If your add-on uses LuaJIT (e.g. via SASL, Gizmo, FlyLua, or directly) then this tool may help. It’s a special build of X-Plane 10.21 for 64-bit Mac that can show total Lua memory use. Use DataRefEditor and filter on “lua” to see the numbers.
Since Lua uses garbage collection, you’ll see the number rise up and then “fall” periodically as garbage gets cleaned up. Non-Lua allocations by plugins are not counted.
If you use LuaJIT in your add-on (or a plugin that uses LuaJIT), please try to keep the amount of Lua memory used below 300 MB or so – more is available, but if you use it all, your plugin won’t inter-operate with other plugins.
Interesting, and thank you.
Any plans to make this available on Windows as well or perhaps just native to X-Plane?
Hi Jack,
It’s only available on platforms where X-Plane manages LuaJIT memory. So for now it’s Mac 64-bit — eventually it will be all 64-bit OSes as we take over memory management everywhere.
cheers
ben