public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/99416] s211 benchmark of TSVC is vectorized by icc and not by gcc
Date: Tue, 12 Jul 2022 09:59:59 +0000	[thread overview]
Message-ID: <bug-99416-4-BAUPhKRlxC@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-99416-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99416

--- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Richard Biener from comment #3)
> Note it's only the outer loop that confuses us here.  With that removed we
> have
> the following because of yet another "heuristic" to disable distribution.

In fact we first analyze the whole nest but then continue to look at the inner
loop only, so this isn't really an issue.

The fusing because of shared memory refs is only because of the double use
of d[i], b[i], b[i-1] or b[i+1] are not detected as problematic for
distribution (the "same memory object" check isn't working as intended).

Fuse partitions because they have shared memory refs:
  Part 1: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 15, 16
  Part 2: 0, 1, 5, 9, 10, 11, 12, 13, 14, 15, 16

note the intersection of both partitions includes half of the stmts
(0, 1, 5, 6, 15, 16) that would be duplicated (5 is the d[i] load) while
the other half is different.

To defeat the final fusing reason we need a positive motivation, like
tracking whether we know a partition can or cannot be vectorized (or
whether we are not sure).  For the partition containing the b[i], b[i+1]
dependence distance of 1 we know we cannot vectorize (with a VF > 0).

      parent reply	other threads:[~2022-07-12  9:59 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-05 16:20 [Bug middle-end/99416] New: " hubicka at gcc dot gnu.org
2021-03-08  8:50 ` [Bug tree-optimization/99416] " rguenth at gcc dot gnu.org
2022-07-11 13:20 ` rguenth at gcc dot gnu.org
2022-07-11 13:27 ` rguenth at gcc dot gnu.org
2022-07-12  9:59 ` rguenth at gcc dot gnu.org [this message]

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=bug-99416-4-BAUPhKRlxC@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /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).