The loop interchanging transformation
exchanges the indexes, the bounds and the steps of two nested do-loops
statements ; the outer loop and an inner loop given by its internal level.
Example 64: Interchange of the first and the third loops (indexes I and K). The level is 2.
DO I=1,N DO J=2,M DO K=2,M CALL F(I,J,K) ENDDO ENDDO ENDDO
DO K=2,M DO J=2,M DO I=1,N CALL F(I,J,K) ENDDO ENDDO ENDDO