public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenther at suse dot de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/52252] An opportunity for x86 gcc vectorizer (gain up to 3 times)
Date: Tue, 28 Nov 2023 10:55:24 +0000 [thread overview]
Message-ID: <bug-52252-4-6N8fLJesMe@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-52252-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=52252
--- Comment #11 from rguenther at suse dot de <rguenther at suse dot de> ---
On Tue, 28 Nov 2023, pinskia at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=52252
>
> Andrew Pinski <pinskia at gcc dot gnu.org> changed:
>
> What |Removed |Added
> ----------------------------------------------------------------------------
> CC| |pinskia at gcc dot gnu.org
>
> --- Comment #10 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
> Note there is also a missing scalar optimization here also (which will improve
> the vectorized version in the end too).
>
> Right now we have the following match pattern:
> /* MIN (~X, ~Y) -> ~MAX (X, Y)
> MAX (~X, ~Y) -> ~MIN (X, Y) */
> (for minmax (min max)
> maxmin (max min)
> (simplify
> (minmax (bit_not:s@2 @0) (bit_not:s@3 @1))
> (bit_not (maxmin @0 @1)))
>
>
> But that does not match here due to the :s. I am not 100% sure but trading 2
> possible bit_not for adding another might end up improving things ...
We're lacking a way to say one of the bit_not should be single-used,
one multi-use would be OK and a fair trade-off - not sure if that
would be enough here, of course. That would mena changing to
a condition with single_use ().
next prev parent reply other threads:[~2023-11-28 10:55 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-14 22:42 [Bug c/52252] New: " evstupac at gmail dot com
2012-02-15 11:55 ` [Bug tree-optimization/52252] " rguenth at gcc dot gnu.org
2012-02-29 12:34 ` evstupac at gmail dot com
2012-07-13 8:48 ` rguenth at gcc dot gnu.org
2014-02-11 14:27 ` evstupac at gmail dot com
2014-05-07 12:11 ` kyukhin at gcc dot gnu.org
2014-06-11 8:38 ` kyukhin at gcc dot gnu.org
2014-06-18 7:47 ` kyukhin at gcc dot gnu.org
2023-08-31 7:07 ` rguenth at gcc dot gnu.org
2023-11-28 6:06 ` pinskia at gcc dot gnu.org
2023-11-28 10:55 ` rguenther at suse dot de [this message]
2023-11-28 22:24 ` pinskia at gcc dot gnu.org
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-52252-4-6N8fLJesMe@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).