Saved registers, Recovery from eit handler – FUJITSU FR family 32-bit microcontroller instruction manuel CM71-00101-5E User Manual
Page 60
36
CHAPTER 4 RESET AND "EIT" PROCESSING
■
Saved Registers
Except in the case of reset processing, the values of the "PS" and "PC" are saved to the stack as designated
by the "SSP", regardless of the value of the "S" flag in the "CCR". No save operation is used in reset
processing.
Figure 4.2-3 illustrates the saving of the values of the "PC" and "PS" in "EIT" processing.
Figure 4.2-3 Saving "PC" and "PS" Values in "EIT" Processing
■
Recovery from EIT handler
RETI instruction is used for recovery from the EIT handler.
To insure the program execution results after recovery, it is required that all the contents of the CPU
register are saved.
Ensure that the PC and PS values in the stack are not overwritten unless necessary because those values,
saved in the stack at the occurrence of EIT, are recovered from the stack during the recovery sequence
using the RETI instruction. Be sure to set the "S" flag to "0" when the RETI instruction is executed.
Memory
s
p
a
ce
Immedi
a
tely
b
efore interr
u
pt
8
0000000
H
000FFC00
H
SS
P
TBR
12
3
4567
8
H
000C0010
H
PC
P
S
FFFFFFFF
H
00000000
H
7FFFFFF
8
H
7FFFFFFC
H
off
s
et: 00000
3
B
8
H
Interr
u
pt
IL=9
567
8
12
3
4
H
Memory
s
p
a
ce
Immedi
a
tely
a
fter interr
u
pt
000FFC00
H
SS
P
TBR
567
8
12
3
4
H
00090010
H
PC
P
S
FFFFFFFF
H
00000000
H
8
0000000
H
7FFFFFFC
H
7FFFFFF
8
H
off
s
et: 00000
3
B
8
H
567
8
12
3
4
H
12
3
4567
8
H
000C0010
H