Skip to content

Enhance dummy async module generation #2084

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

alexcrichton
Copy link
Member

This commit enhances the --async-callback and --async-stackful arguments to the wasm-tools component embed subcommand when paired with --dummy-names legacy. Specifically the dummy module generated now additionally includes imports for various component model intrinsics such as waitable-set management, future management, task.return, etc. The goal of this commit is to stress wit-component's processing of these intrinsics during normal fuzzing.

After the dummy module support was updated the roundtrip_wit fuzzer was run locally for awhile and a number of bugs popped out. This commit additionally includes various fixes and test cases. All tests "pass" before this commit because intrinsics weren't generated in dummy mode, but tests all fail without the wit-component fixes but with the dummy module support.

This commit enhances the `--async-callback` and `--async-stackful` arguments to
the `wasm-tools component embed` subcommand when paired with `--dummy-names
legacy`. Specifically the dummy module generated now additionally includes
imports for various component model intrinsics such as waitable-set management,
future management, `task.return`, etc.  The goal of this commit is to stress
`wit-component`'s processing of these intrinsics during normal fuzzing.

After the dummy module support was updated the `roundtrip_wit` fuzzer
was run locally for awhile and a number of bugs popped out. This commit
additionally includes various fixes and test cases. All tests "pass"
before this commit because intrinsics weren't generated in dummy mode,
but tests all fail without the `wit-component` fixes but with the dummy
module support.
@alexcrichton alexcrichton requested a review from dicej March 7, 2025 00:47
@alexcrichton
Copy link
Member Author

My plan is to make a point release after this is merged.

@alexcrichton alexcrichton added this pull request to the merge queue Mar 7, 2025
Merged via the queue into bytecodealliance:main with commit e669a6c Mar 7, 2025
31 checks passed
@alexcrichton alexcrichton deleted the fix-issues-upstream branch March 7, 2025 18:21
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.

2 participants