From fc8379d9edfa4b1cf63c9f008c8a2d9deaf7024a Mon Sep 17 00:00:00 2001 From: Weikeng Chen Date: Tue, 5 Sep 2023 05:39:34 -0700 Subject: [PATCH] Add the small subgroup power for BN254 (#163) Co-authored-by: mmagician Co-authored-by: Pratyush Mishra --- bn254/src/fields/fr.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bn254/src/fields/fr.rs b/bn254/src/fields/fr.rs index b79e33f..dae25ff 100644 --- a/bn254/src/fields/fr.rs +++ b/bn254/src/fields/fr.rs @@ -3,5 +3,7 @@ use ark_ff::fields::{Fp256, MontBackend, MontConfig}; #[derive(MontConfig)] #[modulus = "21888242871839275222246405745257275088548364400416034343698204186575808495617"] #[generator = "5"] +#[small_subgroup_base = "3"] +#[small_subgroup_power = "2"] pub struct FrConfig; pub type Fr = Fp256>;