This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: gcc 3.2.3 config/os/bits/i386/atomicity.h broken
Loren James Rittle <rittle at latour dot rsch dot comm dot mot dot com> writes:
>> Sorry, one question: Which file exactly is meant?
>
> Sorry, if I was unclear. The patch in question was in the thread (you
> found it more-or-less, I recently CC'd on a "final" version). It was
> not the old 3.2.X-version of config/os/bits/i386/atomicity.h but
> rather this new one that correctly uses instructions actually
> available on i386.
>
> [...]
>> I would prefer to use the i486 implementation and perhaps use this
>> only for i386. The problem I see here is more performance,
>
> OK, agreed, but the issue is i386 code compiled on an i386 and then
> moved to a higher processor. OK, someone that explicitly configures
> for i386 on an x86-64. I am still concerned because of this text:
>
>>> xchgl will work correctly on x86-64. The only problem (and that's why
>>> it was disabled temporarily in the patch you mentioned) is that
>>> arguments to it might have a different size.
>
> Do I have to do anything special to code against that statement?
No, nothing - if you use int's as arguments. The problem arises when
using longs since those are different,
Andreas
--
Andreas Jaeger
SuSE Labs aj at suse dot de
private aj at arthur dot inka dot de
http://www.suse.de/~aj