Skip to content

Enable SVE Support for IP Metric Computation in FP32 functions #1146

Merged
sre-ci-robot merged 1 commit into
zilliztech:mainfrom
ThatikondV:sve-ip-fp32
Apr 21, 2025
Merged

Enable SVE Support for IP Metric Computation in FP32 functions #1146
sre-ci-robot merged 1 commit into
zilliztech:mainfrom
ThatikondV:sve-ip-fp32

Conversation

@ThatikondV
Copy link
Copy Markdown
Contributor

Description:

This PR introduces SVE (Scalable Vector Extension) enablement for IP metric computation in FP32 function. These enhancements provide notable performance improvements over the existing NEON implementation, especially on ARM platforms with SVE capabilities.

Changes in This PR:

  • Added SVE optimizations for IP metric computation in FP32.
  • Refactored internal compute kernels to utilize SVE FP32 intrinsics.

Benchmark Results:

Performance benchmarks were conducted comparing NEON and SVE on ARM. The table below summarizes execution time (in seconds) across supported algorithms:
image

Key observations:

  • All of the algorithms exhibit performance gains with SVE when compared with NEON.

/kind improvement
Fixes #782

@sre-ci-robot
Copy link
Copy Markdown
Collaborator

Welcome @ThatikondV! It looks like this is your first PR to zilliztech/knowhere 🎉

@alexanderguzhva
Copy link
Copy Markdown
Collaborator

/lgtm

@alexanderguzhva
Copy link
Copy Markdown
Collaborator

@ThatikondV We're checking the CI

@alexanderguzhva
Copy link
Copy Markdown
Collaborator

@ThatikondV could you please base to master branch? we've fixed an issue on CI. Thanks.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 17, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 0.00%. Comparing base (3c46f4c) to head (07e30f6).
Report is 355 commits behind head on main.

❌ Your project status has failed because the head coverage (0.00%) is below the target coverage (50.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files

Impacted file tree graph

@@     Coverage Diff      @@
##   main   #1146   +/-   ##
============================
============================
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@alexanderguzhva
Copy link
Copy Markdown
Collaborator

@ThatikondV could you please fix the formatting by running clang-format or applying the following diff?

diff --git a/src/simd/distances_sve.cc b/src/simd/distances_sve.cc
index 17dae74..94211f2 100644
--- a/src/simd/distances_sve.cc
+++ b/src/simd/distances_sve.cc
@@ -40,7 +40,7 @@ fvec_L2sqr_sve(const float* x, const float* y, size_t d) {
     return svaddv_f32(svptrue_b32(), sum);
 }
 
-float 
+float
 fvec_inner_product_sve(const float* x, const float* y, size_t d) {
     svfloat32_t sum = svdup_f32(0.0f);
     size_t i = 0;

Thanks

Signed-off-by: Thatikonda.Varunreddy <Thatikonda.Varunreddy@fujitsu.com>
@ThatikondV
Copy link
Copy Markdown
Contributor Author

@alexanderguzhva I've fixed the formatting issue using clang-format. Please take a look and let me know if anything else is required.

@mergify mergify Bot added the ci-passed label Apr 21, 2025
@alexanderguzhva
Copy link
Copy Markdown
Collaborator

/lgtm
/approve

@sre-ci-robot
Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alexanderguzhva, ThatikondV

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

The pull request process is described 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

@sre-ci-robot sre-ci-robot merged commit dcd2491 into zilliztech:main Apr 21, 2025
13 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support SVE

3 participants