------- Comment #7 from rguenther at suse dot de 2009-11-21 23:23 ------- Subject: Re: Weird translation of DO loops
On Sat, 21 Nov 2009, tkoenig at gcc dot gnu dot org wrote: > ------- Comment #6 from tkoenig at gcc dot gnu dot org 2009-11-21 23:07 > ------- > Created an attachment (id=19076) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19076&action=view) > --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=19076&action=view) > proposed patch > > This patch generates > > D.1336 = m1; > D.1337 = m2; > D.1338 = m3; > i = D.1336; > if (D.1338 > 0) > { > if (D.1337 < D.1336) goto L.2; > } > else > { > if (D.1337 > D.1336) goto L.2; > } > countm1.1 = (character(kind=4)) (D.1337 - D.1336) / (character(kind=4)) > D.1338; > while (1) > { > { > > Is this better, or did I overlook anything? That's better. Richard. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42131