Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2561 from input-output-hk/nc/bench-tx
Benchmarking
- Loading branch information
Showing
8 changed files
with
52 additions
and
4 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
[.[2][] | | ||
.reportName as $bench_name | | ||
{ name: $bench_name, unit: "Nanoseconds", value: .reportAnalysis.anMean.estPoint, range: .reportAnalysis.anStdDev.estPoint }] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Ledger Benchmarks | ||
on: | ||
push: | ||
branches: | ||
- master | ||
- nc/bench-tx | ||
|
||
permissions: | ||
contents: write | ||
deployments: write | ||
|
||
jobs: | ||
benchmark: | ||
name: cardano-ledger benchmarks | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: cachix/install-nix-action@v15 | ||
with: | ||
nix_path: nixpkgs=channel:nixos-unstable | ||
extra_nix_config: | | ||
trusted-public-keys = hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ= cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= | ||
substituters = https://hydra.iohk.io https://cache.nixos.org/ | ||
- name: Build benchmarks | ||
run: nix-build -A haskellPackages.cardano-ledger-test.components.benchmarks | ||
- name: Run benchmark | ||
run: | | ||
cd libs/cardano-ledger-test | ||
../../result/bin/bench "applyTxBenchmarks" --json bench.json | ||
- name: Transform results | ||
run: | | ||
nix-env -i jq -f '<nixpkgs>' | ||
jq -f .github/tools/extract_criterion.jq < libs/cardano-ledger-test/bench.json > output.json | ||
- name: Store benchmark result | ||
uses: benchmark-action/github-action-benchmark@v1 | ||
with: | ||
name: Haskell Benchmark | ||
tool: 'customSmallerIsBetter' | ||
output-file-path: output.json | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
auto-push: true | ||
# Show alert with commit comment on detecting possible performance regression | ||
alert-threshold: '200%' | ||
comment-on-alert: true | ||
fail-on-alert: true | ||
alert-comment-cc-users: '@nc6' |
This file was deleted.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
Binary file modified
BIN
-910 Bytes
(82%)
libs/cardano-ledger-test/bench/resources/1_ledgerstate.cbor
Binary file not shown.
Binary file not shown.
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