Intel® FPGA SDK for OpenCL™ Pro Edition: Programming Guide

ID 683846
Date 3/28/2022

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

2. Intel® FPGA SDK for OpenCL™ Offline Compiler Kernel Compilation Flows

The Intel® FPGA SDK for OpenCL™ Offline Compiler can create your FPGA programming image file (.aocx file) in a single or multistep process. The complexity of your kernels dictates the preferred compilation.
Figure 3. The Intel® FPGA SDK for OpenCL™ FPGA Programming Flow

An OpenCL kernel source file (.cl) contains your OpenCL kernel source code that runs on the FPGA. The offline compiler groups one or more kernels into a temporary file and then compiles this file to generate the following files and folders:

  • A .aoco object file is an intermediate object file that contains information for later stages of the compilation. It is not presented unless the aoc option -save-temps is specified.
  • A.aocx image file is the hardware configuration file and contains information necessary to program the FPGA at runtime.
  • The work folder or subdirectory, which contains data necessary to create the .aocx file. By default, the name of the work directory is the name of your .cl file. If you compile multiple kernel source files, the name of the work directory is the name of the last .cl file you list in the aoc command line.

The .aocx file contains data that the host application uses to create program objects, a concept within the OpenCL runtime API, for the target FPGA. The host application first loads these program objects into memory. Then the host runtime uses these program objects to program the target FPGA, as required for kernel launch operations by the host program.