RangeError: WebAssembly.Memory(): could not allocate memory

I updated the three.module.js to the new release 142 and I am getting an error “RangeError: WebAssembly.Memory(): could not allocate memory”?

The error occurs when I try to cross the bridge on a chrome browser and not on other browsers.

Have you checked your actual physical memory consumption?

I’m seeing very similar errors

when trying to load/process more DEM-tiles (digital elevation model) than my physical memory can hold.

your engine probably needs to load additional data for the other side of the bridge.

I tried the older versions of threejs cannon projects it also gets the same error, Its not threejs error, it chrome bug

Is there anyway we can programmatically increase the browser’s allocated memory so we can load more 3d assets, creating threejs cannon GTA seems to be limited by the browser allocated memory, is there a way around this?

In my experience (macOS 10.15.7, Google Chrome Version 103.0.5060.53) memory does already get allocated dynamically.
The first screenshot shows the ranking of memory “consumers”, immediately following a reboot:

And this is after loading my application which tries to load more data than my physical memory (32 GB) can accomodate. Taken around the time I see the first of the error messages in the console as in my previos post:

Note, that “memory in use” plus “files in cache” pretty much amounts to the available physical memory of 32 GB. In the process list, Google Chrome accounts for ≈ 16 GB of those.

1 Like

use firefox or opera browser, chrome browser is not efficient on memory and often crashes, you can observe chrome high cpu and ram usage on the rask manager even with data processing social media websites.