diff --git a/src/offload/offload_runtime.h b/src/offload/offload_runtime.h index de48ebcaec..77f993f86c 100644 --- a/src/offload/offload_runtime.h +++ b/src/offload/offload_runtime.h @@ -338,7 +338,7 @@ static inline void offloadEnsureMallocHeapSize(const size_t required_size) { if (current_size < required_size) { OFFLOAD_CHECK(cudaDeviceSetLimit(cudaLimitMallocHeapSize, required_size)); } -#elif defined(__OFFLOAD_HIP) && (HIP_VERSION > 50200000) +#elif defined(__OFFLOAD_HIP) && (HIP_VERSION >= 50300000) OFFLOAD_CHECK(hipDeviceGetLimit(¤t_size, hipLimitMallocHeapSize)); if (current_size < required_size) { OFFLOAD_CHECK(hipDeviceSetLimit(hipLimitMallocHeapSize, required_size));