The Vitis Unified IDE provides Processing System (PS) Trace support for debug analysis. PS Trace records processor execution flow so you can inspect runtime behavior that is difficult to observe by using breakpoints and stepping alone.
PS Trace captures execution data in a defined trace window during a debug session. You can use the captured trace to investigate control flow, analyze runtime behavior, and support root-cause analysis.
PS Trace supports multiple capture modes, including on-chip and off-chip trace, based on target and release support.
OpenCSD Setup
Vitis Unified IDE uses OpenCSD to decode trace data for display in trace analysis views. If your environment requires an explicit OpenCSD path, configure it in IDE settings before running PS Trace.
To configure OpenCSD:
- Install OpenCSD on your system using your preferred method supported by your environment.
- Launch the Vitis Unified IDE.
- Open Settings.
- Specify the OpenCSD installation path.
- Save the settings.
Performing PS Trace
To run PS Trace:
- Create or open a debug launch configuration for your application.
- Enable PS Trace in launch configuration options.
- Configure trace memory and output settings as needed.
- Start the debug session.
PS Trace capture uses a ring buffer. The buffer size determines how much execution history is retained. When capture exceeds buffer capacity, newer data replaces older data.
Defining the Trace Window
PS Trace capture commonly uses trace start and trace stop breakpoints to define the region of code to trace. Place a trace start breakpoint at the point where you want trace capture to begin and a trace stop breakpoint at the point where trace capture should end.
When execution reaches the trace start breakpoint, capture begins. When execution reaches the trace stop breakpoint, capture ends and trace processing starts.
Analyzing PS Trace Data
After capture and processing complete:
- Open the generated trace summary file in Vitis Unified IDE.
- Use the Trace File view to inspect decoded execution and control flow.
- Configure source path mapping if needed so traced instructions resolve to local source files.
- Navigate trace output to diagnose issues and analyze behavior.
PS Trace and Debug Session Behavior
PS Trace augments standard debug workflows. Breakpoints and stepping remain available while PS Trace is enabled. PS Trace settings apply to the active debug session.