Visible to Intel only — GUID: ewa1401454091673
Ixiasoft
Visible to Intel only — GUID: ewa1401454091673
Ixiasoft
3.9. Creating the Hardware Configuration File of an OpenCL Kernel for SoC FPGA
After you successfully install your FPGA board, you can create a .aocx file that executes on the device. Cyclone V SoC Development Kit Programming Overview outlines the procedure for programming the hello_world design example onto the Cyclone® V SoC FPGA. For more information about the OpenCL design examples, refer to the OpenCL Design Examples page.
- Verify that you set the environment variable AOCL_BOARD_PACKAGE_ROOT to point to the Cyclone V SoC Development Kit Reference Platform (that is, INTELFPGAOCLSDKROOT/board/c5soc).
The init_opencl script you ran when installing the Cyclone V SoC Development Kit should have set the AOCL_BOARD_PACKAGE_ROOT environment variable. If the returned path does not include INTELFPGAOCLSDKROOT/board/c5soc, modify the AOCL_BOARD_PACKAGE_ROOT setting.
- Verify that you set the environment variable QUARTUS_ROOTDIR_OVERRIDE to point to the installation directory of the correct Intel® Quartus® Prime Standard Edition software.
- At a command prompt, navigate to the hello_world design.
- To list the SoC FPGA boards available in the Cyclone V SoC Development Kit Reference Platform, invoke the aoc -list-boards command.
You should see an output similar to the one below:
Board list: c5soc c5soc_sharedonly
- To compile the kernel for your Cyclone V SoC Development Kit, invoke the following command:
aoc -board=c5soc device/hello_world.cl -o=bin/hello_world.aocxThis command performs the following tasks:
- Generates the Intel® Quartus® Prime design project files from the OpenCL source code.
- Checks for initial syntax errors.
- Performs basic optimizations.
- Creates a hello_world subfolder or subdirectory containing necessary intermediate files.
- Creates the .aoco object file.
- Creates the .aocx hardware configuration file and saves it in the bin subfolder or subdirectory.
Attention:The .aocx file might take hours to build, depending on the complexity of the kernel. To view the progress of the compilation on-screen, include the -v flag in your aoc command (that is, aoc -v <your_kernel_filename>.cl).
The offline compiler displays the line aoc: Hardware generation completed successfully. to signify the completion of the compilation process.
For more information about the -list-boards, -board=<board_name> , -v, and -o=<filename> options of the aoc command, refer to the Intel FPGA SDK for OpenCL Standard Edition Programming Guide.