![]() |
AI Engine API User Guide (AIE-API) 2025.1
|
These functions provide the ability to finely control the pipelining of a loop.
Classes | |
struct | aie::LoopOptions |
A structure containing options related to loop iteration peeling. More... | |
Functions | |
template<unsigned MinIters, LoopOptions Opts = LoopOptions{}, typename Fn> | |
void | aie::pipelined_loop (unsigned count, Fn &&fn) |
Invokes a function object a given number of times. | |
template<unsigned MinIters, LoopOptions OptsFn1 = LoopOptions{}, LoopOptions OptsFn2 = LoopOptions{}, typename Fn1, typename Fn2> | |
void | aie::pipelined_loops (unsigned count, Fn1 &&fn1, Fn2 &&fn2) |
Invokes two function objects a given number of times. | |
struct aie::LoopOptions |
A structure containing options related to loop iteration peeling.
To be used with aie::pipelined_loop
void aie::pipelined_loop | ( | unsigned | count, |
Fn && | fn ) |
Invokes a function object a given number of times.
The pipelining can be controlled by optionally peeling iterations.
MinIters | Lower bound on the number of iterations of the loop body |
Opts | Options related to peeling loop iterations |
count | Number of iterations |
fn | The callable to pipeline |
void aie::pipelined_loops | ( | unsigned | count, |
Fn1 && | fn1, | ||
Fn2 && | fn2 ) |
Invokes two function objects a given number of times.
The pipelining of each can be controlled by optionally peeling iterations.
MinIters | Lower bound on the number of iterations of the loop body |
OptsFn1 | Options related to peeling loop iterations of the first function |
OptsFn2 | Options related to peeling loop iterations of the second function |
count | Number of iterations |
fn1 | The first callable to pipeline |
fn2 | The second callable to pipeline |
For example, take the following
This will result in the following execution: