Skip to content

Conversation

amanasifkhalid
Copy link
Contributor

This assert was hit by Antigen recently. If we are doing fake hot/cold splitting, the JIT should tell the VM to reserve just one unwind info for the main function entry, regardless of whether it is split. However, we still need to reserve unwind infos for the funclets. Thus, this assert doesn't make sense.

@Copilot Copilot AI review requested due to automatic review settings June 30, 2025 16:25
@github-actions github-actions bot added the area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI label Jun 30, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR removes an overzealous debug-only assertion related to fake procedure splitting in the JIT's x86 unwind info handling. The change ensures that when fake-splitting is enabled, the JIT no longer asserts on non-root funclets, and in release builds the unwind reservation proceeds consistently.

  • Remove assert in debug mode when fake procedure splitting is enabled.
  • Add a comment clarifying that all unwind info is treated as hot during fake-splitting.
  • Adjust the control flow to conditionally call unwindReserveFuncHelper based on the fake-splitting configuration.
Comments suppressed due to low confidence (1)

src/coreclr/jit/unwindx86.cpp:123

  • Consider adding a brief comment explaining that in release builds the unwindReserveFuncHelper call always executes, while in debug builds it is skipped when fake procedure splitting is enabled. This clarification can help future maintainers understand the conditional behavior.
        INDEBUG(if (!JitConfig.JitFakeProcedureSplitting()))

Copy link
Contributor

Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch
See info in area-owners.md if you want to be subscribed.

@amanasifkhalid
Copy link
Contributor Author

@dotnet/jit-contrib PTAL, thanks!

@amanasifkhalid
Copy link
Contributor Author

ping @dotnet/jit-contrib

@amanasifkhalid amanasifkhalid merged commit 78ccbe1 into dotnet:main Jul 2, 2025
108 of 113 checks passed
@amanasifkhalid amanasifkhalid deleted the x86-fake-splitting branch July 2, 2025 14:00
@github-actions github-actions bot locked and limited conversation to collaborators Aug 2, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

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.

2 participants