From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 92788 invoked by alias); 12 Jun 2018 22:19:56 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 92404 invoked by uid 89); 12 Jun 2018 22:19:53 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-25.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,SPF_SOFTFAIL autolearn=ham version=3.3.2 spammy= X-HELO: mga01.intel.com X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 From: "H.J. Lu" To: libc-alpha@sourceware.org Subject: [PATCH 10/20] libcpu-rt-c: Don't use IFUNC memcmp in init_cpu_features Date: Tue, 12 Jun 2018 22:20:00 -0000 Message-Id: <20180612221939.19545-11-hjl.tools@gmail.com> In-Reply-To: <20180612221939.19545-1-hjl.tools@gmail.com> References: <20180612221939.19545-1-hjl.tools@gmail.com> X-SW-Source: 2018-06/txt/msg00277.txt.bz2 Don't use IFUNC memcmp in init_cpu_features libcpu-rt-c since IFUNC must be set up by init_cpu_features. * sysdeps/x86/cpu-tunables.c (DEFAULT_MEMCMP): Don't use IFUNC memcmp in libcpu-rt-c. --- sysdeps/x86/cpu-tunables.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sysdeps/x86/cpu-tunables.c b/sysdeps/x86/cpu-tunables.c index 3d1c26577f..901a5d3934 100644 --- a/sysdeps/x86/cpu-tunables.c +++ b/sysdeps/x86/cpu-tunables.c @@ -32,13 +32,17 @@ /* We can't use IFUNC memcmp nor strlen in init_cpu_features from libc.a since IFUNC must be set up by init_cpu_features. */ -# if defined USE_MULTIARCH && !defined SHARED +# if defined USE_MULTIARCH && (!defined SHARED || IS_IN (libcpu_rt_c)) # ifdef __x86_64__ # define DEFAULT_MEMCMP __memcmp_sse2 # else # define DEFAULT_MEMCMP __memcmp_ia32 # endif -extern __typeof (memcmp) DEFAULT_MEMCMP; +extern __typeof (memcmp) DEFAULT_MEMCMP +# if IS_IN (libcpu_rt_c) + __attribute__ ((visibility ("hidden"))); +# endif +; # else # define DEFAULT_MEMCMP memcmp # endif -- 2.17.1