diff --git a/stl/src/vector_algorithms.cpp b/stl/src/vector_algorithms.cpp index a5a637695e..1c5fc74e80 100644 --- a/stl/src/vector_algorithms.cpp +++ b/stl/src/vector_algorithms.cpp @@ -10,6 +10,7 @@ #include #include #include + #ifndef _M_ARM64EC #include #include @@ -47,6 +48,12 @@ namespace { _mm256_zeroupper(); } }; + + __m256i _Avx2_tail_mask_32(const size_t _Count_in_dwords) noexcept { + // _Count_in_dwords must be within [1, 7]. + static constexpr unsigned int _Tail_masks[14] = {~0u, ~0u, ~0u, ~0u, ~0u, ~0u, ~0u, 0, 0, 0, 0, 0, 0, 0}; + return _mm256_loadu_si256(reinterpret_cast(_Tail_masks + (7 - _Count_in_dwords))); + } } // namespace #endif // !defined(_M_ARM64EC) @@ -88,12 +95,6 @@ namespace { void _Advance_bytes(const void*& _Target, _Integral _Offset) noexcept { _Target = static_cast(_Target) + _Offset; } - - __m256i _Avx2_tail_mask_32(const size_t _Count_in_dwords) noexcept { - // _Count_in_dwords must be within [1, 7]. - static constexpr unsigned int _Tail_masks[14] = {~0u, ~0u, ~0u, ~0u, ~0u, ~0u, ~0u, 0, 0, 0, 0, 0, 0, 0}; - return _mm256_loadu_si256(reinterpret_cast(_Tail_masks + (7 - _Count_in_dwords))); - } } // unnamed namespace extern "C" {