On May 26, 2011, at 4:53 PM, Charles Oliver Nutter wrote:
> On Thu, May 26, 2011 at 5:20 AM, Rémi Forax <fo...@univ-mlv.fr> wrote:
>> As far as I know there is no specific optimization of SwitchPoint
>> i.e there is still a volatile read in the middle of the pattern.
>
> If that's true I'm not sure how this is better than a regular GWT with
> a volatile read in the test.
It's probably about the same as GWT+volatile right now; actually there's a MCS
with a memory barrier in the present code.
But since SwitchPoint is a clear pattern it can be optimized in the future.
It's clear the user of a SwitchPoint wants cheap infrequent inter-thread
communication, and volatiles won't give that as easily as an intrinsic known to
the JVM.
-- John
_______________________________________________
mlvm-dev mailing list
mlvm-dev@openjdk.java.net
http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev