Debug Support
PowerPC e500 Core Family Reference Manual, Rev. 1
Freescale Semiconductor
8-11
If MSR[DE] is cleared, DBSR[IDE] is set to capture the imprecise debug event. However, if DE
is set, a DAC debug exception causes the following events:
•
A debug interrupt is taken immediately (if no higher priority exception has caused an
interrupt).
•
Execution of the instruction causing the exception is suppressed.
•
CSRR0 is loaded with the address of the excepting instruction.
Depending on the type of instruction and the alignment of the access, the instruction causing the
exception may have been partially executed (see
Section 5.9, “Partially Executed Instructions
”).
If debug interrupts are disabled when a DAC debug exception occurs, no interrupt is taken and the
instruction completes normally (provided the instruction is not causing some other exception that
generates an enabled interrupt). Also, DBSR[IDE] is set to indicate that the exception occurred
while debug interrupts were disabled.
Later, if MSR[DE] is set and the debug exception has not been reset by clearing the appropriate
DBSR bit (DAC1R, DAC1W, DAC2R, or DAC2W), a delayed debug interrupt occurs. In this
case, CSRR0 contains the address of the instruction following the instruction that enabled the
debug interrupt. The debug interrupt handler can observe DBSR[IDE] to determine how to
interpret the CSRR0 value.
8.4.3
Trap Debug Event
A trap debug event occurs if DBCR0[TRAP] is set (trap debug events are enabled) and a trap
instruction (tw or twi) is executed and the trap conditions specified by the instruction are met. The
event can occur regardless of the values of MSR[DE] or DBCR0[IDM].
When a trap debug event occurs, DBSR[TRAP] is set to capture the debug exception. If MSR[DE]
is cleared, DBSR[IDE] is also set to record the imprecise debug event.
If MSR[DE] is set at the time of the trap debug exception, a debug interrupt occurs immediately
(if no higher priority exception has caused an interrupt), and CSRR0 is set to the address of the
excepting instruction.
If debug interrupts are disabled at the time of the exception, no interrupt is taken and a trap
exception type program interrupt occurs.
Later, if MSR[DE] is set, and the debug exception has not been reset by clearing DBSR[TRAP],
a delayed debug interrupt occurs. In this case, CSRR0 contains the address of the instruction
following the one that enabled the debug interrupt (by setting MSR[DE]). The debug interrupt
handler can observe DBSR[IDE] to determine how to interpret the CSRR0 value.
Summary of Contents for PowerPC e500 Core
Page 1: ...PowerPC e500 Core Family Reference Manual Supports e500v1 e500v2 E500CORERM Rev 1 4 2005...
Page 36: ...PowerPC e500 Core Family Reference Manual Rev 1 xxxvi Freescale Semiconductor...
Page 38: ...PowerPC e500 Core Family Reference Manual Rev 1 Part I 2 Freescale Semiconductor...
Page 332: ...PowerPC e500 Core Family Reference Manual Rev 1 Part II 2 Freescale Semiconductor...
Page 530: ...Opcode Listings PowerPC e500 Core Family Reference Manual Rev 1 D 50 Freescale Semiconductor...
Page 534: ...PowerPC e500 Core Family Reference Manual Rev 1 E 4 Freescale Semiconductor Revision History...