-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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: profile updates for finally optimizations #49139
JIT: profile updates for finally optimizations #49139
Conversation
Update `impImportLeave` to propagate IBC counts to new blocks. Fix profile weights during callfinally chain merging. Scale profile weights for cloned finallys. Choose the continuation path based on profile weight. Make sure to keep handler entry hot. Partial fix for dotnet#48925.
Net diff is slightly positive...
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
src/coreclr/jit/fgehopt.cpp
Outdated
BasicBlock* const firstCloneBlock = blockMap[firstBlock]; | ||
bool retargetedAllCalls = true; | ||
BasicBlock* currentBlock = firstCallFinallyRangeBlock; | ||
BasicBlock::weight_t retargetedWeight = 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
0 => BB_ZERO_WEIGHT
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup.
Another occurrence of #11063
|
Update
impImportLeave
to propagate IBC counts to new blocks.Fix profile weights during callfinally chain merging.
Scale profile weights for cloned finallys. Choose the continuation path based
on profile weight. Make sure to keep handler entry hot.
Partial fix for #48925.