-
Notifications
You must be signed in to change notification settings - Fork 225
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: test running benchmarks in CI
- Loading branch information
1 parent
77f0381
commit ed805b0
Showing
8 changed files
with
104 additions
and
32 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,26 @@ | ||
name: Benchmark | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
|
||
# This will cancel previous runs when a branch or PR is updated | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.ref || github.run_id }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
run-benchmark: | ||
name: Run benchmarks | ||
runs-on: ubuntu-22.04 | ||
timeout-minutes: 30 | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: boa-dev/criterion-compare-action@v3 | ||
with: | ||
# Optional. Compare only this package | ||
package: "nargo_cli" | ||
# Optional. Compare only this benchmark target | ||
benchName: "criterion" |
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,7 @@ | ||
[package] | ||
name = "blake2s" | ||
type = "bin" | ||
authors = [""] | ||
compiler_version = ">=0.22.0" | ||
|
||
[dependencies] |
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,37 @@ | ||
# hello as bytes | ||
# https://toolkitbay.com/tkb/tool/BLAKE2s_256 | ||
x = [104, 101, 108, 108, 111] | ||
result = [ | ||
0x19, | ||
0x21, | ||
0x3b, | ||
0xac, | ||
0xc5, | ||
0x8d, | ||
0xee, | ||
0x6d, | ||
0xbd, | ||
0xe3, | ||
0xce, | ||
0xb9, | ||
0xa4, | ||
0x7c, | ||
0xbb, | ||
0x33, | ||
0x0b, | ||
0x3d, | ||
0x86, | ||
0xf8, | ||
0xcc, | ||
0xa8, | ||
0x99, | ||
0x7e, | ||
0xb0, | ||
0x0b, | ||
0xe4, | ||
0x56, | ||
0xf1, | ||
0x40, | ||
0xca, | ||
0x25, | ||
] |
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,6 @@ | ||
use dep::std; | ||
|
||
fn main(x: [u8; 5], result: [u8; 32]) { | ||
let digest = std::hash::blake2s(x); | ||
assert(digest == result); | ||
} |
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
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
This file was deleted.
Oops, something went wrong.
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