This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc 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]

GNU C Library master sources branch hjl/ifunc/test updated. glibc-2.16-ports-merge-446-g16924bb


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, hjl/ifunc/test has been updated
       via  16924bbd5ba8b0ef321a8aca093efe094c955ee0 (commit)
      from  5e5aafb29847ce627113e25288dea45b34bb1ff1 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=16924bbd5ba8b0ef321a8aca093efe094c955ee0

commit 16924bbd5ba8b0ef321a8aca093efe094c955ee0
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Sep 25 15:03:57 2012 -0700

    Don't build libc_ifunc.so

diff --git a/ChangeLog.test-ifunc b/ChangeLog.test-ifunc
index aac14fb..044f51c 100644
--- a/ChangeLog.test-ifunc
+++ b/ChangeLog.test-ifunc
@@ -1,5 +1,33 @@
 2012-09-25  H.J. Lu  <hongjiu.lu@intel.com>
 
+	* Makeconfig (+link-static-ifunc-tests): Removed.
+	(link-libc-ifunc): Likwewise.
+	(link-libc-ifunc-tests): Likwewise.
+	(link-libc-ifunc-before-gnulib): Likwewise.
+	(link-libc-ifunc): Likwewise.
+	(link-libc-ifunc-tests): Likwewise.
+	(link-libc-static-ifunc-tests): Likwewise.
+	(run-program-prefix): Don't prepend $(common-objpfx)string: to
+	--library-path for ifunc tests.
+	* Makerules (build-shlib-ifunc-helper): Removed.
+	(build-shlib-ifunc): Likewise.
+	(LDFLAGS-c_ifunc.so): Likewise.
+	(LDLIBS-c_ifunc.so): Likwewise.
+	($(common-objpfx)libc_ifunc.so): Likwewise.
+	($(common-objpfx)string/libc.so$(libc.so-version): Likwewise.
+	(common-generated): Don't add string/libc.so$(libc.so-version).
+	* Rules (binaries-ifunc-tests): Removed.
+	(binaries-static-ifunc-tests): Likwewise.
+	(binaries-shared-ifunc-tests): Likwewise.
+	($(addprefix $(objpfx),$(binaries-shared-ifunc-tests))): Likwewise.
+	($(addprefix $(objpfx),$(binaries-static-ifunc-tests))): Likwewise.
+	* string/Makefile: Include ../Makeconfig.
+	(routines): Add libc-func if $(multi-arch) is yes.
+	* string/Versions: Add __libc_func to GLIBC_PRIVATE if
+	USE_MULTIARCH is defined.
+
+2012-09-25  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* include/libc-func.h (__libc_func): Update comments.
 
 2012-09-24  H.J. Lu  <hongjiu.lu@intel.com>
diff --git a/Makeconfig b/Makeconfig
index a46c7ec..e96ebc7 100644
--- a/Makeconfig
+++ b/Makeconfig
@@ -440,8 +440,6 @@ ifndef +link-static
 	       $(+link-static-after-libc)
 +link-static-tests = $(+link-static-before-libc) $(link-libc-static-tests) \
 		     $(+link-static-after-libc)
-+link-static-ifunc-tests = $(+link-static-before-libc) $(link-libc-static-ifunc-tests) \
-		     $(+link-static-after-libc)
 endif
 # Commands for linking programs with the C library.
 ifndef +link
@@ -459,11 +457,9 @@ ifeq (yes,$(build-shared))
 +link-after-libc = $(+postctor) $(+postinit)
 +link = $(+link-before-libc) $(link-libc) $(+link-after-libc)
 +link-tests = $(+link-before-libc) $(link-libc-tests) $(+link-after-libc)
-+link-ifunc-tests = $(+link-before-libc) $(link-libc-ifunc-tests) $(+link-after-libc)
 else
 +link = $(+link-static)
 +link-tests = $(+link-static-tests)
-+link-ifunc-tests = $(+link-static-ifunc-tests)
 endif
 endif
 # Command for statically linking bounded-pointer programs with the C library.
@@ -494,13 +490,6 @@ link-libc-before-gnulib = -Wl,-rpath-link=$(rpath-link) \
 	    $(as-needed) $(common-objpfx)elf/ld.so $(no-as-needed)
 link-libc = $(link-libc-before-gnulib) $(gnulib)
 link-libc-tests = $(link-libc-before-gnulib) $(gnulib-tests)
-# Link against libc_ifunc.so for IFUNC tests.
-link-libc-ifunc-before-gnulib = -Wl,-rpath-link=$(rpath-link) \
-	    $(common-objpfx)string/libc.so$(libc.so-version) \
-	    $(common-objpfx)$(patsubst %,$(libtype.oS),c) \
-	    $(as-needed) $(common-objpfx)elf/ld.so $(no-as-needed)
-link-libc-ifunc = $(link-libc-ifunc-before-gnulib) $(gnulib)
-link-libc-ifunc-tests = $(link-libc-ifunc-before-gnulib) $(gnulib-tests)
 # This is how to find at build-time things that will be installed there.
 rpath-dirs = math elf dlfcn nss nis rt resolv crypt
 rpath-link = \
@@ -511,8 +500,6 @@ nssobjdir := $(patsubst ../$(subdir),.,$(common-objpfx)nss)
 resolvobjdir := $(patsubst ../$(subdir),.,$(common-objpfx)resolv)
 link-libc = $(common-objpfx)libc.a $(otherlibs) $(gnulib) $(common-objpfx)libc.a $(gnulib)
 link-libc-tests = $(common-objpfx)libc.a $(otherlibs) $(gnulib-tests) $(common-objpfx)libc.a $(gnulib-tests)
-link-libc-ifunc = $(common-objpfx)string/libc-func.o $(common-objpfx)libc.a $(otherlibs) $(gnulib) $(common-objpfx)libc.a $(gnulib)
-link-libc-ifunc-tests = $(common-objpfx)string/libc-func.o $(common-objpfx)libc.a $(otherlibs) $(gnulib-tests) $(common-objpfx)libc.a $(gnulib-tests)
 endif
 endif
 
@@ -539,7 +526,6 @@ endif
 # The static libraries.
 link-libc-static = -Wl,--start-group $(common-objpfx)libc.a $(static-gnulib) -Wl,--end-group
 link-libc-static-tests = -Wl,--start-group $(common-objpfx)libc.a $(static-gnulib-tests) -Wl,--end-group
-link-libc-static-ifunc-tests = -Wl,--start-group $(common-objpfx)libc.a $(common-objpfx)string/libc-func.o $(static-gnulib-tests) -Wl,--end-group
 link-libc-bounded = $(common-objpfx)libc_b.a $(gnulib) $(common-objpfx)libc_b.a
 
 # How to link against libgcc.  Some libgcc functions, such as those
@@ -624,10 +610,7 @@ $(subst $(empty) ,:,$(strip $(patsubst -Wl$(comma)-rpath-link=%, %,\
 run-program-prefix = $(if $(filter $(notdir $(built-program-file)),\
 				   $(tests-static) $(xtests-static)),, \
 			  $(elf-objpfx)$(rtld-installed-name) \
-			  --library-path $(if $(filter $(notdir $(built-program-file)), \
-						       $(tests-ifunc) $(xtests-ifunc)), \
-					      $(common-objpfx)string:$(rpath-link)$(patsubst %,:%,$(sysdep-library-path)), \
-					      $(rpath-link)$(patsubst %,:%,$(sysdep-library-path))))
+			  --library-path $(rpath-link)$(patsubst %,:%,$(sysdep-library-path)))
 else
 run-program-prefix =
 endif
diff --git a/Makerules b/Makerules
index dca9589..1281b94 100644
--- a/Makerules
+++ b/Makerules
@@ -455,17 +455,6 @@ $(LINK.o) -shared $(static-libgcc) -Wl,-O1 $(sysdep-LDFLAGS) \
 	  -L$(subst :, -L,$(rpath-link)) -Wl,-rpath-link=$(rpath-link)
 endef
 
-# Build libc_ifunc.so with the same soname as libc.so.
-define build-shlib-ifunc-helper
-$(LINK.o) -shared $(static-libgcc) -Wl,-O1 $(sysdep-LDFLAGS) \
-	  $(if $($(@F)-no-z-defs)$(no-z-defs),,-Wl,-z,defs) $(config-LDFLAGS) \
-	  $(extra-B-$(@F:lib%.so=%).so) -B$(csu-objpfx) \
-	  $(extra-B-$(@F:lib%.so=%).so) $(load-map-file) \
-	  -Wl,-soname=libc.so$(libc.so-version) \
-	  $(LDFLAGS.so) $(LDFLAGS-$(@F:lib%.so=%).so) \
-	  -L$(subst :, -L,$(rpath-link)) -Wl,-rpath-link=$(rpath-link)
-endef
-
 ifeq (yes,$(use-default-link))
 # If the linker is good enough, we can let it use its default linker script.
 shlib-lds =
@@ -515,11 +504,6 @@ $(build-shlib-helper) -o $@ $(shlib-lds-flags) \
 	  $(csu-objpfx)abi-note.o $(build-shlib-objlist)
 endef
 
-define build-shlib-ifunc
-$(build-shlib-ifunc-helper) -o $@ $(shlib-lds-flags) \
-	  $(csu-objpfx)abi-note.o $(build-shlib-objlist)
-endef
-
 define build-module-helper
 $(LINK.o) -shared $(static-libgcc) $(sysdep-LDFLAGS) $(config-LDFLAGS) \
 	  $(if $($(@F)-no-z-defs)$(no-z-defs),,-Wl,-z,defs) \
@@ -562,9 +546,6 @@ LDFLAGS-c.so += -e __libc_main
 ifeq ($(bind-now),yes)
 LDFLAGS-c.so += -Wl,-z,now
 endif
-# Build libbc_ifunc.so the same way as libc.so.
-LDFLAGS-c_ifunc.so = $(LDFLAGS-c.so)
-LDLIBS-c_ifunc.so = $(LDLIBS-c.so)
 # Pre-link the objects of libc_pic.a so that we can locally resolve
 # COMMON symbols before we link against ld.so.  This is because ld.so
 # contains some of libc_pic.a already, which will prevent the COMMONs
@@ -597,25 +578,14 @@ $(common-objpfx)libc.so: $(elfobjdir)/soinit.os \
 			 $(elfobjdir)/interp.os $(elfobjdir)/ld.so \
 			 $(shlib-lds)
 	$(build-shlib)
-$(common-objpfx)libc_ifunc.so: $(elfobjdir)/soinit.os \
-			       $(common-objpfx)libc_pic.os$(libc_pic_clean) \
-			       $(common-objpfx)string/libc-func.os \
-			       $(elfobjdir)/sofini.os \
-			       $(elfobjdir)/interp.os $(elfobjdir)/ld.so \
-			       $(shlib-lds)
-	$(build-shlib-ifunc)
 ifeq ($(versioning),yes)
 $(common-objpfx)libc.so: $(common-objpfx)libc.map
-$(common-objpfx)libc_ifunc.so: $(common-objpfx)libc_ifunc.map
 endif
 common-generated += libc.so libc_pic.os
 ifdef libc.so-version
 $(common-objpfx)libc.so$(libc.so-version): $(common-objpfx)libc.so
 	$(make-link)
 common-generated += libc.so$(libc.so-version)
-$(common-objpfx)string/libc.so$(libc.so-version): $(common-objpfx)libc_ifunc.so
-	$(make-link)
-common-generated += string/libc.so$(libc.so-version)
 endif
 endif
 
diff --git a/Rules b/Rules
index 93c9163..ccc003e 100644
--- a/Rules
+++ b/Rules
@@ -84,10 +84,7 @@ common-generated += dummy.o dummy.c
 # This makes all the auxiliary and test programs.
 
 .PHONY: others tests
-ifeq ($(multi-arch),yes)
-binaries-ifunc-tests = $(tests-ifunc) $(xtests-ifunc)
-else
-binaries-ifunc-tests =
+ifneq ($(multi-arch),yes)
 tests := $(filter-out $(tests-ifunc), $(tests))
 xtests := $(filter-out $(xtests-ifunc), $(xtests))
 endif
@@ -131,18 +128,7 @@ binaries-static =
 binaries-pie =
 endif
 
-ifeq ($(multi-arch),yes)
-binaries-static-ifunc-tests = $(filter $(binaries-ifunc-tests), \
-				       $(binaries-static-tests))
-binaries-shared-ifunc-tests = $(filter-out $(binaries-static-ifunc-tests), \
-					   $(binaries-ifunc-tests))
-else
-binaries-static-ifunc-tests =
-binaries-shared-ifunc-tests =
-endif
-
-binaries-shared-tests = $(filter-out $(binaries-pie) $(binaries-static) \
-					$(binaries-ifunc-tests), \
+binaries-shared-tests = $(filter-out $(binaries-pie) $(binaries-static), \
 				     $(binaries-all-tests))
 binaries-shared-notests = $(filter-out $(binaries-pie) $(binaries-static), \
 				       $(binaries-all-notests))
@@ -161,13 +147,6 @@ $(addprefix $(objpfx),$(binaries-shared-tests)): %: %.o \
 	$(+link-tests)
 endif
 
-ifneq "$(strip $(binaries-shared-ifunc-tests))" ""
-$(addprefix $(objpfx),$(binaries-shared-ifunc-tests)): %: %.o \
-  $(sort $(filter $(common-objpfx)string/lib%, $(link-libc-ifunc))) \
-  $(addprefix $(csu-objpfx),start.o) $(+preinit) $(+postinit)
-	$(+link-ifunc-tests)
-endif
-
 ifneq "$(strip $(binaries-pie))" ""
 $(addprefix $(objpfx),$(binaries-pie)): %: %.o \
   $(sort $(filter $(common-objpfx)lib%,$(link-libc))) \
@@ -189,13 +168,6 @@ $(addprefix $(objpfx),$(binaries-static-tests)): %: %.o \
 	$(+link-static-tests)
 endif
 
-ifneq "$(strip $(binaries-static-ifunc-tests))" ""
-$(addprefix $(objpfx),$(binaries-static-ifunc-tests)): %: %.o \
-  $(sort $(filter $(common-objpfx)lib%,$(link-libc-static-ifunc-tests))) \
-  $(addprefix $(csu-objpfx),start.o) $(+preinit) $(+postinit)
-	$(+link-static-ifunc-tests)
-endif
-
 ifeq ($(build-bounded),yes)
 binaries-bounded = $(addsuffix -bp,$(tests) $(xtests) $(test-srcs))
 $(addprefix $(objpfx),$(binaries-bounded)): %-bp: %.ob \
diff --git a/scripts/versions.awk b/scripts/versions.awk
index dc0c665..22b1c8e 100644
--- a/scripts/versions.awk
+++ b/scripts/versions.awk
@@ -41,12 +41,8 @@ BEGIN {
 /^[a-zA-Z0-9_.]+/ {
   actlib = $1;
   if (!libs[$1]) {
-    if ($1 == "libc_ifunc")
-      libs[$1] = 1;
-    else {
-      printf("no versions defined for %s\n", $1) > "/dev/stderr";
-      ++lossage;
-    }
+    printf("no versions defined for %s\n", $1) > "/dev/stderr";
+    ++lossage;
   }
   next;
 }
@@ -107,10 +103,6 @@ END {
   oldver = "";
   printf("version-maps =");
   while (getline < tmpfile) {
-    if ($1 == "libc_ifunc") {
-      printf(" %s.map", $1);
-      continue;
-    }
     if ($1 != oldlib) {
       if (oldlib != "") {
 	closeversion(oldver, veryoldver);
@@ -141,59 +133,5 @@ END {
   printf("\n");
   closeversion(oldver, veryoldver);
   close_and_move(outfile, real_outfile);
-
-  if (libs["libc_ifunc"]) {
-    close (tmpfile);
-    # Generate libc_ifunc.map from libc and libc_ifunc versions.
-    ifuncfile = buildroot "Versions.ifunc";
-    oldlib = "";
-    last_count=1;
-    while (getline < tmpfile) {
-      if ($1 != "libc" && $1 != "libc_ifunc") {
-	if (oldlib == "libc_ifunc")
-	  break;
-	continue;
-      }
-      sub(/^libc_ifunc/,"libc",$0)
-      oldlib = "libc_ifunc";
-      # Ensure GLIBC_ versions come always first.
-      if ($2 !~ /^GLIBC/) {
-	last_versions[last_count] = $0;
-	last_count++;
-      }
-      else
-	printf("%s\n", $0) > ifuncfile;
-    }
-    for (n = 1; n < last_count; n++)
-      printf("%s\n", last_versions[n]) > ifuncfile;
-    close (ifuncfile);
-    oldlib = "";
-    oldver = "";
-    while (getline < ifuncfile) {
-      if (oldlib == "") {
-	oldlib = "libc_ifunc";
-	real_outfile = buildroot oldlib ".map";
-	outfile = real_outfile "T";
-	firstinfile = 1;
-	veryoldver = "";
-      }
-      if ($2 != oldver) {
-	if (oldver != "") {
-	  closeversion(oldver, veryoldver);
-	  veryoldver = oldver;
-	}
-	printf("%s {\n  global:\n", $2) > outfile;
-	oldver = $2;
-      }
-      printf("   ") > outfile;
-      for (n = 3; n <= NF; ++n) {
-	printf(" %s", $n) > outfile;
-      }
-      printf("\n") > outfile;
-    }
-    printf("\n");
-    closeversion(oldver, veryoldver);
-    close_and_move(outfile, real_outfile);
-  }
   #system("rm -f " tmpfile);
 }
diff --git a/string/Makefile b/string/Makefile
index 17ae4be..76e83dc 100644
--- a/string/Makefile
+++ b/string/Makefile
@@ -20,6 +20,8 @@
 #
 subdir	:= string
 
+include ../Makeconfig
+
 headers	:= string.h strings.h memory.h endian.h bits/endian.h \
 	   argz.h envz.h byteswap.h bits/byteswap.h bits/byteswap-16.h \
 	   bits/string.h bits/string2.h bits/string3.h
@@ -41,6 +43,10 @@ routines	:= strcat strchr strcmp strcoll strcpy strcspn		\
 		   strcoll_l strxfrm_l string-inlines memrchr		\
 		   xpg-strerror strerror_l
 
+ifeq ($(multi-arch),yes)
+routines	+= libc-func
+endif
+
 # Gcc internally generates calls to unbounded memcpy and memset
 # for -fbounded-pointer compiles.  Glibc uses memchr for explicit checks.
 o-objects.ob	:= memcpy.o memset.o memchr.o
diff --git a/string/Versions b/string/Versions
index be68a9d..24c77f2 100644
--- a/string/Versions
+++ b/string/Versions
@@ -80,12 +80,10 @@ libc {
   GLIBC_2.6 {
     strerror_l;
   }
-}
 
 %ifdef USE_MULTIARCH
-libc_ifunc {
   GLIBC_PRIVATE {
     __libc_func;
   }
-}
 %endif
+}

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog.test-ifunc |   28 +++++++++++++++++++++
 Makeconfig           |   19 +-------------
 Makerules            |   30 ----------------------
 Rules                |   32 +----------------------
 scripts/versions.awk |   66 +------------------------------------------------
 string/Makefile      |    6 ++++
 string/Versions      |    4 +--
 7 files changed, 40 insertions(+), 145 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


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