Download original image
Loop nest example in C. The left loop can be raised to the polyhedral model because each data access and the control statement expression are affine functions. The right loop nest cannot be represented in this model because the upper loop bound of the j dimension is an array indirection dependent of i (C[i]). When considered alone, the j loop can be raised in the model because its upper bound can be treated as a constant parameter. In that case we miss the nesting information and reduce the set of potentially applicable code transformations.