http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35561
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org --- Comment #9 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-06-23 13:31:01 UTC --- Well, we could still optimize it e.g. in leaf functions or in functions that only call leaf functions (__attribute__((leaf))). But we do this transformation during gimplification, so either we'd need to add an optimization that would turn an automatic aggregate into static aggregate if possible and useful later on (in particular, if it is determined to be never written into and its value doesn't escape current function or current function is leaf or only calls leaf functions and doesn't tail recurse), or we'd need to do some analysis right before gimplification starts to find out if a function must be leaf or only call leaf functions.