libatomic, 32-bit object code vs. 64-bit object, GCC 8.3.0

Kacvinsky, Tom
Thu Jun 20 15:19:00 GMT 2019


I have built a 32-bit GCC 8.3.0 (no multi-lib support) on RHEL 5 and a 64-bit GCC 8.3.0
(again, no multi-lib support) on CentOS 5.11.  What I find interesting is that when I go
to compile a program that will need atomic locks (a Boost template class pulled in via
a header file), the 32-bit object code requires the library -latomic, but 64-bit object
code does not require that.

Looking over "info gcc" I see a multitude of options for atomic operations.  The take
away for me sis that for architectures that have an instruction set that has support
for atomic operations, libatomic is not necessary, but for other architectures, it is.

Is this a correct analysis.  If you need more specific data from me, let me know.

Thanks and regards,


More information about the Gcc-help mailing list