From 308a2cd8e07e86d15bb810ec83f78a2ccfedb64e Mon Sep 17 00:00:00 2001 From: Christian Guinard <28689358+christiangnrd@users.noreply.github.com> Date: Tue, 5 Aug 2025 18:31:22 -0300 Subject: [PATCH 1/2] Benchmark reverse on bigger arrays --- perf/array.jl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/perf/array.jl b/perf/array.jl index 65baa304dd..3dbab9816c 100644 --- a/perf/array.jl +++ b/perf/array.jl @@ -52,9 +52,13 @@ end let group = addgroup!(group, "reverse") group["1d"] = @async_benchmarkable reverse($gpu_vec) + group["1dL"] = @async_benchmarkable reverse($gpu_vec_long) group["2d"] = @async_benchmarkable reverse($gpu_mat; dims=1) + group["2dL"] = @async_benchmarkable reverse($gpu_mat_long; dims=1) group["1d_inplace"] = @async_benchmarkable reverse!($gpu_vec) + group["1dL_inplace"] = @async_benchmarkable reverse!($gpu_vec_long) group["2d_inplace"] = @async_benchmarkable reverse!($gpu_mat; dims=1) + group["2dL_inplace"] = @async_benchmarkable reverse!($gpu_mat_long; dims=2) end group["broadcast"] = @async_benchmarkable $gpu_mat .= 0f0 From 7c005dfd96af5954b8fc3ecd71a8a8ba997d8187 Mon Sep 17 00:00:00 2001 From: Christian Guinard <28689358+christiangnrd@users.noreply.github.com> Date: Thu, 7 Aug 2025 11:49:24 -0300 Subject: [PATCH 2/2] Fix new reverse benchmarks by adding `gpu_vec_long` --- perf/array.jl | 1 + 1 file changed, 1 insertion(+) diff --git a/perf/array.jl b/perf/array.jl index 3dbab9816c..30348a5120 100644 --- a/perf/array.jl +++ b/perf/array.jl @@ -10,6 +10,7 @@ cpu_mat = rand(rng, Float32, m, n) gpu_mat = CuArray{Float32}(cpu_mat) gpu_mat_long = CuArray{Float32}(rand(rng, Float32, m_long, n_long)) gpu_vec = reshape(gpu_mat, length(gpu_mat)) +gpu_vec_long = reshape(gpu_mat_long, length(gpu_mat_long)) gpu_arr_3d = reshape(gpu_mat, (m, 40, 25)) gpu_arr_4d = reshape(gpu_mat, (m, 10, 10, 10)) gpu_mat_ints = CuArray(rand(rng, -10:10, m, n))