Toshiba TX39 user manual Shows how the RFE instruction works

Models: TX39

1 246
Download 246 pages 24.89 Kb
Page 69
Image 69

Architecture

After an exception handler has executed to perform exception processing, it must issue an RFE (Restore From Exception) instruction to restore the system to its previous status.

The RFE instruction returns control to processing that was in progress when the exception occurred. When a RFE instruction is executed, the previous interrupt enabled bit (IEp) and previous operating mode bit (KUp) in the Status register are copied to the corresponding current bits (IEc and KUc).

The old mode bits (IEo and KUo) are copied to the corresponding previous mode bits (IEp and KUp). The old mode bits (IEo and KUo) retain their current values.

Likewise, the previous data cache auto-lock mode bit (DALp) and previous instruction cache auto- lock mode bit (IALp) in the Cache register are copied to the corresponding current bits (DALc and IALc). The old mode bits (DALo and IALo) are copied to the corresponding previous mode bits (DALp and IALp). The old mode bits (DALo and IALo) retain their current values.

Figure 6-7 shows how the RFE instruction works.

KUo IEo KUp IEp

KUc IEc

RFE instruction issued

KUo IEo KUp IEp

KUc IEc

(a) Status register

0

0 0

IAL

o

DAL

o

IAL

p

DAL IAL

p c

DAL

c

0 0

0

0

0

0

0

0

RFE instruction issued

0 0

IAL DAL

o

o

IAL DAL IAL

p

p

c

DAL

c

0 0

0

0

0

0

0

0

(b) Cache register

Figure 6-7. Status register and cache register when an RFE instruction is issued

60

Page 69
Image 69
Toshiba TX39 user manual Shows how the RFE instruction works