public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
@ 2010-10-25 20:54 zsojka at seznam dot cz
  2010-10-25 20:58 ` [Bug target/46171] " pinskia at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: zsojka at seznam dot cz @ 2010-10-25 20:54 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: [4.6 Regression] ICE: in gen_rtx_SUBREG, at
                    emit-rtl.c:774 with -fno-tree-dce -g
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: rtl-optimization
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: zsojka@seznam.cz


Created attachment 22151
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22151
reduced testcase

Compiler output:
$ gcc -O -fno-tree-dce -g pr46171.c 
pr46171.c: In function 'foo':
pr46171.c:8:1: internal compiler error: in gen_rtx_SUBREG, at emit-rtl.c:774
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.

Tested revisions:
r165915 - crash
r165699 - crash
r163636 - OK
4.5 r165781 - OK


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

* [Bug target/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
@ 2010-10-25 20:58 ` pinskia at gcc dot gnu.org
  2010-10-26  0:50 ` jakub at gcc dot gnu.org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: pinskia at gcc dot gnu.org @ 2010-10-25 20:58 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|rtl-optimization            |target
   Target Milestone|---                         |4.6.0


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

* [Bug target/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
  2010-10-25 20:58 ` [Bug target/46171] " pinskia at gcc dot gnu.org
@ 2010-10-26  0:50 ` jakub at gcc dot gnu.org
  2010-10-26  7:49 ` hjl.tools at gmail dot com
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-10-26  0:50 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P1
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2010.10.26 00:50:48
                 CC|                            |aoliva at gcc dot gnu.org
     Ever Confirmed|0                           |1

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-10-26 00:50:48 UTC ---
This crash is from dead_debug_insert_before, will look at it.


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

* [Bug target/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
  2010-10-25 20:58 ` [Bug target/46171] " pinskia at gcc dot gnu.org
  2010-10-26  0:50 ` jakub at gcc dot gnu.org
@ 2010-10-26  7:49 ` hjl.tools at gmail dot com
  2010-10-27  2:51 ` jakub at gcc dot gnu.org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: hjl.tools at gmail dot com @ 2010-10-26  7:49 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> 2010-10-26 07:49:50 UTC ---
It is caused by revision 165452:

http://gcc.gnu.org/ml/gcc-cvs/2010-10/msg00636.html


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

* [Bug target/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
                   ` (2 preceding siblings ...)
  2010-10-26  7:49 ` hjl.tools at gmail dot com
@ 2010-10-27  2:51 ` jakub at gcc dot gnu.org
  2010-11-09 19:05 ` [Bug debug/46171] " jakub at gcc dot gnu.org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-10-27  2:51 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-10-27 02:51:32 UTC ---
So we have RTL like:
(insn 6 3 7 2 (set (reg:SF 21 xmm0)
        (reg/v:SF 61 [ f ])) pr46171.c:7 110 {*movsf_internal}
     (nil))

(call_insn 7 6 17 2 (set (reg:SF 21 xmm0)
        (call (mem:QI (symbol_ref:DI ("barf") [flags 0x41] <function_decl
0x7ffff16d1000 barf>) [0 S1 A8])
            (const_int 0 [0]))) pr46171.c:7 883 {*call_value_0_rex64}
     (nil)
    (expr_list:REG_DEP_TRUE (use (reg:SF 21 xmm0))
        (nil)))

(debug_insn 17 7 9 2 (var_location:SF D#2 (reg:SF 21 xmm0)) -1
     (nil))

(debug_insn 9 17 10 2 (var_location:SF f (debug_expr:SF D#2)) pr46171.c:7 -1
     (nil))

(insn 10 9 11 2 (set (reg:QI 0 ax)
        (const_int 0 [0])) pr46171.c:8 66 {*movqi_internal}
     (nil))

(call_insn 11 10 16 2 (set (reg:DF 21 xmm0)
        (call (mem:QI (symbol_ref:DI ("bard") [flags 0x41] <function_decl
0x7ffff16b2f00 bard>) [0 S1 A8])
            (const_int 0 [0]))) pr46171.c:8 883 {*call_value_0_rex64}
     (expr_list:REG_UNUSED (reg:DF 21 xmm0)
        (nil))
    (expr_list:REG_DEP_TRUE (use (reg:QI 0 ax))
        (nil)))

(debug_insn 16 11 13 2 (var_location:DF D#1 (reg:DF 21 xmm0)) -1
     (nil))

(debug_insn 13 16 0 2 (var_location:DF d (debug_expr:DF D#1)) pr46171.c:8 -1
     (nil))

debug insn 16 adds DFmode use of xmm0 via dead_debug_add.  Then the call_insn
before it isn't called for reg 21, as there are no uses of it, just sets.
Then another dead_debug_add is called for register 21 on insn 17, this time in
SFmode and then finally a dead_debug_insert_before is called on the first call
insn because reg 21 is also used there, not just set.  As we have both SFmode
and DFmode in dead debug structures for reg 21, it tries to create a SFmode
SUBREG of the DFmode DEBUG_EXPR and ICEs.


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

* [Bug debug/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
                   ` (3 preceding siblings ...)
  2010-10-27  2:51 ` jakub at gcc dot gnu.org
@ 2010-11-09 19:05 ` jakub at gcc dot gnu.org
  2010-11-09 19:21 ` jakub at gcc dot gnu.org
  2010-11-10 12:42 ` jakub at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-11-09 19:05 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-11-09 19:04:48 UTC ---
Author: jakub
Date: Tue Nov  9 19:04:44 2010
New Revision: 166504

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=166504
Log:
    PR debug/46171
    * df-problems.c (struct dead_debug_use, struct dead_debug): Move
    earlier.
    (df_set_unused_notes_for_mw, df_create_unused_note): Add DEBUG
    argument, call dead_debug_reset when adding REG_UNUSED note.
    (dead_debug_reset): New function.
    (df_note_bb_compute): Adjust df_set_unused_notes_for_mw and
    df_create_unused_note callers.

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

Added:
    trunk/gcc/testsuite/gcc.dg/pr46171.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/df-problems.c
    trunk/gcc/testsuite/ChangeLog


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

* [Bug debug/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
                   ` (4 preceding siblings ...)
  2010-11-09 19:05 ` [Bug debug/46171] " jakub at gcc dot gnu.org
@ 2010-11-09 19:21 ` jakub at gcc dot gnu.org
  2010-11-10 12:42 ` jakub at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-11-09 19:21 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

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

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-11-09 19:21:34 UTC ---
Fixed.


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

* [Bug debug/46171] [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g
  2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
                   ` (5 preceding siblings ...)
  2010-11-09 19:21 ` jakub at gcc dot gnu.org
@ 2010-11-10 12:42 ` jakub at gcc dot gnu.org
  6 siblings, 0 replies; 8+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-11-10 12:42 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

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

--- Comment #6 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-11-10 12:42:22 UTC ---
*** Bug 46409 has been marked as a duplicate of this bug. ***


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

end of thread, other threads:[~2010-11-10 12:42 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-10-25 20:54 [Bug rtl-optimization/46171] New: [4.6 Regression] ICE: in gen_rtx_SUBREG, at emit-rtl.c:774 with -fno-tree-dce -g zsojka at seznam dot cz
2010-10-25 20:58 ` [Bug target/46171] " pinskia at gcc dot gnu.org
2010-10-26  0:50 ` jakub at gcc dot gnu.org
2010-10-26  7:49 ` hjl.tools at gmail dot com
2010-10-27  2:51 ` jakub at gcc dot gnu.org
2010-11-09 19:05 ` [Bug debug/46171] " jakub at gcc dot gnu.org
2010-11-09 19:21 ` jakub at gcc dot gnu.org
2010-11-10 12:42 ` jakub 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).