public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "ktkachov at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/99195] Optimise away vec_concat of 64-bit AdvancedSIMD operations with zeroes in aarch64
Date: Thu, 04 Mar 2021 11:55:12 +0000	[thread overview]
Message-ID: <bug-99195-4-iHtzGBCrZj@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-99195-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #1 from ktkachov at gcc dot gnu.org ---
Using a define_subst like:
(define_subst "add_vec_concat_subst"
  [(set (match_operand:VDMOV 0 "" "")
        (match_operand:VDMOV 1 "" ""))]
  "!BYTES_BIG_ENDIAN"
  [(set (match_operand:<VDBL> 0 "register_operand" "=w")
        (vec_concat:<VDBL>
         (match_dup 1)
         (match_operand:VDMOV 2 "aarch64_simd_or_scalar_imm_zero")))]
)

(define_subst_attr "add_vec_concat" "add_vec_concat_subst" "" "_vec_concat")

and adding it to patterns in aarch64-simd.md through <add_vec_concat> seems to
work. It doesn't handle the big-endian case, but maybe we can handle that
separately (or with a second define_subst?)

Does this approach make sense?

  reply	other threads:[~2021-03-04 11:55 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-22 10:27 [Bug target/99195] New: " ktkachov at gcc dot gnu.org
2021-03-04 11:55 ` ktkachov at gcc dot gnu.org [this message]
2021-03-07  2:05 ` [Bug target/99195] " pinskia at gcc dot gnu.org
2023-04-21 17:57 ` cvs-commit at gcc dot gnu.org
2023-04-23 13:41 ` cvs-commit at gcc dot gnu.org
2023-04-25 13:55 ` cvs-commit at gcc dot gnu.org
2023-04-28  8:34 ` cvs-commit at gcc dot gnu.org
2023-05-03 10:16 ` cvs-commit at gcc dot gnu.org
2023-05-03 10:18 ` cvs-commit at gcc dot gnu.org
2023-05-04  8:45 ` cvs-commit at gcc dot gnu.org
2023-05-04  8:45 ` cvs-commit at gcc dot gnu.org
2023-05-10  9:42 ` cvs-commit at gcc dot gnu.org
2023-05-10 10:51 ` cvs-commit at gcc dot gnu.org
2023-05-10 11:02 ` cvs-commit at gcc dot gnu.org
2023-05-15  8:50 ` cvs-commit at gcc dot gnu.org
2023-05-15  8:56 ` cvs-commit at gcc dot gnu.org
2023-05-24 13:53 ` cvs-commit at gcc dot gnu.org
2023-05-25 14:01 ` cvs-commit at gcc dot gnu.org
2023-05-31 16:45 ` cvs-commit at gcc dot gnu.org
2023-05-31 16:46 ` cvs-commit at gcc dot gnu.org
2024-02-27  8:38 ` pinskia at gcc dot gnu.org
2024-04-04  8:21 ` ktkachov 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-99195-4-iHtzGBCrZj@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).