mbtrace - 2022.2 English

Vitis Unified Software Platform Documentation: Embedded Software Development (UG1400)

Document ID
UG1400
Release Date
2023-01-02
Version
2022.2 English

Configure and run MB trace.

Syntax

mbtrace [options]

Configure and run MB program and event trace for tracing the application running on MB. The output is the disassembly of the executed program.

Options

Option Description
-start Enable and start trace. After starting trace the execution of the program is captured for later output.
-stop Stop and output trace.
-con Output trace after resuming execution of active target until a breakpoint is hit. At least one breakpoint or watchpoint must be set to use this option. This option is only available with embedded trace.
-stp Output trace after resuming execution of the active target until control reaches instruction that belongs to different line of source code.
-nxt Output trace after resuming execution of the active target until control reaches instruction that belongs to a different line of source code, but runs any functions called at full speed.
-out <filename> Output trace data to a file. <filename> Name of the output file for writing the trace data. If not specified, data is output to standard output.
-level <level> Set the trace level to "full", "flow", "event", or "cycles". If not specified, "flow" is used.
-halt Set to halt program execution when the trace buffer is full. If not specified, trace is stopped but program execution continues.
-save Set to enable capture of load and get instruction new data value.
-low <addr> Set low address of the external trace buffer address range. The address range must indicate an unused accessible memory space. Only used with external trace.
-high <addr> Set high address of the external trace buffer address range. The address range must indicate an unused accessible memory space. Only used with external trace.
-format <format> Set external trace data format to "mdm", "ftm", or "tpiu". If format is not specified, "mdm" is used. The "ftm" and "tpiu" formats are output by Zynq-7000 PS. Only used with external trace.

Returns

Depends on options used. -start, -out, -level, -halt -save, -low, -high, -format Returns nothing on successful configuration. Error string, in case of error.

-stop, -con, -stp, -nxt: Returns nothing, and outputs trace data to a file or standard output. Error string, in case of error.

Examples

mbtrace -start

Enable and start trace.

mbtrace -start -level full -halt

Enable and start trace, configuring to save complete trace instead of only program flow and to halt execution when trace buffer is full.

mbtrace -stop

Stop trace and output data to standard output.

mbtrace -stop -out trace.out

Stop trace and output data to trace.out.

mbtrace -con -out trace.out

Continue execution and output data to trace.out.