Loop perforation
# Loop perforation

Loop perforation is an approximate computing technique that allows to regularly skip some iterations of a loop.

It relies on one parameter: the perforation rate. The perforation rate can be interpreted as the number of iteration to skip each time or the number of iterations to perform before skipping one.

Variants of loop perforation include those that skip iterations deterministically at regular intervals, those that skip iterations at the beginning or the end of the loop, and those that skip a random sample of iterations. The compiler may select the perforation variant at the compile-time, or include instrumentation that allows the runtime system to adaptively adjust the perforation strategy and perforation rate to satisfy the end-to-end accuracy goal.

Loop perforation techniques were first developed by MIT senior researchers Martin C. Rinard and Stelios Sidiroglou.

## Code examples

The examples that follows provide the result of loop perforation applied on this C-like source code

