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
Add malloc predictor (PR middle-end/83023).
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.dg
/
pr46387.c
blob
e06bd3b106581927ec4c7eb69b060c45d82a6bcf
1
/* PR debug/46387 */
2
/* { dg-do compile } */
3
/* { dg-options "-g -O2" } */
4
5
struct
S
{
double
x
;
double
y
;
short
z
; };
6
int
a
=
0
,
b
=
0
,
c
;
7
void
bar
(
int
,
int
,
int
);
8
void
baz
(
int
*,
int
*,
int
*);
9
10
void
11
foo
(
struct
S
*
v
)
12
{
13
int
x
,
y
,
z
;
14
if
(!
a
&&
b
!=
0
)
15
return
;
16
if
(
v
->
z
)
17
baz
(&
x
, &
y
, &
z
);
18
else
19
{
20
x
=
v
->
x
;
21
y
=
v
->
y
;
22
}
23
x
=
x
/ (
5
+
1
);
24
y
=
y
/ (
5
+
1
);
25
if
(
x
<
0
)
26
x
=
0
;
27
if
(
x
>
c
-
1
)
28
x
=
c
-
1
;
29
if
(
b
==
0
)
30
bar
(
x
,
y
,
1
);
31
return
;
32
}