mirror of
https://github.com/qdrant/qdrant.git
synced 2026-08-06 01:50:57 -05:00
Fix unecessary unsafe in Clippy 1.87 (#6540)
* Fix unecessary unsafe in Clippy 1.87 * bump Rust version for intrinsics safe API * ignore until we can bump the MSRV with cargo-chef * remove unecessary change * mark clearly as TODO
This commit is contained in:
@@ -8,6 +8,7 @@ use crate::data_types::vectors::{DenseVector, VectorElementType};
|
||||
#[target_feature(enable = "avx")]
|
||||
#[target_feature(enable = "fma")]
|
||||
#[allow(clippy::missing_safety_doc)]
|
||||
#[allow(unused_unsafe)] // TODO remove once we can bump the MSRV to 1.87 (cargo-chef)
|
||||
pub unsafe fn hsum256_ps_avx(x: __m256) -> f32 {
|
||||
unsafe {
|
||||
let x128: __m128 = _mm_add_ps(_mm256_extractf128_ps(x, 1), _mm256_castps256_ps128(x));
|
||||
|
||||
@@ -10,6 +10,7 @@ use crate::data_types::vectors::{DenseVector, VectorElementType};
|
||||
|
||||
#[target_feature(enable = "sse")]
|
||||
#[allow(clippy::missing_safety_doc)]
|
||||
#[allow(unused_unsafe)] // TODO remove once we can bump the MSRV to 1.87 (cargo-chef)
|
||||
pub unsafe fn hsum128_ps_sse(x: __m128) -> f32 {
|
||||
unsafe {
|
||||
let x64: __m128 = _mm_add_ps(x, _mm_movehl_ps(x, x));
|
||||
|
||||
Reference in New Issue
Block a user