Skip to content

Init inlining & panic=unwind reinitialization#964

Merged
guybedford merged 16 commits intomainfrom
init
Apr 9, 2026
Merged

Init inlining & panic=unwind reinitialization#964
guybedford merged 16 commits intomainfrom
init

Conversation

@guybedford
Copy link
Copy Markdown
Collaborator

@guybedford guybedford commented Apr 3, 2026

This is a rework of #962, that is based to wasm-bindgen/wasm-bindgen#5083 supporting multiple start functions for wasm bindgen.

With this, we are able to fully inline our init system, and then support the Rust-based panic hook for both panic=abort and panic=unwind, based on JS initState object as in #962.

Then, under panic=unwind it uses a reduced wrapper to use the native reinitalization support in wasm bindgen instead of needing to do this ourselves in the wrapper.

In the process, aborts are now fully handled for unwind, based on abort reinitialization, with the tests updated accordingly.

Non-panic abort detection for still requires further upstream work in wasm bindgen before we can support this fully for panic=abort, with the remaining commented test covering this.

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Apr 3, 2026

Merging this PR will not alter performance

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

✅ 2 untouched benchmarks


Comparing init (8f8324b) with main (bd2dfa5)

Open in CodSpeed

@guybedford guybedford merged commit e363ba6 into main Apr 9, 2026
14 checks passed
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.

1 participant