about summary refs log tree commit diff
path: root/elf
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-02-23 19:05:32 +0000
committerUlrich Drepper <drepper@redhat.com>2002-02-23 19:05:32 +0000
commit9836cfe7dbf10e2a1705d1cd49b89ad81c7ff638 (patch)
treebec4f44d38b6dd45e76bd956beb363dd5760ed28 /elf
parent7fec4f2f70d417b858127d340f7e8f66d8053572 (diff)
downloadglibc-9836cfe7dbf10e2a1705d1cd49b89ad81c7ff638.tar.gz
glibc-9836cfe7dbf10e2a1705d1cd49b89ad81c7ff638.tar.xz
glibc-9836cfe7dbf10e2a1705d1cd49b89ad81c7ff638.zip
Update.
	* elf/dl-fini.c (_dl_fini): Print some final statistics on the
	total number of relocations performed.
Diffstat (limited to 'elf')
-rw-r--r--elf/dl-fini.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/elf/dl-fini.c b/elf/dl-fini.c
index 902ce086d9..5beb24b042 100644
--- a/elf/dl-fini.c
+++ b/elf/dl-fini.c
@@ -169,4 +169,15 @@ _dl_fini (void)
 	    ((fini_t) DL_DT_FINI_ADDRESS (l, l->l_addr + l->l_info[DT_FINI]->d_un.d_ptr)) ();
 	}
     }
+
+  if (__builtin_expect (GL(dl_debug_mask) & DL_DEBUG_STATISTICS, 0))
+    {
+      INTUSE(_dl_debug_printf) ("\nruntime linker statistics:\n");
+      INTUSE(_dl_debug_printf) ("\
+           final number of relocations: %lu\n",
+				GL(dl_num_relocations));
+      INTUSE(_dl_debug_printf) ("\
+final number of relocations from cache: %lu\n",
+				GL(dl_num_cache_relocations));
+    }
 }