mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-02 06:40:25 +08:00
invoke.texi: Document -mTLS.
* doc/invoke.texi: Document -mTLS. * testsuite/gcc.target/frv/all-tls-global-dynamic.c: New. * testsuite/gcc.target/frv/all-tls-initial-exec.c: New. * testsuite/gcc.target/frv/all-tls-initial-exec-pic.c: New. * testsuite/gcc.target/frv/all-tls-local-dynamic.c: New. * testsuite/gcc.target/frv/all-tls-local-dynamic-plt.c: New. * testsuite/gcc.target/frv/all-tls-local-dynamic-plt-pic.c: New. * testsuite/gcc.target/frv/all-tls-local-exec.c: New. * testsuite/gcc.target/frv/all-tls-local-exec-TLS.c: New. * configure.ac: Check for a TLS capable gas. * configure: Regenerate. From-SVN: r94283
This commit is contained in:
parent
55e79aef81
commit
e4dd71deb7
@ -1,3 +1,19 @@
|
||||
2005-01-26 Aldy Hernandez <aldyh@redhat.com>
|
||||
|
||||
* doc/invoke.texi: Document -mTLS.
|
||||
|
||||
* testsuite/gcc.target/frv/all-tls-global-dynamic.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-initial-exec.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-initial-exec-pic.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-local-dynamic.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-local-dynamic-plt.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-local-dynamic-plt-pic.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-local-exec.c: New.
|
||||
* testsuite/gcc.target/frv/all-tls-local-exec-TLS.c: New.
|
||||
|
||||
* configure.ac: Check for a TLS capable gas.
|
||||
|
||||
* configure: Regenerate.
|
||||
2005-01-26 Richard Henderson <rth@redhat.com>
|
||||
|
||||
PR middle-end/18008
|
||||
|
9
gcc/configure
vendored
9
gcc/configure
vendored
@ -13690,6 +13690,15 @@ foo: .long 25
|
||||
tls_first_minor=13
|
||||
tls_as_opt=--fatal-warnings
|
||||
;;
|
||||
frv*-*-*)
|
||||
conftest_s='
|
||||
.section ".tdata","awT",@progbits
|
||||
x: .long 25
|
||||
.text
|
||||
call #gettlsoff(x)'
|
||||
tls_first_major=2
|
||||
tls_first_minor=14
|
||||
;;
|
||||
i[34567]86-*-*)
|
||||
conftest_s='
|
||||
.section ".tdata","awT",@progbits
|
||||
|
@ -2279,6 +2279,15 @@ foo: .long 25
|
||||
tls_first_minor=13
|
||||
tls_as_opt=--fatal-warnings
|
||||
;;
|
||||
frv*-*-*)
|
||||
conftest_s='
|
||||
.section ".tdata","awT",@progbits
|
||||
x: .long 25
|
||||
.text
|
||||
call #gettlsoff(x)'
|
||||
tls_first_major=2
|
||||
tls_first_minor=14
|
||||
;;
|
||||
i[34567]86-*-*)
|
||||
conftest_s='
|
||||
.section ".tdata","awT",@progbits
|
||||
|
@ -461,6 +461,7 @@ Objective-C and Objective-C++ Dialects}.
|
||||
-mvliw-branch -mno-vliw-branch @gol
|
||||
-mmulti-cond-exec -mno-multi-cond-exec -mnested-cond-exec @gol
|
||||
-mno-nested-cond-exec -mtomcat-stats @gol
|
||||
-mTLS -mtls @gol
|
||||
-mcpu=@var{cpu}}
|
||||
|
||||
@emph{H8/300 Options}
|
||||
@ -7872,6 +7873,16 @@ shared libraries (i.e., @option{-fPIC} or @option{-fpic}), or when an
|
||||
optimization option such as @option{-O3} or above is present in the
|
||||
command line.
|
||||
|
||||
@item -mTLS
|
||||
@opindex TLS
|
||||
|
||||
Assume a large TLS segment when generating thread-local code.
|
||||
|
||||
@item -mtls
|
||||
@opindex tls
|
||||
|
||||
Do not assume a large TLS segment when generating thread-local code.
|
||||
|
||||
@item -mgprel-ro
|
||||
@opindex mgprel-ro
|
||||
|
||||
|
12
gcc/testsuite/gcc.target/frv/all-tls-global-dynamic.c
Normal file
12
gcc/testsuite/gcc.target/frv/all-tls-global-dynamic.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-options "-ftls-model=global-dynamic -fpic -mfdpic -mno-inline-plt" } */
|
||||
/* { dg-do compile } */
|
||||
extern __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "call #gettlsoff.x." } } */
|
12
gcc/testsuite/gcc.target/frv/all-tls-initial-exec-pic.c
Normal file
12
gcc/testsuite/gcc.target/frv/all-tls-initial-exec-pic.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-options "-ftls-model=initial-exec -fpic -mfdpic" } */
|
||||
/* { dg-do compile } */
|
||||
extern __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "ld.*#gottlsoff12" } } */
|
12
gcc/testsuite/gcc.target/frv/all-tls-initial-exec.c
Normal file
12
gcc/testsuite/gcc.target/frv/all-tls-initial-exec.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-options "-ftls-model=initial-exec -mfdpic" } */
|
||||
/* { dg-do compile } */
|
||||
extern __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "ld.*#tlsoff.x.@" } } */
|
13
gcc/testsuite/gcc.target/frv/all-tls-local-dynamic-plt-pic.c
Normal file
13
gcc/testsuite/gcc.target/frv/all-tls-local-dynamic-plt-pic.c
Normal file
@ -0,0 +1,13 @@
|
||||
/* { dg-options "-ftls-model=local-dynamic -minline-plt -fpic -mfdpic" } */
|
||||
/* { dg-do compile } */
|
||||
static __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "lddi.*gottlsdesc12" } } */
|
||||
/* { dg-final { scan-assembler "calll.*#gettlsoff\\(0\\)" } } */
|
12
gcc/testsuite/gcc.target/frv/all-tls-local-dynamic-plt.c
Normal file
12
gcc/testsuite/gcc.target/frv/all-tls-local-dynamic-plt.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-options "-ftls-model=local-dynamic -minline-plt -fPIC -mfdpic" } */
|
||||
/* { dg-do compile } */
|
||||
static __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "ldd.*tlsdesc\\(0\\)@" } } */
|
13
gcc/testsuite/gcc.target/frv/all-tls-local-dynamic.c
Normal file
13
gcc/testsuite/gcc.target/frv/all-tls-local-dynamic.c
Normal file
@ -0,0 +1,13 @@
|
||||
/* { dg-options "-ftls-model=local-dynamic -fpic -mfdpic" } */
|
||||
/* { dg-do compile } */
|
||||
static __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "gettlsoff\\(0\\)" } } */
|
||||
/* { dg-final { scan-assembler "tlsmoff12" } } */
|
12
gcc/testsuite/gcc.target/frv/all-tls-local-exec-TLS.c
Normal file
12
gcc/testsuite/gcc.target/frv/all-tls-local-exec-TLS.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-options "-ftls-model=local-exec -mfdpic -mTLS" } */
|
||||
/* { dg-do compile } */
|
||||
static __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler "sethi.*tlsmoffhi\\(x\\)," } } */
|
12
gcc/testsuite/gcc.target/frv/all-tls-local-exec.c
Normal file
12
gcc/testsuite/gcc.target/frv/all-tls-local-exec.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-options "-ftls-model=local-exec -mfdpic" } */
|
||||
/* { dg-do compile } */
|
||||
static __thread int x;
|
||||
extern void bar ();
|
||||
int *y;
|
||||
|
||||
void foo (void)
|
||||
{
|
||||
bar ();
|
||||
y = &x;
|
||||
}
|
||||
/* { dg-final { scan-assembler ".*tlsmoff12" } } */
|
Loading…
x
Reference in New Issue
Block a user