Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
ff151fb
sgx-ra: Disable the building of samples (#2507)
JamesMenetrey Aug 28, 2023
411b903
Add mutex stress test (#2472)
Zzzabiyaka Aug 30, 2023
53d7027
Implement strict validation of thread IDs according to the specificat…
loganek Aug 31, 2023
382d52f
Stop abusing shared memory lock to protect exception (#2509)
yamt Aug 31, 2023
1ff41eb
Implement os_usleep for posix (#2517)
yamt Sep 1, 2023
8c2dc1d
Add unit tests for the tid allocator (#2519)
loganek Sep 4, 2023
2e78230
set_exception_visitor: Remove the special case for wasi proc exit (#2…
yamt Sep 4, 2023
9e39043
Revert "Return error when exception was raised after main thread fini…
yamt Sep 4, 2023
48b71a0
libc-wasi: Remove unused code (#2528)
yamt Sep 4, 2023
709127d
Add callback to handle memory.grow failures (#2522)
eloparco Sep 5, 2023
4798b69
Add ARM aeabi symbol for clearing memory content in a specific range …
loganek Sep 6, 2023
151dfae
Unifdef -U WASMTIME_SSP_STATIC_CURFDS (#2533)
yamt Sep 6, 2023
af2f3c8
Fix typo for IP address buffer (#2532)
cngzhnp Sep 7, 2023
6c846ac
Implement module instance context APIs (#2436)
yamt Sep 7, 2023
534a8cf
Handle a return from wasi _start function correctly (#2529)
yamt Sep 8, 2023
f128150
fd_object_release: Preserve errno (#2535)
yamt Sep 8, 2023
a6fda9b
Add an API to terminate instance (#2538)
yamt Sep 13, 2023
83db970
Add user to enlarge memory error callback (#2546)
eloparco Sep 13, 2023
f697244
runtest.py: Show accurate case amount in summary (#2549)
lum1n0us Sep 15, 2023
9c34fc3
Fix build with ancient GCC (4.8) (#2553)
yamt Sep 15, 2023
132378f
Allow using custom signal handler from non-main thread (#2551)
eloparco Sep 15, 2023
d436e84
Add support for running tests on apple M1 macs (#2554)
zoraaver Sep 17, 2023
444b159
Implement async termination of blocking thread (#2516)
yamt Sep 20, 2023
6fca48d
Fix inverted WASM_DISABLE_WAKEUP_BLOCKING_OP checks (#2571)
yamt Sep 21, 2023
c7a7db2
export_native_api.md: Add a note about thread termination (#2572)
yamt Sep 21, 2023
47daaee
Fix compiling error for RT-Thread (#2569)
greedyhao Sep 21, 2023
cf97ee0
test_wamr.sh: Print a bit more meaningful message (#2574)
yamt Sep 21, 2023
0677288
run_wasi_tests.sh: Provide stdin by ourselves (#2576)
yamt Sep 22, 2023
06527f7
Remove provision of unnecessary fd rights (#2579)
zoraaver Sep 22, 2023
71e07a7
Fix potential unaligned store issue when extra return value is v128 (…
TianlongLiang Sep 23, 2023
363f089
Fix a few issues in "run_wasi_tests.sh: provide stdin by ourselves" (…
yamt Sep 23, 2023
f474f3d
Return __WASI_EINVAL from fd_prestat_dir_name (#2580)
zoraaver Sep 25, 2023
99b47fd
Support AOT compiler with LLVM 17 (#2567)
fredldotme Sep 25, 2023
efb5cca
Fix compile error of tsf benchmark (#2588)
wenyongh Sep 25, 2023
94f276e
test_wamr.sh: Bump wasi-testsuite version (#2568)
yamt Sep 26, 2023
913a141
Add support for closing/renumbering preopen fds (#2578)
zoraaver Sep 26, 2023
b622622
samples/inst-context-threads: Add a brief explanation (#2592)
yamt Sep 26, 2023
6382162
Fix loader push_pop_frame_ref_offset (#2590)
wenyongh Sep 26, 2023
ade73f6
Fix compilation error on Android platform (#2594)
wenyongh Sep 26, 2023
a50a438
Ignore handling SIG_DFL/SIG_IGN for previous sig action (#2589)
wenyongh Sep 26, 2023
fff0e2a
Fix nightly run sanitizer error in Fast JIT (#2601)
wenyongh Sep 27, 2023
79b27c1
Support muti-module for AOT mode (#2482)
dongsheng28849455 Sep 28, 2023
cd0cec5
Check ValueKind before extracting a constant int value (#2595)
lum1n0us Sep 28, 2023
ac64358
doc/memory_tune.md: "remove malloc" hack is not relevant to wasi-thre…
yamt Sep 28, 2023
3c17a36
Patch implementations of vfbinop(min,max,pmin,pax) (#2584)
lum1n0us Sep 28, 2023
0053962
Improve stack trace dump and fix coding guideline CI (#2599)
eloparco Sep 29, 2023
e1ea15d
aot_resolve_stack_sizes: Disable the size check for now (#2608)
yamt Sep 29, 2023
1a88104
Remove module instance from hashmap in wasi_nn_destroy (#2613)
zhen9910 Oct 3, 2023
64baf54
Fix label index out-of-range references in op_br_table_cache (#2615)
funera1 Oct 3, 2023
28ebd57
Refactor stress tests to make them runnable in reactor mode (#2614)
Zzzabiyaka Oct 4, 2023
8987432
libc-wasi: Conditionally support SYNC flags (#2581)
zoraaver Oct 4, 2023
d8ee771
Add Cosmopolitan Libc Platform (#2598)
G4Vi Oct 4, 2023
74acfd9
Run rust tests from wasi-testsuite (#2484)
zoraaver Oct 6, 2023
1ef7c1c
spec-test-script: Fix NaN comparision between v128 values (#2605)
lum1n0us Oct 7, 2023
3668093
Enable AOT usage on M1 mac (#2618)
eloparco Oct 7, 2023
b115b7b
Fix compilation of shift opcodes on x86_64 and i386 architectures (#2…
loganek Oct 7, 2023
7c22bde
CI: Enable testing AOT multi-module feature (#2621)
wenyongh Oct 8, 2023
059fbfc
Fix potential issue in aot compiler when translating block opcodes (#…
TianlongLiang Oct 8, 2023
85869ed
Merge branch main into dev/gc_refactor
wenyongh Oct 8, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/coding_guidelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ concurrency:

jobs:
compliance_job:
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
steps:
- name: checkout
uses: actions/checkout@v3
Expand Down
58 changes: 46 additions & 12 deletions .github/workflows/compilation_on_android_ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ env:
THREADS_TEST_OPTIONS: "-s spec -b -p -P"
X86_32_TARGET_TEST_OPTIONS: "-m x86_32 -P"
WASI_TEST_OPTIONS: "-s wasi_certification -w -S"
WAMR_COMPILER_TEST_OPTIONS: "-s wamr_compiler -b -P"
GC_TEST_OPTIONS: "-s spec -G -b -P"

jobs:
Expand All @@ -73,7 +74,7 @@ jobs:
with:
os: "ubuntu-22.04"
arch: "X86"

build_wamrc:
needs:
[build_llvm_libraries_on_ubuntu_2204]
Expand Down Expand Up @@ -151,9 +152,7 @@ jobs:
exclude:
# uncompatiable feature and platform
# uncompatiable mode and feature
# MULTI_MODULE only on INTERP mode
- make_options_run_mode: $AOT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
# MULTI_MODULE only on INTERP mode and AOT mode
- make_options_run_mode: $FAST_JIT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
- make_options_run_mode: $LLVM_LAZY_JIT_BUILD_OPTIONS
Expand Down Expand Up @@ -242,6 +241,14 @@ jobs:
cmake --build . --config Release --parallel 4
working-directory: product-mini/platforms/${{ matrix.platform }}

- name: Build and run unit tests
run: |
mkdir build-unittests && cd build-unittests
cmake .. ${{ matrix.make_options_run_mode }} ${{ matrix.make_options_feature }}
cmake --build . --config Release --parallel 4
ctest
working-directory: tests/unit

build_samples_wasm_c_api:
needs:
[
Expand Down Expand Up @@ -321,7 +328,12 @@ jobs:
working-directory: samples/wasm-c-api

build_samples_others:
needs: [build_iwasm]
needs:
[
build_iwasm,
build_llvm_libraries_on_ubuntu_2204,
build_wamrc,
]
runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand All @@ -334,6 +346,9 @@ jobs:
[
"https://github.com/WebAssembly/wabt/releases/download/1.0.31/wabt-1.0.31-ubuntu.tar.gz",
]
include:
- os: ubuntu-22.04
llvm_cache_key: ${{ needs.build_llvm_libraries_on_ubuntu_2204.outputs.cache_key }}
steps:
- name: checkout
uses: actions/checkout@v3
Expand All @@ -351,7 +366,23 @@ jobs:
sudo wget ${{ matrix.wabt_release }}
sudo tar -xzf wabt-1.0.31-*.tar.gz
sudo mv wabt-1.0.31 wabt

- name: Get LLVM libraries
id: retrieve_llvm_libs
uses: actions/cache@v3
with:
path: |
./core/deps/llvm/build/bin
./core/deps/llvm/build/include
./core/deps/llvm/build/lib
./core/deps/llvm/build/libexec
./core/deps/llvm/build/share
key: ${{ matrix.llvm_cache_key }}
- name: Build wamrc
run: |
mkdir build && cd build
cmake ..
cmake --build . --config Release --parallel 4
working-directory: wamr-compiler
- name: Build Sample [basic]
run: |
cd samples/basic
Expand All @@ -378,9 +409,10 @@ jobs:
run: |
cd samples/multi-module
mkdir build && cd build
cmake ..
cmake .. -DWAMR_BUILD_AOT=1
cmake --build . --config Release --parallel 4
./multi_module
./multi_module mC.wasm
./multi_module mC.aot

- name: Build Sample [spawn-thread]
run: |
Expand Down Expand Up @@ -451,16 +483,18 @@ jobs:
- os: ubuntu-22.04
llvm_cache_key: ${{ needs.build_llvm_libraries_on_ubuntu_2204.outputs.cache_key }}
ubuntu_version: "22.04"
- os: ubuntu-22.04
llvm_cache_key: ${{ needs.build_llvm_libraries_on_ubuntu_2204.outputs.cache_key }}
running_mode: aot
test_option: $WAMR_COMPILER_TEST_OPTIONS
exclude:
# uncompatiable modes and features
# classic-interp and fast-interp don't support simd
- running_mode: "classic-interp"
test_option: $SIMD_TEST_OPTIONS
- running_mode: "fast-interp"
test_option: $SIMD_TEST_OPTIONS
# aot and jit don't support multi module
- running_mode: "aot"
test_option: $MULTI_MODULES_TEST_OPTIONS
# llvm jit doesn't support multi module
- running_mode: "jit"
test_option: $MULTI_MODULES_TEST_OPTIONS
# fast-jit doesn't support multi module, simd
Expand Down Expand Up @@ -502,7 +536,7 @@ jobs:
sudo tar -xzf wasi-sdk-*.tar.gz
sudo mv wasi-sdk-20.0 wasi-sdk

# It is a temporary solution until new wasi-sdk that includes bug fixes is released
# It is a temporary solution until new wasi-sdk that includes bug fixes is released
- name: build wasi-libc from source
if: matrix.test_option == '$WASI_TEST_OPTIONS'
run: |
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/compilation_on_macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -133,13 +133,11 @@ jobs:
exclude:
# uncompatiable feature and platform
# uncompatiable mode and feature
# MULTI_MODULE only on INTERP mode
# MULTI_MODULE only on INTERP mode and AOT mode
- make_options_run_mode: $LLVM_LAZY_JIT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
- make_options_run_mode: $LLVM_EAGER_JIT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
- make_options_run_mode: $AOT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
# SIMD only on JIT/AOT mode
- make_options_run_mode: $CLASSIC_INTERP_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_SIMD=1"
Expand Down Expand Up @@ -245,7 +243,7 @@ jobs:
working-directory: samples/wasm-c-api

build_samples_others:
needs: [build_iwasm]
needs: [build_iwasm, build_wamrc]
runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand Down Expand Up @@ -304,7 +302,7 @@ jobs:
mkdir build && cd build
cmake ..
cmake --build . --config Release --parallel 4
./multi_module
./multi_module mC.wasm

- name: Build Sample [spawn-thread]
run: |
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/compilation_on_sgx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,6 @@ jobs:
platform: [linux-sgx]
exclude:
# uncompatiable mode and feature
# MULTI_MODULE only on INTERP mode
- make_options_run_mode: $AOT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
# MINI_LOADER only on INTERP mode
- make_options_run_mode: $AOT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MINI_LOADER=1"
Expand Down
56 changes: 44 additions & 12 deletions .github/workflows/nightly_run.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@ on:
types:
- opened
- synchronize
#running nightly pipeline if you're changing it
# running nightly pipeline if you're changing it
# stress tests are run only in nightly at the moment, so running them in they are changed
paths:
- ".github/workflows/nightly_run.yml"
- "core/iwasm/libraries/lib-wasi-threads/stress-test/**"

# midnight UTC
schedule:
Expand Down Expand Up @@ -125,9 +127,7 @@ jobs:
exclude:
# uncompatiable feature and platform
# uncompatiable mode and feature
# MULTI_MODULE only on INTERP mode
- make_options_run_mode: $AOT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
# MULTI_MODULE only on INTERP mode and AOT mode
- make_options_run_mode: $FAST_JIT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
- make_options_run_mode: $LLVM_LAZY_JIT_BUILD_OPTIONS
Expand Down Expand Up @@ -250,7 +250,7 @@ jobs:
exclude:
# uncompatiable feature and platform
# uncompatiable mode and feature
# MULTI_MODULE only on INTERP mode
# MULTI_MODULE only on INTERP mode and AOT mode
- make_options_run_mode: $FAST_JIT_BUILD_OPTIONS
make_options_feature: "-DWAMR_BUILD_MULTI_MODULE=1"
# SIMD only on JIT/AOT mode
Expand Down Expand Up @@ -380,7 +380,12 @@ jobs:
working-directory: samples/wasm-c-api

build_samples_others:
needs: [build_iwasm]
needs:
[
build_iwasm,
build_llvm_libraries_on_ubuntu_2004,
build_wamrc,
]
runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand All @@ -393,6 +398,9 @@ jobs:
[
"https://github.com/WebAssembly/wabt/releases/download/1.0.31/wabt-1.0.31-ubuntu.tar.gz",
]
include:
- os: ubuntu-20.04
llvm_cache_key: ${{ needs.build_llvm_libraries_on_ubuntu_2004.outputs.cache_key }}
steps:
- name: checkout
uses: actions/checkout@v3
Expand All @@ -409,6 +417,26 @@ jobs:
sudo wget ${{ matrix.wabt_release }}
sudo tar -xzf wabt-1.0.31-*.tar.gz
sudo mv wabt-1.0.31 wabt

- name: Get LLVM libraries
id: retrieve_llvm_libs
uses: actions/cache@v3
with:
path: |
./core/deps/llvm/build/bin
./core/deps/llvm/build/include
./core/deps/llvm/build/lib
./core/deps/llvm/build/libexec
./core/deps/llvm/build/share
key: ${{ matrix.llvm_cache_key }}

- name: Build wamrc
run: |
mkdir build && cd build
cmake -D WAMR_BUILD_SANITIZER="${{matrix.sanitizer}}" ..
cmake --build . --config Release --parallel 4
working-directory: wamr-compiler

- name: Build Sample [basic]
run: |
cd samples/basic
Expand All @@ -432,9 +460,10 @@ jobs:
run: |
cd samples/multi-module
mkdir build && cd build
cmake ..
cmake .. -DWAMR_BUILD_AOT=1
cmake --build . --config Release --parallel 4
./multi_module
./multi_module mC.wasm
./multi_module mC.aot
- name: Build Sample [spawn-thread]
run: |
cd samples/spawn-thread
Expand Down Expand Up @@ -522,9 +551,7 @@ jobs:
test_option: $SIMD_TEST_OPTIONS
- running_mode: "fast-interp"
test_option: $SIMD_TEST_OPTIONS
# aot and jit don't support multi module
- running_mode: "aot"
test_option: $MULTI_MODULES_TEST_OPTIONS
# llvm jit doesn't support multi module
- running_mode: "jit"
test_option: $MULTI_MODULES_TEST_OPTIONS
# fast-jit doesn't support multi module, simd
Expand Down Expand Up @@ -599,6 +626,11 @@ jobs:
run: bash build.sh --sysroot "$SYSROOT_PATH"
working-directory: ./core/iwasm/libraries/lib-wasi-threads/test/

- name: Build WASI thread stress tests
if: matrix.test_option == '$WASI_TEST_OPTIONS'
run: bash build.sh --sysroot "$SYSROOT_PATH"
working-directory: ./core/iwasm/libraries/lib-wasi-threads/stress-test/

- name: build socket api tests
if: matrix.test_option == '$WASI_TEST_OPTIONS'
run: bash build.sh
Expand All @@ -624,4 +656,4 @@ jobs:
timeout-minutes: 40
if: env.TEST_ON_X86_32 == 'true'
run: ./test_wamr.sh ${{ env.X86_32_TARGET_TEST_OPTIONS }} ${{ matrix.test_option }} -t ${{ matrix.running_mode }}
working-directory: ./tests/wamr-test-suites
working-directory: ./tests/wamr-test-suites
11 changes: 11 additions & 0 deletions build-scripts/config_common.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,13 @@ else ()
add_definitions (-DWASM_DISABLE_STACK_HW_BOUND_CHECK=0)
endif ()
endif ()
if (WAMR_DISABLE_WAKEUP_BLOCKING_OP EQUAL 1)
add_definitions (-DWASM_DISABLE_WAKEUP_BLOCKING_OP=1)
message (" Wakeup of blocking operations disabled")
else ()
add_definitions (-DWASM_DISABLE_WAKEUP_BLOCKING_OP=0)
message (" Wakeup of blocking operations enabled")
endif ()
if (WAMR_BUILD_SIMD EQUAL 1)
if (NOT WAMR_BUILD_TARGET MATCHES "RISCV64.*")
add_definitions (-DWASM_ENABLE_SIMD=1)
Expand Down Expand Up @@ -388,6 +395,10 @@ if (WAMR_BUILD_WASM_CACHE EQUAL 1)
add_definitions (-DWASM_ENABLE_WASM_CACHE=1)
message (" Wasm files cache enabled")
endif ()
if (WAMR_BUILD_MODULE_INST_CONTEXT EQUAL 1)
add_definitions (-DWASM_ENABLE_MODULE_INST_CONTEXT=1)
message (" Module instance context enabled")
endif ()
if (WAMR_BUILD_GC_HEAP_VERIFY EQUAL 1)
add_definitions (-DWASM_ENABLE_GC_VERIFY=1)
message (" GC heap verification enabled")
Expand Down
2 changes: 2 additions & 0 deletions build-scripts/runtime_lib.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,10 @@ endif ()

if (WAMR_BUILD_LIBC_UVWASI EQUAL 1)
include (${IWASM_DIR}/libraries/libc-uvwasi/libc_uvwasi.cmake)
set (WAMR_BUILD_MODULE_INST_CONTEXT 1)
elseif (WAMR_BUILD_LIBC_WASI EQUAL 1)
include (${IWASM_DIR}/libraries/libc-wasi/libc_wasi.cmake)
set (WAMR_BUILD_MODULE_INST_CONTEXT 1)
endif ()

if (WAMR_BUILD_LIB_PTHREAD_SEMAPHORE EQUAL 1)
Expand Down
5 changes: 5 additions & 0 deletions core/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -504,4 +504,9 @@
#define WASM_MEM_DUAL_BUS_MIRROR 0
#endif

/* The max number of module instance contexts. */
#ifndef WASM_MAX_INSTANCE_CONTEXTS
#define WASM_MAX_INSTANCE_CONTEXTS 8
#endif

#endif /* end of _CONFIG_H_ */
Loading