diff --git a/constantine/arithmetic/bigints.nim b/constantine/arithmetic/bigints.nim index 6c38c60..53ec303 100644 --- a/constantine/arithmetic/bigints.nim +++ b/constantine/arithmetic/bigints.nim @@ -10,7 +10,7 @@ import ../config/[common, type_bigint], ../primitives, ./limbs, - ./limbs_generic_modular, + ./limbs_modular, ./limbs_montgomery export BigInt diff --git a/constantine/arithmetic/finite_fields_inversion.nim b/constantine/arithmetic/finite_fields_inversion.nim index 16a3144..cbaeae5 100644 --- a/constantine/arithmetic/finite_fields_inversion.nim +++ b/constantine/arithmetic/finite_fields_inversion.nim @@ -19,13 +19,13 @@ export zoo_inversions # # ############################################################ -func inv_euclid*(r: var Fp, a: Fp) = +func inv_euclid*(r: var Fp, a: Fp) {.inline.} = ## Inversion modulo p via ## Niels Moller constant-time version of ## Stein's GCD derived from extended binary Euclid algorithm r.mres.steinsGCD(a.mres, Fp.C.getR2modP(), Fp.C.Mod, Fp.C.getPrimePlus1div2()) -func inv*(r: var Fp, a: Fp) = +func inv*(r: var Fp, a: Fp) {.inline.} = ## Inversion modulo p ## ## The inverse of 0 is 0. @@ -41,7 +41,7 @@ func inv*(r: var Fp, a: Fp) = else: r.inv_euclid(a) -func inv*(a: var Fp) = +func inv*(a: var Fp) {.inline.} = ## Inversion modulo p ## ## The inverse of 0 is 0. diff --git a/constantine/arithmetic/limbs_generic_modular.nim b/constantine/arithmetic/limbs_modular.nim similarity index 100% rename from constantine/arithmetic/limbs_generic_modular.nim rename to constantine/arithmetic/limbs_modular.nim