Tuesday, August 2, 2011

Atomic operations in C/C++

The atomic operations provided by GCC [1] come in quite handy even though they are limited to a few data types and in fact Intel-specific. AFAIK SPARC has it's own set of variants.

[1] http://gcc.gnu.org/onlinedocs/gcc-4.4.0/gcc/Atomic-Builtins.html#Atomic-Builtins

No comments: