This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Common Tail Elimination


This is called code sinking and AFAIK this is implemented in the 4.x
series. You can also look at the code factoring branch that was being
merged into 4.2.


> Does gcc/g++ have what I think is called "common tail elimination"?
> If a function does: step a, step b, step c, return val; in more than
> one place, will the common code be pulled out and branched to in
> order to reduce the size of the code?  This may be contrary to most
> optimizations since it introduces a branch which costs time but the
> benefit is smaller code size.
>
> Thanks,
> Perry
>


----
Ramana Radhakrishnan
GNU Tools
Codito Technologies



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]