This preview shows page 1. Sign up to view the full content.
Unformatted text preview: A[j+1][i] = B[i + 1][j - 1]; } } (a) Give the distance and direction vectors for the dependences in this loop. Indicate which array the dependences are on. (b) Is loop interchange legal for this loop? Why or why not? (c) Assuming both the A and B arrays are stored in row-major order, do you expect loop interchange to be benecial for this code? Why or why not? Note that in modern processors, there are essentially no latency penalties for cache misses that occur during stores; it is mostly only cache misses during loads that aect performance. 1...
View Full Document
This note was uploaded on 02/19/2012 for the course ECE 468 taught by Professor Test during the Fall '08 term at Purdue University-West Lafayette.
- Fall '08