[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-02-21 Thread jamborm at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

--- Comment #18 from Martin Jambor jamborm at gcc dot gnu.org ---
Author: jamborm
Date: Fri Feb 21 13:05:40 2014
New Revision: 207990

URL: http://gcc.gnu.org/viewcvs?rev=207990root=gccview=rev
Log:
2014-02-21  Martin Jambor  mjam...@suse.cz

PR ipa/55260
* ipa-cp.c (cgraph_edge_brings_all_agg_vals_for_node): Uce correct
info when checking whether lattices are bottom.

testsuite/
* gcc.dg/ipa/pr55260.c: New test.


Added:
branches/gcc-4_8-branch/gcc/testsuite/gcc.dg/ipa/pr55260.c
Modified:
branches/gcc-4_8-branch/gcc/ChangeLog
branches/gcc-4_8-branch/gcc/ipa-cp.c
branches/gcc-4_8-branch/gcc/testsuite/ChangeLog


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-02-20 Thread jamborm at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

--- Comment #14 from Martin Jambor jamborm at gcc dot gnu.org ---
Author: jamborm
Date: Thu Feb 20 13:28:34 2014
New Revision: 207941

URL: http://gcc.gnu.org/viewcvs?rev=207941root=gccview=rev
Log:
2014-02-20  Martin Jambor  mjam...@suse.cz

PR ipa/55260
* ipa-cp.c (cgraph_edge_brings_all_agg_vals_for_node): Uce correct
info when checking whether lattices are bottom.

testsuite/
* gcc.dg/ipa/pr55260.c: New test.


Added:
trunk/gcc/testsuite/gcc.dg/ipa/pr55260.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/ipa-cp.c
trunk/gcc/testsuite/ChangeLog


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-02-20 Thread trippels at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

Markus Trippelsdorf trippels at gcc dot gnu.org changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #15 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
Fixed again. Thanks.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-02-20 Thread jamborm at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

--- Comment #16 from Martin Jambor jamborm at gcc dot gnu.org ---
Not yet on the 4.8 branch, but I'm re-running the tests there now and hopefully
will commit it also there today or tomorrow.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-02-20 Thread trippels at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

--- Comment #17 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
(In reply to Martin Jambor from comment #16)
 Not yet on the 4.8 branch, but I'm re-running the tests there now and
 hopefully will commit it also there today or tomorrow.

Ah, sorry.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-02-04 Thread jamborm at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

--- Comment #13 from Martin Jambor jamborm at gcc dot gnu.org ---
Fix to this second issue (which is indeed very similar to the initial
one) has been sent to the mailing list:

http://gcc.gnu.org/ml/gcc-patches/2014-02/msg00201.html


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-01-31 Thread trippels at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

--- Comment #11 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
Martin, can you take a look?


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-01-31 Thread jamborm at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

Martin Jambor jamborm at gcc dot gnu.org changed:

   What|Removed |Added

 Status|REOPENED|ASSIGNED

--- Comment #12 from Martin Jambor jamborm at gcc dot gnu.org ---
(In reply to Markus Trippelsdorf from comment #11)
 Martin, can you take a look?

Sure.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-01-10 Thread shenhanc at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

Han Shen shenhanc at gmail dot com changed:

   What|Removed |Added

 CC||shenhanc at gmail dot com

--- Comment #9 from Han Shen shenhanc at gmail dot com ---
Created attachment 31806
  -- http://gcc.gnu.org/bugzilla/attachment.cgi?id=31806action=edit
Test case for gcc 4.8 and trunk

Hi I found this same error in gcc 4_8 and trunk, to reproduce - 
gcc -c -std=c89 -m64 -O3 ~/preprocessor.pp.c 

preprocessor.pp.c: At top level:
preprocessor.pp.c:108:1: internal compiler error: in ipa_get_parm_lattices, at
ipa-cp.c:261
 }
 ^
0xedeba7 ipa_get_parm_lattices
../../trunk/gcc/ipa-cp.c:261
0xedeba7 find_aggregate_values_for_callers_subset
../../trunk/gcc/ipa-cp.c:3051
0xedeba7 decide_about_value
../../trunk/gcc/ipa-cp.c:3365
0xee0a6c decide_whether_version_node
../../trunk/gcc/ipa-cp.c:3411
0xee0a6c ipcp_decision_stage
../../trunk/gcc/ipa-cp.c:3556
0xee0a6c ipcp_driver
../../trunk/gcc/ipa-cp.c:3598
0xee0a6c execute
../../trunk/gcc/ipa-cp.c:3694
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See http://gcc.gnu.org/bugs.html for instructions.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2014-01-10 Thread trippels at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55260

Markus Trippelsdorf trippels at gcc dot gnu.org changed:

   What|Removed |Added

 Status|RESOLVED|REOPENED
 CC||trippels at gcc dot gnu.org
 Resolution|FIXED   |---
  Known to fail||4.9.0

--- Comment #10 from Markus Trippelsdorf trippels at gcc dot gnu.org ---
Confirmed.

A bit further reduced:

markus@x4 tmp % cat test.i
typedef struct {
  int *ptr;
  int len;
} string;
typedef struct {
  string nantstr;
  int *nant;
} malv;
typedef struct {
  int *nor;
} list_heads;
int b;
list_heads *fn1(string, int *, unsigned);
void fn2(malv *p1, list_heads *p2, unsigned p3) {
  string a = p1-nantstr;
  fn1(a, p1-nant, p3);
}

void fn3(unsigned p1) { fn2(0, 0, p1); }

list_heads *fn1(string p1, int *p2, unsigned p3) {
  while (1) {
if (p3)
  fn3(1);
if (b)
  return 0;
fn3(1);
  }
}

void fn5() {
  list_heads c;
  c.nor = 0;
  fn2(0, c, 1);
}

markus@x4 tmp % /var/tmp/gcc_test/usr/local/bin/gcc -c -O2 -fno-inline
-fipa-cp-clone test.i
test.i:35:1: internal compiler error: in ipa_get_parm_lattices, at ipa-cp.c:261
 }
 ^
0xe99411 ipa_get_parm_lattices
../../gcc/gcc/ipa-cp.c:261
0xe99411 cgraph_edge_brings_all_agg_vals_for_node
../../gcc/gcc/ipa-cp.c:3187
0xe99411 perhaps_add_new_callers
../../gcc/gcc/ipa-cp.c:3245
0xe99411 decide_about_value
../../gcc/gcc/ipa-cp.c:3318
0xe9c2c3 decide_whether_version_node
../../gcc/gcc/ipa-cp.c:3411
0xe9c2c3 ipcp_decision_stage
../../gcc/gcc/ipa-cp.c:3556
0xe9c2c3 ipcp_driver
../../gcc/gcc/ipa-cp.c:3598
0xe9c2c3 execute
../../gcc/gcc/ipa-cp.c:3694
Please submit a full bug report,


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-21 Thread jamborm at gcc dot gnu.org


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



--- Comment #6 from Martin Jambor jamborm at gcc dot gnu.org 2012-11-21 
17:03:46 UTC ---

This is the second fix, as posted to the mailing list:



http://gcc.gnu.org/ml/gcc-patches/2012-11/msg01724.html



also slightly related is:



http://gcc.gnu.org/ml/gcc-patches/2012-11/msg01758.html


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-21 Thread jamborm at gcc dot gnu.org


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



--- Comment #7 from Martin Jambor jamborm at gcc dot gnu.org 2012-11-21 
17:04:54 UTC ---

Author: jamborm

Date: Wed Nov 21 17:04:45 2012

New Revision: 193700



URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=193700

Log:

2012-11-21  Martin Jambor  mjam...@suse.cz



PR tree-optimization/55260

* ipa-cp.c (intersect_aggregates_with_edge): New function.

(find_aggregate_values_for_callers_subset): Part moved to the function

above.  Call it.

(cgraph_edge_brings_all_agg_vals_for_node): Reimplemented using

intersect_aggregates_with_edge.



* testsuite/g++.dg/torture/pr55260-2.C: New test.





Added:

trunk/gcc/testsuite/g++.dg/torture/pr55260-2.C

Modified:

trunk/gcc/ChangeLog

trunk/gcc/ipa-cp.c

trunk/gcc/testsuite/ChangeLog


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-21 Thread jamborm at gcc dot gnu.org


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



Martin Jambor jamborm at gcc dot gnu.org changed:



   What|Removed |Added



 Status|ASSIGNED|RESOLVED

 Resolution||FIXED



--- Comment #8 from Martin Jambor jamborm at gcc dot gnu.org 2012-11-21 
17:10:05 UTC ---

Fixed.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-20 Thread jamborm at gcc dot gnu.org


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



--- Comment #5 from Martin Jambor jamborm at gcc dot gnu.org 2012-11-20 
11:20:47 UTC ---

Author: jamborm

Date: Tue Nov 20 11:20:41 2012

New Revision: 193657



URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=193657

Log:

2012-11-20  Martin Jambor  mjam...@suse.cz



PR tree-optimization/55260

* ipa-cp.c (find_aggregate_values_for_callers_subset): Rename info to

dest_info, use caller_info instead of info when determining whether

callee is a clone.



* testsuite/g++.dg/torture/pr55260-1.C: New test.





Added:

trunk/gcc/testsuite/g++.dg/torture/pr55260-1.C

Modified:

trunk/gcc/ChangeLog

trunk/gcc/ipa-cp.c

trunk/gcc/testsuite/ChangeLog


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-17 Thread jamborm at gcc dot gnu.org


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



--- Comment #4 from Martin Jambor jamborm at gcc dot gnu.org 2012-11-17 
12:45:05 UTC ---

Even though they both lead to the same ICE, the testcase in the

summary and the one from comment #2 are actually caused by different

bugs in ipa-cp.c.



I have just submitted the summary testcase fix to the mailing list:

http://gcc.gnu.org/ml/gcc-patches/2012-11/msg01443.html



I'll deal with the other issue next week.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-16 Thread markus at trippelsdorf dot de


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



Markus Trippelsdorf markus at trippelsdorf dot de changed:



   What|Removed |Added



 CC||jamborm at gcc dot gnu.org,

   ||markus at trippelsdorf dot

   ||de



--- Comment #2 from Markus Trippelsdorf markus at trippelsdorf dot de 
2012-11-16 10:04:56 UTC ---

This ICE also hits in the boost testsuite:



markus@x4 more % cat test.ii

struct B

{

virtual void test_suite_finish ();

};

void

fn1 (B  p2)

{

fn1 (p2);

B  a = p2;

a.test_suite_finish ();

B b;

fn1 (b);

}



markus@x4 more % c++ -O3 -c test.ii

test.ii:13:1: internal compiler error: in ipa_get_parm_lattices, at

ipa-cp.c:263

 }

 ^

0xeb2b52 ipa_get_parm_lattices

/home/markus/gcc/gcc/ipa-cp.c:263

0xeb059a ipa_get_parm_lattices

/home/markus/gcc/gcc/ipa-cp.c:2930

0xeb059a cgraph_edge_brings_all_agg_vals_for_node

/home/markus/gcc/gcc/ipa-cp.c:3105

0xeb059a perhaps_add_new_callers

/home/markus/gcc/gcc/ipa-cp.c:3157

0xeb059a decide_about_value

/home/markus/gcc/gcc/ipa-cp.c:3230

0xeb2693 decide_whether_version_node

/home/markus/gcc/gcc/ipa-cp.c:3324

0xeb2693 ipcp_decision_stage

/home/markus/gcc/gcc/ipa-cp.c:3464

0xeb2693 ipcp_driver

/home/markus/gcc/gcc/ipa-cp.c:3506

Please submit a full bug report,

with preprocessed source if appropriate.

Please include the complete backtrace with any bug report.

See http://gcc.gnu.org/bugs.html for instructions.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-16 Thread jamborm at gcc dot gnu.org


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



Martin Jambor jamborm at gcc dot gnu.org changed:



   What|Removed |Added



 Status|UNCONFIRMED |ASSIGNED

   Last reconfirmed||2012-11-16

 AssignedTo|unassigned at gcc dot   |jamborm at gcc dot gnu.org

   |gnu.org |

 Ever Confirmed|0   |1



--- Comment #3 from Martin Jambor jamborm at gcc dot gnu.org 2012-11-16 
16:07:31 UTC ---

Mine.


[Bug tree-optimization/55260] [4.8 Regression] ICE: in ipa_get_parm_lattices, at ipa-cp.c:263 with -O2 -fno-inline -fipa-cp-clone

2012-11-11 Thread dcb314 at hotmail dot com


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



David Binderman dcb314 at hotmail dot com changed:



   What|Removed |Added



 CC||dcb314 at hotmail dot com



--- Comment #1 from David Binderman dcb314 at hotmail dot com 2012-11-11 
10:32:16 UTC ---

This seems to have broken sometime between 7 Nov and 11 Nov.