Examples of produceStack()


Examples of org.apache.bcel.generic.Instruction.produceStack()

                    InstructionHandle lastLogHandle = handle;
                    logger.info(
                        "Found a ReturnInstruction of type: "
                            + inst.toString());
                    int stackSize =
                        inst.consumeStack(cp) - inst.produceStack(cp);
                    while (stackSize != 0) {
                        handle = handle.getPrev();
                        inst = handle.getInstruction();
                        logger.info("prev instruction: " + inst);
                        stackSize += inst.consumeStack(cp)
View Full Code Here

Examples of org.apache.bcel.generic.Instruction.produceStack()

                    while (stackSize != 0) {
                        handle = handle.getPrev();
                        inst = handle.getInstruction();
                        logger.info("prev instruction: " + inst);
                        stackSize += inst.consumeStack(cp)
                            - inst.produceStack(cp);
                    }

                    InstructionHandle insertHandle =
                        insertExit(mg, il, handle, cp);
                    if (insertHandle != null) {
View Full Code Here

Examples of org.apache.bcel.generic.Instruction.produceStack()

        // about which new is-null information is known.
        // If any other instances of the produced values exist,
        // update their is-null information.
        // Also, make a note of any newly-produced null values.

        int numProduced = ins.produceStack(methodGen.getConstantPool());
        if (numProduced == Constants.UNPREDICTABLE) {
            throw new DataflowAnalysisException("Unpredictable stack production", methodGen, handle);
        }

        int start = fact.getNumSlots() - numProduced;
View Full Code Here

Examples of org.apache.bcel.generic.Instruction.produceStack()

    @Override
    public void transferInstruction(InstructionHandle handle, BasicBlock basicBlock, StackDepth fact)
            throws DataflowAnalysisException {
        Instruction ins = handle.getInstruction();
        int produced = ins.produceStack(cpg);
        int consumed = ins.consumeStack(cpg);
        if (produced == Constants.UNPREDICTABLE || consumed == Constants.UNPREDICTABLE) {
            throw new IllegalStateException("Unpredictable stack delta for instruction: " + handle);
        }
        int depth = fact.getDepth();
View Full Code Here

Examples of org.apache.bcel.generic.Instruction.produceStack()

        for (Iterator<Location> i = cfg.locationIterator(); i.hasNext();) {
            Location location = i.next();
            Instruction instruction = location.getHandle().getInstruction();
            short opcode = instruction.getOpcode();

            int produces = instruction.produceStack(cpg);
            if (instruction instanceof InvokeInstruction) {
                // Model return value
                registerReturnValueSource(location);
            } else if (opcode == Constants.GETFIELD || opcode == Constants.GETSTATIC) {
                // Model field loads
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.