public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug debug/42425]  New: ICE declaring local class
@ 2009-12-18 11:13 reichelt at gcc dot gnu dot org
  2009-12-19 12:16 ` [Bug debug/42425] " rguenth at gcc dot gnu dot org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2009-12-18 11:13 UTC (permalink / raw)
  To: gcc-bugs

The following valid code snippet triggers an ICE on trunk when compiled
with "-flto -g":

==========================
struct A
{
  virtual ~A();
};

void foo()
{
  struct B : A {};
  B b;
}
==========================

bug.cc: In member function 'B':
bug.cc:8:16: internal compiler error: tree check: expected class 'type', have
'declaration' (function_decl) in gen_type_die_with_usage, at dwarf2out.c:18739
Please submit a full bug report, [etc.]


-- 
           Summary: ICE declaring local class
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, lto
          Severity: normal
          Priority: P3
         Component: debug
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
@ 2009-12-19 12:16 ` rguenth at gcc dot gnu dot org
  2010-04-23 15:59 ` rguenth at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-12-19 12:16 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from rguenth at gcc dot gnu dot org  2009-12-19 12:15 -------
We free too many DECL and TYPE contexts which confuses dwarf2out.c.  Now in the
end the contexts shouldn't drag in too many extra trees though

1) we'd need support for streaming NAMESPACE_DECLs

2) we should be able to get rid of most abstract DECLs and references to them,
they are the source of most bloat in the lto streams for C++ code.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2009-12-19 12:15:48
               date|                            |


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
  2009-12-19 12:16 ` [Bug debug/42425] " rguenth at gcc dot gnu dot org
@ 2010-04-23 15:59 ` rguenth at gcc dot gnu dot org
  2010-04-26  9:13 ` rguenth at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-04-23 15:59 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from rguenth at gcc dot gnu dot org  2010-04-23 15:58 -------
Testing a patch.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |rguenth at gcc dot gnu dot
                   |dot org                     |org
             Status|NEW                         |ASSIGNED
   Last reconfirmed|2009-12-19 12:15:48         |2010-04-23 15:58:28
               date|                            |


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
  2009-12-19 12:16 ` [Bug debug/42425] " rguenth at gcc dot gnu dot org
  2010-04-23 15:59 ` rguenth at gcc dot gnu dot org
@ 2010-04-26  9:13 ` rguenth at gcc dot gnu dot org
  2010-04-26  9:17 ` rguenth at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-04-26  9:13 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from rguenth at gcc dot gnu dot org  2010-04-26 09:13 -------
Subject: Bug 42425

Author: rguenth
Date: Mon Apr 26 09:13:00 2010
New Revision: 158722

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=158722
Log:
2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/42425
        * tree.c (free_lang_data_in_type): Do not free TYPE_CONTEXT
        if emitting debug information and it is either a function
        or a namespace decl.

        * g++.dg/lto/20100423-2_0.C: New testcase.

Added:
    trunk/gcc/testsuite/g++.dg/lto/20100423-2_0.C
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree.c


-- 


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2010-04-26  9:13 ` rguenth at gcc dot gnu dot org
@ 2010-04-26  9:17 ` rguenth at gcc dot gnu dot org
  2010-05-02 15:32 ` rguenth at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-04-26  9:17 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from rguenth at gcc dot gnu dot org  2010-04-26 09:17 -------
Fixed.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
      Known to fail|                            |4.5.0
         Resolution|                            |FIXED
   Target Milestone|---                         |4.6.0


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2010-04-26  9:17 ` rguenth at gcc dot gnu dot org
@ 2010-05-02 15:32 ` rguenth at gcc dot gnu dot org
  2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
  2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-05-02 15:32 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from rguenth at gcc dot gnu dot org  2010-05-02 15:32 -------
*** Bug 43956 has been marked as a duplicate of this bug. ***


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |andrej dot gelenberg at udo
                   |                            |dot edu


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2010-05-02 15:32 ` rguenth at gcc dot gnu dot org
@ 2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
  2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-05-19 13:18 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from rguenth at gcc dot gnu dot org  2010-05-19 13:16 -------
Subject: Bug 42425

Author: rguenth
Date: Wed May 19 13:14:37 2010
New Revision: 159564

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=159564
Log:
2010-05-19  Richard Guenther  <rguenther@suse.de>

        Backport from mainline:
        2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/43455
        * tree-inline.c (tree_can_inline_p): Also check compatibility
        of return types.

        * gcc.dg/lto/20100423-1_0.c: New testcase.
        * gcc.dg/lto/20100423-1_1.c: Likewise.

        2010-04-23  Richard Guenther  <rguenther@suse.de>

        PR lto/42653
        * tree.c (free_lang_data_in_decl): Do not reset DECL_CONTEXT
        of FUNCTION_DECLs.

        * g++.dg/lto/20100423-1_0.C: New testcase.

        2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/42425
        * tree.c (free_lang_data_in_type): Do not free TYPE_CONTEXT
        if emitting debug information and it is either a function
        or a namespace decl.

        * g++.dg/lto/20100423-2_0.C: New testcase.

        2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/43080
        * gimple.c (gimple_decl_printable_name): Deal gracefully
        with a NULL DECL_NAME.

        * g++.dg/lto/20100423-3_0.C: New testcase.

        2010-04-30  Richard Guenther  <rguenther@suse.de>

        PR lto/43946
        * passes.c (init_optimization_passes): Move pass_ipa_free_lang_data
        first after all lowering passes.

        * gcc.dg/lto/20100430-1_0.c: New testcase.

Added:
    branches/gcc-4_5-branch/gcc/testsuite/g++.dg/lto/20100423-1_0.C
    branches/gcc-4_5-branch/gcc/testsuite/g++.dg/lto/20100423-2_0.C
    branches/gcc-4_5-branch/gcc/testsuite/g++.dg/lto/20100423-3_0.C
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/lto/20100423-1_0.c
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/lto/20100423-1_1.c
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/lto/20100430-1_0.c
Modified:
    branches/gcc-4_5-branch/gcc/ChangeLog
    branches/gcc-4_5-branch/gcc/gimple.c
    branches/gcc-4_5-branch/gcc/passes.c
    branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
    branches/gcc-4_5-branch/gcc/tree-inline.c
    branches/gcc-4_5-branch/gcc/tree.c


-- 


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


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

* [Bug debug/42425] ICE declaring local class
  2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
@ 2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
  6 siblings, 0 replies; 8+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-05-19 13:18 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from rguenth at gcc dot gnu dot org  2010-05-19 13:16 -------
Subject: Bug 42425

Author: rguenth
Date: Wed May 19 13:14:37 2010
New Revision: 159564

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=159564
Log:
2010-05-19  Richard Guenther  <rguenther@suse.de>

        Backport from mainline:
        2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/43455
        * tree-inline.c (tree_can_inline_p): Also check compatibility
        of return types.

        * gcc.dg/lto/20100423-1_0.c: New testcase.
        * gcc.dg/lto/20100423-1_1.c: Likewise.

        2010-04-23  Richard Guenther  <rguenther@suse.de>

        PR lto/42653
        * tree.c (free_lang_data_in_decl): Do not reset DECL_CONTEXT
        of FUNCTION_DECLs.

        * g++.dg/lto/20100423-1_0.C: New testcase.

        2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/42425
        * tree.c (free_lang_data_in_type): Do not free TYPE_CONTEXT
        if emitting debug information and it is either a function
        or a namespace decl.

        * g++.dg/lto/20100423-2_0.C: New testcase.

        2010-04-26  Richard Guenther  <rguenther@suse.de>

        PR lto/43080
        * gimple.c (gimple_decl_printable_name): Deal gracefully
        with a NULL DECL_NAME.

        * g++.dg/lto/20100423-3_0.C: New testcase.

        2010-04-30  Richard Guenther  <rguenther@suse.de>

        PR lto/43946
        * passes.c (init_optimization_passes): Move pass_ipa_free_lang_data
        first after all lowering passes.

        * gcc.dg/lto/20100430-1_0.c: New testcase.

Added:
    branches/gcc-4_5-branch/gcc/testsuite/g++.dg/lto/20100423-1_0.C
    branches/gcc-4_5-branch/gcc/testsuite/g++.dg/lto/20100423-2_0.C
    branches/gcc-4_5-branch/gcc/testsuite/g++.dg/lto/20100423-3_0.C
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/lto/20100423-1_0.c
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/lto/20100423-1_1.c
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/lto/20100430-1_0.c
Modified:
    branches/gcc-4_5-branch/gcc/ChangeLog
    branches/gcc-4_5-branch/gcc/gimple.c
    branches/gcc-4_5-branch/gcc/passes.c
    branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
    branches/gcc-4_5-branch/gcc/tree-inline.c
    branches/gcc-4_5-branch/gcc/tree.c


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.6.0                       |4.5.1


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


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

end of thread, other threads:[~2010-05-19 13:18 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-12-18 11:13 [Bug debug/42425] New: ICE declaring local class reichelt at gcc dot gnu dot org
2009-12-19 12:16 ` [Bug debug/42425] " rguenth at gcc dot gnu dot org
2010-04-23 15:59 ` rguenth at gcc dot gnu dot org
2010-04-26  9:13 ` rguenth at gcc dot gnu dot org
2010-04-26  9:17 ` rguenth at gcc dot gnu dot org
2010-05-02 15:32 ` rguenth at gcc dot gnu dot org
2010-05-19 13:18 ` rguenth at gcc dot gnu dot org
2010-05-19 13:18 ` rguenth at gcc dot gnu dot 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).