From 58f1f9eae9125bf025918fde975d69511b2f5fd4 Mon Sep 17 00:00:00 2001 From: Erik Faulhaber <44124897+efaulhaber@users.noreply.github.com> Date: Sun, 25 May 2025 19:19:14 +0200 Subject: [PATCH 1/2] Make tests run on Metal --- test/examples/gpu.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/examples/gpu.jl b/test/examples/gpu.jl index c99c67f13..2242fc10c 100644 --- a/test/examples/gpu.jl +++ b/test/examples/gpu.jl @@ -135,7 +135,7 @@ end cell_list), parallelization_backend=Main.parallelization_backend) - # Note that this simulation only takes 42 time steps on the CPU. + # TODO Note that this simulation only takes 42 time steps on the CPU. # Due to https://github.com/JuliaGPU/Metal.jl/issues/549, it doesn't work on Metal. trixi_include_changeprecision(Float32, @__MODULE__, joinpath(examples_dir(), "fluid", @@ -143,7 +143,7 @@ end tspan=(0.0f0, 0.1f0), fluid_particle_spacing=0.1, semi=semi_fullgrid, - maxiters=42) + maxiters=43) @test sol.retcode == ReturnCode.Success backend = TrixiParticles.KernelAbstractions.get_backend(sol.u[end].x[1]) @test backend == Main.parallelization_backend From 720d7f0d1878858025a478293d9ec858b41eed9d Mon Sep 17 00:00:00 2001 From: Erik Faulhaber <44124897+efaulhaber@users.noreply.github.com> Date: Wed, 28 May 2025 11:12:52 +0200 Subject: [PATCH 2/2] Update comments --- test/examples/gpu.jl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/examples/gpu.jl b/test/examples/gpu.jl index 2242fc10c..7aca5f83d 100644 --- a/test/examples/gpu.jl +++ b/test/examples/gpu.jl @@ -135,8 +135,9 @@ end cell_list), parallelization_backend=Main.parallelization_backend) - # TODO Note that this simulation only takes 42 time steps on the CPU. - # Due to https://github.com/JuliaGPU/Metal.jl/issues/549, it doesn't work on Metal. + # Note that this simulation only takes 42 time steps on the CPU. + # TODO This takes 43 time steps on Metal. + # Maybe related to https://github.com/JuliaGPU/Metal.jl/issues/549 trixi_include_changeprecision(Float32, @__MODULE__, joinpath(examples_dir(), "fluid", "dam_break_3d.jl"),