JuliaGPU / JuliaGPU/KernelAbstractions.jl
StackOverflow for `get_device` on `ROCArray`
Nobody has claimed this yet.
- Dominant language
- Julia
- Stars
- 523
- Forks
- 88
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 25
Description
julia> a = ROCArray(rand(10,10));
julia> KernelAbstractions.get_device(a)
ERROR: StackOverflowError:
Stacktrace:
[1] get_device(A::ROCMatrix{Float64}) (repeats 79984 times)
@ KernelAbstractions ~/.julia/packages/KernelAbstractions/DqITC/src/KernelAbstractions.jl:355
Calling AMDGPU.device(a) works:
julia> AMDGPU.device(a)
GPU-XX [AMD Radeon RX 6700 XT (gfx1030)]
So maybe there's a way to get rid of one layer of abstraction here?
As a note:
julia> b = Array(rand(10,10));
julia> KernelAbstractions.get_device(b)
CPU()
So shouldn't we be returning ROCdevice() instead of GPU-XX [AMD Radeon RX 6700 XT (gfx1030)]? Or was there something about the recent change with how ROCDevice() that changes things?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the ROCArray example and inspect get_device at src/KernelAbstractions.jl:355, comparing its dispatch with AMDGPU.device(a) and the working Array case. Determine the intended device abstraction for ROCArray, then verify that get_device no longer recurses and returns the expected device type.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- julia
- Domain
- hpc
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100