This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: volatile qualifier hurts single-threaded optimized case


Richard Guenther wrote:

bits/atomicity.h has volatile qualifiers on the _Atomic_word* arguments to
the __*_single and __*_dispatch variants of the atomic operations. This
huts especially the single-threaded optimization variants which are usually
inlined. Removing those qualifiers allows to reduce code size significantly
as can be seen in the following simple testcase

Ok, what can be done, realistically, considering that __exchange_and_add and __atomic_add are exported, thus in any case cannot change signature, and, if possible, we would rather avoid too ugly casts?


Thanks,
Paolo.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]