Skip to content

Copy States Optimization #371

Copy States Optimization

Copy States Optimization #371

Workflow file for this run

name: Run benchmarks
on:
pull_request:
paths:
- '.github/workflows/benchmark.yml'
- 'benchmark/**'
- 'src/**'
# Benchmarks include this file
- 'test/models/llw2d.jl'
workflow_dispatch:
concurrency:
# Skip intermediate builds: always.
# Cancel intermediate builds: always.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
# needed to allow julia-actions/cache to delete old caches that it has created
actions: write
contents: read
# Needed to post a custom job status when pushing the results to a branch
statuses: write
jobs:
benchmark:
timeout-minutes: 90
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: julia-actions/setup-julia@v2
with:
version: '1.11.7'
- uses: julia-actions/cache@v2
id: julia-cache
with:
cache-name: "benchmarks"
- name: Install dependencies
shell: julia --color=yes {0}
run: |
using Pkg
Pkg.instantiate()
pkg"add PkgBenchmark [email protected]"
- name: Run benchmarks
shell: julia --color=yes {0}
run: |
using PkgBenchmark, BenchmarkCI
BenchmarkCI.judge(
PkgBenchmark.BenchmarkConfig(
env = Dict(
"JULIA_NUM_THREADS" => "2",
),
),
"origin/main",
)
- name: Print judgement
shell: julia --color=yes {0}
run: |
using BenchmarkCI
BenchmarkCI.displayjudgement()
- name: Push results
shell: julia --color=yes {0}
run: |
using BenchmarkCI
BenchmarkCI.pushresult(;
url = "[email protected]:Team-RADDISH/ParticleDA.jl.git",
)
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SSH_KEY: ${{ secrets.DOCUMENTER_KEY }}
- uses: actions/upload-artifact@v4
with:
name: tune-json
path: |
**/tune.json
- name: Save Julia depot cache on cancel or failure
id: julia-cache-save
if: cancelled() || failure()
uses: actions/cache/save@v4
with:
path: |
${{ steps.julia-cache.outputs.cache-paths }}
key: ${{ steps.julia-cache.outputs.cache-key }}