mirror of
https://github.com/vacp2p/linea-monorepo.git
synced 2026-01-09 20:27:58 -05:00
* feat(state): connect the Hub and the StateSummary * Merged main into prover/beta-v2 * constraints: bump to beta-v2.0-rc1 * use beta-v2.0-rc1 zkevm.bin generated by go-corset * bump go-corset to v0.9.1 * fix go-corset compile errors * bump constraints to beta v2.0-rc1.1 * go-corset v0.9.1 with metadata * fix ReadZkevmBin error to align with go-corset v0.9.1 * add optimization level to CheckerZkEvm * ReadZkevmBinadd detailed logs to * feat(state-manager):adding arithmetization column names for ACP and SCP * bump go-corset to v0.9.2 * fix go-corset v0.9.2 compatibility * constraints: bump to beta-v2.1-rc1 * use zkevm.bin without 2B block gas limit for testing * fix(state manager):batch numbers on prover side + updated 20-byte address calculation * feat(go-corset): go-corset as submodule (#743) * remove corset submodule * add go-corset submodule * use go-corst in Makefile * use go-corset v0.9.2 * update go-corset submodule url * fix(go-corset): typo in submodule url * fix(state-manager): fixed Shomei issue through skippable traces + missing HUB processed address constraints + cosmetic refactoring * fix(state-manager):fixed wrong begin/end markers for account segments due to skipped Shomei traces * fix(state-manager): added an intermediary keccakcodehash column in state summary for the HUB connection + its constraints * (bump prover/beta-v2 branch): constraints beta-v2.1-rc4 and go-corset v1.0.1 (#766) - bump constraints from beta-v2.1-rc1 to rc4 - bump go-corset from v0.9.2 to v1.0.1 - this commit is to bump branch prover/beta-v2 branch to the latest verion of constraints and go-corsete without rebasing onto main * fix(state-manager): account insertion's storage segments are excluded in the lookup from HUB to state summary. * fix(state-manager): added missing constraints for the insertion edge case. * (bump beta-v2 branch): constraints beta-v2.1-rc6 and go-corset v1.0.2 * fix(state-manager): address edge case for SSLOAD out of gas exception behavior that results in no traces on Shomei side, but rows on the HUB side. * remove polluting changes * fix(state-manager): address edge case for SSLOAD out of gas exception behavior that results in no traces on Shomei side, but rows on the HUB side, proper commit. * fix(state-manager): address bug in the constancy constraint for the INSERT filter . * minor(alignment): better error message when overflowing a precompile limit * remove old v3 testdata to before merging origin/main * bump: constraints beta-v2.1-rc10 and go-corset v1.0.3 * chore: remove unnecessary code * revert pnpm-lock.yaml to main branch version * update go.sum * revert state-recovery/appcore/logic/build.gradle to main version Remove the files to revert back to the main version. Its directory structure has changed. Signed-off-by: Leo Jeong <dreamerty@postech.ac.kr> * Revert "revert state-recovery/appcore/logic/build.gradle to main version" This reverts commit 97f6c92230e511a66a29fd597bf059c9c003adfe. * revert back to the mainnet build.gradle * fixup(test): fix a test in the state-summary * minor(csv): comment out the csv tracing --------- Signed-off-by: Leo Jeong <dreamerty@postech.ac.kr> Co-authored-by: AlexandreBelling <alexandrebelling8@gmail.com> Co-authored-by: Bogdan Ursu <bogdanursuoffice@gmail.com>
148 lines
3.8 KiB
Makefile
148 lines
3.8 KiB
Makefile
# required for `source`
|
|
SHELL := /usr/bin/env bash
|
|
CORSET_ROOT := $(shell pwd)/../go-corset
|
|
|
|
VERSION := $(shell git rev-parse --short HEAD)
|
|
|
|
LINUX_AMD64_FLAGS := CGO_ENABLED=1 CC="x86_64-linux-musl-gcc" CXX="x86_64-linux-musl-g++" GOOS="linux" GOARCH="amd64"
|
|
DARWIN_ARM64_FLAGS := CGO_ENABLED=1 GOOS="linux" GOARCH="arm64"
|
|
|
|
# Ensure that we are using go-corset from the monorepo
|
|
GO_CORSET := PATH="${CORSET_ROOT}/bin":$$PATH
|
|
|
|
# these targets are not defined as depending on source files,
|
|
# so they should be recompiled by default “just in case”.
|
|
.PHONY: \
|
|
copy-prover-assets \
|
|
download-srs \
|
|
bin/proofless \
|
|
bin/compression-aggregation-sample \
|
|
bin/state-manager-inspector \
|
|
zkevm/arithmetization/zkevm.bin \
|
|
lib/compressor \
|
|
lib/shnarf-calculator \
|
|
lib/compressor-and-shnarf-calculator \
|
|
lib/compressor-and-shnarf-calculator-local \
|
|
docker \
|
|
bin/prover \
|
|
bin/checker \
|
|
go-corset \
|
|
testdata \
|
|
|
|
|
|
##
|
|
## This rule produces the go-corset binary
|
|
##
|
|
go-corset:
|
|
cd ${CORSET_ROOT} && make build
|
|
|
|
##
|
|
## Build and bundle the go-corset trace-expander dependency
|
|
##
|
|
zkevm/arithmetization/zkevm.bin: go-corset
|
|
cd ../constraints && $(GO_CORSET) make zkevm.bin && mv zkevm.bin ../prover/zkevm/arithmetization
|
|
|
|
##
|
|
## Generate the setup for the execution prover (to be run with S3 access)
|
|
##
|
|
setup: bin/prover
|
|
bin/prover setup --config ./config/config-sepolia-full.toml --dict ./lib/compressor/compressor_dict.bin --assets-dir ./prover-assets
|
|
|
|
##
|
|
## Copy the prover assets to the S3 bucket (zkuat)
|
|
##
|
|
copy-prover-assets:
|
|
aws s3 sync --exclude "*prover/dev*" --exclude "*05b9ef1*" --exclude "*05b9ef1*" --exclude "*96e3a19*" --exclude "*a9e4681*" prover-assets s3://zk-uat-prover/prover-assets/ --profile=zk-uat-s3-access
|
|
|
|
download-srs:
|
|
aws s3 sync s3://gnark-ignition/with_lines/ ./prover-assets/kzgsrs --exclude "*" --include "*.memdump"
|
|
|
|
###
|
|
### Controller
|
|
###
|
|
bin/controller:
|
|
mkdir -p bin/
|
|
rm -f $@
|
|
go build -o $@ ./cmd/controller
|
|
|
|
##
|
|
## Prover (setup and prove)
|
|
##
|
|
bin/prover:
|
|
mkdir -p bin
|
|
rm -f $@
|
|
go build -tags debug -o $@ ./cmd/prover
|
|
|
|
##
|
|
## Compiles the state-manager inspector
|
|
##
|
|
bin/state-manager-inspector:
|
|
mkdir -p bin
|
|
rm -f $@
|
|
go build -o ./$@ ./cmd/dev-tools/state-manager-inspector
|
|
|
|
##
|
|
## Generate the sample generator for the compression and the aggregation
|
|
##
|
|
bin/compression-aggregation-sample:
|
|
mkdir -p bin
|
|
rm -f $@
|
|
go build -o ./$@ -tags nocorset ./cmd/dev-tools/testcase-gen/compression-aggregation
|
|
|
|
##
|
|
## corset-checker
|
|
##
|
|
bin/checker:
|
|
mkdir -p bin
|
|
rm -f $@
|
|
go build -o $@ ./cmd/dev-tools/corset-checker
|
|
|
|
##
|
|
## Build the prover docker image
|
|
##
|
|
docker:
|
|
echo "Building docker image for the prover version ${VERSION}"
|
|
cd .. && docker buildx build -f prover/Dockerfile --build-context prover=prover/ --build-context corset=corset/ --build-context constraints=constraints/ -t consensys/linea-prover .
|
|
|
|
##
|
|
## Build compressor library
|
|
##
|
|
lib/compressor:
|
|
CGO_ENABLED=1 go build -tags=nocorset -buildmode=c-shared -o lib/compressor/build/libblob_compressor_native_jna ./lib/compressor/blob_compressor.go
|
|
|
|
##
|
|
## Build the shnarf calculator library
|
|
##
|
|
lib/shnarf-calculator:
|
|
CGO_ENABLED=1 go build -tags=nocorset -buildmode=c-shared -o lib/shnarf_calculator/build/libshnarf_calculator_native_jna ./lib/shnarf_calculator/shnarf_calculator.go
|
|
|
|
##
|
|
## Build the compressor and the shnarf-calculator for local system
|
|
##
|
|
lib/compressor-and-shnarf-calculator-local: lib/compressor lib/shnarf_calculator
|
|
|
|
##
|
|
## Run all the unit-tests
|
|
##
|
|
test:
|
|
go test ./...
|
|
|
|
##
|
|
## Run the CI linting
|
|
##
|
|
ci-lint:
|
|
golangci-lint run --timeout 5m
|
|
|
|
##
|
|
## Echo, the CGO flags. Usefull for testing manually
|
|
##
|
|
cgo-flags:
|
|
@echo $(CORSET_FLAGS)
|
|
|
|
#
|
|
# Update the prover's testdata in ../testdata/prover
|
|
#
|
|
make update-testdata-for-coordinator:
|
|
go test -timeout 30m -tags amd64,nocorset -run TestSamples github.com/consensys/linea-monorepo/prover/backend/testing -v
|
|
cp -f backend/testing/**/*-*-zkProof.json ../testdata/prover/output
|