preds is array instead of hash

appendInstruction() takes no parameter any more


git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@553 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 26 years ago
parent 541f1446ff
commit 1f6e56b052
  1. 6
      jode/jode/obfuscator/RemovePopAnalyzer.java

@ -49,7 +49,7 @@ public class RemovePopAnalyzer implements CodeAnalyzer, Opcodes {
Instruction findMatchingPush(Instruction instr) { Instruction findMatchingPush(Instruction instr) {
int count = 0; int count = 0;
while (true) { while (true) {
if (instr.preds.size() != 1) if (instr.preds != null)
return null; return null;
instr = instr.prevByAddr; instr = instr.prevByAddr;
switch (instr.opcode) { switch (instr.opcode) {
@ -346,7 +346,7 @@ public class RemovePopAnalyzer implements CodeAnalyzer, Opcodes {
if (instr.opcode == opc_pop) if (instr.opcode == opc_pop)
instr.opcode = opc_pop2; instr.opcode = opc_pop2;
else { else {
Instruction thirdPop = instr.appendInstruction(false); Instruction thirdPop = instr.appendInstruction();
thirdPop.length = 1; thirdPop.length = 1;
thirdPop.opcode = opc_pop; thirdPop.opcode = opc_pop;
} }
@ -399,7 +399,7 @@ public class RemovePopAnalyzer implements CodeAnalyzer, Opcodes {
* split it and continue with second half * split it and continue with second half
*/ */
instr.opcode = opc_pop; instr.opcode = opc_pop;
instr = instr.appendInstruction(false); instr = instr.appendInstruction();
instr.opcode = opc_pop; instr.opcode = opc_pop;
instr.length = 1; instr.length = 1;
continue; continue;

Loading…
Cancel
Save