User guide
GUI Reference
Trace View (Debug Perspective)
You open this view from the Debug perspective by pointing to Show View on the Window
menu, and then clicking Trace.
The Nios II IDE Trace view displays a disassembly trace of the instructions executed prior to
the current breakpoint or watchpoint, and optionally displays load/store addresses and the
associated data. The Trace view allows you to analyze execution details that are not available
in the source disassembly listing, such as branches taken at runtime, and precisely when
exceptions occurred.
The Trace view is only available in the Debug perspective, and does not automatically display
as part of the Debug perspective. The Trace view only functions when debugging Nios II
hardware targets. If the hardware does not support trace, then the Trace view does not
function. The JTAG debug module on the target processor must be configured to support trace
collection.
During a debug session, the Trace view automatically displays trace data whenever processor
execution suspends. The most recently executed instruction displays at the bottom of the
view.
The Trace view displays the following information:
Address of the instruction in hex
C/C++ function containing the suspended instruction, plus a (hex) offset
The instruction word in hex
Disassembly of the instruction word
Load and/or store addresses, and associated data (depending on trace preferences)
Ellipses in the disassembly indicate that the JTAG debug module might have dropped some
instructions while collecting trace data. The trace might not be reliable at that point. The
following disassembly is an example.
0x01000068 <foo+0x24>: 0xdec00204 addi sp, sp, 8
...
0x0100006c <foo+0x28>: 0xf800283a ret
Note: FS/2 must be disabled in the Debug dialog box in order for native trace to work.
Related Nios II IDE Help Topics
Viewing Execution Trace
Trace Page (Preferences Dialog Box)
Related Topics on the Web
Nios II Processor Reference Handbook at
www.altera.com/literature/hb/nios2/n2cpu_nii5v1.pdf—Contains details on the JTAG
debug module on the Nios II processor.
149