KernelAbstractions.jl
KernelAbstractions.jl copied to clipboard
1.11: reduce_private test generates gcframe under --check-bounds=yes
MWE, reduced from the tests:
using KernelAbstractions
@kernel function reduce_private(out, A)
I = @index(Global, NTuple)
i = @index(Local)
priv = @private eltype(A) (1,)
@inbounds begin
priv[1] = zero(eltype(A))
for k in 1:size(A, ndims(A))
priv[1] += A[I..., k]
end
out[I...] = priv[1]
end
end
KernelAbstractions.ka_code_llvm(
reduce_private(CPU(), (8,)), Tuple{Array{Float64, 1}, Array{Float64, 2}},
optimize=true, ndrange = (64,), debuginfo=:none
)
This generates a gcframe (the absence of which is being tested) when running on 1.11 under --check-bounds=yes, as done by Pkg.