Tarantool development patches archive
 help / color / mirror / Atom feed
* [Tarantool-patches] [PATCH luajit] test: off JIT for routines in <lang/stackov.lua>
@ 2024-09-05 10:14 Sergey Kaplun via Tarantool-patches
  2024-09-05 10:29 ` Maxim Kokryashkin via Tarantool-patches
  2024-09-05 11:02 ` Sergey Bronnikov via Tarantool-patches
  0 siblings, 2 replies; 3+ messages in thread
From: Sergey Kaplun via Tarantool-patches @ 2024-09-05 10:14 UTC (permalink / raw)
  To: Maxim Kokryashkin, Sergey Bronnikov; +Cc: tarantool-patches

This patch is a follow-up to the commit
6a3a97cd8111a2164143fcf81439f70588e0be42 ("test: enable
<misc/stackovc.lua> LuaJIT test"). The enabled test may raise an error
for the specific builds (see [1], for example) when the stack overflow
error is raised on the trace exit during the restoration from the
snapshot. In that case, LuaJIT VM can't restore the full traceback, and
the corresponding check in the test is failed.

This patch disables JIT for these functions with recursive calls to
avoid such failures.

[1]: https://github.com/tarantool/luajit/actions/runs/10717386746

Follows up #9398
---

Branch: https://github.com/tarantool/luajit/tree/skaplun/follow-up-fix-gh-9398-p2

 test/LuaJIT-tests/lang/stackov.lua | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/test/LuaJIT-tests/lang/stackov.lua b/test/LuaJIT-tests/lang/stackov.lua
index 21ae40b6..8afa86b4 100644
--- a/test/LuaJIT-tests/lang/stackov.lua
+++ b/test/LuaJIT-tests/lang/stackov.lua
@@ -1,18 +1,22 @@
 local function f()
   f()
 end
+jit.off(f)
 
 local function g(i)
   g(i)
 end
+jit.off(g)
 
 local function vtail(...)
   return vtail(1, ...)
 end
+jit.off(vtail)
 
 local function vcall(...)
   vcall(1, ...)
 end
+jit.off(vcall)
 
 local function test_error_msg(func, s)
   local first = string.match(s, "[^\n]+")
-- 
2.46.0


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Tarantool-patches] [PATCH luajit] test: off JIT for routines in <lang/stackov.lua>
  2024-09-05 10:14 [Tarantool-patches] [PATCH luajit] test: off JIT for routines in <lang/stackov.lua> Sergey Kaplun via Tarantool-patches
@ 2024-09-05 10:29 ` Maxim Kokryashkin via Tarantool-patches
  2024-09-05 11:02 ` Sergey Bronnikov via Tarantool-patches
  1 sibling, 0 replies; 3+ messages in thread
From: Maxim Kokryashkin via Tarantool-patches @ 2024-09-05 10:29 UTC (permalink / raw)
  To: Sergey Kaplun; +Cc: tarantool-patches

Hi, Sergey!
Thanks for the patch!
LGTM

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Tarantool-patches] [PATCH luajit] test: off JIT for routines in <lang/stackov.lua>
  2024-09-05 10:14 [Tarantool-patches] [PATCH luajit] test: off JIT for routines in <lang/stackov.lua> Sergey Kaplun via Tarantool-patches
  2024-09-05 10:29 ` Maxim Kokryashkin via Tarantool-patches
@ 2024-09-05 11:02 ` Sergey Bronnikov via Tarantool-patches
  1 sibling, 0 replies; 3+ messages in thread
From: Sergey Bronnikov via Tarantool-patches @ 2024-09-05 11:02 UTC (permalink / raw)
  To: Sergey Kaplun, Maxim Kokryashkin; +Cc: tarantool-patches

[-- Attachment #1: Type: text/plain, Size: 722 bytes --]

Hi, Sergey!

On 05.09.2024 13:14, Sergey Kaplun wrote:
> This patch is a follow-up to the commit
> 6a3a97cd8111a2164143fcf81439f70588e0be42 ("test: enable
> <misc/stackovc.lua> LuaJIT test"). The enabled test may raise an error
> for the specific builds (see [1], for example) when the stack overflow
> error is raised on the trace exit during the restoration from the
> snapshot. In that case, LuaJIT VM can't restore the full traceback, and
> the corresponding check in the test is failed.
>
> This patch disables JIT for these functions with recursive calls to
> avoid such failures.
>
> [1]:https://github.com/tarantool/luajit/actions/runs/10717386746
>
> Follows up #9398
> ---

Thanks for the patch! LGTM

<snipped>

[-- Attachment #2: Type: text/html, Size: 1289 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-09-05 11:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-09-05 10:14 [Tarantool-patches] [PATCH luajit] test: off JIT for routines in <lang/stackov.lua> Sergey Kaplun via Tarantool-patches
2024-09-05 10:29 ` Maxim Kokryashkin via Tarantool-patches
2024-09-05 11:02 ` Sergey Bronnikov via Tarantool-patches

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox