Floating point problems when building for ARM v5
Brian Clarke
brian.clarke@oxsemi.com
Thu Sep 23 16:16:00 GMT 2004
Hello all,
I am attempting to use a GCC 3.4.2 based ARM toolchain (binutils-2.15,
newlib-1.12.0) to build for both v4 and v5 instruction targets.
When building for a v4 target all is well, the toolchain's libs (libc,
libgcc) clain to be built for FPA floating point as do my object files
and the code runs fine on the target.
When I try to build for a v5 target (actually ARM926EJ-S, which has no
hardware FP support) the linker complains about floating point
conflicts. The toolchain libs are again FPA, but my object files are VFP
format.
I've tried convincing the toolchain to build my libraries for FPA, via
experimenting with -msoft-float, -mhard-float and -fp=2/3 but each time
I still get VFP libraries. I tried specifying the -mfpu=fpa switch, but
this is rejected by the compiler.
Can anyone suggest a way to get the toolchain to build FPA libraries?
I've also tried to understand how to build the toolchain so it will
build VFP libraries (i.e. for libc, libgcc). I have specified
--with-arch=armv5te to the configure scripts of gcc (pt1 and pt2),
newlib and binutils. This has resulted in libgcc being built for VFP,
but libc is still built for FPA, suggesting I need to provide some other
option while configuring newlib. The options I'm currently giving to
newlib are:
configure --target=arm-elf --with-arch=armv5te --enable-multilib
--enable-interwork --prefix=$(PREFIX-PATH) --exec-prefix=$(EXEC-PATH)
I expected to see multiple versions of libc etc. built due to the
--enable-multilib option, but only one appears, with FPA as the floating
point type. Can anyone suggest an option to specify to the newlib
configure to produce VFP libraries? The newlib config-ml.in file doesn't
seem to allow for selecting VFP.
Thanks,
Brian.
More information about the Gcc-help
mailing list