public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/94790] Failure to use andn in specific pattern in which it is available Date: Thu, 13 Jan 2022 05:14:30 +0000 [thread overview] Message-ID: <bug-94790-4-WNThNs11r1@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-94790-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94790 --- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by hongtao Liu <liuhongt@gcc.gnu.org>: https://gcc.gnu.org/g:5f19303ada7db92c155332e7ba317233ca05946b commit r12-6538-g5f19303ada7db92c155332e7ba317233ca05946b Author: Haochen Jiang <haochen.jiang@intel.com> Date: Wed Jan 12 10:01:21 2022 +0800 Optimize a ^ ((a ^ b) & mask) to (~mask & a) | (b & mask). From the perspective of the pipeline, `andn + and + ior` version take 2 cycles(AND and ANDN doesn't have dependence), but xor + and + xor will take 3 cycles. - xorl %edi, %esi andl %edx, %esi - movl %esi, %eax - xorl %edi, %eax + andn %edi, %edx, %eax + orl %esi, %eax gcc/ChangeLog: PR target/94790 * config/i386/i386.md (*xor2andn): New define_insn_and_split. gcc/testsuite/ChangeLog: PR target/94790 * gcc.target/i386/pr94790-1.c: New test. * gcc.target/i386/pr94790-2.c: Ditto.
next prev parent reply other threads:[~2022-01-13 5:14 UTC|newest] Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-04-27 9:30 [Bug tree-optimization/94790] New: " gabravier at gmail dot com 2020-04-27 10:21 ` [Bug rtl-optimization/94790] " rguenth at gcc dot gnu.org 2021-12-27 5:53 ` pinskia at gcc dot gnu.org 2021-12-27 7:20 ` luoxhu at gcc dot gnu.org 2021-12-27 7:49 ` luoxhu at gcc dot gnu.org 2022-01-12 6:09 ` crazylht at gmail dot com 2022-01-13 5:14 ` cvs-commit at gcc dot gnu.org [this message] 2022-01-13 5:17 ` crazylht at gmail dot com 2022-01-14 5:02 ` cvs-commit 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-94790-4-WNThNs11r1@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).