The document discusses the ARM and Thumb instruction sets used in embedded systems. It explains that Thumb encodes ARM instructions into a smaller 16-bit format, allowing higher performance on 16-bit systems but lower on 32-bit. It also describes how the processor state determines whether ARM or Thumb instructions can be executed, and how branch instructions like BX and BLX are used to switch states. Finally, it provides an overview of different instruction types like data processing, logical operations, and conditional instructions supported by the ARM and Thumb instruction sets.
The document discusses the ARM and Thumb instruction sets used in embedded systems. It explains that Thumb encodes ARM instructions into a smaller 16-bit format, allowing higher performance on 16-bit systems but lower on 32-bit. It also describes how the processor state determines whether ARM or Thumb instructions can be executed, and how branch instructions like BX and BLX are used to switch states. Finally, it provides an overview of different instruction types like data processing, logical operations, and conditional instructions supported by the ARM and Thumb instruction sets.
The document discusses the ARM and Thumb instruction sets used in embedded systems. It explains that Thumb encodes ARM instructions into a smaller 16-bit format, allowing higher performance on 16-bit systems but lower on 32-bit. It also describes how the processor state determines whether ARM or Thumb instructions can be executed, and how branch instructions like BX and BLX are used to switch states. Finally, it provides an overview of different instruction types like data processing, logical operations, and conditional instructions supported by the ARM and Thumb instruction sets.
Quaid -E- Awam University of Engineering, Science and
Technology Nawabshah
# 12
EMBEDDED SYSTEMS
Department of Computer Systems Engineering
Thumb architecture ARM states
• Thumb encodes a subset of the 32-bit ARM
instructions into a 16-bit instruction set space.
• Implements 16-bit instruction on 32-bit architecture
• Thumb has higher performance than ARM on a
processor with a 16-bit data bus, but lower performance than ARM on a 32-bit data bus. ARM states
• A processor in ARM state cannot execute Thumb
instruction, and a processor in Thumb state cannot execute ARM instruction. • Processor never receives instruction of the wrong instruction set for the current state. Thumb register Thumb state
To call a Thumb routine from an ARM routine,
the core has to change state. This state change is shown in theT bit of the cpsr . The BX and BLX branch instructions cause a switch between ARM and Thumb state while branching to a routine. The BX lr instruction returns from a routine, also with a state switch if necessary. Data processing instructions Load /store instructions Load / store instruction Logical instructions Logical instructions Shift Register Shift Register Add/ Subtract Instructions Add / Subtract Instructions Conditional Instructions Conditional Instructions Conditional instructions Unconditional Instruction Allah Hafiz