The techniques of programming, simulating, and synthesizing the PL kernel
objects are described in the
Vitis High-Level Synthesis User Guide (UG1399). The kernel
object file (.xo) can be compiled by the HLS
compiler (v++ -c --mode hls
) as described below. The
compiled object file can be linked with the AI Engine graph application, and the target platform, and used
with the v++ --link
command as described in Linking the System.
-c
) and linked (-l
) in
two separate steps. v++ -c --mode hls --config ./src/hls_config.cfg --work_dir vadd
The various arguments used are described below:
-
-c
: Specifies the compilation mode of thev++
command. This can be specified using-c
or--compile
-
--mode hls
: Launches the HLS compiler form of the Vitis compiler -
--config <config_filename>
: Specify a Configuration file for use with the HLS compiler. The configuration file has HLS compiler options as described in v++ Mode HLS. Refer to Creating an HLS Component in the Vitis High-Level Synthesis User Guide (UG1399) for additional details. The Configuration file will specify:- The target platform or part for the build. The platform
specified in the
v++ --link
command must match the target platform or part used for the HLS compile command - The source C++ file or files for the PL kernel
- The Configuration file will also specify an output name if one is needed. The default output name is the same as the top-level function with the .xo extension
- The target platform or part for the build. The platform
specified in the
-
--work_dir
: Specifies the location of the HLS component created by thev++
compiler
Refer to Output Directories of the v++ Command to get an understanding of the location of various output files generated by the HLS compiler.
After the compilation step is complete, any reports generated during this process are collected into the <kernel_name>.compile_summary. This collection of reports can be viewed by opening the compile_summary in the Analysis view of Vitis unified IDE, and includes a Summary report, Kernel Estimate for timing and resource estimates, Kernel Guidance offering any suggestions for compilation, and the HLS Synthesis log. Refer to Working with the Analysis View (Vitis Analyzer) for additional information.