Andrew Stubbs ams@codesourcery.com wrote:
Some discussion later, they decided it would be better to implement the optimization using inter-procedural dead store analysis: http://gcc.gnu.org/ml/gcc-patches/2008-07/msg01602.html
I agree that this would be a much nicer way ...
This doesn't seem to have actually been done. Not yet, anyway.
Maybe this is something we should be working on then?
So basically we're left with this patch that does something we want, but not in a way that can go upstream. :(
The question is, should I merge this to Linaro, or not? Loic and I agreed to hold off until I'd done a bit more research and/or tried to upstream it again, but now I think we need to think again.
The one concern I have is that the patch introduces a user-visible construct: the -fremove-local-statics command line option. If we add this now, and users add the flag to their Makefiles, and then it goes away later on, users' builds could break.
On the other hand, we already have the flag in 4.4 anyway, so that risk is there in either case ...
Mit freundlichen Gruessen / Best Regards
Ulrich Weigand
-- Dr. Ulrich Weigand | Phone: +49-7031/16-3727 STSM, GNU compiler and toolchain for Linux on System z and Cell/B.E. IBM Deutschland Research & Development GmbH Vorsitzender des Aufsichtsrats: Martin Jetter | Geschäftsführung: Dirk Wittkopp Sitz der Gesellschaft: Böblingen | Registergericht: Amtsgericht Stuttgart, HRB 243294