public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "steven at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug inline-asm/56148] [4.8 Regression] inline asm matching constraint with different mode
Date: Tue, 12 Feb 2013 16:25:00 -0000	[thread overview]
Message-ID: <bug-56148-4-4gk23Z8vtC@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-56148-4@http.gcc.gnu.org/bugzilla/>


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56148

Steven Bosscher <steven at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |steven at gcc dot gnu.org

--- Comment #7 from Steven Bosscher <steven at gcc dot gnu.org> 2013-02-12 16:24:39 UTC ---
(in my previous post I of course mean inputs and constraints...)

Breaking down the insn once more in something that's more readable
to me at least:

(parallel [
   (set (reg:DI 63 [ a ]) (asm_in[0] (reg:SI 67) "0"))
   (set (reg:DI 64 [ c ]) (asm_in[1] (reg:DI 65) "mr"))
   (set (reg:DI 65 [ d ]) (asm_in[2] (reg:SI 69) "1"))
   (set (reg:DI 66 [ b ]) (asm_in[3] (reg:DI 65) "2"))
                          (asm_in[4] (reg:SI 67) "3")])

so
- r67:SI must match r63:DI
- r69:SI must match r64:DI
- r65:DI must match r65:DI
- r67:SI must match r66:DI

The last constraint comes from CSE, which transforms:

[   (reg:SI 67)
    (reg:DI 68)
    (reg:SI 69)
    (reg:DI 70)
    (reg:SI 71) ]

to

[   (reg:SI 67)
    (reg/f:DI 68)
    (reg:SI 69)
    (reg/f:DI 68)
    (reg:SI 67) ]

because r70 and r68 have the same value before CSE:

    6: {r68:DI=frame:DI-0x10;clobber flags:CC;}
    8: {r70:DI=frame:DI-0x10;clobber flags:CC;}

and CSE cleans that up:

    6: {r68:DI=frame:DI-0x10;clobber flags:CC;}
    8: r70:DI=r68:DI

Disabling or undoing that transformation makes the ICE disappear.
This is also in effect what old reload does with reload insn 21.


  parent reply	other threads:[~2013-02-12 16:25 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-30 12:02 [Bug inline-asm/56148] New: " jakub at gcc dot gnu.org
2013-01-30 12:03 ` [Bug inline-asm/56148] " jakub at gcc dot gnu.org
2013-02-04  3:07 ` sergio at serjux dot com
2013-02-04  3:12 ` sergio at serjux dot com
2013-02-04  7:02 ` jakub at gcc dot gnu.org
2013-02-04 19:47 ` sergio at serjux dot com
2013-02-08 15:20 ` rguenth at gcc dot gnu.org
2013-02-12  0:15 ` steven at gcc dot gnu.org
2013-02-12 16:25 ` steven at gcc dot gnu.org [this message]
2013-02-12 17:45 ` vmakarov at gcc dot gnu.org
2013-02-12 18:10 ` steven at gcc dot gnu.org
2013-02-12 18:13 ` steven at gcc dot gnu.org
2013-02-12 18:38 ` sergio at serjux dot com
2013-02-12 18:52 ` vmakarov at redhat dot com
2013-02-21 17:46 ` sergio at serjux dot com
2013-02-22 14:40 ` fm3 at os dot inf.tu-dresden.de
2013-02-22 16:31 ` vmakarov 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-56148-4-4gk23Z8vtC@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).