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 #130
Closed
Closed
Merge with upstream #130
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
Nothing major here, just minor updates
This is a re-application of bytecodealliance#1712 to fix the broken build from upgrading serde in a previous commit.
…bytecodealliance#1741) * Remove feature flag from post-stabilization feature gates This commit removes the optional `feature` specification from feature gates (`@since`, in particular). This change should simplify the usage of feature gates (see WebAssembly/component-model#387) for more discussion. This is a breaking change for those who were depending on `wit-parser` as `feature` now no longer present. Signed-off-by: Victor Adossi <vadossi@cosmonic.com> * Update wit-component to not use feature option in since This commit updates `wit-component` to remove reliance on the `feature` option when dealing with post-stabilization (`@since`) feature gates. Signed-off-by: Victor Adossi <vadossi@cosmonic.com> * Update tests to remove optional feature on since gates Signed-off-by: Victor Adossi <vadossi@cosmonic.com> --------- Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
) These display representations are easy to get confused with the previous return values of `u32` which do implement `Display`, but the `Display` here isn't as applicable as it used to be. As a stopgap remove the `Display` implementations entirely to help identify locations that need to be updated to explicitly use an accessor or otherwise to calculate the size/align information.
) * Support optimizing feature checks at compile time Something I've long wanted for `wasmparser` is the ability to constant-propagate decisions about feature selection instead of requiring runtime checks to do so. This should be a performance win for proposals as they become standardized and more and more of wasm is gated behind some feature or another. The goal with this is to enable a mode of `wasmparser` which doesn't require runtime checks of booleans/bits to see whether a proposal is enabled or not. In lieu of not redesigning everything too much (e.g. adding `F: WasmFeatures` everywhere) this commit adds a new compile time Cargo feature to the crate called `features` which, when disabled, makes `WasmFeatures` a zero-sized type that represent the default active features for `wasmparser`. This enables const-propagating decisions about features throughout the codebase and should help optimize the validator/decoder in niche situations. * Add required feature * Update crates/wasmparser/src/features.rs Co-authored-by: Nick Fitzgerald <fitzgen@gmail.com> --------- Co-authored-by: Nick Fitzgerald <fitzgen@gmail.com>
* threads: add validation for shared calls The shared-everything-threads [proposal] prevents `shared` contexts (e.g., in a `shared` function) from accessing unshared objects. This change adds validation to prevent `shared`-to-unshared calls. [proposal]: https://github.com/WebAssembly/shared-everything-threads * threads: refactor and add shared access checks This checks shareability of other kinds of shared objects (minus `shared` memories). * Replace `type_of_function` with `type_index_of_function` `WasmModuleResources` previously retrieved the entire `FuncType` but this obscured the sharedness of the function in question, since the shared flag is held a level up in `CompositeType`. By replacing `WasmModuleResources::type_of_function` with a more low-level `WasmModuleResources::type_index_of_function`, we can reuse the existing helper functions that retrieve a `FuncType` from a `CompositeType` and do the necessary sharedness checks. * Clean up `OperatorValidator::new_func`
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.