From 7cf64710bdce77005b55e68acce633dc7fa5b7e5 Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Thu, 23 Jun 2011 20:52:58 +0200 Subject: [PATCH] tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use get_pointer_alignment to see if base isn't sufficiently aligned. * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use get_pointer_alignment to see if base isn't sufficiently aligned. From-SVN: r175348 --- gcc/ChangeLog | 5 +++++ gcc/tree-vect-data-refs.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1d1dbd1d958..fad09669668 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2011-06-23 Jakub Jelinek + + * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use + get_pointer_alignment to see if base isn't sufficiently aligned. + 2011-06-23 Jan Hubicka PR tree-optimize/49373 diff --git a/gcc/tree-vect-data-refs.c b/gcc/tree-vect-data-refs.c index c98eb13b225..9a2c5b627e5 100644 --- a/gcc/tree-vect-data-refs.c +++ b/gcc/tree-vect-data-refs.c @@ -859,7 +859,9 @@ vect_compute_data_ref_alignment (struct data_reference *dr) || (TREE_CODE (base_addr) == SSA_NAME && tree_int_cst_compare (ssize_int (TYPE_ALIGN_UNIT (TREE_TYPE ( TREE_TYPE (base_addr)))), - alignment) >= 0)) + alignment) >= 0) + || (get_pointer_alignment (base_addr, TYPE_ALIGN (vectype)) + >= TYPE_ALIGN (vectype))) base_aligned = true; else base_aligned = false; -- 2.30.2