Loop-carried dependencies – Altera Nios II C2H Compiler User Manual

Page 84

Advertising
background image

3–44

9.1

Altera Corporation

Nios II C2H Compiler User Guide

November 2009

Scheduling

Figure 3–21

illustrates how the C2H Compiler schedules successive

iterations of the loop shown in

Figure 3–20

. The C2H Compiler is able to

start a new iteration of the loop immediately after the prior iteration
completes State 0.

This is an example of an ideally-pipelined loop. Although the
C2H Compiler can pipeline many loops ideally, it is sometimes not
possible due to the lack of inherent parallelism in the code, as shown in

“Loop-Carried Dependencies”

.

Figure 3–21. Pipelined Loop Iterations

Loop-Carried Dependencies

Loop-carried dependencies are data dependencies that manifest when
pipelining successive iterations of a loop. If the result of one calculation
in an iteration of the loop is used in a later iteration of the loop, then a
loop-carried dependency exists between the two operations.

Advertising