-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Cleaning up write barrier code #68124
Conversation
Tagging subscribers to this area: @JulieLeeMSFT Issue DetailsI was investigating some diffs from deleting the last of
No diffs are expected.
|
{ | ||
CorInfoHelpFunc helper = genWriteBarrierHelperForWriteBarrierForm(tgt, wbf); | ||
CorInfoHelpFunc helper = genWriteBarrierHelperForWriteBarrierForm(store, wbf); | ||
|
||
#ifdef FEATURE_COUNT_GC_WRITE_BARRIERS |
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.
The new FEATURE_COUNT_GC_WRITE_BARRIERS
code is a best-effort construction based on what I thought was "reasonable", I did not test it.
1) Delete leftovers from legacy codegen, including the "tgt" naming. 2) Do not second-guess the write barrier form when selecting a helper, always return "known" WBF from "gcIsWriteBarrierCandidate" instead.
beae5fc
to
4e16737
Compare
And create GTF_IND_TGT_HEAP instead, its logical opposite. For reference, the situation before this change was as follows: // Type of the ("simplified"/"base") address: // // - TYP_I_IMPL: checked write barrier // - TYP_REF: unchecked write barrier // - TYP_BYREF: // 1) No flags: unchecked write barrier // 2) TGT_ANYWHERE: checked write barrier The TYP_BYREF case will now look like this: // // 1) No flags: checked write barrier // 2) TGT_HEAP: unchecked write barrier The main benefit is that we get the default state (no flags) to be the conservatively correct one.
4e16737
to
6af2d7a
Compare
No diffs, but there is one seemingly pre-existing related SPMI failure:
|
@dotnet/jit-contrib |
I was investigating some diffs from deleting the last of
CLS_VAR
(on ARM), and the majority had to do with how we select write barriers for stores. I found the relevant code that does that somewhat confusing, so, two changes:No diffs are expected.