cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
leuko
Visitor
Visitor
235 Views
Registered: ‎02-28-2021

[Vitis HLS] What do `Bits P{0,1,2}` mean in Vitis HLS resource profile?

What do `Bits P{0,1,2}` mean in Vitis resource profile in the screenshot attached? Vitis HLS user guide does not contain any details about resource profile viewer.

loop-vitis-resource-profile.png

 

 

 

 

 

 

 

 

 

 

 

The code:

#include <array>                                                                                                     
                                                                                                                     
const auto N = 1<<5;  // array size                                                                                  
using vec_t = std::array<int, N>;                                                                                    
                                                                                                                     
auto multiply_and_accumulate(vec_t& xs, vec_t& ys) {                                                                 
    auto sum = 0;                                                                                                    
                                                                                                                     
    unsigned int i=0;                                                                                                
    for (const auto& x : xs) {                                                                                       
        sum += x*ys[i];                                                                                              
        ++i;                                                                                                         
    }                                                                                                                
    return sum;                                                                                                      
}                                                                                                                    
Tags (1)
0 Kudos
1 Reply
leuko
Visitor
Visitor
224 Views
Registered: ‎02-28-2021

I have the hunch that an expression in Vitis HLS can have three terms at most, and these are `P0`, `P1`, and `P2`. For example the expression `sum_1_*` adds two 32 bit numbers together.

0 Kudos