diff options
author | Gael Guennebaud <g.gael@free.fr> | 2015-03-13 21:15:50 +0100 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2015-03-13 21:15:50 +0100 |
commit | 1330f8bbd12306cc4955d943f27e5281d413bed4 (patch) | |
tree | 0296bc727247353a3032375cfca1af8499e91c36 /test/unalignedassert.cpp | |
parent | d99ab35f9e886a014be6d47606d232af1e668f76 (diff) |
bug #973, improve AVX support by enabling vectorization of Vector4i-like types, and enforcing alignement of Vector4f/Vector2d-like types to preserve compatibility with SSE and future Eigen versions that will vectorize them with AVX enabled.
Diffstat (limited to 'test/unalignedassert.cpp')
-rw-r--r-- | test/unalignedassert.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/unalignedassert.cpp b/test/unalignedassert.cpp index d8815263a..6f7b72167 100644 --- a/test/unalignedassert.cpp +++ b/test/unalignedassert.cpp @@ -81,7 +81,7 @@ void construct_at_boundary(int boundary) void unalignedassert() { - #if EIGEN_ALIGN_STATICALLY +#if EIGEN_ALIGN_STATICALLY construct_at_boundary<Vector2f>(4); construct_at_boundary<Vector3f>(4); construct_at_boundary<Vector4f>(16); @@ -100,7 +100,7 @@ void unalignedassert() construct_at_boundary<Vector3cf>(4); construct_at_boundary<Vector2cd>(EIGEN_ALIGN_BYTES); construct_at_boundary<Vector3cd>(16); - #endif +#endif check_unalignedassert_good<TestNew1>(); check_unalignedassert_good<TestNew2>(); @@ -112,11 +112,12 @@ void unalignedassert() check_unalignedassert_good<Depends<true> >(); #if EIGEN_ALIGN_STATICALLY - if(EIGEN_ALIGN_BYTES==16) + if(EIGEN_ALIGN_BYTES>=16) { VERIFY_RAISES_ASSERT(construct_at_boundary<Vector4f>(8)); VERIFY_RAISES_ASSERT(construct_at_boundary<Vector2d>(8)); VERIFY_RAISES_ASSERT(construct_at_boundary<Vector2cf>(8)); + VERIFY_RAISES_ASSERT(construct_at_boundary<Vector4i>(8)); } for(int b=8; b<EIGEN_ALIGN_BYTES; b+=8) { |