Class MethodAnalyzer
- java.lang.Object
-
- com.offbynull.coroutines.instrumenter.MethodAnalyzer
-
final class MethodAnalyzer extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classMethodAnalyzer.TypeTracker
-
Field Summary
Fields Modifier and Type Field Description private ClassInformationRepositoryclassInfoRepoprivate static org.objectweb.asm.TypeCONTINUATION_CLASS_TYPEprivate static java.lang.reflect.MethodCONTINUATION_SUSPEND_METHOD
-
Constructor Summary
Constructors Constructor Description MethodAnalyzer(ClassInformationRepository classInfoRepo)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private CacheVariablesallocateCacheVariableSlots(VariableTable varTable, MethodAnalyzer.TypeTracker invocationReturnTypes, boolean invocationFoundWrappedInTryCatch)private LockVariablesallocateLockVariableSlots(VariableTable varTable, boolean containsSyncPoints)private StorageContainerVariablesallocateStorageContainerVariableSlots(VariableTable varTable)private StorageVariablesallocateStorageVariableSlots(VariableTable varTable, MethodAnalyzer.TypeTracker storageTypes)MethodAttributesanalyze(org.objectweb.asm.tree.ClassNode classNode, org.objectweb.asm.tree.MethodNode methodNode, InstrumentationSettings settings)private intgetLocalVariableIndexOfContinuationParameter(org.objectweb.asm.tree.MethodNode methodNode)private voidvalidateNoInvokeDynamic(java.util.List<org.objectweb.asm.tree.AbstractInsnNode> insnNodes)
-
-
-
Field Detail
-
CONTINUATION_CLASS_TYPE
private static final org.objectweb.asm.Type CONTINUATION_CLASS_TYPE
-
CONTINUATION_SUSPEND_METHOD
private static final java.lang.reflect.Method CONTINUATION_SUSPEND_METHOD
-
classInfoRepo
private final ClassInformationRepository classInfoRepo
-
-
Constructor Detail
-
MethodAnalyzer
MethodAnalyzer(ClassInformationRepository classInfoRepo)
-
-
Method Detail
-
analyze
public MethodAttributes analyze(org.objectweb.asm.tree.ClassNode classNode, org.objectweb.asm.tree.MethodNode methodNode, InstrumentationSettings settings)
-
getLocalVariableIndexOfContinuationParameter
private int getLocalVariableIndexOfContinuationParameter(org.objectweb.asm.tree.MethodNode methodNode)
-
allocateCacheVariableSlots
private CacheVariables allocateCacheVariableSlots(VariableTable varTable, MethodAnalyzer.TypeTracker invocationReturnTypes, boolean invocationFoundWrappedInTryCatch)
-
allocateStorageVariableSlots
private StorageVariables allocateStorageVariableSlots(VariableTable varTable, MethodAnalyzer.TypeTracker storageTypes)
-
allocateStorageContainerVariableSlots
private StorageContainerVariables allocateStorageContainerVariableSlots(VariableTable varTable)
-
allocateLockVariableSlots
private LockVariables allocateLockVariableSlots(VariableTable varTable, boolean containsSyncPoints)
-
validateNoInvokeDynamic
private void validateNoInvokeDynamic(java.util.List<org.objectweb.asm.tree.AbstractInsnNode> insnNodes)
-
-