All of lore.kernel.org
 help / color / mirror / Atom feed
* Building yocto with hard float support
@ 2015-11-12  9:17 Toby Gomersall
  2015-11-12 17:03 ` Mark Hatle
  0 siblings, 1 reply; 4+ messages in thread
From: Toby Gomersall @ 2015-11-12  9:17 UTC (permalink / raw)
  To: yocto

[-- Attachment #1: Type: text/plain, Size: 453 bytes --]

Hi,

I want to build yocto with hard float support. I understand that I can
point the EXTERNAL_TOOLCHAIN variable at the appropriate external hard
float compiler (gcc-5-arm-linux-gnueabihf). However, I was wondering if
there was anything within the yocto project to do this?

I'm concerned that future updates to an external compiler might affect
my build and I would prefer to use a method from within the yocto project.

Thank you,
Toby


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

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

* Re: Building yocto with hard float support
  2015-11-12  9:17 Building yocto with hard float support Toby Gomersall
@ 2015-11-12 17:03 ` Mark Hatle
  2015-11-13 10:55   ` Toby Gomersall
  2015-11-13 20:50   ` Khem Raj
  0 siblings, 2 replies; 4+ messages in thread
From: Mark Hatle @ 2015-11-12 17:03 UTC (permalink / raw)
  To: Toby Gomersall, yocto

On 11/12/15 3:17 AM, Toby Gomersall wrote:
> Hi,
> 
> I want to build yocto with hard float support. I understand that I can
> point the EXTERNAL_TOOLCHAIN variable at the appropriate external hard
> float compiler (gcc-5-arm-linux-gnueabihf). However, I was wondering if
> there was anything within the yocto project to do this?

I'm going to be pedantic for a second.. bear with me.

ARM has two ABIs, the standard EABI which passes floating point values via
integer registers and EABIHF that passes floating point values via floating
point registers.

EABI allows hardware floating point along with neon or any other core specific
optimizations.

EABIHF requires a specific set and size of VFP registers.

The Yocto Project is capable of building for both ABIs with whatever
combinations of optimizations you need.

The ABI and default processor optimization is configured by the 'DEFAULTTUNE'
parameter.  This is typically defined in your machine configuration file, either
explicitly or implicitly via the including of the tune files.


So for example, if you have an ARMv5 CPU you would likely use:

DEFAULTTUNE="armv5e"

This would select ARM EABI, no VFP.

alternatively you could do:

DEFAULTTUNE="armv5e-vfp"

This would select ARM EABI w/ VFP floating point.

OR

(what I think you are actually trying to ask)

DEFAULTTUNE="armv5ehf-vfp"

This would select ARM EABIHF w/ VFP floating point.


So start with your machine and determine which defaulttune (bitbake -e) you have
selected.  Adjust it to a compatible setting for the ABI and processor
optimizations that you wish to use.

> I'm concerned that future updates to an external compiler might affect
> my build and I would prefer to use a method from within the yocto project.

Unless you have a specific need, I don't recommend external compilers.  The
Yocto Project compilers and configurations are well tested and high quality.
While using an external compiler is support by some vendors, it adds complexity
that may not be beneficial.  (Sometimes support and other aspects of commercial
offerings outweigh the complexity..)

> Thank you,
> Toby
> 
> 
> 



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

* Re: Building yocto with hard float support
  2015-11-12 17:03 ` Mark Hatle
@ 2015-11-13 10:55   ` Toby Gomersall
  2015-11-13 20:50   ` Khem Raj
  1 sibling, 0 replies; 4+ messages in thread
From: Toby Gomersall @ 2015-11-13 10:55 UTC (permalink / raw)
  To: Mark Hatle, yocto

[-- Attachment #1: Type: text/plain, Size: 2432 bytes --]



On 12/11/15 17:03, Mark Hatle wrote:
> On 11/12/15 3:17 AM, Toby Gomersall wrote:
>> Hi,
>>
>> I want to build yocto with hard float support. I understand that I can
>> point the EXTERNAL_TOOLCHAIN variable at the appropriate external hard
>> float compiler (gcc-5-arm-linux-gnueabihf). However, I was wondering if
>> there was anything within the yocto project to do this?
> 
> I'm going to be pedantic for a second.. bear with me.
> 
> ARM has two ABIs, the standard EABI which passes floating point values via
> integer registers and EABIHF that passes floating point values via floating
> point registers.
> 
> EABI allows hardware floating point along with neon or any other core specific
> optimizations.
> 
> EABIHF requires a specific set and size of VFP registers.
> 
> The Yocto Project is capable of building for both ABIs with whatever
> combinations of optimizations you need.
> 
> The ABI and default processor optimization is configured by the 'DEFAULTTUNE'
> parameter.  This is typically defined in your machine configuration file, either
> explicitly or implicitly via the including of the tune files.
> 
> 
> So for example, if you have an ARMv5 CPU you would likely use:
> 
> DEFAULTTUNE="armv5e"
> 
> This would select ARM EABI, no VFP.
> 
> alternatively you could do:
> 
> DEFAULTTUNE="armv5e-vfp"
> 
> This would select ARM EABI w/ VFP floating point.
> 
> OR
> 
> (what I think you are actually trying to ask)
> 
> DEFAULTTUNE="armv5ehf-vfp"
> 
> This would select ARM EABIHF w/ VFP floating point.
> 
> 
> So start with your machine and determine which defaulttune (bitbake -e) you have
> selected.  Adjust it to a compatible setting for the ABI and processor
> optimizations that you wish to use.
> 
>> I'm concerned that future updates to an external compiler might affect
>> my build and I would prefer to use a method from within the yocto project.
> 
> Unless you have a specific need, I don't recommend external compilers.  The
> Yocto Project compilers and configurations are well tested and high quality.
> While using an external compiler is support by some vendors, it adds complexity
> that may not be beneficial.  (Sometimes support and other aspects of commercial
> offerings outweigh the complexity..)
> 
>> Thank you,
>> Toby
>>
>>
>>
> 

Thank you very much for your help, that was exactly what I was looking for.


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

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

* Re: Building yocto with hard float support
  2015-11-12 17:03 ` Mark Hatle
  2015-11-13 10:55   ` Toby Gomersall
@ 2015-11-13 20:50   ` Khem Raj
  1 sibling, 0 replies; 4+ messages in thread
From: Khem Raj @ 2015-11-13 20:50 UTC (permalink / raw)
  To: Mark Hatle; +Cc: Toby Gomersall, yocto

[-- Attachment #1: Type: text/plain, Size: 2705 bytes --]


> On Nov 12, 2015, at 9:03 AM, Mark Hatle <mark.hatle@windriver.com> wrote:
> 
> On 11/12/15 3:17 AM, Toby Gomersall wrote:
>> Hi,
>> 
>> I want to build yocto with hard float support. I understand that I can
>> point the EXTERNAL_TOOLCHAIN variable at the appropriate external hard
>> float compiler (gcc-5-arm-linux-gnueabihf). However, I was wondering if
>> there was anything within the yocto project to do this?
> 
> I'm going to be pedantic for a second.. bear with me.
> 
> ARM has two ABIs, the standard EABI which passes floating point values via
> integer registers and EABIHF that passes floating point values via floating
> point registers.
> 
> EABI allows hardware floating point along with neon or any other core specific
> optimizations.
> 
> EABIHF requires a specific set and size of VFP registers.
> 
> The Yocto Project is capable of building for both ABIs with whatever
> combinations of optimizations you need.
> 
> The ABI and default processor optimization is configured by the 'DEFAULTTUNE'
> parameter.  This is typically defined in your machine configuration file, either
> explicitly or implicitly via the including of the tune files.
> 
> 
> So for example, if you have an ARMv5 CPU you would likely use:
> 
> DEFAULTTUNE="armv5e"
> 
> This would select ARM EABI, no VFP.
> 
> alternatively you could do:
> 
> DEFAULTTUNE="armv5e-vfp"
> 
> This would select ARM EABI w/ VFP floating point.
> 
> OR
> 
> (what I think you are actually trying to ask)
> 
> DEFAULTTUNE="armv5ehf-vfp"
> 
> This would select ARM EABIHF w/ VFP floating point.
> 

all is fine except armv5 here will confuse people thinking that hf ABI works on armv5 as well
would have been better explained with armv7 example.

> 
> So start with your machine and determine which defaulttune (bitbake -e) you have
> selected.  Adjust it to a compatible setting for the ABI and processor
> optimizations that you wish to use.
> 
>> I'm concerned that future updates to an external compiler might affect
>> my build and I would prefer to use a method from within the yocto project.
> 
> Unless you have a specific need, I don't recommend external compilers.  The
> Yocto Project compilers and configurations are well tested and high quality.
> While using an external compiler is support by some vendors, it adds complexity
> that may not be beneficial.  (Sometimes support and other aspects of commercial
> offerings outweigh the complexity..)
> 
>> Thank you,
>> Toby
>> 
>> 
>> 
> 
> --
> _______________________________________________
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto


[-- Attachment #2: Message signed with OpenPGP using GPGMail --]
[-- Type: application/pgp-signature, Size: 211 bytes --]

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

end of thread, other threads:[~2015-11-13 20:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-12  9:17 Building yocto with hard float support Toby Gomersall
2015-11-12 17:03 ` Mark Hatle
2015-11-13 10:55   ` Toby Gomersall
2015-11-13 20:50   ` Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.