public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/113677] Missing `VEC_PERM_EXPR <{a, CST}, CST, {0, 1, 2, ...}>` optimization Date: Tue, 06 Feb 2024 17:05:46 +0000 [thread overview] Message-ID: <bug-113677-4-AcPHostfFE@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-113677-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113677 --- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Note it is not just about constants either. Take: ``` #define vect64 __attribute__((vector_size(8) )) #define vect128 __attribute__((vector_size(16) )) vect128 unsigned int f(vect64 unsigned int a, vect64 unsigned int b) { vect64 unsigned int zero={0, 0}; return __builtin_shufflevector (a, b, 0, 1, 2, 3); } ``` We get: ``` _1 = {a_3(D), { 0, 0 }}; _2 = {b_4(D), { 0, 0 }}; _5 = VEC_PERM_EXPR <_1, _2, { 0, 1, 4, 5 }>; ``` Which obvious could be done to just: `_5 = {a_3(D), b_4(D)};`
next prev parent reply other threads:[~2024-02-06 17:05 UTC|newest] Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-01-31 1:46 [Bug tree-optimization/113677] New: " pinskia at gcc dot gnu.org 2024-01-31 1:47 ` [Bug tree-optimization/113677] " pinskia at gcc dot gnu.org 2024-01-31 2:16 ` pinskia at gcc dot gnu.org 2024-01-31 8:27 ` rguenth at gcc dot gnu.org 2024-02-06 17:05 ` pinskia at gcc dot gnu.org [this message] 2024-03-08 5:08 ` 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-113677-4-AcPHostfFE@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: linkBe 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).