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

ID 683342
Date 4/22/2019
Public
Document Table of Contents

12.2.1. Restrictions on the Usage of Variable-Specific Attributes

The Intel® FPGA SDK for OpenCL™ Offline Compiler will error out or issue warnings if it detects unsupported usages of the variable-specific attributes or incorrect memory configurations.

Unsupported usages of variable-specific attributes that cause compilation errors:

  • You use the kernel attributes in declarations other than local or private variable declarations (for example, declarations for function parameters, global variable declarations, or function declarations).
  • You use the register attribute in conjunction with any of the other variable-specific attributes.
  • You specify the numbanks attribute but not the bankwidth attribute in the same variable declaration, or vice versa.
  • You include both the singlepump and doublepump attributes in the same variable declaration.
  • You specify the numreadports and numwriteports attributes without also including the singlepump or doublepump attribute in the same variable declaration.
  • You specify the numreadports attribute but not the numwriteports attribute in the same variable declaration, or vice versa.
  • You specify any of the following attributes without also specifying the numbanks and bankwidth attributes in the same variable declaration:
    • numreadports
    • numwriteports
    • singlepump
    • doublepump

Incorrect memory configurations that cause the offline compiler to issue warnings during compilation:

  • The memory configuration that is defined by the variable-specific attributes exceeds the available storage size (for example, specifying eight banks of local memory for an integer variable).

Incorrect memory configurations that cause compilation errors:

  • The bank width is smaller than the data storage size (for example, bank width is 2 bytes for an array of 4-byte integers).
  • You specify memory configurations for the variables. However, because of compiler restrictions or coding style, the offline compiler implements the variables in the same memory instead of splitting the memory.
  • You specify the register attribute for a variable. However, because of compiler restrictions or coding style, the offline compiler cannot implement the variable in a register.