This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Probingof syscall.*.return fails


Hi,

I try to figure out what syscalls fail, while running a certain process.

I run the following script:

function is_err:long(ret:long) {
    return ret < 0 && ret > -4096
}

probe syscall.*.return {
    if (target() == pid())
    {
	ret = returnval()
	if (is_err (ret))
	    printf ("syscall %s failed with %d\n", name, -ret)
    }
}

with:
stap -v -c df -o df.errno-trace minimal.stp

The script hangs at step 5:

Pass 1: parsed user script and 43 library script(s) in 270usr/20sys/298real ms.
Pass 2: analyzed script: 313 probe(s), 4 function(s), 15 embed(s), 0
global(s) in 1350usr/2480sys/4058real ms.
Pass 3: translated to C into
"/tmp/stapXm12Yx/stap_bd8e59632324008043fe1841dc788df7_131223.c" in
250usr/430sys/697real ms.
Pass 4: compiled C into
"stap_bd8e59632324008043fe1841dc788df7_131223.ko" in
6340usr/2760sys/9733real ms.
Pass 5: starting run.

I running systemtap 0.7 under Fedora 8 on
Linux localhost.localdomain 2.6.25.14-69.fc8 #1 SMP Mon Aug 4 14:20:24
EDT 2008 i686 i686 i386 GNU/Linux
in a VM (VirtualBox 2.0.0)

I also tested a version with a C-Implementation of is_err (using
IS_ERR_VALUE). But this crashes the VM (not only the kernel)
completely at step 5.

Do you have any suggestions how to probe syscall.*.return?

Thanks,
        Martin SÃÃkraut

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]