This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Loop optimizer misses simple optimisation?
- To: Jim Wilson <wilson at cygnus dot com>
- Subject: Re: Loop optimizer misses simple optimisation?
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Sun, 03 May 1998 21:10:23 -0600
- cc: Kamil Iskra <kamil at dwd dot interkom dot pl>, egcs at cygnus dot com
- Reply-To: law at cygnus dot com
In message <199805032232.PAA08246@rtl.cygnus.com>you write:
> However, a div or mod operation can not generally be moved out of
> a loop unless you know it won't trap (divide by zero).
>
> If an instruction might trap, then it will be moved out of a loop if we
> can prove that it will be executed at least once.
Ah, yes, you're right. I forgot about that tidbit.
jeff