diff options
author | William Wilgus <me.theuser@yahoo.com> | 2019-07-12 05:23:52 -0500 |
---|---|---|
committer | William Wilgus <me.theuser@yahoo.com> | 2019-07-28 15:17:48 +0200 |
commit | 45bd14b392622cb58e967a24e4652c510b3d43e4 (patch) | |
tree | 22bd2e5cafc2d82ecc4773f83de7f86515b4db43 /apps/plugins/lua/luaconf.h | |
parent | 4beafe16fafc2e5c59734ef065a6f8d23766520d (diff) | |
download | rockbox-45bd14b392622cb58e967a24e4652c510b3d43e4.tar.gz rockbox-45bd14b392622cb58e967a24e4652c510b3d43e4.zip |
Lua Add Emergency Garbage Collector
Derivative of work by RobertGabrielJakabosky
http://lua-users.org/wiki/EmergencyGarbageCollector
I've only implemented the not enough memory part and
expanded this idea to adding a mechanism to signal
the OOM condition of the plugin buffer which allows us to only
grab the playback buffer after garbage collection fails
(SO THE MUSIC KEEPS PLAYING AS LONG AS POSSIBLE)
Change-Id: I684fb98b540ffc01f7ba324ab5b761ceb59b9f9b
Diffstat (limited to 'apps/plugins/lua/luaconf.h')
-rw-r--r-- | apps/plugins/lua/luaconf.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/apps/plugins/lua/luaconf.h b/apps/plugins/lua/luaconf.h index 582968d423..62a3ea0f6b 100644 --- a/apps/plugins/lua/luaconf.h +++ b/apps/plugins/lua/luaconf.h | |||
@@ -810,7 +810,13 @@ extern long rb_pow(long, long); | |||
810 | /*Rocklua functions*/ | 810 | /*Rocklua functions*/ |
811 | #include "rockconf.h" | 811 | #include "rockconf.h" |
812 | 812 | ||
813 | /* heap */ | ||
814 | #undef LUAI_GCPAUSE /*200*/ | ||
815 | #define LUAI_GCPAUSE 125 | ||
816 | #define MINSTRTABSIZE 512 /*32*/ | ||
817 | |||
813 | /*else*/ | 818 | /*else*/ |
819 | #define LUA_USER_H "lua_user.h" | ||
814 | #define LUA_DISABLE_BYTECODE | 820 | #define LUA_DISABLE_BYTECODE |
815 | 821 | ||
816 | #endif | 822 | #endif |