only merge adjacent pops, if the second has no predecessors

git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@586 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 26 years ago
parent 4d71621216
commit 9836620e6c
  1. 4
      jode/jode/obfuscator/RemovePopAnalyzer.java

@ -203,7 +203,7 @@ public class RemovePopAnalyzer implements CodeAnalyzer, Opcodes {
case opc_istore: case opc_istore:
case opc_fstore: case opc_astore: case opc_fstore: case opc_astore:
case opc_pop: case opc_pop:
count ++; count++;
break; break;
case opc_lstore: case opc_dstore: case opc_lstore: case opc_dstore:
@ -405,7 +405,7 @@ public class RemovePopAnalyzer implements CodeAnalyzer, Opcodes {
continue; continue;
} }
} }
if (instr.opcode == opc_pop if (instr.opcode == opc_pop && instr.preds == null
&& instr.prevByAddr.opcode == opc_pop) { && instr.prevByAddr.opcode == opc_pop) {
/* merge two single pops together. */ /* merge two single pops together. */
instr.prevByAddr.removeInstruction(); instr.prevByAddr.removeInstruction();

Loading…
Cancel
Save