This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: Generic test suite failures found with ARM testing
On Thu, Jun 14, 2007 at 10:42:27AM -0400, Martin Hunt wrote:
On Thu, 2007-06-14 at 09:11 -0500, David Smith wrote:
Quentin Barnes wrote:
> I've run across two test failures on ARM that are not ARM-specific. They
> are with systemtap.samples/profile.exp and systemtap.samples/syscalls2.exp.
> These tests fail for me because of the 128 character limit on strings.
>
> For example, with profile.exp the output being looked for is truncated:
> staprun(4619)
> kernel.function("sys_poll@/proj/cost/work/qbarnes/kprobes/work/usr/src/linux-2.6.21.4/fs/select.c:742").call
> coun^M
The reason why we haven't noticed this problem is that you are evidently
compiling your kernel differently than we are.
Somebody doing something previously untried is often a good source of
new bugs. :-)
I've seen this before. It happens if you use "make O=output/dir" to
build your kernel.
Ah, ha!
In the log, sometimes I was getting "short" names and sometimes I
was getting "long" names. I never figured out why. That's the
missing piece. Most of the time I build with O=... giving me the
long names, but sometimes I would build in place giving me the short
names.
I believe the following patch will fix the problem by removing the
strcats. If this works for you I'll check it in.
diff -u -p -r1.2 profile.stp
--- testsuite/systemtap.samples/profile.stp 2 Apr 2007 20:30:30
-0000 1.2
+++ testsuite/systemtap.samples/profile.stp 14 Jun 2007 14:10:01 -0000
@@ -30,9 +30,9 @@ probe timer.ms(5000) {
}
probe end {
foreach ([pid,syscall] in syscall_count-) {
- log (command[pid] . "(" . sprint(pid) . ") " . syscall .
- " count=" . sprint(syscall_count[pid,syscall]) .
- " ttime=" . sprint(syscall_times[pid,syscall]))
+ printf("%s(%d) %s count=%d ttime=%d\n", command[pid], pid, syscall,
+ syscall_count[pid,syscall], syscall_times[pid,syscall])
+
if (count++ > 30) next
}
}
It worked!
I think removing all uses of the dot concatenation operator would be a
good idea. Maybe keep a specific testcase around for backwards
compatibility.
Probably...
Martin
Quentin