EncodedMethod toEncodedMethod(DexOptions dexOptions) { RopMethod ropMethod = new RopMethod(code.toBasicBlocks(), 0); LocalVariableInfo locals = null; DalvCode dalvCode = RopTranslator.translate( ropMethod, PositionList.NONE, locals, code.paramSize(), dexOptions); return new EncodedMethod(method.constant, flags, dalvCode, StdTypeList.EMPTY); } }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Returns an instance that is identical to this one, except that * the registers in each instruction are offset by the given * amount. * * @param delta the amount to offset register numbers by * @return {@code non-null;} an appropriately-constructed instance */ public RopMethod withRegisterOffset(int delta) { RopMethod result = new RopMethod(blocks.withRegisterOffset(delta), firstLabel); if (exitPredecessors != null) { /* * The predecessors have been calculated. It's safe to * inject these into the new instance, since the * transformation being applied doesn't affect the * predecessors. */ result.exitPredecessors = exitPredecessors; result.predecessors = predecessors; } return result; }
/** * Extracts the resulting {@link RopMethod} from the instance. * * @return {@code non-null;} the method object */ private RopMethod getRopMethod() { // Construct the final list of blocks. int sz = result.size(); BasicBlockList bbl = new BasicBlockList(sz); for (int i = 0; i < sz; i++) { bbl.set(i, result.get(i)); } bbl.setImmutable(); // Construct the method object to wrap it all up. /* * Note: The parameter assignment block is always the first * that should be executed, hence the second argument to the * constructor. */ return new RopMethod(bbl, getSpecialLabel(PARAM_ASSIGNMENT)); }
/** * Extracts the resulting {@link RopMethod} from the instance. * * @return {@code non-null;} the method object */ private RopMethod getRopMethod() { // Construct the final list of blocks. int sz = result.size(); BasicBlockList bbl = new BasicBlockList(sz); for (int i = 0; i < sz; i++) { bbl.set(i, result.get(i)); } bbl.setImmutable(); // Construct the method object to wrap it all up. /* * Note: The parameter assignment block is always the first * that should be executed, hence the second argument to the * constructor. */ return new RopMethod(bbl, getSpecialLabel(PARAM_ASSIGNMENT)); }
/** * Extracts the resulting {@link RopMethod} from the instance. * * @return {@code non-null;} the method object */ private RopMethod getRopMethod() { // Construct the final list of blocks. int sz = result.size(); BasicBlockList bbl = new BasicBlockList(sz); for (int i = 0; i < sz; i++) { bbl.set(i, result.get(i)); } bbl.setImmutable(); // Construct the method object to wrap it all up. /* * Note: The parameter assignment block is always the first * that should be executed, hence the second argument to the * constructor. */ return new RopMethod(bbl, getSpecialLabel(PARAM_ASSIGNMENT)); }
/** * Extracts the resulting {@link RopMethod} from the instance. * * @return {@code non-null;} the method object */ private RopMethod getRopMethod() { // Construct the final list of blocks. int sz = result.size(); BasicBlockList bbl = new BasicBlockList(sz); for (int i = 0; i < sz; i++) { bbl.set(i, result.get(i)); } bbl.setImmutable(); // Construct the method object to wrap it all up. /* * Note: The parameter assignment block is always the first * that should be executed, hence the second argument to the * constructor. */ return new RopMethod(bbl, getSpecialLabel(PARAM_ASSIGNMENT)); }
/** * Extracts the resulting {@link RopMethod} from the instance. * * @return {@code non-null;} the method object */ private RopMethod getRopMethod() { // Construct the final list of blocks. int sz = result.size(); BasicBlockList bbl = new BasicBlockList(sz); for (int i = 0; i < sz; i++) { bbl.set(i, result.get(i)); } bbl.setImmutable(); // Construct the method object to wrap it all up. /* * Note: The parameter assignment block is always the first * that should be executed, hence the second argument to the * constructor. */ return new RopMethod(bbl, getSpecialLabel(PARAM_ASSIGNMENT)); }
/** * Extracts the resulting {@link RopMethod} from the instance. * * @return {@code non-null;} the method object */ private RopMethod getRopMethod() { // Construct the final list of blocks. int sz = result.size(); BasicBlockList bbl = new BasicBlockList(sz); for (int i = 0; i < sz; i++) { bbl.set(i, result.get(i)); } bbl.setImmutable(); // Construct the method object to wrap it all up. /* * Note: The parameter assignment block is always the first * that should be executed, hence the second argument to the * constructor. */ return new RopMethod(bbl, getSpecialLabel(PARAM_ASSIGNMENT)); }
EncodedMethod toEncodedMethod(DexOptions dexOptions) { RopMethod ropMethod = new RopMethod(code.toBasicBlocks(), 0); LocalVariableInfo locals = null; DalvCode dalvCode = RopTranslator.translate(ropMethod, PositionList.NONE, locals, code.paramSize(), dexOptions); return new EncodedMethod(method.constant, flags, dalvCode, StdTypeList.EMPTY); } }
EncodedMethod toEncodedMethod(DexOptions dexOptions) { RopMethod ropMethod = new RopMethod(code.toBasicBlocks(), 0); LocalVariableInfo locals = null; DalvCode dalvCode = RopTranslator.translate( ropMethod, PositionList.NONE, locals, code.paramSize(), dexOptions); return new EncodedMethod(method.constant, flags, dalvCode, StdTypeList.EMPTY); } }
EncodedMethod toEncodedMethod(DexOptions dexOptions) { RopMethod ropMethod = new RopMethod(code.toBasicBlocks(), 0); LocalVariableInfo locals = null; DalvCode dalvCode = RopTranslator.translate( ropMethod, PositionList.NONE, locals, code.paramSize(), dexOptions); return new EncodedMethod(method.constant, flags, dalvCode, StdTypeList.EMPTY); } }
RopMethod ropMethod = new RopMethod(convertBasicBlocks(), ssaMeth.blockIndexToRopLabel(ssaMeth.getEntryBlockIndex())); ropMethod = new IdenticalBlockCombiner(ropMethod).process();
RopMethod ropMethod = new RopMethod(convertBasicBlocks(), ssaMeth.blockIndexToRopLabel(ssaMeth.getEntryBlockIndex())); ropMethod = new IdenticalBlockCombiner(ropMethod).process();
RopMethod ropMethod = new RopMethod(convertBasicBlocks(), ssaMeth.blockIndexToRopLabel(ssaMeth.getEntryBlockIndex())); ropMethod = new IdenticalBlockCombiner(ropMethod).process();