Skip to content

fix: [cp2.6] support CPU adaptation for GPU CAGRA loading (#50096)#50385

Open
marcelo-cjl wants to merge 1 commit into
milvus-io:2.6from
marcelo-cjl:cherrypick-50096-2.6
Open

fix: [cp2.6] support CPU adaptation for GPU CAGRA loading (#50096)#50385
marcelo-cjl wants to merge 1 commit into
milvus-io:2.6from
marcelo-cjl:cherrypick-50096-2.6

Conversation

@marcelo-cjl

@marcelo-cjl marcelo-cjl commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Cherry-pick from master

pr: #50096
issue: #49836

Summary

  • Treat GPU CAGRA indexes with adapt_for_cpu enabled as CPU-adapted in QueryNode resource checks.
  • Apply the same GPU requirement check when estimating segment load resources and collection GPU index flags.
  • Keep the Milvus-side OpenBLAS Conan option needed by the current Knowhere dependency set on 2.6.

Test plan

  • git diff --check upstream/2.6..HEAD
  • GO_DIFF_FILES="internal/datanode/index_services_test.go internal/querynodev2/segments/collection.go internal/querynodev2/segments/collection_test.go internal/querynodev2/segments/segment_loader.go internal/querynodev2/segments/segment_loader_test.go" make fmt
  • go test -count=1 -tags test ./internal/querynodev2/segments -run 'TestGpuIndexRequiresGpu|TestCollectionManagerSuite/TestGpuIndexFlagWithCagraAdaptForCPU' blocked locally because this clean 2.6 workspace has not built internal/core/output/lib/libmilvus_core.so.

@sre-ci-robot sre-ci-robot added the size/L Denotes a PR that changes 100-499 lines. label Jun 8, 2026
@mergify mergify Bot added dco-passed DCO check passed. kind/bug Issues or changes related a bug labels Jun 8, 2026
@marcelo-cjl marcelo-cjl added this to the 2.6.19 milestone Jun 8, 2026
@sre-ci-robot

Copy link
Copy Markdown
Contributor

[ci-v2-notice]
Notice: New ci-v2 system is enabled for this PR.

To rerun ci-v2 checks, comment with:

  • /ci-rerun-code-check // for ci-v2/code-check
  • /ci-rerun-code-check-macos // for Code Checker MacOS (GitHub Actions)
  • /ci-rerun-build // for ci-v2/build
  • /ci-rerun-build-all // for ci-v2/build-all (multi-arch builds)
  • /ci-rerun-buildenv // for ci-v2/build-env (build milvus-env builder images)
  • /ci-rerun-ut-integration // for ci-v2/ut-integration, will rerun ci-v2/build
  • /ci-rerun-ut-go // for ci-v2/ut-go, will rerun ci-v2/build
  • /ci-rerun-ut-cpp // for ci-v2/ut-cpp
  • /ci-rerun-ut // for all ci-v2/ut-integration, ci-v2/ut-go, ci-v2/ut-cpp, will rerun ci-v2/build
  • /ci-rerun-e2e-default // for ci-v2/e2e-default
  • /ci-rerun-e2e-amd // for ci-v2/e2e-amd (e2e pool dispatcher)
  • /ci-rerun-build-ut-cov // for ci-v2/build-ut-cov (build + unit tests in one pipeline)
  • /ci-rerun-gosdk // for ci-v2/go-sdk (Go SDK E2E tests, ARM)

If you have any questions or requests, please contact @zhikunyao.

@sre-ci-robot sre-ci-robot added the do-not-merge/need-merge-master-first any pr merge to release branch need to merge master first label Jun 8, 2026
@sre-ci-robot

Copy link
Copy Markdown
Contributor

[INFO] PR Label Summary by Default
[FAILED] PR #50096 not merged

Use /refresh-label to update related check and label manually

@marcelo-cjl marcelo-cjl changed the title fix: [2.6] support CPU adaptation for GPU CAGRA loading (#50096) fix: [cp2.6] support CPU adaptation for GPU CAGRA loading (#50096) Jun 8, 2026
@codecov

codecov Bot commented Jun 8, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 76.00000% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 77.73%. Comparing base (cb08db0) to head (b65eef6).
⚠️ Report is 945 commits behind head on 2.6.

Files with missing lines Patch % Lines
internal/querynodev2/segments/segment_loader.go 75.00% 4 Missing and 2 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##              2.6   #50385      +/-   ##
==========================================
+ Coverage   76.99%   77.73%   +0.74%     
==========================================
  Files        1700     1999     +299     
  Lines      262533   329117   +66584     
==========================================
+ Hits       202142   255846   +53704     
- Misses      53550    65428   +11878     
- Partials     6841     7843    +1002     
Components Coverage Δ
Client 79.48% <74.73%> (+1.34%) ⬆️
Core 84.58% <45.83%> (+2.37%) ⬆️
Go 75.80% <55.09%> (+0.41%) ⬆️
Files with missing lines Coverage Δ
internal/querynodev2/segments/collection.go 87.66% <100.00%> (+1.51%) ⬆️
internal/querynodev2/segments/segment_loader.go 56.40% <75.00%> (-5.74%) ⬇️

... and 1411 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sre-ci-robot sre-ci-robot added the low-code-coverage add test-label from zhikun, diff coverage > 80% label Jun 8, 2026
Signed-off-by: marcelo-cjl <marcelo.chen@zilliz.com>
(cherry picked from commit 22f5f9b)
Signed-off-by: marcelo-cjl <marcelo.chen@zilliz.com>
@marcelo-cjl marcelo-cjl force-pushed the cherrypick-50096-2.6 branch from 62ce95a to b65eef6 Compare June 11, 2026 07:24
@sre-ci-robot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: marcelo-cjl
To complete the pull request process, please assign congqixia after the PR has been reviewed.
You can assign the PR to them by writing /assign @congqixia in a comment when ready.

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

Details 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

@marcelo-cjl

Copy link
Copy Markdown
Contributor Author

/refresh-label

@sre-ci-robot sre-ci-robot removed the do-not-merge/need-merge-master-first any pr merge to release branch need to merge master first label Jun 11, 2026
@sre-ci-robot

Copy link
Copy Markdown
Contributor

[INFO] PR Label Summary by Refresh-Label

[SUCCESS] PR #50096 merged to master

Use /refresh-label to update related check and label manually

@mergify mergify Bot added the ci-passed label Jun 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-passed dco-passed DCO check passed. kind/bug Issues or changes related a bug low-code-coverage add test-label from zhikun, diff coverage > 80% size/L Denotes a PR that changes 100-499 lines.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants