David Symonds
unread,May 7, 2012, 7:42:02 PM5/7/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to em...@franckjeannin.com, golang-dev
The fast-path atomic.LoadUint32 requires that operations on o.done to
be made atomically, which is why doing "o.done = 1" under the lock is
not sufficient. StoreUint32 would work fine too; it's probably a CAS
for historic reasons, as Brad suggested.
Dave.