Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
28 changes: 11 additions & 17 deletions crates/test-util/src/wast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,22 +193,17 @@ fn component_test_config(test: &Path) -> TestConfig {
ret.reference_types = Some(true);
ret.multi_memory = Some(true);
ret.component_model_implements = Some(true);
ret.bulk_memory = Some(true);
ret.component_model_async = Some(true);
ret.component_model_more_async_builtins = Some(true);
ret.component_model_async_stackful = Some(true);
ret.component_model_threading = Some(true);

if test.ends_with("memory64.wast") {
ret.component_model_memory64 = Some(true);
}

if let Some(parent) = test.parent() {
if parent.ends_with("async")
|| [
"trap-in-post-return.wast",
"resources.wast",
"multiple-resources.wast",
]
.into_iter()
.any(|name| Some(name) == test.file_name().and_then(|s| s.to_str()))
{
ret.component_model_async = Some(true);
ret.component_model_async_stackful = Some(true);
ret.component_model_more_async_builtins = Some(true);
ret.component_model_threading = Some(true);
}
if parent.ends_with("wasm-tools") {
ret.memory64 = Some(true);
ret.threads = Some(true);
Expand Down Expand Up @@ -472,9 +467,8 @@ impl WastTest {
}

let unsupported = [
// Can be re-enabled once the tests/component-model submodule has been bumped to a commit that includes
// https://github.com/WebAssembly/component-model/pull/676
"test/wasm-tools/memory64.wast",
// needs to be updated after WebAssembly/component-model#680
"test/values/post-return.wast",
];
if unsupported.iter().any(|part| self.path.ends_with(part)) {
return true;
Expand Down
13 changes: 9 additions & 4 deletions crates/wasmtime/src/runtime/component/concurrent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4063,9 +4063,13 @@ impl Instance {
store.suspend(SuspendReason::Yielding {
thread: caller,
cancellable: false,
// `subtask.cancel` is not allowed to be called in a
// sync context, so we cannot skip the may-block check.
skip_may_block_check: false,
// We've already checked that for a sync version of
// this intrinsic we're allowed to block (start of
// the function here), and otherwise this is similar
// to `suspension_intrinsic` where we're doing a
// brief yield to deliver the event, so there's no
// need to check may-block again.
skip_may_block_check: true,
})?;
break;
} else if let GuestThreadState::Ready {
Expand All @@ -4079,7 +4083,8 @@ impl Instance {
store.suspend(SuspendReason::Yielding {
thread: caller,
cancellable: false,
skip_may_block_check: false,
// See the comment above for why this is `true`
skip_may_block_check: true,
})?;
break;
}
Expand Down
2 changes: 1 addition & 1 deletion tests/component-model
Submodule component-model updated 70 files
+32 −16 README.md
+7 −2 design/high-level/Goals.md
+81 −78 design/mvp/Binary.md
+101 −88 design/mvp/CanonicalABI.md
+26 −26 design/mvp/Concurrency.md
+566 −541 design/mvp/Explainer.md
+7 −10 design/mvp/Linking.md
+80 −31 design/mvp/WIT.md
+44 −38 design/mvp/canonical-abi/definitions.py
+4 −2 design/mvp/canonical-abi/run_tests.py
+3 −0 design/mvp/examples/LinkTimeVirtualization.md
+8 −5 design/mvp/examples/SharedEverythingDynamicLinking.md
+9 −5 test/README.md
+6 −6 test/async/async-calls-sync.wast
+1,660 −0 test/async/big-interleaving-test.wast
+39 −0 test/async/builtin-trap-poisons-instance.wast
+2 −2 test/async/cancel-stream.wast
+7 −7 test/async/cancel-subtask.wast
+14 −14 test/async/cancellable.wast
+3 −3 test/async/closed-stream.wast
+19 −19 test/async/cross-abi-calls.wast
+103 −0 test/async/cross-task-future.wast
+3 −3 test/async/deadlock.wast
+2 −2 test/async/dont-block-start.wast
+5 −5 test/async/drop-cross-task-borrow.wast
+3 −3 test/async/drop-stream.wast
+4 −4 test/async/drop-subtask.wast
+3 −3 test/async/drop-waitable-set.wast
+5 −5 test/async/empty-wait.wast
+1 −1 test/async/futures-must-write.wast
+8 −8 test/async/partial-stream-copies.wast
+2 −2 test/async/passing-resources.wast
+7 −7 test/async/same-component-stream-future.wast
+11 −11 test/async/sync-barges-in.wast
+45 −15 test/async/sync-streams.wast
+12 −12 test/async/trap-if-block-and-sync.wast
+6 −6 test/async/trap-if-done.wast
+305 −0 test/async/trap-if-sync-and-waitable-set.wast
+51 −0 test/async/trap-if-transfer-in-waitable-set.wast
+5 −5 test/async/trap-on-reenter.wast
+27 −0 test/async/validate-no-async-abi-for-sync-type.wast
+7 −0 test/async/validate-no-stream-char.wast
+2 −2 test/async/wait-during-callback.wast
+4 −4 test/async/zero-length.wast
+99 −0 test/linking/link-time-virtualization.wast
+191 −0 test/linking/shared-everything-dynamic-linking.wast
+1,947 −0 test/linking/unit.wast
+3 −0 test/nyi.txt
+2 −2 test/resources/multiple-resources.wast
+31 −0 test/validation/abi.wast
+243 −0 test/validation/attributes.wast
+216 −0 test/validation/external-visibility.wast
+0 −108 test/validation/implements.wast
+249 −0 test/validation/indicies.wast
+0 −0 test/validation/kebab.wast
+230 −0 test/validation/outer-alias.wast
+576 −0 test/validation/resources.wast
+458 −0 test/values/concat.wast
+172 −37 test/values/post-return.wast
+9 −9 test/values/strings.wast
+20 −20 test/wasm-tools/adapt.wast
+2 −2 test/wasm-tools/big.wast
+6 −6 test/wasm-tools/func.wast
+2 −2 test/wasm-tools/memory64.wast
+3 −3 test/wasm-tools/resources.wast
+6 −6 test/wasm-tools/virtualize.wast
+10 −10 test/wasmtime/adapter.wast
+21 −21 test/wasmtime/fused.wast
+1 −1 test/wasmtime/resources.wast
+6 −6 test/wasmtime/strings.wast
Loading