From: qiulaidongfeng <2645477756@qq.com> Date: Wed, 28 Feb 2024 11:47:39 +0000 (+0000) Subject: crypto/internal/bigmod: remove unused ctGeq X-Git-Tag: go1.23rc1~1050 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=a414fd791172de8f53eb93d495a00d63514db951;p=gostls13.git crypto/internal/bigmod: remove unused ctGeq Change-Id: I6d76fe4a307be0f976ccaeeedb6f08d672ae4851 GitHub-Last-Rev: a9554cdb47489b9160d3f03efd41898b244f13d0 GitHub-Pull-Request: golang/go#65992 Reviewed-on: https://go-review.googlesource.com/c/go/+/567675 LUCI-TryBot-Result: Go LUCI Reviewed-by: Roland Shoemaker Reviewed-by: Filippo Valsorda Auto-Submit: Filippo Valsorda Reviewed-by: Carlos Amedee --- diff --git a/src/crypto/internal/bigmod/nat.go b/src/crypto/internal/bigmod/nat.go index 7fdd8ef177..8918fe4c8a 100644 --- a/src/crypto/internal/bigmod/nat.go +++ b/src/crypto/internal/bigmod/nat.go @@ -40,14 +40,6 @@ func ctEq(x, y uint) choice { return not(choice(c1 | c2)) } -// ctGeq returns 1 if x >= y, and 0 otherwise. The execution time of this -// function does not depend on its inputs. -func ctGeq(x, y uint) choice { - // If x < y, then x - y generates a carry. - _, carry := bits.Sub(x, y, 0) - return not(choice(carry)) -} - // Nat represents an arbitrary natural number // // Each Nat has an announced length, which is the number of limbs it has stored.