PR tree-optimization/63666
* tree-vect-slp.c (vect_get_mask_element): Properly handle
accessing out-of-bound elements.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@216825
138bc75d-0d04-0410-961f-
82ee72b054a4
+2014-10-29 Richard Biener <rguenther@suse.de>
+
+ PR tree-optimization/63666
+ * tree-vect-slp.c (vect_get_mask_element): Properly handle
+ accessing out-of-bound elements.
+
2014-10-29 Alexander Ivchenko <alexander.ivchenko@intel.com>
Maxim Kuznetsov <maxim.kuznetsov@intel.com>
Anna Tikhonova <anna.tikhonova@intel.com>
}
/* The mask requires the next vector. */
- if (*current_mask_element >= mask_nunits * 2)
+ while (*current_mask_element >= mask_nunits * 2)
{
if (*needs_first_vector || *mask_fixed)
{
&number_of_mask_fixes, &mask_fixed,
&needs_first_vector))
return false;
+ gcc_assert (current_mask_element < 2 * nunits);
mask[index++] = current_mask_element;
if (index == nunits)