Commit Graph

9 Commits

Author SHA1 Message Date
YAMAMOTO Takashi
b511ad9c50 samples/native-stack-overflow/wasm-apps: comment out redundant logic 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
740a48d3d8 canary 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
ee0ff4f370 add a simple canary for temporal debugging 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
671d6cc523 samples/native-stack-overflow: comment 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
09b084281f samples/native-stack-overflow/clean.sh: rm -f 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
b7cf6d0587 samples/native-stack-overflow/wasm-apps: comment 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
230213b3ad samples/native-stack-overflow/wasm-apps: disable_tail_calls 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
e0923a8cb9 samples/native-stack-overflow/run.sh: add interpreter w/o hw bound check 2024-04-24 17:54:38 +09:00
YAMAMOTO Takashi
d6e8d224ce
Add native-stack-overflow sample (#3321)
This is a test code to examine native stack overflow detection logic.

The current output on my environment (macOS amd64):

```shell
====== Interpreter
 stack size   | fail?  | leak?  | exception
---------------------------------------------------------------------------
    0 - 14704 | failed | leaked | Exception: native stack overflow
14704 - 17904 | failed |     ok | Exception: native stack overflow
17904 - 24576 |     ok |     ok |

====== AOT
 stack size   | fail?  | leak?  | exception
---------------------------------------------------------------------------
    0 - 18176 | failed | leaked | Exception: native stack overflow
18176 - 24576 |     ok |     ok |

====== AOT WAMR_DISABLE_HW_BOUND_CHECK=1
 stack size   | fail?  | leak?  | exception
---------------------------------------------------------------------------
    0 -  1968 | failed |     ok | Exception: native stack overflow
 1968 - 24576 |     ok |     ok |
```

This is a preparation to work on relevant issues, including:

https://github.com/bytecodealliance/wasm-micro-runtime/issues/3325
https://github.com/bytecodealliance/wasm-micro-runtime/issues/3320
https://github.com/bytecodealliance/wasm-micro-runtime/issues/3314
https://github.com/bytecodealliance/wasm-micro-runtime/issues/3297
2024-04-19 15:49:09 +08:00