[concurrency-interest] AtomicReferenceweakCompareAndSet "Mayfailspuriously"?

Pete Soper Pete.Soper at Sun.COM
Tue May 30 17:32:29 EDT 2006

Shaffer, Darron wrote:
> So, as you turn the crank some display would say something like:
>    Read of this.field, possible values: 5, 25, 17.
> This would be a real challenge to write.  Not just making it figure out
> all the possibilities from multiple threads, but also coming up with a
> clear an usable display.  And a properly written program would make *no*
> use of the hardest part of the work!

I was absolutely muddle-headed about that spurious failure example, not 
noticing the array element assignment until I'd sent some silly blather 
to the list that confused the compare in a CAS with its read, etc, etc. 
Color me red.

I was joking about "visible VM". To accurately show what's happening I 
think extra hardware would be a must, and the UI would make a 747 
cockpit look simple or require AI or something. Hotspot or J9 and modern 
computer hardware are to the "visible V8 car engine" mentioned earlier 
on this list as the Space Shuttle is to a spring-operated mousetrap.


> -----Original Message-----
> From: concurrency-interest-bounces at cs.oswego.edu
> [mailto:concurrency-interest-bounces at cs.oswego.edu] On Behalf Of Pete
> Soper
> Sent: Sunday, May 28, 2006 9:47 PM
> To: Bill Pugh
> Cc: concurrency-interest at cs.oswego.edu; dholmes at ieee.org
> Subject: Re: [concurrency-interest] AtomicReferenceweakCompareAndSet
> "Mayfailspuriously"?
> <snip>
> I'm ready for the visible VM. Just turn the crank very, very slowly and 
> all will be revealed. So in this case the surprising/not 
> apparent/spurious/data race order is "read null, write int[], read 
> int[], write int[]{1}".
> -Pete
> _______________________________________________
> Concurrency-interest mailing list
> Concurrency-interest at altair.cs.oswego.edu
> http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest

More information about the Concurrency-interest mailing list