From 3d78f2e96e29feaff7046c22fdc97aa58bee9688 Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Tue, 21 May 2002 18:11:29 -0700 Subject: c-common.h (enum rid): Add RID_THREAD. * c-common.h (enum rid): Add RID_THREAD. * c-decl.c (start_decl): Do not set DECL_COMMON for tls variables. (grokdeclarator): Grok __thread. * c-parse.in (reswords): Add __thread. (rid_to_yy): Add RID_THREAD. * cp/lex.c (rid_to_yy): Add RID_THREAD. * tree.h (DECL_THREAD_LOCAL): New. (struct tree_decl): Add thread_local_flag. * print-tree.c (print_node): Dump DECL_THREAD_LOCAL. * tree.c (staticp): TLS variables are not static. * target-def.h (TARGET_HAVE_TLS): New. * target.h (have_tls): New. * output.h (SECTION_TLS): New. * varasm.c (assemble_variable): TLS variables can't be common for now. (default_section_type_flags): Handle .tdata and .tbss. (default_elf_asm_named_section): Handle SECTION_TLS. (categorize_decl_for_section): Handle DECL_THREAD_LOCAL. * flags.h (flag_tls_default): Declare. * toplev.c (flag_tls_default): Define. (display_help): Display help for it. (decode_f_option): Set it. * doc/extend.texi (Thread-Local): New node describing language-level thread-local storage. * doc/invoke.texi (-ftls-model): Document. * fixinc/inclhack.def (thread_keyword): New. * fixinc/fixincl.x: Rebuild. From-SVN: r53715 --- gcc/doc/invoke.texi | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'gcc/doc/invoke.texi') diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 855fcd9..cedabdf 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -677,7 +677,7 @@ in the following sections. -fverbose-asm -fpack-struct -fstack-check @gol -fstack-limit-register=@var{reg} -fstack-limit-symbol=@var{sym} @gol -fargument-alias -fargument-noalias @gol --fargument-noalias-global -fleading-underscore} +-fargument-noalias-global -fleading-underscore -ftls-model=@var{model}} @end table @menu @@ -9915,6 +9915,14 @@ is to help link with legacy assembly code. Be warned that you should know what you are doing when invoking this option, and that not all targets provide complete support for it. + +@item -ftls-model=@var{model} +Alter the thread-local storage model to be used (@pxref{Thread-Local}). +The @var{model} argument should be one of @code{global-dynamic}, +@code{local-dynamic}, @code{initial-exec} or @code{local-exec}. + +The default without @option{-fpic} is @code{initial-exec}; with +@option{-fpic} the default is @code{global-dynamic}. @end table @c man end -- cgit v1.1