[Tarantool-patches] [PATCH luajit 0/2] Fix canonicalization of +-0.0 keys for IR_NEWREF.

Igor Munkin imun at tarantool.org
Tue Jul 4 20:10:24 MSK 2023


Sergey,

I've checked the patchset into all long-term branches in
tarantool/luajit and bumped a new version in master, release/2.11 and
release/2.10.

On 10.05.23, Sergey Kaplun via Tarantool-patches wrote:
> The backported commit needs to be checked precisely -- we don't want to
> just check that the assertion failures are gone -- some commits [1] may
> replace the aforementioned assertions with `return 0` or something else
> [2] due to other issues. Hence, we need to be sure that there is no such
> IR as "NEWREF.*-0" for these traces anymore. So the first commit
> introduces new utility module for tests to parse traces dumped into the
> file. There is nothing too fancy -- for now, the returned traces may
> only say is there some particular IR or no. Any other features may be
> added in the future uses, if we need.
> 
> Q: Can we use `jit.dump()` as is, without temporary file?
> A: Yes, but no:
>    `jit.dump()` may be easily patched to use a custom object as the
>    second argument, not only file name. But this module dumps trace
>    information not by lines but more iterative. So we can use the
>    similar approach as in <luajit-gdb.py> -- concat each line and only
>    then dump it. But I don't ready to discuss this opportunity with Mike
>    now:). So, for now just use a temporary file and remove it after
>    usage.
> 
> Branch: https://github.com/tarantool/luajit/tree/skaplun/lj-noticket-folding-0
> Taranrool PR: https://github.com/tarantool/tarantool/pull/8634
> Related issues:
> * https://github.com/tarantool/tarantool/issues/8516
> * https://github.com/LuaJIT/LuaJIT/issues/981
> 
> [1]: https://github.com/LuaJIT/LuaJIT/commit/d4c0c6e17ef7edf1f2893bc807746b80612e63e9
> [2]: https://github.com/LuaJIT/LuaJIT/issues/994
> 
> Mike Pall (1):
>   Fix canonicalization of +-0.0 keys for IR_NEWREF.
> 
> Sergey Kaplun (1):
>   test: add utility for parsing `jit.dump`
> 
>  src/lj_record.c                               |   2 +
>  .../tarantool-tests/lj-981-folding-0.test.lua |  57 +++++++
>  test/tarantool-tests/utils/jit_parse.lua      | 156 ++++++++++++++++++
>  3 files changed, 215 insertions(+)
>  create mode 100644 test/tarantool-tests/lj-981-folding-0.test.lua
>  create mode 100644 test/tarantool-tests/utils/jit_parse.lua
> 
> -- 
> 2.34.1
> 

-- 
Best regards,
IM


More information about the Tarantool-patches mailing list