This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Optimization/clarity coding : what is gcc able to do for me ?
On Monday 17 January 2005 16:59, Joe Buck wrote:
> It's up to you as a programmer to implement locking if you want to access
> any variable longer than a "sig_atomic_t" (which is a typedef that defines
> an integral type for which accesses are guaranteed to be atomic on your
> system; it is often "int", but might not be).
We don't guarantee atomic operation for smaller types either.
For example on some arm targets "int" is atomic, but "short" is not.
Paul