This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: What loop optimizations could increase the code size significantly?
- From: Gan <george dot gan at gmail dot com>
- To: "Fang, Changpeng" <Changpeng dot Fang at amd dot com>
- Cc: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>, "gcc-help at gcc dot gnu dot org" <gcc-help at gcc dot gnu dot org>
- Date: Fri, 10 Dec 2010 14:28:39 -0600
- Subject: Re: What loop optimizations could increase the code size significantly?
- References: <D4C76825A6780047854A11E93CDE84D004C17683F6@SAUSEXMBP01.amd.com>
- Reply-to: george dot gan at gmail dot com
Software pipeline (a.k.a, sms) generates prologue and epilogue code.
In addition, loop versioning duplicates loop body, which would also
increase code size. But I guess you don't want to turn on SWP, right?
Gan
On Fri, Dec 10, 2010 at 1:40 PM, Fang, Changpeng <Changpeng.Fang@amd.com> wrote:
> Hi,
>
> ?I am kooking ways to reduce the code size. What loop optimizations could increase the code size significantly?
> The optimization I know are: unswitch, vectorization, prefetch and unrolling.
> We should not perform these optimizations if the loop just roll a few iterations.
>
> In addition, what loop optimizations could generate pre- and/or post loops?
> For example, vectorization, unrolling,
>
> Thanks,
>
> Changpeng
>
--
Best Regards
Gan