/** * Ends the current basic block. This method must be used in the case where the current basic * block does not have any successor. * * <p>WARNING: this method must be called after the currently visited instruction has been put in * {@link #code} (if frames are computed, this method inserts a new Label to start a new basic * block after the current instruction). */ private void endCurrentBasicBlockWithNoSuccessor() { if (compute == COMPUTE_ALL_FRAMES) { Label nextBasicBlock = new Label(); nextBasicBlock.frame = new Frame(nextBasicBlock); nextBasicBlock.resolve(code.data, code.length); lastBasicBlock.nextBasicBlock = nextBasicBlock; lastBasicBlock = nextBasicBlock; currentBasicBlock = null; } else if (compute == COMPUTE_MAX_STACK_AND_LOCAL) { currentBasicBlock.outputStackMax = (short) maxRelativeStackSize; currentBasicBlock = null; } }
/** * Sets this CurrentFrame to the input stack map frame of the next "current" instruction, i.e. the * instruction just after the given one. It is assumed that the value of this object when this * method is called is the stack map frame status just before the given instruction is executed. */ @Override void execute( final int opcode, final int arg, final Symbol symbolArg, final SymbolTable symbolTable) { super.execute(opcode, arg, symbolArg, symbolTable); Frame successor = new Frame(null); merge(symbolTable, successor, 0); copyFrom(successor); } }
label.frame = new Frame(label); } else if (compute == COMPUTE_INSERTED_FRAMES) { if (currentBasicBlock == null) {
if (previousFrame == null) { int argumentsSize = Type.getArgumentsAndReturnSizes(descriptor) >> 2; Frame implicitFirstFrame = new Frame(new Label()); implicitFirstFrame.setInputFrameFromDescriptor( symbolTable, accessFlags, descriptor, argumentsSize);
/** * Ends the current basic block. This method must be used in the case where * the current basic block does not have any successor. */ private void noSuccessor() { if (compute == FRAMES) { Label l = new Label(); l.frame = new Frame(); l.frame.owner = l; l.resolve(this, code.length, code.data); previousBlock.successor = l; previousBlock = l; } else { currentBlock.outputStackMax = maxStackSize; } currentBlock = null; }
/** * Ends the current basic block. This method must be used in the case where the current basic * block does not have any successor. * * <p>WARNING: this method must be called after the currently visited instruction has been put in * {@link #code} (if frames are computed, this method inserts a new Label to start a new basic * block after the current instruction). */ private void endCurrentBasicBlockWithNoSuccessor() { if (compute == COMPUTE_ALL_FRAMES) { Label nextBasicBlock = new Label(); nextBasicBlock.frame = new Frame(nextBasicBlock); nextBasicBlock.resolve(code.data, code.length); lastBasicBlock.nextBasicBlock = nextBasicBlock; lastBasicBlock = nextBasicBlock; currentBasicBlock = null; } else if (compute == COMPUTE_MAX_STACK_AND_LOCAL) { currentBasicBlock.outputStackMax = (short) maxRelativeStackSize; currentBasicBlock = null; } }
/** * Ends the current basic block. This method must be used in the case where the current basic * block does not have any successor. * * <p>WARNING: this method must be called after the currently visited instruction has been put in * {@link #code} (if frames are computed, this method inserts a new Label to start a new basic * block after the current instruction). */ private void endCurrentBasicBlockWithNoSuccessor() { if (compute == COMPUTE_ALL_FRAMES) { Label nextBasicBlock = new Label(); nextBasicBlock.frame = new Frame(nextBasicBlock); nextBasicBlock.resolve(code.data, code.length); lastBasicBlock.nextBasicBlock = nextBasicBlock; lastBasicBlock = nextBasicBlock; currentBasicBlock = null; } else if (compute == COMPUTE_MAX_STACK_AND_LOCAL) { currentBasicBlock.outputStackMax = (short) maxRelativeStackSize; currentBasicBlock = null; } }
/** * Ends the current basic block. This method must be used in the case where * the current basic block does not have any successor. */ private void noSuccessor() { if (compute == FRAMES) { Label l = new Label(); l.frame = new Frame(); l.frame.owner = l; l.resolve(this, code.length, code.data); previousBlock.successor = l; previousBlock = l; } else { currentBlock.outputStackMax = maxStackSize; } if (compute != INSERTED_FRAMES) { currentBlock = null; } }
/** * Ends the current basic block. This method must be used in the case where the current basic * block does not have any successor. * * <p>WARNING: this method must be called after the currently visited instruction has been put in * {@link #code} (if frames are computed, this method inserts a new Label to start a new basic * block after the current instruction). */ private void endCurrentBasicBlockWithNoSuccessor() { if (compute == COMPUTE_ALL_FRAMES) { Label nextBasicBlock = new Label(); nextBasicBlock.frame = new Frame(nextBasicBlock); nextBasicBlock.resolve(code.data, code.length); lastBasicBlock.nextBasicBlock = nextBasicBlock; lastBasicBlock = nextBasicBlock; currentBasicBlock = null; } else if (compute == COMPUTE_MAX_STACK_AND_LOCAL) { currentBasicBlock.outputStackMax = (short) maxRelativeStackSize; currentBasicBlock = null; } }
/** * Sets this CurrentFrame to the input stack map frame of the next "current" * instruction, i.e. the instruction just after the given one. It is assumed * that the value of this object when this method is called is the stack map * frame status just before the given instruction is executed. */ @Override void execute(int opcode, int arg, ClassWriter cw, Item item) { super.execute(opcode, arg, cw, item); Frame successor = new Frame(); merge(cw, successor, 0); set(successor); owner.inputStackTop = 0; } }
/** * Sets this CurrentFrame to the input stack map frame of the next "current" instruction, i.e. the * instruction just after the given one. It is assumed that the value of this object when this * method is called is the stack map frame status just before the given instruction is executed. */ @Override void execute( final int opcode, final int arg, final Symbol symbolArg, final SymbolTable symbolTable) { super.execute(opcode, arg, symbolArg, symbolTable); Frame successor = new Frame(null); merge(symbolTable, successor, 0); copyFrom(successor); } }
/** * Sets this CurrentFrame to the input stack map frame of the next "current" instruction, i.e. the * instruction just after the given one. It is assumed that the value of this object when this * method is called is the stack map frame status just before the given instruction is executed. */ @Override void execute( final int opcode, final int arg, final Symbol symbolArg, final SymbolTable symbolTable) { super.execute(opcode, arg, symbolArg, symbolTable); Frame successor = new Frame(null); merge(symbolTable, successor, 0); copyFrom(successor); } }
/** * Sets this CurrentFrame to the input stack map frame of the next "current" instruction, i.e. the * instruction just after the given one. It is assumed that the value of this object when this * method is called is the stack map frame status just before the given instruction is executed. */ @Override void execute( final int opcode, final int arg, final Symbol symbolArg, final SymbolTable symbolTable) { super.execute(opcode, arg, symbolArg, symbolTable); Frame successor = new Frame(null); merge(symbolTable, successor, 0); copyFrom(successor); } }
label.frame = new Frame(); label.frame.owner = label;
label.frame = new Frame(label); } else if (compute == COMPUTE_INSERTED_FRAMES) { if (currentBasicBlock == null) {
label.frame = new Frame(); label.frame.owner = label;
label.frame = new Frame(label); } else if (compute == COMPUTE_INSERTED_FRAMES) { if (currentBasicBlock == null) {
label.frame = new Frame(label); } else if (compute == COMPUTE_INSERTED_FRAMES) { if (currentBasicBlock == null) {
if (previousFrame == null) { int argumentsSize = Type.getArgumentsAndReturnSizes(descriptor) >> 2; Frame implicitFirstFrame = new Frame(new Label()); implicitFirstFrame.setInputFrameFromDescriptor( symbolTable, accessFlags, descriptor, argumentsSize);
if (previousFrame == null) { int argumentsSize = Type.getArgumentsAndReturnSizes(descriptor) >> 2; Frame implicitFirstFrame = new Frame(new Label()); implicitFirstFrame.setInputFrameFromDescriptor( symbolTable, accessFlags, descriptor, argumentsSize);