From 0fafb7813abfcda34fb3e411daecfea0eb0f7196 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Garillot?= Date: Tue, 13 Feb 2024 10:46:08 -0500 Subject: [PATCH] fix: gate parallelism on cuda --- src/spartan/batched_ppsnark.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/spartan/batched_ppsnark.rs b/src/spartan/batched_ppsnark.rs index fa369ba6..30d9268e 100644 --- a/src/spartan/batched_ppsnark.rs +++ b/src/spartan/batched_ppsnark.rs @@ -226,6 +226,13 @@ impl> BatchedRelaxedR1CSSNARKTrait let comms_Az_Bz_Cz = polys_Az_Bz_Cz .par_iter() .map(|[Az, Bz, Cz]| { + #[cfg(features = "cuda")] + { + let comm_Az = E::CE::commit(ck, Az); + let comm_Bz = E::CE::commit(ck, Bz); + let comm_Cz = E::CE::commit(ck, Cz); + } + #[cfg(not(features = "cuda"))] let (comm_Az, (comm_Bz, comm_Cz)) = rayon::join( || E::CE::commit(ck, Az), || rayon::join(|| E::CE::commit(ck, Bz), || E::CE::commit(ck, Cz)),