-
Notifications
You must be signed in to change notification settings - Fork 158
44 lines (42 loc) · 1.4 KB
/
jmh-binary-tree.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
name: jmh/benchmark-binary-tree
on:
push:
paths:
- 'jmh/benchmark-binary-tree/**'
- '.github/workflows/jmh-binary-tree.yml'
pull_request:
paths:
- 'jmh/benchmark-binary-tree/**'
- '.github/workflows/jmh-binary-tree.yml'
schedule:
- cron: "0 0 1 * *" # run every month
workflow_dispatch:
permissions:
contents: read
jobs:
build:
name: GraalVM Binary Tree Benchmark
runs-on: ubuntu-latest
timeout-minutes: 45
steps:
- uses: actions/checkout@v3
- uses: graalvm/setup-graalvm@v1
with:
java-version: '17.0.7'
distribution: 'graalvm'
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Build and Test Java Code
run: |
cd jmh/benchmark-binary-tree
# build the Java code
./mvnw --no-transfer-progress clean package
# build the native exe
./mvnw --no-transfer-progress -Pnative -DskipNativeTests package
# Could just replace with a check that the binary exists?
./target/benchmark-binary-tree
# build and run the instrumented native exe
./mvnw --no-transfer-progress -Pinstrumented -DskipNativeTests package
./target/benchmark-binary-tree-instr
# build and run the optimised native exe
./mvnw --no-transfer-progress -Poptimised -DskipNativeTests package
./target/benchmark-binary-tree-opt