-
Notifications
You must be signed in to change notification settings - Fork 14
56 lines (53 loc) · 1.62 KB
/
codspeed.yml
File metadata and controls
56 lines (53 loc) · 1.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: CodSpeed Benchmarks
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
benchmarks:
name: Run benchmarks
runs-on: ${{ matrix.runner }}
strategy:
matrix:
include:
- runner: ubuntu-latest
mode: instrumentation
bench: [hello_world, bfs]
- runner: codspeed-macro
mode: walltime
bench:
[
dna_matcher,
lut_grayscale_bench,
lut_filters_bench,
simd_brightness_bench,
simd_filters_bench,
blob_corruption_checker,
blob_corruption_checker,
]
steps:
- uses: actions/checkout@v4
with:
lfs: true
- name: Setup rust toolchain, cache and cargo-codspeed
uses: moonrepo/setup-rust@v1
with:
channel: nightly
cache-target: release
bins: cargo-codspeed
- name: Generate genome.fasta for dna_matcher
if: contains(matrix.bench, 'dna_matcher')
run: cargo run --bin generate_fasta --release
- name: Generate blob files for blob_corruption_checker
if: contains(matrix.bench, 'blob_corruption_checker')
run: cargo run --bin generate_blobs --release
- name: Build benchmark target(s)
run: cargo codspeed build ${{ format('--bench {0}', join(matrix.bench, ' --bench ')) }}
- name: Run the benchmarks
uses: CodSpeedHQ/action@v4
with:
mode: ${{ matrix.mode }}
run: cargo codspeed run
token: ${{ secrets.CODSPEED_TOKEN }}