EasyManuals Logo

ARM Cortex-M3 User Manual

ARM Cortex-M3
410 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #107 background imageLoading...
Page #107 background image
Exceptions
ARM DDI 0337G Copyright © 2005-2008 ARM Limited. All rights reserved. 5-11
Unrestricted Access Non-Confidential
5.5 Pre-emption
The following sections describe the behavior of the processor when it takes an
exception:
Stacking
Late-arriving on page 5-15
Tail-chaining on page 5-14.
5.5.1 Stacking
When the processor invokes an exception, it automatically stores the following eight
registers to the SP in the following order:
Program Counter (PC)
Processor Status Register (xPSR)
•r0-r3
•r12
Link Register (LR).
The SP is decremented by eight words by the completion of the stack push. Figure 5-1
shows the contents of the stack after an exception pre-empts the current program flow.
Figure 5-1 Stack contents after pre-emption
Note
Figure 5-1 shows the order on the stack.
If STKALIGN is set in the Configuration Control Register then an extra word can
be inserted before the stacking takes place. See Configuration Control Register on
page 8-26.
After returning from the ISR, the processor automatically pops the eight registers from
the stack. Interrupt return is passed as a data field in the LR, so ISR functions can be
normal C/C++ functions, and do not require a veneer.
Old SP
SP
xPSR
PC
LR
r12
r3
r2
r1
r0
<previous>

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the ARM Cortex-M3 and is the answer not in the manual?

ARM Cortex-M3 Specifications

General IconGeneral
ArchitectureARMv7-M
Instruction SetThumb-2
Pipeline Stages3-stage
InterruptsNested Vectored Interrupt Controller (NVIC)
Interrupt ControllerNested Vectored Interrupt Controller (NVIC)
Memory Protection UnitOptional
Power ConsumptionVaries by implementation
Max Clock SpeedUp to 100 MHz
DebuggingJTAG and Serial Wire Debug (SWD)
Operating Voltage1.8V to 3.6V
Manufacturing ProcessVaries by implementation
Core Type32-bit

Related product manuals