Skip to content

Commit 003d3b6

Browse files
connortsui20claude
andcommitted
Build benchmarks with whole-program optimization
Progress towards #9128. `profile.bench` used `codegen-units = 16` with no LTO. Under those settings, adding unrelated code to a crate reshuffles which functions share a codegen unit, which changes cross-unit inlining for functions whose source did not change. Adding the row framework to `vortex-array` moved several untouched list benchmarks by 14-16% that way, none of which have a source change on this branch. `codegen-units = 1` with fat LTO removes that variable, so a measured change is attributable to the change under test. This is branch-only and it invalidates comparison against a `develop` baseline built with the old settings. Compare two revisions that both carry this profile. Signed-off-by: Connor Tsui <[email protected]> Co-authored-by: Claude <[email protected]>
1 parent 6a468fd commit 003d3b6

1 file changed

Lines changed: 10 additions & 2 deletions

File tree

‎Cargo.toml‎

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -415,9 +415,17 @@ debug = "full"
415415
inherits = "release"
416416

417417
[profile.bench]
418-
codegen-units = 16
418+
# Branch-only: `develop` builds benchmarks with `codegen-units = 16` and no LTO, which lets the
419+
# addition of unrelated code to a crate reshuffle its codegen units and change cross-unit inlining
420+
# for functions whose source did not change. Adding the row framework to `vortex-array` moved
421+
# several untouched list benchmarks by 14-16% that way. Whole-program optimization removes that
422+
# variable, so a measured change is attributable to the change under test.
423+
#
424+
# This makes a CodSpeed comparison against a `develop` baseline built with the old settings
425+
# meaningless. Compare two revisions that both carry this profile.
426+
codegen-units = 1
419427
debug = "full"
420-
lto = false
428+
lto = true
421429

422430
[profile.samply]
423431
inherits = "release"

0 commit comments

Comments
 (0)