-
Notifications
You must be signed in to change notification settings - Fork 750
Open
Description
Hi,
I build WAMR with WAMR_BUILD_BULK_MEMORY set to 0 as I want all pages to have the default number of bytes. However, when loading the WASM module, the WASM loader shinks the memory and overwrites the number of pages to 1. Shouldn't this only happen if WAMR_BUILD_BULK_MEMORY is set to 1? My application expects the WASM module to have many default-sized memory pages.
Here's the offending snippet:
wasm-micro-runtime/core/iwasm/interpreter/wasm_loader.c
Lines 3525 to 3529 in c70e1eb
| if (shrunk_memory_size <= init_memory_size) { | |
| /* Reset memory info to decrease memory usage */ | |
| memory->num_bytes_per_page = shrunk_memory_size; | |
| memory->init_page_count = 1; | |
| LOG_VERBOSE("Shrink memory size to %d", shrunk_memory_size); |
Metadata
Metadata
Assignees
Labels
No labels