RFR: 8079315: UseCondCardMark broken in conjunction with CMS precleaning

Andrew Haley aph at redhat.com
Tue May 5 16:20:57 UTC 2015

On 05/05/2015 04:36 PM, Vitaly Davidovich wrote:
>> But I'm at a loss to understand how that helps with the problem of
>> reading an old value for the card mark.  There still has to be some
>> sort of happens-before relationship between something and the read of
>> the card mark.  What good would a store-store do here?
> My understanding was that the card can be in 1 of 3 states: clean,
> dirty, precleaned.  Right now if mutator's read of the card floats
> above the store and it sees "dirty" (e.g. it read "precleaned"), it
> will not mark the card as dirty and the write is lost.  I think
> Mikael's idea was that by changing the mutator to check for "!=
> clean", it will automatically cover either "dirty" or "precleaned",
> and the 3rd state ("clean") can't happen since CMS preclean thread
> does not set it to such.  So although you're right in the general
> sense of there needing to be a happens-before relationship, I think
> this is a targeted suggestion given the protocol involved.  Or, of
> course, I misunderstood Mikael's rationale/suggestion.

Well, yeah, alright.  I'd be happy to submit a patch which does that
if I had any idea that it was correct.  Mikael's language about a
"partial solution" worries me.


More information about the hotspot-dev mailing list