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

ID 683846
Date 12/19/2022
Public
Document Table of Contents

11.3.1. Hardware for Kernel Interface

The Intel® FPGA SDK for OpenCL™ Offline Compiler generates hardware around the kernel pipeline. For some OpenCL™ applications, these interface hardware components are not necessary.

Hardware around the kernel pipeline is necessary for functions such as the following:

  • Dispatching IDs for work-items and work-groups
  • Communicating with the host regarding kernel arguments and work-group sizes

Intel® FPGA SDK for OpenCL™ Offline Compiler-Generated Interface Hardware around a Kernel Pipeline illustrates the hardware that the offline compiler generates when it compiles the following kernel:

__kernel void my_kernel(global int* arg)
{
    …
    int sum = 0;
    for(unsigned i = 0; i < n; i++)
    {
        if(sum < m) sum += val;
    }
    *arg = sum;
    …
}
Figure 34.  Intel® FPGA SDK for OpenCL™ Offline Compiler-Generated Interface Hardware around a Kernel Pipeline