Performance Pragma - 3 - 2022.2 English

Vitis HLS Messaging (UG1448)

Document ID
UG1448
Release Date
2022-12-16
Version
2022.2 English

Description

Warning: [HLS 214-346] Cannot apply performance pragma for loop 'VITIS_LOOP_10_3' in function 'top' because dataflow pragma takes precedence (test.cpp:11:9).

Explanation

The performance pragma cannot directly be applied to a loop that is also being dataflow'ed. Consider moving the performance pragma to a loop that is within the dataflow loop or a sub function called from the dataflow loop.

//////////// ORIGINAL ////////////
void top(int a[100][100],
  int b[10000][100]) {
  int k;
  int i;
  int j;
  for (i = 0; i < 100; i++) {
    for (k = 0; k < 100; k++) {
      for (j = 0; j < 100; j++)
#pragma HLS performance target_ti=200
#pragma HLS dataflow
        a[i][j] = b[i*k][j]+ b[i + k][j];
    }
  }
}