diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lj_emit_x86.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lj_emit_x86.h b/src/lj_emit_x86.h index bcceb93e..9c371a95 100644 --- a/src/lj_emit_x86.h +++ b/src/lj_emit_x86.h | |||
@@ -268,10 +268,12 @@ static void emit_movmroi(ASMState *as, Reg base, int32_t ofs, int32_t i) | |||
268 | /* mov r, i / xor r, r */ | 268 | /* mov r, i / xor r, r */ |
269 | static void emit_loadi(ASMState *as, Reg r, int32_t i) | 269 | static void emit_loadi(ASMState *as, Reg r, int32_t i) |
270 | { | 270 | { |
271 | /* XOR r,r is shorter, but modifies the flags. This is bad for HIOP. */ | 271 | /* XOR r,r is shorter, but modifies the flags. This is bad for HIOP/jcc. */ |
272 | if (i == 0 && !(LJ_32 && (IR(as->curins)->o == IR_HIOP || | 272 | if (i == 0 && !(LJ_32 && (IR(as->curins)->o == IR_HIOP || |
273 | (as->curins+1 < as->T->nins && | 273 | (as->curins+1 < as->T->nins && |
274 | IR(as->curins+1)->o == IR_HIOP)))) { | 274 | IR(as->curins+1)->o == IR_HIOP))) && |
275 | !((*as->mcp == 0x0f && (as->mcp[1] & 0xf0) == XI_JCCn) || | ||
276 | (*as->mcp & 0xf0) == XI_JCCs)) { | ||
275 | emit_rr(as, XO_ARITH(XOg_XOR), r, r); | 277 | emit_rr(as, XO_ARITH(XOg_XOR), r, r); |
276 | } else { | 278 | } else { |
277 | MCode *p = as->mcp; | 279 | MCode *p = as->mcp; |