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]

Re: Bug in loop opt



  In message <vyzn1ygpffm.fsf@issan.cs.uni-dortmund.de>you write:
  > This triggers a bug in the loop optimizer:
  > 
  > int b;
  > void f ()
  > {
  >   int i = 0;
  >   if (b == 0)
  >     do {
  >       b = i;
  >       i++;
  >     } while (i < 10);
  > }
  > 
  > int main ()
  > {
  >   f ();
  >   if (b != 9)
  >     abort ();
  >   return 0;
  > }
  > 
  > If you look at the changes that were made on Jan 19 then this patch will
  > become obvious.
  > 
  > 
  > 1999-05-13  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
  > 
  > 	* loop.c (check_dbra_loop): Fix change of Jan 19.
Thanks.  Patch was installed into the mainline sources and the branch.  Test
was added to the mainline sources.

jeff


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