glibc macro FPU_GETCW, FPU_SETCP (see below) is rejected by clang because ARMAsmParser thinks that cp10, cp11 is not accessible under armv7/armv8. That's not correct for armv7a with neon/vfp feature.
According to ARMv7a Architecture Reference manual - A2.9
Any implementation that includes either or both of the Advanced SIMD extension and the VFP extension must enable access to both CP10 and CP11.
Code reference -
> sysdeps/arm/fpu__control.h
#define _FPU_GETCW(cw) \
__asm__ __volatile__ ("mrc p10, 7, %0, cr1, cr0, 0" : "=r" (cw))
#define _FPU_SETCW(cw) \
__asm__ __volatile__ ("mcr p10, 7, %0, cr1, cr0, 0" : : "r" (cw))
> ARMAsmParser.cpp -
ARMAsmParser::OperandMatchResultTy
... ...
// ARMv7 and v8 don't allow cp10/cp11 due to VFP/NEON specific instructions
if ((hasV7Ops() || hasV8Ops()) && (Num == 10 || Num == 11))
return MatchOperand_NoMatch;
[reply] [-] Comment 1
Comment 1 by llozano@chromium.org
, Oct 7 2016