Skip to content

Commit

Permalink
Fix SQ4 AVX-512 implementation (zilliztech#506)
Browse files Browse the repository at this point in the history
Signed-off-by: Alexandr Guzhva <alexanderguzhva@gmail.com>
  • Loading branch information
alexanderguzhva authored Apr 17, 2024
1 parent 4f88afc commit 79d00e3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion thirdparty/faiss/faiss/impl/ScalarQuantizerCodec_avx512.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ struct Codec4bit_avx512 : public Codec4bit_avx {
__m128i c16 =
_mm_unpacklo_epi8(_mm_set1_epi64x(c8ev), _mm_set1_epi64x(c8od));
__m256i c8lo = _mm256_cvtepu8_epi32(c16);
__m256i c8hi = _mm256_cvtepu8_epi32(_mm_srli_si128(c16, 4));
__m256i c8hi = _mm256_cvtepu8_epi32(_mm_srli_si128(c16, 8));
__m512i i16 = _mm512_castsi256_si512(c8lo);
i16 = _mm512_inserti32x8(i16, c8hi, 1);
__m512 f16 = _mm512_cvtepi32_ps(i16);
Expand Down

0 comments on commit 79d00e3

Please sign in to comment.