forked from bytecodealliance/wasm-tools
-
Notifications
You must be signed in to change notification settings - Fork 1
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
Merge with upstream #77
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…1472) * Don't generate exports named `memory` in wit-smith This fixes a fuzz bug discovered last night and this applies a similar fix for interfaces which avoids using `memory` that clashes with the canonical name for linear memory itself. * Review comments
…nce#1473) * Bail when doing wit-component::decode on a component Signed-off-by: Ryan Levick <ryan.levick@fermyon.com> * Add test for component-new-existing-component Signed-off-by: Ryan Levick <ryan.levick@fermyon.com> --------- Signed-off-by: Ryan Levick <ryan.levick@fermyon.com>
…iance#1474) * Add additional error context to ComponentEncoder::encode Signed-off-by: Ryan Levick <ryan.levick@fermyon.com> * Update tests Signed-off-by: Ryan Levick <ryan.levick@fermyon.com> --------- Signed-off-by: Ryan Levick <ryan.levick@fermyon.com>
* Refactor how spans are held in `UnresolvedPackage` Put them in a `struct` with named fields and group them together by relevance. * Disallow returns-of-borrows in WIT Currently in the component model it's not valid to have a function that returns a `borrow` resource. In WIT, however, there's no protection currently against this until a component is actually made. Bindings generators additionally might panic and/or assume that they won't need to generate bindings for borrows. This commit implements a `Resolve`-level validation that a function never returns a `borrow<T>` transitively within it. This ensures that the error for returning a borrowed resource shows up earlier in the development cycle and additionally ensures that bindings generators don't have to each specifically handle this case. Closes bytecodealliance/wit-bindgen#907 * Fix test expectation
…iance#1475) The [shared-everything-threads] proposal adds new `shared` annotations in more places, new atomic instructions, new component model thread intrinsics, etc. This change just sets the ground work by adding the shared-everything-threads flags in all the places I found to be needed; more PRs to follow. [shared-everything-threads]: https://github.com/WebAssembly/shared-everything-threads
…ecodealliance#1478) * add `--use-built-in-libdl` option to `component link` subcommand This tells `wit-component` to include a prebuilt libdl.so when linking. This library provides `dlopen`, `dlsym`, etc. using the lookup tables generated by the linker when one or more `--dl-openable` options are provided. Signed-off-by: Joel Dice <joel.dice@fermyon.com> * mark `dl` crate unpublishable Signed-off-by: Joel Dice <joel.dice@fermyon.com> * move libdl.so to hopefully make `./publish verify` happy Signed-off-by: Joel Dice <joel.dice@fermyon.com> * update link-dl-openable-builtin-libdl/component.wat Signed-off-by: Joel Dice <joel.dice@fermyon.com> * tweak error message set by `dlsym` Signed-off-by: Joel Dice <joel.dice@fermyon.com> * update libdl.so and link-dl-openable-builtin-libdl/component.wat Signed-off-by: Joel Dice <joel.dice@fermyon.com> * address review feedback - make libdl.so smaller - remove unnecessary newtype - check that libdl.so is up-to-date during CI - use CStr literal syntax - add `dl` crate to workspace Signed-off-by: Joel Dice <joel.dice@fermyon.com> * CI fix Signed-off-by: Joel Dice <joel.dice@fermyon.com> * use LTO and strip when building libdl.so This helps ensure the build is deterministic and not system-dependent. Signed-off-by: Joel Dice <joel.dice@fermyon.com> * another CI fix Signed-off-by: Joel Dice <joel.dice@fermyon.com> * exclude `dl` crate when testing on WebAssembly Signed-off-by: Joel Dice <joel.dice@fermyon.com> * remove debug logging Signed-off-by: Joel Dice <joel.dice@fermyon.com> * revert unneeded change in crates/wit-component/tests/components.rs Signed-off-by: Joel Dice <joel.dice@fermyon.com> --------- Signed-off-by: Joel Dice <joel.dice@fermyon.com>
We always resolve symbols in the global scope in AOT linking, so we can safely accept the `RTLD_GLOBAL` flag in the `dlopen` function.
This commit adds to the list of release binaries created in CI to publish a wasm32-wasi binary alongside the others. I don't expect it to be used that often but it's a neat showcase.
My earlier PR had a bug that led to an error when `--use-built-in-libdl` was specified and there were unused libraries provided by the user _and_ `--stub-missing-functions` was _not_ used. This adds a test to exercise that case and moves the `self.use_built_in_libdl = false;` statement so that it is always run prior to a recursive call to `Linker::encode`. Signed-off-by: Joel Dice <joel.dice@fermyon.com>
* threads: add `shared` globals This change allows wasm-tools to encode and decode `shared` global types as a part of the [shared-everything-threads] proposal. It includes some initial fuzzing support, though it all should be turned off by default. [shared-everything-threads]: https://github.com/WebAssembly/shared-everything-threads * review: remove wit-component TODOs * review: use enclosed parser variable * review: avoid shared-everything-threads in wasm-smith for now * review: emit new 'malformed' message * review: add imports to test * review: add 'missing-features' tests
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.