@@ -150,7 +150,7 @@ using gpuMemLocation = hipMemLocation;
150150using gpuMemLocation = cudaMemLocation;
151151#endif
152152
153- #if ROCM_VERSION >= 70000
153+ #if ROCM_VERSION >= 70100
154154// In contrast to CUDA 13, which overrides the API signature of cudaMemAdvise,
155155// ROCm 7.0, adds hipMemAdvise_v2 to maintain backwards compatibiility.
156156//
@@ -203,7 +203,7 @@ Tensor new_managed_tensor(
203203 ptr,
204204 size_bytes,
205205 cudaMemAdviseSetPreferredLocation,
206- #if CUDART_VERSION >= 13000 || ROCM_VERSION >= 70000
206+ #if CUDART_VERSION >= 13000 || ROCM_VERSION >= 70100
207207 // Starting with CUDA 13, the deviceId arg (int) is replaced with
208208 // cudaMemLocation (struct)
209209 new_mem_location_cpu ()
@@ -218,7 +218,7 @@ Tensor new_managed_tensor(
218218 ptr,
219219 size_bytes,
220220 cudaMemAdviseSetAccessedBy,
221- #if CUDART_VERSION >= 13000 || ROCM_VERSION >= 70000
221+ #if CUDART_VERSION >= 13000 || ROCM_VERSION >= 70100
222222 new_mem_location_from_device (at::cuda::current_device ())
223223#else
224224 at::cuda::current_device ()
@@ -415,7 +415,7 @@ void uvm_cuda_mem_advise(const Tensor& t, int64_t cuda_memory_advise) {
415415 ptr,
416416 size_bytes,
417417 static_cast <enum cudaMemoryAdvise>(cuda_memory_advise),
418- #if CUDART_VERSION >= 13000
418+ #if CUDART_VERSION >= 13000 || ROCM_VERSION >= 70100
419419 new_mem_location_from_device (hint_device)
420420#else
421421 hint_device
0 commit comments