Index: compiler-rt/trunk/lib/builtins/assembly.h =================================================================== --- compiler-rt/trunk/lib/builtins/assembly.h +++ compiler-rt/trunk/lib/builtins/assembly.h @@ -70,9 +70,8 @@ #if defined(__ARM_ARCH_4T__) || __ARM_ARCH >= 5 #define ARM_HAS_BX #endif -#if !defined(__ARM_FEATURE_CLZ) && \ - ((__ARM_ARCH >= 6 && __ARM_ARCH_PROFILE != 'M') || \ - (__ARM_ARCH == 5 && !defined(__ARM_ARCH_5__))) +#if !defined(__ARM_FEATURE_CLZ) && __ARM_ARCH_ISA_THUMB != 1 && \ + (__ARM_ARCH >= 6 || (__ARM_ARCH == 5 && !defined(__ARM_ARCH_5__))) #define __ARM_FEATURE_CLZ #endif