summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog3
-rw-r--r--translate.cxx24
2 files changed, 11 insertions, 16 deletions
diff --git a/ChangeLog b/ChangeLog
index 97f08dde..2ec18711 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2008-01-14 Martin Hunt <hunt@redhat.com>
+ * translate.cxx (emit_module_init): Call _stp_print_kernel_info()
+ to print out version information and internal memory usage stats.
+2008-01-14 Martin Hunt <hunt@redhat.com>
* translate.cxx (emit_module_exit): When using timing, delete timing
stats when finished.
diff --git a/translate.cxx b/translate.cxx
index 874e9dc1..7f42ceec 100644
--- a/translate.cxx
+++ b/translate.cxx
@@ -1,5 +1,5 @@
// translation pass
-// Copyright (C) 2005-2007 Red Hat Inc.
+// Copyright (C) 2005-2008 Red Hat Inc.
// Copyright (C) 2005-2007 Intel Corporation.
//
// This file is part of systemtap, and is free software. You can
@@ -1148,21 +1148,13 @@ c_unparser::emit_module_init ()
// Print a message to the kernel log about this module. This is
// intended to help debug problems with systemtap modules.
- o->newline() << "printk (KERN_DEBUG \"%s: "
- << "systemtap: " << VERSION << "/" << dwfl_version (NULL)
- << ", base: %p"
- << ", memory: %lu+%lu+%lu+%lu+%lu data+text+ctx+io+glob"
- << ", probes: " << session->probes.size()
- << "\\n\""
- // printk arguments
- << ", THIS_MODULE->name"
- << ", THIS_MODULE->module_core"
- << ", (unsigned long) (THIS_MODULE->core_size - THIS_MODULE->core_text_size)"
- << ", (unsigned long) THIS_MODULE->core_text_size"
- << ", (unsigned long) (num_online_cpus() * sizeof(struct context))"
- << ", (unsigned long) _stp_allocated_net_memory"
- << ", (unsigned long) _stp_allocated_memory"
- << ");";
+
+ o->newline() << "_stp_print_kernel_info("
+ << "\"" << VERSION
+ << "/" << dwfl_version (NULL) << "\""
+ << ", (num_online_cpus() * sizeof(struct context))"
+ << ", " << session->probes.size()
+ << ");";
// Run all probe registrations. This actually runs begin probes.