Skip to content

Commit bf9f3f9

Browse files
committed
Run core benchmarks with CodSpeed
1 parent cd12d51 commit bf9f3f9

File tree

1 file changed

+70
-0
lines changed

1 file changed

+70
-0
lines changed

.github/workflows/codspeed.yml

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
name: CodSpeed
19+
20+
concurrency:
21+
group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
22+
cancel-in-progress: true
23+
24+
on:
25+
push:
26+
branches-ignore:
27+
- 'gh-readonly-queue/**'
28+
paths-ignore:
29+
- "docs/**"
30+
- "**.md"
31+
- ".github/ISSUE_TEMPLATE/**"
32+
- ".github/pull_request_template.md"
33+
pull_request:
34+
paths-ignore:
35+
- "docs/**"
36+
- "**.md"
37+
- ".github/ISSUE_TEMPLATE/**"
38+
- ".github/pull_request_template.md"
39+
merge_group:
40+
# manual trigger
41+
# https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
42+
workflow_dispatch:
43+
44+
jobs:
45+
cargo_bench:
46+
name: cargo bench benchmarks
47+
runs-on: ubuntu-latest
48+
steps:
49+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
50+
- name: Rust Dependency Cache
51+
uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2.8.2
52+
with:
53+
shared-key: "amd-ci-codpseed"
54+
save-if: ${{ github.ref_name == 'main' }}
55+
- name: Setup codspeed
56+
run: cargo install cargo-codspeed
57+
- name: Download benchmark data
58+
run: benchmarks/bench.sh data clickbench_partitioned
59+
- name: Install codpseed-criterion-compat
60+
working-directory: datafusion/core
61+
run: cargo add --dev --rename criterion --features async_tokio,async_futures [email protected]
62+
- name: Build the benchmark targets
63+
working-directory: datafusion/core
64+
run: cargo codspeed build -j 2 --profile release-nonlto --bench sql_planner
65+
- name: Run the benchmarks
66+
uses: CodSpeedHQ/action@972e3437949c89e1357ebd1a2dbc852fcbc57245 # v4.5.1
67+
with:
68+
mode: simulation
69+
working-directory: datafusion/core
70+
run: cargo codspeed run

0 commit comments

Comments
 (0)