1 #include <stdlib.h> 2 copy_summary(int b[1000],int a[1000],int pos)3void copy_summary(int b[1000], int a[1000], int pos) 4 { 5 b[pos] = 0; 6 int c = a[pos]; 7 } 8 9 #ifdef pencil_access 10 __attribute__((pencil_access(copy_summary))) 11 #endif 12 void copy(int b[1000], int a[1000], int pos); 13 main()14int main() 15 { 16 int a[1000], b[1000]; 17 18 for (int i = 0; i < 1000; ++i) 19 a[i] = i; 20 #pragma scop 21 for (int i = 0; i < 1000; ++i) 22 copy(b, a, i); 23 #pragma endscop 24 for (int i = 0; i < 1000; ++i) 25 if (b[i] != a[i]) 26 return EXIT_FAILURE; 27 28 return EXIT_SUCCESS; 29 } 30