Optimization directives can be also applied to objects or scopes defined in a class. The difference is typically that classes are defined in a header file. Use one of the following actions to open the header file:
- From the Explorer view in the Vitis HLS GUI,
Includesfolder, double-click the header file to open it in the Code Editor.
- From within an open source code file, place the cursor over the
#includestatement for the header file, hold down the Ctrl key, and click the header file to open it in the Code Editor.
The Directives tab is populated with the objects in the header file, and directives can be applied.
Care should be taken when applying directives as pragmas to a header file. The file might be used by other people or used in other projects. Any directives added as a pragma are applied each time the header file is included in a design.