Forum Discussion
Altera_Forum
Honored Contributor
11 years agoAbout Loop Pipelining
Hello everyone, I am wondering if the AOC compiler would automatically infer loop pipelining for non-task multi-threaded kernels as well? In addition, does the "shift register inference" optimi...
Altera_Forum
Honored Contributor
11 years agoI think it's not based on unroll factors but instead based on how many operations are in the loop body. For example: if you have 5 operations in the loop body, the pipeline will have 5 stages. When you unroll the loop, other optimizations may apply, for example: you may have a reduction tree for things like sum+=b[i]; but if there are dependencies a very long and inefficient pipeline may be designed.
Disclaimer: I am not working for Altera so this answer is compiled from my understanding of reply from Outku and AOCL Optimization guide.