From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17283 invoked by alias); 1 Apr 2010 00:55:47 -0000 Received: (qmail 17260 invoked by uid 22791); 1 Apr 2010 00:55:46 -0000 X-SWARE-Spam-Status: No, hits=-1.0 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED,SPF_HELO_PASS,T_RP_MATCHES_RCVD,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: sourceware.org Received: from kuber.nabble.com (HELO kuber.nabble.com) (216.139.236.158) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 01 Apr 2010 00:55:41 +0000 Received: from isper.nabble.com ([192.168.236.156]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1Nx8h8-00047A-Vf for gcc-bugs@gcc.gnu.org; Wed, 31 Mar 2010 17:55:38 -0700 Message-ID: <28103457.post@talk.nabble.com> Date: Thu, 01 Apr 2010 00:55:00 -0000 From: Auser99 To: gcc-bugs@gcc.gnu.org Subject: Re: [Bug middle-end/43602] New: ___emutls_v.__gcov_indirect_call_[counters|callee] undefined on *-*-darwin* In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit References: X-IsSubscribed: yes Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-04/txt/msg00002.txt.bz2 Thanks. au http://www.xprad.org/ Bugzilla from gcc-bugzilla@gcc.gnu.org wrote: > > The commit of... > > Author: rguenth > Date: Tue Mar 30 13:10:16 2010 > New Revision: 157822 > > URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=157822 > Log: > 2010-03-30 Seongbae Park > Jack Howarth > > * tree-profile.c (tree_init_ic_make_global_vars): Make static > variables TLS. > > Modified: > trunk/gcc/ChangeLog > trunk/gcc/tree-profile.c > > ...resulted in a number of profile related testsuite regressions on > darwin. > These are all of the form... > > [MacPro:~] howarth% > /sw/src/fink.build/gcc45-4.4.999-20100330/darwin_objdir/gcc/xgcc > -B/sw/src/fink.build/gcc45-4.4.999-20100330/darwin_objdir/gcc/ > /sw/src/fink.build/gcc45-4.4.999-20100330/gcc-4.5-20100330/gcc/testsuite/gcc.dg/matrix/transpose-1.c > -fprofile-generate -O3 -lm -o > /sw/src/fink.build/gcc45-4.4.999-20100330/darwin_objdir/gcc/testsuite/gcc/transpose-1.x01 > Undefined symbols: > "___emutls_v.__gcov_indirect_call_counters", referenced from: > _mem_init in cc591Wfh.o > _main in cc591Wfh.o > global constructors keyed to 65535_0_transpose_1.c in cc591Wfh.o > "___emutls_v.__gcov_indirect_call_callee", referenced from: > _mem_init in cc591Wfh.o > _mem_init in cc591Wfh.o > _main in cc591Wfh.o > _main in cc591Wfh.o > global constructors keyed to 65535_0_transpose_1.c in cc591Wfh.o > global constructors keyed to 65535_0_transpose_1.c in cc591Wfh.o > ld: symbol(s) not found > collect2: ld returned 1 exit status > > Reverting r157822 eliminates these failures. These are surprising since > darwin > should now provide all of the additional emutls symbols via a versioned > libgcc_ext shared library. > > On x86_64-apple-darwin10, current gcc trunk produces... > > [MacPro:darwin_objdir/x86_64-apple-darwin10.3.0/libgcc] howarth% nm > libgcc_s.1.dylib | grep emutls > 00013e70 T ___emutls_get_address > 00014070 T ___emutls_register_common > 00013e20 t _emutls_destroy > 00013de0 t _emutls_init > 00015100 b _emutls_key > 000150a0 d _emutls_mutex > 000150fc b _emutls_size > > [MacPro:darwin_objdir/x86_64-apple-darwin10.3.0/libgcc] howarth% nm > libgcc_ext.10.5.dylib | grep emutls > 00013e70 T ___emutls_get_address > 00014070 T ___emutls_register_common > > The undefined ___emutls_v.__gcov_indirect_call_counters and > ___emutls_v.__gcov_indirect_call_callee symbols occur for the following > permutations... > > 1) r157820 with r157822 applied (where libgcc is built with only > -DHAVE_CC_TLS). > 2) r157822 (where libgcc is built with both -DHAVE_CC_TLS and > -DUSE_EMUTLS) > 3) r157822 with the following patch applied to invert the logic of that > commit > so that neither -DHAVE_CC_TLS or -DUSE_EMUTLS are used in building > libgcc) > > Index: libgcc/Makefile.in > =================================================================== > --- libgcc/Makefile.in (revision 157840) > +++ libgcc/Makefile.in (working copy) > @@ -226,7 +226,7 @@ > # will usually contain -g, so for the moment CFLAGS goes first. We must > # include CFLAGS - that's where multilib options live. > INTERNAL_CFLAGS = $(CFLAGS) $(LIBGCC2_CFLAGS) $(HOST_LIBGCC2_CFLAGS) \ > - $(INCLUDES) @set_have_cc_tls@ @set_use_emutls@ > + $(INCLUDES) @set_have_cc_tls@ > > MULTIDIR := $(shell $(CC) $(CFLAGS) -print-multi-directory) > MULTIOSDIR := $(shell $(CC) $(CFLAGS) -print-multi-os-directory) > Index: libgcc/configure.ac > =================================================================== > --- libgcc/configure.ac (revision 157840) > +++ libgcc/configure.ac (working copy) > @@ -232,20 +232,13 @@ > # gcc, which can't be used to build executable due to that libgcc > # is yet to be built here. > GCC_CHECK_CC_TLS > +GCC_CHECK_EMUTLS > set_have_cc_tls= > -if test "$enable_tls $gcc_cv_have_cc_tls" = "yes yes"; then > +if test "$enable_tls $gcc_cv_have_cc_tls $gcc_cv_use_emutls" = "yes yes > no"; > then > set_have_cc_tls="-DHAVE_CC_TLS" > fi > AC_SUBST(set_have_cc_tls) > > -# See if we have emulated thread-local storage. > -GCC_CHECK_EMUTLS > -set_use_emutls= > -if test "$enable_tls $gcc_cv_use_emutls" = "yes yes"; then > - set_use_emutls="-DUSE_EMUTLS" > -fi > -AC_SUBST(set_use_emutls) > - > # Conditionalize the makefile for this target machine. > tmake_file_= > for f in ${tmake_file} > > > -- > Summary: ___emutls_v.__gcov_indirect_call_[counters|callee] > undefined on *-*-darwin* > Product: gcc > Version: 4.5.0 > Status: UNCONFIRMED > Severity: normal > Priority: P3 > Component: middle-end > AssignedTo: unassigned at gcc dot gnu dot org > ReportedBy: howarth at nitro dot med dot uc dot edu > GCC build triplet: *-*-darwin* > GCC host triplet: *-*-darwin* > GCC target triplet: *-*-darwin* > > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43602 > > > -- View this message in context: http://old.nabble.com/-Bug-middle-end-43602---New%3A-___emutls_v.__gcov_indirect_call_-counters%7Ccallee--undefined-on-*-*-darwin*-tp28095803p28103457.html Sent from the gcc - bugs mailing list archive at Nabble.com.