Loop Unroll - Variable Trip Count - 2020.1 English - UG1448

Vitis HLS Messaging (UG1448)

Document ID
UG1448
Release Date
2020-06-03
Version
2020.1 English

Description

This message is to inform the user that the code is violating loop unrolling optimization rules

Explanation

If the tool could not estimate the loop-bound, then it would not be possible for the tool to generate the number of parallel ops. The following is an example that fails the optimization:

// var is from the input which goes till estimated 128
for(int i=0;i<var;i++)
{
#pragma HLS unroll
...
...
}

Solution

If the user knows the loop bound, then it is advised to use it for the loop bound for the loop unrolling optimization.