From: Jakub Jelinek <jakub@redhat.com>
To: Hongtao Liu <crazylht@gmail.com>
Cc: Jeff Law <law@redhat.com>, GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH][AVX512]Lower AVX512 vector compare to AVX version when dest is vector
Date: Thu, 21 Jan 2021 14:47:56 +0100 [thread overview]
Message-ID: <20210121134756.GB4020736@tucnak> (raw)
In-Reply-To: <CAMZc-bz5+EkNCQ+r-MeyhReVkCyHoQamu9bn8A8=KMK70Qn9JA@mail.gmail.com>
On Wed, Jan 06, 2021 at 11:34:32AM +0800, Hongtao Liu via Gcc-patches wrote:
> > >>
> > >> Note there's a data dependency between them. insn 7 feeds insn 9. When
> > >> there's a data dependency, combiner patterns are usually the better
> > >> choice than peepholes. I think you'd be looking to match something
> > >> likethis (from the . combine dump):
> > >>
>
> Using combiner patterns, details is discussed in PR98348
>
> Boottrapped and regtested on x86_64-linux-gnu{-m32,} for both GCC10 and trunk.
> gcc/ChangeLog:
>
> PR target/96891
> PR target/98348
> * config/i386/sse.md (VI_128_256): New mode iterator.
> (*avx_cmp<mode>3_1, *avx_cmp<mode>3_2, *avx_cmp<mode>3_3,
> *avx_cmp<mode>3_4, *avx2_eq<mode>3, *avx2_pcmp<mode>3_1,
> *avx2_pcmp<mode>3_2, *avx2_gt<mode>3): New
> define_insn_and_split to lower avx512 vector comparison to avx
> version when dest is vector.
> (*<avx512>_cmp<mode>3,*<avx512>_cmp<mode>3,*<avx512>_ucmp<mode>3):
> define_insn_and_split for negating the comparison result.
> * config/i386/predicates.md (float_vector_all_ones_operand):
> New predicate.
> * config/i386/i386-expand.c (ix86_expand_sse_movcc): Use
> general NOT operator without UNSPEC_MASKOP.
>
> gcc/testsuite/ChangeLog:
>
> PR target/96891
> PR target/98348
> * gcc.target/i386/avx512bw-pr96891-1.c: New test.
> * gcc.target/i386/avx512f-pr96891-1.c: New test.
> * gcc.target/i386/avx512f-pr96891-2.c: New test.
> * gcc.target/i386/avx512f-pr96891-3.c: New test.
> * g++.target/i386/avx512f-pr96891-1.C: New test.
> * gcc.target/i386/bitwise_mask_op-3.c: Adjust testcase.
Ok for trunk. I'd prefer not to backport it to GCC 10.
Jakub
prev parent reply other threads:[~2021-01-21 13:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-02 9:34 Hongtao Liu
2020-09-02 12:20 ` H.J. Lu
2020-11-17 0:05 ` Jeff Law
2020-11-17 3:10 ` Hongtao Liu
2020-11-30 16:38 ` Jeff Law
2021-01-06 3:34 ` Hongtao Liu
2021-01-21 13:47 ` Jakub Jelinek [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=20210121134756.GB4020736@tucnak \
--to=jakub@redhat.com \
--cc=crazylht@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=law@redhat.com \
/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).