Update Wasm try-delegate semantics to match latest spec
Categories
(Core :: JavaScript: WebAssembly, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox94 | --- | fixed |
People
(Reporter: asumu, Assigned: asumu)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
Recently there has been a discussion on clarifying the behavior in the spec for the try-delegate
instruction for Wasm exception handling: https://github.com/WebAssembly/exception-handling/issues/176
There's now consensus between the proposal champion and other spec authors, so this bug is for implementing the proposed new semantics.
The currently implemented semantics is that try-delegate
can only target try
blocks and the body block of a function.
The new semantics is that try-delegate
may target any block, and the delegation will skip to the nearest enclosing try
block (this can be determined statically) or rethrow out of the function.
I already have a patch prepared to implement this that I will attach later.
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Comment 1•4 years ago
|
||
The semantics of the try-delegate Wasm exception handling instruction
was recently changed in this spec discussion:
https://github.com/WebAssembly/exception-handling/issues/176
This patch adjusts compilation and validation to match the new
semantics, which allows delegate to target any block.
Assignee | ||
Comment 2•4 years ago
|
||
There was also a suggestion to remove the current validation restriction on delegating to a catch
(https://github.com/WebAssembly/exception-handling/issues/176#issuecomment-912413970) so the attached patch might need to change to accommodate that too.
Updated•4 years ago
|
Comment 4•4 years ago
|
||
bugherder |
Description
•