OSDN Git Service
(root)
/
pf3gnuchains
/
gcc-fork.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
Merge lto branch into trunk.
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
gcc.c-torture
/
execute
/
struct-aliasing-1.c
1
struct S { float f; };
2
int __attribute__((noinline))
3
foo (int *r, struct S *p)
4
{
5
int *q = (int *)&p->f;
6
int i = *q;
7
*r = 0;
8
return i + *q;
9
}
10
extern void abort (void);
11
int main()
12
{
13
int i = 1;
14
if (foo (&i, (struct S *)&i) != 1)
15
abort ();
16
return (0);
17
}