Skip to content

Commit 5fbfe72

Browse files
committed
Revert "Run diff / bench in parallel"
This reverts commit 6d7d7d6.
1 parent 1609a12 commit 5fbfe72

File tree

1 file changed

+10
-43
lines changed

1 file changed

+10
-43
lines changed

.github/workflows/diff.yml

Lines changed: 10 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -5,61 +5,28 @@ on:
55
branches: [ master ]
66

77
jobs:
8-
benchmark:
8+
bench:
99
runs-on: ubuntu-latest
10-
strategy:
11-
matrix:
12-
ref: [master, ${{ github.sha }}]
13-
include:
14-
- ref: master
15-
name: old
16-
- ref: ${{ github.sha }}
17-
name: new
1810
steps:
1911
- name: Setup Go 1.18
2012
uses: actions/setup-go@v4
2113
with:
2214
go-version: 1.18
23-
24-
- name: Checkout code
25-
uses: actions/checkout@v3
26-
with:
27-
ref: ${{ matrix.ref }}
28-
29-
- name: Run benchmark
30-
run: go test -bench=. -benchmem -run=^$ -count=10 -timeout=30m | tee /tmp/${{ matrix.name }}.txt
31-
32-
- name: Upload benchmark results
33-
uses: actions/upload-artifact@v3
34-
with:
35-
name: benchmark-${{ matrix.name }}
36-
path: /tmp/${{ matrix.name }}.txt
37-
38-
compare:
39-
needs: benchmark
40-
runs-on: ubuntu-latest
41-
steps:
42-
- name: Setup Go 1.18
43-
uses: actions/setup-go@v4
44-
with:
45-
go-version: 1.18
46-
4715
- name: Install benchstat
4816
# NOTE: benchstat@latest requires go 1.23 since 2025-02-14 - this is the last go 1.18 ref
4917
# https://cs.opensource.google/go/x/perf/+/c95ad7d5b636f67d322a7e4832e83103d0fdd292
5018
run: go install golang.org/x/perf/cmd/benchstat@884df5810d2850d775c2cb4885a7ea339128a17d
5119

52-
- name: Download old benchmark results
53-
uses: actions/download-artifact@v3
54-
with:
55-
name: benchmark-old
56-
path: /tmp/
20+
- uses: actions/checkout@v3
21+
- name: Benchmark new code
22+
run: go test -bench=. -benchmem -run=^$ -count=10 -timeout=30m | tee /tmp/new.txt
5723

58-
- name: Download new benchmark results
59-
uses: actions/download-artifact@v3
24+
- name: Checkout master
25+
uses: actions/checkout@v3
6026
with:
61-
name: benchmark-new
62-
path: /tmp/
27+
ref: master
28+
- name: Benchmark master
29+
run: go test -bench=. -benchmem -run=^$ -count=10 -timeout=30m | tee /tmp/old.txt
6330

64-
- name: Compare benchmarks
31+
- name: Diff
6532
run: benchstat /tmp/old.txt /tmp/new.txt

0 commit comments

Comments
 (0)