This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v2] Fix atomic_full_barrier on x86 and x86_64.
- From: Rich Felker <dalias at libc dot org>
- To: Torvald Riegel <triegel at redhat dot com>
- Cc: GLIBC Devel <libc-alpha at sourceware dot org>, "H.J. Lu" <hjl dot tools at gmail dot com>
- Date: Tue, 23 Jun 2015 12:03:02 -0400
- Subject: Re: [PATCH v2] Fix atomic_full_barrier on x86 and x86_64.
- Authentication-results: sourceware.org; auth=none
- References: <1435066479 dot 25759 dot 79 dot camel at localhost dot localdomain>
On Tue, Jun 23, 2015 at 03:34:39PM +0200, Torvald Riegel wrote:
> This is a revision of
> https://sourceware.org/ml/libc-alpha/2014-10/msg00702.
>
> This fixes BZ #17403 by defining atomic_full_barrier,
> atomic_read_barrier, and atomic_write_barrier on x86 and x86_64. A full
> barrier is implemented through an atomic idempotent modification to the
> stack and not through using mfence because the latter can supposedly be
> somewhat slower due to having to provide stronger guarantees wrt
> self-modifying code, for example.
Small nit in the description: "idempotent" means n applications of the
operation are the same as one application. Here the intended meaning
is that the operation makes no change at all, i.e. n applications are
equivalent to 0 applications. I'm not sure what the right word is
though.
Rich