Skip to content

Commit e6934a7

Browse files
committed
Updates for RMM 25.12 compatibility
1 parent 0b67a40 commit e6934a7

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

src/common/device_vector.cuh

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,9 @@
77
#include <thrust/device_vector.h> // for device_vector
88

99
#if defined(XGBOOST_USE_RMM) && XGBOOST_USE_RMM == 1
10-
#include <cuda/memory_resource> // for async_resource_ref
11-
#include <cuda/stream_ref> // for stream_ref
12-
#include <rmm/mr/device/device_memory_resource.hpp> // for device_memory_resource
13-
#include <rmm/mr/device/per_device_resource.hpp> // for get_current_device_resource
10+
#include <cuda/memory_resource> // for async_resource_ref
11+
#include <cuda/stream_ref> // for stream_ref
12+
#include <rmm/mr/per_device_resource.hpp> // for get_current_device_resource
1413

1514
#include "xgboost/global_config.h" // for GlobalConfigThreadLocalStore
1615

@@ -266,7 +265,7 @@ namespace detail {
266265
*/
267266
template <typename T>
268267
class ThrustAllocMrAdapter : public thrust::device_malloc_allocator<T> {
269-
DeviceAsyncResourceRef mr_{rmm::mr::get_current_device_resource()};
268+
DeviceAsyncResourceRef mr_{rmm::mr::get_current_device_resource_ref()};
270269

271270
public:
272271
using Super = thrust::device_malloc_allocator<T>;

tests/cpp/helpers.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,9 @@
2929
#if defined(XGBOOST_USE_RMM) && XGBOOST_USE_RMM == 1
3030
#include <memory>
3131
#include <vector>
32-
#include "rmm/mr/device/per_device_resource.hpp"
33-
#include "rmm/mr/device/cuda_memory_resource.hpp"
34-
#include "rmm/mr/device/pool_memory_resource.hpp"
32+
#include "rmm/mr/per_device_resource.hpp"
33+
#include "rmm/mr/cuda_memory_resource.hpp"
34+
#include "rmm/mr/pool_memory_resource.hpp"
3535
#endif // defined(XGBOOST_USE_RMM) && XGBOOST_USE_RMM == 1
3636

3737
bool FileExists(const std::string& filename) {

0 commit comments

Comments
 (0)