Skip to content

Expose Module reference from InstanceHandle#147

Merged
sunfishcode merged 1 commit intobytecodealliance:masterfrom
yurydelendik:module-ref
May 14, 2019
Merged

Expose Module reference from InstanceHandle#147
sunfishcode merged 1 commit intobytecodealliance:masterfrom
yurydelendik:module-ref

Conversation

@yurydelendik
Copy link
Contributor

No description provided.

@sunfishcode
Copy link
Member

LGTM!

@sunfishcode sunfishcode merged commit 6740704 into bytecodealliance:master May 14, 2019
pchickey added a commit to pchickey/wasmtime that referenced this pull request May 16, 2023
…_symlink_test

Add a WASI test for creating an absolute-path symlink
mooori pushed a commit to mooori/wasmtime that referenced this pull request Dec 20, 2023
Annotate constant definitions in ZK ASM
dhil pushed a commit to dhil/wasmtime that referenced this pull request Apr 2, 2024
…alliance#147)

Currently, we inherit the following behavior from the `wasmtime_fiber`
crate:
The toplevel function executed inside a `Fiber` is a Rust closure.
However, this flexibility is not required for our use case: The function
we want to run inside a continuation is always the array call trampoline
of a wasm function.

This PR specializes our module `wasmtime_runtime::fibre` to our
particular use case, getting rid of the involved closures. Instead, all
the required data is passed around explicitly in function arguments,
instead of being implicitly stored in a closure. This has the following
advantages:
1. We do not need to allocate a `Box` holding the closure anymore.
2. The function `wasmtime_runtime::fibre::unix::fiber_start`, which is
the Rust entry point for execution inside a Fiber, is no longer
parameterized over a closure type `F`. Thus, we can call it directly
from `wasmtime_fibre_start`, instead of needing to pass it around.
3. Since the internal layout of closures is not specified by Rust, their
usage stands in the way of replacing
`wasmtime_runtime::fibre::unix::fiber_start` with generated code
eventually.

In a sense, what this PR does is some kind of manual closure conversion:
Instead of creating a closure in
`wasmtime_runtime::continuation::cont_new` and passing it to
`Fiber::new`, we pass all of the necessary environment to `Fiber::new`.
It is then stored on the Fiber stack by `wasmtime_fibre_init`, where it
is read off and passed to `fiber_start` when `resume`-ing a continuation
for the first time.
avanhatt pushed a commit to wellesley-prog-sys/wasmtime that referenced this pull request Oct 18, 2024
Use temporary log directory in filetests.

Prevents the tests from conflicting with each other.
dicej added a commit to dicej/wasmtime that referenced this pull request May 8, 2025
…oncurrent-rs-unsafe-comments

add comments to `unsafe` code in `concurrent.rs`
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