Skip to content

Commit 647b755

Browse files
Corrected issue ARM-software#146
1 parent 4acfef7 commit 647b755

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Include/arm_math_types.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ extern "C"
119119
#endif
120120
#endif
121121

122-
#if (__ARM_FEATURE_MVE & 2)
122+
#if defined(__ARM_FEATURE_MVE) && (__ARM_FEATURE_MVE & 2)
123123
#if !defined(ARM_MATH_MVEF)
124124
#define ARM_MATH_MVEF
125125
#endif

Include/arm_math_types_f16.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,16 +49,16 @@ If it is not available, f16 version of the kernels
4949
won't be built.
5050
5151
*/
52-
#if !(__ARM_FEATURE_MVE & 2)
52+
#if defined(__ARM_FEATURE_MVE) && (__ARM_FEATURE_MVE & 2)
53+
/* When Vector float16, this flag is always defined and can't be disabled */
54+
#define ARM_FLOAT16_SUPPORTED
55+
#else
5356
#if !defined(DISABLEFLOAT16)
5457
#if defined(__ARM_FP16_FORMAT_IEEE) || defined(__ARM_FP16_FORMAT_ALTERNATIVE)
5558
typedef __fp16 float16_t;
5659
#define ARM_FLOAT16_SUPPORTED
5760
#endif
5861
#endif
59-
#else
60-
/* When Vector float16, this flag is always defined and can't be disabled */
61-
#define ARM_FLOAT16_SUPPORTED
6262
#endif
6363

6464
#if defined(ARM_MATH_NEON) || (defined(ARM_MATH_MVEF) && !defined(ARM_MATH_AUTOVECTORIZE)) /* floating point vector*/

0 commit comments

Comments
 (0)