This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH][BZ 18743] PowerPC: Fix a race condition when eliding a lock
- From: Peter Bergner <bergner at vnet dot ibm dot com>
- To: Torvald Riegel <triegel at redhat dot com>
- Cc: Tulio Magno Quites Machado Filho <tuliom at linux dot vnet dot ibm dot com>, Adhemerval Zanella <adhemerval dot zanella at linaro dot org>, libc-alpha at sourceware dot org
- Date: Thu, 03 Sep 2015 17:07:40 -0500
- Subject: Re: [PATCH][BZ 18743] PowerPC: Fix a race condition when eliding a lock
- Authentication-results: sourceware.org; auth=none
- References: <1438274936-26493-1-git-send-email-tuliom at linux dot vnet dot ibm dot com> <55BA703D dot 7010303 at linaro dot org> <874mkl3wtq dot fsf at totoro dot lan> <1440103701 dot 5188 dot 46 dot camel at otta> <1440332176 dot 27492 dot 49 dot camel at localhost dot localdomain>
On Sun, 2015-08-23 at 14:16 +0200, Torvald Riegel wrote:
> To summarize, I think tbegin needs to have lock acquisition semantics
> and an unknown return value, and tend needs to have lock release
> semantics.
>
> Does everyone agree with this reasoning?
>
> Peter (or someone else), could you take care of documenting this
> reasoning (or whatever reasoning we agree on) in the GCC sources for the
> HTM builtins (ie, Power, s390, and Intel)? I can review such a patch,
> and can also help with the wording if necessary. Thanks!
Ok, I submitted the POWER patch to fix this along with some verbiage
about the memory consistency sematics. Torvald, is the documentation
I added in the patch below what you wanted?
https://gcc.gnu.org/ml/gcc-patches/2015-09/msg00315.html
Peter