Programmer’s Model
2-16
Copyright © 2001, 2004 ARM Limited. All rights reserved.
ARM DDI 0210C
2.8
Exceptions
Exceptions arise whenever the normal flow of a program has to be halted temporarily,
for example, to service an interrupt from a peripheral. Before attempting to handle an
exception, the ARM7TDMI processor preserves the current processor state so that the
original program can resume when the handler routine has finished.
If two or more exceptions arise simultaneously, the exceptions are dealt with in the fixed
order given in Table 2-3.
This section provides details of the ARM7TDMI processor exception handling:
•
Exception entry and exit summary
•
Entering an exception
on page 2-17
•
Leaving an exception
on page 2-18
•
Fast interrupt request
on page 2-18
•
Interrupt request
on page 2-19
•
Software interrupt instruction
on page 2-21
•
Undefined instruction
on page 2-21
•
Exception vectors
on page 2-21
•
Exception priorities
on page 2-22.
2.8.1
Exception entry and exit summary
Table 2-3 summarizes the pc value preserved in the relevant r14 on exception entry, and
the recommended instruction for exiting the exception handler.
Table 2-3 Exception entry and exit
Exception
or entry
Return instruction
Previous state ARM r14_x
Thumb r14_x
Remarks
BL
MOV PC, R14
PC+4
PC+2
Where PC is the address of the BL, SWI, or
undefined instruction fetch that had the
Prefetch Abort
SWI
MOVS PC, R14_svc
PC+4
PC+2
UDEF
MOVS PC, R14_und
PC+4
PC+2
PABT
SUBS PC, R14_abt, #4
PC+4
PC+4
Содержание ARM7TDMI
Страница 6: ...Contents vi Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 10: ...List of Tables x Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 14: ...List of Figures xiv Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 46: ...Introduction 1 26 Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 120: ...Coprocessor Interface 4 18 Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 142: ...Debug Interface 5 22 Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 276: ...Differences Between Rev 3a and Rev 4 C 6 Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...
Страница 282: ...Glossary Glossary 6 Copyright 2001 2004 ARM Limited All rights reserved ARM DDI 0210C ...