[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua 5.4 tests?
- From: Andrew Gierth <andrew@...>
- Date: Sat, 01 Jun 2019 08:26:19 +0100
>>>>> "Tony" == Tony Papadimitriou <tonyp@acm.org> writes:
Tony> Assuming the cstack.lua tests are valid also for 5.3.5, my guess
Tony> from the above results is that it's not my system or compiler
Tony> configurations but something in 5.4 is causing this dramatic
Tony> reduction in maximum recursion. But, that's for you to decide.
Function calls from Lua code to lua functions in 5.3 don't consume the C
stack at all, i.e. they are handled by saving state information and
continuing within the same interpreter loop, whereas in 5.4, the
interpreter recursively invokes itself for every function call. This is
a problem because the stack usage for the interpreter is surprisingly
large, I believe thanks to the number of temporary values introduced by
inlining of function calls.
--
Andrew.