wasm-micro-runtime/samples/wasi-threads/wasm-apps
Wenyong Huang 38c67b3f48
thread-mgr: Fix spread "wasi proc exit" exception and atomic.wait issues (#1988)
Raising "wasi proc exit" exception, spreading it to other threads and then
clearing it in all threads may result in unexpected behavior: the sub thread
may end first, handle the "wasi proc exit" exception and clear exceptions
of other threads, including the main thread. And when main thread's
exception is cleared, it may continue to run and throw "unreachable"
exception. This also leads to some assertion failed.

Ignore exception spreading for "wasi proc exit" and don't clear exception
of other threads to resolve the issue.

And add suspend flag check after atomic wait since the atomic wait may
be notified by other thread when exception occurs.
2023-02-24 20:05:39 +08:00
..
CMakeLists.txt Rename thread_spawn import (#1907) 2023-01-27 06:45:34 +08:00
no_pthread.c Disable aux stack allocations for threads spawned by wasi_thread_start (#1867) 2023-01-09 20:36:34 +08:00
thread_termination.c thread-mgr: Fix spread "wasi proc exit" exception and atomic.wait issues (#1988) 2023-02-24 20:05:39 +08:00
wasi_thread_start.h Increase stack size in the example app (#1880) 2023-01-11 09:40:32 +08:00
wasi_thread_start.S Disable aux stack allocations for threads spawned by wasi_thread_start (#1867) 2023-01-09 20:36:34 +08:00