Skip to content

[MOD-11477] [MOD-10920] Fix vector compression type reporting and rename SVS environment variable#6843

Merged
meiravgri merged 1 commit intomasterfrom
meiravg_allow_building_intel_opt
Sep 16, 2025
Merged

[MOD-11477] [MOD-10920] Fix vector compression type reporting and rename SVS environment variable#6843
meiravgri merged 1 commit intomasterfrom
meiravg_allow_building_intel_opt

Conversation

@meiravgri
Copy link
Copy Markdown
Collaborator

@meiravgri meiravgri commented Sep 16, 2025

MOD-11477 Bug Fix: Incorrect compression type in FT.INFO

Problem:
The FT.INFO command was incorrectly reporting SVS index compression types when Intel SVS optimizations are enaled. The isLVQSupported() function always returned false because the SVS_PRE_COMPILED_LIB macro was never defined during compilation, even when the environment variable was set.

Root Cause:
The environment variable SVS_PRE_COMPILED_LIB was not being translated into a compilation macro. The conditional compilation check in src/vector_index.c:

#if defined(CPUID_AVAILABLE) && defined(SVS_PRE_COMPILED_LIB)

was always evaluating to false because SVS_PRE_COMPILED_LIB was undefined at compile time.

Fix:

  • Added CMake logic to define the compilation macro when the environment variable is set
  • The macro is now properly defined and the Intel CPU detection code executes correctly
  • FT.INFO now accurately reports compression types when using precompiled Intel SVS libraries

MOD-10920 Environment Variable Rename

Change:
Renamed SVS_PRE_COMPILED_LIB to BUILD_INTEL_SVS_OPT throughout the codebase to align with naming conventions requested in MOD-10920.

Files Modified:

  • build.sh: Updated environment variable name and default value
  • CMakeLists.txt: Updated CMake condition and macro definition
  • src/vector_index.c: Updated conditional compilation directive

rename SVS_PRE_COMPILED_LIB to BUILD_INTEL_SVS_OPT
@meiravgri meiravgri changed the title fix bug in info [MOD-10920] Fix vector compression type reporting and rename SVS environment variable Sep 16, 2025
@meiravgri meiravgri changed the title [MOD-10920] Fix vector compression type reporting and rename SVS environment variable [MOD-11477] [MOD-10920] Fix vector compression type reporting and rename SVS environment variable Sep 16, 2025
@meiravgri meiravgri requested a review from GuyAv46 September 16, 2025 15:57
@codecov
Copy link
Copy Markdown

codecov bot commented Sep 16, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.93%. Comparing base (a1e376d) to head (7950819).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6843      +/-   ##
==========================================
- Coverage   86.98%   86.93%   -0.06%     
==========================================
  Files         288      288              
  Lines       46168    46173       +5     
  Branches     9072     9072              
==========================================
- Hits        40159    40139      -20     
- Misses       5858     5883      +25     
  Partials      151      151              
Flag Coverage Δ
flow 84.62% <ø> (-0.18%) ⬇️
unit 49.70% <ø> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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

@meiravgri meiravgri added this pull request to the merge queue Sep 16, 2025
Merged via the queue into master with commit a78a74d Sep 16, 2025
21 checks passed
@meiravgri meiravgri deleted the meiravg_allow_building_intel_opt branch September 16, 2025 18:22
redisearch-backport-pull-request bot pushed a commit that referenced this pull request Sep 16, 2025
…ame SVS environment variable (#6843)

fix bug in info
rename SVS_PRE_COMPILED_LIB to BUILD_INTEL_SVS_OPT

(cherry picked from commit a78a74d)
@redisearch-backport-pull-request
Copy link
Copy Markdown
Contributor

github-merge-queue bot pushed a commit that referenced this pull request Sep 16, 2025
…nd rename SVS environment variable (#6845)

[MOD-11477] [MOD-10920] Fix vector compression type reporting and rename SVS environment variable (#6843)

fix bug in info
rename SVS_PRE_COMPILED_LIB to BUILD_INTEL_SVS_OPT

(cherry picked from commit a78a74d)

Co-authored-by: meiravgri <109056284+meiravgri@users.noreply.github.com>
lerman25 pushed a commit that referenced this pull request Sep 24, 2025
…ame SVS environment variable (#6843)

fix bug in info
rename SVS_PRE_COMPILED_LIB to BUILD_INTEL_SVS_OPT
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.

2 participants