beautypg.com

6 trace functions – Epson S5U1C62000A User Manual

Page 162

background image

150

EPSON

S5U1C62000A MANUAL

(S1C60/62 FAMILY ASSEMBLER PACKAGE)

CHAPTER 9: DEBUGGER

9.8.6 Trace Functions

The debugger has a function to trace program execution.

Trace memory and trace information

The ICE contains a trace memory. When the program executes instructions in the trace range set by a
command, the trace information on each cycle is taken into this memory. The trace memory has the
capacity to store information for 8,192 cycles, making it possible to trace up to 2,730 instructions (for
five-clock instructions only). When the trace information exceeds this capacity, the data is overwritten,
the oldest data first. Consequently, the trace information stored in the trace memory is always within
8,192 cycles. The trace memory is cleared when a program is executed, starting to trace the new
execution data.

The following lists the trace information that is taken into the trace memory in every cycle. This list is
corresponded to display in the [Trace] window.

Loc:

Trace cycle number (decimal)
The last information taken into the trace memory becomes 0000.

CODE:

Fetched code (hexadecimal) and unassembled content (mnemonic)

PC:

PC address (hexadecimal)

A, B, X, Y:

Values of A, B, X, Y registers (hexadecimal)

IDZC:

Values of I, D, Z and C flags (binary) after cycle execution

MemOP:

Read/write operation (denoted by R or W at the beginning of data), accessed data
memory address (hexadecimal), and data (hexadecimal)

OtherOP:

Interrupt process: INT1 (stack), INT2 (vector fetch)

Trace areas and conditions

Trace areas (address ranges) and a trace condition can be selected using the following commands.

Table 9.8.6.1 Trace area/condition set-up command

Function

Command

Menu

Set trace area

ta

[Trace | Trace Area...]

Set trace condition

tc

[Trace | Trace Condition...]

(1) Trace area

Multiple program address ranges can be specified as the trace areas. The debugger samples trace
information from the set areas only.