Skip to content

Fix alignment of poll subscriptions#42

Merged
abrown merged 1 commit intoWebAssembly:mainfrom
yamt:wat-tests-alignment
Feb 28, 2023
Merged

Fix alignment of poll subscriptions#42
abrown merged 1 commit intoWebAssembly:mainfrom
yamt:wat-tests-alignment

Conversation

@yamt
Copy link
Copy Markdown
Contributor

@yamt yamt commented Feb 28, 2023

_Alignof(__wasi_subscription_t) is 8. wasmtime actually rejects misaligned addresses.

The problem pointed out by sunfishcode:
bytecodealliance/wasmtime#5891 (comment)

Fixes #39

_Alignof(__wasi_subscription_t) is 8.  wasmtime actually rejects
misaligned addresses.

The problem pointed out by sunfishcode:
bytecodealliance/wasmtime#5891 (comment)

Fixes WebAssembly#39
Copy link
Copy Markdown
Collaborator

@abrown abrown left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can confirm this does fix the issue. I now see:

$ TEST_RUNTIME_EXE="wasmtime --wasm-features=threads --wasi-modules=experimental-wasi-threads" python wasi-testsuite/test-runner/wasi_test_runner.py -r wasi-testsuite/adapters/wasmtime.py -t wasi-threads/test/testsuite/
Test wasi_threads_exit_main_block passed
Test wasi_threads_exit_main_busy passed
Test wasi_threads_exit_main_wasi passed
Test wasi_threads_exit_nonmain_block passed
Test wasi_threads_exit_nonmain_busy passed
Test wasi_threads_exit_nonmain_wasi passed
Test wasi_threads_spawn passed

===== Test results =====
Runtime: wasmtime-cli 7.0.0
Suite: WASI threads proposal
  Total: 7
  Passed:  7
  Failed:  0
  Skipped: 0

Test suites: 1 passed, 0 total
Tests:       7 passed, 0 total

@abrown abrown merged commit e1893c0 into WebAssembly:main Feb 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test: wasi_threads_exit_*main_wasi.wat fails on Wasmtime

2 participants