aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2019-08-17 07:43:08 -0400
committerJack Lloyd <[email protected]>2019-08-17 07:43:08 -0400
commit3470529e238571c8b31f83102a8617c3575efb46 (patch)
tree6898683c6d26eacd17590e8f991cf7d700b565f7
parent0f57ea372e9f8b514922b9efc896fb3163b42304 (diff)
Add function comment [ci skip]
-rw-r--r--src/lib/math/numbertheory/reducer.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lib/math/numbertheory/reducer.h b/src/lib/math/numbertheory/reducer.h
index 65d9956f2..b1c2c87a9 100644
--- a/src/lib/math/numbertheory/reducer.h
+++ b/src/lib/math/numbertheory/reducer.h
@@ -47,6 +47,12 @@ class BOTAN_PUBLIC_API(2,0) Modular_Reducer
BigInt cube(const BigInt& x) const
{ return multiply(x, this->square(x)); }
+ /**
+ * Low level reduction function. Mostly for internal use.
+ * Sometimes useful for performance by reducing temporaries
+ * Reduce x mod p and place the output in out. ** X and out must not reference each other **
+ * ws is a temporary workspace.
+ */
void reduce(BigInt& out, const BigInt& x, secure_vector<word>& ws) const;
bool initialized() const { return (m_mod_words != 0); }