public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r14-4792] middle-end: don't pass loop_vinfo to vect_set_loop_condition during prolog peeling
@ 2023-10-20 14:00 Tamar Christina
  0 siblings, 0 replies; only message in thread
From: Tamar Christina @ 2023-10-20 14:00 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:eb15fad3190a8b33e3e451b964ff1ecf08bbb113

commit r14-4792-geb15fad3190a8b33e3e451b964ff1ecf08bbb113
Author: Tamar Christina <tamar.christina@arm.com>
Date:   Fri Oct 20 14:58:39 2023 +0100

    middle-end: don't pass loop_vinfo to vect_set_loop_condition during prolog peeling
    
    During the refactoring I had passed loop_vinfo on to vect_set_loop_condition
    during prolog peeling.  This parameter is unused in most cases except for in
    vect_set_loop_condition_partial_vectors where it's behaviour depends on whether
    loop_vinfo is NULL or not.  Apparently this code expect it to be NULL and it
    reads the structures from a different location.
    
    This fixes the failing testcase which was not using the lens values determined
    earlier in vectorizable_store because it was looking it up in the given
    loop_vinfo instead.
    
    gcc/ChangeLog:
    
            PR tree-optimization/111866
            * tree-vect-loop-manip.cc (vect_do_peeling): Pass null as vinfo to
            vect_set_loop_condition during prolog peeling.

Diff:
---
 gcc/tree-vect-loop-manip.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/tree-vect-loop-manip.cc b/gcc/tree-vect-loop-manip.cc
index db1d4f867ead..9c2551261e33 100644
--- a/gcc/tree-vect-loop-manip.cc
+++ b/gcc/tree-vect-loop-manip.cc
@@ -3235,7 +3235,7 @@ vect_do_peeling (loop_vec_info loop_vinfo, tree niters, tree nitersm1,
 
       /* Update the number of iterations for prolog loop.  */
       tree step_prolog = build_one_cst (TREE_TYPE (niters_prolog));
-      vect_set_loop_condition (prolog, prolog_e, loop_vinfo, niters_prolog,
+      vect_set_loop_condition (prolog, prolog_e, NULL, niters_prolog,
 			       step_prolog, NULL_TREE, false);
 
       /* Skip the prolog loop.  */

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-10-20 14:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-20 14:00 [gcc r14-4792] middle-end: don't pass loop_vinfo to vect_set_loop_condition during prolog peeling Tamar Christina

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).