Skip to content

Separate Algorithm and Driver - part II (SVD)#189

Merged
lkdvos merged 20 commits intomainfrom
ld-algmerge2
Mar 18, 2026
Merged

Separate Algorithm and Driver - part II (SVD)#189
lkdvos merged 20 commits intomainfrom
ld-algmerge2

Conversation

@lkdvos
Copy link
Member

@lkdvos lkdvos commented Mar 16, 2026

Follow-up on #178 to improve on #176.

This consists of quite a few more opinionated changes that I think are warranted but might not be completely fair.

I have renamed a bunch of the LAPACK-like functions across YALAPACK/YAROCSOLVER/YACUSOLVER in an attempt to make life slightly easier, and simply merge all of the implementations into a single big @eval loop.

In the meantime, I also changed the GLA implementations to actually copy in-place, as this is something that has come up quite a few times already and I think overall this is probably more convenient anyways.

The jacobi-svd algorithm that only worked for LAPACK with m >= n is now also implemented for m < n by making use of the same svd_via_adjoint pattern that was already present in some of the GPU solvers, which is now also shared.


I think overall this manages to delete quite a bit of code, but the eval loops are also somewhat hard to follow so I'm not sure if this is all that much "simpler" implementation-wise, but at least it does allow selecting DivideAndConquer in a driver-agnostic way.

@lkdvos lkdvos force-pushed the ld-algmerge2 branch 2 times, most recently from 30844a2 to b2059b9 Compare March 17, 2026 14:37
Copy link
Member

@Jutho Jutho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some suggestions but otherwise looks great.

@lkdvos
Copy link
Member Author

lkdvos commented Mar 17, 2026

@kshyatt I think this one is good to go, only CUDA seems to somehow go out of memory and I'm confused why this is only now happening. I reduced the sizes a bit, but if this doesn't end up helping I might just call this unrelated to this PR and we should go ahead with merging this one.

@leburgel leburgel added the documentation Improvements or additions to documentation label Mar 18, 2026
@github-actions
Copy link

After the build completes, the updated documentation will be available here

@lkdvos lkdvos enabled auto-merge (squash) March 18, 2026 12:55
@lkdvos lkdvos merged commit cb7e825 into main Mar 18, 2026
9 checks passed
@lkdvos lkdvos deleted the ld-algmerge2 branch March 18, 2026 13:32
@codecov
Copy link

codecov bot commented Mar 18, 2026

Codecov Report

❌ Patch coverage is 90.83333% with 11 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/algorithms.jl 44.44% 5 Missing ⚠️
src/implementations/svd.jl 92.85% 4 Missing ⚠️
...ixAlgebraKitAMDGPUExt/MatrixAlgebraKitAMDGPUExt.jl 92.85% 1 Missing ⚠️
src/interface/svd.jl 50.00% 1 Missing ⚠️
Files with missing lines Coverage Δ
...MatrixAlgebraKitCUDAExt/MatrixAlgebraKitCUDAExt.jl 74.13% <100.00%> (+4.13%) ⬆️
ext/MatrixAlgebraKitCUDAExt/yacusolver.jl 96.12% <100.00%> (+0.37%) ⬆️
ext/MatrixAlgebraKitGenericLinearAlgebraExt.jl 84.84% <100.00%> (-1.07%) ⬇️
src/MatrixAlgebraKit.jl 100.00% <ø> (ø)
src/common/defaults.jl 64.28% <ø> (ø)
src/common/gauge.jl 100.00% <100.00%> (ø)
src/implementations/lq.jl 95.06% <ø> (ø)
src/implementations/qr.jl 95.08% <ø> (ø)
src/interface/decompositions.jl 76.19% <ø> (+5.82%) ⬆️
src/yalapack.jl 85.37% <100.00%> (ø)
... and 4 more

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants