3 ms·
You mentioned in a sibling comment that this was using LuaJIT, do you know if it was before the allocation sinking optimization was added? At some point (2.1?)
by samatman 4y ago
You mentioned in a sibling comment that this was using LuaJIT, do you know if it was before the allocation sinking optimization was added?
At some point (2.1?) LuaJIT added a peephole interpreter optimization which can follow a simple constructed table for awhile, and if it's never stored, the values it's conveying are just put on the stack.
I'm pretty fearless with creating transient tables, and run enough profiling to be moderately confident that the allocation sink is keeping that from providing memory pressure.
There's a larger thing here about the JIT being temperamental and having to kind of learn its moods, but: it's faster as an interpreter than other choices by a matter of multiples, and when the JIT works, it positively screams.
- rahkiin 4y agoHonestly I am not sure. We were using the LuaJIT interpreter because JIT is not allowed on consoles or phones.