-
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: loop inversion doing some questionable profile maintenance #84319
Comments
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch, @kunalspathak Issue DetailsFrom the Note how BB04's profile data gets trashed
|
Seems like Simple fix is to not rotate when |
The problem more generally is that profile updates to the Inversion is going duplicate the code in BB14 on left into a new block (also called BB14, on right) to handle the path that might enter the loop. That new block has weight 1.0 as it should. But the original BB14 (now BB12)'s profile is too small, it should be 1.99 and not 1.00. The backedge weight is also off. The fix I have been proposing is for I'm going to set this aside for now as I don't know of any specific perf problems this causes, though I expect there are sone. Provisional changes here: main...AndyAyersMS:runtime:FixLoopInversion |
If the loop test block has multiple predecessors we will not do proper profile updates. This can lead to downstream problems with block layout (say leaving a cold block in a loop). Fix by changing how we compute the amount of profile that should remain in the test block. Fixes dotnet#84319.
If the loop test block has multiple predecessors we will not do proper profile updates. This can lead to downstream problems with block layout (say leaving a cold block in a loop). Fix by changing how we compute the amount of profile that should remain in the test block. Fixes #84319.
From the
PerfLabTests.CastingPerf:CheckArrayIsInterfaceNo
benchmark, running with TieredPGO, during an OSR recompile:Note how BB04's profile data gets trashed
The text was updated successfully, but these errors were encountered: