ARM Neon Compilation Error

Source: Internet
Author: User


Compiling the Neon program on the AARCH64 ARM processor, the following error occurred:


/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:5792:1: Error:inlining failed in call to Always_inline ' Vdupq_n _s32 ': Target specific option mismatch
VDUPQ_N_S32 (int32_t __a)
^~~~~~~~~~~
Convolution_neon_int32.c:94:13:note:called from here
int32x4_t sum_t = vdupq_n_s32 (0);
^~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:583:1: Error:inlining failed in call to Always_inline ' Vaddq_ S32 ': Target specific option mismatch
Vaddq_s32 (int32x4_t __a, int32x4_t __b)
^~~~~~~~~
Convolution_neon_int32.c:103:10:note:called from here
sum_t = Vaddq_s32 (sum_t, multiply_t);
~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:1072:1: Error:inlining failed in call to Always_inline ' Vmulq_ S32 ': Target specific option mismatch
Vmulq_s32 (int32x4_t __a, int32x4_t __b)
^~~~~~~~~
Convolution_neon_int32.c:102:15:note:called from here
multiply_t = Vmulq_s32 (matb_t, veca_t);
~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:8997:1: Error:inlining failed in call to Always_inline ' Vld1q_ S32 ': Target specific option mismatch
VLD1Q_S32 (const int32_t * __a)
^~~~~~~~~
Convolution_neon_int32.c:101:11:note:called from here
veca_t = Vld1q_s32 (Ptr_veca);
~~~~~~~^~~~~~~~~~~~~~~~~~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:8997:1: Error:inlining failed in call to Always_inline ' Vld1q_ S32 ': Target specific option mismatch
VLD1Q_S32 (const int32_t * __a)
^~~~~~~~~
Convolution_neon_int32.c:99:11:note:called from here
matb_t = Vld1q_s32 (PTR_MATB);
~~~~~~~^~~~~~~~~~~~~~~~~~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:5299:1: Error:inlining failed in call to Always_inline ' vget_ Lane_s32 ': Target specific option mismatch
Vget_lane_s32 (int32x2_t __a, const int __b)
^~~~~~~~~~~~~
Convolution_neon_int32.c:117:10:note:called from here
Sum + = Vget_lane_s32 (half_t, 1);
^~~~~~~~~~~~~~~~~~~~~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:5299:1: Error:inlining failed in call to Always_inline ' vget_ Lane_s32 ': Target specific option mismatch
Vget_lane_s32 (int32x2_t __a, const int __b)
^~~~~~~~~~~~~
Convolution_neon_int32.c:116:10:note:called from here
Sum + = vget_lane_s32 (half_t, 0);
^~~~~~~~~~~~~~~~~~~~~~~~
In file included from convolution_neon_int32.c:3:0:
/usr/lib/gcc/arm-linux-gnueabihf/6/include/arm_neon.h:3061:1: Error:inlining failed in call to Always_inline ' Vpadd_ S32 ': Target specific option mismatch
Vpadd_s32 (int32x2_t __a, int32x2_t __b)


The workaround is to add the following compile option:-march=armv8-a-marm-mfpu=neon

Arm-linux-gnueabihf-gcc-march=armv8-a-marm-mfpu=neon Convolution_neon_int32.c-o Convolution_neon_int32


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.