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
libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
pr102478.c
blob
43bc49b584df990c6f92970b65790a9abe69875c
1
/* PR rtl-optimization/102478 */
2
/* { dg-do compile } */
3
/* { dg-options "-O2 -fno-if-conversion -Wno-div-by-zero" } */
4
5
unsigned
a
,
b
,
c
;
6
7
void
8
foo
(
void
)
9
{
10
c
|=
__builtin_expect
(
65535
/
a
,
0
) &&
0
/
0
;
11
b
=
0
;
12
}
13
14
void
15
bar
(
void
)
16
{
17
if
(
a
<=
65535
)
18
__builtin_trap
();
19
b
=
0
;
20
}
21
22
void
23
baz
(
void
)
24
{
25
if
(
a
>
65535
)
26
b
=
0
;
27
else
28
__builtin_trap
();
29
}