public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Uros Bizjak <ubizjak@gmail.com>
To: Roger Sayle <roger@nextmovesoftware.com>
Cc: "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>
Subject: [PATCH] i386: Use "r" constraint in *andn<mode>3_doubleword_bmi
Date: Fri, 1 Jul 2022 17:28:16 +0200	[thread overview]
Message-ID: <CAFULd4a=bJ-n=8RKMXvtwrK3CjS-8ecfvgx-JkoH5TB7XvH==A@mail.gmail.com> (raw)
In-Reply-To: <CAFULd4YNvBmY_SxiJsMm=V_QyS6JAvRaM3EZ+4Tx3mHmTq8z9Q@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 345 bytes --]

ANDN is non-destructive, so use "r" instead of "0" for its operand 1 constraint.

2022-07-01  Uroš Bizjak  <ubizjak@gmail.com>

gcc/ChangeLog:

    * config/i386/i386.md (*andn<mode>3_doubleword_bmi):
    Use "r" constraint for operand 1.

Bootstrapped and regression tested on x86_64-linux-gnu {,-m32}.

Pushed to master.

Uros.

[-- Attachment #2: p.diff.txt --]
[-- Type: text/plain, Size: 557 bytes --]

diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md
index 352a21c585c..20c3b9a4122 100644
--- a/gcc/config/i386/i386.md
+++ b/gcc/config/i386/i386.md
@@ -10407,7 +10407,7 @@ (define_split
 (define_insn_and_split "*andn<mode>3_doubleword_bmi"
   [(set (match_operand:<DWI> 0 "register_operand" "=r")
 	(and:<DWI>
-	  (not:<DWI> (match_operand:<DWI> 1 "register_operand" "0"))
+	  (not:<DWI> (match_operand:<DWI> 1 "register_operand" "r"))
 	  (match_operand:<DWI> 2 "nonimmediate_operand" "ro")))
    (clobber (reg:CC FLAGS_REG))]
   "TARGET_BMI"

      reply	other threads:[~2022-07-01 15:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-01 10:17 [Committed] Add constraints to new andn<dwi>_doubleword_bmi pattern in i386.md Roger Sayle
2022-07-01 11:18 ` Uros Bizjak
2022-07-01 15:28   ` Uros Bizjak [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='CAFULd4a=bJ-n=8RKMXvtwrK3CjS-8ecfvgx-JkoH5TB7XvH==A@mail.gmail.com' \
    --to=ubizjak@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=roger@nextmovesoftware.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).