Hello, This patch is a back-port of one of the scalability improvements I made to perform, well, maybe not well but at least not so poorly on the test case of PR54146, which has an extremely large function.
The problem in ifcvt.c has two parts. The first is that clearing several arrays of size(max_reg_num) for every basic block slowed down things. The second part is that this memory was being allocated with alloca, so that a sufficiently large function could blow out the stack. The latter problem was now also found by a user trying to compile a sensible and well-known piece of software (see http://gcc.gnu.org/ml/gcc/2012-10/msg00202.html). This code compiles with older GCC releases, so this problem is a regression. To fix the problem in GCC 4.7, I'd like to propose this back-port. Bootstrapped&tested with release and default development checking on x86_64-unknown-linux-gnu and on powerpc64-unknown-linux-gnu. The patch has also already spent more than two months on the trunk now without problems. OK for the GCC 4.7 release branch? Maybe also for the GCC 4.6 branch after testing? Ciao! Steven
PR54146_ifcvt_47.diff
Description: Binary data