Planning for AI Engine Debug - 2021.2 English

Versal ACAP System and Solution Planning Methodology Guide (UG1504)

Document ID
UG1504
Release Date
2021-11-19
Version
2021.2 English

Every AI Engine in the AI Engine array has a debug interface, which can be used to read/write to all the individual AI Engine registers. The following files can be read and written over this interface: scalar register files, vector register files, status registers (for overflow, saturation, etc.), special registers like stack pointer, and zero overhead loop registers.

Requests for reading and writing AI Engine registers are sent via the AXI4 memory-mapped (AXI4-MM) interface and are then forwarded to the AI Engine Debug Interface. All the registers in the AI Engine are mapped on the AXI4-MM. The AXI4-MM interface has a 32-bit read/write bus. You can specify any AXI4-MM mapped address to read over the AXI4-MM interface. Any external AXI4-MM master (e.g., PS) can issue a stall signal to a specific AI Engine by writing into the control/status register. There are independent registers for system control (e.g., normal program flow) and the debugger. The Vitis™ System Debugger provides a comprehensive source code debugger that helps debug AI Engine graphs and kernels.

Events are another important feature of AI Engine debug and performance analysis. Events are similar to triggers. An event signal is high in the cycle for which the condition associated with that event is true. Examples of events include Conflict DM bank 0, Lock 11 Released, Floating point Overflow, and PC event 0. Each event has a unique 7-bit number, and there are up to 128 events in each AI Engine. Following are additional details:

Event Actions
can be configured to perform a task whenever a specific event occurs. Examples of event actions include Debug halt core, Single step core, and Increment Performance Counter.
Event Broadcast
can be used to send events signals to a neighboring AI Engine and the PL.
Event Trace Unit
can collect cycle-by-cycle event activity from 8 numbered event signals and send compressed trace information from the AI Engine array via the AXI4-Stream network. The Vitis environment allows you to capture specific events from an AI Engine that can be analyzed in the Vitis Analyzer tool.

For more information, see Debugging the AI Engine Application in the AI Engine User Guide (UG1076).