* [Bug middle-end/39999] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
@ 2009-05-01 22:49 ` pinskia at gcc dot gnu dot org
2009-05-01 23:00 ` howarth at nitro dot med dot uc dot edu
` (10 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2009-05-01 22:49 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from pinskia at gcc dot gnu dot org 2009-05-01 22:49 -------
So GCC hangs and not the compiled code?
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|c |middle-end
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug middle-end/39999] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
2009-05-01 22:49 ` [Bug middle-end/39999] " pinskia at gcc dot gnu dot org
@ 2009-05-01 23:00 ` howarth at nitro dot med dot uc dot edu
2009-05-02 10:20 ` [Bug tree-optimization/39999] " rguenth at gcc dot gnu dot org
` (9 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: howarth at nitro dot med dot uc dot edu @ 2009-05-01 23:00 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from howarth at nitro dot med dot uc dot edu 2009-05-01 23:00 -------
On Linux and Darwin, it seems to be constantly allocating memory and never
finishes the compilation (at least over 10+ minutes). The example code compiles
instantly at -O1. I've not discovered any -O2 switches that can be disabled
which would eliminate the problem.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
2009-05-01 22:49 ` [Bug middle-end/39999] " pinskia at gcc dot gnu dot org
2009-05-01 23:00 ` howarth at nitro dot med dot uc dot edu
@ 2009-05-02 10:20 ` rguenth at gcc dot gnu dot org
2009-05-06 13:25 ` [Bug tree-optimization/39999] [4.4/4.5 Regression] " rguenth at gcc dot gnu dot org
` (8 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-02 10:20 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from rguenth at gcc dot gnu dot org 2009-05-02 10:19 -------
Confirmed. I hit
#ifdef ENABLE_CHECKING
/* Theoretically possible, but *highly* unlikely. */
gcc_assert (num_iterations < 500);
#endif
on trunk.
We seem to oscillate
....
ANTIC_IN[12] := { A1_1 (0001), A2_2 (0002), {pointer_plus_expr,A1_1,-4} (0026),
{pointer_plus_expr,A2_2,-4} (0046) }
ANTIC_IN[12] := { A1_1 (0001), A2_2 (0002), {pointer_plus_expr,A2_2,-4} (0025),
{pointer_plus_expr,A2_2,-4} (0046) }
ANTIC_IN[12] := { A1_1 (0001), A2_2 (0002), {pointer_plus_expr,A1_1,-4} (0026),
{pointer_plus_expr,A2_2,-4} (0046) }
ANTIC_IN[12] := { A1_1 (0001), A2_2 (0002), {pointer_plus_expr,A2_2,-4} (0025),
{pointer_plus_expr,A2_2,-4} (0046) }
ANTIC_IN[12] := { A1_1 (0001), A2_2 (0002), {pointer_plus_expr,A1_1,-4} (0026),
{pointer_plus_expr,A2_2,-4} (0046) }
ANTIC_IN[12] := { A1_1 (0001), A2_2 (0002), {pointer_plus_expr,A2_2,-4} (0025),
{pointer_plus_expr,A2_2,-4} (0046) }
Maybe we get confused by the degenerate PHIs
<bb 22>:
<bb 14>:
# A1_17 = PHI <A1_1(22)>
# A2_18 = PHI <A2_2(22)>
C_29 = MMAPMON (p_8(D), A2_18);
D.1783_30 = A2_18 + -4;
free (D.1783_30);
D.1784_31 = A1_17 + -4;
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dberlin at gcc dot gnu dot
| |org, rguenth at gcc dot gnu
| |dot org
Status|UNCONFIRMED |NEW
Component|middle-end |tree-optimization
Ever Confirmed|0 |1
Keywords| |ice-on-valid-code
Last reconfirmed|0000-00-00 00:00:00 |2009-05-02 10:19:57
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4/4.5 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (2 preceding siblings ...)
2009-05-02 10:20 ` [Bug tree-optimization/39999] " rguenth at gcc dot gnu dot org
@ 2009-05-06 13:25 ` rguenth at gcc dot gnu dot org
2009-05-06 13:53 ` rguenth at gcc dot gnu dot org
` (7 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-06 13:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from rguenth at gcc dot gnu dot org 2009-05-06 13:24 -------
Reduced testcase:
void foo(void *);
void
MMAPGCD (int *A1, int *A2)
{
int *t;
do
{
t = A1;
A1 = A2;
A2 = t;
}
while (A2[-1]);
foo (A1-1);
foo (A2-1);
}
if you make foo take int * the issue goes away.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to fail| |4.4.0
Known to work| |4.3.3
Summary|gcc 4.4.0 compiles in |[4.4/4.5 Regression] gcc
|infinite loop |4.4.0 compiles in infinite
| |loop
Target Milestone|--- |4.4.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4/4.5 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (3 preceding siblings ...)
2009-05-06 13:25 ` [Bug tree-optimization/39999] [4.4/4.5 Regression] " rguenth at gcc dot gnu dot org
@ 2009-05-06 13:53 ` rguenth at gcc dot gnu dot org
2009-05-06 15:30 ` mmitchel at gcc dot gnu dot org
` (6 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-06 13:53 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from rguenth at gcc dot gnu dot org 2009-05-06 13:52 -------
Ok, I know what happens.
--
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-05-02 10:19:57 |2009-05-06 13:52:20
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4/4.5 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (4 preceding siblings ...)
2009-05-06 13:53 ` rguenth at gcc dot gnu dot org
@ 2009-05-06 15:30 ` mmitchel at gcc dot gnu dot org
2009-05-15 13:10 ` rguenth at gcc dot gnu dot org
` (5 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2009-05-06 15:30 UTC (permalink / raw)
To: gcc-bugs
--
mmitchel at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4/4.5 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (5 preceding siblings ...)
2009-05-06 15:30 ` mmitchel at gcc dot gnu dot org
@ 2009-05-15 13:10 ` rguenth at gcc dot gnu dot org
2009-05-15 13:10 ` [Bug tree-optimization/39999] [4.4 " rguenth at gcc dot gnu dot org
` (4 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-15 13:10 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from rguenth at gcc dot gnu dot org 2009-05-15 13:10 -------
Subject: Bug 39999
Author: rguenth
Date: Fri May 15 13:09:53 2009
New Revision: 147573
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=147573
Log:
2009-05-15 Richard Guenther <rguenther@suse.de>
PR tree-optimization/39999
* gimple.h (gimple_expr_type): Use the expression type looking
through useless conversions.
* tree-ssa-sccvn.c (vn_nary_op_lookup_stmt): Use gimple_expr_type.
(vn_nary_op_insert_stmt): Likewise.
(simplify_binary_expression): Likewise.
* gcc.c-torture/compile/pr39999.c: New testcase.
Added:
trunk/gcc/testsuite/gcc.c-torture/compile/pr39999.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/gimple.h
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree-ssa-sccvn.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (6 preceding siblings ...)
2009-05-15 13:10 ` rguenth at gcc dot gnu dot org
@ 2009-05-15 13:10 ` rguenth at gcc dot gnu dot org
2009-05-15 13:38 ` howarth at nitro dot med dot uc dot edu
` (3 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-15 13:10 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from rguenth at gcc dot gnu dot org 2009-05-15 13:10 -------
Fixed on the trunk.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to work|4.3.3 |4.3.3 4.5.0
Summary|[4.4/4.5 Regression] gcc |[4.4 Regression] gcc 4.4.0
|4.4.0 compiles in infinite |compiles in infinite loop
|loop |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (7 preceding siblings ...)
2009-05-15 13:10 ` [Bug tree-optimization/39999] [4.4 " rguenth at gcc dot gnu dot org
@ 2009-05-15 13:38 ` howarth at nitro dot med dot uc dot edu
2009-05-15 13:47 ` rguenther at suse dot de
` (2 subsequent siblings)
11 siblings, 0 replies; 13+ messages in thread
From: howarth at nitro dot med dot uc dot edu @ 2009-05-15 13:38 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from howarth at nitro dot med dot uc dot edu 2009-05-15 13:37 -------
Will this fix be backported for gcc 4.4.1?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (8 preceding siblings ...)
2009-05-15 13:38 ` howarth at nitro dot med dot uc dot edu
@ 2009-05-15 13:47 ` rguenther at suse dot de
2009-05-18 10:14 ` rguenth at gcc dot gnu dot org
2009-05-18 10:14 ` rguenth at gcc dot gnu dot org
11 siblings, 0 replies; 13+ messages in thread
From: rguenther at suse dot de @ 2009-05-15 13:47 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from rguenther at suse dot de 2009-05-15 13:47 -------
Subject: Re: [4.4 Regression] gcc 4.4.0 compiles
in infinite loop
On Fri, 15 May 2009, howarth at nitro dot med dot uc dot edu wrote:
> ------- Comment #8 from howarth at nitro dot med dot uc dot edu 2009-05-15 13:37 -------
> Will this fix be backported for gcc 4.4.1?
Yes, I will wait a few days to spot problems though.
Richard.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (9 preceding siblings ...)
2009-05-15 13:47 ` rguenther at suse dot de
@ 2009-05-18 10:14 ` rguenth at gcc dot gnu dot org
2009-05-18 10:14 ` rguenth at gcc dot gnu dot org
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-18 10:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from rguenth at gcc dot gnu dot org 2009-05-18 10:14 -------
Fixed.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread
* [Bug tree-optimization/39999] [4.4 Regression] gcc 4.4.0 compiles in infinite loop
2009-05-01 22:43 [Bug c/39999] New: gcc 4.4.0 compiles in infinite loop howarth at nitro dot med dot uc dot edu
` (10 preceding siblings ...)
2009-05-18 10:14 ` rguenth at gcc dot gnu dot org
@ 2009-05-18 10:14 ` rguenth at gcc dot gnu dot org
11 siblings, 0 replies; 13+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-18 10:14 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from rguenth at gcc dot gnu dot org 2009-05-18 10:13 -------
Subject: Bug 39999
Author: rguenth
Date: Mon May 18 10:13:43 2009
New Revision: 147657
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=147657
Log:
2009-05-18 Richard Guenther <rguenther@suse.de>
PR tree-optimization/39999
* gimple.h (gimple_expr_type): Use the expression type looking
through useless conversions.
* tree-ssa-sccvn.c (vn_nary_op_lookup_stmt): Use gimple_expr_type.
(vn_nary_op_insert_stmt): Likewise.
(simplify_binary_expression): Likewise.
* gcc.c-torture/compile/pr39999.c: New testcase.
Added:
branches/gcc-4_4-branch/gcc/testsuite/gcc.c-torture/compile/pr39999.c
Modified:
branches/gcc-4_4-branch/gcc/ChangeLog
branches/gcc-4_4-branch/gcc/gimple.h
branches/gcc-4_4-branch/gcc/testsuite/ChangeLog
branches/gcc-4_4-branch/gcc/tree-ssa-sccvn.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39999
^ permalink raw reply [flat|nested] 13+ messages in thread