Skip to contentSkip to conversation

beagleboard: enable hard floating point abi

PATCH In review Darren Hart 5 participants 9 messages Aug 19, 2011 – Aug 23, 2011

lore
Share & tools
lore
#0 lore raw

cover beagleboard: enable hard floating point abi

There have been requests to enable the hard floating point abi for the Yocto Project Beagleboard BSP. With the recent cortexa8 tune file changes I submitted to oe-core, subject "tune: update arm7a and cortexa8 tune files", it is now possible for the machine config to change DEFAULTTUNE to take advantage of the newly added "hf" tune variants.

Some binary libraries are incompatible with hardfp, as is 3D support on the Beagleboard. We don't ship either, so I feel it makes sense to take advantage of as much of the core CPU features as possible.

This addresses [YOCTO 1203]
http://bugzilla.yoctoproject.org/show_bug.cgi?id=1204

I don't feel very strongly about this however. So if someone would like to argue for hardfp not being the default, please do so and I can easily comment out the DEFAULTTUNE change and add a comment in the machine config describing how to enable hardfp.

The following changes since commit 53bdf3fd520b75730cc802f52121dd394894e130:

tune: Add hard floating point variants of cortexa8 tunes (2011-08-19 15:02:10 -0700)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dvhart/beagleboard-hardfp
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dvhart/beagleboard-hardfp

Darren Hart (1):
beagleboard: enable hard floating point abi

 meta-yocto/conf/machine/beagleboard.conf |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
Signature · 1 line
1.7.6
#1 lore raw

PATCH 1/1 beagleboard: enable hard floating point abi

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi. This can be easily disabled by anyone building on top of meta-yocto if they need the soft abi by overriding DEFAULT_TUNE.

CC Jason Kridner <[email protected]>
CC Koen Kooi <[email protected]>
---
 meta-yocto/conf/machine/beagleboard.conf |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
meta-yocto/conf/machine/beagleboard.conf +5 -0
index 0b3cebc..8f11732 100644
@@ -18,6 +18,11 @@ MACHINE_EXTRA_RRECOMMENDS += "beagleboard-audio"
 # Allow for MMC booting (required by the NAND-less Beagleboard XM)
 EXTRA_IMAGEDEPENDS += "u-boot x-load"
 
+# Use the hard floating point abi. This breaks some binary libraries and
+# 3D. Since poky and meta-yocto do not provide these by default, enable the
+# hard floating point abi. Comment out the following or override it to disable
+# it.
+DEFAULTTUNE ?= "cortexa8hf-neon"
 include conf/machine/include/tune-cortexa8.inc
 
 IMAGE_FSTYPES += "tar.bz2 jffs2"
Signature · 1 line
1.7.6
#2 lore raw
Quoted 23 lines · Darren Hart

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi. This can be easily disabled by anyone building on top of meta-yocto if they need the soft abi by overriding DEFAULT_TUNE.

CC Jason Kridner <[email protected]>
CC Koen Kooi <[email protected]>

---
 meta-yocto/conf/machine/beagleboard.conf |    5 +++++

 1 files changed, 5 insertions(+), 0 deletions(-)
meta-yocto/conf/machine/beagleboard.conf +0 -0
index 0b3cebc..8f11732 100644
@@ -18,6 +18,11 @@ MACHINE_EXTRA_RRECOMMENDS += "beagleboard-audio"
  # Allow for MMC booting (required by the NAND-less Beagleboard XM)

 EXTRA_IMAGEDEPENDS += "u-boot x-load"

meta-yocto/conf/machine/beagleboard.conf MACHINE_EXTRA_RRECOMMENDS += "beagleboard-audio" · line 25

Quoted 5 lines
meta-yocto/conf/machine/beagleboard.conf +5 -0
+# Use the hard floating point abi. This breaks some binary libraries and
+# 3D. Since poky and meta-yocto do not provide these by default, enable the
+# hard floating point abi. Comment out the following or override it to disable
+# it.
+DEFAULTTUNE ?= "cortexa8hf-neon"

I'm not really fond of what this breaks, but I don't yet have a vision of what I'd be doing with meta-yocto yet and therefore am open to this project giving test coverage to new conditions like this.

Quoted 7 lines

 include conf/machine/include/tune-cortexa8.inc

 IMAGE_FSTYPES += "tar.bz2 jffs2"
--
1.7.6

#3 lore raw
In reply to Darren Hart

Op 20 aug. 2011, om 00:23 heeft Darren Hart het volgende geschreven:

Quoted 5 lines

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi.

What advantage are you talking about? So far everyone has been unable to provide real-world numbers[1] that show hardfp making a difference compared to a properly configured softfp. The numbers debian and meego are showing are comparing it against completely vfpless builds, which borders on fraud.

Yocto is of course free to do what it pleases, but switching to hardfp isn't going to make beagle support better, only worse. But if that's your goal, go for it, meta-ti is still there to provide the absolute best beagle support.

[1] povray is the only outlier, but I don't think people will build beagle based renderfarms in the near future.

#4 lore raw
Quoted 10 lines · Koen Kooi

Op 20 aug. 2011, om 00:23 heeft Darren Hart het volgende geschreven:

Quoted 6 lines

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi.

Quoted 4 lines

What advantage are you talking about? So far everyone has been unable to provide real-world numbers[1] that show hardfp making a difference compared to a properly configured softfp. The numbers debian and meego are showing are comparing it against completely vfpless builds,

That's good reasoning to stick with softfp+neon. Unfortunately I can't find the mail threads that first got me looking into adding hardfp support. As I said, I'm not sold on the idea, but it was requested so I looked into how to address it.

If nobody comes forward saying they would really like to have this, I'm going to modify the patch series to disable hardfp by default, but leave the infrastructure in place so people can enable if they like.

Signature · 3 lines
Darren Hart
Intel Open Source Technology Center
Yocto Project - Linux Kernel
#5 lore raw
Quoted 17 lines · Darren Hart
Quoted 10 lines · Koen Kooi

Op 20 aug. 2011, om 00:23 heeft Darren Hart het volgende geschreven:

Quoted 6 lines

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi.

Quoted 4 lines

What advantage are you talking about? So far everyone has been unable to provide real-world numbers[1] that show hardfp making a difference compared to a properly configured softfp. The numbers debian and meego are showing are comparing it against completely vfpless builds,

Quoted 8 lines

That's good reasoning to stick with softfp+neon. Unfortunately I can't find the mail threads that first got me looking into adding hardfp support. As I said, I'm not sold on the idea, but it was requested so I looked into how to address it.

If nobody comes forward saying they would really like to have this, I'm going to modify the patch series to disable hardfp by default, but leave the infrastructure in place so people can enable if they like.

Well, are there some softfp related config bits we need on the yocto side that meta-ti has, in order to bring that performance back in line?

Signature · 1 line
Tom
#6 lore raw
Quoted 23 lines · Tom Rini
Quoted 22 lines · Darren Hart
Quoted 10 lines · Koen Kooi

Op 20 aug. 2011, om 00:23 heeft Darren Hart het volgende geschreven:

Quoted 6 lines

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi.

Quoted 4 lines

What advantage are you talking about? So far everyone has been unable to provide real-world numbers[1] that show hardfp making a difference compared to a properly configured softfp. The numbers debian and meego are showing are comparing it against completely vfpless builds,

That's good reasoning to stick with softfp+neon. Unfortunately I can't find the mail threads that first got me looking into adding hardfp support. As I said, I'm not sold on the idea, but it was requested so I looked into how to address it.

Quoted 7 lines
Quoted 3 lines

If nobody comes forward saying they would really like to have this, I'm going to modify the patch series to disable hardfp by default, but leave the infrastructure in place so people can enable if they like.

Well, are there some softfp related config bits we need on the yocto side that meta-ti has, in order to bring that performance back in line?

Are you referring to a specific performance measure?

Jason, Koen, are there any such config bits? We are currently using the cortexa8-neon tune configuration from oe-core.

Signature · 3 lines
Darren Hart
Intel Open Source Technology Center
Yocto Project - Linux Kernel
#7 lore raw
Quoted 28 lines · Darren Hart
Quoted 27 lines · Tom Rini
Quoted 25 lines · Darren Hart
Quoted 10 lines · Koen Kooi

Op 20 aug. 2011, om 00:23 heeft Darren Hart het volgende geschreven:

Quoted 6 lines

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi.

Quoted 4 lines

What advantage are you talking about? So far everyone has been unable to provide real-world numbers[1] that show hardfp making a difference compared to a properly configured softfp. The numbers debian and meego are showing are comparing it against completely vfpless builds,

That's good reasoning to stick with softfp+neon. Unfortunately I can't find the mail threads that first got me looking into adding hardfp support. As I said, I'm not sold on the idea, but it was requested so I looked into how to address it.

If nobody comes forward saying they would really like to have this, I'm going to modify the patch series to disable hardfp by default, but leave the infrastructure in place so people can enable if they like.

Quoted 5 lines
Quoted 3 lines

Well, are there some softfp related config bits we need on the yocto side that meta-ti has, in order to bring that performance back in line?

Are you referring to a specific performance measure?

Just the general ones that have caused people to say softfp+neon isn't enough (outside of povray :)).

Signature · 1 line
Tom
#8 lore raw
In reply to Koen Kooi
Quoted 9 lines · Koen Kooi

Op 20 aug. 2011, om 00:23 heeft Darren Hart het volgende geschreven:

Quoted 5 lines

Fixes [YOCTO #1203]

Using the hard floating point abi is incompatible with some binary libaries and 3D support for the Beagleboard. As we do not provide these in poky and meta-yocto, we can take advantage of the hard floating point abi.

Quoted 5 lines

What advantage are you talking about? So far everyone has been unable to provide real-world numbers[1] that show hardfp making a difference compared to a properly configured softfp. The numbers debian and meego are showing are comparing it against completely vfpless builds, which borders on fraud.

Yocto is of course free to do what it pleases, but switching to hardfp isn't going to make beagle support better, only worse. But if that's your goal, go for it, meta-ti is still there to provide the absolute best beagle support.

[1] povray is the only outlier, but I don't think people will build beagle based renderfarms in the near future.

The big win for hard float ABI (emphasis mine) is functions that return floating point values. I personally care about this, but we also know returning floats is "bad" so we sort of avoid it.

I agree with Phil Blundell that this is not a beagle specific thing.

Long term I expect hard float to become normal, but I see no need to rush there (no matter what other distros are claiming).

Philip