This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Stmts in the the loop that are "irrelevant" (i.e. don't need to be vectorized, for various reasons) should not be considered for cost model analysis, also if they are "live" (used out of the loop). What happens in this PR is that during cost model analysis we don't skip irrelevant stmts that are "live"; the type of the computation recorded for irrelevant stmts (the STMT_VINFO_TYPE) is undefined (undef_vec_info_type), which is something the cost model analysis doesn't exepct, and therefore we ICE. This patch fixes that by making sure we skip irrelevant stmts also if they are live. Bootstrapped with vectorization enabled on powerpc64-linux. Bootstrapped on i686-linux and passed full regression testing. To be committed to mainline. dorit PR tree-optimization/34445 * tree-vect-trasnform.c (vect_estimate_min_profitable_iters): Skip stmts (including live stmts) that are not relevant. PR tree-optimization/34445 * gfortran.dg/vect/cost-model-pr34445.f: New test.. * gfortran.dg/vect/cost-model-pr34445a.f: New test. (See attached file: diff.txt)
Attachment:
diff.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |