mod5
mod5
PRE
cpsr = nzcvqiFt_SVC
r0 = 0x00000000
r1 = 0x70000000 (positive)
r2 = 0x7fffffff (positive)
ADDS r0, r1, r2
POST
cpsr = NzcVqiFt_SVC
r0 = 0xefffffff (negative)
Conditional Execution
• Most ARM instructions are conditionally executed—you can specify that the
instruction only executes if the condition code flags pass a given condition or test.
• The condition field is a two-letter mnemonic appended to the instruction
mnemonic. The default mnemonic is AL, or always execute.
GCD without conditional execution
GCD using conditional execution