[Bug tree-optimization/56490] [4.6/4.7/4.8 Regression] -Wall triggering infinite loop

2013-03-08 Thread rguenth at gcc dot gnu.org


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



Richard Biener rguenth at gcc dot gnu.org changed:



   What|Removed |Added



  Known to work|4.8.0   |

Summary|[4.6/4.7 Regression] -Wall  |[4.6/4.7/4.8 Regression]

   |triggering infinite loop|-Wall triggering infinite

   ||loop

  Known to fail||4.8.0



--- Comment #4 from Richard Biener rguenth at gcc dot gnu.org 2013-03-08 
16:03:30 UTC ---

Clearly the limiting is bougs ... the issue is with large fanout BBs

we recurse in compute_control_dep_chain which leads to exponential

complexity.  Limiting that to 8^5 isn't really a fix ... (yes, you

can call that O(1)).



compute_control_dep_chain is called 65 million times(!) for the testcase

after the patch.



There has to be a better algorithmic way of implementing this.



IMHO still not fixed in 4.8.


[Bug tree-optimization/56490] [4.6/4.7/4.8 Regression] -Wall triggering infinite loop

2013-03-08 Thread xinliangli at gmail dot com


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



--- Comment #5 from davidxl xinliangli at gmail dot com 2013-03-08 16:21:13 
UTC ---

(In reply to comment #4)

 Clearly the limiting is bougs ... the issue is with large fanout BBs

 we recurse in compute_control_dep_chain which leads to exponential

 complexity.  Limiting that to 8^5 isn't really a fix ... (yes, you

 can call that O(1)).

 

 compute_control_dep_chain is called 65 million times(!) for the testcase

 after the patch.

 

 There has to be a better algorithmic way of implementing this.

 

 IMHO still not fixed in 4.8.



Right. 



However for on demand computation like this,  limiting is still needed. For

this particular case, limiting the depth to 3 (or may be smaller) won't cause

any regressions.