Re: doloop-opt deficiency

2005-08-31 Thread Sebastian Pop
Dale Johannesen wrote: > No, look closer. The version in loop-iv.c does a NEG of 'step' just > before what's shown here. The version in tree-ssa-loop-niter.c > doesn't. Reversing the operator does make them do the same thing. Then, I think this is ok. But you'll have to ask a middle-end mainta

Re: doloop-opt deficiency

2005-08-31 Thread Zdenek Dvorak
Hello, > Dale Johannesen wrote: > > I think this is a simple pasto; this code was evidently copied from > > the previous block: > > > > I don't think that this was a simple pasto. The code looks correct. > We have the same code in tree-ssa-loop-niter.c around line 436, since > we inherited this

Re: doloop-opt deficiency

2005-08-30 Thread Dale Johannesen
extern int a[]; int foo(int w) { int n = w; while (n >= 512) { a[n] = 42; n -= 256; } } On Aug 30, 2005, at 9:25 AM, Sebastian Pop wrote: Thanks for looking at this. But... Dale Johannesen wrote: I think this is a simple pasto; this code was evidently copied from the previous block: I don't th

Re: doloop-opt deficiency

2005-08-30 Thread Sebastian Pop
Dale Johannesen wrote: > I think this is a simple pasto; this code was evidently copied from > the previous block: > I don't think that this was a simple pasto. The code looks correct. We have the same code in tree-ssa-loop-niter.c around line 436, since we inherited this code from the rtl-level

doloop-opt deficiency

2005-08-29 Thread Dale Johannesen
We noticed that the simple loop here extern int a[]; int foo(int w) { int n = w; while (n >= 512) { a[n] = 42; n -= 256; } } was being treated as ineligible for the doloop modification. I think this is a simple pasto; this code was evidently copied from the previous blo