When building the system, it best practice to use the three available build targets described in Build Targets. Each build target is represented in a separate build configuration in the Assistant view. Work through these build configurations in the following order:
- Emulation-SW
- Build for software emulation (
sw_emu
) to confirm the algorithm functionality of both the host program and kernel code working together. - Emulation-HW
- Build for hardware emulation (
hw_emu
) to compile the kernel into a hardware description language (HDL), confirm the correctness of the generated logic, and evaluate its simulated performance. - Hardware
- Perform a system hardware build (
hw
) to implement the application running on the target platform.
Before launching the build command, configure each of these build configurations to ensure it meets your needs. Select the specific build configuration, and click the Settings icon to open the Build Configuration Settings dialog box. For more information on using this dialog box, refer to Vitis Build Configuration Settings.
Beyond the build configuration settings, many of the settings that will affect your application are contained in the Hardware Function, accessed through the Vitis Hardware Function Settings dialog box. It is a good idea to review each of the Settings dialog boxes as discussed in Configuring the Vitis IDE.
From the Assistant view, with the various options of the build configuration
specified, you can start the build process by selecting a build configuration and clicking on
the Build () button. The Vitis core development kit uses a two part build process that generates the FPGA
binary (.xclbin) for the hardware kernels using the
Vitis™
compiler v++
command, and compiles and links the host program code using the g++
compiler.
After the build process is complete, the Assistant view shows the specific build configuration with a green check mark to indicate it has been successfully built, as shown in the following figure. You can open any of the build reports, such as the Compile Summary in the hardware function, or the Link Summary in the binary container. Right-click the report in the Assistant view and select Open in Vitis Analyzer.
With the build complete, you can now run the application in the context provided by the specific build configuration. For instance, exercise a C-model of the host program and FPGA binary working together in the Emulation-SW build, or review the host program and the RTL kernel code in simulation in the Emulation-HW build, or run the application on the target platform in the Hardware build.
To run the application from within the Vitis IDE, select the build configuration, and click the Run button () to launch the default run configuration. You can also right-click the build configuration and use the Run menu to select a specific run configuration, or edit a run configuration as described in Vitis Run and Debug Configuration Settings.