From 6c58b597bd97d9601c6192c55b1a997731b0a2ac Mon Sep 17 00:00:00 2001 From: Ryan Stocks Date: Mon, 30 Sep 2024 20:17:50 +1000 Subject: [PATCH] Compiling HIP on NVIDIA --- .../local_work_driver/device/hip/kernels/hip_ssh_2d.hip | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/xc_integrator/local_work_driver/device/hip/kernels/hip_ssh_2d.hip b/src/xc_integrator/local_work_driver/device/hip/kernels/hip_ssh_2d.hip index d4f6eda9..727f6061 100644 --- a/src/xc_integrator/local_work_driver/device/hip/kernels/hip_ssh_2d.hip +++ b/src/xc_integrator/local_work_driver/device/hip/kernels/hip_ssh_2d.hip @@ -122,7 +122,12 @@ void modify_weights_ssf_kernel_2d( int32_t npts, int32_t natoms, int cont = (iCenter < natoms); // We will continue iterating until all of the threads have cont set to 0 + +#ifdef __HIP_PLATFORM_NVIDIA__ + while (__any_sync(__activemask(), cont)) { +#else while (__any(cont)) { +#endif if (cont) { double2 rj[weight_unroll/2]; double2 rab_val[weight_unroll/2];