http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59660
--- Comment #5 from rguenther at suse dot de <rguenther at suse dot de> --- On Tue, 7 Jan 2014, hubicka at ucw dot cz wrote: > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59660 > > --- Comment #4 from Jan Hubicka <hubicka at ucw dot cz> --- > > Not all testcases can be handled at gimplification time IIRC. Which > > means "testcases welcome" first, so we can look at them individually. > > The GCC one I saw was equivalent of: > #include <stdbool.h> > bool > m_is_less_than_n (int n, int m) > { > return (n==m || m_is_less_than_n (n-1,m)); > } That's only optimizable after the 'mergephi' pass. Before the temporary setting is shared by the n==m code. Thus maybe 'mergephi' itself can handle this ...