index=ia(1)
do i=1,n
   num=ia(index)
   index=num
end do

ia(n) contains the integers 1 to n in random order, causing memory loads in random order. Because each iteration depends on the previous one, the time to complete one iteration depends on the latency in accessing the element of the array.

-- MattWalsh - 23 Feb 2004

Topic revision: r1 - 23 Feb 2004 - MattWalsh
 
This site is powered by the TWiki collaboration platformCopyright © 2008-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback