diff options
-rw-r--r-- | testsuite/systemtap.maps/hist_in_string.exp | 8 | ||||
-rw-r--r-- | testsuite/systemtap.maps/hist_in_string.stp | 10 |
2 files changed, 18 insertions, 0 deletions
diff --git a/testsuite/systemtap.maps/hist_in_string.exp b/testsuite/systemtap.maps/hist_in_string.exp new file mode 100644 index 00000000..02f201af --- /dev/null +++ b/testsuite/systemtap.maps/hist_in_string.exp @@ -0,0 +1,8 @@ +# test histogram printed to string + +set test "hist_in_string" +set ::result_string {value |-------------------------------------------------- count + 0 |@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ 128 +} + +stap_run2 $srcdir/$subdir/$test.stp diff --git a/testsuite/systemtap.maps/hist_in_string.stp b/testsuite/systemtap.maps/hist_in_string.stp new file mode 100644 index 00000000..f9d0e81a --- /dev/null +++ b/testsuite/systemtap.maps/hist_in_string.stp @@ -0,0 +1,10 @@ +global l + +probe begin +{ + for (i = 0; i < 128; i++) + l <<< 0 + + print(sprint(@hist_linear(l, 0, 0, 1))) + exit() +} |