luajit2 icon indicating copy to clipboard operation
luajit2 copied to clipboard

[feature request] backport lua 5.4 generational GC

Open suikabreaker opened this issue 3 years ago • 5 comments

ATT.

I'm developing using OpenResty and have put heavy logic on lua(with relatively large in-memory data and lot of string manipulation, and a lot of functions), and I noticed that those permanent GC object also slows down GC.

If we can mannually specify object as permanent it may also be sufficient for my case.

suikabreaker avatar Nov 02 '21 08:11 suikabreaker

here is an example of backporting: https://github.com/dibyendumajumdar/ravi/issues/196

suikabreaker avatar Nov 02 '21 08:11 suikabreaker

and another example(for manully disable GC for specified object): https://yuerer.com/Lua-GC%E5%9E%83%E5%9C%BE%E5%9B%9E%E6%94%B6%E4%BC%98%E5%8C%96%E6%96%B9%E6%A1%88/

suikabreaker avatar Nov 03 '21 09:11 suikabreaker

I have the same problem

Summer-Time-2020 avatar Mar 28 '22 04:03 Summer-Time-2020

@suikabreaker Is your problem solved?

hankai17 avatar Sep 12 '23 09:09 hankai17

https://github.com/openresty/luajit2/issues/210

hankai17 avatar Oct 09 '23 06:10 hankai17