Skip to content

Conversation

@alexcrichton
Copy link
Member

This commit is a minor refactoring of the wasmtime-unwinder crate to use a Handler structure as a "package" for the pc/fp/sp triple that's required to resume to an exception handler. Freestanding functions are now associated methods/functions of Handler such as finding a frame on the stack and resuming to a handler.

This doesn't actually change any behavior, just moving some things around to prepare for a future refactoring.

This commit is a minor refactoring of the `wasmtime-unwinder` crate to
use a `Handler` structure as a "package" for the pc/fp/sp triple that's
required to resume to an exception handler. Freestanding functions are now
associated methods/functions of `Handler` such as finding a frame on the
stack and resuming to a handler.

This doesn't actually change any behavior, just moving some things
around to prepare for a future refactoring.
@alexcrichton alexcrichton requested review from a team as code owners August 30, 2025 00:38
@alexcrichton alexcrichton requested review from fitzgen and removed request for a team August 30, 2025 00:38
@github-actions github-actions bot added cranelift Issues related to the Cranelift code generator wasmtime:api Related to the API of the `wasmtime` crate itself labels Aug 30, 2025
@alexcrichton alexcrichton requested review from pchickey and removed request for a team and fitzgen September 3, 2025 17:44
@alexcrichton alexcrichton added this pull request to the merge queue Sep 3, 2025
@alexcrichton alexcrichton removed this pull request from the merge queue due to a manual request Sep 3, 2025
@alexcrichton alexcrichton added this pull request to the merge queue Sep 3, 2025
Merged via the queue into bytecodealliance:main with commit 789f037 Sep 3, 2025
44 checks passed
@alexcrichton alexcrichton deleted the unwinder-refactor branch September 3, 2025 19:28
bongjunj pushed a commit to prosyslab/wasmtime that referenced this pull request Oct 20, 2025
* Package up exception handler state

This commit is a minor refactoring of the `wasmtime-unwinder` crate to
use a `Handler` structure as a "package" for the pc/fp/sp triple that's
required to resume to an exception handler. Freestanding functions are now
associated methods/functions of `Handler` such as finding a frame on the
stack and resuming to a handler.

This doesn't actually change any behavior, just moving some things
around to prepare for a future refactoring.

* Fix some CI issues

* Fix conditional build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cranelift Issues related to the Cranelift code generator wasmtime:api Related to the API of the `wasmtime` crate itself

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants