Skip to content

Commit 016b6c7

Browse files
committed
removing heuristic
1 parent 1b71726 commit 016b6c7

File tree

1 file changed

+0
-18
lines changed

1 file changed

+0
-18
lines changed

src/gpuarrays.jl

-18
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,6 @@ import KernelAbstractions: Backend
1010

1111
## execution
1212

13-
@inline function GPUArrays.launch_heuristic(::oneAPIBackend, obj::O, args::Vararg{Any,N};
14-
elements::Int, elements_per_thread::Int) where {O,N}
15-
ndrange = ceil(Int, elements / elements_per_thread)
16-
ndrange, workgroupsize, iterspace, dynamic = KA.launch_config(obj, ndrange,
17-
nothing)
18-
19-
# this might not be the final context, since we may tune the workgroupsize
20-
ctx = KA.mkcontext(obj, ndrange, iterspace)
21-
22-
kernel = @oneapi launch=false obj.f(ctx, args...)
23-
24-
items = launch_configuration(kernel)
25-
# XXX: how many groups is a good number? the API doesn't tell us.
26-
# measured on a low-end IGP, 32 blocks seems like a good sweet spot.
27-
# note that this only matters for grid-stride kernels, like broadcast.
28-
return (threads=items, blocks=32)
29-
end
30-
3113
const GLOBAL_RNGs = Dict{ZeDevice,GPUArrays.RNG}()
3214
function GPUArrays.default_rng(::Type{<:oneArray})
3315
dev = device()

0 commit comments

Comments
 (0)