mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-01 03:57:15 +02:00
LibCrypto: Remove now unused temporary BigInt buffers
Plus 1 drive-by division->shift optimization
This commit is contained in:
committed by
Andrew Kaster
parent
c96d44e9cf
commit
70cfa60f56
Notes:
sideshowbarker
2024-07-17 16:23:55 +09:00
Author: https://github.com/Hendiadyoin1 Commit: https://github.com/SerenityOS/serenity/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 ✅
@@ -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);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user