-
Notifications
You must be signed in to change notification settings - Fork 67
50 lines (43 loc) · 1.39 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
49
50
name: 'Benchmark'
on:
pull_request:
jobs:
self:
name: Georgia Tech | Phoenix (NVHPC)
if: github.repository == 'MFlowCode/MFC'
strategy:
matrix:
device: ['cpu', 'gpu']
runs-on:
group: phoenix
labels: self-hosted
steps:
- name: Clone - PR
uses: actions/checkout@v3
with:
path: pr
- name: Clone - Master
uses: actions/checkout@v3
with:
repository: henryleberre/MFC
ref: master
path: master
- name: Bench (Master v. PR)
run: |
(cd pr && bash .github/workflows/phoenix/submit.sh .github/workflows/phoenix/bench.sh ${{ matrix.device }}) &
(cd master && bash .github/workflows/phoenix/submit.sh .github/workflows/phoenix/bench.sh ${{ matrix.device }}) &
wait %1 && wait %2
- name: Generate Comment
run: |
COMMENT_MSG=`python3 .github/workflows/phoenix/compare.py master/bench-${{ matrix.device }}.yaml pr/bench-${{ matrix.device }}.yaml`
echo "COMMENT_MSG=\"$COMMENT_MSG\"" >> $GITHUB_ENV
- name: Post Comment
run: echo "$COMMENT_MSG"
- name: Archive Logs
uses: actions/upload-artifact@v3
if: always()
with:
name: logs-${{ matrix.device }}
path: |
pr/bench-${{ matrix.device }}-*
master/bench-${{ matrix.device }}-*