This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch][google/integration] Don't force tls-model to initial-exec when building libgomp (issue6107046)


The patch below is needed for google/integration branch:
we want to be able build libgomp.a with -fPIC, be able to link it into a
shared library, and be able to dlopen that library without running out of
static TLS space (-ftls-model=initial-exec precludes that last part).

Google ref b/6368405
Google ref b/6156799

Tested: make && make check

2012-04-22   Paul Pluzhnikov  <>

	* libgomp/configure.tgt: Don't force initial-exec.

Index: libgomp/configure.tgt
--- libgomp/configure.tgt	(revision 186636)
+++ libgomp/configure.tgt	(working copy)
@@ -10,16 +10,6 @@
 #  XCFLAGS		Add extra compile flags to use.
 #  XLDFLAGS		Add extra link flags to use.
-# Optimize TLS usage by avoiding the overhead of dynamic allocation.
-if test $gcc_cv_have_tls = yes ; then
-  case "${target}" in
-    *-*-linux*)
-	XCFLAGS="${XCFLAGS} -ftls-model=initial-exec"
-	;;
-  esac
 # Since we require POSIX threads, assume a POSIX system by default.

This patch is available for review at

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]