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]

Re: PR3498: more efficient dwfl searching


Josh Stone wrote:
On 07/15/2009 02:18 AM, Wenji Huang wrote:
Wenji Huang wrote:
I found one regression since this commit.

$ stap -l nfsd.create*
Segmentation fault
[78375.044067] <6>stap[24911]: segfault at 0 ip 0000000000480efb sp 00007ffffe706400 error 4 in stap[400000+142000]

Works for me -- can you provide more details about your configuration?

Related config. CONFIG_NFSD=y # CONFIG_NFSD_V3 is not set

Another test case
$ stap -p2 -e 'probe a2=module("no module").function("no_func")? {} probe a1=kernel.function("sys_read")?, module("no module").function("a")? {} probe a* {}'
Segmentation fault


This can be reproduced on self-built kernel x86/x86_64, elfutils 0.141/0.137. But it's strange that it works well on FC11, the distributed kernel. And output
Missing separate debuginfos, use: debuginfo-install kernel-PAE-2.6.29.4-167.fc11.i686
It should not be possible for dw to come out NULL, so I would rather not
paper over this.  Can you root cause how this happened?

Did deep investigation, Seems the culprit is the segment in dwflpp::setup_kernel.
...
if (! offline_search_match_p)
{
if (debuginfo_needed) {
// Suggest a likely kernel dir to find debuginfo rpm for
string dir = string("/lib/modules/" + sess.kernel_release );
find_debug_rpms(sess, dir.c_str());
}
throw semantic_error (string("missing ") + sess.architecture +
string(" kernel/module debuginfo under '") +
sess.kernel_build_tree + string("'"));
}
...
For example, "no module" doesn't exit, there will be error thrown and
dwflpp::dwflpp{setup_kernel} constructor procedure can't be completely finished. But stap will tolerate such kind of error for optional probe and regard the structure is well formatted. So the searched dw from get_kern_dw isn't in good shape.


Regards,
Wenji


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