Skip to content

Commit 771e2f5

Browse files
authored
ci: simplify codspeed sharding (#5572)
Signed-off-by: Alexander Droste <[email protected]>
1 parent fec90ce commit 771e2f5

File tree

1 file changed

+12
-90
lines changed

1 file changed

+12
-90
lines changed

.github/workflows/ci.yml

Lines changed: 12 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -472,15 +472,23 @@ jobs:
472472
bench-codspeed:
473473
strategy:
474474
matrix:
475-
shard: [1, 2, 3, 4, 5, 6, 7, 8]
475+
include:
476+
- { shard: 1, name: "Core foundation", packages: "vortex-buffer vortex-dtype vortex-error" }
477+
- { shard: 2, name: "Array types", packages: "vortex-array vortex-scalar vortex-vector", features: "--features test-harness" }
478+
- { shard: 3, name: "Main library", packages: "vortex vortex-compute" }
479+
- { shard: 4, name: "Encodings 1", packages: "vortex-alp vortex-bytebool vortex-datetime-parts" }
480+
- { shard: 5, name: "Encodings 2", packages: "vortex-decimal-byte-parts vortex-fastlanes vortex-fsst", features: "--features test-harness" }
481+
- { shard: 6, name: "Encodings 3", packages: "vortex-pco vortex-runend vortex-sequence" }
482+
- { shard: 7, name: "Encodings 4", packages: "vortex-sparse vortex-zigzag vortex-zstd" }
483+
- { shard: 8, name: "Storage formats", packages: "vortex-flatbuffers vortex-proto vortex-btrblocks" }
476484
name: "Benchmark with Codspeed (Shard #${{ matrix.shard }})"
477485
timeout-minutes: 120
478486
runs-on:
479487
- runs-on=${{ github.run_id }}
480488
- family=c6id.8xlarge
481489
- extras=s3-cache
482490
- image=ubuntu24-full-x64
483-
- tag=bench-codspeed-${{matrix.shard}}
491+
- tag=bench-codspeed-${{ matrix.shard }}
484492
steps:
485493
- uses: runs-on/action@v2
486494
with:
@@ -489,98 +497,12 @@ jobs:
489497
- uses: ./.github/actions/setup-rust
490498
with:
491499
repo-token: ${{ secrets.GITHUB_TOKEN }}
492-
493500
- name: Install Codspeed
494-
shell: bash
495501
run: cargo install --force cargo-codspeed --locked
496-
497-
- name: Build benchmarks (shard 1 - Core foundation)
498-
env:
499-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
500-
if: ${{ matrix.shard == 1 }}
501-
run: |
502-
cargo codspeed build \
503-
-p vortex-buffer \
504-
-p vortex-dtype \
505-
-p vortex-error \
506-
--profile bench
507-
508-
- name: Build benchmarks (shard 2 - Array types)
509-
env:
510-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
511-
if: ${{ matrix.shard == 2 }}
512-
run: |
513-
cargo codspeed build --features test-harness \
514-
-p vortex-array \
515-
-p vortex-scalar \
516-
-p vortex-vector \
517-
--profile bench
518-
519-
- name: Build benchmarks (shard 3 - Main library)
520-
env:
521-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
522-
if: ${{ matrix.shard == 3 }}
523-
run: |
524-
cargo codspeed build \
525-
-p vortex \
526-
-p vortex-compute \
527-
--profile bench
528-
529-
- name: Build benchmarks (shard 4 - Encodings 1)
530-
env:
531-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
532-
if: ${{ matrix.shard == 4 }}
533-
run: |
534-
cargo codspeed build \
535-
-p vortex-alp \
536-
-p vortex-bytebool \
537-
-p vortex-datetime-parts \
538-
--profile bench
539-
540-
- name: Build benchmarks (shard 5 - Encodings 2)
502+
- name: Build benchmarks
541503
env:
542504
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
543-
if: ${{ matrix.shard == 5 }}
544-
run: |
545-
cargo codspeed build --features test-harness \
546-
-p vortex-decimal-byte-parts \
547-
-p vortex-fastlanes \
548-
-p vortex-fsst \
549-
--profile bench
550-
551-
- name: Build benchmarks (shard 6 - Encodings 3)
552-
env:
553-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
554-
if: ${{ matrix.shard == 6 }}
555-
run: |
556-
cargo codspeed build \
557-
-p vortex-pco \
558-
-p vortex-runend \
559-
-p vortex-sequence \
560-
--profile bench
561-
562-
- name: Build benchmarks (shard 7 - Encodings 4)
563-
env:
564-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
565-
if: ${{ matrix.shard == 7 }}
566-
run: |
567-
cargo codspeed build \
568-
-p vortex-sparse \
569-
-p vortex-zigzag \
570-
-p vortex-zstd \
571-
--profile bench
572-
573-
- name: Build benchmarks (shard 8 - Storage formats)
574-
env:
575-
RUSTFLAGS: "-C target-feature=+avx2 -C debug-assertions=yes"
576-
if: ${{ matrix.shard == 8 }}
577-
run: |
578-
cargo codspeed build \
579-
-p vortex-flatbuffers \
580-
-p vortex-proto \
581-
-p vortex-btrblocks \
582-
--profile bench
583-
505+
run: cargo codspeed build ${{ matrix.features }} $(printf -- '-p %s ' ${{ matrix.packages }}) --profile bench
584506
- name: Run benchmarks
585507
uses: CodSpeedHQ/action@346a2d8a8d9d38909abd0bc3d23f773110f076ad
586508
with:

0 commit comments

Comments
 (0)