Given the current reliance of masking on niters and the fact this is
undetermined for uncounted loops, we circumvent this limitation by
disabling the use of partial vectors when vectorizing loops with an
unkown upper bound.
gcc/ChangeLog:
* tree-vect-loop.cc (vect_analyze_loop_2): Disable partial
vector use for uncounted loops.
orig_loop_vinfo = loop_vinfo;
gcc_assert (orig_loop_vinfo);
+ /* We can't mask on niters for uncounted loops due to unkown upper bound. */
+ if (LOOP_VINFO_NITERS_UNCOUNTED_P (loop_vinfo))
+ LOOP_VINFO_CAN_USE_PARTIAL_VECTORS_P (loop_vinfo) = false;
+
/* The first group of checks is independent of the vector size. */
fatal = true;