[patch] Vectorizer cost model implementation

Eric Christopher echristo@apple.com
Thu Jun 7 02:09:00 GMT 2007


>
> I have attached the cost model patch. The test cases have been reduced
> to a smaller subset which I think should give us a fairly good  
> coverage
> to start with. Currently I have only added the tests on x86 and  
> x86-64.
>

Want to add them in numerical order maybe?

And a few comments:

+  /* Cost model disabled.  */
+  if (!flag_vect_cost_model)
+    {
+      if (vect_print_dump_info (REPORT_DETAILS))
+        fprintf (vect_dump, "cost model disabled.");
+      return 0;
+    }

Want to add this where vect_estimate_min_profitable_iters is called from
rather than inside? Lot of code to just return 0.

And in a similar vein:

        STMT_VINFO_TYPE (stmt_info) = reduc_vec_info_type;
+      vect_model_reduction_cost (stmt_info, epilog_reduc_code,  
ncopies);

Shouldn't we determine if we're going to compute costs before doing so?

Otherwise it looks OK to me (note I can't approve it).

-eric



More information about the Gcc-patches mailing list