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
x86: Tune Skylake, Cannonlake and Icelake as Haswell
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.c-torture
/
execute
/
pr78170.c
blob
dce8a3eee362f43216210abb20df14520ded0cd7
1
/* { dg-require-effective-target int32plus } */
2
3
/* PR tree-optimization/78170.
4
Check that sign-extended store to a bitfield
5
doesn't overwrite other fields. */
6
7
int
a
,
b
,
d
;
8
9
struct
S0
10
{
11
int
f0
;
12
int
f1
;
13
int
f2
;
14
int
f3
;
15
int
f4
;
16
int
f5
:
15
;
17
int
f6
:
17
;
18
int
f7
:
2
;
19
int
f8
:
30
;
20
}
c
;
21
22
void
fn1
()
23
{
24
d
=
b
=
1
;
25
for
(;
b
;
b
=
a
)
26
{
27
struct
S0 e
= {
0
,
0
,
0
,
0
,
0
,
0
,
1
,
0
,
1
};
28
c
=
e
;
29
c
.
f6
= -
1
;
30
}
31
}
32
33
int
main
()
34
{
35
fn1
();
36
if
(
c
.
f7
!=
0
)
37
__builtin_abort
();
38
return
0
;
39
}