diff --git a/ext/AMDGPU/blockjacobi.jl b/ext/AMDGPU/blockjacobi.jl index b43780a..1d27d46 100644 --- a/ext/AMDGPU/blockjacobi.jl +++ b/ext/AMDGPU/blockjacobi.jl @@ -1,7 +1,7 @@ KP.BlockJacobiPreconditioner(J::rocSPARSE.ROCSparseMatrixCSR; options...) = BlockJacobiPreconditioner(SparseMatrixCSC(J); options...) function KP.create_blocklist(cublocks::ROCArray, npart) - blocklist = Array{CuArray{Float64,2}}(undef, npart) + blocklist = Array{ROCArray{Float64,2}}(undef, npart) for b in 1:npart blocklist[b] = ROCMatrix{Float64}(undef, size(cublocks,1), size(cublocks,2)) end diff --git a/ext/AMDGPU/ilu0.jl b/ext/AMDGPU/ilu0.jl index cc5d6a8..89af844 100644 --- a/ext/AMDGPU/ilu0.jl +++ b/ext/AMDGPU/ilu0.jl @@ -27,8 +27,8 @@ for ArrayType in (:(ROCVector{T}), :(ROCMatrix{T})) end function ldiv!(ilu::AMD_ILU0{ROCSparseMatrixCSC{T,Cint}}, x::$ArrayType) where T <: BlasReal - ldiv!(LowerTriangular(ilu.P), y) # Forward substitution with L - ldiv!(UnitUpperTriangular(ilu.P), y) # Backward substitution with U + ldiv!(LowerTriangular(ilu.P), x) # Forward substitution with L + ldiv!(UnitUpperTriangular(ilu.P), x) # Backward substitution with U return x end