Section 2: Simulate the AI Engine Graph using the x86simulator - 2023.2 English

Vitis Tutorials: AI Engine (XD100)

Document ID
XD100
Release Date
2024-03-05
Version
2023.2 English

After the graph has been compiled, you can simulate your design with the x86simulator command. The x86 simulator is an ideal choice for testing, debugging, and verifying behavior because of the speed of iteration and the high level of data visibility it provides the developer. The x86 simulation does not provide timing, resource, or performance information.

  1. To run simulation run the command:

     make sim
    

    Or

    x86simulator --pkg-dir=./Work
    
| Flag | Description |
| ---- | ----------- |
| --pkg-dir | The ***Work*** directory. |
  1. When the simulation is completed, navigate to the x86simulator_output directory from a terminal and run: cd x86simulator_output; ls

    You should see something similar to the following:

     data/  x86sim.aierun_summary  x86simulator.log
    

    As you can see, a variety of files in the data directory are generated with the output file(s) you have in the graph.cpp for the PLIO objects and the x86sim.aierun_summary is generated, which contains all the information generated by x86simulator.

Vitis Analyzer

  1. Open the generated x86sim.aierun_summary from the x86simulator_output directory for Vitis Analyzer. To do this, run the command:

    vitis_analyzer x86simulator_output/x86sim.aierun_summary
    

This opens the summary view in Vitis Analyzer that displays the simulation run time and the exact command line used for simulation.

Vitis Analyzer Summary

Note: As the x86 simulation runs the design at a functional level, kernels do not physically map and route on the AI engine array. Therefore, the Array view is not available in aierun summary.