projects
/
org.ibex.classgen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
536baf9
)
cleanup POP/DUP
author
brian
<brian@brianweb.net>
Sun, 3 Jul 2005 21:46:27 +0000
(21:46 +0000)
committer
brian
<brian@brianweb.net>
Sun, 3 Jul 2005 21:46:27 +0000
(21:46 +0000)
darcs-hash:
20050703214627
-24bed-
39d2065025693ee95483535a7b901f010bac819f
.gz
src/org/ibex/classgen/JSSA.java
patch
|
blob
|
history
diff --git
a/src/org/ibex/classgen/JSSA.java
b/src/org/ibex/classgen/JSSA.java
index
d01aa06
..
d6c15b7
100644
(file)
--- a/
src/org/ibex/classgen/JSSA.java
+++ b/
src/org/ibex/classgen/JSSA.java
@@
-483,10
+483,10
@@
public class JSSA extends MethodGen implements CGConst {
case ISTORE_1: case LSTORE_1: case FSTORE_1: case DSTORE_1: case ASTORE_1: local[1] = pop(); return null;
case ASTORE_2: case DSTORE_2: case FSTORE_2: case LSTORE_2: case ISTORE_2: local[2] = pop(); return null;
case ISTORE_3: case LSTORE_3: case FSTORE_3: case DSTORE_3: case ASTORE_3: local[3] = pop(); return null;
case ISTORE_1: case LSTORE_1: case FSTORE_1: case DSTORE_1: case ASTORE_1: local[1] = pop(); return null;
case ASTORE_2: case DSTORE_2: case FSTORE_2: case LSTORE_2: case ISTORE_2: local[2] = pop(); return null;
case ISTORE_3: case LSTORE_3: case FSTORE_3: case DSTORE_3: case ASTORE_3: local[3] = pop(); return null;
- case POP: stack[--sp] = null;
- case POP2: stack[--sp] = null; stack[--sp] = null; /** fixme: pops a WORD, not an item */
- case DUP: stack[sp] = stack[sp-1]; sp++;
- case DUP2: stack[sp] = stack[sp-2]; stack[sp+1] = stack[sp-1]; sp+=2;
+ case POP: pop(); return null;
+ case POP2: pop(); pop(); return null;
+ case DUP: push(stack[sp-1]); return null;
+ case DUP2: push(stack[sp-2]); push(stack[sp-2]); return null;
// Conversions //////////////////////////////////////////////////////////////////////////////
// Conversions //////////////////////////////////////////////////////////////////////////////