Patchwork [4.7/4.6] Backport typo fix

login
register
mail settings
Submitter Eric Botcazou
Date Jan. 14, 2013, 2:57 p.m.
Message ID <1492128.E7tJBqb2eG@polaris>
Download mbox | patch
Permalink /patch/211800/
State New
Headers show

Comments

Eric Botcazou - Jan. 14, 2013, 2:57 p.m.
Having vect_get_single_scalar_iteraion_cost is really not pretty.  This was 
fixed on the mainline only (r188611) so this patch completes the work.

Tested on x86-64/Linux, applied on the 4.7 branch and 4.6 branch as obvious.


2013-01-14  Eric Botcazou  <ebotcazou@adacore.com>

	* tree-vectorizer.h (vect_get_single_scalar_iteraion_cost): Fix typo.
	* tree-vect-loop.c (vect_get_single_scalar_iteraion_cost): Likewise.
	(vect_estimate_min_profitable_iter): Adjust to above fix.
	* tree-vect-data-refs.c (vect_peeling_hash_get_lowest_cost): Likewise.

Patch

Index: tree-vectorizer.h
===================================================================
--- tree-vectorizer.h	(revision 194927)
+++ tree-vectorizer.h	(working copy)
@@ -916,7 +916,7 @@  extern int vect_estimate_min_profitable_
 extern tree get_initial_def_for_reduction (gimple, tree, tree *);
 extern int vect_min_worthwhile_factor (enum tree_code);
 extern int vect_get_known_peeling_cost (loop_vec_info, int, int *, int);
-extern int vect_get_single_scalar_iteraion_cost (loop_vec_info);
+extern int vect_get_single_scalar_iteration_cost (loop_vec_info);
 
 /* In tree-vect-slp.c.  */
 extern void vect_free_slp_instance (slp_instance);
Index: tree-vect-loop.c
===================================================================
--- tree-vect-loop.c	(revision 194927)
+++ tree-vect-loop.c	(working copy)
@@ -2386,7 +2386,7 @@  vect_force_simple_reduction (loop_vec_in
 
 /* Calculate the cost of one scalar iteration of the loop.  */
 int
-vect_get_single_scalar_iteraion_cost (loop_vec_info loop_vinfo)
+vect_get_single_scalar_iteration_cost (loop_vec_info loop_vinfo)
 {
   struct loop *loop = LOOP_VINFO_LOOP (loop_vinfo);
   basic_block *bbs = LOOP_VINFO_BBS (loop_vinfo);
@@ -2619,7 +2619,7 @@  vect_estimate_min_profitable_iters (loop
 	}
     }
 
-  scalar_single_iter_cost = vect_get_single_scalar_iteraion_cost (loop_vinfo);
+  scalar_single_iter_cost = vect_get_single_scalar_iteration_cost (loop_vinfo);
 
   /* Add additional cost for the peeled instructions in prologue and epilogue
      loop.
Index: tree-vect-data-refs.c
===================================================================
--- tree-vect-data-refs.c	(revision 194927)
+++ tree-vect-data-refs.c	(working copy)
@@ -1296,7 +1296,7 @@  vect_peeling_hash_get_lowest_cost (void
     }
 
   outside_cost += vect_get_known_peeling_cost (loop_vinfo, elem->npeel, &dummy,
-                         vect_get_single_scalar_iteraion_cost (loop_vinfo));
+                         vect_get_single_scalar_iteration_cost (loop_vinfo));
 
   if (inside_cost < min->inside_cost
       || (inside_cost == min->inside_cost && outside_cost < min->outside_cost))