Step 7.1.4 Enable GDB to Work with x86simulator - 2022.2 English

Vitis Tutorials: AI Engine Development

Document ID
Release Date
2022.2 English

Update the configuration file, ${PROJECT_PATH}/Emulation-SW/Work/options/x86sim.options, change gdb=no to gdb=yes then launch x86simulator. Or issue command x86simulator --gdb to launch x86simulator. By default, when running the x86simulator with the --gdb command line switch it breaks immediately before entering main() in graph.cpp. This pauses execution before any AI Engine kernels have started because the graph has not been run. To exit GDB type quit or help for more commands.

Launch x86simulator with gdb, issue command x86simulator --gdb.

After x86simulator is launched successfully with gdb, set up a breakpoint by break command.

Continue execution until a breakpoint is hit. Examine local variables and/or call stack.

Clear all breakpoints and continue execution until end of program. Issue quit to exit out of gdb.