wasm-micro-runtime/core/iwasm/libraries/thread-mgr
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
..
SConscript add porting codes of rt-thread (#494) 2021-01-14 11:26:35 +08:00
thread_manager.c thread-mgr: Fix spread "wasi proc exit" exception and atomic.wait issues (#1988) 2023-02-24 20:05:39 +08:00
thread_manager.h Fix issues in the libc-wasi poll_oneoff when thread-mgr is enabled (#1980) 2023-02-23 16:11:33 +08:00
thread_mgr.cmake Enable shared memory && add pthread support (#282) 2020-06-15 19:04:04 +08:00