diff options
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/tree-vect-loop.c | 4 |
2 files changed, 10 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9292748..4c052cc 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -2,6 +2,13 @@ Alan Hayward <alan.hayward@arm.com> David Sherwood <david.sherwood@arm.com> + * tree-vect-loop.c (vectorizable_live_operation): Fix element size + calculation for vector booleans. + +2017-09-18 Richard Sandiford <richard.sandiford@linaro.org> + Alan Hayward <alan.hayward@arm.com> + David Sherwood <david.sherwood@arm.com> + * tree-vect-stmts.c (can_vectorize_live_stmts): New function, split out from... (vect_transform_stmt): ...here. diff --git a/gcc/tree-vect-loop.c b/gcc/tree-vect-loop.c index 82b6629..5d29ef5 100644 --- a/gcc/tree-vect-loop.c +++ b/gcc/tree-vect-loop.c @@ -7066,7 +7066,9 @@ vectorizable_live_operation (gimple *stmt, : gimple_get_lhs (stmt); lhs_type = TREE_TYPE (lhs); - bitsize = TYPE_SIZE (TREE_TYPE (vectype)); + bitsize = (VECTOR_BOOLEAN_TYPE_P (vectype) + ? bitsize_int (TYPE_PRECISION (TREE_TYPE (vectype))) + : TYPE_SIZE (TREE_TYPE (vectype))); vec_bitsize = TYPE_SIZE (vectype); /* Get the vectorized lhs of STMT and the lane to use (counted in bits). */ |