Vince Greg wrote:
Hi,
I read with the most attention the diffrents mails that I received for my
questions.
But I have again a question. To create the Official lfs liveCd all package
has been compiled with this options of optimization : CFLAGS: -Os -s
-fno-strict-aliasing but it is possible to optimize more ?
Yes, this is "optimize for size" (and on machines with low RAM and small cache this means "for speed" too) plus "strip" optimizations, plus a "don't assume that C programs behave well with pointers" pessimization.

The fact is that one doesn't want to optimize too much. The more you optimize, the more assumptions the compiler makes about the program. When such assumptions break (and this does happen rather often even with the default -O2 optimization level), the compiled program misbehaves. The book does document some known cases (Mesa, MySQL), and surely there are unknown ones. So I chose the safe side here. The programs are a bit slower, but bugs resulting from pointer aliasing are completely hidden.

--
Alexander E. Patrakov
--
http://linuxfromscratch.org/mailman/listinfo/livecd
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to