summaryrefslogtreecommitdiff
path: root/gcm_simd.cpp
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2018-11-14 23:12:39 -0500
committerJeffrey Walton <noloader@gmail.com>2018-11-14 23:12:39 -0500
commit505c58acc1f683024c24354397b6cc768cb0a240 (patch)
treedb2d21f2d594dc57b86905e4dace5363083ca76b /gcm_simd.cpp
parentfa8e692d840380a9c1c78bd8146dd73c2740f10e (diff)
downloadcryptopp-git-505c58acc1f683024c24354397b6cc768cb0a240.tar.gz
Add Octet suffix for vec_sld
We need to make room for packed shifts and rotates
Diffstat (limited to 'gcm_simd.cpp')
-rw-r--r--gcm_simd.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/gcm_simd.cpp b/gcm_simd.cpp
index a967eec0..fe15f18f 100644
--- a/gcm_simd.cpp
+++ b/gcm_simd.cpp
@@ -173,7 +173,7 @@ using CryptoPP::uint32x4_p;
using CryptoPP::uint64x2_p;
using CryptoPP::VectorGetLow;
using CryptoPP::VectorGetHigh;
-using CryptoPP::VectorRotateLeft;
+using CryptoPP::VectorRotateLeftOctet;
// POWER8 GCM mode is confusing. The algorithm is reflected so
// nearly everything we do is reversed for a little-endian system,
@@ -192,7 +192,7 @@ using CryptoPP::VectorRotateLeft;
inline uint64x2_p VMULL2LE(const uint64x2_p& val)
{
#if (CRYPTOPP_BIG_ENDIAN)
- return VectorRotateLeft<8>(val);
+ return VectorRotateLeftOctet<8>(val);
#else
return val;
#endif
@@ -755,10 +755,10 @@ uint64x2_p GCM_Reduce_VMULL(uint64x2_p c0, uint64x2_p c1, uint64x2_p c2, uint64x
c1 = VectorXor(c1, VectorShiftRight<8>(c0));
c1 = VectorXor(c1, VMULL_10LE(c0, r));
- c0 = VectorXor(c1, VectorShiftLeft<8>(c0));
+ c0 = VectorXor(c1, VectorShiftLeftOctet<8>(c0));
c0 = VMULL_00LE(vec_sl(c0, m1), r);
c2 = VectorXor(c2, c0);
- c2 = VectorXor(c2, VectorShiftLeft<8>(c1));
+ c2 = VectorXor(c2, VectorShiftLeftOctet<8>(c1));
c1 = vec_sr(vec_mergeh(c1, c2), m63);
c2 = vec_sl(c2, m1);
@@ -820,7 +820,7 @@ void GCM_SetKeyWithoutResync_VMULL(const byte *hashKey, byte *mulTable, unsigned
template <class T>
inline T SwapWords(const T& data)
{
- return (T)VectorRotateLeft<8>(data);
+ return (T)VectorRotateLeftOctet<8>(data);
}
inline uint64x2_p LoadBuffer1(const byte *dataBuffer)