[Tarantool-patches] [PATCH luajit 1/1] x86/x64: Change ipairs_aux to match JIT backend behavior.
Sergey Kaplun
skaplun at tarantool.org
Fri Jun 5 18:47:15 MSK 2026
Hi, Sergey!
Thanks for the review!
Fixed your comment and force-pushed the branch.
On 05.06.26, Sergey Bronnikov wrote:
> Hi, Sergey,
>
> thanks for the patch! LGTM with a minor comment(s).
>
> Sergey
>
> On 6/5/26 15:49, Sergey Kaplun wrote:
> > From: Mike Pall <mike>
> >
> > Thanks to Sergey Kaplun.
> >
> > (cherry picked from commit 64b1f10835acc18bf8923adf248dce4894867882)
> >
> > In the single-number VM, `ipairs_aux()` first adds the 1 to the given
> > number and only after casts it to an integer. This leads to results
> > different from Vanilla Lua 5.1 and inconsistent with JIT engine
>
> s/Vanilla/PUC Rio/
>
> feel free to ignore
Rephrasing as you suggested. The new commit message is the following:
| x86/x64: Change ipairs_aux to match JIT backend behavior.
|
| Thanks to Sergey Kaplun.
|
| (cherry picked from commit 64b1f10835acc18bf8923adf248dce4894867882)
|
| In the single-number VM, `ipairs_aux()` first adds the 1 to the given
| number and only after casts it to an integer. This leads to results
| different from PUC Rio Lua 5.1 and inconsistent with JIT engine
| recording.
|
| This patch fixes it by casting the value to an integer before addition.
|
| Sergey Kaplun:
| * added the description and the test for the problem
|
| Part of tarantool/tarantool#12480
>
> > recording.
> >
> > This patch fixes it by casting the value to an integer before addition.
> >
> > Sergey Kaplun:
> > * added the description and the test for the problem
> >
> > Part of tarantool/tarantool#12480
> > ---
> >
> > Branch:https://github.com/tarantool/luajit/tree/skaplun/lj-1463-ipairs-aux-consistency
> > Related issues:
> > *https://github.com/LuaJIT/LuaJIT/issues/1463
> > *https://github.com/tarantool/tarantool/issues/12480
> >
<snipped>
--
Best regards,
Sergey Kaplun
More information about the Tarantool-patches
mailing list