Non-Confidential | ![]() | ARM DUI0375E | ||
| ||||
Home > Using the Inline and Embedded Assemblers of the ARM Compiler > Expansion of inline assembler instructions that use constants |
A constant operand specified in an instruction is not limited to the values permitted by the instruction. Instead, the compiler might translate the instruction into a sequence of instructions with the same effect.
ADD r0,r0,#1023
ADD r0,r0,#1024 SUB r0,r0,#1
MOV rn,0x12345678
MUL
instruction can
be expanded into a sequence of adds and shifts when the third operand is a constant.CPSR
by an expanded instruction is: