This is an archive of the discontinued LLVM Phabricator instance.

[WebAssemblly] Fix rethrow's argument computation
AbandonedPublic

Authored by aheejin on Feb 11 2021, 11:39 AM.

Details

Reviewers
dschuff
tlively
Summary

Previously we assumed rethrow's argument was always 0, but it turned
out rethrow follows the same rule with br or delegate:
https://github.com/WebAssembly/exception-handling/pull/137
https://github.com/WebAssembly/exception-handling/issues/146#issuecomment-777349038

Currently rethrows generated by our backend always rethrow the
exception caught by the innermost enclosing catch, so this adds a
function to compute that and replaces rethrow's argument with its
computed result.

Diff Detail

Event Timeline

aheejin created this revision.Feb 11 2021, 11:39 AM
aheejin requested review of this revision.Feb 11 2021, 11:39 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 11 2021, 11:39 AM
dschuff accepted this revision.Feb 11 2021, 12:05 PM
This revision is now accepted and ready to land.Feb 11 2021, 12:05 PM
aheejin closed this revision.Feb 12 2021, 4:21 AM

Sorry, this had a bug and I had to change the code significantly. To prevent confusion I'll close this and open a new one.

aheejin reopened this revision.Feb 12 2021, 4:22 AM
This revision is now accepted and ready to land.Feb 12 2021, 4:22 AM
aheejin abandoned this revision.Feb 12 2021, 4:22 AM