6.3 __arm_mcr, __arm_mcr2, __arm_mcrr, __arm_mcrr2 Intrinsic Function
Inserts a coprocessor write instruction, MCR,
MCR2, MCRR, or
MCRR2. The parameters
coproc, opc1,
opc2, CRn,
and CRm will be encoded in the instruction and must
therefore be constants.
These intrinsic functions are defined according to the Arm C Language Extensions (ACLE).
Suggested Replacement
__builtin_arm_mcr
__builtin_arm_mcr2
__builtin_arm_mcrr
__builtin_arm_mcrr2
Caveats
None.
Examples
Consider migrating IAR code such
as:
void __arm_mcr(__cpid coproc, __cpopc opc1, __ul src, __cpreg CRn, __cpreg CRm, __cpopc opc2);
void __arm_mcr2(__cpid coproc, __cpopc opc1, __ul src, __cpreg CRn, __cpreg CRm, __cpopc opc2);
void __arm_mcrr(__cpid coproc, __cpopc opc1, unsigned long long src, __cpreg CRm);
void __arm_mcrr2(__cpid coproc, __cpopc opc1, unsigned long long src, __cpreg CRm);
to
MPLAB XC codes similar
to:void __builtin_arm_mcr(__cpid coproc, __cpopc opc1, __ul src, __cpreg CRn, __cpreg CRm, __cpopc opc2);
void __builtin_arm_mcr2(__cpid coproc, __cpopc opc1, __ul src, __cpreg CRn, __cpreg CRm, __cpopc opc2);
void __builtin_arm_mcrr(__cpid coproc, __cpopc opc1, unsigned long long src, __cpreg CRm);
void __builtin_arm_mcrr2(__cpid coproc, __cpopc opc1, unsigned long long src, __cpreg CRm);
Further Information
None.
