Rename FOLLY_A64 to FOLLY_AARCH64
authorChristopher Dykes <cdykes@fb.com>
Thu, 24 Aug 2017 05:51:43 +0000 (22:51 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Thu, 24 Aug 2017 06:10:07 +0000 (23:10 -0700)
Summary:
`FOLLY_AARCH64` is more descriptive.
(searching for A64 tells you nothing, searching for aarch64 tells you a lot)

Reviewed By: yfeldblum, andrewjcg

Differential Revision: D5663075

fbshipit-source-id: 8f31fde4aa394f5452305929541af6d38e4d8a37

folly/DiscriminatedPtr.h
folly/GroupVarint.h
folly/Math.h
folly/PackedSyncPtr.h
folly/PicoSpinLock.h
folly/Portability.h
folly/SmallLocks.h
folly/portability/Asm.h

index b773bec8ce2ca4cb96bd006f47987a9d956c2aeb..2c57fb6ee75ccc7c1447166873e774f3c38e4b2f 100644 (file)
@@ -35,7 +35,7 @@
 #include <folly/Portability.h>
 #include <folly/detail/DiscriminatedPtrDetail.h>
 
-#if !FOLLY_X64 && !FOLLY_A64 && !FOLLY_PPC64
+#if !FOLLY_X64 && !FOLLY_AARCH64 && !FOLLY_PPC64
 # error "DiscriminatedPtr is x64, arm64 and ppc64 specific code."
 #endif
 
index 8780f04e4088ebfd09c91485d423fc8a75ee4a50..6f1807d20eff314517f51c3f9290cc6ea07c86ed 100644 (file)
@@ -27,7 +27,7 @@
 
 #include <folly/Portability.h>
 
-#if FOLLY_X64 || defined(__i386__) || FOLLY_PPC64 || FOLLY_A64
+#if FOLLY_X64 || defined(__i386__) || FOLLY_PPC64 || FOLLY_AARCH64
 #define HAVE_GROUP_VARINT 1
 
 #include <folly/Bits.h>
index e31335a118032be65c96d7425da6b0f534ea061e..6d4eee5370ff77fa9f39e4d2badce6dba36a51f8 100644 (file)
@@ -106,7 +106,7 @@ using IdivResultType = typename std::enable_if<
     decltype(N{1} / D{1})>::type;
 }
 
-#if defined(__arm__) && !FOLLY_A64
+#if defined(__arm__) && !FOLLY_AARCH64
 constexpr auto kIntegerDivisionGivesRemainder = false;
 #else
 constexpr auto kIntegerDivisionGivesRemainder = true;
index 44d3f5576390ff5d43ad6db2afe14b67abaae919..a5dd51847ad99625e209d027e61b840458d95f7f 100644 (file)
@@ -23,7 +23,7 @@
 #include <folly/Portability.h>
 #include <folly/SmallLocks.h>
 
-#if !FOLLY_X64 && !FOLLY_PPC64 && !FOLLY_A64
+#if !FOLLY_X64 && !FOLLY_PPC64 && !FOLLY_AARCH64
 #error "PackedSyncPtr is x64, ppc64 or aarch64 specific code."
 #endif
 
index 4280e653d6b2014c5710b69c0513b5a7c73067ae..070f1fbe97838342aed1dea5db4663ef34802997 100644 (file)
@@ -50,7 +50,7 @@
 #include <folly/Portability.h>
 #include <folly/detail/Sleeper.h>
 
-#if !FOLLY_X64 && !FOLLY_A64 && !FOLLY_PPC64
+#if !FOLLY_X64 && !FOLLY_AARCH64 && !FOLLY_PPC64
 #error "PicoSpinLock.h is currently x64, aarch64 and ppc64 only."
 #endif
 
@@ -171,7 +171,7 @@ struct PicoSpinLock {
     }
 
 #undef FB_DOBTS
-#elif FOLLY_A64
+#elif FOLLY_AARCH64
     ret =
         !(__atomic_fetch_or(&lock_, kLockBitMask_, __ATOMIC_SEQ_CST) &
           kLockBitMask_);
@@ -254,7 +254,7 @@ struct PicoSpinLock {
     }
 
 #undef FB_DOBTR
-#elif FOLLY_A64
+#elif FOLLY_AARCH64
     __atomic_fetch_and(&lock_, ~kLockBitMask_, __ATOMIC_SEQ_CST);
 #elif FOLLY_PPC64
 #define FB_DOBTR(size)                                 \
index cf2c8d32749897faab4c5409bef86ef8f468a11a..a180bea41586d3185c8c3483d8b4456077dc4ad9 100644 (file)
@@ -169,9 +169,9 @@ struct alignas(max_align_v) max_align_t {};
 #endif
 
 #if defined(__aarch64__)
-# define FOLLY_A64 1
+# define FOLLY_AARCH64 1
 #else
-# define FOLLY_A64 0
+# define FOLLY_AARCH64 0
 #endif
 
 #if defined (__powerpc64__)
@@ -182,7 +182,7 @@ struct alignas(max_align_v) max_align_t {};
 
 namespace folly {
 constexpr bool kIsArchAmd64 = FOLLY_X64 == 1;
-constexpr bool kIsArchAArch64 = FOLLY_A64 == 1;
+constexpr bool kIsArchAArch64 = FOLLY_AARCH64 == 1;
 constexpr bool kIsArchPPC64 = FOLLY_PPC64 == 1;
 }
 
index c6ef54acea7c7e48036f974a0b2811bf87cc02d1..b0939802180f65a901b03c28cf40d413c9efd1c7 100644 (file)
@@ -37,6 +37,6 @@
 #include <folly/MicroSpinLock.h>
 
 #include <folly/Portability.h>
-#if FOLLY_X64 || FOLLY_A64 || FOLLY_PPC64
+#if FOLLY_X64 || FOLLY_AARCH64 || FOLLY_PPC64
 #include <folly/PicoSpinLock.h>
 #endif
index f7b7ebba86d0b52f933ca31ee43e198a5cee8f2e..2ed0f05137460d4b101f568d96ca5206f2cb99e2 100644 (file)
@@ -36,7 +36,7 @@ inline void asm_volatile_pause() {
   ::_mm_pause();
 #elif defined(__i386__) || FOLLY_X64
   asm volatile("pause");
-#elif FOLLY_A64 || defined(__arm__)
+#elif FOLLY_AARCH64 || defined(__arm__)
   asm volatile("yield");
 #elif FOLLY_PPC64
   asm volatile("or 27,27,27");