This is the mail archive of the libc-alpha@sources.redhat.com 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]

Re: Why does sysdeps/generic/dl-cache.c check _DL_PLATFORMS_COUNT?


>>>>> H J Lu writes:

 > _DL_PLATFORMS_COUNT is only defined in
 > sysdeps/unix/sysv/linux/i386/dl-procinfo.h. I don't see why it is
 > necessary. Right now, glibc won't build on any none-x86 platforms.
 > Here is a patch.

I prefer this version of the patch - this way the check in dl-cache.c
can be optimized away by the compiler for platforms that don't use it.

Uli, your decision which one should be applied - but I agree with HJ:
One should be applied asap,
Andreas

2000-11-16  Andreas Jaeger  <aj@suse.de>

	* sysdeps/generic/dl-procinfo.h (_DL_PLATFORMS_COUNT): Added.
	* sysdeps/unix/sysv/linux/sparc/sparc32/dl-procinfo.h
	(_DL_PLATFORMS_COUNT): Likewise.
	* sysdeps/unix/sysv/linux/sparc/sparc64/dl-procinfo.h
	(_DL_PLATFORMS_COUNT): Likewise.

============================================================
Index: sysdeps/generic/dl-procinfo.h
--- sysdeps/generic/dl-procinfo.h	2000/11/15 08:45:53	1.5
+++ sysdeps/generic/dl-procinfo.h	2000/11/16 06:43:36
@@ -39,6 +39,9 @@
 /* We don't have any hardware capabilities.  */
 #define _DL_HWCAP_COUNT 0
 
+/* All platforms are the same.  */
+#define _DL_PLATFORMS_COUNT  0
+
 #define _dl_string_hwcap(str) (-1)
 
 #define _dl_string_platform(str) (-1)
============================================================
Index: sysdeps/unix/sysv/linux/sparc/sparc32/dl-procinfo.h
--- sysdeps/unix/sysv/linux/sparc/sparc32/dl-procinfo.h	2000/11/15 08:44:38	1.3
+++ sysdeps/unix/sysv/linux/sparc/sparc32/dl-procinfo.h	2000/11/16 06:43:36
@@ -74,6 +74,9 @@
 /* There're no platforms to filter out.  */
 #define _DL_HWCAP_PLATFORM 0
 
+/* All platforms are the same.  */
+#define _DL_PLATFORMS_COUNT  0
+
 #define _dl_string_platform(str) (-1)
 
 #endif /* dl-procinfo.h */
============================================================
Index: sysdeps/unix/sysv/linux/sparc/sparc64/dl-procinfo.h
--- sysdeps/unix/sysv/linux/sparc/sparc64/dl-procinfo.h	2000/11/15 08:44:38	1.3
+++ sysdeps/unix/sysv/linux/sparc/sparc64/dl-procinfo.h	2000/11/16 06:43:37
@@ -75,6 +75,9 @@
 /* There're no platforms to filter out.  */
 #define _DL_HWCAP_PLATFORM 0
 
+/* All platforms are the same.  */
+#define _DL_PLATFORMS_COUNT  0
+
 #define _dl_string_platform(str) (-1)
 
 #endif /* dl-procinfo.h */

-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

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