Hi Arnaud, On 23 Jul 2012, at 09:02, Arnaud Charlet wrote:
> This patch implements a check in the runtime library that determines whether > the current target supports the atomic primitives up to 64 bits. If I understand the name of the flag, it looks like an "all or nothing" for atomic primitives? is that a consequence of the language definition, or simply that it isn't worth spending a lot of effort on 32 bit machines? > This should fix build failures on e.g. powerpc-darwin. almost :-) On a 64-bit processor, the [32 bit] powerpc-darwin kernel is capable of launching 64bit processes. Thus, there is an m64 multi-lib for powerpc-darwin, which is built by default for GCC (and, for that multi-lib, the 64 bit locks are available). At present, bootstrap is failing while building this multi-lib. With the following, bootstrap completed on powerpc-apple-darwin9, and make check-ada shows no new fails. Should I apply it? Iain gcc/ada: * system-darwin-ppc64.ads: Add Support_Atomic_Primitives, set to True. Index: gcc/ada/system-darwin-ppc64.ads =================================================================== --- gcc/ada/system-darwin-ppc64.ads (revision 189777) +++ gcc/ada/system-darwin-ppc64.ads (working copy) @@ -137,6 +137,7 @@ private Stack_Check_Limits : constant Boolean := False; Support_64_Bit_Divides : constant Boolean := True; Support_Aggregates : constant Boolean := True; + Support_Atomic_Primitives : constant Boolean := True; Support_Composite_Assign : constant Boolean := True; Support_Composite_Compare : constant Boolean := True; Support_Long_Shifts : constant Boolean := True;