public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
@ 2015-05-21  9:26 schwab@linux-m68k.org
  2015-05-21 10:41 ` [Bug rtl-optimization/66237] [6 " rguenth at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: schwab@linux-m68k.org @ 2015-05-21  9:26 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 66237
           Summary: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c
                    compilation,  -fprofile-use -D_PROFILE_USE (internal
                    compiler error)
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: rtl-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: schwab@linux-m68k.org
                CC: miyuki at gcc dot gnu.org
  Target Milestone: ---
            Target: aarch64-*-*

$ gcc/xgcc -Bgcc/ ../gcc/testsuite/gcc.dg/tree-prof/pr34999.c -O2
-freorder-blocks-and-partition -fprofile-generate -D_PROFILE_GENERATE -lm -o
pr34999.x01
$ ./pr34999.x01
$ gcc/xgcc -Bgcc/ ../gcc/testsuite/gcc.dg/tree-prof/pr34999.c -O2
-freorder-blocks-and-partition -fprofile-use -D_PROFILE_USE -lm -o pr34999.x02
../gcc/testsuite/gcc.dg/tree-prof/pr34999.c: In function ‘main’:
../gcc/testsuite/gcc.dg/tree-prof/pr34999.c:44:1: internal compiler error: in
as_a, at is-a.h:192
 }
 ^
0xe72e5f rtx_jump_insn* as_a<rtx_jump_insn*, rtx_insn>(rtx_insn*)
        ../../gcc/is-a.h:192
0xe72e5f fix_crossing_conditional_branches
        ../../gcc/bb-reorder.c:2047
0xe72e5f execute
        ../../gcc/bb-reorder.c:2742

f9a00e9e5f0f056b558f8615e3c030d37923ee72 is the first bad commit
commit f9a00e9e5f0f056b558f8615e3c030d37923ee72
Author: miyuki <miyuki@138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Wed May 20 19:39:42 2015 +0000

    Promote types of RTL expressions to more derived ones.
>From gcc-bugs-return-486905-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Thu May 21 09:26:01 2015
Return-Path: <gcc-bugs-return-486905-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 120556 invoked by alias); 21 May 2015 09:26:00 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 120465 invoked by uid 48); 21 May 2015 09:25:56 -0000
From: "ubizjak at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug rtl-optimization/66236] [6 Regression] FAIL: gcc.c-torture/execute/pr42691.c on alpha-linux-gnu
Date: Thu, 21 May 2015 09:26:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: rtl-optimization
X-Bugzilla-Version: 6.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ubizjak at gmail dot com
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-66236-4-2rpV8ZHavk@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-66236-4@http.gcc.gnu.org/bugzilla/>
References: <bug-66236-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-05/txt/msg01745.txt.bz2
Content-length: 548

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

Uroš Bizjak <ubizjak at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |law at gcc dot gnu.org,
                   |                            |thopre01 at gcc dot gnu.org

--- Comment #1 from Uroš Bizjak <ubizjak at gmail dot com> ---
Caused by r223113.

This problem can be triggered by a crosscompiler to alpha-linux-gnu.
>From gcc-bugs-return-486907-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Thu May 21 09:28:59 2015
Return-Path: <gcc-bugs-return-486907-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 129723 invoked by alias); 21 May 2015 09:28:59 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 129665 invoked by uid 48); 21 May 2015 09:28:54 -0000
From: "olegendo at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/65979] Multiple issues in conftest.c prevent build on sh4-linux-gnu
Date: Thu, 21 May 2015 09:28:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: target
X-Bugzilla-Version: 5.1.1
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: olegendo at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-65979-4-H58f0XrLQC@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-65979-4@http.gcc.gnu.org/bugzilla/>
References: <bug-65979-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-05/txt/msg01747.txt.bz2
Content-length: 1857

https://gcc.gnu.org/bugzilla/show_bug.cgi?ide979

--- Comment #19 from Oleg Endo <olegendo at gcc dot gnu.org> ---
(In reply to Oleg Endo from comment #18)

> Yes, that is true.  However, because op0, op1, op2 are all "arith_reg_dest"
> the peephole will only match if those are GP regs.  Each captured insn will
> only reference a single GP reg, because DImode moves should have been
> smashed into SImode moves before the peephole2 pass.  Thus, I think it
> should be safe to just force the mode of op0 to SImode.  I'll try it out.

The following seems to work OK and I'd propose this as a fix for the problem:

Index: gcc/config/sh/sh.md
==================================================================--- gcc/config/sh/sh.md (revision 223416)
+++ gcc/config/sh/sh.md (working copy)
@@ -14721,7 +14721,11 @@
        || REGNO (operands[2]) == REGNO (operands[5]))"
   [(const_int 0)]
 {
-  sh_check_add_incdec_notes (emit_move_insn (operands[2], operands[3]));
+  if (REGNO (operands[1]) == REGNO (operands[2]))
+      operands[2] = gen_rtx_REG (SImode, REGNO (operands[0]));
+
+  sh_check_add_incdec_notes (emit_insn (gen_rtx_SET (operands[2],
+                                                    operands[3])));
   emit_insn (gen_tstsi_t (operands[2],
                          gen_rtx_REG (SImode, (REGNO (operands[1])))));
 })
@@ -14748,7 +14752,8 @@
        || REGNO (operands[2]) == REGNO (operands[5]))"
   [(const_int 0)]
 {
-  sh_check_add_incdec_notes (emit_move_insn (operands[2], operands[3]));
+  sh_check_add_incdec_notes (emit_insn (gen_rtx_SET (operands[2],
+                                                    operands[3])));
   emit_insn (gen_tstsi_t (operands[2],
                          gen_rtx_REG (SImode, (REGNO (operands[1])))));
 })


Could you guys please test this patch?  Actually, now it looks quite obvious I
think.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
@ 2015-05-21 10:41 ` rguenth at gcc dot gnu.org
  2015-05-21 14:04 ` miyuki at gcc dot gnu.org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu.org @ 2015-05-21 10:41 UTC (permalink / raw)
  To: gcc-bugs

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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |6.0
            Summary|[6.0 regression] FAIL:      |[6 regression] FAIL:
                   |gcc.dg/tree-prof/pr34999.c  |gcc.dg/tree-prof/pr34999.c
                   |compilation,  -fprofile-use |compilation,  -fprofile-use
                   |-D_PROFILE_USE (internal    |-D_PROFILE_USE (internal
                   |compiler error)             |compiler error)


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
  2015-05-21 10:41 ` [Bug rtl-optimization/66237] [6 " rguenth at gcc dot gnu.org
@ 2015-05-21 14:04 ` miyuki at gcc dot gnu.org
  2015-05-21 14:10 ` schwab@linux-m68k.org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: miyuki at gcc dot gnu.org @ 2015-05-21 14:04 UTC (permalink / raw)
  To: gcc-bugs

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

Mikhail Maltsev <miyuki at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2015-05-21
           Assignee|unassigned at gcc dot gnu.org      |miyuki at gcc dot gnu.org
     Ever confirmed|0                           |1

--- Comment #1 from Mikhail Maltsev <miyuki at gcc dot gnu.org> ---
I could reproduce this ICE in somewhat "unnatural" conditions: profile is
generated by an x86_64 executable and used by aarch64 cross-compiler, but the
backtraces match, so I can start fixing it (and setting up QEMU...). If
possible, could you provide the actual profile (.gcda file) generated after
pr34999.x01 invocation? Does it differ from pristine build?


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
  2015-05-21 10:41 ` [Bug rtl-optimization/66237] [6 " rguenth at gcc dot gnu.org
  2015-05-21 14:04 ` miyuki at gcc dot gnu.org
@ 2015-05-21 14:10 ` schwab@linux-m68k.org
  2015-05-21 14:19 ` schwab@linux-m68k.org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: schwab@linux-m68k.org @ 2015-05-21 14:10 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Andreas Schwab <schwab@linux-m68k.org> ---
Created attachment 35589
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35589&action=edit
pr34999.gcda


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
                   ` (2 preceding siblings ...)
  2015-05-21 14:10 ` schwab@linux-m68k.org
@ 2015-05-21 14:19 ` schwab@linux-m68k.org
  2015-05-21 21:27 ` schwab@linux-m68k.org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: schwab@linux-m68k.org @ 2015-05-21 14:19 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Andreas Schwab <schwab@linux-m68k.org> ---
The profile files differ in a few bytes.

  9  17 ^O   265 M-5
 10 217 M-^O  44 $
 11 323 M-S  301 M-A
 12 166 v    165 u
 21 146 f    376 M-~
 22 213 M-^K 233 M-^[
 23 166 v     32 ^Z
 24  14 ^L   107 G


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
                   ` (3 preceding siblings ...)
  2015-05-21 14:19 ` schwab@linux-m68k.org
@ 2015-05-21 21:27 ` schwab@linux-m68k.org
  2015-05-22 22:58 ` miyuki at gcc dot gnu.org
  2015-07-06 22:03 ` miyuki at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: schwab@linux-m68k.org @ 2015-05-21 21:27 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #5 from Andreas Schwab <schwab@linux-m68k.org> ---
This fixes the ICE both on aarch64 and m68k.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
                   ` (4 preceding siblings ...)
  2015-05-21 21:27 ` schwab@linux-m68k.org
@ 2015-05-22 22:58 ` miyuki at gcc dot gnu.org
  2015-07-06 22:03 ` miyuki at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: miyuki at gcc dot gnu.org @ 2015-05-22 22:58 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from Mikhail Maltsev <miyuki at gcc dot gnu.org> ---
Author: miyuki
Date: Fri May 22 22:58:22 2015
New Revision: 223596

URL: https://gcc.gnu.org/viewcvs?rev=223596&root=gcc&view=rev
Log:
PR rtl-optimization/66237

* bb-reorder.c (fix_crossing_conditional_branches): Fix wrong
location of an "as_a" cast.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/bb-reorder.c


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [Bug rtl-optimization/66237] [6 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation,  -fprofile-use -D_PROFILE_USE (internal compiler error)
  2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
                   ` (5 preceding siblings ...)
  2015-05-22 22:58 ` miyuki at gcc dot gnu.org
@ 2015-07-06 22:03 ` miyuki at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: miyuki at gcc dot gnu.org @ 2015-07-06 22:03 UTC (permalink / raw)
  To: gcc-bugs

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

Mikhail Maltsev <miyuki at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #7 from Mikhail Maltsev <miyuki at gcc dot gnu.org> ---
Though I could not fully test this fix myself (I don't have an aarch64 box), I
suppose that it's safe to rely on test results published on the mailing list:
https://gcc.gnu.org/ml/gcc-testresults/2015-05/msg02567.html - fail
https://gcc.gnu.org/ml/gcc-testresults/2015-05/msg02714.html - pass
Thus, fixed for GCC 6.


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2015-07-06 22:03 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-21  9:26 [Bug rtl-optimization/66237] New: [6.0 regression] FAIL: gcc.dg/tree-prof/pr34999.c compilation, -fprofile-use -D_PROFILE_USE (internal compiler error) schwab@linux-m68k.org
2015-05-21 10:41 ` [Bug rtl-optimization/66237] [6 " rguenth at gcc dot gnu.org
2015-05-21 14:04 ` miyuki at gcc dot gnu.org
2015-05-21 14:10 ` schwab@linux-m68k.org
2015-05-21 14:19 ` schwab@linux-m68k.org
2015-05-21 21:27 ` schwab@linux-m68k.org
2015-05-22 22:58 ` miyuki at gcc dot gnu.org
2015-07-06 22:03 ` miyuki at gcc dot gnu.org

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).