This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: [BUG] syscall.unlink no longer works after upgrading kernel to 3.7.3
- From: Zheng Da <zhengda1936 at gmail dot com>
- To: Josh Stone <jistone at redhat dot com>
- Cc: Mark Wielaard <mjw at redhat dot com>, agentzh <agentzh at gmail dot com>, "systemtap at sourceware dot org" <systemtap at sourceware dot org>
- Date: Tue, 28 May 2013 14:52:48 -0400
- Subject: Re: [BUG] syscall.unlink no longer works after upgrading kernel to 3.7.3
- References: <CAB4Tn6PdW3GOa09z_tfjQs=F+7XLOqMr5+c5GourX5e0v8FMeQ at mail dot gmail dot com> <1360054656 dot 3837 dot 13 dot camel at bordewijk dot wildebeest dot org> <51114188 dot 60400 at redhat dot com>
Hello,
I think I got a very similar error in Ubuntu:
semantic error: not accessible at this address [man error::dwarf]
(0xffffffff81480e80, dieoffset: 0x43d730b): identifier '$sdev' at
:10:6
source: if ($sdev->host->host_no == 9 && $sdev->id == 1) {
^
I use Linux v3.8.12, and gcc version is 4.6.3.
Is there any better fix for this problem? I checked the workaround for
perf, but I don't know how to apply it to systemtap.
Thanks,
Da
On Tue, Feb 5, 2013 at 12:29 PM, Josh Stone <jistone@redhat.com> wrote:
> On 02/05/2013 12:57 AM, Mark Wielaard wrote:
>> Perf seems to have a workaround for this issue:
>> https://lkml.org/lkml/2012/10/3/187
>>
>> + if (fentry && (dwarf_tag(vr_die) == DW_TAG_formal_parameter) &&
>> + (dwarf_getlocation_addr(&attr, addr, &op, &nops, 1) == 0))
>> + /*
>> + * Workaround: GCC -mfentry option generates odd
>> + * variable location entries which start from a
>> + * function entry+5, even if it is a formal_parameter.
>> + * On the other hand, for functions without fentry call
>> + * (e.g. notrace function), the formal_parameter location
>> + * starts from the function entry address.
>> + * Here, if we find a formal_parameter which doesn't
>> + * start from the function entry, but from function
>> + * entry+5, it should be a buggy entry.
>> + * We forcibly get the variable(parameter) location
>> + * information from entry+5.
>> + */
>> + addr += 5;
>>
>> That seems a little crude, but maybe we can do something like that in
>> systemtap too with some special flag?
>
> Aha! Frank and I were just talking about workarounds for this
> yesterday, and what perf has done here is pretty much what I had in
> mind. The offset +5 is very arch-specific, of course, for an x86 call.
>
> The other relevant bug is on Fedora's gcc:
> https://bugzilla.redhat.com/show_bug.cgi?id=896741
>
> As soon as the upstream gcc fix is confirmed and backported to Fedora,
> we'll get the kernel folks to spin a new build on it. In the meantime
> though, I wouldn't mind a heuristic similar to perf's.