public abstract class MethodProbesVisitor
extends org.objectweb.asm.MethodVisitor
MethodVisitor
with additional methods to get probe insertion
information.Constructor and Description |
---|
MethodProbesVisitor()
New visitor instance without delegate visitor.
|
MethodProbesVisitor(org.objectweb.asm.MethodVisitor mv)
New visitor instance that delegates to the given visitor.
|
Modifier and Type | Method and Description |
---|---|
abstract void |
visitInsnWithProbe(int opcode,
int probeId)
Visits a zero operand instruction with a probe.
|
abstract void |
visitJumpInsnWithProbe(int opcode,
org.objectweb.asm.Label label,
int probeId,
IFrame frame)
Visits a jump instruction.
|
abstract void |
visitLookupSwitchInsnWithProbes(org.objectweb.asm.Label dflt,
int[] keys,
org.objectweb.asm.Label[] labels,
IFrame frame)
Visits a LOOKUPSWITCH instruction with optional probes for each target
label.
|
abstract void |
visitProbe(int probeId)
Visits an unconditional probe that should be inserted at the current
position.
|
abstract void |
visitTableSwitchInsnWithProbes(int min,
int max,
org.objectweb.asm.Label dflt,
org.objectweb.asm.Label[] labels,
IFrame frame)
Visits a TABLESWITCH instruction with optional probes for each target
label.
|
visitAnnotation, visitAnnotationDefault, visitAttribute, visitCode, visitEnd, visitFieldInsn, visitFrame, visitIincInsn, visitInsn, visitInsnAnnotation, visitIntInsn, visitInvokeDynamicInsn, visitJumpInsn, visitLabel, visitLdcInsn, visitLineNumber, visitLocalVariable, visitLocalVariableAnnotation, visitLookupSwitchInsn, visitMaxs, visitMethodInsn, visitMethodInsn, visitMultiANewArrayInsn, visitParameter, visitParameterAnnotation, visitTableSwitchInsn, visitTryCatchAnnotation, visitTryCatchBlock, visitTypeAnnotation, visitTypeInsn, visitVarInsn
public MethodProbesVisitor()
public MethodProbesVisitor(org.objectweb.asm.MethodVisitor mv)
mv
- optional next visitor in chainpublic abstract void visitProbe(int probeId)
probeId
- id of the probe to insertpublic abstract void visitJumpInsnWithProbe(int opcode, org.objectweb.asm.Label label, int probeId, IFrame frame)
opcode
- the opcode of the type instruction to be visited. This opcode
is either IFEQ, IFNE, IFLT, IFGE, IFGT, IFLE, IF_ICMPEQ,
IF_ICMPNE, IF_ICMPLT, IF_ICMPGE, IF_ICMPGT, IF_ICMPLE,
IF_ACMPEQ, IF_ACMPNE, GOTO, IFNULL or IFNONNULL.label
- the operand of the instruction to be visited. This operand is
a label that designates the instruction to which the jump
instruction may jump.probeId
- id of the probeframe
- stackmap frame status after the execution of the jump
instruction. The instance is only valid with the call of this
method.MethodVisitor.visitJumpInsn(int, Label)
public abstract void visitInsnWithProbe(int opcode, int probeId)
opcode
- the opcode of the instruction to be visited. This opcode is
either IRETURN, LRETURN, FRETURN, DRETURN, ARETURN, RETURN or
ATHROW.probeId
- id of the probeMethodVisitor.visitInsn(int)
public abstract void visitTableSwitchInsnWithProbes(int min, int max, org.objectweb.asm.Label dflt, org.objectweb.asm.Label[] labels, IFrame frame)
LabelInfo.getProbeId(Label)
.min
- the minimum key value.max
- the maximum key value.dflt
- beginning of the default handler block.labels
- beginnings of the handler blocks. labels[i]
is
the beginning of the handler block for the
min + i
key.frame
- stackmap frame status after the execution of the switch
instruction. The instance is only valid with the call of this
method.MethodVisitor.visitTableSwitchInsn(int, int, Label, Label[])
public abstract void visitLookupSwitchInsnWithProbes(org.objectweb.asm.Label dflt, int[] keys, org.objectweb.asm.Label[] labels, IFrame frame)
LabelInfo.getProbeId(Label)
.dflt
- beginning of the default handler block.keys
- the values of the keys.labels
- beginnings of the handler blocks. labels[i]
is
the beginning of the handler block for the
keys[i]
key.frame
- stackmap frame status after the execution of the switch
instruction. The instance is only valid with the call of this
method.MethodVisitor.visitLookupSwitchInsn(Label, int[], Label[])
Copyright © 2015. All rights reserved.