Update CRYPTOPP_BOOL_ARM_PMULL_INTRINSICS_AVAILABLE availability (Issue 362)

PMULL and PMULL2 are available on Aarch64 only, and not Aarch32 or A-32
pull/368/head
Jeffrey Walton 2017-01-16 05:35:53 -05:00
parent 3a1a14c885
commit 8eb1b6cb6b
No known key found for this signature in database
GPG Key ID: B36AB348921B1838
1 changed files with 4 additions and 2 deletions

View File

@ -491,13 +491,15 @@ NAMESPACE_END
# endif # endif
#endif #endif
// Requires ARMv8 and ACLE 2.0. GCC requires 4.8 and above. // Requires ARMv8, ACLE 2.0 and Aarch64. GCC requires 4.8 and above.
// LLVM Clang requires 3.5. Apple Clang does not support it at the moment. // LLVM Clang requires 3.5. Apple Clang does not support it at the moment.
// Microsoft plans to support ARM-64, but its not clear how to detect it. // Microsoft plans to support ARM-64, but its not clear how to detect it.
// TODO: Add MSC_VER and ARM-64 platform define when available // TODO: Add MSC_VER and ARM-64 platform define when available
#if !defined(CRYPTOPP_BOOL_ARM_PMULL_INTRINSICS_AVAILABLE) && !defined(CRYPTOPP_DISABLE_ASM) #if !defined(CRYPTOPP_BOOL_ARM_PMULL_INTRINSICS_AVAILABLE) && !defined(CRYPTOPP_DISABLE_ASM)
# if defined(__ARM_FEATURE_CRYPTO) && !defined(__apple_build_version__) # if defined(__ARM_FEATURE_CRYPTO) && !defined(__apple_build_version__)
# define CRYPTOPP_BOOL_ARM_PMULL_INTRINSICS_AVAILABLE 1 # if defined(__arm64__) || defined(__aarch64__)
# define CRYPTOPP_BOOL_ARM_PMULL_INTRINSICS_AVAILABLE 1
# endif
# endif # endif
#endif #endif