about summary refs log tree commit diff
path: root/sysdeps
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-09-10 08:14:03 +0000
committerUlrich Drepper <drepper@redhat.com>2000-09-10 08:14:03 +0000
commit2119c7059e593c336a916ca542583b0da7222960 (patch)
treef7fcd7084f895dead0ea43a76e2df0f316481cd9 /sysdeps
parentada0ce8f414c34001e632c57af326458cc1917f4 (diff)
downloadglibc-2119c7059e593c336a916ca542583b0da7222960.tar.gz
glibc-2119c7059e593c336a916ca542583b0da7222960.tar.xz
glibc-2119c7059e593c336a916ca542583b0da7222960.zip
Update.
2000-09-10  Ulrich Drepper  <drepper@redhat.com>

	* shlib-versions: Simplify libm entries.  Correct a few Hurd entries.

	* sysdeps/generic/initfini.c: Rewrite slightly to get rid of the
	ugly GMON_WEAK_START hack.
	Patch by Philip Blundell <philb@gnu.org>.

	* sysdeps/i386/i486/bits/string.h: Pretty printing.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/generic/initfini.c33
-rw-r--r--sysdeps/i386/i486/bits/string.h2
2 files changed, 12 insertions, 23 deletions
diff --git a/sysdeps/generic/initfini.c b/sysdeps/generic/initfini.c
index 4c43941ad0..836d606cfd 100644
--- a/sysdeps/generic/initfini.c
+++ b/sysdeps/generic/initfini.c
@@ -61,6 +61,16 @@ asm ("\n/*@TESTS_END*/");
 /* The beginning of _init:  */
 asm ("\n/*@_init_PROLOG_BEGINS*/");
 
+static void
+call_gmon_start(void)
+{
+  extern void __gmon_start__ (void) __attribute__ ((weak)); /*weak_extern (__gmon_start__);*/
+  void (*gmon_start) (void) = __gmon_start__;
+
+  if (gmon_start)
+    gmon_start ();  
+}
+
 SECTION (".init");
 void
 _init (void)
@@ -71,15 +81,7 @@ _init (void)
      gcrt1.o to reference a symbol which would be defined by some library
      module which has a constructor; but then user code's constructors
      would come first, and not be profiled.  */
-  extern void __gmon_start__ (void) __attribute__ ((weak)); /*weak_extern (__gmon_start__);*/
-#ifndef WEAK_GMON_START
-  __gmon_start__ ();
-#else
-  void (*gmon_start) (void) = __gmon_start__;
-
-  if (gmon_start)
-    gmon_start ();
-#endif
+  call_gmon_start ();
 
   asm ("ALIGN");
   asm("END_INIT");
@@ -89,19 +91,6 @@ _init (void)
   SECTION(".init");
 }
 asm ("END_INIT");
-#ifndef WEAK_GMON_START
-SECTION(".text");
-
-/* This version of __gmon_start__ is used if no other is found.  By providing
-   a default function we avoid the need to test whether the pointer is NULL,
-   which can be painful on some machines.  */
-
-void __attribute__ ((weak))
-__gmon_start__ (void)
-{
-  /* do nothing */
-}
-#endif
 
 /* End of the _init epilog, beginning of the _fini prolog. */
 asm ("\n/*@_init_EPILOG_ENDS*/");
diff --git a/sysdeps/i386/i486/bits/string.h b/sysdeps/i386/i486/bits/string.h
index b60807286c..9d88ee3149 100644
--- a/sysdeps/i386/i486/bits/string.h
+++ b/sysdeps/i386/i486/bits/string.h
@@ -113,7 +113,7 @@ __memcpy_by2 (void *__dest, __const void *__src, size_t __n)
 __STRING_INLINE void *__memcpy_g (void *__dest, __const void *__src,
 				  size_t __n);
 
-     __STRING_INLINE void *
+__STRING_INLINE void *
 __memcpy_g (void *__dest, __const void *__src, size_t __n)
 {
   register unsigned long int __d0, __d1, __d2;