Skip to content
Commit Detail

Commit 4b786cf

Author
Hood Chatham <roberthoodchatham@gmail.com> 2024-03-27 12:16:37 +0100
Parents
9651cc9
Tree
c8ccac8
Python: Reduce memory usage when restoring snapshot (#1875)

Previously we paid for two copies of the snapshot memory: one copy in the wasm
linear memory itself and a second copy in `BUNDLE_MEMORY_SNAPSHOT`. This ensures
that we never have more memory than one copy of the linear memory heap by
copying the memory directly from the snapshot to the linear memory. We also
release the C++ memory when we are done with it.

Files changed