diff options
author | Mike Pall <mike> | 2014-02-20 15:09:02 +0100 |
---|---|---|
committer | Mike Pall <mike> | 2014-02-20 15:09:02 +0100 |
commit | 2863b1095699404693a50082dd8d19b6c4cad99f (patch) | |
tree | 4c4626f4b8a342773fdd961f46eb39dc43616e5e /src/lj_asm_x86.h | |
parent | 46ce03464b67935fb84ace1d0710a7f3cc62e132 (diff) | |
parent | 998651fcdafc8b6f3d922e1e60864fec83409118 (diff) | |
download | luajit-2863b1095699404693a50082dd8d19b6c4cad99f.tar.gz luajit-2863b1095699404693a50082dd8d19b6c4cad99f.tar.bz2 luajit-2863b1095699404693a50082dd8d19b6c4cad99f.zip |
Merge branch 'master' into v2.1
Diffstat (limited to 'src/lj_asm_x86.h')
-rw-r--r-- | src/lj_asm_x86.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lj_asm_x86.h b/src/lj_asm_x86.h index 398d34ef..3e87ba18 100644 --- a/src/lj_asm_x86.h +++ b/src/lj_asm_x86.h | |||
@@ -638,6 +638,7 @@ static void asm_retf(ASMState *as, IRIns *ir) | |||
638 | int32_t delta = 1+bc_a(*((const BCIns *)pc - 1)); | 638 | int32_t delta = 1+bc_a(*((const BCIns *)pc - 1)); |
639 | as->topslot -= (BCReg)delta; | 639 | as->topslot -= (BCReg)delta; |
640 | if ((int32_t)as->topslot < 0) as->topslot = 0; | 640 | if ((int32_t)as->topslot < 0) as->topslot = 0; |
641 | irt_setmark(IR(REF_BASE)->t); /* Children must not coalesce with BASE reg. */ | ||
641 | emit_setgl(as, base, jit_base); | 642 | emit_setgl(as, base, jit_base); |
642 | emit_addptr(as, base, -8*delta); | 643 | emit_addptr(as, base, -8*delta); |
643 | asm_guardcc(as, CC_NE); | 644 | asm_guardcc(as, CC_NE); |
@@ -2508,7 +2509,7 @@ static void asm_head_root_base(ASMState *as) | |||
2508 | Reg r = ir->r; | 2509 | Reg r = ir->r; |
2509 | if (ra_hasreg(r)) { | 2510 | if (ra_hasreg(r)) { |
2510 | ra_free(as, r); | 2511 | ra_free(as, r); |
2511 | if (rset_test(as->modset, r)) | 2512 | if (rset_test(as->modset, r) || irt_ismarked(ir->t)) |
2512 | ir->r = RID_INIT; /* No inheritance for modified BASE register. */ | 2513 | ir->r = RID_INIT; /* No inheritance for modified BASE register. */ |
2513 | if (r != RID_BASE) | 2514 | if (r != RID_BASE) |
2514 | emit_rr(as, XO_MOV, r, RID_BASE); | 2515 | emit_rr(as, XO_MOV, r, RID_BASE); |
@@ -2522,7 +2523,7 @@ static RegSet asm_head_side_base(ASMState *as, IRIns *irp, RegSet allow) | |||
2522 | Reg r = ir->r; | 2523 | Reg r = ir->r; |
2523 | if (ra_hasreg(r)) { | 2524 | if (ra_hasreg(r)) { |
2524 | ra_free(as, r); | 2525 | ra_free(as, r); |
2525 | if (rset_test(as->modset, r)) | 2526 | if (rset_test(as->modset, r) || irt_ismarked(ir->t)) |
2526 | ir->r = RID_INIT; /* No inheritance for modified BASE register. */ | 2527 | ir->r = RID_INIT; /* No inheritance for modified BASE register. */ |
2527 | if (irp->r == r) { | 2528 | if (irp->r == r) { |
2528 | rset_clear(allow, r); /* Mark same BASE register as coalesced. */ | 2529 | rset_clear(allow, r); /* Mark same BASE register as coalesced. */ |