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
When compiling a project using the Spartan Lib (Code Below) on the current nightly (rustc 1.76.0-nightly (ba7c7a301 2023-11-13)), I get the following error (below) that packed_simd_2 could not be compiled. I'm not sure what is causing this, although in doing some searching, it seems support was dropped in rust 1.72 for this function [Ref: https://github.com/dtolnay/proc-macro2/issues/398]. However, I did try falling back to rust 1.71 stable and received a different error because the dependencies need the nightly features to work. It seems that this may be related, although I am not sure: rust-lang/packed_simd#356
For what it is worth, I get the same error when compiling on Rust 1.74 nightly (rustc 1.74.0-nightly (7d9bce327 2023-09-16))
[package]
name = "spartan-pocf"version = "0.1.0"edition = "2021"# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
merlin = "3.0.0"spartan = "0.8.0"
main.rs
externcrate libspartan;externcrate merlin;use libspartan::{Instance,SNARKGens,SNARK};use merlin::Transcript;fnmain(){test_libspartan();}fntest_libspartan(){// specify the size of an R1CS instancelet num_vars = 1024;let num_cons = 1024;let num_inputs = 10;let num_non_zero_entries = 1024;// produce public parameterslet gens = SNARKGens::new(num_cons, num_vars, num_inputs, num_non_zero_entries);// ask the library to produce a synthentic R1CS instancelet(inst, vars, inputs) = Instance::produce_synthetic_r1cs(num_cons, num_vars, num_inputs);// create a commitment to the R1CS instancelet(comm, decomm) = SNARK::encode(&inst,&gens);// produce a proof of satisfiabilityletmut prover_transcript = Transcript::new(b"snark_example");let proof = SNARK::prove(&inst,&comm,&decomm, vars,&inputs,&gens,&mut prover_transcript);// verify the proof of satisfiabilityletmut verifier_transcript = Transcript::new(b"snark_example");assert!(proof
.verify(&comm,&inputs,&mut verifier_transcript,&gens).is_ok());println!("proof verification successful!");}
Hi! One option could be to run it with default-features turned off. If you see the default feature here, it turns on the simd-backend feature of curve25519-dalek:
When compiling a project using the Spartan Lib (Code Below) on the current nightly (
rustc 1.76.0-nightly (ba7c7a301 2023-11-13)
), I get the following error (below) thatpacked_simd_2
could not be compiled. I'm not sure what is causing this, although in doing some searching, it seems support was dropped in rust 1.72 for this function [Ref: https://github.com/dtolnay/proc-macro2/issues/398]. However, I did try falling back to rust 1.71 stable and received a different error because the dependencies need the nightly features to work. It seems that this may be related, although I am not sure: rust-lang/packed_simd#356For what it is worth, I get the same error when compiling on Rust 1.74 nightly (
rustc 1.74.0-nightly (7d9bce327 2023-09-16)
)Error:
Project Code
Cargo.toml
main.rs
Versions
Rust Version
Ubuntu Version
The text was updated successfully, but these errors were encountered: