Visible to Intel only — GUID: GUID-29AC525F-4345-49CC-A45E-C02D32AFBB88
Visible to Intel only — GUID: GUID-29AC525F-4345-49CC-A45E-C02D32AFBB88
Additional Data Types Provided by the ap_float.hpp Header File
The ap_float.hpp header file provides some aliases for certain data types that you can use instead of explicitly declaring an ap_float data type.
Data Type | Description |
---|---|
ihc::bfloat16 | A 16-bit floating-point number with an 8-bit exponent and a 7-bit mantissa (equivalent to declaring ihc::ap_float<8, 7>). On Agilex™ 7devices, dot product operations that involve the bfloat16 (or ihc::ap_float<8,7>) data type are mapped to FP16 DSPs. On other device families, dot product operations are mapped to ALMs and fixed-point 18-bit DSPs. On all device families, all other math functions are mapped to ALMs and fixed-point 18-bit DSPs. |
ihc::bfloat19 | A 19-bit floating-point number with an 8-bit exponent and a 10-bit mantissa (equivalent to declaring ihc::ap_float<8,10>). On Agilex™ 7devices, dot product operations that involve the bfloat19 (or ihc::ap_float<8,10>) data type are mapped to FP19 DSPs. On other device families, dot product operations are mapped to ALMs and fixed-point 18-bit DSPs. On all device families, all other math functions are mapped to ALMs and fixed-point 18-bit DSPs. |
ihc::FPsingle | A 32-bit floating-point number with an 8-bit exponent, a 23-bit mantissa, and a "Round to the nearest, tie break to even" rounding mode (equivalent to declaring ihc::ap_float<8, 23, fp_config::FP_Round::RNE>). Math operations with FPsingle map to the same hardware as the native float data type when the native float data type uses IEEE-754 round nearest ties to even (RNE) mode. For information about controlling the rounding mode for native floating-point data types, refer to Modify the Rounding Mode of Floating-point Operations (-Xsrounding=<rounding_type>). |
ihc::FPdouble | A 64-bit floating-point number with an 11-bit exponent, a 52-bit mantissa, and a "Round to the nearest, tie break to even" rounding mode (equivalent to declaring ihc::ap_float<11, 52, fp_config::FP_Round::RNE>). When subnormal support is on, math operations with FPdouble map to the same hardware at the native double data type. For information about controlling the subnormal settings of FPdouble (and other ap_float data types), refer to Operations with Explicit Precision Controls. |