* [Bug c++/26140] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
@ 2006-02-06 23:02 ` dcb314 at hotmail dot com
2006-02-06 23:31 ` pinskia at gcc dot gnu dot org
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: dcb314 at hotmail dot com @ 2006-02-06 23:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from dcb314 at hotmail dot com 2006-02-06 23:02 -------
Created an attachment (id=10793)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=10793&action=view)
C++ source code
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
2006-02-06 23:02 ` [Bug c++/26140] " dcb314 at hotmail dot com
@ 2006-02-06 23:31 ` pinskia at gcc dot gnu dot org
2006-02-06 23:39 ` [Bug c++/26140] [4.2 Regression] " pinskia at gcc dot gnu dot org
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-02-06 23:31 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from pinskia at gcc dot gnu dot org 2006-02-06 23:30 -------
Reducing.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] [4.2 Regression] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
2006-02-06 23:02 ` [Bug c++/26140] " dcb314 at hotmail dot com
2006-02-06 23:31 ` pinskia at gcc dot gnu dot org
@ 2006-02-06 23:39 ` pinskia at gcc dot gnu dot org
2006-02-07 0:35 ` pinskia at gcc dot gnu dot org
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-02-06 23:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from pinskia at gcc dot gnu dot org 2006-02-06 23:39 -------
It worked with "4.2.0 20051217".
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
GCC host triplet|x86_64-suse-gnu |
GCC target triplet| |x86_64-suse-gnu
Keywords| |ice-on-valid-code
Summary|ice on valid C++ code |[4.2 Regression] ice on
| |valid C++ code
Target Milestone|--- |4.2.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] [4.2 Regression] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
` (2 preceding siblings ...)
2006-02-06 23:39 ` [Bug c++/26140] [4.2 Regression] " pinskia at gcc dot gnu dot org
@ 2006-02-07 0:35 ` pinskia at gcc dot gnu dot org
2006-02-07 10:07 ` rguenth at gcc dot gnu dot org
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-02-07 0:35 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pinskia at gcc dot gnu dot org 2006-02-07 00:35 -------
Reduced testcase:
struct Pitch
{
int notename_;
};
struct Audio_note
{
Audio_note (Pitch p);
};
void create_audio_elements ()
{
Pitch *pit;
new Audio_note (*pit);
}
--------
Looks like this is caused by:
2006-01-30 Richard Guenther <rguenther@suse.de>
PR c++/23372
* gimplify.c (gimplify_target_expr): Handle easy cases
without creating a temporary.
------
The reason I said this patch is because the IR looks like:
(void) (TARGET_EXPR <D.2018, *(struct Pitch &) (struct Pitch *)
NON_LVALUE_EXPR <pit>>;, TARGET_EXPR <D.1993, (struct Audio_note *) operator
new (1)>;, try
{
__comp_ctor (NON_LVALUE_EXPR <D.1993>, D.2018);
}
catch
{
operator delete ((void *) D.1993);
}, D.1993) >>>
>>;
So we reduce the TARGET_EXPR to *pit but we reference D.2018 in the other
expression.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |rguenth at gcc dot gnu dot
| |org
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2006-02-07 00:35:43
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] [4.2 Regression] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
` (3 preceding siblings ...)
2006-02-07 0:35 ` pinskia at gcc dot gnu dot org
@ 2006-02-07 10:07 ` rguenth at gcc dot gnu dot org
2006-02-07 14:46 ` pinskia at gcc dot gnu dot org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-02-07 10:07 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from rguenth at gcc dot gnu dot org 2006-02-07 10:07 -------
Ho humm, so I propose to revert the patch (that I didn't like very much
anyway). Can I do so without approval?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] [4.2 Regression] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
` (4 preceding siblings ...)
2006-02-07 10:07 ` rguenth at gcc dot gnu dot org
@ 2006-02-07 14:46 ` pinskia at gcc dot gnu dot org
2006-02-07 15:36 ` rguenth at gcc dot gnu dot org
2006-02-07 15:39 ` rguenth at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-02-07 14:46 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from pinskia at gcc dot gnu dot org 2006-02-07 14:46 -------
(In reply to comment #5)
> Ho humm, so I propose to revert the patch (that I didn't like very much
> anyway). Can I do so without approval?
Yes but what about fixing the C++ front-end so that it does not place the
TARGET_EXPR in the wrong spot?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] [4.2 Regression] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
` (5 preceding siblings ...)
2006-02-07 14:46 ` pinskia at gcc dot gnu dot org
@ 2006-02-07 15:36 ` rguenth at gcc dot gnu dot org
2006-02-07 15:39 ` rguenth at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-02-07 15:36 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from rguenth at gcc dot gnu dot org 2006-02-07 15:36 -------
Subject: Bug 26140
Author: rguenth
Date: Tue Feb 7 15:36:44 2006
New Revision: 110699
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=110699
Log:
2006-02-07 Richard Guenther <rguenther@suse.de>
PR c++/26140
Revert
2006-01-30 Richard Guenther <rguenther@suse.de>
PR c++/23372
* gimplify.c (gimplify_target_expr): Handle easy cases
without creating a temporary.
Revert
2006-01-30 Richard Guenther <rguenther@suse.de>
PR c++/23372
* gcc.dg/pr23372-1.C: New testcase.
* g++.dg/tree-ssa/pr26140.C: New testcase.
Added:
trunk/gcc/testsuite/g++.dg/tree-ssa/pr26140.C
Modified:
trunk/gcc/ChangeLog
trunk/gcc/gimplify.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gcc.dg/pr23372-1.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug c++/26140] [4.2 Regression] ice on valid C++ code
2006-02-06 23:00 [Bug c++/26140] New: ice on valid C++ code dcb314 at hotmail dot com
` (6 preceding siblings ...)
2006-02-07 15:36 ` rguenth at gcc dot gnu dot org
@ 2006-02-07 15:39 ` rguenth at gcc dot gnu dot org
7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-02-07 15:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from rguenth at gcc dot gnu dot org 2006-02-07 15:39 -------
Fixed.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26140
^ permalink raw reply [flat|nested] 9+ messages in thread