Merge pull request #587 from etclabscore/release/v1.12.16 #103
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Benchmark VM | |
on: | |
push: | |
branches: [ master ] | |
workflow_dispatch: | |
jobs: | |
bench_core_geth: | |
name: Benchmark core-geth | |
runs-on: ubuntu-latest | |
timeout-minutes: 360 | |
steps: | |
- name: Set up Go 1.x | |
id: go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: ^1.19 | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v2 | |
with: | |
submodules: 'recursive' | |
- name: Benchmark etclabscore/core-geth | |
id: bench | |
run: | | |
go test -short ./tests -count 1 -p 1 -timeout 60m -run NONE -bench=VM -v |& tee core-geth.txt | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: core-geth | |
path: ./core-geth.txt | |
bench_go_ethereum: | |
name: Benchmark go-ethereum | |
runs-on: ubuntu-latest | |
timeout-minutes: 360 | |
steps: | |
- name: Set up Go 1.x | |
id: go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: ^1.19 | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v2 | |
with: | |
submodules: 'recursive' | |
- name: Benchmark ethereum/go-ethereum | |
id: bench | |
run: | | |
git remote add foundation https://github.com/ethereum/go-ethereum.git | |
git fetch foundation | |
git checkout v1.11.5 | |
# git submodule update | |
git checkout $GITHUB_SHA -- tests/vm_bench_test.go | |
go test -short ./tests -count 1 -p 1 -timeout 60m -run NONE -bench=VM -v |& tee go-ethereum.txt | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: go-ethereum | |
path: ./go-ethereum.txt | |
compare: | |
name: Compare | |
needs: [bench_core_geth, bench_go_ethereum] | |
runs-on: ubuntu-latest | |
timeout-minutes: 10 | |
steps: | |
- name: Set up Go 1.x | |
id: go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: ^1.19 | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v2 | |
- name: Get dependencies | |
run: | | |
go install golang.org/x/perf/cmd/benchstat@latest | |
- uses: actions/download-artifact@v2 | |
name: Get go-ethereum artifact | |
with: | |
name: go-ethereum | |
- uses: actions/download-artifact@v2 | |
name: Get core-geth artifact | |
with: | |
name: core-geth | |
- name: Prepare data | |
run: | | |
cat core-geth.txt | ./build/bench-suite-compress.sh | tee core-geth_compress.txt | |
cat go-ethereum.txt | ./build/bench-suite-compress.sh | tee go-ethereum_compress.txt | |
- name: "Analyze Results [COMPRESSED]" | |
run: | | |
benchstat go-ethereum_compress.txt core-geth_compress.txt | |
- name: "Analyze Results [RAW DELTA]" | |
run: | | |
benchstat go-ethereum.txt core-geth.txt |