lua.vm.js icon indicating copy to clipboard operation
lua.vm.js copied to clipboard

Lua's garbage collector goes crazy after a few minutes

Open jice-nospam opened this issue 8 years ago • 5 comments

Hey,

I've been using this for a fantasy console project of mine for a few months. There seems to be a leak somewhere that leads to a 100% cpu usage by the lua garbage collector after a few minutes. Is this a know issue of lua.vm.js or something wrong on my side ? My lua stack is always empty after each function call and I've no idea what other check I can to do try and figure out where the problem is.

jice-nospam avatar Nov 26 '17 11:11 jice-nospam

Thanks for your interest.

I've moved on from lua.vm.js and am now only accepting bug fixes. Please consider using the successor to lua.vm.js, fengari

daurnimator avatar Nov 26 '17 12:11 daurnimator

OK I'll give fengari a try, though I'm a bit concerned about the performance impact of going from asm.js to plain javascript. I'll be able to give you some data about the switch soon. Thanks for your reply.

jice-nospam avatar Nov 26 '17 14:11 jice-nospam

I actually gained frames per second by switching to fengari! (went from 45 fps to 55 fps)! great job!

jice-nospam avatar Nov 26 '17 21:11 jice-nospam

@jice-nospam great ! Is your project viewable somewhere ? Any use of fengari is interesting to us.

giann avatar Nov 29 '17 08:11 giann

It's still in early stage. You can test it here: http://roguecentral.org/~jice/viper/

jice-nospam avatar Nov 30 '17 10:11 jice-nospam