Skip to content

Commit

Permalink
Handle GT_SWIFT_ERROR_RET in LinearScan::getKillSetForNode (dotnet#10…
Browse files Browse the repository at this point in the history
…2519)

Fixes dotnet#102349. In LinearScan::getKillSetForNode, GT_SWIFT_ERROR_RET (which represents the regular return value, alongside the Swift error register value to be loaded) needs to be handled like GT_RETURN if Compiler::compIsProfilerHookNeeded is true, which is possible under some JitStress scenarios.
  • Loading branch information
amanasifkhalid authored and steveharter committed May 28, 2024
1 parent 06f159f commit 1325b90
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/coreclr/jit/lsrabuild.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1063,6 +1063,7 @@ regMaskTP LinearScan::getKillSetForNode(GenTree* tree)
// profiler callback would trash these registers. See vm\amd64\asmhelpers.asm for
// more details.
case GT_RETURN:
case GT_SWIFT_ERROR_RET:
killMask = getKillSetForReturn();
break;

Expand Down

0 comments on commit 1325b90

Please sign in to comment.