abstract class BytecodeContainer extends java.lang.Object implements WritableData, CompilerConstants
Modifier and Type | Field and Description |
---|---|
protected int |
length
Number of bytes which this container consumes.
|
protected int |
offset
Byte position of the beginning of this container.
|
_aastore, _aconst_null, _aload_0, _aload_1, _aload_2, _aload_3, _anewarray, _areturn, _astore_1, _astore_2, _astore_3, _checkcast, _d2i, _d2l, _dadd, _dcmpg, _dconst_0, _dconst_1, _ddiv, _dmul, _dneg, _drem, _dreturn, _dsub, _dup, _getfield, _goto, _i2d, _i2l, _iadd, _iand, _iconst_0, _iconst_1, _iconst_2, _iconst_3, _iconst_4, _iconst_5, _idiv, _if_icmpeq, _if_icmpge, _if_icmpgt, _if_icmple, _if_icmplt, _if_icmpne, _ifeq, _ifge, _ifgt, _ifle, _iflt, _ifne, _ifnonnull, _ifnull, _imul, _ineg, _invokeinterface, _invokespecial, _invokestatic, _invokevirtual, _ior, _irem, _ireturn, _ishl, _ishr, _isub, _iushr, _ixor, _l2d, _l2i, _ladd, _land, _lcmp, _lconst_0, _lconst_1, _ldc_w, _ldc2_w, _ldiv, _lmul, _lneg, _lor, _lrem, _lshl, _lshr, _lsub, _lushr, _lxor, _new, _pop, _pop2, _return, _swap, CLASS_COMPILEDEXPRESSION, METHDESC_EXECUTE, METHNAME_EXECUTE, METHOD_INIT
Constructor and Description |
---|
BytecodeContainer() |
Modifier and Type | Method and Description |
---|---|
void |
fixupBranchOffset()
This method may be overridden if the subclass needs to perform any
special processing to fix up its branch instructions (if any) so
that their arguments will branch to the proper offset in the bytecode
array.
|
(package private) abstract void |
fixupStack(java.util.Stack stack)
This method must be implemented to pop away any superfluous runtime
stack entries in the event the compiled code must branch control.
|
(package private) int |
getLength()
Return the length, in bytes, of this code container.
|
(package private) int |
getOffset()
Return the offset of the first instruction in this container.
|
(package private) abstract int |
layout(int offset)
This method must be implemented to assign the specified offset to
this bytecode container, and to return the offset pointing to the
beginning of the next available position in the bytecode array.
|
(package private) abstract void |
modifyStackDepth(Compiler compiler)
This method must be implemented to update the stack depth of the
current bytecode array, based upon the impact of the instruction(s)
which compose that bytecode array.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
write
protected int offset
protected int length
int getOffset()
int getLength()
abstract void modifyStackDepth(Compiler compiler)
compiler
- Expression compiler which maintains stack depth information.abstract int layout(int offset)
offset
- Integer offset (position) of the beginning bytecode in this
bytecode container.abstract void fixupStack(java.util.Stack stack)
stack
- Stack object which represents the state the runtime stack
will be in at the time the instructions in this bytecode
container are executed.public void fixupBranchOffset()