Skip to content

Commit 4a06a75

Browse files
committed
ci: add benchmark
1 parent 5076c7a commit 4a06a75

File tree

4 files changed

+357
-97
lines changed

4 files changed

+357
-97
lines changed

.github/workflows/benchmark.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Benchmark
2+
3+
permissions: {}
4+
5+
on:
6+
pull_request:
7+
push:
8+
branches:
9+
- main
10+
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
13+
cancel-in-progress: true
14+
15+
defaults:
16+
run:
17+
shell: bash
18+
19+
jobs:
20+
benchmark:
21+
name: Benchmark
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v5
25+
26+
- name: Setup Rust
27+
uses: dtolnay/rust-toolchain@stable
28+
with:
29+
targets: x86_64-unknown-linux-gnu
30+
31+
- uses: taiki-e/install-action@v2
32+
with:
33+
tool: cargo-codspeed
34+
35+
- name: Build benchmark
36+
run: cargo codspeed build
37+
38+
- name: Run benchmark
39+
uses: CodSpeedHQ/action@v4
40+
timeout-minutes: 15
41+
with:
42+
run: cargo codspeed run
43+
mode: instrumentation
44+
token: ${{ secrets.CODSPEED_TOKEN }}

0 commit comments

Comments
 (0)