public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <jeffreyalaw@gmail.com>
To: Richard Biener <rguenther@suse.de>, gcc-patches@gcc.gnu.org
Subject: Re: [PATCH][RFC] tree-optimization/92335 - Improve sinking heuristics for vectorization
Date: Mon, 31 Jul 2023 09:33:03 -0600	[thread overview]
Message-ID: <320f94c3-8805-ec64-dd4b-0454c8ecce14@gmail.com> (raw)
In-Reply-To: <20230728070552.50C1413276@imap2.suse-dmz.suse.de>



On 7/28/23 01:05, Richard Biener via Gcc-patches wrote:
> The following delays sinking of loads within the same innermost
> loop when it was unconditional before.  That's a not uncommon
> issue preventing vectorization when masked loads are not available.
> 
> Bootstrapped and tested on x86_64-unknown-linux-gnu.
> 
> I have a followup patch improving sinking that without this would
> cause more of the problematic sinking - now that we have a second
> sink pass after loop opts this looks like a reasonable approach?
> 
> OK?
> 
> Thanks,
> Richard.
> 
> 	PR tree-optimization/92335
> 	* tree-ssa-sink.cc (select_best_block): Before loop
> 	optimizations avoid sinking unconditional loads/stores
> 	in innermost loops to conditional executed places.
> 
> 	* gcc.dg/tree-ssa/ssa-sink-10.c: Disable vectorizing.
> 	* gcc.dg/tree-ssa/predcom-9.c: Clone from ssa-sink-10.c,
> 	expect predictive commoning to happen instead of sinking.
> 	* gcc.dg/vect/pr65947-3.c: Adjust.
I think it's reasonable -- there's probably going to be cases where it's 
not great, but more often than not I think it's going to be a reasonable 
heuristic.

If there is undesirable fallout, better to find it over the coming 
months than next spring.  So I'd suggest we go forward now to give more 
time to find any pathological cases (if they exist).

Jeff

  reply	other threads:[~2023-07-31 15:33 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-28  7:05 Richard Biener
2023-07-31 15:33 ` Jeff Law [this message]
2023-08-02  8:46   ` Richard Biener
2023-08-03 11:42     ` Prathamesh Kulkarni
2023-08-03 12:14       ` Richard Biener
2023-08-03 12:16         ` Richard Biener
2023-08-03 12:18           ` Richard Biener
2023-08-07  0:04             ` Prathamesh Kulkarni
2023-08-07  7:48               ` Richard Biener
2023-08-14 14:58                 ` Prathamesh Kulkarni
2023-08-15  7:36                   ` Richard Biener
2023-08-15  8:58                     ` Richard Sandiford
2023-08-17 17:10                       ` Prathamesh Kulkarni
2023-08-18  9:29                         ` Richard Biener
2023-08-18 11:41                           ` Richard Biener
2023-08-19 15:48                             ` Prathamesh Kulkarni
2023-08-21  6:57                               ` Richard Biener
2023-08-21 11:32                                 ` Prathamesh Kulkarni

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=320f94c3-8805-ec64-dd4b-0454c8ecce14@gmail.com \
    --to=jeffreyalaw@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=rguenther@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).