Description
I've been making some irresponsibly sized worlds, trying to push into the multi-million tile mark with 16px, 256 tile levels. I can get to around 22 levels in my world grid ('save levels to separate files' ON) before loading (and, later, saving) hits a memory footprint of >4 gigabytes and the screen goes blank.
This throws Error sending from webFrameMain: Error: Render frame was disposed before WebFrameMain could be accessed at s.send (node:electron/js2c/browser_init:2:86534) at _.send (node:electron/js2c/browser_init:2:72329) at BrowserWindow.<anonymous> (/tmp/.mount_ldtk.A4urIbY/resources/app.asar/assets/main.js:67:41) at BrowserWindow.emit (node:events:513:28)
in my terminal window if I try to exit.
I got my own build of LDtk going with trace-gc and --max-old-space-size=16384 in all of the various locations recommended to me around the web (export to path, run with electron in package.json, WebPreferences, to name just a few) and caught OOM error in V8: MarkCompactCollector: young object promotion failed Allocation failed - JavaScript heap out of memory
while loading my big map, which initially had me under the impression it was Electron's V8 memory cage. After trying again with both gerhardberger's v8 sandbox disabled release, as well as multiple pre-v21 releases before V8, I am still getting the blank screen crash. Albeit, without any obvious V8-related error reports, but nevertheless always shortly after hitting the 4gig allocation point.
That's taken me to the limit of my personal familiarity with the topic. Currently neither 'save levels to separate files' nor 'multi-worlds support' offer the kind of lazy loading functionality needed to only have a portion of the project in mem at a time to lower the memory overhead while saving and loading. Is there any obvious way to beat this?
CPU: AMD Threadripper 1950x
GPU: RTX 4070
RAM: 64GB
OS: Ubuntu 25.04
Version: 1.5.3