JuliaGPU / JuliaGPU/GPUArrays.jl

Abstract type aliases do not match expected types

Open
#529 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Julia
Stars
450
Forks
104
Avg merge
1d 4h
Merged PRs (30d)
10

Description

For example, `AbstractGPUVecOrMat`:

```julia
julia> LinearAlgebra.Adjoint{Float64, Matrix{Float64}} <: AbstractVecOrMat
true

julia> LinearAlgebra.Adjoint{Float64, CuMatrix{Float64}} <: GPUArrays.AbstractGPUVecOrMat
false
```

... because `Adjoint` is `<: AbstractArray` but not `<: AbstractGPUArray`. This is bad, because it breaks a bunch of generic code, e.g., https://github.com/JuliaLang/julia/pull/53611#issuecomment-2045278635.

I guess this is https://github.com/JuliaLang/julia/issues/51910, however we probably need a different fix in the short term.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the AbstractGPUVecOrMat and AbstractGPUArray behavior shown in the issue, then review Julia issue #51910 and the linked Julia pull request discussion. Determine a short-term fix for the mismatch involving LinearAlgebra.Adjoint and verify that the affected generic code recognizes the expected types.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.