-
-
Notifications
You must be signed in to change notification settings - Fork 107
82 lines (71 loc) · 2.59 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
name: Trigger Benchmark
on:
workflow_dispatch:
push:
branches:
- 'master'
- 'NewFastSIMD'
paths-ignore:
- 'NoiseTool/**'
- '.github/**'
- '*.md'
jobs:
benchmark-matrix:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
name: win64-msvc
cmake_options: -A x64
- os: windows-latest
name: win64-clangcl
cmake_options: -A x64 -T ClangCL
- os: ubuntu-22.04
name: linux64-gcc
cmake_options: -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11
- os: ubuntu-22.04
name: linux64-clang
cmake_options: -DCMAKE_C_COMPILER=clang-14 -DCMAKE_CXX_COMPILER=clang++-14
steps:
- name: 'Checkout'
uses: actions/checkout@v3
- name: 'CMake Configure'
run: cmake -S ${{ github.workspace }} -B ${{ github.workspace }}/build -DCMAKE_BUILD_TYPE=Release -DFASTNOISE2_TOOLS=OFF -DFASTNOISE2_TESTS=ON ${{ matrix.cmake_options }}
- name: 'CMake Build'
run: cmake --build ${{ github.workspace }}/build --config Release --target FastNoiseBenchmark --parallel 4
- name: 'Upload artifact'
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.name }}-benchmark-bin
path: ${{ github.workspace }}/build/Release/bin/
if-no-files-found: error
- id: get-commit-msg
run: echo "msg=$(git log --format=%B -n 1 ${{ github.sha }})" >> "$env:GITHUB_OUTPUT"
shell: pwsh
- id: message-format-1
uses: ashley-taylor/regex-property-action@v1
with:
value: ${{ steps.get-commit-msg.outputs.msg }}
regex: "^\\s*|[^a-zA-Z0-9_&\\(\\) -]"
replacement: ""
- id: message-format
uses: ashley-taylor/regex-property-action@v1
with:
value: ${{ steps.message-format-1.outputs.value }}
regex: "(?<=.{50}).*"
replacement: ""
- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v2
with:
token: ${{ secrets.REPO_ACCESS_TOKEN }}
repository: Auburn/FastNoise2Benchmarking
event-type: benchmark
client-payload: '{"ref": "${{ github.ref }}", "sha": "${{ github.sha }}", "runid": "${{ github.run_id }}", "name": "${{ matrix.name }}", "msg": "${{ steps.message-format.outputs.value }}"}'
benchmarkbin-complete:
runs-on: ubuntu-latest
needs: benchmark-matrix
steps:
- run: echo benchmarkbin-complete