![](http://datasheet.mmic.net.cn/230000/79RC32438-200BB_datasheet_15568909/79RC32438-200BB_496.png)
IDT EJTAG System
Debug Control Register
79RC32438 User Reference Manual
20 - 30
November 4, 2002
Notes
Table 20.17 DEPC Register Field Description
Debug Exception Save Register (CP0 Register 31, Select 0)
The Debug Exception Save (DESAVE) register is a read/write register that functions as a simple
scratchpad register. The size of this register is 32 bits for 32-bit processors and 64 bits for 64-bit processor.
The debug exception handler uses this to save one of the GPRs, which is then used to save the rest of
the context to a pre-determined memory area, for example, in the dmseg. This register allows the safe
debugging of exception handlers and other types of code where the existence of a valid stack for context
saving cannot be assumed.
Figure 2-4 shows the format of the DESAVE register; Table 2-13 describes the DESAVE register field.
Figure 20.5 DESAVE Register Format
Debug Control Register
The Debug Control Register (DCR) controls and provides information about debug issues. The width of
the register is 32 bits for 32-bit processors, and 64 bits for 64-bit processors. The DCR is located in the
drseg at offset 0x0000. The Debug Control Register (DCR) provides the following key features:
Interrupt and NMI control when in Non-Debug Mode
NMI pending indication
Availability indicator of instruction and data hardware breakpoints.
For EJTAG features, there are no difference between a reset and a soft reset occurring to the processor;
they behave identically in both Debug Mode and Non-Debug Mode. References to reset in the following
therefore refers to both reset (hard reset) and soft reset. The DataBrk and InstBrk bits within the DCR indi-
cate the types of hardware breakpoints implemented. Debug software is expected to read hardware break-
point registers for additional information on the number of implemented breakpoints. Refer to section
“Hardware Breakpoints” on page 20-32 for a description of the hardware breakpoint registers.
Hardware and software interrupts can be disabled in Non-Debug Mode using the DCR’s IntE bit. This bit
is a global interrupt enable used along with several other interrupt enables that enable specific mecha-
nisms. The NMI interrupt can be disabled in Non-Debug Mode using the DCR’s NMIE bit; a pending NMI is
indicated through the NMIpend bit. Pending interrupts are indicated in the Cause register, and pending
Fields
Description
Read/
Write
Reset
State
Compli-
ance
Name
Bits
DEPC
MSB:0
Debug Exception Program Counter
R/W
Undefined
Required
31
0
DESAVE
Fields
Description
Read/
Write
Reset
State
Compli-
ance
Name
Bits
DESAVE
MSB:0
Debug Exception Save contents
R/W
Undefined
Required
Table 20.18 DESAVE Register Field Description