Explorar o código

x64/LJ_GC64: Fix type-check-only variant of SLOAD.

Thanks to Peter Cawley.
Mike Pall %!s(int64=8) %!d(string=hai) anos
pai
achega
05fbdf565c
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/lj_asm_x86.h

+ 1 - 1
src/lj_asm_x86.h

@@ -1759,7 +1759,7 @@ static void asm_sload(ASMState *as, IRIns *ir)
       emit_i8(as, irt_toitype(t));
       emit_rr(as, XO_ARITHi8, XOg_CMP, tmp);
       emit_shifti(as, XOg_SAR|REX_64, tmp, 47);
-      emit_rmro(as, XO_MOV, tmp|REX_64, base, ofs+4);
+      emit_rmro(as, XO_MOV, tmp|REX_64, base, ofs);
 #else
     } else {
       emit_i8(as, irt_toitype(t));