[OE-core] [PATCH] arch-armv7a.inc: default to Thumb2 instruction set for armv7a and above

Andre McCurdy armccurdy at gmail.com
Sat May 19 06:48:45 UTC 2018


On Fri, May 18, 2018 at 10:42 PM, Martin Jansa <martin.jansa at gmail.com> wrote:
> This variable was always meant to be used from DISTRO config

I'm not sure if that's true. Do you have a reference?

>, why not add it
> to:
> oe-core/meta/conf/distro/include/default-distrovars.inc
> or
> oe-core/meta/conf/distro/include/tcmode-default.inc
>
> ?

Because then it would either apply to all ARM machines, including
those which only support Thumb1, which isn't ideal. Keeping it as part
of the machine config makes it easy to apply selectively to armv7a and
above where we know it's safe and desirable. Distros can of course
still over-ride (ie the machine only sets a weak default).

Is there a specific problem you see with the current patch?

> On Sat, May 19, 2018 at 1:40 AM Khem Raj <raj.khem at gmail.com> wrote:
>>
>>
>> On Fri, May 18, 2018 at 3:50 PM Andre McCurdy <armccurdy at gmail.com> wrote:
>>>
>>> Although there may still be specific cases which can benefit from the
>>> ARM instruction set, the Thumb2 instruction set is generally a better
>>> default for armv7a class CPUs. Distros such as Debian and Fedora have
>>> been targeting Thumb2 by default for some time.
>>>
>>> Note that setting ARM_INSTRUCTION_SET has no effect unless
>>> TUNE_FEATURES contains "thumb" (which is controlled by the "t" suffix
>>> in DEFAULTTUNE, e.g. armv7vehf-neon -vs- armv7vethf-neon, etc) so out
>>> of tree machine configs may need to update their DEFAULTTUNE to take
>>> advantage of this change.
>>
>>
>>
>> I think this is a good change and we shoudl take it in thumb2 is default
>> ISA
>> for other major distros as well
>>
>> Oe based distros who ship feeds might be affected
>>>
>>>
>>>
>>> Signed-off-by: Andre McCurdy <armccurdy at gmail.com>
>>> ---
>>>  meta/conf/machine/include/arm/arch-armv7a.inc | 1 +
>>>  1 file changed, 1 insertion(+)
>>>
>>> diff --git a/meta/conf/machine/include/arm/arch-armv7a.inc
>>> b/meta/conf/machine/include/arm/arch-armv7a.inc
>>> index bad1c27..a2663d8 100644
>>> --- a/meta/conf/machine/include/arm/arch-armv7a.inc
>>> +++ b/meta/conf/machine/include/arm/arch-armv7a.inc
>>> @@ -1,4 +1,5 @@
>>>  DEFAULTTUNE ?= "armv7athf"
>>> +ARM_INSTRUCTION_SET ?= "thumb"
>>>
>>>  TUNEVALID[armv7a] = "Enable instructions for ARMv7-a"
>>>  TUNECONFLICTS[armv7a] = "armv4 armv5 armv6 armv7"
>>> --
>>> 1.9.1
>>>
>>> --
>>> _______________________________________________
>>> Openembedded-core mailing list
>>> Openembedded-core at lists.openembedded.org
>>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core at lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core



More information about the Openembedded-core mailing list