]> git.ipfire.org Git - thirdparty/LuaJIT.git/commitdiff
Invalidate SCEV entry when returning to lower frame.
authorMike Pall <mike>
Thu, 9 Nov 2023 10:02:36 +0000 (11:02 +0100)
committerMike Pall <mike>
Thu, 9 Nov 2023 10:02:36 +0000 (11:02 +0100)
Thanks to Zhongwei Yao. #1115

src/lj_record.c

index a49f942aabb1649a376cec017c4ce4becceebfef..0122105bfb01f9de682b158259a8c054456a733d 100644 (file)
@@ -755,6 +755,7 @@ void lj_record_ret(jit_State *J, BCReg rbase, ptrdiff_t gotresults)
       emitir(IRTG(IR_RETF, IRT_P32), trpt, trpc);
       J->retdepth++;
       J->needsnap = 1;
+      J->scev.idx = REF_NIL;
       lua_assert(J->baseslot == 1);
       /* Shift result slots up and clear the slots of the new frame below. */
       memmove(J->base + cbase, J->base-1, sizeof(TRef)*nresults);