Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NativeAOT-LLVM] Rewrite exception handling to support nested dispatch #2374

Merged
merged 10 commits into from
Aug 25, 2023

Conversation

SingleAccretion
Copy link

@SingleAccretion SingleAccretion commented Aug 16, 2023

See the added nativeaot-wasm-exception-handling.md for an explanation of how the new EH scheme works. Feedback on what to improve in it is most welcome (e. g. some parts are not detailed enough, or unclear, or some terms are not explained, etc)!

Contributes to #2169.

Size statistics:

 All table formats:
  0x00113384
  + 0.08%
  + 924 bytes

 Excluding "small":
  0x001135b4
  + 0.13%
  + 1484 bytes

 Excluding "small" and "clause type":
  0x001138d8
  + 0.20%
  + 2288 bytes

About ~2.5x win for the more complex format as compared to the naive option.
Using funclets for now.

Also deletes the dynamic stack support (no longer needed).
And delete the unused CORINFO_HELP_LLVM_EH_CATCH_POP_UNWOUND_VIRTUAL_FRAMES.
@SingleAccretion SingleAccretion marked this pull request as ready for review August 22, 2023 01:32
@SingleAccretion
Copy link
Author

@dotnet/nativeaot-llvm

@jkotas jkotas added the area-NativeAOT-LLVM LLVM generation for Native AOT compilation (including Web Assembly) label Aug 23, 2023
Copy link
Contributor

@yowl yowl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Qudos for the extensive write up and code. I don't pretend to have gone through the logic, but I see a good set of tests so this looks great. Thanks!

src/coreclr/jit/llvmlssa.cpp Outdated Show resolved Hide resolved
Co-authored-by: yowl <[email protected]>
@jkotas
Copy link
Member

jkotas commented Aug 25, 2023

Thank you for the hard work and dedication!

@jkotas jkotas merged commit 6f57287 into dotnet:feature/NativeAOT-LLVM Aug 25, 2023
11 checks passed
@SingleAccretion SingleAccretion deleted the EH-Unwind branch August 25, 2023 06:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-NativeAOT-LLVM LLVM generation for Native AOT compilation (including Web Assembly)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants