namespace to reduce code

This commit is contained in:
Hui Liu
2023-10-27 10:51:32 -07:00
parent 4302200a33
commit 6762230d9a
26 changed files with 14 additions and 136 deletions

View File

@@ -15,13 +15,6 @@
#include "xgboost/json.h"
#include "xgboost/logging.h"
#if defined(XGBOOST_USE_HIP)
namespace cub = hipcub;
namespace thrust {
namespace cuda = thrust::hip;
}
#endif
namespace xgboost {
namespace {
auto SetDeviceToPtr(void const* ptr) {

View File

@@ -17,12 +17,6 @@
#include "adapter.h"
#include "array_interface.h"
#if defined(XGBOOST_USE_HIP)
namespace thrust {
namespace cuda = thrust::hip;
}
#endif
namespace xgboost {
namespace data {

View File

@@ -16,12 +16,6 @@
#include "simple_batch_iterator.h"
#include "sparse_page_source.h"
#if defined(XGBOOST_USE_HIP)
namespace thrust {
namespace cuda = thrust::hip;
}
#endif
namespace xgboost::data {
void IterativeDMatrix::InitFromCUDA(Context const* ctx, BatchParam const& p,
DataIterHandle iter_handle, float missing,

View File

@@ -13,12 +13,6 @@
#include "../common/error_msg.h" // for InfInData
#include "device_adapter.cuh" // for HasInfInData
#if defined(XGBOOST_USE_HIP)
namespace thrust {
namespace cuda = thrust::hip;
}
#endif
namespace xgboost::data {
#if defined(XGBOOST_USE_CUDA)