[Bug target/96827] [10/11 Regression] __m128i from _mm_set_epi32 is backwards with -O3
joel.hutton at arm dot com
gcc-bugzilla@gcc.gnu.org
Mon Sep 7 13:08:02 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96827
--- Comment #8 from Joel Hutton <joel.hutton at arm dot com> ---
I'm working on this.
I believe this may have been introduced by my earlier SLP vector constructor
patch.(commit 10d1592)
What I believe to be the relevant section:
+ else if (constructor)
+ {
+ tree rhs = gimple_assign_rhs1 (stmt_info->stmt);
+ tree val;
+ FOR_EACH_CONSTRUCTOR_VALUE (CONSTRUCTOR_ELTS (rhs), i, val)
+ {
+ if (TREE_CODE (val) == SSA_NAME)
+ {
+ gimple* def = SSA_NAME_DEF_STMT (val);
+ stmt_vec_info def_info = vinfo->lookup_stmt (def);
+ /* Value is defined in another basic block. */
+ if (!def_info)
+ return false;
+ scalar_stmts.safe_push (def_info);
+ }
+ else
+ return false;
+ }
+ }
I'm investigating, but I suspect pushing to a stack which is then popped from
later has created a reversal of element order.
More information about the Gcc-bugs
mailing list