Intel 80200 Computer Hardware User Manual


 
13-32 March, 2003 Developers Manual
Intel
®
80200 Processor based on Intel
®
XScale
Microarchitecture
Software Debug
13.13.2 Trace Buffer Usage
The Intel
®
80200 processor trace buffer is 256 bytes in length. The first byte read from the buffer
represents the oldest trace history information in the buffer. The last (256th) byte read represents
the most recent entry in the buffer. The last byte read from the buffer is always a message byte.
This provides the debugger with a starting point for parsing the entries out of the buffer. Because
the debugger needs the last byte as a starting point when parsing the buffer, the entire trace buffer
must be read (256 bytes on the Intel
®
80200 processor) before the buffer can be parsed.
Figure 13-9 is a high level view of the trace buffer.
The trace buffer must be initialized prior to its initial usage, then again prior to each subsequent
usage. Initialization is done be reading the entire trace buffer. The process of reading the trace
buffer also clears it out (all entries are set to 0b0000 0000), so when the trace buffer has been used
to capture a trace, the process of reading the captured trace data also re-initializes the trace buffer
for its next usage.
The trace buffer can be used to capture a trace up to a processor reset. A processor reset disables
the trace buffer, but the contents are unaffected. The trace buffer captures a trace up to the
processor reset.
The trace buffer does not capture reset events or debug exceptions.
Since the trace buffer is cleared out before it is used, all entries are initially 0b0000 0000. In
fill-once mode, these 0’s can be used to identify the first valid entry in the trace buffer. In wrap
around mode, in addition to identifying the first valid entry, these 0 entries can be used to
determine whether a wrap around occurred.
Figure 13-9. High Level View of Trace Buffer
target[7:0]
1001 CCCC (indirect)
1000 CCCC (direct)
1100 CCCC (direct)
. . .
1111 1111 (roll-over)
target[31:24]
target[23:16]
target[15:8]
target[7:0]
1101 CCCC (indirect)
1000 CCCC (direct)
1111 1111 (roll-over)
1000 CCCC (direct)
last byte read
(most recent entry)
first byte read
(oldest entry)
CHKPT1
CHKPT0