-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[23.0.0] A few more backports (#8922)
* Add custom-pages-sizes to CLI flags (#8917) * Update dependency on `wit-bindgen` (#8911) * Update dependency on `wit-bindgen` Updating to the latest released version. * Add vets * Fix build of test-programs * Fix panic with invalid DWARF file indices (#8913) I'm not entirely sure what causes this but Wasmtime shouldn't panic with invalid DWARF. In general (#5537) Wasmtime's support for DWARF needs to be rewritten, but in the meantime let's play whack-a-mole with panics and try to paper over issues. Closes #8884 Closes #8904 * Wasmtime: Pop GC LIFO roots even when there is no GC heap (#8899) * Wasmtime: Pop GC LIFO roots even when there is no GC heap We can create and root `i31ref`s without ever allocating a GC heap for the store, so we can't guard popping LIFO roots on the presence of a GC heap or else we risk unbounded growth of the LIFO root set. * Fix build with the gc feature disabled --------- Co-authored-by: Nick Fitzgerald <fitzgen@gmail.com>
- Loading branch information
1 parent
d5e2170
commit 72fe1de
Showing
13 changed files
with
155 additions
and
134 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
wit_bindgen::generate!({ | ||
world: "test-reactor", | ||
path: "../wasi/wit", | ||
generate_all, | ||
}); | ||
|
||
struct T; | ||
|
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
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
use wasmtime::*; | ||
|
||
#[test] | ||
fn always_pop_i31ref_lifo_roots() -> Result<()> { | ||
let mut config = Config::new(); | ||
config.wasm_function_references(true); | ||
config.wasm_gc(true); | ||
|
||
let engine = Engine::new(&config)?; | ||
let mut store = Store::new(&engine, ()); | ||
|
||
let anyref = { | ||
let mut scope = RootScope::new(&mut store); | ||
AnyRef::from_i31(&mut scope, I31::wrapping_u32(42)) | ||
}; | ||
|
||
// The anyref has left its rooting scope and been unrooted. | ||
assert!(anyref.is_i31(&store).is_err()); | ||
|
||
Ok(()) | ||
} |
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