From: Richard Biener Date: Mon, 20 Sep 2021 09:20:19 +0000 (+0200) Subject: Avoid premature alignment setting in vect_duplicate_ssa_name_ptr_info X-Git-Tag: basepoints/gcc-13~4631 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=24f99147b9264f8f7d9cfb2fa6bd431edfa252d2;p=thirdparty%2Fgcc.git Avoid premature alignment setting in vect_duplicate_ssa_name_ptr_info This removes adjusting alignment based on the vectorized accesses and instead keeps what was set on the original access. The code generating the actual accesses make sure to properly align the vectorized accesses based on the generated pointer already and the vectorizers alignment is always based of the desired alignment of a vector type and thus will reset alignment to unknown this way for example when doing strided accesses. 2021-09-20 Richard Biener * tree-vect-data-refs.c (vect_duplicate_ssa_name_ptr_info): Do not compute alignment of the vectorized access here. --- diff --git a/gcc/tree-vect-data-refs.c b/gcc/tree-vect-data-refs.c index 1a7abe3ff29a..a57700f2c1b4 100644 --- a/gcc/tree-vect-data-refs.c +++ b/gcc/tree-vect-data-refs.c @@ -4635,13 +4635,6 @@ static void vect_duplicate_ssa_name_ptr_info (tree name, dr_vec_info *dr_info) { duplicate_ssa_name_ptr_info (name, DR_PTR_INFO (dr_info->dr)); - int misalign = DR_MISALIGNMENT (dr_info); - if (misalign == DR_MISALIGNMENT_UNKNOWN) - mark_ptr_info_alignment_unknown (SSA_NAME_PTR_INFO (name)); - else - set_ptr_info_alignment (SSA_NAME_PTR_INFO (name), - known_alignment (DR_TARGET_ALIGNMENT (dr_info)), - misalign); } /* Function vect_create_addr_base_for_vector_ref.