This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Loop unrolling
- To: Joern Rennecke <amylaar at cygnus dot co dot uk>
- Subject: Re: Loop unrolling
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Fri, 12 Jun 1998 16:09:22 -0600
- cc: branko dot cibej at hermes dot si (Branko Cibej), mrs at wrs dot com, egcs at cygnus dot com, pfeifer at dbai dot tuwien dot ac dot at
- Reply-To: law at cygnus dot com
In message <199806121642.RAA00482@phal.cygnus.co.uk>you write:
> Apropos... is the following an empty loop?
>
> for (i = 0; i <= 9; i = foo (i));
Not if foo is a function call. Similarly for your other
examples.
An empty loop would be a loop with a body that consists of a
counter increment and branch to the top of the loop (at the
RTL level). Nothing more, nothing less.
I don't think trying to describe what an empty loop is with C
source is all that interesting since in the end it's going to be
detected by the loop optimizer.
jeff