Intel® High Level Synthesis Compiler Pro Edition: Reference Manual

ID 683349
Date 9/23/2022
Public

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

Document Table of Contents

8.3. Declaring ac_complex Data Types

The HLS compiler package includes an ac_complex.h header file for complex number support.
  1. Include the ac_complex.h header file in your component in the following manner:
    #ifdef __INTELFPGA_COMPILER__ 
    #include "HLS/ac_complex.h" 
    #else 
    #include "ref/ac_complex.h" 
    #endif
  2. After you include the header file, declare your ac_complex variables according to the data type of your complex number.

    The underlying data type can be ac_int, ac_fixed, hls_float, and standard C integer or floating-point data types.

For a list of supported operators and their return types, see "4. Complex Datatype" in Mentor Graphics Algorithmic C (AC) Datatypes, which is available in the following file: <quartus_installdir>/hls/include/ref/ac_datatypes_ref.pdf.