You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my app design i'm compiling WASM once and have to create several instances of WASM on different events.
But i have no idea how to dispose those instances, when i don't need them.
I googled the issue and found that it uses normal garbage collector, so if instance not referenced - it is automatically destroyed.
But this seems doesn't work. The point is my WASM project uses pthreads. And when i instantiate it - i see 8 additional threads (em-pthread) in workers list.
But when i set this.wasmInstance to null - Threads aren't disposed. So i guess instance is not garbage collected.
So how can i properly destroy WASM instances then ?
The text was updated successfully, but these errors were encountered:
Hello,
In my app design i'm compiling WASM once and have to create several instances of WASM on different events.
But i have no idea how to dispose those instances, when i don't need them.
I googled the issue and found that it uses normal garbage collector, so if instance not referenced - it is automatically destroyed.
But this seems doesn't work. The point is my WASM project uses pthreads. And when i instantiate it - i see 8 additional threads (em-pthread) in workers list.
But when i set this.wasmInstance to null - Threads aren't disposed. So i guess instance is not garbage collected.
So how can i properly destroy WASM instances then ?
The text was updated successfully, but these errors were encountered: