![ARM Cortex-M4 Generic User Manual Download Page 49](http://html.mh-extra.com/html/arm/cortex-m4/cortex-m4_generic-user-manual_2973228049.webp)
The Cortex-M4 Instruction Set
ARM DUI 0553A
Copyright © 2010 ARM. All rights reserved.
3-2
ID121610
Non-Confidential
3.1
Instruction set summary
The processor implements a version of the Thumb instruction set.
lists the supported
instructions.
Note
In
•
angle brackets, <>, enclose alternative forms of the operand
•
braces, {}, enclose optional operands
•
the Operands column is not exhaustive
•
Op2
is a flexible second operand that can be either a register or a constant
•
most instructions can use an optional condition code suffix.
For more information on the instructions and operands, see the instruction descriptions.
Table 3-1 Cortex-M4 instructions
Mnemonic
Operands
Brief description
Flags
Page
ADC, ADCS
{Rd,}
Rn,
Op2
Add with Carry
N,Z,C,V
ADD, ADDS
{Rd,}
Rn, Op2
Add
N,Z,C,V
ADD, ADDW
{Rd,}
Rn, #imm12
Add
-
ADR
Rd, label
Load PC-relative Address
-
AND, ANDS
{Rd,} Rn, Op2
Logical AND
N,Z,C
ASR, ASRS
Rd, Rm, <Rs|#n>
Arithmetic Shift Right
N,Z,C
B
label
Branch
-
BFC
Rd, #lsb, #width
Bit Field Clear
-
BFI
Rd, Rn, #lsb, #width
Bit Field Insert
-
BIC, BICS
{Rd,}
Rn, Op2
Bit Clear
N,Z,C
BKPT
#imm
Breakpoint
-
BL
label
Branch with Link
-
BLX
Rm
Branch indirect with Link
-
BX
Rm
Branch indirect
-
CBNZ
Rn, label
Compare and Branch if Non Zero
-
CBZ
Rn, label
Compare and Branch if Zero
-
CLREX
-
Clear Exclusive
-
CLZ
Rd, Rm
Count Leading Zeros
-
CMN
Rn, Op2
Compare Negative
N,Z,C,V
CMP
Rn, Op2
Compare
N,Z,C,V
CPSID
i
Change Processor State, Disable Interrupts
-
CPSIE
i
Change Processor State, Enable Interrupts
-