summaryrefslogtreecommitdiff
path: root/adv-simd.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2018-07-01 03:29:12 -0400
committerJeffrey Walton <noloader@gmail.com>2018-07-01 03:29:12 -0400
commit64d15aff668da71290ff104353d2974e04ff5801 (patch)
treea4ad0297d60585958185c0e263b5c091b6333e4e /adv-simd.h
parentb35df7589041cefd493fda9ed23b7251e3516326 (diff)
downloadcryptopp-git-64d15aff668da71290ff104353d2974e04ff5801.tar.gz
Update documentation
Diffstat (limited to 'adv-simd.h')
-rw-r--r--adv-simd.h22
1 files changed, 19 insertions, 3 deletions
diff --git a/adv-simd.h b/adv-simd.h
index 496dae9f..b99369c7 100644
--- a/adv-simd.h
+++ b/adv-simd.h
@@ -853,6 +853,14 @@ NAMESPACE_END // CryptoPP
NAMESPACE_BEGIN(CryptoPP)
+/// \brief AdvancedProcessBlocks for 1 and 2 blocks
+/// \tparam F1 function to process 1 64-bit block
+/// \tparam F4 function to process 2 64-bit blocks
+/// \tparam W word type of the subkey table
+/// \details AdvancedProcessBlocks64_2x1_SSE processes 2 and 1 SSE SIMD words
+/// at a time.
+/// \details The subkey type is usually word32 or word64. F1 and F2 must use the
+/// same word type.
template <typename F1, typename F2, typename W>
inline size_t AdvancedProcessBlocks64_2x1_SSE(F1 func1, F2 func2,
MAYBE_CONST W *subKeys, size_t rounds, const byte *inBlocks,
@@ -1583,8 +1591,16 @@ inline size_t AdvancedProcessBlocks128_4x1_SSE(F1 func1, F4 func4,
return length;
}
-template <typename F1, typename F2, typename W>
-inline size_t AdvancedProcessBlocks64_4x1_SSE(F1 func1, F2 func2,
+/// \brief AdvancedProcessBlocks for 1 and 4 blocks
+/// \tparam F1 function to process 1 64-bit block
+/// \tparam F4 function to process 6 64-bit blocks
+/// \tparam W word type of the subkey table
+/// \details AdvancedProcessBlocks64_4x1_SSE processes 4 and 1 SSE SIMD words
+/// at a time.
+/// \details The subkey type is usually word32 or word64. F1 and F4 must use the
+/// same word type.
+template <typename F1, typename F4, typename W>
+inline size_t AdvancedProcessBlocks64_4x1_SSE(F1 func1, F4 func4,
MAYBE_CONST W *subKeys, size_t rounds, const byte *inBlocks,
const byte *xorBlocks, byte *outBlocks, size_t length, word32 flags)
{
@@ -1670,7 +1686,7 @@ inline size_t AdvancedProcessBlocks64_4x1_SSE(F1 func1, F2 func2,
xorBlocks += xorIncrement;
}
- func2(block0, block1, block2, block3, subKeys, static_cast<unsigned int>(rounds));
+ func4(block0, block1, block2, block3, subKeys, static_cast<unsigned int>(rounds));
if (xorOutput)
{