mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 20:29:18 +00:00
LibCrypto: Remove now unused temporary BigInt buffers
Plus 1 drive-by division->shift optimization
This commit is contained in:
parent
c96d44e9cf
commit
70cfa60f56
Notes:
sideshowbarker
2024-07-17 16:23:55 +09:00
Author: https://github.com/Hendiadyoin1
Commit: 70cfa60f56
Pull-request: https://github.com/SerenityOS/serenity/pull/23619
Issue: https://github.com/SerenityOS/serenity/issues/23575
Reviewed-by: https://github.com/ADKaster ✅
Reviewed-by: https://github.com/DanShaders ✅
7 changed files with 19 additions and 42 deletions
|
@ -13,9 +13,6 @@ void UnsignedBigIntegerAlgorithms::modular_inverse_without_allocation(
|
|||
UnsignedBigInteger const& a,
|
||||
UnsignedBigInteger const& b,
|
||||
UnsignedBigInteger& temp_1,
|
||||
UnsignedBigInteger& temp_2,
|
||||
UnsignedBigInteger& temp_3,
|
||||
UnsignedBigInteger& temp_4,
|
||||
UnsignedBigInteger& temp_minus,
|
||||
UnsignedBigInteger& temp_quotient,
|
||||
UnsignedBigInteger& temp_d,
|
||||
|
@ -87,7 +84,7 @@ void UnsignedBigIntegerAlgorithms::modular_inverse_without_allocation(
|
|||
}
|
||||
|
||||
// return x % b
|
||||
divide_without_allocation(temp_x, b, temp_1, temp_2, temp_3, temp_4, temp_quotient, result);
|
||||
divide_without_allocation(temp_x, b, temp_quotient, result);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue