-
Notifications
You must be signed in to change notification settings - Fork 98
132 lines (107 loc) · 4.22 KB
/
benchmark.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
name: Benchmark
on:
# pull_request:
# branches:
# - main
# types:
# - closed
workflow_dispatch:
jobs:
run-benchmarks:
# if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && github.event.pull_request.merged == true && !contains(github.event.pull_request.title, '[SKIPCI]'))
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: "1.21.1"
- name: Install crystal
uses: crystal-lang/install-crystal@v1
- name: Install zig
uses: goto-bus-stop/setup-zig@v2
- name: Install Julia
uses: julia-actions/setup-julia@v1
- name: Install Vlang
uses: vlang/[email protected]
# with:
# version: "stable"
- name: Install odin
run: |
wget https://github.com/odin-lang/Odin/releases/download/dev-2023-08/odin-ubuntu-amd64-dev-2023-08.zip -O odin.zip
unzip odin.zip -d odin_exe
chmod +x $GITHUB_WORKSPACE/odin_exe/odin
echo "$GITHUB_WORKSPACE/odin_exe" >> $GITHUB_PATH
- name: Install hyperfine for benchmarking
run: |
wget https://github.com/sharkdp/hyperfine/releases/download/v1.17.0/hyperfine_1.17.0_amd64.deb -O hyperfine.deb
sudo dpkg -i hyperfine.deb
- name: Install dart
uses: dart-lang/setup-dart@v1
- name: Install swift
uses: swift-actions/setup-swift@v1
- name: Install node
uses: actions/setup-node@v3
with:
node-version: latest
- name: Install bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Install deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: Install Java
uses: actions/[email protected]
with:
distribution: "temurin"
java-version: "17"
- name: Install GraalVM
uses: graalvm/setup-graalvm@v1
with:
java-version: "21"
set-java-home: false
- name: Install Nim
uses: iffy/install-nim@v5
- name: Install Dotnet
uses: actions/setup-dotnet@v3
- name: Install LuaJit
run: |
sudo apt install luajit lua5.1 luarocks lua-socket:amd64
- name: Install Python
uses: actions/[email protected]
with:
python-version: "3.11"
- name: Install Ocaml
uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: "5.1"
- name: Run Benchmark
run: ./run.sh all raw_results.md
- name: Clean up
run: rm -rf odin_exe && rm hyperfine.deb && rm odin.zip && rm -rf vlang
# - name: Push results to repo
# uses: github-actions-x/[email protected]
# with:
# commit-message: "Update benchmark results"
# files: raw_results.md
# push-branch: main
# github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Modify Readme
run: dart extract_results.dart raw_results.md
- name: Create Pull Request
uses: peter-evans/create-pull-request@v5
with:
token: ${{ secrets.GH_REPO_TOKEN }}
commit-message: Update benchmark results
title: "[SKIPCI] Update benchmark results"
body: "New benchmark results"
labels: automated pr
branch: benchmark-results
add-paths: |
raw_results.md
readme.md