Re: no-op delay loops

2015-12-01 Thread Richard Henderson
On 11/30/2015 01:29 PM, Rasmus Villemoes wrote: ./arch/alpha/boot/main.c:187:1-4: no-op delay loop Not sure why this is there. The runkernel function that preceeds it cannot return, having performed an indirect branch (not a call) to the kernel start. I see no reason to actually change anyt

Re: no-op delay loops

2015-11-30 Thread Ralf Baechle
On Mon, Nov 30, 2015 at 10:29:26PM +0100, Rasmus Villemoes wrote: > OK, thanks. That's a very very long time ago. > > FWIW, the remaining instances that my trivial coccinelle script found > are After your initial report I also wrote a coccinelle which is looking also for delay loops implemented

Re: no-op delay loops

2015-11-30 Thread Arnd Bergmann
On Monday 30 November 2015 22:29:26 Rasmus Villemoes wrote: > > OK, thanks. That's a very very long time ago. > > FWIW, the remaining instances that my trivial coccinelle script found > are > > ./arch/alpha/boot/main.c:187:1-4: no-op delay loop > ./arch/m68k/68000/m68VZ328.c:86:10-13: no-op dela

Re: no-op delay loops

2015-11-30 Thread Rasmus Villemoes
On Fri, Nov 27 2015, Arnd Bergmann wrote: > On Friday 27 November 2015 09:53:50 Rasmus Villemoes wrote: >> >> It seems that gcc happily compiles >> >> for (i = 0; i < 10; ++i) ; >> >> into simply >> >> i = 10; >> >> (which is then usually eliminated as a dead store). At least

Re: no-op delay loops

2015-11-27 Thread Ralf Baechle
On Fri, Nov 27, 2015 at 09:53:50AM +0100, Rasmus Villemoes wrote: > It seems that gcc happily compiles > > for (i = 0; i < 10; ++i) ; > > into simply > > i = 10; > > (which is then usually eliminated as a dead store). At least at -O2, and > when i is not declared volatile. So i

Re: no-op delay loops

2015-11-27 Thread Arnd Bergmann
On Friday 27 November 2015 09:53:50 Rasmus Villemoes wrote: > > It seems that gcc happily compiles > > for (i = 0; i < 10; ++i) ; > > into simply > > i = 10; > > (which is then usually eliminated as a dead store). At least at -O2, and > when i is not declared volatile. So it wo

Re: no-op delay loops

2015-11-27 Thread Andy Shevchenko
On Fri, Nov 27, 2015 at 11:04 AM, yalin wang wrote: >> On Nov 27, 2015, at 16:53, Rasmus Villemoes wrote: >> It seems that gcc happily compiles >> >> for (i = 0; i < 10; ++i) ; >> >> into simply >> >> i = 10; >> >> (which is then usually eliminated as a dead store). At least at -

Re: no-op delay loops

2015-11-27 Thread yalin wang
> On Nov 27, 2015, at 16:53, Rasmus Villemoes wrote: > > Hi, > > It seems that gcc happily compiles > > for (i = 0; i < 10; ++i) ; > > into simply > > i = 10; > > (which is then usually eliminated as a dead store). At least at -O2, and > when i is not declared volatile. So i

no-op delay loops

2015-11-27 Thread Rasmus Villemoes
Hi, It seems that gcc happily compiles for (i = 0; i < 10; ++i) ; into simply i = 10; (which is then usually eliminated as a dead store). At least at -O2, and when i is not declared volatile. So it would seem that the loops at arch/mips/pci/pci-rt2880.c:235 arch/mips/pmcs-msp7