* [Bug c++/55419] [4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
@ 2012-11-21 1:07 ` paolo.carlini at oracle dot com
2012-11-21 11:09 ` [Bug c++/55419] [4.7/4.8 " jakub at gcc dot gnu.org
` (8 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-11-21 1:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-11-21
Summary|internal compiler error: in |[4.8 Regression] ICE in
|gimplify_init_ctor_preeval, |gimplify_init_ctor_preeval,
|at gimplify.c:3587 |at gimplify.c:3587
Ever Confirmed|0 |1
--- Comment #1 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-11-21 01:06:40 UTC ---
It's a regression.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
2012-11-21 1:07 ` [Bug c++/55419] [4.8 Regression] ICE " paolo.carlini at oracle dot com
@ 2012-11-21 11:09 ` jakub at gcc dot gnu.org
2012-11-21 11:18 ` jakub at gcc dot gnu.org
` (7 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-11-21 11:09 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org,
| |jason at gcc dot gnu.org
Target Milestone|--- |4.8.0
Summary|[4.8 Regression] ICE in |[4.7/4.8 Regression] ICE in
|gimplify_init_ctor_preeval, |gimplify_init_ctor_preeval,
|at gimplify.c:3587 |at gimplify.c:3587
--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-11-21 11:08:46 UTC ---
Reduced testcase:
struct P
{
P () = default;
explicit constexpr P (int x) : p (x) {}
int p;
};
struct Q
{
constexpr Q () : q (0x7f) {}
int q;
};
struct R
{
Q q;
P p;
};
void
foo (R *x)
{
*x = {};
}
Started ICEing with http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=177997
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
2012-11-21 1:07 ` [Bug c++/55419] [4.8 Regression] ICE " paolo.carlini at oracle dot com
2012-11-21 11:09 ` [Bug c++/55419] [4.7/4.8 " jakub at gcc dot gnu.org
@ 2012-11-21 11:18 ` jakub at gcc dot gnu.org
2012-12-07 10:16 ` rguenth at gcc dot gnu.org
` (6 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-11-21 11:18 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-11-21 11:18:22 UTC ---
/* We always set TREE_SIDE_EFFECTS so that expand_expr does not
ignore the TARGET_EXPR. If there really turn out to be no
side-effects, then the optimizer should be able to get rid of
whatever code is generated anyhow. */
TREE_SIDE_EFFECTS (t) = 1;
+ if (literal_type_p (type))
+ TREE_CONSTANT (t) = TREE_CONSTANT (value);
So we end up with TARGET_EXPR with TREE_SIDE_EFFECTS, but TREE_CONSTANT set
too, which is what the gimplifier is complaining about. constants shouldn't
have side-effects. If this is some trick internal to the C++ FE, then at least
the genericizer should drop TREE_CONSTANT from TARGET_EXPRs with
TREE_SIDE_EFFECTS set that are passed down to the middle-end.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (2 preceding siblings ...)
2012-11-21 11:18 ` jakub at gcc dot gnu.org
@ 2012-12-07 10:16 ` rguenth at gcc dot gnu.org
2012-12-07 15:43 ` jason at gcc dot gnu.org
` (5 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-12-07 10:16 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (3 preceding siblings ...)
2012-12-07 10:16 ` rguenth at gcc dot gnu.org
@ 2012-12-07 15:43 ` jason at gcc dot gnu.org
2012-12-08 3:31 ` jason at gcc dot gnu.org
` (4 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2012-12-07 15:43 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
AssignedTo|unassigned at gcc dot |jason at gcc dot gnu.org
|gnu.org |
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (4 preceding siblings ...)
2012-12-07 15:43 ` jason at gcc dot gnu.org
@ 2012-12-08 3:31 ` jason at gcc dot gnu.org
2012-12-08 3:32 ` jason at gcc dot gnu.org
` (3 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2012-12-08 3:31 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
--- Comment #4 from Jason Merrill <jason at gcc dot gnu.org> 2012-12-08 03:31:33 UTC ---
Author: jason
Date: Sat Dec 8 03:31:25 2012
New Revision: 194317
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194317
Log:
PR c++/55419
* tree.c (build_target_expr): Don't set TREE_CONSTANT.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/constexpr-initlist6.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/tree.c
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (5 preceding siblings ...)
2012-12-08 3:31 ` jason at gcc dot gnu.org
@ 2012-12-08 3:32 ` jason at gcc dot gnu.org
2012-12-08 3:33 ` jason at gcc dot gnu.org
` (2 subsequent siblings)
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2012-12-08 3:32 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
--- Comment #5 from Jason Merrill <jason at gcc dot gnu.org> 2012-12-08 03:32:06 UTC ---
Author: jason
Date: Sat Dec 8 03:31:56 2012
New Revision: 194319
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194319
Log:
PR c++/55419
* tree.c (build_target_expr): Don't set TREE_CONSTANT.
Added:
branches/gcc-4_7-branch/gcc/testsuite/g++.dg/cpp0x/constexpr-initlist6.C
Modified:
branches/gcc-4_7-branch/gcc/cp/ChangeLog
branches/gcc-4_7-branch/gcc/cp/tree.c
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (6 preceding siblings ...)
2012-12-08 3:32 ` jason at gcc dot gnu.org
@ 2012-12-08 3:33 ` jason at gcc dot gnu.org
2013-01-03 20:38 ` jason at gcc dot gnu.org
2013-01-03 20:38 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2012-12-08 3:33 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
Target Milestone|4.8.0 |4.7.3
--- Comment #6 from Jason Merrill <jason at gcc dot gnu.org> 2012-12-08 03:33:06 UTC ---
Fixed for 4.7.3.
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (7 preceding siblings ...)
2012-12-08 3:33 ` jason at gcc dot gnu.org
@ 2013-01-03 20:38 ` jason at gcc dot gnu.org
2013-01-03 20:38 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2013-01-03 20:38 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
--- Comment #7 from Jason Merrill <jason at gcc dot gnu.org> 2013-01-03 20:37:04 UTC ---
Author: jason
Date: Thu Jan 3 20:36:49 2013
New Revision: 194870
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194870
Log:
PR c++/55419
PR c++/55753
* pt.c (tsubst_copy_and_build) [TARGET_EXPR]: Don't touch
TREE_CONSTANT.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/constexpr-ctor12.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/pt.c
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Bug c++/55419] [4.7/4.8 Regression] ICE in gimplify_init_ctor_preeval, at gimplify.c:3587
2012-11-20 22:24 [Bug c++/55419] New: internal compiler error: in gimplify_init_ctor_preeval, at gimplify.c:3587 jasongross9+bugzilla at gmail dot com
` (8 preceding siblings ...)
2013-01-03 20:38 ` jason at gcc dot gnu.org
@ 2013-01-03 20:38 ` jason at gcc dot gnu.org
9 siblings, 0 replies; 11+ messages in thread
From: jason at gcc dot gnu.org @ 2013-01-03 20:38 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55419
--- Comment #8 from Jason Merrill <jason at gcc dot gnu.org> 2013-01-03 20:37:50 UTC ---
Author: jason
Date: Thu Jan 3 20:37:28 2013
New Revision: 194872
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194872
Log:
PR c++/55419
PR c++/55753
* pt.c (tsubst_copy_and_build) [TARGET_EXPR]: Don't touch
TREE_CONSTANT.
Added:
branches/gcc-4_7-branch/gcc/testsuite/g++.dg/cpp0x/constexpr-ctor12.C
Modified:
branches/gcc-4_7-branch/gcc/cp/ChangeLog
branches/gcc-4_7-branch/gcc/cp/pt.c
^ permalink raw reply [flat|nested] 11+ messages in thread