Describe the bug
The attached PoC results in wasm auxiliary stack underflow error for all modes of WAMR runtime. When __heap_base value becomes less than 5264, the exception no longer occurs.
Version
iwasm 2.4.3
Commit: 4b306f0
To Reproduce
Steps to reproduce the behavior:
- Convert the following PoC to wasm:
(module
(global $__stack_pointer (;0;) (mut i32) i32.const 1)
(global (;1;) i32 i32.const 5264)
(global (;2;) i32 i32.const 1)
(export "__heap_base" (global 1))
(export "__data_end" (global 2))
(export "main" (func $main))
(func $main
global.get $__stack_pointer
i32.const 1
i32.add
global.set $__stack_pointer
return
)
)
- Run the following:
iwasm -f main poc.wasm
Expected behavior
Should exit with no exception based on other runtimes.
Actual Result
wasm auxiliary stack underflow
Desktop (please complete the following information):
- Arch [x86_64]
- OS [Linux]
- Version [22.04]
Describe the bug
The attached PoC results in
wasm auxiliary stack underflowerror for all modes of WAMR runtime. When__heap_basevalue becomes less than 5264, the exception no longer occurs.Version
iwasm 2.4.3
Commit: 4b306f0
To Reproduce
Steps to reproduce the behavior:
iwasm -f main poc.wasmExpected behavior
Should exit with no exception based on other runtimes.
Actual Result
wasm auxiliary stack underflowDesktop (please complete the following information):