diff options
Diffstat (limited to 'gcc/tree-vect-slp.cc')
| -rw-r--r-- | gcc/tree-vect-slp.cc | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/gcc/tree-vect-slp.cc b/gcc/tree-vect-slp.cc index 31d8485..66c4518 100644 --- a/gcc/tree-vect-slp.cc +++ b/gcc/tree-vect-slp.cc @@ -4045,7 +4045,9 @@ vect_build_slp_store_interleaving (vec<slp_tree> &rhs_nodes, } /* Analyze an SLP instance starting from SCALAR_STMTS which are a group - of KIND. Return true if successful. */ + of KIND. Return true if successful. SCALAR_STMTS is owned by this + function, REMAIN and ROOT_STMT_INFOS ownership is transfered back to + the caller upon failure. */ static bool vect_build_slp_instance (vec_info *vinfo, @@ -4059,7 +4061,10 @@ vect_build_slp_instance (vec_info *vinfo, { /* If there's no budget left bail out early. */ if (*limit == 0) - return false; + { + scalar_stmts.release (); + return false; + } if (kind == slp_inst_kind_ctor) { @@ -4217,6 +4222,7 @@ vect_analyze_slp_reduc_chain (loop_vec_info vinfo, if (!gimple_extract_op (STMT_VINFO_STMT (vect_orig_stmt (stmt)), &op)) gcc_unreachable (); if (CONVERT_EXPR_CODE_P (op.code) + && tree_nop_conversion_p (op.type, TREE_TYPE (op.ops[0])) && (first || is_a <gphi *> (STMT_VINFO_STMT (next_stmt)))) ; @@ -5563,10 +5569,10 @@ vect_analyze_slp (vec_info *vinfo, unsigned max_tree_size, bb_vinfo->roots[i].remain, max_tree_size, &limit, bst_map, false)) { - bb_vinfo->roots[i].stmts = vNULL; bb_vinfo->roots[i].roots = vNULL; bb_vinfo->roots[i].remain = vNULL; } + bb_vinfo->roots[i].stmts = vNULL; } } |
