summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2019-07-02 16:55:00 -0400
committerJeffrey Walton <noloader@gmail.com>2019-07-02 16:55:00 -0400
commitfbbf0a08e8cf4faca661b0f75f806ea652abea70 (patch)
tree35d8792ee03bdd7395c539a842190a706376278c
parent2eb400c52f60eea14be7b0c56295c58de3210fc6 (diff)
downloadcryptopp-git-fbbf0a08e8cf4faca661b0f75f806ea652abea70.tar.gz
Add missing XOP header for blake2b_simd.cpp (GH #859)
The Gentoo folks caught a bug at https://bugs.gentoo.org/689162. The 689162 bug uses -march=bdver1 -msse4.1 on a AMD Bulldozer machine. Investigating the issue we are missing the XOP header blake2b_simd.cpp. However, adding the XOP header is not enough for this particular config. Four source files fail to compile with the expected headers. We are waiting on the GCC folks to get back to us with a fix.
-rw-r--r--blake2b_simd.cpp5
-rw-r--r--keccak_simd.cpp5
-rw-r--r--simon128_simd.cpp1
-rw-r--r--speck128_simd.cpp1
4 files changed, 12 insertions, 0 deletions
diff --git a/blake2b_simd.cpp b/blake2b_simd.cpp
index ff138321..b246824c 100644
--- a/blake2b_simd.cpp
+++ b/blake2b_simd.cpp
@@ -32,6 +32,11 @@
# undef CRYPTOPP_ALTIVEC_AVAILABLE
#endif
+#if defined(__XOP__)
+# include <immintrin.h>
+# include <ammintrin.h>
+#endif
+
#if (CRYPTOPP_SSE41_AVAILABLE)
# include <emmintrin.h>
# include <tmmintrin.h>
diff --git a/keccak_simd.cpp b/keccak_simd.cpp
index 45674ac2..ae2f2095 100644
--- a/keccak_simd.cpp
+++ b/keccak_simd.cpp
@@ -26,6 +26,11 @@
# include <tmmintrin.h>
#endif
+#if defined(__XOP__)
+# include <immintrin.h>
+# include <ammintrin.h>
+#endif
+
// Squash MS LNK4221 and libtool warnings
extern const char KECCAK_SIMD_FNAME[] = __FILE__;
diff --git a/simon128_simd.cpp b/simon128_simd.cpp
index 5331c351..4b551f8f 100644
--- a/simon128_simd.cpp
+++ b/simon128_simd.cpp
@@ -23,6 +23,7 @@
#endif
#if defined(__XOP__)
+# include <immintrin.h>
# include <ammintrin.h>
#endif
diff --git a/speck128_simd.cpp b/speck128_simd.cpp
index 2c356346..fb3eb1e6 100644
--- a/speck128_simd.cpp
+++ b/speck128_simd.cpp
@@ -23,6 +23,7 @@
#endif
#if defined(__XOP__)
+# include <immintrin.h>
# include <ammintrin.h>
#endif