public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/31260] New: ICE: segmentation fault on invalid code
@ 2007-03-19 9:18 wouter dot vermaelen at pi dot be
2007-03-19 9:27 ` [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code pinskia at gcc dot gnu dot org
` (10 more replies)
0 siblings, 11 replies; 12+ messages in thread
From: wouter dot vermaelen at pi dot be @ 2007-03-19 9:18 UTC (permalink / raw)
To: gcc-bugs
Using SVN revision 123051
> cat bug.ii
template<class T1> struct S1 {
template<bool T2> struct S2;
template<template<bool> class T3> struct S3 {
template<typename T4 = S3<S2> > struct S4 {};
struct S5 : S4<> {
> g++ bug.ii
bug-segv.ii:5: internal compiler error: Segmentation fault
--
Summary: ICE: segmentation fault on invalid code
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: wouter dot vermaelen at pi dot be
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
@ 2007-03-19 9:27 ` pinskia at gcc dot gnu dot org
2007-03-22 23:17 ` mmitchel at gcc dot gnu dot org
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-03-19 9:27 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from pinskia at gcc dot gnu dot org 2007-03-19 09:26 -------
It seems like this can be made into valid code and still ICE.
The valid code is:
template<class T1> struct S1 {
template<bool T2> struct S2;
template<template<bool> class T3> struct S3 {
template<typename T4=S3<S2> > struct S4 {};
struct S5 : S4<> {
};
};
};
-----
Note if I change how S5 is declared using a specific template argument instead
of <>, the crash goes away in that the follow compiles just fine:
template<class T1> struct S1 {
template<bool T2> struct S2;
template<template<bool> class T3> struct S3 {
template<typename T4=S3<S2> > struct S4 {};
struct S5 : S4<S3<S2> > {
};
};
};
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Keywords| |ice-on-invalid-code, ice-on-
| |valid-code
Last reconfirmed|0000-00-00 00:00:00 |2007-03-19 09:26:55
date| |
Summary|ICE: segmentation fault on |[4.1/4.2/4.3 Regression]
|invalid code |ICE: segmentation fault with
| |template code
Target Milestone|--- |4.1.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
2007-03-19 9:27 ` [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code pinskia at gcc dot gnu dot org
@ 2007-03-22 23:17 ` mmitchel at gcc dot gnu dot org
2007-04-08 22:16 ` reichelt at gcc dot gnu dot org
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2007-03-22 23:17 UTC (permalink / raw)
To: gcc-bugs
--
mmitchel at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
2007-03-19 9:27 ` [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code pinskia at gcc dot gnu dot org
2007-03-22 23:17 ` mmitchel at gcc dot gnu dot org
@ 2007-04-08 22:16 ` reichelt at gcc dot gnu dot org
2007-04-08 23:38 ` reichelt at gcc dot gnu dot org
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-04-08 22:16 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from reichelt at gcc dot gnu dot org 2007-04-08 23:15 -------
Btw, the bug appeared in GCC 4.0.2.
The code compiles with GCC 4.0.1 or earlier.
--
reichelt at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |reichelt at gcc dot gnu dot
| |org
Keywords| |monitored
Known to fail| |4.0.2 4.0.4 4.1.0 4.1.2
| |4.2.0 4.3.0
Known to work| |3.3.6 3.4.0 3.4.6 4.0.0
| |4.0.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (2 preceding siblings ...)
2007-04-08 22:16 ` reichelt at gcc dot gnu dot org
@ 2007-04-08 23:38 ` reichelt at gcc dot gnu dot org
2007-09-20 10:22 ` pcarlini at suse dot de
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2007-04-08 23:38 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from reichelt at gcc dot gnu dot org 2007-04-09 00:38 -------
Mark, this appeared with your patch for PR 23789:
2005-09-12 Mark Mitchell <mark@codesourcery.com>
PR c++/23789
* cvt.c (perform_qualification_conversions): Don't create
unnecessary NOP_EXPRs.
* pt.c (tsubst_template_arg): Use fold_non_dependent_expr.
--
reichelt at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mark at codesourcery dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (3 preceding siblings ...)
2007-04-08 23:38 ` reichelt at gcc dot gnu dot org
@ 2007-09-20 10:22 ` pcarlini at suse dot de
2007-12-01 13:54 ` pcarlini at suse dot de
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: pcarlini at suse dot de @ 2007-09-20 10:22 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pcarlini at suse dot de 2007-09-20 10:21 -------
On it.
--
pcarlini at suse dot de changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |pcarlini at suse dot de
|dot org |
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (4 preceding siblings ...)
2007-09-20 10:22 ` pcarlini at suse dot de
@ 2007-12-01 13:54 ` pcarlini at suse dot de
2008-07-04 22:01 ` [Bug c++/31260] [4.2/4.3/4.4 " jsm28 at gcc dot gnu dot org
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: pcarlini at suse dot de @ 2007-12-01 13:54 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from pcarlini at suse dot de 2007-12-01 13:54 -------
Unassigning, likely other can fix it much easily than me
--
pcarlini at suse dot de changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|pcarlini at suse dot de |unassigned at gcc dot gnu
| |dot org
Status|ASSIGNED |NEW
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.2/4.3/4.4 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (5 preceding siblings ...)
2007-12-01 13:54 ` pcarlini at suse dot de
@ 2008-07-04 22:01 ` jsm28 at gcc dot gnu dot org
2009-01-16 21:43 ` [Bug c++/31260] [4.2/4.3 " reichelt at gcc dot gnu dot org
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2008-07-04 22:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from jsm28 at gcc dot gnu dot org 2008-07-04 22:00 -------
Closing 4.1 branch.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|[4.1/4.2/4.3/4.4 Regression]|[4.2/4.3/4.4 Regression]
|ICE: segmentation fault with|ICE: segmentation fault with
|template code |template code
Target Milestone|4.1.3 |4.2.5
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (6 preceding siblings ...)
2008-07-04 22:01 ` [Bug c++/31260] [4.2/4.3/4.4 " jsm28 at gcc dot gnu dot org
@ 2009-01-16 21:43 ` reichelt at gcc dot gnu dot org
2009-01-16 22:35 ` sje at gcc dot gnu dot org
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2009-01-16 21:43 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from reichelt at gcc dot gnu dot org 2009-01-16 21:43 -------
Fixed on the trunk by Steve Ellcey's patch for PR38357.
Steve, would you mind backporting the patch to the 4.3 branch as it fixes an
ice-on-valid-code regression there?
--
reichelt at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |sje at cup dot hp dot com
Summary|[4.2/4.3/4.4 Regression] |[4.2/4.3 Regression] ICE:
|ICE: segmentation fault with|segmentation fault with
|template code |template code
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.2/4.3 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (7 preceding siblings ...)
2009-01-16 21:43 ` [Bug c++/31260] [4.2/4.3 " reichelt at gcc dot gnu dot org
@ 2009-01-16 22:35 ` sje at gcc dot gnu dot org
2009-01-18 11:47 ` [Bug c++/31260] [4.2 " reichelt at gcc dot gnu dot org
2009-03-30 21:43 ` jsm28 at gcc dot gnu dot org
10 siblings, 0 replies; 12+ messages in thread
From: sje at gcc dot gnu dot org @ 2009-01-16 22:35 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from sje at gcc dot gnu dot org 2009-01-16 22:35 -------
Subject: Bug 31260
Author: sje
Date: Fri Jan 16 22:35:24 2009
New Revision: 143444
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=143444
Log:
PR c++/31260
PR c++/38357
* pt.c (tsubst): Check for NULL args.
* g++.dg/template/crash87.C: New test.
Added:
branches/gcc-4_3-branch/gcc/testsuite/g++.dg/template/crash87.C
Modified:
branches/gcc-4_3-branch/gcc/cp/ChangeLog
branches/gcc-4_3-branch/gcc/cp/pt.c
branches/gcc-4_3-branch/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.2 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (8 preceding siblings ...)
2009-01-16 22:35 ` sje at gcc dot gnu dot org
@ 2009-01-18 11:47 ` reichelt at gcc dot gnu dot org
2009-03-30 21:43 ` jsm28 at gcc dot gnu dot org
10 siblings, 0 replies; 12+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2009-01-18 11:47 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from reichelt at gcc dot gnu dot org 2009-01-18 11:47 -------
Fixed on the 4.3 branch.
--
reichelt at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to fail|4.0.2 4.0.4 4.1.0 4.1.2 |4.0.2 4.0.4 4.1.0 4.1.2
|4.2.0 4.3.0 |4.2.0 4.3.0 4.3.2
Known to work|3.3.6 3.4.0 3.4.6 4.0.0 |3.3.6 3.4.0 3.4.6 4.0.0
|4.0.1 |4.0.1 4.3.3
Summary|[4.2/4.3 Regression] ICE: |[4.2 Regression] ICE:
|segmentation fault with |segmentation fault with
|template code |template code
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/31260] [4.2 Regression] ICE: segmentation fault with template code
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
` (9 preceding siblings ...)
2009-01-18 11:47 ` [Bug c++/31260] [4.2 " reichelt at gcc dot gnu dot org
@ 2009-03-30 21:43 ` jsm28 at gcc dot gnu dot org
10 siblings, 0 replies; 12+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2009-03-30 21:43 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from jsm28 at gcc dot gnu dot org 2009-03-30 21:43 -------
Closing 4.2 branch, fixed in 4.3.3 and 4.4.0.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Known to fail|4.0.2 4.0.4 4.1.0 4.1.2 |4.0.2 4.0.4 4.1.0 4.1.2
|4.2.0 4.3.0 4.3.2 |4.2.0 4.3.0 4.3.2 4.2.5
Known to work|3.3.6 3.4.0 3.4.6 4.0.0 |3.3.6 3.4.0 3.4.6 4.0.0
|4.0.1 4.3.3 |4.0.1 4.3.3 4.4.0
Resolution| |FIXED
Target Milestone|4.2.5 |4.3.3
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31260
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2009-03-30 21:43 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-03-19 9:18 [Bug c++/31260] New: ICE: segmentation fault on invalid code wouter dot vermaelen at pi dot be
2007-03-19 9:27 ` [Bug c++/31260] [4.1/4.2/4.3 Regression] ICE: segmentation fault with template code pinskia at gcc dot gnu dot org
2007-03-22 23:17 ` mmitchel at gcc dot gnu dot org
2007-04-08 22:16 ` reichelt at gcc dot gnu dot org
2007-04-08 23:38 ` reichelt at gcc dot gnu dot org
2007-09-20 10:22 ` pcarlini at suse dot de
2007-12-01 13:54 ` pcarlini at suse dot de
2008-07-04 22:01 ` [Bug c++/31260] [4.2/4.3/4.4 " jsm28 at gcc dot gnu dot org
2009-01-16 21:43 ` [Bug c++/31260] [4.2/4.3 " reichelt at gcc dot gnu dot org
2009-01-16 22:35 ` sje at gcc dot gnu dot org
2009-01-18 11:47 ` [Bug c++/31260] [4.2 " reichelt at gcc dot gnu dot org
2009-03-30 21:43 ` jsm28 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).