The following makes the target aware of OMP SIMD calls.  Scalar
costing costs calls as scalar_stmt, so make sure to at least do
this level of costing for the vector side.

Bootstrap and regtest ongoing on x86_64-unknown-linux-gnu.

I consider this part quite obvious, [2/2] will need some ideas.

        PR tree-optimization/125174
        * tree-vect-stmts.cc (vectorizable_simd_clone_call): Cost
        the number of OMP SIMD calls number of vector stmts.
---
 gcc/tree-vect-stmts.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/tree-vect-stmts.cc b/gcc/tree-vect-stmts.cc
index 32691f47eb7..b26579e3c5f 100644
--- a/gcc/tree-vect-stmts.cc
+++ b/gcc/tree-vect-stmts.cc
@@ -4542,7 +4542,7 @@ vectorizable_simd_clone_call (vec_info *vinfo, 
stmt_vec_info stmt_info,
       SLP_TREE_TYPE (slp_node) = call_simd_clone_vec_info_type;
       slp_node->data = new vect_simd_clone_data (std::move (_data));
       DUMP_VECT_SCOPE ("vectorizable_simd_clone_call");
-/*      vect_model_simple_cost (vinfo, 1, slp_node, cost_vec); */
+      vect_model_simple_cost (vinfo, ncopies, slp_node, cost_vec);
       return true;
     }
 
-- 
2.51.0

Reply via email to