summaryrefslogtreecommitdiffstats
path: root/testsuite/systemtap.base/timers.stp
diff options
context:
space:
mode:
authorhunt <hunt>2006-09-28 19:42:05 +0000
committerhunt <hunt>2006-09-28 19:42:05 +0000
commit74948c250560f0b8e6580104c36730dc64eb2e86 (patch)
tree40a1f340bdd9ce5aa4c48ad7251eab1e595e0a8f /testsuite/systemtap.base/timers.stp
parente38a2092c71ac4c8d0f887dba56c55124ebe0db4 (diff)
downloadsystemtap-steved-74948c250560f0b8e6580104c36730dc64eb2e86.tar.gz
systemtap-steved-74948c250560f0b8e6580104c36730dc64eb2e86.tar.xz
systemtap-steved-74948c250560f0b8e6580104c36730dc64eb2e86.zip
Better output for debugging.
Diffstat (limited to 'testsuite/systemtap.base/timers.stp')
-rw-r--r--testsuite/systemtap.base/timers.stp42
1 files changed, 21 insertions, 21 deletions
diff --git a/testsuite/systemtap.base/timers.stp b/testsuite/systemtap.base/timers.stp
index 9f370e74..8b990aab 100644
--- a/testsuite/systemtap.base/timers.stp
+++ b/testsuite/systemtap.base/timers.stp
@@ -10,7 +10,7 @@ global ms1, ms500, msmax
probe begin
{
- log("systemtap starting probe")
+ printf("systemtap starting probe\n")
}
probe timer.profile { ++p }
@@ -27,47 +27,47 @@ probe timer.ms(1000000) { ++msmax }
probe end
{
- log("systemtap ending probe")
- log("p = " . sprint(p))
- log("j1 = " . sprint(j1))
- log("j2 = " . sprint(j2))
- log("jmax = " . sprint(jmax))
- log("ms1 = " . sprint(ms1))
- log("ms500 = " . sprint(ms500))
- log("msmax = " . sprint(msmax))
+ printf("systemtap ending probe\n")
+ printf("p = %d\n", p)
+ printf("j1 = %d\n", j1)
+ printf("j2 = %d\n", j2)
+ printf("jmax = %d\n", jmax)
+ printf("ms1 = %d\n", ms1)
+ printf("ms500 = %d\n", ms500)
+ printf("msmax = %d\n", msmax)
/* profile counter should be non-zero, and at
* least as many as the jiffies(1) counter */
if ((p > 0) && (p >= j1)) {
- log("systemtap test success")
+ printf("systemtap test success\n")
} else {
- log("unexpected profile count")
- log("systemtap test failure");
+ printf("unexpected profile count: %d profiles and %d jiffies\n", p, j1)
+ printf("systemtap test failure\n");
}
/* jiffies(1) should count more than jiffies(2),
* and both should be non-zero. */
if ((j2 > 0) && (j2 < j1)) {
- log("systemtap test success")
+ printf("systemtap test success\n")
} else {
- log("unexpected jiffies count")
- log("systemtap test failure");
+ printf("unexpected jiffies count\n")
+ printf("systemtap test failure\n");
}
/* ms(1) should count more than ms(500),
* and both should be non-zero. */
if ((ms500 > 0) && (ms500 < ms1)) {
- log("systemtap test success")
+ printf("systemtap test success\n")
} else {
- log("unexpected ms count")
- log("systemtap test failure");
+ printf("unexpected ms count\n")
+ printf("systemtap test failure\n");
}
/* both 'infinite' intervals should register zero counts */
if ((jmax == 0) && (msmax == 0)) {
- log("systemtap test success")
+ printf("systemtap test success\n")
} else {
- log("unexpected count on 'infinite' interval")
- log("systemtap test failure");
+ printf("unexpected count on 'infinite' interval\n")
+ printf("systemtap test failure\n");
}
}