tree-vect-stmts.c (vectorizable_mask_load_store): Check mask has a proper number of elements.

gcc/

	* tree-vect-stmts.c (vectorizable_mask_load_store): Check mask
	has a proper number of elements.

From-SVN: r234104
This commit is contained in:
Ilya Enkovich 2016-03-10 10:58:57 +00:00 committed by Ilya Enkovich
parent ba52669fc5
commit dc6a314740
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2016-03-10 Ilya Enkovich <enkovich.gnu@gmail.com>
* tree-vect-stmts.c (vectorizable_mask_load_store): Check mask
has a proper number of elements.
2016-03-10 Alan Modra <amodra@gmail.com>
PR rtl-optimization/69195

View File

@ -1742,7 +1742,8 @@ vectorizable_mask_load_store (gimple *stmt, gimple_stmt_iterator *gsi,
if (!mask_vectype)
mask_vectype = get_mask_type_for_scalar_type (TREE_TYPE (vectype));
if (!mask_vectype || !VECTOR_BOOLEAN_TYPE_P (mask_vectype))
if (!mask_vectype || !VECTOR_BOOLEAN_TYPE_P (mask_vectype)
|| TYPE_VECTOR_SUBPARTS (mask_vectype) != TYPE_VECTOR_SUBPARTS (vectype))
return false;
if (is_store)