
ML674001 Series/ML675001 Series User’s Manual
Chapter 2 CPU
2-9
2.10 Instruction Set Features
There are two instruction sets: 32-bit ARM instructions and 16-bit THUMB ones.
2.10.1
ARM Instruction Set
The ARM instruction set contains the following six main instruction types.
Branch instructions
Data processing instructions
Status register transfer instructions
Load/store instructions
Coprocessor instructions
Exception generation instructions
Most data processing instructions and one class of coprocessor instructions sometimes update the four
condition code flags (sign, zero, carry, and overflow) in the current program status (CPSR).
Almost all ARM instructions include a 4-bit condition field. One such code (“Always”) specifies
unconditional execution. The others specify execution only if the corresponding condition is valid at the start
of instruction execution. There is no execution if the condition is not met.
There are 14 such codes for testing the following.
Equality and inequality
Inequality (<, <=, >, or >=) after signed or unsigned arithmetic
Individual condition code flags
2.10.2
THUMB Instruction Set
Each 16-bit THUMB instruction has a corresponding 32-bit ARM instruction with the same effect on the
processor model. The twin design goals here are to boost performance in user applications using a 16 bits
wide (or smaller) memory data bus and to increase code density.
THUMB instructions retain the same 32-bit architecture as ARM instructions--in particular, 32-bit arithmetic
and 32-bit addresses for data access instructions and instruction fetch. They are, however, subject to a few
access limitations. THUMB instructions share the first eight general-purpose registers, R0 to R7, with ARM
instructions. The upper eight, R8 to R15, are generally off limits, but certain THUMB instructions have
access to the program counter (ARM register 15), link register (ARM register 14), and stack pointer (ARM
register 13).
ARM register 15 holds the program counter in bits 31 to 1. Bit 0 returns “0” for reads. Writes to bit 0 are
ignored.
There are no THUMB analogs for the ARM instructions (MSR and MRS) for direct transfers to and from
current program status register (CPSR) and saved program status registers (SPSR).