-
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
Deleting field sequences from LCL_FLD
and VNF_PtrToArrElem
#68986
Deleting field sequences from LCL_FLD
and VNF_PtrToArrElem
#68986
Conversation
Tagging subscribers to this area: @JulieLeeMSFT Issue DetailsThe first round of deleting field sequences:
Also includes clean up of We're expecting a good amount of positive diffs, mainly from the deletion of Depends on #68979.
|
LCL_FLD
and VNF_PtrToArrElem
5a08623
to
9cd3379
Compare
@dotnet/jit-contrib I would like to request a run of stress and libraries stress for this change. |
/azp run runtime-coreclr jitstress, runtime-coreclr libraries-jitstress |
Azure Pipelines successfully started running 2 pipeline(s). |
dfccd94
to
05ac8d1
Compare
615799d
to
9c81107
Compare
@jakobbotsch could you please re-trigger the stress pipelines? |
/azp run runtime-coreclr jitstress, runtime-coreclr libraries-jitstress |
Azure Pipelines successfully started running 2 pipeline(s). |
That was quite a bit of red CI to interpret... The runtime pipeline:
Stress:
Libraries stress:
|
In theory it should be loadable with x86 windbg, but I have not had much success. I can try looking at the dump on my rpi some time this week. |
Unfortunate I ran into problems while analyzing the dump, I left a comment at |
/azp run runtime-coreclr libraries-jitstress |
9c81107
to
7a251eb
Compare
@jakobbotsch I think this is ready for another stress run. |
/azp run runtime-coreclr jitstress, runtime-coreclr libraries-jitstress |
Azure Pipelines successfully started running 2 pipeline(s). |
The System.Memory.Tests failures are out (as expected).
Edit: regular CI hit the same crash inside S.T.J.Tests on Linux ARM. Edit: two more failures on Linux_musl ARM. This is a bit surprising, the CI was green for this change yesterday, today's force push just removed the GC hole fix (now in main) from the commit list. So it almost seems like something in the upstream commit chain made the failures more apparent. Edit: and said failures (or at least one of them) do appear to exist in the upstream too, e. g. the stack we see for
Edit: more similar-looking AVs in another stress run. Edit: on progress status - I have managed to set up things such that I can look into the ARM dumps with x86 WinDbg, next step is to download (1GB worth of) the S.T.J. minidump from the latest stress run, as the core dumps from regular CI do not appear to have enough managed information. |
7a251eb
to
a4efcfd
Compare
@SingleAccretion I think given your investigations above that you don't need to block this PR on those GC holes. Are there any other known problems with this PR? |
@jakobbotsch nothing that I am aware of. I will investigate the dumps over the weekend, and if nothing comes up, will mark this as ready for review. Edit, progress status: in all apparency the 1GB S.T.J. dump was too much for the x86 address space to handle (with WinDbg crashing). Perhaps I will be able to get something smaller from Sunday's libraries stress run... Edit: we have a Linux ARM64 crash, but the dump was too big to upload... Edit: will presume the GC holes above are #69657. |
Move the responsibility of determining "entireness" to its only caller that needed to do that: "DefinesLocal". Add function headers. No diffs.
No diffs.
Also address the TODO-CQ.
Exposed by the more aggressive hoisting.
a4efcfd
to
9de70e9
Compare
This is finally ready for review. Not sure what's up with @dotnet/jit-contrib, @jakobbotsch |
{ | ||
|
||
haveCorrectFieldForVN = | ||
compiler->info.compCompHnd->doesFieldBelongToClass(field->gtFldHnd, clsHnd); |
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.
This removes the only uses of this JIT-EE function, correct?
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.
Yep. Will open an issue tracking deleting it completely.
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.
Sounds good. @dotnet/jit-contrib we should keep in mind to delete this one together with the next JIT-EE update.
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.
Also cc @sandreenko who will be happy to hear that :-)
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.
Looks great to me, I love to see all the deletions :)
The first round of deleting field sequences:
LCL_FLD
: replace it with aClassLayout*
pointer (for now, unused). De-pessimize block morphing and block numbering, remove quirks from VN.VNF_PtrToArrElem
: not replaced by anything because it is not needed anymore.Also includes clean up of
DefinesLocalAddr
and a miscellaneous fix for the numbering of return buffer locals.The diffs are pretty nice, including the throughput ones, and come mainly from the deletion of
fgMorphCanUseLclFldForCopy
, but also from the array change. We see some regressions with CSEs and hoisting (there is one extreme case of this on x86 where 6 new SIMD CSEs trigger pathological RA behavior and we see it "spill the world", fortunately it is in a PMI-instantiated method). There are also a few cases where locals become tracked andoptRemoveRedundantZeroInits
no longer removes the explicit zero-initialization.This also saves
~0.16%
in memory consumption when CG-ing CoreLib.Closes #12142.