Skip to content

Commit

Permalink
fix CPUStorage
Browse files Browse the repository at this point in the history
  • Loading branch information
tgymnich committed Sep 26, 2024
1 parent 5616177 commit 8e6413e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/mps/linalg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ end
# Metal's pivoting sequence needs to be iterated sequentially...
# TODO: figure out a GPU-compatible way to get the permutation matrix
LinearAlgebra.ipiv2perm(v::MtlVector{T,S}, maxi::Integer) where {T,S} = LinearAlgebra.ipiv2perm(Array(v), maxi)
LinearAlgebra.ipiv2perm(v::MtlVector{T,S}, maxi::Integer) where {T,S<:CPUStorage} = LinearAlgebra.ipiv2perm(unsafe_wrap(Array, v), maxi)
LinearAlgebra.ipiv2perm(v::MtlVector{T,S}, maxi::Integer) where {T,S<:MTL.CPUStorage} = LinearAlgebra.ipiv2perm(unsafe_wrap(Array, v), maxi)

@autoreleasepool function LinearAlgebra.lu(A::MtlMatrix{T};
check::Bool=true) where {T<:MtlFloat}
Expand Down

0 comments on commit 8e6413e

Please sign in to comment.