This is the mail archive of the gcc-patches@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]

Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dotcz>


> Zdenek Dvorak wrote
> 3) Removes simplify_using_outer_evolutions.  This function does
>    basically constant propagation in weird special cases, like
>
>   for (i = 0; i < 50; i++)
>     ...;
>   for (; i < 100; i++)
>     ...;
>
>   to detect that the initial value of i in the second loop is 50.
>   In practice, this just wastes time.

and typically inferior to eliminating the otherwise potentially expensive
arbitrary constant comparison (vs. a typically cheep/free zero comparison)
loop count testing in cases when the iteration count isn't used otherwise:

   for (i = 50; i != 0; i--)
      ...;
   for (i = 50; i != 0; i--)
     ...;



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