This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [PATCH] [Committed] Fix PR libstdc++/13480 warning in i386's atomicity.h
- From: Andrew Pinski <pinskia at physics dot uc dot edu>
- To: Jason Merrill <jason at redhat dot com>
- Cc: libstdc++ at gcc dot gnu dot org, GCC Patches <gcc-patches at gcc dot gnu dot org>, Andrew Pinski <pinskia at physics dot uc dot edu>
- Date: Wed, 24 Dec 2003 23:27:15 -0500
- Subject: Re: [PATCH] [Committed] Fix PR libstdc++/13480 warning in i386's atomicity.h
- References: <19863A98-367E-11D8-8342-000393A6D2F2@physics.uc.edu> <xyp1xqt4jd5.fsf@miranda.boston.redhat.com>
On Dec 24, 2003, at 23:22, Jason Merrill wrote:
On Wed, 24 Dec 2003 21:00:22 -0500, Andrew Pinski
<pinskia@physics.uc.edu> wrote:
It looks like Jason forgot to update the i386's atomicity.h for the
new
warning.
This fixes the warning, I committed as obvious.
Hmm, I wonder why I didn't notice that warning in my testing? Thanks.
Well I messed up the patch too.
Here is a patch which I committed to fix the problem.
Index: config/cpu/i386/atomicity.h
===================================================================
RCS file: /cvs/gcc/gcc/libstdc++-v3/config/cpu/i386/atomicity.h,v
retrieving revision 1.9
diff -u -p -r1.9 atomicity.h
--- config/cpu/i386/atomicity.h 25 Dec 2003 02:04:06 -0000 1.9
+++ config/cpu/i386/atomicity.h 25 Dec 2003 04:25:58 -0000
@@ -52,7 +52,7 @@ __exchange_and_add(volatile _Atomic_word
/* obtain the atomic exchange/add spin lock */
do {
__asm__ __volatile__ ("xchg{l} {%0,%1|%1,%0}"
- : "m" (__Atomicity_lock<0>::_S_atomicity_lock),
+ : "=m" (__Atomicity_lock<0>::_S_atomicity_lock),
"+r" (__tmp)
: "m"
(__Atomicity_lock<0>::_S_atomicity_lock));
} while (__tmp);