Skip to content

Commit

Permalink
Skip LCL_FLD stress for pinned locals
Browse files Browse the repository at this point in the history
  • Loading branch information
jakobbotsch committed Feb 5, 2025
1 parent f631371 commit 2649942
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/coreclr/jit/lclvars.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8111,6 +8111,13 @@ Compiler::fgWalkResult Compiler::lvaStressLclFldCB(GenTree** pTree, fgWalkData*
return WALK_CONTINUE;
}

// Pinned locals would not remain pinned if we did this transformation.
if (varDsc->lvPinned)
{
varDsc->lvNoLclFldStress = true;
return WALK_CONTINUE;
}

// Weed out "small" types like TYP_BYTE as we don't mark the GT_LCL_VAR
// node with the accurate small type. If we bash lvaTable[].lvType,
// then there will be no indication that it was ever a small type.
Expand Down

0 comments on commit 2649942

Please sign in to comment.