Discussion:
aarch64 toolchain support NEON and vfp features
Joy Deng
2017-10-30 07:52:45 UTC
Permalink
Hi ,

I am a SW engineer that use Linaro-toolchain to build images,

Recently, I encounter some issue about enable NEON features on ARMv8 processor platform.
I cat cpuinfo, can not find neon and vfp feature enable in list, the image was build with aarch-64 toolchian;
While, the image built by armv7l toolchain can list "neon and vfp" in cpuinfo.

I want to verify from your side,

1. if the toolchain of aarch64 version already enable" neon and vfp " in default, Because I do not find some build items that related with "neon",
2. If not supported defaultly, can you give some suggestion to enable it.

Thanks & B.R.
Joy Deng
Yao Qi
2017-10-30 09:27:30 UTC
Permalink
Post by Joy Deng
Hi ,
I am a SW engineer that use Linaro-toolchain to build images,
Recently, I encounter some issue about enable NEON features on ARMv8 processor platform.
I cat cpuinfo, can not find neon and vfp feature enable in list, the image was build with aarch-64 toolchian;
In ARMv8, it should be "asimd".
Post by Joy Deng
While, the image built by armv7l toolchain can list "neon and vfp" in cpuinfo.
I want to verify from your side,
1. if the toolchain of aarch64 version already enable" neon and vfp " in default, Because I do not find some build items that related with "neon",
2. If not supported defaultly, can you give some suggestion to enable it.
It has nothing to do with toolchain. The cpuinfo is retrieved from
Linux kernel,
and kernel returns something different for aarch64 process and aarch32
process, to order to be backward compatible. That is why your apps
get different cpuinfo on the same kernel.
--
Yao Qi
Yao Qi
2017-11-02 10:12:22 UTC
Permalink
Hi, Qi
Thanks a lot for your quick reply.
As you said, in ARMv8, neon is deployed as asimd in cpuinfo, so we can consider tool-chain will not affect the NEON function.
But, when build source code by enable neon, I can not find "-mfpu=neon" in Makefile CFLAGS defaultly on ARMv8, while I can find it when build on ARMv7.
ARMv8 is completely different from ARMv7, in many aspects. In GCC and
Linux kernel, aarch64 (arm64) is different backend/port from armv7. Some
options are not portable from v7 to v8.
Does it affect neon function enable? As I known, if we want enable neon, we should build with "-mfpu=neon" flags.
In aarch64 (64-bit state in armv8), asimd is mandatory by the architecture, so
aarch64 compiler can generate asimd instructions without any options. armv7
is different, because neon is optional, so you need an option to enable it.
--
Yao Qi
Joy Deng
2017-11-03 02:33:01 UTC
Permalink
Ok , got it . thanks a lot for your detailed comments.

Thanks,
Joy

-----Original Message-----
From: Yao Qi [mailto:***@linaro.org]
Sent: Thursday, November 02, 2017 6:12 PM
To: Joy Deng <***@nxp.com>
Cc: linaro-***@lists.linaro.org; Ting Liu <***@nxp.com>; Shuo Zhang <***@nxp.com>
Subject: Re: aarch64 toolchain support NEON and vfp features
Hi, Qi
Thanks a lot for your quick reply.
As you said, in ARMv8, neon is deployed as asimd in cpuinfo, so we can consider tool-chain will not affect the NEON function.
But, when build source code by enable neon, I can not find "-mfpu=neon" in Makefile CFLAGS defaultly on ARMv8, while I can find it when build on ARMv7.
ARMv8 is completely different from ARMv7, in many aspects. In GCC and Linux kernel, aarch64 (arm64) is different backend/port from armv7. Some options are not portable from v7 to v8.
Does it affect neon function enable? As I known, if we want enable neon, we should build with "-mfpu=neon" flags.
In aarch64 (64-bit state in armv8), asimd is mandatory by the architecture, so
aarch64 compiler can generate asimd instructions without any options. armv7 is different, because neon is optional, so you need an option to enable it.
--
Yao Qi
Loading...