public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* Segmentation Fault: Task died at uprobe probepoint
@ 2010-06-14  9:18 Gaurav Dhiman
  2010-06-14 12:55 ` Srikar Dronamraju
  2010-06-14 21:06 ` Frank Ch. Eigler
  0 siblings, 2 replies; 19+ messages in thread
From: Gaurav Dhiman @ 2010-06-14  9:18 UTC (permalink / raw)
  To: systemtap

Hi All,

I have recently installed SystemTap on my Ubuntu 9.04 based system. I
have Linux kernel 2.6.29.1 with utrace support (I used the utrace
patch from http://people.redhat.com/roland/utrace/old/2.6.29/) . I
wrote a very simple program to test out the userspace probe
functionality. Here is the stap script I wrote:

probe process("/home/gdhiman/tests/uprobe-test").begin
{
        printf("uprobe-test begin!!\n")
}

probe process("/home/gdhiman/tests/uprobe-test").function("test_func")
{
        printf("test_func called!\n");
        log($$parms);
}

The uprobe-test code is as follows:

int test_func(int i)
{
        printf("%d\n", i);
        return j;
}

int main()
{
        int i;
        i = test_func(5);
        return 0;
}

Then I ran the script as root using stap -v test.stp; it is compiled
and inserted successfully. I see the following message if I do dmesg:
[ 1694.148460] stap_9736f2321b446f9fc03126194f89aac2_1643: systemtap:
1.2/0.131, base: ffffffffa0010000, memory:
136data/29text/10ctx/13net/34alloc kb, probes: 2

However, when i actually run uprobe-test, although both the probes
fire successfully, the task generates a segmentation fault and dies on
the 'test_func' probe. I see the following message on doing dmesg:
[ 1709.650827] Task died at uprobe probepoint:  pid/tgid = 3934/3934,
probepoint = 0x400517

I am not sure why is this happening. Is there something wrong in the
patch I used, or am I making some stupid mistake in programming the
probes? Any insights into what might be happening and how to resolve
the issue would be really helpful.

Thanks in advance,
-Gaurav

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2010-06-22  7:01 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-14  9:18 Segmentation Fault: Task died at uprobe probepoint Gaurav Dhiman
2010-06-14 12:55 ` Srikar Dronamraju
     [not found]   ` <AANLkTilvvj9hdiaa9VWjO0j-jK02LMweg5cAEBgoLyRK@mail.gmail.com>
2010-06-15  9:11     ` Gaurav Dhiman
2010-06-15 17:46       ` Mark Wielaard
2010-06-16 13:54         ` Gaurav Dhiman
2010-06-16 19:05           ` Frank Ch. Eigler
2010-06-22  8:57             ` Gaurav Dhiman
2010-06-22 10:36               ` Roland McGrath
2010-06-22 13:05                 ` Gaurav Dhiman
2010-06-22 13:11                   ` Roland McGrath
2010-06-22 13:12                     ` Gaurav Dhiman
2010-06-15 18:17     ` Srikar Dronamraju
2010-06-16 14:19       ` Gaurav Dhiman
2010-06-14 21:06 ` Frank Ch. Eigler
2010-06-15  9:24   ` Gaurav Dhiman
2010-06-15 10:39     ` Frank Ch. Eigler
2010-06-15 12:25       ` Gaurav Dhiman
2010-06-15 18:07         ` Mark Wielaard
2010-06-16 14:08           ` Gaurav Dhiman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).