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/94291] [10 Regression] ICE: in reg_or_subregno, at jump.c:1928 at -Og since r10-3993-ga79048f6250febc1acce09d790035276d534e754
Date: Tue, 07 Apr 2020 19:31:02 +0000	[thread overview]
Message-ID: <bug-94291-4-Khd2zq3kcs@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-94291-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:c23c899aedf11069e992eed7358802b262d62f98

commit r10-7607-gc23c899aedf11069e992eed7358802b262d62f98
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Apr 7 21:30:12 2020 +0200

    combine: Fix split_i2i3 ICE [PR94291]

    The following testcase ICEs on armv7hl-linux-gnueabi.
    try_combine is called on:
    (gdb) p debug_rtx (i3)
    (insn 20 12 22 2 (set (mem/c:SI (plus:SI (reg/f:SI 102 sfp)
                    (const_int -4 [0xfffffffffffffffc])) [1 x+0 S4 A32])
            (reg:SI 125)) "pr94291.c":7:8 241 {*arm_movsi_insn}
         (expr_list:REG_DEAD (reg:SI 125)
            (nil)))
    (gdb) p debug_rtx (i2)
    (insn 12 7 20 2 (parallel [
                (set (reg:CC 100 cc)
                    (compare:CC (reg:SI 121 [ <retval> ])
                        (const_int 0 [0])))
                (set (reg:SI 125)
                    (reg:SI 121 [ <retval> ]))
            ]) "pr94291.c":7:8 248 {*movsi_compare0}
         (expr_list:REG_UNUSED (reg:CC 100 cc)
            (nil)))
    and tries to recognize cc = r121 cmp 0; [sfp-4] = r121 parallel,
    but that isn't recognized, so it splits it into two: split_i2i3
    [sfp-4] = r121 followed by cc = r121 cmp 0 which is recognized, but
    ICEs because the code below insist that the SET_DEST of newi2pat
    (or first set in PARALLEL thereof) must be a REG or SUBREG of REG,
    but it is a MEM in this case.  I don't see any condition that would
    guarantee that, perhaps for the swap_i2i3 case it was somehow guaranteed.

    As the code just wants to update LOG_LINKS and LOG_LINKS are only for
    registers, not for MEM or anything else, the patch just doesn't update
those
    if it isn't a REG or SUBREG of REG.

    2020-04-07  Jakub Jelinek  <jakub@redhat.com>

            PR rtl-optimization/94291
            PR rtl-optimization/84169
            * combine.c (try_combine): For split_i2i3, don't assume SET_DEST
            must be a REG or SUBREG of REG; if it is not one of these, don't
            update LOG_LINKs.

            * gcc.dg/pr94291.c: New test.

  parent reply	other threads:[~2020-04-07 19:31 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-23 18:55 [Bug rtl-optimization/94291] New: [10 Regression] ICE: in reg_or_subregno, at jump.c:1928 at -Og zsojka at seznam dot cz
2020-03-24  6:20 ` [Bug rtl-optimization/94291] " marxin at gcc dot gnu.org
2020-03-24  6:36 ` [Bug rtl-optimization/94291] [10 Regression] ICE: in reg_or_subregno, at jump.c:1928 at -Og since r10-3993-ga79048f6250febc1acce09d790035276d534e754 marxin at gcc dot gnu.org
2020-03-24 11:47 ` [Bug target/94291] " jakub at gcc dot gnu.org
2020-03-24 11:53 ` jakub at gcc dot gnu.org
2020-04-01  7:48 ` [Bug rtl-optimization/94291] " rguenth at gcc dot gnu.org
2020-04-01  7:57 ` jakub at gcc dot gnu.org
2020-04-07 19:31 ` cvs-commit at gcc dot gnu.org [this message]
2020-04-07 20:02 ` jakub at gcc dot gnu.org
2020-04-07 20:39 ` segher at gcc dot gnu.org
2020-04-07 20:42 ` jakub at gcc dot gnu.org
2020-04-07 20:54 ` segher 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-94291-4-Khd2zq3kcs@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).