[PATCH] tree-optimization/101003 - use pattern defs when linearizing
Thu Jun 10 08:41:09 GMT 2021
We of course have to use pattern stmt defs for the linearized
chain operands which is what I failed to ensure.
Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed.
2021-06-10 Richard Biener <firstname.lastname@example.org>
* tree-vect-slp.c (vect_build_slp_tree_2): Appropriately
use the pattern stmt defs when linearizing a chain.
gcc/tree-vect-slp.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/gcc/tree-vect-slp.c b/gcc/tree-vect-slp.c
index 1915d74070b..c4f8f38012f 100644
@@ -1806,6 +1806,11 @@ vect_build_slp_tree_2 (vec_info *vinfo, slp_tree node,
bool res = vect_is_simple_use (op, vinfo, &dt, &def_stmt_info);
+ if (dt == vect_internal_def)
+ def_stmt_info = vect_stmt_to_vectorize (def_stmt_info);
+ op = gimple_get_lhs (def_stmt_info->stmt);
if (dt == vect_internal_def
More information about the Gcc-patches