Freebsd-7.4 + std gcc 4.2.1 fails to honour -march=i586
Dan Nelson
dnelson at allantgroup.com
Sun Jul 17 02:02:25 UTC 2011
In the last episode (Jul 17), Julian H. Stacey said:
> Hi all,
> ENVIRONMENT:
> Standard
> gcc version 4.2.1 20070719 [FreeBSD]
> that comes with
> FreeBSD 7.4-RELEASE
> on my 686 host with
> CFLAGS += -march=i586
> in
> /etc/make.conf
> used with
> cd /usr/src/bin/who ; make clean ; make cleandir ; make clean ; make
> reports
> Warning: Object directory not changed from original /usr/src/usr.bin/who
> cc -O2 -fno-strict-aliasing -march=i586 -c /usr/src/usr.bin/who/who.c
> cc -O2 -fno-strict-aliasing -march=i586 -o who who.o
> looking with
> file who
> reports
> who: ELF 32-bit LSB executable, Intel 80386, version 1
> (FreeBSD), for FreeBSD 7.4, dynamically linked (uses shared
> libs), FreeBSD-style, not stripped
>
> Problem:
> Use it from a 586 7.4-RELEASE host (AMD+NFS)
> file /host/sony/usr/src/usr.bin/who/who
> /host/sony/usr/src/usr.bin/who/who: ELF 32-bit LSB executable,
> Intel 80386, version 1 (FreeBSD), for FreeBSD 7.4, dynamically
> linked (uses shared libs), FreeBSD-style, not stripped
> /host/sony/usr/src/usr.bin/who/who
> fails with
> Illegal instruction
Were the crt*.o files on your fast machine also compiled with -march=i586 ?
If you run gdb on the core file, can you determine what function the bad
instruction is in?
--
Dan Nelson
dnelson at allantgroup.com
More information about the freebsd-hackers
mailing list