This is an archive of the discontinued LLVM Phabricator instance.

[WebAssembly] Rename wasm.catch.exn intrinsic back to wasm.catch
ClosedPublic

Authored by aheejin on Aug 24 2021, 7:57 PM.

Details

Summary

The plan was to use wasm.catch.exn intrinsic to catch exceptions and
add wasm.catch.longjmp intrinsic, that returns two values (setjmp
buffer and return value), later to catch longjmps. But because we
decided not to use multivalue support at the moment, we are going to use
one intrinsic that returns a single value for both exceptions and
longjmps. And even if it's not for that, I now think the naming of
wasm.catch.exn is a little weird, because the intrinsic can still take
a tag immediate, which means it can be used for anything, not only
exceptions, as long as that returns a single value.

This partially reverts D107405.

Diff Detail

Event Timeline

aheejin created this revision.Aug 24 2021, 7:57 PM
aheejin requested review of this revision.Aug 24 2021, 7:57 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 24 2021, 7:57 PM
tlively accepted this revision.Aug 25 2021, 8:14 AM

Is there a comment thread about using multivalue or not that I can catch up on?

This revision is now accepted and ready to land.Aug 25 2021, 8:14 AM

Oh no it's more like not we but I've decided not to use it.. 😅 Sorry for not being clear. Yeah apparently the LLVM codegen for multivalue and Binaryen DWARF support are not stable, and I don't want to delay Wasm SjLj after fixing all those issues, and the workaround is simple enough, so I thought why not.

This revision was landed with ongoing or failed builds.Aug 25 2021, 2:19 PM
This revision was automatically updated to reflect the committed changes.