From 1e0c7d4f4933b12a325dbaa2c79ce946bb13f7d6 Mon Sep 17 00:00:00 2001 From: Antonio Sanchez Date: Thu, 25 Feb 2021 14:29:49 -0800 Subject: Add print for SSE/NEON, use NEON rounding intrinsics if available. In SSE, by adding/subtracting 2^MantissaBits, we force rounding according to the current rounding mode. For NEON, we use the provided intrinsics for rint/floor/ceil if available (armv8). Related to #1969. --- Eigen/src/Core/util/Macros.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'Eigen/src/Core/util') diff --git a/Eigen/src/Core/util/Macros.h b/Eigen/src/Core/util/Macros.h index b39c6ca43..ac514cbb4 100644 --- a/Eigen/src/Core/util/Macros.h +++ b/Eigen/src/Core/util/Macros.h @@ -265,6 +265,14 @@ #define EIGEN_ARCH_ARM_OR_ARM64 0 #endif +/// \internal EIGEN_ARCH_ARMV8 set to 1 if the architecture is armv8 or greater. +#if EIGEN_ARCH_ARM_OR_ARM64 && defined(__ARM_ARCH) && __ARM_ARCH >= 8 +#define EIGEN_ARCH_ARMV8 1 +#else +#define EIGEN_ARCH_ARMV8 0 +#endif + + /// \internal EIGEN_HAS_ARM64_FP16 set to 1 if the architecture provides an IEEE /// compliant Arm fp16 type #if EIGEN_ARCH_ARM64 -- cgit v1.2.3