Repository navigation
docs: the bidiagonalisation parallel hint is not dropped (DROPPED experiment) - #11
Merged
Merged
Conversation
shinaoka
force-pushed
the
perf/bidiag-par
branch
from
October 14, 2026 03:33
ac7811b to
9309ec2
Compare
…eriment The lead the compact-factor region-floor record left unverified was that `bidiag_in_place_scratch` discards its hint (`_ = par; _ = params;`) and that `BidiagParams::par_threshold` is never read, so the bidiagonalisation is sequential however the caller calls it. Only the scratch-size function ignores the hint, and correctly -- the workspace is shape-sized, not thread-sized. The worker, `bidiag_in_place`, reads the threshold on every column and forwards `par` into the trailing update. Isolation, `bidiag_in_place` at f64/c64, CPUs 0-3, best of 7, interleaved A/B: the floor makes 128x128 fully sequential (Seq and rayon(8) both 0.319 ms f64), threading 256x256 is 4.7% slower (2.223 -> 2.328), and only 512x512 pays. It is load-bearing: removing the gate costs 2.50x (f64) / 1.77x (c64) at 128x128 and 1.44x at 256x256. Keeping the caller's hint for the two trailing `upgrade_householder_factor` calls, which the latch starves, moves no row by more than 6%. No code change. The ledger row is DROPPED and the record carries the numbers that dropped both candidates.
shinaoka
force-pushed
the
perf/bidiag-par
branch
from
October 14, 2026 03:33
9309ec2 to
c71811f
Compare
The same re-reading that closed the bidiagonalisation lead applies to `evd/tridiag.rs`: the scratch function's ignored hint is workspace sizing, and `tridiag_in_place` reads `params.par_threshold` and latches to `Par::Seq` below it, which at 128x128 closes the whole factorisation. The flat `eigh` reading is this library's floor, not a missing hint; whether the floor is set where it should be is a measurement, not a reading.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes the lead left unverified in
docs/worklogs/2026-10-14-compact-factor-region-floor.md:that
bidiag_in_place_scratch's_ = par; _ = params;and an unreadBidiagParams::par_thresholdmake the bidiagonalisation sequential however thecaller calls it. Only the scratch-size function ignores the hint, and correctly
(the workspace is shape-sized, not thread-sized). The worker
bidiag_in_placereads the threshold on every column and forwards
parinto the trailing update.No code change. Measured, and the two candidates that lost with their numbers:
bidiag_in_placeat128x128, 1.44x at 256x256, 1.08-1.12x at 512x512; end to end 1.81x
(
svd_values) / 1.52x (svd_thin) at 128x128.upgrade_householder_factorcalls that the latch starves moves no row by more than 6%.
Isolation:
bidiag_in_placeandlinalg::svd::svd, f64/c64, 128/256/512 squareplus 1024x64 and 4096x256, CPUs 0-3 (the four free cores),
RAYON_NUM_THREADS=8,best of 7, interleaved A/B.
Record:
docs/worklogs/2026-10-14-bidiag-parallel-hint.md. Ledger rowBidiagonalisation parallel hint(DROPPED).Gate:
cargo test -p t4a-faer --lib— 203 passed, 0 failed, 2 ignored.sparse::linalg::qr::tests::test_numeric_simplicial_qr_1_transposepasses here(five reruns), so the failure recorded in the earlier worklog did not reproduce on
9de95f7.