TrixiParticles.jl
TrixiParticles.jl copied to clipboard
Road to TrixiParticles.jl on GPUs
- [x] Make array types in structs generic. Change types like
Array{ELTYPE, 2}to type parameters. #486 - [x] Recursively convert (adapt)
Semidiscretizationobject to GPU types with Adapt.jl. #492 - [x] #532
- [x] #533
- [x] Minimally invasive working GPU implementation with KernelAbstractions.jl without neighborhood search.
Two alternatives: Either #493 using plain kernels for everything or #534 hiding the kernels in the
@threadedmacro. - [x] Rework neighborhood search to be more efficient and GPU-compatible. https://github.com/trixi-framework/PointNeighbors.jl/issues/26
- [x] Make
SolutionSavingCallbackwork on GPUs (#579). - [x] Make TLSPH work on GPUs.
- [x] Benchmark, profile and optimize interactions on GPUs.
- [ ] Avoid synchronization. For example, fluid-solid and solid-solid interactions have no race conditions, so all *-solid interaction kernels can be spawned on the GPU without synchronization. The same holds for all *-fluid and *-boundary interactions. However, this should happen after optimization, since we will lose timers for each individual interaction. Also, we will only see a benefit for multi-physics simulations, as a simple fluid-boundary simulation can't run any two non-trivial interactions without synchronization. Note that a single fluid-* kernel might also be able to improve performance.
Here are some remaining To-Dos from #723:
- [ ] The
SchoenbergQuarticSplineKerneldoes not work on GPUs (https://github.com/JuliaGPU/CUDA.jl/issues/2681 and https://github.com/JuliaGPU/Metal.jl/issues/550). - [ ] Some weird Heisenbug breaking the 3D dam break on Metal (https://github.com/JuliaGPU/Metal.jl/issues/549). But only on my machine, apparently.
- [ ] The open boundary system is not GPU-compatible (https://github.com/trixi-framework/PointNeighbors.jl/issues/20).
- [ ] Monaghan-Kajtar BC don't work with
Float32(https://github.com/JuliaGPU/Metal.jl/issues/552). - [ ] Intel GPUs just report a segfault in the first example (https://buildkite.com/julialang/trixiparticles/builds/121#01956711-2f9f-45c6-a3ce-b591179eac07).