aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMike Pall <mike>2010-11-29 16:00:44 +0100
committerMike Pall <mike>2010-11-29 16:00:44 +0100
commit592cf3ffac0410a01330d9c34dfa7b99143b7b73 (patch)
tree885a7d1b4ffa6e861b9784fd9e238562c574dac0 /src
parent2033d6310bbda7dc5554dd3c473836743929f2c3 (diff)
downloadluajit-592cf3ffac0410a01330d9c34dfa7b99143b7b73.tar.gz
luajit-592cf3ffac0410a01330d9c34dfa7b99143b7b73.tar.bz2
luajit-592cf3ffac0410a01330d9c34dfa7b99143b7b73.zip
Don't mark REF_BASE in DCE.
Diffstat (limited to 'src')
-rw-r--r--src/lj_opt_dce.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lj_opt_dce.c b/src/lj_opt_dce.c
index 083239f6..49cc766e 100644
--- a/src/lj_opt_dce.c
+++ b/src/lj_opt_dce.c
@@ -27,7 +27,7 @@ static void dce_marksnap(jit_State *J)
27 MSize n, nent = snap->nent; 27 MSize n, nent = snap->nent;
28 for (n = 0; n < nent; n++) { 28 for (n = 0; n < nent; n++) {
29 IRRef ref = snap_ref(map[n]); 29 IRRef ref = snap_ref(map[n]);
30 if (!irref_isk(ref)) 30 if (ref >= REF_FIRST)
31 irt_setmark(IR(ref)->t); 31 irt_setmark(IR(ref)->t);
32 } 32 }
33 } 33 }
@@ -54,8 +54,8 @@ static void dce_propagate(jit_State *J)
54 pchain[IR_NOP] = &ir->prev; 54 pchain[IR_NOP] = &ir->prev;
55 continue; 55 continue;
56 } 56 }
57 if (!irref_isk(ir->op1)) irt_setmark(IR(ir->op1)->t); 57 if (ir->op1 >= REF_FIRST) irt_setmark(IR(ir->op1)->t);
58 if (!irref_isk(ir->op2)) irt_setmark(IR(ir->op2)->t); 58 if (ir->op2 >= REF_FIRST) irt_setmark(IR(ir->op2)->t);
59 } 59 }
60 *pchain[IR_NOP] = 0; /* Terminate NOP chain. */ 60 *pchain[IR_NOP] = 0; /* Terminate NOP chain. */
61} 61}