提交 eadf2adb 编写于 作者: J jinhai

Merge branch '0.5.1' into '0.5.1'

0.5.1

See merge request megasearch/milvus!814

Former-commit-id: 0e8c62a802edb2546d1f69bbb23df992c37bae67
...@@ -7,6 +7,7 @@ Please mark all change in change log and use the ticket from JIRA. ...@@ -7,6 +7,7 @@ Please mark all change in change log and use the ticket from JIRA.
## Bug ## Bug
- \#134 - JFrog cache error - \#134 - JFrog cache error
- \#161 - Search IVFSQHybrid crash on gpu - \#161 - Search IVFSQHybrid crash on gpu
- \#169 - IVF_FLAT search out of memory
## Feature ## Feature
- \#90 - The server start error messages could be improved to enhance user experience - \#90 - The server start error messages could be improved to enhance user experience
......
...@@ -309,30 +309,13 @@ ExecutionEngineImpl::CopyToGpu(uint64_t device_id, bool hybrid) { ...@@ -309,30 +309,13 @@ ExecutionEngineImpl::CopyToGpu(uint64_t device_id, bool hybrid) {
return Status::OK(); return Status::OK();
} }
#endif #endif
try {
auto index = std::static_pointer_cast<VecIndex>(cache::GpuCacheMgr::GetInstance(device_id)->GetIndex(location_)); index_ = index_->CopyToGpu(device_id);
bool already_in_cache = (index != nullptr); ENGINE_LOG_DEBUG << "CPU to GPU" << device_id;
if (already_in_cache) { } catch (std::exception& e) {
index_ = index; ENGINE_LOG_ERROR << e.what();
} else { return Status(DB_ERROR, e.what());
if (index_ == nullptr) {
ENGINE_LOG_ERROR << "ExecutionEngineImpl: index is null, failed to copy to gpu";
return Status(DB_ERROR, "index is null");
}
try {
index_ = index_->CopyToGpu(device_id);
ENGINE_LOG_DEBUG << "CPU to GPU" << device_id;
} catch (std::exception& e) {
ENGINE_LOG_ERROR << e.what();
return Status(DB_ERROR, e.what());
}
} }
if (!already_in_cache) {
GpuCache(device_id);
}
return Status::OK(); return Status::OK();
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册