repo.or.cz
/
official-gcc
/
alias-decl.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
re-enable tls and lto tests for ObjC/C++
[official-gcc/alias-decl.git]
/
gcc
/
testsuite
/
obj-c++.dg
/
torture
/
tls
/
thr-init-1.mm
blob
62e322ed14b41c133155379f6d70e1a42a8fa9c1
1
// { dg-do run }
2
// { dg-require-effective-target tls }
3
// { dg-add-options tls }
4
5
extern "C" {
6
extern void abort ();
7
}
8
9
static __thread int fstat = 1;
10
11
int test_code(int b)
12
{
13
fstat += b ;
14
return fstat;
15
}
16
17
int main (int ac, char *av[])
18
{
19
int a = test_code(1);
20
21
if ( a != 2 || fstat != 2 )
22
abort ();
23
24
return 0;
25
}