]> granicus.if.org Git - libatomic_ops/commitdiff
Fix 'visibility' of some CPU-specific internal macros
authorIvan Maidanski <ivmai@mail.ru>
Thu, 6 Oct 2016 22:14:08 +0000 (01:14 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Thu, 6 Oct 2016 22:14:08 +0000 (01:14 +0300)
Undefine internal macros that are defined and used solely in a single
CPU-specific file.

* src/atomic_ops/sysdeps/gcc/arm.h (AO_BR_ALIGN, AO_MASK_PTR,
AO_THUMB_GO_ARM, AO_THUMB_RESTORE_MODE, AO_THUMB_SWITCH_CLOBBERS):
Undefine at the end of file.
* src/atomic_ops/sysdeps/gcc/hppa.h (AO_PA_LDCW_ALIGNMENT, AO_ldcw,
AO_ldcw_align): Likewise.
* src/atomic_ops/sysdeps/gcc/ia64.h (AO_IN_ADDR, AO_LEN, AO_MASK,
AO_OUT_ADDR, AO_SWIZZLE): Likewise.
* src/atomic_ops/sysdeps/gcc/mips.h (AO_MIPS_LL, AO_MIPS_LL_1,
AO_MIPS_SC, AO_MIPS_SET_ISA): Likewise.
* src/atomic_ops/sysdeps/hpc/hppa.h (AO_PA_LDCW_ALIGNMENT, AO_ldcw,
AO_ldcw_align): Likewise.
* src/atomic_ops/sysdeps/hpc/ia64.h (AO_T_FASIZE, AO_T_SIZE): Likewise.
* src/atomic_ops/sysdeps/icc/ia64.h (AO_INTEL_PTR_t): Likewise.
* src/atomic_ops/sysdeps/test_and_set_t_is_char.h (AO_TS_SET_TRUEVAL):
Likewise.

src/atomic_ops/sysdeps/gcc/arm.h
src/atomic_ops/sysdeps/gcc/hppa.h
src/atomic_ops/sysdeps/gcc/ia64.h
src/atomic_ops/sysdeps/gcc/mips.h
src/atomic_ops/sysdeps/hpc/hppa.h
src/atomic_ops/sysdeps/hpc/ia64.h
src/atomic_ops/sysdeps/icc/ia64.h
src/atomic_ops/sysdeps/test_and_set_t_is_char.h

index 84a96e1691a8c28bd75622f8a0c9d41fb8834620..f548aa1e446b0e858af9f77eff88db730c1f60a4 100644 (file)
@@ -719,3 +719,9 @@ AO_fetch_compare_and_swap(volatile AO_t *addr, AO_t old_val, AO_t new_val)
 # include "generic.h"
 
 #endif /* AO_GCC_ATOMIC_TEST_AND_SET */
+
+#undef AO_BR_ALIGN
+#undef AO_MASK_PTR
+#undef AO_THUMB_GO_ARM
+#undef AO_THUMB_RESTORE_MODE
+#undef AO_THUMB_SWITCH_CLOBBERS
index d36f5823da4a66023e5eb9a774174effcac9ab2c..ae1c3158554c48e7d4869439171d5e8ff235c7a3 100644 (file)
@@ -87,3 +87,7 @@ AO_pa_clear(volatile AO_TS_t * addr)
   *a = 1;
 }
 #define AO_CLEAR(addr) AO_pa_clear(addr)
+
+#undef AO_PA_LDCW_ALIGNMENT
+#undef AO_ldcw
+#undef AO_ldcw_align
index f5549fe801ca893f9b1656b49f191256031a5c61..98627d53bdd7a105412aee0735fe47d5abc1f8d4 100644 (file)
@@ -279,3 +279,9 @@ AO_short_fetch_compare_and_swap_release(volatile unsigned short *addr,
 
 /* TODO: Add compare_and_swap_double as soon as there is widely         */
 /* available hardware that implements it.                               */
+
+#undef AO_IN_ADDR
+#undef AO_LEN
+#undef AO_MASK
+#undef AO_OUT_ADDR
+#undef AO_SWIZZLE
index 191ad26822d28850e011e92aa71691bd783362cd..f8f154ff69e7288eddef46a00f7379e34bf59438 100644 (file)
@@ -190,3 +190,8 @@ AO_fetch_compare_and_swap(volatile AO_t *addr, AO_t old, AO_t new_val)
 /* CAS primitives with acquire, release and full semantics are  */
 /* generated automatically (and AO_int_... primitives are       */
 /* defined properly after the first generalization pass).       */
+
+#undef AO_MIPS_LL
+#undef AO_MIPS_LL_1
+#undef AO_MIPS_SC
+#undef AO_MIPS_SET_ISA
index 4e27eb2efbb4c23901960f198dc041d2cdac2ab4..f2f1dcfbb9c006cf2165b1b14539fc83e61600a7 100644 (file)
@@ -94,3 +94,7 @@ AO_pa_clear(volatile AO_TS_t * addr)
   *a = 1;
 }
 #define AO_CLEAR(addr) AO_pa_clear(addr)
+
+#undef AO_PA_LDCW_ALIGNMENT
+#undef AO_ldcw
+#undef AO_ldcw_align
index 6391eda3c01962198fbee2b041db3f24d9d40795..e71f5e80752ef09fc7e9bd8eb85fd993d8328847 100644 (file)
@@ -153,3 +153,6 @@ AO_short_fetch_compare_and_swap_release(volatile unsigned short *addr,
 #ifndef __LP64__
 # define AO_T_IS_INT
 #endif
+
+#undef AO_T_FASIZE
+#undef AO_T_SIZE
index b43a50148aab5afeefb926d6c5c889ce9c8f245b..6654209dd4341e0b5a442eae3c1480483c27067f 100644 (file)
@@ -203,3 +203,5 @@ AO_int_fetch_compare_and_swap_release(volatile unsigned int *addr,
   return _InterlockedCompareExchange_rel(addr, new_val, old_val);
 }
 #define AO_HAVE_int_fetch_compare_and_swap_release
+
+#undef AO_INTEL_PTR_t
index 1711ffd4d9c70a57024d0ac8681e03628fc2cc55..75df9c010e65b9f886ea6ada1610050521e0188e 100644 (file)
@@ -45,3 +45,5 @@ typedef enum {
 #define AO_TS_t unsigned char
 
 #define AO_CHAR_TS_T 1
+
+#undef AO_TS_SET_TRUEVAL