Skip to content

Commit e88c0a3

Browse files
add benchmarks and run in codspeed (#248)
1 parent eec734c commit e88c0a3

File tree

11 files changed

+562
-16
lines changed

11 files changed

+562
-16
lines changed

.github/workflows/bench.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: bench
2+
3+
on:
4+
pull_request:
5+
push:
6+
branches: [main]
7+
workflow_dispatch:
8+
9+
jobs:
10+
benchmarks:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
contents: read
14+
steps:
15+
- uses: actions/checkout@v5
16+
with:
17+
persist-credentials: false
18+
19+
- uses: actions-rust-lang/setup-rust-toolchain@2fcdc490d667999e01ddbbf0f2823181beef6b39
20+
with:
21+
toolchain: stable
22+
23+
- run: cargo install cargo-codspeed --locked
24+
25+
- name: Build the benchmark target(s)
26+
run: cargo codspeed build
27+
28+
- name: Run the benchmarks
29+
uses: CodSpeedHQ/action@653fdc30e6c40ffd9739e40c8a0576f4f4523ca1
30+
with:
31+
mode: instrumentation
32+
run: cargo codspeed run

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ jobs:
7676
components: clippy
7777

7878
- name: Run clippy
79-
run: cargo clippy --all-targets --all-features -- -D warnings
79+
run: cargo clippy --all-targets --all-features --benches -- -D warnings
8080

8181
cargo-check:
8282
runs-on: ubuntu-24.04

0 commit comments

Comments
 (0)