-
Notifications
You must be signed in to change notification settings - Fork 12
48 lines (46 loc) · 1.51 KB
/
bench.yml
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
# SPDX-License-Identifier: Apache-2.0
name: Bench
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
types: [ "labeled" ]
jobs:
bench:
runs-on: self-hosted-rpi4
permissions:
contents: write
if: github.repository_owner == 'pq-code-package' && (github.event.label.name == 'benchmark' || github.ref == 'refs/heads/main')
steps:
- uses: actions/checkout@v4
- name: Setup nix
uses: ./.github/actions/setup-nix
with:
devShell: ci
script: |
ARCH=$(uname -m)
cat >> $GITHUB_STEP_SUMMARY <<-EOF
## Setup
Architecture: $ARCH
- $(uname -a)
- $(nix --version)
- $(astyle --version)
- $(${{ matrix.cross_prefix }}gcc --version | grep -m1 "")
- $(bash --version | grep -m1 "")
## CPU Info
$(cat /proc/cpuinfo)
EOF
- name: Run benchmark
shell: nix develop .#ci -c bash -e {0}
run: |
tests bench -c PMU --cflags -mcpu=cortex-a72 -v --output output.json
- name: Store benchmark result
if: github.repository_owner == 'pq-code-package' && github.ref == 'refs/heads/main'
uses: benchmark-action/github-action-benchmark@v1
with:
name: Arm Cortex-A72 (Raspberry Pi 4) benchmarks
tool: 'customSmallerIsBetter'
output-file-path: output.json
github-token: ${{ secrets.GITHUB_TOKEN }}
auto-push: true