GPUArrays.jl icon indicating copy to clipboard operation
GPUArrays.jl copied to clipboard

`Hermitian()` wrapper missing a GPU compatible iterator

Open abussy opened this issue 8 months ago • 1 comments

The following reproducer code fails with LoadError: Scalar indexing is disallowed.:

using CUDA
using LinearAlgebra

A = CuArray(ones(Float32, 5, 5))

# This works
any(isnan, Symmetric(A))

# This does not
any(isnan, Hermitian(A))

It seems that some underlying function call tries explicit element access with the Hermitian() wrapper, but not with Symmetric(). I am not 100% sure whether that issue belongs here or in LinearAlgebra.

I get this issue with Julia version 1.10.8 (LTS) and 1.11.3 (current stable).

abussy avatar Feb 07 '25 16:02 abussy