repo.or.cz
/
netbsd-mini2440.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
No empty .Rs/.Re
[netbsd-mini2440.git]
/
gnu
/
dist
/
gcc4
/
gcc
/
testsuite
/
gcc.dg
/
tls
/
pic-1.c
blob
bcd42bd8572cef972854a7faddd06b87852d92ab
1
/* { dg-do compile } */
2
/* { dg-options "-O2 -fpic -ftls-model=global-dynamic" } */
3
/* { dg-require-effective-target tls } */
4
5
extern
__thread
long
e1
;
6
extern
__thread
int
e2
;
7
static
__thread
long
s1
;
8
static
__thread
int
s2
;
9
10
long
*
ae1
(
void
)
11
{
12
return
&
e1
;
13
}
14
15
int
*
ae2
(
void
)
16
{
17
return
&
e2
;
18
}
19
20
long
*
as1
(
void
)
21
{
22
return
&
s1
;
23
}
24
25
int
*
as2
(
void
)
26
{
27
return
&
s2
;
28
}
29
30
long
ge1
(
void
)
31
{
32
return
e1
;
33
}
34
35
int
ge2
(
void
)
36
{
37
return
e2
;
38
}
39
40
long
gs1
(
void
)
41
{
42
return
s1
;
43
}
44
45
int
gs2
(
void
)
46
{
47
return
s2
;
48
}
49
50
long
ge3
(
void
)
51
{
52
return
e1
+
e2
;
53
}
54
55
long
gs3
(
void
)
56
{
57
return
s1
+
s2
;
58
}
59
60
long
ge4
(
void
)
61
{
62
if
(
0
)
63
return
e1
;
64
return
e2
;
65
}
66
67
long
gs4
(
void
)
68
{
69
if
(
0
)
70
return
s1
;
71
return
s2
;
72
}