mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Support AVX for i686.
<!--
Thanks for contributing a merge request!
We recommend that first-time contributors read our [contribution guidelines](https://eigen.tuxfamily.org/index.php?title=Contributing_to_Eigen).
Before submitting the MR, please complete the following checks:
- Create one PR per feature or bugfix,
- Run the test suite to verify your changes.
See our [test guidelines](https://eigen.tuxfamily.org/index.php?title=Tests).
- Add tests to cover the bug addressed or any new feature.
- Document new features. If it is a substantial change, add it to the [Changelog](https://gitlab.com/libeigen/eigen/-/blob/master/CHANGELOG.md).
- Leave the following box checked when submitting: `Allow commits from members who can merge to the target branch`.
This allows us to rebase and merge your change.
Note that we are a team of volunteers; we appreciate your patience during the review process.
-->
### Description
<!--Please explain your changes.-->
Support AVX for i686.
There was an existing work-around for windows. Added the more generic
architecture comparison to also apply for linux.
### Reference issue
<!--
You can link to a specific issue using the gitlab syntax #<issue number>.
If the MR fixes an issue, write "Fixes #<issue number>" to have the issue automatically closed on merge.
-->
Fixes #2991.
Closes #2991
See merge request libeigen/eigen!2037
(cherry picked from commit 8e60d4173c)
This commit is contained in:
committed by
Antonio Sanchez
parent
66375a8dc9
commit
41e848c558
@@ -2831,7 +2831,7 @@ inline __m128i segment_mask_4x8(Index begin, Index count) {
|
||||
mask <<= CHAR_BIT * count;
|
||||
mask--;
|
||||
mask <<= CHAR_BIT * begin;
|
||||
#if defined(_WIN32) && !defined(_WIN64)
|
||||
#if !EIGEN_ARCH_x86_64
|
||||
return _mm_loadl_epi64(reinterpret_cast<const __m128i*>(&mask));
|
||||
#else
|
||||
return _mm_cvtsi64_si128(mask);
|
||||
@@ -2847,7 +2847,7 @@ inline __m128i segment_mask_8x8(Index begin, Index count) {
|
||||
mask <<= (CHAR_BIT / 2) * count;
|
||||
mask--;
|
||||
mask <<= CHAR_BIT * begin;
|
||||
#if defined(_WIN32) && !defined(_WIN64)
|
||||
#if !EIGEN_ARCH_x86_64
|
||||
return _mm_loadl_epi64(reinterpret_cast<const __m128i*>(&mask));
|
||||
#else
|
||||
return _mm_cvtsi64_si128(mask);
|
||||
|
||||
Reference in New Issue
Block a user