diff options
author | Rasmus Munk Larsen <rmlarsen@google.com> | 2019-06-05 13:36:37 -0700 |
---|---|---|
committer | Rasmus Munk Larsen <rmlarsen@google.com> | 2019-06-05 13:36:37 -0700 |
commit | f715f6e816d75077feb3aa682bec7ffee1b26207 (patch) | |
tree | f192bd454cecfba2ce00e3e5fc79a83d0bc51976 /Eigen/src/Core/util | |
parent | c1b0aea653f6fec269264230f67b59cad5517937 (diff) |
Add workaround for choosing the right include files with FP16C support with clang.
Diffstat (limited to 'Eigen/src/Core/util')
-rw-r--r-- | Eigen/src/Core/util/ConfigureVectorization.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Eigen/src/Core/util/ConfigureVectorization.h b/Eigen/src/Core/util/ConfigureVectorization.h index d2f2f33f7..3cf5cb480 100644 --- a/Eigen/src/Core/util/ConfigureVectorization.h +++ b/Eigen/src/Core/util/ConfigureVectorization.h @@ -375,6 +375,13 @@ #if defined(__F16C__) && (!defined(EIGEN_COMP_CLANG) || EIGEN_COMP_CLANG>=380) // We can use the optimized fp16 to float and float to fp16 conversion routines #define EIGEN_HAS_FP16_C + + #if defined(EIGEN_COMP_CLANG) + // Workaround for clang: The FP16C intrinsics for clang are included by + // immintrin.h, as opposed to emmintrin.h as suggested by Intel: + // https://software.intel.com/sites/landingpage/IntrinsicsGuide/#othertechs=FP16C&expand=1711 + #include <immintrin.h> + #endif #endif #if defined EIGEN_CUDACC |