harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Ellison <t.p.elli...@gmail.com>
Subject Re: [classlib] Fixing an unsafe reference in InputStream
Date Fri, 13 Nov 2009 16:48:50 GMT
On 12/Nov/2009 19:20, Vijay Menon wrote:
> Right, writes - even unsynchronized ones - to the same cache line are
> problematic.  Here's a good quick read on this:
> http://en.wikipedia.org/wiki/MESI_protocol.  Recent Intel architectures
> adapt this protocol.  Here's the interesting bit:
> A write may only be performed if the cache line is in the Modified or
> Exclusive state. If it is in the Shared state, all other cached copies must
> be invalidated first. This is typically done by a broadcast operation known
> as *Read For Ownership (RFO)*.
> If two cores continually write to the same cache line, they'll repeatedly
> invalidate each other.

Thanks for the pointers.

Given that the current code has been there since time immemorial and is
not broken, I'm inclined to leave it for now and pick this thread up
again after M12.  That'll give us time to see what the difference is
between the local and static versions (though if I were a betting person
I'd say skip is used infrequently enough that nobody's app will notice).


View raw message