diff options
| author | Jeffrey Walton <noloader@gmail.com> | 2016-07-23 23:49:26 -0400 |
|---|---|---|
| committer | Jeffrey Walton <noloader@gmail.com> | 2016-07-23 23:49:26 -0400 |
| commit | ef4f185d9beed6709e6bf843b98f579c5fb38e8c (patch) | |
| tree | 414fc4675deb4218c52592d87cabf16b8229d02b /blake2.cpp | |
| parent | d8638a597fe364bca762fe55639899adcafc7e2b (diff) | |
| download | cryptopp-git-ef4f185d9beed6709e6bf843b98f579c5fb38e8c.tar.gz | |
Avoid accessing union value through inactive member
Diffstat (limited to 'blake2.cpp')
| -rw-r--r-- | blake2.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -13,7 +13,8 @@ NAMESPACE_BEGIN(CryptoPP)
-// Uncomment for benchmarking C++ against NEON
+// Uncomment for benchmarking C++ against SSE2 or NEON
+// #undef CRYPTOPP_BOOL_SSE4_INTRINSICS_AVAILABLE
// #undef CRYPTOPP_BOOL_NEON_INTRINSICS_AVAILABLE
// Visual Studio needs both VS2005 (1400) and _M_64 for SSE2 and _mm_set_epi64x()
@@ -46,7 +47,7 @@ inline __m128i _mm_set_epi64x(const uint64_t a, const uint64_t b) INT_128_64 v;
v.v64[0] = b; v.v64[1] = a;
- return v.v128;
+ return *(reinterpret_cast<__m128i*>(v.v64));
}
#endif
|
