repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
pr79732.c: Require alias support.
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
torture
/
pr36373-1.c
blob
9cd02c57a40a58dbb1b6e7e569e4af13abce5f82
1
/* { dg-do run } */
2
/* { dg-options "-fno-tree-sra" } */
3
4
extern
void
abort
(
void
);
5
struct
Bar
{
6
struct
Foo
{
7
int
*
p
;
8
}
x
;
9
int
*
q
;
10
};
11
struct
Foo
__attribute__
((
noinline
))
12
bar
(
int
*
p
)
13
{
14
struct
Foo f
;
15
f
.
p
=
p
;
16
return
f
;
17
}
18
void
__attribute__
((
noinline
))
19
foo
(
struct
Foo f
)
20
{
21
*
f
.
p
=
0
;
22
}
23
int
main
()
24
{
25
int
a
,
b
;
26
a
=
0
;
27
b
=
1
;
28
struct
Bar f
;
29
f
.
x
=
bar
(&
b
);
30
f
.
q
= &
a
;
31
foo
(
f
.
x
);
32
if
(
b
!=
0
)
33
abort
();
34
return
0
;
35
}