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

[PATCH 2/3] io_submit.stp: use an accumulator for traces


On very large systems, we get a lot of skipped probes due to lock
contention on the traces array.  The end result is that we don't
get any data for such systems.  Simply converting the traces array
to an accumulator resolves this issue in testing (on a highly-
loaded 288 cpu system).

Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
---
 testsuite/systemtap.examples/io/io_submit.stp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/testsuite/systemtap.examples/io/io_submit.stp b/testsuite/systemtap.examples/io/io_submit.stp
index c5edd66..62d15c9 100755
--- a/testsuite/systemtap.examples/io/io_submit.stp
+++ b/testsuite/systemtap.examples/io/io_submit.stp
@@ -37,7 +37,7 @@ probe syscall.io_submit.return {
  */
 probe kernel.function("schedule") {
   if (tid() in in_iosubmit) {
-    traces[backtrace()]++
+    traces[backtrace()] <<< 1
 
     /*
      * change this to if (1) if you want a backtrace every time
@@ -59,7 +59,7 @@ probe kernel.function("schedule") {
  */
 probe end {
   foreach (stack in traces- limit 30) {
-    printf("%d:", traces[stack])
+    printf("%d:", @count(traces[stack]))
     print_syms(stack);
   }
 }
-- 
2.8.2.335.g4bb51ae


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