Skip to content

chore: [fuzz] only emit call-export and call-export-catch when exception handling is enabled#8001

Closed
Changqing-JING wants to merge 2 commits into
WebAssembly:mainfrom
Changqing-JING:chore/fuzz-call-export
Closed

chore: [fuzz] only emit call-export and call-export-catch when exception handling is enabled#8001
Changqing-JING wants to merge 2 commits into
WebAssembly:mainfrom
Changqing-JING:chore/fuzz-call-export

Conversation

@Changqing-JING
Copy link
Copy Markdown
Contributor

@Changqing-JING Changqing-JING commented Oct 27, 2025

If exception is not enabled, call-export and call-export-catch are useless

@Changqing-JING Changqing-JING changed the title chore: [fuzz] only emit call-export and call-export-catch when except… chore: [fuzz] only emit call-export and call-export-catch when exception handling is enabled Oct 27, 2025
@Changqing-JING Changqing-JING marked this pull request as draft October 27, 2025 06:11
@Changqing-JING Changqing-JING marked this pull request as ready for review October 27, 2025 07:01
@kripken
Copy link
Copy Markdown
Member

kripken commented Oct 28, 2025

In what sense are they useless? The catching is on the JS side, which can catch wasm traps, which occur even without wasm exceptions being enabled.

@Changqing-JING
Copy link
Copy Markdown
Contributor Author

When a user generates mvp Wasm module, the Wasm module never throw, then nothing can be catch in JS

@kripken
Copy link
Copy Markdown
Member

kripken commented Oct 29, 2025

But even in MVP, division by zero will trap. The trap becomes a thrown exception on the JS side, which can be caught there.

@Changqing-JING
Copy link
Copy Markdown
Contributor Author

Thank you for this kindly explanation. I closed this PR

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