Thread (19 messages) flat view 19 messages, 7 authors, 2007-12-09

Re: [PATCH] Fake NUMA emulation for PowerPC

From: Arnd Bergmann <arnd@arndb.de>
Date: 2007-12-07 21:58:40
Also in: lkml

On Friday 07 December 2007, Balbir Singh wrote:
Balbir Singh wrote:
quoted
Geert Uytterhoeven wrote:
quoted
On Sat, 8 Dec 2007, Balbir Singh wrote:
quoted
+=A0=A0=A0if (strstr(p, "fake=3D"))
+=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0cmdline =3D p + 5;=A0=A0=A0=A0=A0=
=A0=A0=A0/* 5 is faster than strlen("fake=3D") */
quoted
quoted
Really? My gcc is smart enough to replace the `strlen("fake=3D")' by 5=
, even
quoted
quoted
without -O.
=20
Thanks for pointing that out, but I am surprised that a compiler would
interpret library routines like strlen.
=20
=20
I just tested it and it turns out that you are right. I'll go hunt to
see where gcc gets its magic powers from.
=20
Even if it wasn't: Why the heck would you want to optimize this? The functi=
on
is run _once_ at boot time and the object code gets thrown away afterwards!

	Arnd <><
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help