Skip to content

Commit

Permalink
[sycl] Minimize host-device memory synchronization for ColumnSampler. (
Browse files Browse the repository at this point in the history
  • Loading branch information
razdoburdin authored Oct 14, 2024
1 parent 347bb14 commit 78b82e4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/common/random.h
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,10 @@ class ColumnSampler {
}
Reset();

feature_set_tree_->SetDevice(ctx->Device());
// We process ColumnSampler on host for SYCL. So don't need to push data to device
if (!ctx->Device().IsSycl()) {
feature_set_tree_->SetDevice(ctx->Device());
}
feature_set_tree_->Resize(num_col);
if (ctx->IsCUDA()) {
#if defined(XGBOOST_USE_CUDA)
Expand Down

0 comments on commit 78b82e4

Please sign in to comment.