aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/validation/mem2reg/init-local-array.c
blob: 2ac53bc7732ff56005d9a3642399390bfeaf572f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
int array(void)
{
	int a[2];

	a[1] = 1;
	return a[1];
}

int sarray(void)
{
	struct {
		int a[2];
	} s;

	s.a[1] = 1;
	return s.a[1];
}

/*
 * check-name: init local array
 * check-command: test-linearize -Wno-decl -fdump-ir=mem2reg $file
 * check-output-ignore
 * check-output-excludes: load\\.
 * check-output-excludes: store\\.
 */