Skip to content

Commit

Permalink
add missing LinearAlgebra.dot(::GPUArray, ::GPUComponentArray)
Browse files Browse the repository at this point in the history
  • Loading branch information
vpuri3 authored Oct 24, 2023
1 parent df9bd66 commit d4d2a3b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ext/ComponentArraysGPUArraysExt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ function Base.fill!(A::GPUComponentArray{T}, x) where {T}
end

LinearAlgebra.dot(x::GPUComponentArray, y::GPUComponentArray) = dot(getdata(x), getdata(y))
LinearAlgebra.dot(x::GPUComponentArray, y::AbstractGPUArray) = dot(getdata(x), y)
LinearAlgebra.dot(x::AbstractGPUArray, y::GPUComponentArray) = dot(x, getdata(y))

LinearAlgebra.norm(ca::GPUComponentArray, p::Real) = norm(getdata(ca), p)
LinearAlgebra.rmul!(ca::GPUComponentArray, b::Number) = GPUArrays.generic_rmul!(ca, b)

Expand Down

0 comments on commit d4d2a3b

Please sign in to comment.