Visible to Intel only — GUID: cgy1522340402284
Ixiasoft
1. About this Document
2. Setting Up the Host Machine
3. Running Diagnostics
4. OpenCL* Support for Multi-Card Systems
5. Running Samples
6. Compiling OpenCL* Kernels
7. Intel® PAC with Intel® Arria® 10 GX FPGA Security for OpenCL* Applications
8. OpenCL* on the Intel® PAC with Intel® Arria® 10 GX FPGA Quick Start User Guide Archives
9. Document Revision History for OpenCL* Quick Start User Guide Intel® Programmable Acceleration Card with Intel® Arria® 10 GX FPGA
Visible to Intel only — GUID: cgy1522340402284
Ixiasoft
6. Compiling OpenCL* Kernels
Before compiling an OpenCL* kernel, you must install the Intel® Acceleration Stack for Development.
- Set the user environment variable using one of the following commands:
source <DEV Install Path>/init_env.sh
- Ensure that the environment is setup with correct BSP using the following command:
aoc -list-boards
Example sample output:Board list: pac_a10 Board Package: /home/username/inteldevstack/opencl_bsp
Board list: pac_s10_dc Board Package: /tools/<username>/dcp_2_0_1_PV_RC2/inteldevstack/d5005_ias_2_0_1_b237/opencl/opencl_bspBoard list:
- Compile an OpenCL Kernel to an aocx using commands similar to the following:
cd $OPAE_PLATFROM_ROOT/opencl/exm_opencl_vector_add_x64_linux/vector_add aoc device/vector_add.cl -o bin/vector_add.aocx -board pac_a10
cd $OPAE_PLATFROM_ROOT/opencl/vector_add aoc device/vector_add.cl -o bin/vector_add.aocx -board pac_s10_dc
- The security features of the Intel® PAC with Intel® Arria® 10 GX FPGA requires the signing of metadata in a bitstream even if you don't intend to use the security features of the card. If you try to program the aocx file as is generated after the compilation in the above step, the PACSign tool gives the following error message:
$ aocl program acl0 hello_world.aocx aocl program: Running program from /home/DCPsupport/inteldevstack_1_2_1_pv/a10_gx_pac_ias_1_2_1_pv/opencl/opencl_bsp/linux64/libexec libopae-c reconf.c:427:fpgaReconfigureSlot() **ERROR** : Failed to reconfigure bitstream: Input/output error libopae-c reconf.c:450:fpgaReconfigureSlot() **ERROR** : PR incompatible bitstream error detected Error writing bitstream to FPGA: reconfiguration error Error programming device aocl program: Program failed
- If you are in the development process or have a new Intel® PAC with Intel® Arria® 10 GX FPGA card with no root entry hash programmed to it, follow the instructions from this section Example: Creating an Unsigned .aocx File Using OpenSSL Manager to create an unsigned aocx file with only signing metadata.
- If you have Intel® PAC with Intel® Arria® 10 GX FPGA with the root entry hash programmed, follow the steps from section Creating the OpenCL Bitstream to create signed aocx file with your preferred method.
- After you follow the steps above, depending on the condition of your Intel® PAC with Intel® Arria® 10 GX FPGA, you should be able to successfully program the signed or unsigned aocx file by using the following command:
aocl program acl0 <unsigned_file.aocx>