wasmerio / wasmer

🚀 The leading Wasm Runtime supporting WASIX, WASI and Emscripten
https://wasmer.io
MIT License
18.19k stars 767 forks source link

memory profile #4871

Open newNcy opened 1 week ago

newNcy commented 1 week ago

Is there any tool that can show how much memory wasmer used during the loading of the module and the instantiation of the module, on windows I just loaded a simple demo that used more than 500 mb of memory, with the help of vs memory heap analysis I only see a few tens of mb allocated, and with the interfaces under vm/src/mmap.rs there is only 270m, I'm not sure if I can find a tool that can show how much memory was used during the loading and instantiation of the module, but I'd like to know. Where is the rest of the 250+mb memory used?

Translated with DeepL.com (free version)

syrusakbary commented 1 week ago

Possible solution: add trace logs that show the size of the compiled artifact. Suspicion: if the Wasm module is big, perhaps we are keeping it alive in memory as well as the compiled artifact and that might be adding up on memory