Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix compiling with IAR #64

Merged
merged 1 commit into from
Sep 4, 2023

Conversation

asmellby
Copy link
Contributor

__ARM_FEATURE_MVE is defined but set to zero on Cortex-M33, and presumably other non-MVE platforms. Check for bit 0 to be set, indicating integer MVE support. This is consistent with the __ARM_FEATURE_DSP check above.

__RESTRICT was missing from the IAR compiler abstraction.

@felix-johnny felix-johnny added the bug Something isn't working label Aug 15, 2023
@mansnils
Copy link
Contributor

@asmellby Thanks for the PR! Can I ask you to update $Date and $Revision according semver.org?
That would be 1.2.1 for arm_nn_compiler.h and 1.3.3 for arm_nn_math_types.h.

__ARM_FEATURE_MVE is defined but set to zero on Cortex-M33, and
presumably other non-MVE platforms. Check for bit 0 to be set,
indicating integer MVE support.

__RESTRICT was missing from the IAR compiler abstraction.
@asmellby
Copy link
Contributor Author

asmellby commented Aug 16, 2023

Done!
For reference, the compile errors fixed by this PR are

__STATIC_FORCEINLINE void arm_memcpy_s8(int8_t *__RESTRICT dst, const int8_t *__RESTRICT src, uint32_t block_size)
                                                             ^
"Include/arm_nnsupportfunctions.h",953  Error[Pe018]: 
          expected a ")"

for __RESTRICT and

  __STATIC_FORCEINLINE int32x4_t arm_doubling_high_mult_mve(const int32x4_t m1, const int32_t m2)
                       ^
"Include/arm_nnsupportfunctions.h",990  Error[Pe020]: 
          identifier "int32x4_t" is undefined

and a plethora of others for __ARM_FEATURE_MVE.

@mansnils
Copy link
Contributor

mansnils commented Sep 4, 2023

Done! For reference, the compile errors fixed by this PR are

__STATIC_FORCEINLINE void arm_memcpy_s8(int8_t *__RESTRICT dst, const int8_t *__RESTRICT src, uint32_t block_size)
                                                             ^
"Include/arm_nnsupportfunctions.h",953  Error[Pe018]: 
          expected a ")"

for __RESTRICT and

  __STATIC_FORCEINLINE int32x4_t arm_doubling_high_mult_mve(const int32x4_t m1, const int32_t m2)
                       ^
"Include/arm_nnsupportfunctions.h",990  Error[Pe020]: 
          identifier "int32x4_t" is undefined

and a plethora of others for __ARM_FEATURE_MVE.

Thanks and sorry for the slow response!

@mansnils mansnils merged commit b03f9a1 into ARM-software:main Sep 4, 2023
1 check passed
@mansnils mansnils mentioned this pull request Sep 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants