diff options
author | wenji <wjhuang@dhcp-beijing-cdc-10-182-120-233.cn.oracle.com> | 2008-04-13 22:50:18 -0400 |
---|---|---|
committer | wenji <wjhuang@dhcp-beijing-cdc-10-182-120-233.cn.oracle.com> | 2008-04-13 22:50:18 -0400 |
commit | bd10b81c06a0102ac10617da2f368fcc168fc15e (patch) | |
tree | 07c4878e3eaf77801d5104c2f6c498cfff9e3bbd /testsuite/systemtap.context/backtrace.stp | |
parent | d58c66bfef5cfa7267ced03db11928fd5c78ba9c (diff) | |
parent | f7e07777e033e580351dc6886ab7dbdddd9839fe (diff) | |
download | systemtap-steved-bd10b81c06a0102ac10617da2f368fcc168fc15e.tar.gz systemtap-steved-bd10b81c06a0102ac10617da2f368fcc168fc15e.tar.xz systemtap-steved-bd10b81c06a0102ac10617da2f368fcc168fc15e.zip |
Merge branch 'master' of ssh://wenji@sources.redhat.com/git/systemtap
Diffstat (limited to 'testsuite/systemtap.context/backtrace.stp')
-rw-r--r-- | testsuite/systemtap.context/backtrace.stp | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/testsuite/systemtap.context/backtrace.stp b/testsuite/systemtap.context/backtrace.stp index c14d071c..ddd7d00a 100644 --- a/testsuite/systemtap.context/backtrace.stp +++ b/testsuite/systemtap.context/backtrace.stp @@ -1,10 +1,9 @@ -function print_all_trace_info(point:string) { +function print_all_trace_info(point) { printf("backtrace from %s:\n", pp()) print_backtrace() - print("--------\n") + printf("--- %s ---\n", point) bt = backtrace() - printf("the %s stack is %s\n", point, bt) - printf("--<%s>--\n", point) + printf("the stack is %s\n", bt) print_stack(bt); print("--------\n") } @@ -18,18 +17,20 @@ probe end { } global flag = 0 -probe module("systemtap_test_module2").function("yyy_func3").call { - print_all_trace_info("call") + +probe module("systemtap_test_module2").function("yyy_func2") { + print_all_trace_info("yyy_func2") flag ++ } -probe module("systemtap_test_module2").function("yyy_func4").return { - print_all_trace_info("return") + +probe module("systemtap_test_module2").function("yyy_func3") { + print_all_trace_info("yyy_func3") flag ++ } -probe timer.profile { - if (cpu() == 0 && flag == 2 && probemod() != "systemtap_test_module2") { - print_all_trace_info("profile") - flag ++ - } + +probe module("systemtap_test_module2").function("yyy_func4") { + print_all_trace_info("yyy_func4") + flag ++ } + |