diff options
author | Jack Lloyd <[email protected]> | 2019-08-21 09:26:15 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2019-08-22 10:07:16 -0400 |
commit | 6adfc07738df32dc38d1b4c19e51ac3f0e21e145 (patch) | |
tree | 09bbb4c340cb2504e9e293bb8a9005595e0eda79 /src/lib/math/bigint/bigint.cpp | |
parent | f4f8dc439252589263bb20221d5b865fa60b4343 (diff) |
Small BigInt optimizations
Based on profiling RSA key generation
Diffstat (limited to 'src/lib/math/bigint/bigint.cpp')
-rw-r--r-- | src/lib/math/bigint/bigint.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/math/bigint/bigint.cpp b/src/lib/math/bigint/bigint.cpp index 154beb4b7..6f5f1f473 100644 --- a/src/lib/math/bigint/bigint.cpp +++ b/src/lib/math/bigint/bigint.cpp @@ -132,12 +132,12 @@ int32_t BigInt::cmp(const BigInt& other, bool check_signs) const return 1; if(other.is_negative() && this->is_negative()) - return (-bigint_cmp(this->data(), this->sig_words(), - other.data(), other.sig_words())); + return (-bigint_cmp(this->data(), this->size(), + other.data(), other.size())); } - return bigint_cmp(this->data(), this->sig_words(), - other.data(), other.sig_words()); + return bigint_cmp(this->data(), this->size(), + other.data(), other.size()); } bool BigInt::is_equal(const BigInt& other) const |