Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] Question about float-abi
@ 2012-02-28 10:55 Ludovic Desroches
  2012-02-29 11:08 ` Ludovic Desroches
  0 siblings, 1 reply; 5+ messages in thread
From: Ludovic Desroches @ 2012-02-28 10:55 UTC (permalink / raw)
  To: buildroot

Hi,

I am trying to play with the -mfloat-abi option to see performance improvement
between soft, softfp and hard values.

I was not sure that the toolchain generated by Buildroot (even if BR2_VFP_FLOAT
is selected) will fit my needs (since I had low performances on nbench floating
point index).

Then I decided to use Crosstool-ng to generate my toolchain (moreover I'll be
able to compare glibc/eglibc/uclibc performances). I set the -mtune, -mfpu
options and changed -mfloat-abi value to generate three toolchains: one with
-mfloat-abi=soft, one with -mfloat-abi=softfp and one with -mfloat-abi=hard.

Then I compiled nbench as a static binary. The results of the benchmark are
consistent. Floating point index is low for mfloat-abi=soft, much better for
softfp and hard.

So I would like to remove the static option. I expected to have an issue with
at least one of the three binaries. The rootfs I used was generated with
Buildroot and the code sourcery toolchain (I also tried with the toolchains I
have generated with crosstool-ng).
I could run the binary with mfloat-abi=hard but floating point performances
were low so it seems that the libm/libc are not using the vfp unit. Why not!
I was surprised when I could also run the binary with mfloat-abi=soft because
I thought that soft and hard float-abi were not compatible.

If I try to compile nbench with mfloat-abi=hard with the toolchain generated
with mfloat-abi=soft I have some erros telling me that I am using VFP register
arguments. In this case, the behavior is ok.


I don't understand what happens when I generate my rootfs with Buildroot.
Why both soft and hard float-abi can be used? Why my libc is not using the vfp
unit? BR2_VFP_FLOAT options seems not sufficient. I tried to add my mtune,
mfpu and mfloat-abi flag to BR2_TARGET_OPTIMIZATION but I am not sure that it
is the good place since the behavior and performances are still the same.

Thanks for your help.

Regards.

Ludovic

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-03-01  8:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-28 10:55 [Buildroot] Question about float-abi Ludovic Desroches
2012-02-29 11:08 ` Ludovic Desroches
2012-02-29 13:49   ` Ludovic Desroches
2012-02-29 14:47     ` Thomas Petazzoni
2012-03-01  8:09       ` Ludovic Desroches

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox