On Sat, Nov 14, 2009 at 8:51 PM, Richard Guenther <richard.guent...@gmail.com> wrote: > Note that some optimizers (for example value-numbering) contain cut-offs > so that they are turned off for large functions as otherwise compile-time > issues appear as algorithms are non-linear in the size of the function. > > So it might even be not profitable in the end for size and speed reasons.
...where one should keep in mind, that this is one of those areas where GCC is still at least a decade behind the best compilers in the industry. Those optimizations, that cut themselves off, would work just fine on regions instead of whole functions. Another thing that might be helpful, is partial inlining (e.g. http://www.csc.villanova.edu/~tway/publications/wayPDPTA02.pdf although I suspect that for the code from Toon only whole-function inlining is useful...?). Zadeck had code for structural analysis a couple of years ago. I don't think anyone has seriously worked with that to experiment with region based compilation. But I guess it will be the Next Big Challange for GCC, after LTO. Ciao! Steven