1 2 #include "tree-vect.h" 3 4 double v[4096][4]; 5 6 __attribute__((noinline, noclone)) void bar(double p[][4])7bar (double p[][4]) 8 { 9 int i; 10 double d = 172.0; 11 for (i = 0; i < 4096; i++) 12 { 13 if (p[i][0] != 6.0 || p[i][1] != 6.0 || p[i][2] != 10.0) 14 __builtin_abort (); 15 if (__builtin_fabs (p[i][3] - d) > 0.25) 16 __builtin_abort (); 17 } 18 } 19 20 __attribute__((noinline, noclone)) void foo(void)21foo (void) 22 { 23 int i; 24 double w[4096][4], t; 25 for (i = 0; i < 4096; i++) 26 { 27 w[i][0] = v[i][0] + 2.0; 28 w[i][1] = v[i][1] + 1.0; 29 w[i][2] = v[i][2] + 4.0; 30 w[i][3] = (w[i][0] * w[i][0] + w[i][1] * w[i][1] + w[i][2] * w[i][2]); 31 } 32 bar (w); 33 } 34 35 int main()36main () 37 { 38 int i; 39 40 check_vect (); 41 42 for (i = 0; i < 4096; i++) 43 { 44 v[i][0] = 4.0; 45 v[i][1] = 5.0; 46 v[i][2] = 6.0; 47 } 48 foo (); 49 return 0; 50 } 51 52