This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Unrolling loops
- From: Ian Lance Taylor <iant at google dot com>
- To: Joseph Jezak <josejx at gentoo dot org>
- Cc: gcc-help at gcc dot gnu dot org
- Date: 26 Jul 2007 13:07:57 -0700
- Subject: Re: Unrolling loops
- References: <46A7C7C3.3060204@gentoo.org>
Joseph Jezak <josejx@gentoo.org> writes:
> I was looking at the binary output from a simple loop that's been
> compiled with -funroll-all-loops and I noticed that gcc will only
> unroll a loop if the loop repeats less than 16 times. Is there a
> way to turn this off? Is there a reason for it?
I don't think that is always true, though it may well be true for your
test case.
You can control this behaviour in various ways. Look at the
documentation for the --param option, and the parameters like
max-unrolled-insns.
Ian