From c528f760fb5782a4bf0eb21d043fa8bb01e24503 Mon Sep 17 00:00:00 2001 From: Julian P Samaroo Date: Wed, 10 Jan 2024 08:18:07 -0700 Subject: [PATCH] Updates for HIP-based AMDGPU --- Project.toml | 2 +- ext/AMDGPUExt.jl | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index 3158da47..e872f45b 100644 --- a/Project.toml +++ b/Project.toml @@ -38,7 +38,7 @@ MetalExt = ["Metal"] oneAPIExt = ["oneAPI"] [compat] -AMDGPU = "0.4.9" +AMDGPU = "0.5, 0.6, 0.7, 0.8" Adapt = "3, 4" CUDA = "4.1.0, 5" ChainRulesCore = "1" diff --git a/ext/AMDGPUExt.jl b/ext/AMDGPUExt.jl index 096f5a39..01fa2ba0 100644 --- a/ext/AMDGPUExt.jl +++ b/ext/AMDGPUExt.jl @@ -5,6 +5,9 @@ import DiffEqGPU using .AMDGPU import .AMDGPU: ROCBackend +function DiffEqGPU.EnsembleGPUArray(cpu_offload::Float64) + DiffEqGPU.EnsembleGPUArray(ROCBackend(), cpu_offload) +end DiffEqGPU.maxthreads(::ROCBackend) = 256 DiffEqGPU.maybe_prefer_blocks(::ROCBackend) = ROCBackend()