This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: empty function optimizations
- To: Andreas Schwab <schwab at suse dot de>
- Subject: Re: empty function optimizations
- From: Joern Rennecke <amylaar at cygnus dot co dot uk>
- Date: Wed, 12 Jul 2000 20:11:02 +0100 (BST)
- CC: Ken Clark <ken at gesn dot com>, gcc at gcc dot gnu dot org
> This would break the gurantee of generating identical code with or without
> debugging information. Debugging information should be completely
> removable with a simple run of `strip'.
The rule of thumb is that -O1 should work reasonably well with debugging,
while -O2 may be more aggressive.
SO we could make this optimization default to on for optimize >= 2
(or just make it dependent on -fexpensive-optimization).
Of course, gcc has to tell the linker about the uses of a label are
only jumps for this optimization to ork safely, we can make the creation
of this information dependent on the flag setting.