wasm-micro-runtime/samples/wasi-threads
liang.he 8f8c5605e9
Raise wasi-sdk to 25 and wabt to 1.0.37 (#4187)
Raise wasi-sdk to 25 and wabt to 1.0.37. It includes
  - Refactor CI workflow to install WASI-SDK and WABT from a composite action
  - Use ExternalProject to bring wasm-apps for few samples. file/ wasi-threads/
  - Refactor sample build and test steps in SGX compilation workflow for improved clarity and efficiency (workaround)

Add CMake support for EMSCRIPTEN and WAMRC, update module paths
2025-04-17 16:41:47 +08:00
..
wasm-apps Raise wasi-sdk to 25 and wabt to 1.0.37 (#4187) 2025-04-17 16:41:47 +08:00
CMakeLists.txt Raise wasi-sdk to 25 and wabt to 1.0.37 (#4187) 2025-04-17 16:41:47 +08:00
README.md Update wasi-libc version in CI and implement custom sync primitives (#2028) 2023-03-26 09:03:26 +08:00

"WASI threads" sample introduction

To run the sample, wasi-sdk >= 20 is required.

Build and run the samples

$ mkdir build
$ cd build
$ cmake ..
$ make
...
$ ./iwasm wasm-apps/no_pthread.wasm

Run samples in AOT mode

$ ../../../wamr-compiler/build/wamrc \
    --enable-multi-thread \
    -o wasm-apps/no_pthread.aot wasm-apps/no_pthread.wasm
$ ./iwasm wasm-apps/no_pthread.aot