From 814bc89d4635f101b2c0077598f31aad95ed15b7 Mon Sep 17 00:00:00 2001 From: fche Date: Sat, 12 Aug 2006 05:13:09 +0000 Subject: 2006-08-12 Frank Ch. Eigler * configure.ac, Makefile.am: Descend into testsuite/ directory. Remove local test logic. * configure, Makefile.in: Regenerated. * runtest.sh: Not yet removed. * HACKING: Update for new testsuite layout. 2006-08-12 Frank Ch. Eigler * all: Reorganized old pass-1..4 tests one dejagnu bucket. Moved over old pass-5 tests, except for disabled syscalls tests. * Makefile (installcheck): New target for running pass-1..5 tests against installed systemtap. --- testsuite/systemtap.samples/kmalloc-stacks.stp | 35 ++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 testsuite/systemtap.samples/kmalloc-stacks.stp (limited to 'testsuite/systemtap.samples/kmalloc-stacks.stp') diff --git a/testsuite/systemtap.samples/kmalloc-stacks.stp b/testsuite/systemtap.samples/kmalloc-stacks.stp new file mode 100644 index 00000000..25a23f2d --- /dev/null +++ b/testsuite/systemtap.samples/kmalloc-stacks.stp @@ -0,0 +1,35 @@ +global kmalloc_stack + +function reset_maxaction () %{ + if (CONTEXT && CONTEXT->actioncount) + CONTEXT->actioncount=0; +%} + +function write_output() +{ + foreach (stack in kmalloc_stack) { + log(""); + print_stack(stack); + log(""); + print(""); + print(sprint(kmalloc_stack[stack])); + log(""); + reset_maxaction(); + } +} + +probe timer.jiffies(5000) +{ + write_output(); + delete kmalloc_stack; +} + +probe kernel.function("__kmalloc") +{ + kmalloc_stack[backtrace()]++; +} + +probe end +{ + write_output(); +} -- cgit