|
Revision tags: dev, v36.0.9, v44.0.1, v43.0.2, v36.0.8, v24.0.8, v44.0.0, v43.0.1, v42.0.2, v36.0.7, v24.0.7, v43.0.0, v42.0.1, v41.0.4, v42.0.0, v40.0.4, v36.0.6, v24.0.6, v41.0.3, v41.0.2, v41.0.1, v36.0.5, v40.0.3, v41.0.0, v36.0.4, v39.0.2, v40.0.2, v40.0.1, v40.0.0, v39.0.1, v39.0.0, v38.0.4, v37.0.3, v36.0.3, v24.0.5, v38.0.3, v38.0.2, v38.0.1, v37.0.2, v37.0.1, v37.0.0, v36.0.2, v36.0.1, v36.0.0, v35.0.0, v24.0.4, v33.0.2, v34.0.2, v34.0.1, v33.0.1, v24.0.3, v32.0.1, v34.0.0, v33.0.0, v32.0.0 |
|
| #
ca7081a2 |
| 20-Mar-2025 |
Alex Crichton <[email protected]> |
Consolidate "util" crates for testing (#10423)
* Consolidate "util" crates for testing
This commit consolidates all of the existing crates we have for testing into a smaller set of crates. Specific
Consolidate "util" crates for testing (#10423)
* Consolidate "util" crates for testing
This commit consolidates all of the existing crates we have for testing into a smaller set of crates. Specifically:
* `crates/misc/component-fuzz-util` => `wasmtime-test-util` + `component-fuzz` feature * `crates/misc/component-test-util` => `wasmtime-test-util` + `component` feature * `crates/wast-util` => `wasmtime-test-util` + `wast` feature * `crates/misc/component-macro-test` => `wasmtime-test-macros`
The goal is to have one location we put various test helpers/macros rather than our current organically-grown many locations. This is inspired by the test failure on #10405 where I'd like to refactor more infrastructure to a "test util" location but it wasn't clear where to put it so I wanted to do this refactoring first.
* Remove unused file
show more ...
|
|
Revision tags: v31.0.0, v30.0.2, v30.0.1, v30.0.0, v29.0.1 |
|
| #
a6227aad |
| 21-Jan-2025 |
Taylor Hogge <[email protected]> |
Add Pulley support to wasmtime_test macro (#10057)
* wasmtime_test: Rename "Cranelift" strategy to "CraneliftNative"
* wasmtime_test: Add CraneliftPulley to default test strategies
* wasmtime_test
Add Pulley support to wasmtime_test macro (#10057)
* wasmtime_test: Rename "Cranelift" strategy to "CraneliftNative"
* wasmtime_test: Add CraneliftPulley to default test strategies
* wasmtime_test: Use one specific compilation strategy with `only` specifier.
Tests in `tests/all/fuel.rs` and `tests/all/winch_engine_features.rs` were using `#[wasmtime_test(strategies(not(Cranelift)))]` to gate their Winch specific tests. Now that there is a third compilation strategy, those tests were failing against Pulley.
I've replaced those with `#[wasmtime_test(strategies(only(Winch)))]` to be more clear that they are targeted specifically at Winch.
* wasmtime_test: Fix flaky `wrap_and_typed_i31ref` test in tests/all/func.rs
The `static HITS` variable was sharing state between tests, causing them to clobber each other when ran together.
show more ...
|
|
Revision tags: v29.0.0 |
|
| #
7f9049b9 |
| 15-Jan-2025 |
Alex Crichton <[email protected]> |
Replace `signals-based-traps` with auto-detection (#9941)
* Replace `signals-based-traps` with auto-detection
This commit refactors the platform support of the `wasmtime` crate itself to remove the
Replace `signals-based-traps` with auto-detection (#9941)
* Replace `signals-based-traps` with auto-detection
This commit refactors the platform support of the `wasmtime` crate itself to remove the previously added `signals-based-traps` feature in favor of auto-detecting whether it's there or not. The `build.rs` script for the `wasmtime` crate will now detect the target platform and auto-enable this feature as necessary.
The `signals-based-traps` cargo feature is removed and split into two custom `#[cfg]` directives that the build script sets:
* `has_virtual_memory` - this is used to gate mmap implementations for example. This is enabled on `unix || windows` and will be off for `no_std` targets for example. This is split out of "signals-based-traps" to better handle platforms like iOS which have virtual memory but don't execute native code (removing the need for native signals).
* `has_native_signals` - gates signal handlers on Unix for example. This is disabled on MIRI but otherwise enabled for `unix || windows`. This is intended to in the future get disabled for iOS by default for example since it's not necessary when using Pulley. This is additionally off-by-default for `no_std` platforms.
Two new crate features were added for `no_std` or "custom" platforms to opt-in to the `wasmtime-platform.h` C APIs for implementing virtual memory and signals. These are used in the `min-platform` embedding example.
This commit additionally updates some various documentation here and there to be more up-to-date.
* Update CI configuration
* Fix compile warnings
* Fix test on miri
* Fix more tests on miri
* Fix some warnings
* Another round of miri/CI attempts/fixes
prtest:full
show more ...
|
|
Revision tags: v28.0.1, v28.0.0 |
|
| #
70a37939 |
| 06-Dec-2024 |
Alex Crichton <[email protected]> |
Support executing Pulley in Wasmtime (#9744)
* Support executing Pulley in Wasmtime
This commit is the initial implementation of executing the Pulley interpreter from the `wasmtime` crate. This gi
Support executing Pulley in Wasmtime (#9744)
* Support executing Pulley in Wasmtime
This commit is the initial implementation of executing the Pulley interpreter from the `wasmtime` crate. This gives access to all of the `wasmtime` crate's runtime APIs backed by execution of bytecode in Pulley. This builds on the previous PRs I've been making for support in Pulley to culminate in testing on CI in this PR. This PR handles some final tidbits related to producing a runnable image that can be interpreted by the `wasmtime` crate such as:
* Pulley compilation artifacts are no longer marked as natively executable, just read-only. * Pulley compilation artifacts include wasm-to-array trampolines like normal platforms (removes a pulley special-case). * Dispatch of host calls from Pulley to the Wasmtime runtime are implemented. * Pulley's list of panicking wasm features is slimmed down as most are covered by "this lowering isn't supported" errors. * Execution of wasm code now has an `if` to see whether Pulley is enabled within a `Store` or not. * Traps and basic "unwinding" of the pulley stack are implemented (e.g. a "pulley version" of `setjmp` and `longjmp`, sort of) * Halting the interpreter has been refactored to help shrink the size of `ControlFlow<Done>` and handle metadata with each done state.
Some minor refactorings are also included here and there along with a few fixes here and there necessary to get tests passing.
The next major part of this commit is updates to our `wast` test suite and executing all `*.wast` files. Pulley is now executed by default for all files as a new execution engine. This means that all platforms in CI will start executing Pulley tests. At this time almost all tests are flagged as "expected to fail" but there are a small handful of allow-listed tests which are expected to pass. This exact list will change over time as CLIF lowerings are implemented and the interpreter is extended.
Follow-up PRs will extend the testing strategy further such as:
* Extending `#[wasmtime_test]` to include Pulley in addition to Winch. * Getting testing set up on CI for 32-bit platforms.
prtest:full
* Fix pulley fuzz build
* Fix clippy lints
* Shuffle around some `#[cfg]`'d code
* Remove unused imports
* Update feature sets testing MIRI
Enable pulley for wasmtime/wasmtime-cli and also enable all features for wasmtime-environ
* Round up pulley's page size to 64k
* Skip pulley tests on s390x for now
* Add a safety rail for matching a pulley target to the host
* Fix more pulley tests on s390x
* Review comments
* Fix fuzz build
show more ...
|
| #
4f386b73 |
| 20-Nov-2024 |
Alex Crichton <[email protected]> |
Refactor the `#[wasmtime_test]` macro (#9627)
* Refactor the `#[wasmtime_test]` macro
* Start tests with a blank slate of features instead of with the default set of features enables (ensures eac
Refactor the `#[wasmtime_test]` macro (#9627)
* Refactor the `#[wasmtime_test]` macro
* Start tests with a blank slate of features instead of with the default set of features enables (ensures each test explicitly specifies required features)
* Reuse test features from `wasmtime_wast_util` to avoid duplicating listings of features. Also shares logic for "should this compiler fail this test because of unsupported features".
* Move logic in `tests/wast.rs` to apply test configuration to a `Config` to a new location that can be shared across suites.
* Add a new feature for `simd` and flag tests that need it with the feature.
This is done in preparation for adding a new compiler strategy of Pulley to be able to flag tests as passing for pulley or not.
* Review feedback
show more ...
|
|
Revision tags: v27.0.0 |
|
| #
ba8131c6 |
| 13-Nov-2024 |
Saúl Cabrera <[email protected]> |
test-macros: Handle custom test attributes (#9602)
This commit introduces the ability to pass a custom attribute to the procedural macro via `#[wasmtime_test(with = "...")]`. This makes it possible
test-macros: Handle custom test attributes (#9602)
This commit introduces the ability to pass a custom attribute to the procedural macro via `#[wasmtime_test(with = "...")]`. This makes it possible to use the macro in situations where the caller desires to use a different test attribute such as `#[tokio::test]`.
Additionally this commit also introduces support for the test funcition asyncness, which was previously ignored.
This change is mainly motivated by adding epoch interruption support to Winch.
show more ...
|
|
Revision tags: v26.0.1, v25.0.3, v24.0.2 |
|
| #
1887ae05 |
| 22-Oct-2024 |
Saúl Cabrera <[email protected]> |
test-macros: Handle dead code warnings (#9492)
This commit handles dead code warnings produced by the compiler when the macro is invoked as:
#[wasmtime_test(strategies(not(Cranelift))]
Which o
test-macros: Handle dead code warnings (#9492)
This commit handles dead code warnings produced by the compiler when the macro is invoked as:
#[wasmtime_test(strategies(not(Cranelift))]
Which occur because Winch currently only offers support for x86_64.
The motivation behind this change comes from https://github.com/bytecodealliance/wasmtime/pull/9490, which is where the warnings surfaced.
show more ...
|
|
Revision tags: v26.0.0 |
|
| #
ba8ed6c0 |
| 14-Oct-2024 |
Saúl Cabrera <[email protected]> |
test-macros: Fix default return type (#9469)
This commit fixes the handling of default return types in `wasmtime-test-macros`. Prior to this commit, functions returning `()` inserted a `()` after th
test-macros: Fix default return type (#9469)
This commit fixes the handling of default return types in `wasmtime-test-macros`. Prior to this commit, functions returning `()` inserted a `()` after the return output, which resulted in a syntax error.
This commit fixes this issue by quoting empty tokens when the return type is the default one.
show more ...
|
|
Revision tags: v21.0.2, v22.0.1, v23.0.3, v25.0.2, v24.0.1, v25.0.1, v25.0.0, v24.0.0, v23.0.2 |
|
| #
a0442ea0 |
| 05-Aug-2024 |
Hamir Mahal <[email protected]> |
Enforce `uninlined_format_args` for the workspace (#9065)
* Enforce `uninlined_format_args` for the workspace
* fix: failing `Monolith Checks` job
* fix: formatting
|
|
Revision tags: v23.0.1, v23.0.0, v22.0.0 |
|
| #
37af9e42 |
| 13-Jun-2024 |
Saúl Cabrera <[email protected]> |
Fix a typo in the `wasmtime_test` macro (#8801)
Follow-up to: https://github.com/bytecodealliance/wasmtime/pull/8789; fixes the validation error message.
|
| #
04416e46 |
| 13-Jun-2024 |
Saúl Cabrera <[email protected]> |
Initial migration to `wasmtime_test` (#8789)
* Initial migration to `wasmtime_test`
This commit introduces the initial migration to the `wasmtime_test` macro.
This change starts by migrating all t
Initial migration to `wasmtime_test` (#8789)
* Initial migration to `wasmtime_test`
This commit introduces the initial migration to the `wasmtime_test` macro.
This change starts by migrating all the applicable `func.rs` integration tests and at the same time it removes all the duplicated integration tests in `winch.rs`.
Additionally, this change introduces a slight change to how the macro works. Inspired by https://github.com/bytecodealliance/wasmtime/pull/8622#pullrequestreview-2083046911 it defaults to including all the known configuration combinations and allows the macro user to opt-out where applicable. This makes the usage of the macro less verbose.
The intention is to follow-up with subsequent PRs to migrate the all the applicable tests.
* Remove unused `bail` import
* Add the ability to specify `wasm_features`
This commit adds the ability to specify `wasm_features` when invoking the macro.
If the feature is off by default, the macro will ensure that the feature is enabled in the resulting config.
If the feature is not supported by any of the compiler strategies, no tests will be generated for such strategy.
show more ...
|
| #
f0845e55 |
| 28-May-2024 |
Saúl Cabrera <[email protected]> |
wasmtime: Introduce the `test-macros` crate (#8622)
* wasmtime: Introduce the `test-macros` crate
This commit introduces the `test-macros` crate. The whole idea behind this crate is to export a sin
wasmtime: Introduce the `test-macros` crate (#8622)
* wasmtime: Introduce the `test-macros` crate
This commit introduces the `test-macros` crate. The whole idea behind this crate is to export a single or multiple macros to make it easier to configure Wasmtime for integration tests. The main use-case at this time, is running a subset of the integration tests with Cranelift and Winch. This crate could be extended to serve other use-cases, like testing pooling allocator and/or GC configurations.
This commit introduces a single example of how this macro could be used. If there's agreement on merging this change in some shape or form, I'll follow up with migrating the current tests to use `#[wasmtime_test]` where applicable.
Part of what's implemented in this PR was discussed in Cranelift's meeting on [April 24th, 2024](https://github.com/bytecodealliance/meetings/blob/main/cranelift/2024/cranelift-04-24.md), however there are several discussion points that are still "in the air", like for example, what's the best way to avoid the combinatorial explosion problem for the potential test matrix.
* Add crate license
* Clippy fixes
* Remove test-macros from members
* Clean up test-macros Cargo.toml
- Fix version - Add `[lints]` - Add publish key
* Add `TestConfig` and simpify parsing
This commit adds a `TestConfig` struct that holds the supported Wasmtime test configuration. Additonally this commit introduces a partial function parser, in which only the attributes, visibility, and signature are fully parsed, leaving the function body as an opaque `TokenStream`
show more ...
|