From 7ac7b88520d72b70c3e1367796e99850a0797201 Mon Sep 17 00:00:00 2001 From: Tamas Bela Feher Date: Wed, 5 Jul 2023 14:41:32 +0200 Subject: [PATCH 1/2] Enable conservative memory allocations for RAFT IVF-Flat benchmarks. --- cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h | 1 + 1 file changed, 1 insertion(+) diff --git a/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h b/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h index cf04e07d19..ec8a4b514e 100644 --- a/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h +++ b/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h @@ -97,6 +97,7 @@ RaftIvfFlatGpu::RaftIvfFlatGpu(Metric metric, int dim, const BuildParam mr_(rmm::mr::get_current_device_resource(), 1024 * 1024 * 1024ull) { index_params_.metric = parse_metric_type(metric); + index_params_.conservative_memory_allocation = true; rmm::mr::set_current_device_resource(&mr_); RAFT_CUDA_TRY(cudaGetDevice(&device_)); } From 449738c86398b827b47268e61f582574672ba343 Mon Sep 17 00:00:00 2001 From: Tamas Bela Feher Date: Wed, 5 Jul 2023 20:01:21 +0200 Subject: [PATCH 2/2] Fix style issue --- cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h b/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h index ec8a4b514e..bdd688f29b 100644 --- a/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h +++ b/cpp/bench/ann/src/raft/raft_ivf_flat_wrapper.h @@ -96,7 +96,7 @@ RaftIvfFlatGpu::RaftIvfFlatGpu(Metric metric, int dim, const BuildParam dimension_(dim), mr_(rmm::mr::get_current_device_resource(), 1024 * 1024 * 1024ull) { - index_params_.metric = parse_metric_type(metric); + index_params_.metric = parse_metric_type(metric); index_params_.conservative_memory_allocation = true; rmm::mr::set_current_device_resource(&mr_); RAFT_CUDA_TRY(cudaGetDevice(&device_));