1/* { dg-do run } */ 2 3#include <assert.h> 4int A[2][2] = { 1, 2, 3, 4 }; 5void 6f (int n, int B[n][n], int C[]) 7{ 8 int D[2][2] = { 1, 2, 3, 4 }; 9 int E[n][n]; 10 assert (n >= 2); 11 E[1][1] = 4; 12#pragma omp parallel firstprivate(B, C, D, E) 13 { 14 assert (sizeof (B) == sizeof (int (*)[n])); 15 assert (sizeof (C) == sizeof (int *)); 16 assert (sizeof (D) == 4 * sizeof (int)); 17 assert (sizeof (E) == n * n * sizeof (int)); 18 /* Private B and C have values of original B and C. */ 19 assert (&B[1][1] == &A[1][1]); 20 assert (&C[3] == &A[1][1]); 21 assert (D[1][1] == 4); 22 assert (E[1][1] == 4); 23 } 24} 25int 26main () 27{ 28 f (2, A, A[0]); 29 return 0; 30} 31