开源C2优化
- 显卡3090
git clone https://github.com/jackoelv/bellperson.git
cd bellperson/
git checkout origin/3090
vim Cargo.toml
- version = “0.12.3” 修改为 version = “0.12.5”
[package]
name = "bellperson"
authors = [
"dignifiedquire <me@dignifiedquire.com>",
"Sean Bowe <ewillbefull@gmail.com>",
]
description = "zk-SNARK library"
documentation = "https://docs.rs/bellperson"
homepage = "https://github.com/filecoin-project/bellman"
license = "MIT/Apache-2.0"
repository = "https://github.com/filecoin-project/bellman"
version = "0.12.5"
readme = "README.md"
edition = "2018"
lotus
- 先编译一次
env RUSTFLAGS="-C target-cpu=native -g" FFI_BUILD_FROM_SOURCE=1 make clean all
cd extern/filecoin-ffi/rust/
vim Cargo.toml
- 添加bellperson路径
[patch.crates-io]
bellperson = { path = "/root/jackoelv/bellperson" }
# cargo update
Updating `https://mirrors.tuna.tsinghua.edu.cn/git/crates.io-index.git` index
Adding bellperson v0.12.5 (/root/jackoelv/bellperson)
Updating bellperson v0.12.5 -> v0.13.0
Adding blst v0.3.3
Adding blstrs v0.2.2
Updating neptune v2.6.0 -> v2.7.0
Adding scoped_threadpool v0.1.9
Adding zeroize v1.2.0
Adding zeroize_derive v1.0.1
# cargo update -p neptune --precise 2.6.0
Updating `https://mirrors.tuna.tsinghua.edu.cn/git/crates.io-index.git` index
Removing bellperson v0.13.0
Updating neptune v2.7.0 -> v2.6.0
- 重新编译,5个告警可以忽略
env RUSTFLAGS="-C target-cpu=native -g" FFI_BUILD_FROM_SOURCE=1 make clean all
参考: