Skip to content

Commit d8cf28c

Browse files
committed
Add the check for gesvdx too
1 parent 68132de commit d8cf28c

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎ext/MatrixAlgebraKitAMDGPUExt/yarocsolver.jl‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,7 @@ for (fname, elty, relty) in
234234
S::StridedROCVector{$relty} = similar(A, $relty, min(size(A)...)),
235235
U::StridedROCMatrix{$elty} = similar(A, $elty, size(A, 1), min(size(A)...)),
236236
Vᴴ::StridedROCMatrix{$elty} = similar(A, $elty, min(size(A)...), size(A, 2));
237+
check::Bool = CHECK_LIBRARY_CALLS[],
237238
kwargs...
238239
)
239240
chkstride1(A, U, Vᴴ, S)
@@ -258,8 +259,10 @@ for (fname, elty, relty) in
258259
S, U, ldu, Vᴴ, ldv, ifail,
259260
dev_info
260261
)
261-
info = @allowscalar dev_info[1]
262-
rocSOLVER.chkargsok(BlasInt(info))
262+
if check
263+
info = @allowscalar dev_info[1]
264+
rocSOLVER.chkargsok(BlasInt(info))
265+
end
263266
# Zero the entries of `S` that `gesvdx` did not write.
264267
nv = @allowscalar Int(nsv[1])
265268
nv < length(S) && fill!(view(S, (nv + 1):length(S)), zero(eltype(S)))

0 commit comments

Comments
 (0)