This is the mail archive of the
libc-hacker@sourceware.cygnus.com
mailing list for the glibc project.
Re: "memory" clobber in synchronization primitives
- To: Geoff Keating <geoffk@ozemail.com.au>, roland@frob.com
- Subject: Re: "memory" clobber in synchronization primitives
- From: Richard Henderson <rth@cygnus.com>
- Date: Wed, 9 Sep 1998 01:29:21 -0700
- Cc: drepper@cygnus.com, libc-hacker@gnu.org
- References: <199808311904.PAA12326@baalperazim.frob.com> <199809010424.OAA00600@geoffk.wattle.id.au>
- Reply-To: Richard Henderson <rth@cygnus.com>
On Tue, Sep 01, 1998 at 02:24:23PM +1000, Geoff Keating wrote:
> The actual compare_and_swap procedure has two
> 'sync' instructions surrounding the main code, which are 'asm
> volatile' and therefore memory barriers.
Um, asm_volatile is not a memory barrier. An asm with an
explict memory clobber is.
r~