Debian Codegraph @

gcc/testsuite/gcc.dg/vect/pr84357.c

raw
1 /* { dg-do compile } */
2 /* { dg-additional-options "-Wall" } */
3
4 #define COUNT 32
5
6 typedef struct s1 {
7 unsigned char c;
8 } s1;
9
10 typedef struct s2
11 {
12 char pad;
13 s1 arr[COUNT];
14 } s2;
15
16 typedef struct s3 {
17 s1 arr[COUNT];
18 } s3;
19
20 s2 * get_s2();
21 s3 * gActiveS3;
22 void foo()
23 {
24 s3 * three = gActiveS3;
25 s2 * two = get_s2();
26
27 for (int i = 0; i < COUNT; i++)
28 {
29 two->arr[i].c = three->arr[i].c;
30 }
31 }