[meta-oe,4/4] freerdp: Enable NEON SIMD on armv7a and armv7ve

Message ID 20211118175144.1708578-4-marex@denx.de
State New
Headers show
Series [meta-oe,1/4] freerdp: Upgrade 2.3.0 -> 2.4.1 | expand

Commit Message

Marek Vasut Nov. 18, 2021, 5:51 p.m. UTC
Enable NEON SIMD on armv7a and armv7ve, this does improve performance
on these systems. Aarch64 NEON SIMD is available only in FreeRDP 3.x,
so do not enable NEON on aarch64 just yet.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Alexander Kanavin <alex@linutronix.de>
Cc: Khem Raj <raj.khem@gmail.com>
---
 meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Khem Raj Nov. 18, 2021, 7:03 p.m. UTC | #1
On 11/18/21 9:51 AM, Marek Vasut wrote:
> Enable NEON SIMD on armv7a and armv7ve, this does improve performance
> on these systems. Aarch64 NEON SIMD is available only in FreeRDP 3.x,
> so do not enable NEON on aarch64 just yet.
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Alexander Kanavin <alex@linutronix.de>
> Cc: Khem Raj <raj.khem@gmail.com>
> ---
>   meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb | 4 ++++
>   1 file changed, 4 insertions(+)
> 
> diff --git a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
> index aba77e20f..571ba5fcb 100644
> --- a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
> +++ b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
> @@ -30,6 +30,10 @@ EXTRA_OECMAKE += " \
>       -DWITH_MANPAGES=OFF \
>   "
>   
> +EXTRA_OECMAKE:append:armv7a = " -DWITH_NEON=ON"
> +EXTRA_OECMAKE:append:armv7ve = " -DWITH_NEON=ON"


its better to check for neon feature

EXTRA_OECMAKE:append = ${@bb.utils.contains('TUNE_FEATURES', 'neon', ' 
-DWITH_NEON=ON', '', d)}

> +# ARMv8a NEON support is available only in FreeRDP 3.x
> +
>   PACKAGECONFIG ??= " \
>       ${@bb.utils.filter('DISTRO_FEATURES', 'directfb pam pulseaudio wayland x11', d)}\
>       gstreamer cups pcsc \
>
Marek Vasut Nov. 18, 2021, 7:11 p.m. UTC | #2
On 11/18/21 8:03 PM, Khem Raj wrote:

[...]

>> diff --git a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb 
>> b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
>> index aba77e20f..571ba5fcb 100644
>> --- a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
>> +++ b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
>> @@ -30,6 +30,10 @@ EXTRA_OECMAKE += " \
>>       -DWITH_MANPAGES=OFF \
>>   "
>> +EXTRA_OECMAKE:append:armv7a = " -DWITH_NEON=ON"
>> +EXTRA_OECMAKE:append:armv7ve = " -DWITH_NEON=ON"
> 
> 
> its better to check for neon feature
> 
> EXTRA_OECMAKE:append = ${@bb.utils.contains('TUNE_FEATURES', 'neon', ' 
> -DWITH_NEON=ON', '', d)}

Doesn't that enable it for ARMv8a too ?

Feel free to pick the first three of these patches if they are OK and 
I'll respin this one a bit later.
Marek Vasut Nov. 18, 2021, 7:47 p.m. UTC | #3
On 11/18/21 8:15 PM, Khem Raj wrote:
> 
> 
> On 11/18/21 11:11 AM, Marek Vasut wrote:
>> On 11/18/21 8:03 PM, Khem Raj wrote:
>>
>> [...]
>>
>>>> diff --git a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb 
>>>> b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
>>>> index aba77e20f..571ba5fcb 100644
>>>> --- a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
>>>> +++ b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
>>>> @@ -30,6 +30,10 @@ EXTRA_OECMAKE += " \
>>>>       -DWITH_MANPAGES=OFF \
>>>>   "
>>>> +EXTRA_OECMAKE:append:armv7a = " -DWITH_NEON=ON"
>>>> +EXTRA_OECMAKE:append:armv7ve = " -DWITH_NEON=ON"
>>>
>>>
>>> its better to check for neon feature
>>>
>>> EXTRA_OECMAKE:append = ${@bb.utils.contains('TUNE_FEATURES', 'neon', 
>>> ' -DWITH_NEON=ON', '', d)}
>>
>> Doesn't that enable it for ARMv8a too ?
>>
> 
> for cortexa32 only.

The neon build is broken on armv8a until freerdp 3.0.0 is out, then we 
can enable it for armv8a too.

Patch

diff --git a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
index aba77e20f..571ba5fcb 100644
--- a/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
+++ b/meta-oe/recipes-support/freerdp/freerdp_2.4.1.bb
@@ -30,6 +30,10 @@  EXTRA_OECMAKE += " \
     -DWITH_MANPAGES=OFF \
 "
 
+EXTRA_OECMAKE:append:armv7a = " -DWITH_NEON=ON"
+EXTRA_OECMAKE:append:armv7ve = " -DWITH_NEON=ON"
+# ARMv8a NEON support is available only in FreeRDP 3.x
+
 PACKAGECONFIG ??= " \
     ${@bb.utils.filter('DISTRO_FEATURES', 'directfb pam pulseaudio wayland x11', d)}\
     gstreamer cups pcsc \