Skip to content

Commit 591f603

Browse files
Fix LAPACK vendor detection for Julia version compatibility
Add try-catch block around LinearAlgebra.LAPACK.vendor() call since this function doesn't exist in all Julia versions. Falls back to using BLAS vendor as LAPACK vendor when not available. Fixes UndefVarError: vendor not defined in LinearAlgebra.LAPACK in gpu_detection.jl:143 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent c6549ef commit 591f603

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

lib/LinearSolveAutotune/src/gpu_detection.jl

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,13 @@ function get_detailed_system_info()
140140

141141
# BLAS and linear algebra libraries
142142
system_data["blas_vendor"] = string(LinearAlgebra.BLAS.vendor())
143-
system_data["lapack_vendor"] = string(LinearAlgebra.LAPACK.vendor())
143+
# LAPACK vendor detection (safe for different Julia versions)
144+
try
145+
system_data["lapack_vendor"] = string(LinearAlgebra.LAPACK.vendor())
146+
catch
147+
# Fallback: LAPACK vendor often matches BLAS vendor
148+
system_data["lapack_vendor"] = system_data["blas_vendor"]
149+
end
144150
system_data["blas_num_threads"] = LinearAlgebra.BLAS.get_num_threads()
145151

146152
# LinearSolve-specific package availability

0 commit comments

Comments
 (0)