more on ffast-math and gcc-4.1.1 (and finally fixed)

Kevin Day thekevinday at
Mon Aug 7 23:03:49 PDT 2006

After boot-strapping my system for a few weeks, and cleaning every
error that pops-up, I am now getting something more useful error
messages with my ffast-math problems.

/bin/ld: crtfastmath.o: No such file: No such file or directory

crtfastmath pulled more results than -ffast-math on both bugzilla for
gcc and
I ended up at the following sites (one way or another):

1) -Os is note passed to/by uClibc thanks to hlfs's sed command that
removes this.
2) in gcc/config/i386/t-crtfm, i found that -msse is passed, so
targets that do not support sse will have problems with ffast-math
3) I added i386/t-crtfm to the gcc/config.gcc file where uclibc
support is added by the gcc-4.1.1-uclibc patch

4) Now the -ffast-math links once again and suddenly the apps segfault again.
(echo 'int main(){}' >> test.c && gcc test.c -ffast-math && ./a.out) == segfault

5) I apply the patch: gcc-crt-align-1.patch, which I will have
rediffed and labeled appropriately for HLFS and supplied with this
e-mail and segfault no more!! (with additional patch by Lu, Hongjiu
from intel).

6) I also have my fix for making sure crtfastmath.o gets compiled and
installed. It looks like glibc should be unaffected by this problem,
but the uClibc patch overlooks this and a rediff has been made and
I have yet to switch to the new development version of HLFS, so the
uClibc_conf-2 patch may not be needed for the new HLFS dev.

7) Now all I have to do is get the -ffast-math calls back into my
system and see if things that should be noticably effected improve.
(most specifically, MESA!!).

Kevin Day
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc-4.1.1-fix_fastmath-1.patch
Type: application/octet-stream
Size: 1764 bytes
Desc: not available
URL: <>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc-4.1.1-uClibc_conf-2.patch
Type: application/octet-stream
Size: 3423 bytes
Desc: not available
URL: <>

More information about the hlfs-dev mailing list