Fix Illegal Instruction under SSE2+SSSE3

It appears SSE4.1 crept into our SSE2+SSSE3 implementation. We'll revisit it in the future
pull/461/head
Jeffrey Walton 2017-08-11 06:43:14 -04:00
parent 0c194bbc46
commit 6c28b521bd
No known key found for this signature in database
GPG Key ID: B36AB348921B1838
2 changed files with 3 additions and 1341 deletions

File diff suppressed because it is too large Load Diff

View File

@ -22,17 +22,8 @@ NAMESPACE_BEGIN(CryptoPP)
# undef CRYPTOPP_SSE42_AVAILABLE
#endif
// C/C++ implementation
static void BLAKE2_Compress32_CXX(const byte* input, BLAKE2_State<word32, false>& state);
static void BLAKE2_Compress64_CXX(const byte* input, BLAKE2_State<word64, true>& state);
// Also see http://github.com/weidai11/cryptopp/issues/247 for SunCC 5.12
#if CRYPTOPP_SSE2_AVAILABLE
extern void BLAKE2_Compress32_SSE2(const byte* input, BLAKE2_State<word32, false>& state);
# if (__SUNPRO_CC != 0x5120)
extern void BLAKE2_Compress64_SSE2(const byte* input, BLAKE2_State<word64, true>& state);
# endif
#endif
void BLAKE2_Compress32_CXX(const byte* input, BLAKE2_State<word32, false>& state);
void BLAKE2_Compress64_CXX(const byte* input, BLAKE2_State<word64, true>& state);
#if CRYPTOPP_SSE42_AVAILABLE
extern void BLAKE2_Compress32_SSE4(const byte* input, BLAKE2_State<word32, false>& state);
@ -101,13 +92,6 @@ pfnCompress64 InitializeCompress64Fn()
return &BLAKE2_Compress64_SSE4;
else
#endif
#if CRYPTOPP_SSE2_AVAILABLE
# if (__SUNPRO_CC != 0x5120)
if (HasSSE2())
return &BLAKE2_Compress64_SSE2;
else
# endif
#endif
#if CRYPTOPP_BOOL_ARM32 && CRYPTOPP_ARM_NEON_AVAILABLE
if (HasNEON())
return &BLAKE2_Compress64_NEON;
@ -123,11 +107,6 @@ pfnCompress32 InitializeCompress32Fn()
return &BLAKE2_Compress32_SSE4;
else
#endif
#if CRYPTOPP_SSE2_AVAILABLE
if (HasSSE2())
return &BLAKE2_Compress32_SSE2;
else
#endif
#if CRYPTOPP_BOOL_ARM32 && CRYPTOPP_ARM_NEON_AVAILABLE
if (HasNEON())
return &BLAKE2_Compress32_NEON;