diff options
Diffstat (limited to 'src/lj_asm.c')
-rw-r--r-- | src/lj_asm.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/lj_asm.c b/src/lj_asm.c index ce2a70d7..5ad14003 100644 --- a/src/lj_asm.c +++ b/src/lj_asm.c | |||
@@ -1538,9 +1538,10 @@ static void asm_tail_link(ASMState *as) | |||
1538 | /* -- Trace setup --------------------------------------------------------- */ | 1538 | /* -- Trace setup --------------------------------------------------------- */ |
1539 | 1539 | ||
1540 | /* Clear reg/sp for all instructions and add register hints. */ | 1540 | /* Clear reg/sp for all instructions and add register hints. */ |
1541 | static void asm_setup_regsp(ASMState *as, int sink) | 1541 | static void asm_setup_regsp(ASMState *as) |
1542 | { | 1542 | { |
1543 | GCtrace *T = as->T; | 1543 | GCtrace *T = as->T; |
1544 | int sink = T->sinktags; | ||
1544 | IRRef nins = T->nins; | 1545 | IRRef nins = T->nins; |
1545 | IRIns *ir, *lastir; | 1546 | IRIns *ir, *lastir; |
1546 | int inloop; | 1547 | int inloop; |
@@ -1768,7 +1769,6 @@ void lj_asm_trace(jit_State *J, GCtrace *T) | |||
1768 | ASMState as_; | 1769 | ASMState as_; |
1769 | ASMState *as = &as_; | 1770 | ASMState *as = &as_; |
1770 | MCode *origtop; | 1771 | MCode *origtop; |
1771 | int sink; | ||
1772 | 1772 | ||
1773 | /* Ensure an initialized instruction beyond the last one for HIOP checks. */ | 1773 | /* Ensure an initialized instruction beyond the last one for HIOP checks. */ |
1774 | J->cur.nins = lj_ir_nextins(J); | 1774 | J->cur.nins = lj_ir_nextins(J); |
@@ -1789,7 +1789,6 @@ void lj_asm_trace(jit_State *J, GCtrace *T) | |||
1789 | as->mcp = as->mctop; | 1789 | as->mcp = as->mctop; |
1790 | as->mclim = as->mcbot + MCLIM_REDZONE; | 1790 | as->mclim = as->mcbot + MCLIM_REDZONE; |
1791 | asm_setup_target(as); | 1791 | asm_setup_target(as); |
1792 | sink = (IR(REF_BASE)->prev == 1); | ||
1793 | 1792 | ||
1794 | do { | 1793 | do { |
1795 | as->mcp = as->mctop; | 1794 | as->mcp = as->mctop; |
@@ -1805,7 +1804,7 @@ void lj_asm_trace(jit_State *J, GCtrace *T) | |||
1805 | as->gcsteps = 0; | 1804 | as->gcsteps = 0; |
1806 | as->sectref = as->loopref; | 1805 | as->sectref = as->loopref; |
1807 | as->fuseref = (as->flags & JIT_F_OPT_FUSE) ? as->loopref : FUSE_DISABLED; | 1806 | as->fuseref = (as->flags & JIT_F_OPT_FUSE) ? as->loopref : FUSE_DISABLED; |
1808 | asm_setup_regsp(as, sink); | 1807 | asm_setup_regsp(as); |
1809 | if (!as->loopref) | 1808 | if (!as->loopref) |
1810 | asm_tail_link(as); | 1809 | asm_tail_link(as); |
1811 | 1810 | ||