From: Sergey Kaplun via Tarantool-patches <tarantool-patches@dev.tarantool.org>
To: Sergey Bronnikov <sergeyb@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches] [PATCH luajit] DUALNUM: Add missing type conversion for FORI slots.
Date: Thu, 5 Mar 2026 12:57:54 +0300 [thread overview]
Message-ID: <aalTojQh2jORvJvy@root> (raw)
In-Reply-To: <07642828-4ad9-4532-a195-b24afa22963f@tarantool.org>
Hi, Sergey!
Thanks for the review.
See my answer below.
On 04.03.26, Sergey Bronnikov wrote:
> Hi, Sergey,
>
> thanks for the patch!
>
> The bug cannot be reproduced with reverted fix.
>
> CMake: cmake -S . -B build -DCMAKE_BUILD_TYPE=Debug -DLUAJIT_NUMMODE=2
You need to enable assertions as well.
> Sergey
>
> On 3/2/26 11:14, Sergey Kaplun wrote:
> > From: Mike Pall <mike>
> >
> > Reported by Sergey Kaplun.
> >
> > (cherry picked from commit 406cf69b3ae0a3ecd5ede2bb97b937b7a5d92074)
> >
> > `rec_for_loop()` narrows the FORL index values by getting them from the
> > runtime. In case when the `start`, `stop`, `step` control variables are
> > already loaded to the slots, their TRef isn't converted to the
> > corresponding type. This leads to the following inconsistent IR dump and
> > to the assertion failure later:
> > | 0002 > int SLOAD 10 TCI
> > | 0003 int ADD 0002 +1.
> > | 0004 > int LE 0003 +1.
> > | 0005 int ADD 0003 +1.
> > | 0006 > int GT 0005 +1.
> >
> > This patch adds the missing type conversion.
> >
> > Sergey Kaplun:
> > * added the description and the test for the problem
> >
> > Part of tarantool/tarantool#12134
> > ---
> >
> > Branch:https://github.com/tarantool/luajit/tree/skaplun/lj-1413-missing-conv-fori
> > Related issues:
> > *https://github.com/LuaJIT/LuaJIT/issues/1413
> > *https://github.com/tarantool/tarantool/issues/12134
> >
<snipped>
--
Best regards,
Sergey Kaplun
next prev parent reply other threads:[~2026-03-05 9:57 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-02 8:14 Sergey Kaplun via Tarantool-patches
2026-03-04 15:14 ` Sergey Bronnikov via Tarantool-patches
2026-03-05 9:57 ` Sergey Kaplun via Tarantool-patches [this message]
2026-03-05 12:09 ` Sergey Bronnikov via Tarantool-patches
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aalTojQh2jORvJvy@root \
--to=tarantool-patches@dev.tarantool.org \
--cc=sergeyb@tarantool.org \
--cc=skaplun@tarantool.org \
--subject='Re: [Tarantool-patches] [PATCH luajit] DUALNUM: Add missing type conversion for FORI slots.' \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox