From ebca1f409062372e115a90874b07a3fbe23f9902 Mon Sep 17 00:00:00 2001 From: Katharine Hyatt Date: Thu, 6 Aug 2026 12:30:24 -0400 Subject: [PATCH] Try simplied BK YAML and turn off generic tests on GPU --- .buildkite/pipeline.yml | 62 ++++++--------------- test/genericlinearalgebra/exponential.jl | 66 ++++++++++++----------- test/genericschur/exponential.jl | 68 +++++++++++++----------- 3 files changed, 87 insertions(+), 109 deletions(-) diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml index 11944ebb2..457d59ced 100644 --- a/.buildkite/pipeline.yml +++ b/.buildkite/pipeline.yml @@ -2,58 +2,28 @@ env: SECRET_CODECOV_TOKEN: "MH6hHjQi7vG2V1Yfotv5/z5Dkx1k5SdyGYlGTFXiQr22XksJgsXaBuvFKUrjC7JwcpBsOVU8103LuMKl3m7VJ35WzHZrOssYycVbdGcb2kloc6xvUOsN2R5BrhCQ4Pii0l6ZeVRjCnZVkcmb0Rf4glGFyfibCrqniry8RLhblsuFKFsijRK4OxiWYEs1IvUulN+ER8tEsEtw4+ZqC5nbLGMSnUG/saPkDQOVIBscvikbKEnBcCXBheGPktF+Y/cy/1Xa+FiBPoZcypwTeAjKG1g0MqyHXjaYekb/7fekaj+hukGaeJSCXxY8KEb2IZCh+Y36Tp6y6qsIp/AdtEnCpQ==;U2FsdGVkX18WQxvGLspPwzC4aDe+U7TXU+itebTbgh8LUkE6GukxxReHYiDZ6IrBiVvSGTVJMquW0c8KsOI1pw==" steps: - - label: "Julia v1 -- CUDA" + - label: "Julia {{matrix.julia}} -- {{matrix.queue}} / {{matrix.group}}" plugins: - JuliaCI/julia#v1: - version: "1" - - JuliaCI/julia-test#v1: ~ + version: "{{matrix.julia}}" + - JuliaCI/julia-test#v1: + test_args: "{{matrix.group}}" - JuliaCI/julia-coverage#v1: dirs: - src - ext agents: - queue: "cuda" - if: build.message !~ /\[skip tests\]/ - timeout_in_minutes: 30 - - - label: "Julia LTS -- CUDA" - plugins: - - JuliaCI/julia#v1: - version: "1.10" # "lts" isn't valid - - JuliaCI/julia-test#v1: ~ - - JuliaCI/julia-coverage#v1: - dirs: - - src - - ext - agents: - queue: "cuda" - if: build.message !~ /\[skip tests\]/ - timeout_in_minutes: 30 - - - label: "Julia v1 -- AMDGPU" - plugins: - - JuliaCI/julia#v1: - version: "1" - - JuliaCI/julia-test#v1: ~ - - JuliaCI/julia-coverage#v1: - dirs: - - src - - ext - agents: - queue: "rocm" - if: build.message !~ /\[skip tests\]/ - timeout_in_minutes: 30 - - - label: "Julia LTS -- AMDGPU" - plugins: - - JuliaCI/julia#v1: - version: "1.10" # "lts" isn't valid - - JuliaCI/julia-test#v1: ~ - - JuliaCI/julia-coverage#v1: - dirs: - - src - - ext - agents: - queue: "rocm" + queue: "{{matrix.queue}}" if: build.message !~ /\[skip tests\]/ timeout_in_minutes: 30 + matrix: + setup: + julia: + - "1.10" + - "1.12" + queue: + - "cuda" + - "rocm" + group: + - "decompositions" + - "mooncake" diff --git a/test/genericlinearalgebra/exponential.jl b/test/genericlinearalgebra/exponential.jl index 5743d3b4d..5ffdaa10b 100644 --- a/test/genericlinearalgebra/exponential.jl +++ b/test/genericlinearalgebra/exponential.jl @@ -6,41 +6,45 @@ using MatrixAlgebraKit: diagview using LinearAlgebra using GenericLinearAlgebra -GenericFloats = (BigFloat, Complex{BigFloat}) - -@testset "exponential! for T = $T" for T in GenericFloats - rng = StableRNG(123) - m = 54 - - A = project_hermitian!(randn(rng, T, m, m)) - D, V = @constinferred eigh_full(A) - algs = (MatrixFunctionViaEigh(GLA_QRIteration()),) - @testset "algorithm $alg" for alg in algs - expA = @constinferred exponential!(copy(A); alg) - expA2 = @constinferred exponential(A; alg) - @test expA2 ≈ expA - - Dexp, Vexp = @constinferred eigh_full(expA) - @test diagview(Dexp) ≈ LinearAlgebra.exp.(diagview(D)) +is_buildkite = get(ENV, "BUILDKITE", "false") == "true" + +if !is_buildkite + GenericFloats = (BigFloat, Complex{BigFloat}) + + @testset "exponential! for T = $T" for T in GenericFloats + rng = StableRNG(123) + m = 54 + + A = project_hermitian!(randn(rng, T, m, m)) + D, V = @constinferred eigh_full(A) + algs = (MatrixFunctionViaEigh(GLA_QRIteration()),) + @testset "algorithm $alg" for alg in algs + expA = @constinferred exponential!(copy(A); alg) + expA2 = @constinferred exponential(A; alg) + @test expA2 ≈ expA + + Dexp, Vexp = @constinferred eigh_full(expA) + @test diagview(Dexp) ≈ LinearAlgebra.exp.(diagview(D)) + end end -end -using GenericSchur -@testset "exponential! for T1 = $T1, T2 = $T2" for T1 in GenericFloats, T2 in GenericFloats - rng = StableRNG(123) - m = 54 - A = project_hermitian!(randn(rng, T1, m, m)) - τ = randn(rng, T2) + using GenericSchur + @testset "exponential! for T1 = $T1, T2 = $T2" for T1 in GenericFloats, T2 in GenericFloats + rng = StableRNG(123) + m = 54 + A = project_hermitian!(randn(rng, T1, m, m)) + τ = randn(rng, T2) - D, V = @constinferred eigh_full(A) - algs = (MatrixFunctionViaEigh(GLA_QRIteration()),) - @testset "algorithm $alg" for alg in algs - expτA = @constinferred exponential!((τ, copy(A)); alg) - expτA2 = @constinferred exponential((τ, A); alg) - @test expτA2 ≈ expτA + D, V = @constinferred eigh_full(A) + algs = (MatrixFunctionViaEigh(GLA_QRIteration()),) + @testset "algorithm $alg" for alg in algs + expτA = @constinferred exponential!((τ, copy(A)); alg) + expτA2 = @constinferred exponential((τ, A); alg) + @test expτA2 ≈ expτA - Dexp, Vexp = @constinferred eig_full(expτA) + Dexp, Vexp = @constinferred eig_full(expτA) - @test sort(diagview(Dexp); by = real) ≈ sort(LinearAlgebra.exp.(diagview(D) .* τ); by = real) + @test sort(diagview(Dexp); by = real) ≈ sort(LinearAlgebra.exp.(diagview(D) .* τ); by = real) + end end end diff --git a/test/genericschur/exponential.jl b/test/genericschur/exponential.jl index e2d26e2bd..7754e02c7 100644 --- a/test/genericschur/exponential.jl +++ b/test/genericschur/exponential.jl @@ -6,42 +6,46 @@ using MatrixAlgebraKit: diagview using LinearAlgebra using GenericSchur -GenericFloats = (BigFloat, Complex{BigFloat}) - -@testset "exponential! for T = $T" for T in GenericFloats - rng = StableRNG(123) - m = 54 - - A = randn(rng, T, m, m) - D, V = @constinferred eig_full(A) - algs = (MatrixFunctionViaEig(GS_QRIteration()),) - expA_LA = @constinferred exponential(A) - @testset "algorithm $alg" for alg in algs - expA = @constinferred exponential!(copy(A)) - expA2 = @constinferred exponential(A; alg = alg) - @test expA ≈ expA_LA - @test expA2 ≈ expA - - Dexp, Vexp = @constinferred eig_full(expA) - @test sort(diagview(Dexp); by = imag) ≈ sort(LinearAlgebra.exp.(diagview(D)); by = imag) +is_buildkite = get(ENV, "BUILDKITE", "false") == "true" + +if !is_buildkite + GenericFloats = (BigFloat, Complex{BigFloat}) + + @testset "exponential! for T = $T" for T in GenericFloats + rng = StableRNG(123) + m = 54 + + A = randn(rng, T, m, m) + D, V = @constinferred eig_full(A) + algs = (MatrixFunctionViaEig(GS_QRIteration()),) + expA_LA = @constinferred exponential(A) + @testset "algorithm $alg" for alg in algs + expA = @constinferred exponential!(copy(A)) + expA2 = @constinferred exponential(A; alg = alg) + @test expA ≈ expA_LA + @test expA2 ≈ expA + + Dexp, Vexp = @constinferred eig_full(expA) + @test sort(diagview(Dexp); by = imag) ≈ sort(LinearAlgebra.exp.(diagview(D)); by = imag) + end end -end -@testset "exponential! for T1 = $T1, T2 = $T2" for T1 in GenericFloats, T2 in GenericFloats - rng = StableRNG(123) - m = 54 + @testset "exponential! for T1 = $T1, T2 = $T2" for T1 in GenericFloats, T2 in GenericFloats + rng = StableRNG(123) + m = 54 - A = randn(rng, T1, m, m) - τ = randn(rng, T2) + A = randn(rng, T1, m, m) + τ = randn(rng, T2) - D, V = @constinferred eig_full(A) - algs = (MatrixFunctionViaEig(GS_QRIteration()),) - @testset "algorithm $alg" for alg in algs - expτA = @constinferred exponential!((τ, copy(A))) - expτA2 = @constinferred exponential((τ, A); alg) - @test expτA2 ≈ expτA + D, V = @constinferred eig_full(A) + algs = (MatrixFunctionViaEig(GS_QRIteration()),) + @testset "algorithm $alg" for alg in algs + expτA = @constinferred exponential!((τ, copy(A))) + expτA2 = @constinferred exponential((τ, A); alg) + @test expτA2 ≈ expτA - Dexp, Vexp = @constinferred eig_full(expτA) - @test sort(diagview(Dexp); by = x -> (imag(x), real(x))) ≈ sort(LinearAlgebra.exp.(diagview(D) .* τ); by = x -> (imag(x), real(x))) + Dexp, Vexp = @constinferred eig_full(expτA) + @test sort(diagview(Dexp); by = x -> (imag(x), real(x))) ≈ sort(LinearAlgebra.exp.(diagview(D) .* τ); by = x -> (imag(x), real(x))) + end end end