Skip to content
This repository has been archived by the owner on Aug 16, 2023. It is now read-only.

Remove omp process in diskann index #759

Merged
merged 1 commit into from
Mar 27, 2023

Conversation

cqy123456
Copy link
Collaborator

@cqy123456 cqy123456 commented Mar 21, 2023

issue: #782
Comparison between omp and thread pool on building diskann as follow:

  • dataset: sift1m128d

  • threads number: 12

  1. OMP-version
  • Train PQ code: 40.3169s

  • Build graph: 242.631s

  • Total: 284.553s

  1. Thread Pool-version
  • Train PQ code : 31.2216s

  • Build graph: 226.467ss

  • Total: 259.264s

@sre-ci-robot sre-ci-robot requested a review from liliu-z March 21, 2023 11:24
@sre-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cqy123456

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@cqy123456 cqy123456 changed the title remove omp process in diskann index Remove omp process in diskann index Mar 21, 2023
@mergify mergify bot added the dco-passed DCO check passed. label Mar 21, 2023
@mergify
Copy link

mergify bot commented Mar 21, 2023

@cqy123456 Please associate the related issue to the body of your Pull Request. (eg. “issue: #”)

Copy link
Member

@liliu-z liliu-z left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Let's don't put this many codes with different purposes in a single PR.
  2. Do we cleaned all OMP in DiskANN? I guess we still have some in Load path right?
  3. Any performance change for this PR?

// query at a time. More threads will result in higher aggregate query throughput, but will also use more IOs/second
// across the system, which may lead to higher per-query latency. So find the balance depending on the maximum
// number of IOPs supported by the SSD.
CFG_INT num_threads;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will existed code crash due to num_threads turning to invalid?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I put this key into ext_legal_json_keys, and it still legal.

@@ -493,7 +504,6 @@ int generate_pq_data_from_pivots(const std::string data_file,
LOG_KNOWHERE_DEBUG_ << "Processing points [" << start_id << ", " << end_id
<< ")..";

#pragma omp parallel for firstprivate(block_data_tmp) schedule(static, 8192)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it OK here to not replace omp with any pool?

@cqy123456 cqy123456 force-pushed the remove-diskann-omp branch from 0cd8b37 to 244aaa7 Compare March 23, 2023 14:04
@mergify mergify bot added ci-passed and removed ci-passed labels Mar 23, 2023
@cqy123456 cqy123456 force-pushed the remove-diskann-omp branch from 244aaa7 to 306d9c7 Compare March 23, 2023 17:08
@mergify mergify bot added ci-passed and removed ci-passed labels Mar 23, 2023
@cqy123456 cqy123456 force-pushed the remove-diskann-omp branch from 306d9c7 to 9e63eee Compare March 24, 2023 03:07
@mergify mergify bot added ci-passed and removed ci-passed labels Mar 24, 2023
@cqy123456 cqy123456 force-pushed the remove-diskann-omp branch from 9e63eee to 84390fc Compare March 27, 2023 03:52
@mergify mergify bot added ci-passed and removed ci-passed labels Mar 27, 2023
@liliu-z
Copy link
Member

liliu-z commented Mar 27, 2023

/lgtm

@mergify mergify bot added the ci-passed label Mar 27, 2023
@sre-ci-robot sre-ci-robot merged commit e5d7dff into milvus-io:main Mar 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants