This lab uses the same files as the AMD Vitis™ IDE flow, but all the operations are completed within a terminal.
To complete phase 1, change directory:
cd Phase1
.This directory contains a single file, which is a Makefile. Open it in any editor or display it in the terminal using
more
,less
, orcat
. The Makefile contains three stages:kernels
: To build the PL kernels. The output is a number of XO files, which are packaged RTL kernels.aie
: To build the AI Engine graph. The output is the filelibadf.a
, which is the compiled graph with all the PL/AI Engine interfaces.link
: To link the AI Engine array design with the PL design. This stage creates the XCLBIN and the XSA files.
There are also optional stages to simulate the AI Engine application using the aiesim
target and run_emu
to launch hardware emulation that includes all the PL kernels.
In the terminal, type make clean phase1
and all the required stages (kernels
, aie
, and link
) will be run in the terminal as well as hardware emulation (package
and run_emu
).
Check the placement of the AI Engine kernels using Vitis Analyzer and opening the graph.aiecompile_summary
file.
Note: The hardware emulation does not launch automatically. You have to launch it manually:
cd /run/media/mmcblk0p1
./host.exe a.xclbin
At the end of the simulation the following message is displayed:
mm2s (DataIn1) completed with status(4)
[59672.228524] zocl-drm axi:zyxclmm_drm: ffff0008003cd410 kds_del_context: Client pid(2424) del context CU(0x1)
polar_clip completed with status(4)
[59672.230697] zocl-drm axi:zyxclmm_drm: ffff0008003cd410 kds_del_context: Client pid(2424) del context CU(0x2)
s2mm (DataOut1) completed with status(4)
[59674.351664] zocl-drm axi:zyxclmm_drm: ffff0008003cd410 kds_del_context: Client pid(2424) del context CU(0xffffffff)
[59674.353188] zocl-drm axi:zyxclmm_drm: ffff0008003cd410 kds_del_context: Client pid(2424) del context CU(0x0)
TEST PASSED
Releasing remaining XRT objects...
[59674.355157] [drm] bitstream 8ae06494-3226-bda4-94c7-906e136725ad unlocked, ref=0
[59674.452197] zocl-drm axi:zyxclmm_drm: zocl_destroy_client: client exits pid(2424)
root@versal-rootfs-common-20232:/run/media/mmcblk0p1#
You can get out of QEMU by hitting Ctrl + a x.