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

JIT: handle nested try case in empty try removal #111129

Merged
merged 2 commits into from
Jan 7, 2025

Conversation

AndyAyersMS
Copy link
Member

When we remove a try region, the try entry block may still be a try entry for enclosing try regions, so we can't unconditionally drop the DONT_REMOVE flag.

Fixes #110958

When we remove a try region, the try entry block may still be a try entry
for enclosing try regions, so we can't unconditionally drop the DONT_REMOVE flag.

Fixes dotnet#110958
@dotnet-issue-labeler dotnet-issue-labeler bot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Jan 6, 2025
@AndyAyersMS
Copy link
Member Author

@amanasifkhalid PTAL
cc @dotnet/jit-contrib

Copy link
Member

@amanasifkhalid amanasifkhalid left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

src/coreclr/jit/fgehopt.cpp Outdated Show resolved Hide resolved
@BruceForstall
Copy link
Member

fwiw, #82336

@AndyAyersMS
Copy link
Member Author

AndyAyersMS commented Jan 7, 2025

fwiw, #82336

What I was hoping to get to someday was to have all block references be enumerable from the block -- most would be from flow edges like with our current pred lists, but we'd have some special references from the EH table, statics on the compiler object (eg fgFirstBB), and similar.

@AndyAyersMS AndyAyersMS merged commit c5df73f into dotnet:main Jan 7, 2025
114 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Assertion failed 'HBtab->ebdTryBeg->HasFlag(BBF_DONT_REMOVE)' during 'Remove empty try-catch-fault 2/3
3 participants