You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adding a Mutex around the WitnessCalculator solves it. So .clone() on it is not actually safe.
The clone call happens concurrently (because the types allow it). Forcing the clone to be sequential does not solve the issue. Forcing calculate_witness_element to be sequential does solve it. This despite the calls being on separated clones instances. So it appears that clone() creates unsafe shared state.
The
ProvingKey<Bn254>
,ConstraintMatrices<Fr>
are shared through constant reference.WitnessCalculator
is cloned and passed as mutable reference.The text was updated successfully, but these errors were encountered: