Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [linuxtools-dev] perf probe & SW event duration


Hi danie,
 
Appreciated for your help. I tried to install all the elfutils packages, but it not work to me.
 
my perf version is perf version 2.6.32-358.0.1.el6.x86_64.debug , and my kernel is 3.8.4.
 
I get some help from other people, and then i can now "perf probe" some kernel symbol, like : do_sys_open, but when i want to perf probe other symbol, like some symbol in "/proc/kallsyms", it turn out some error:
"perf probe do_page_fault":
Added new event:
Failed to write event: Invalid argument
Error: Failed to add events. (-1)
And when i type perf probe page_fault_entry:
Kernel symbol 'page_fault_entry' not found.
Error: Failed to add events. (-2)
 
Best,
Chen
 
 
Hello,
Which kernel and perf version are you using? Which arch?
On a quick google search (my kernel is old and this perf doesn't have
the "probe" command, incoming re-install) I found out the error you're
experiencing in the perf source code:
---------
        init_vmlinux();
        if (session.need_dwarf)
#ifdef NO_DWARF_SUPPORT
                 die("Debuginfo-analysis is not supported");
---------
So my first guess was that there is something missing from perf or the
kernel itself, related to this NO_DWARF_SUPPORT. After further research
I've found the following presentation:
http://events.linuxfoundation.org/slides/lfcs2010_hiramatsu.pdf
Going to slide 25, it says:
"Elfutils(Libdw)
● Dwarf format (debuginfo) analysis library
– Developed closely with GCC.
● Without elfutils, perf probe can't support debuginfo "
In fedora/RHEL the following packages were a match for "elfutils":
============================ N/S Matched: elfutils
=============================
elfutils.x86_64 : A collection of utilities and DSOs to handle compiled
objects
elfutils-devel.i686 : Development libraries to handle compiled objects
elfutils-devel.x86_64 : Development libraries to handle compiled objects
elfutils-devel-static.x86_64 : Static archives to handle compiled
objects
elfutils-libelf.i686 : Library to read and write ELF files
elfutils-libelf.x86_64 : Library to read and write ELF files
elfutils-libelf-devel.i686 : Development support for libelf
elfutils-libelf-devel.x86_64 : Development support for libelf
elfutils-libelf-devel-static.x86_64 : Static archive of libelf
elfutils-libs.i686 : Libraries to handle compiled objects
elfutils-libs.x86_64 : Libraries to handle compiled objects
TL;DR: What I would try to do is install all the elfutils packages and
see if you can run perf probe. If the error persists then you'll need to
dig deeper, maybe even posting this question in a kernel mailing list.
Hope that helps,
daniel
On Mon, 2013-04-01 at 01:34 +0800, OSDepend wrote:
> Hi all,
>  
> Is there any way to use perf probe to add new tracepoint like pagefault enter/exit?
>  
> I'm wandering how to use perf tool to get the event latency of SW event.
> Just to get the time cost by the context-switch, pagefault?
>  
> When I type perf probe fault:10      
> I always get the error as follow:
>  
> Debuginfo-analysis is not supported.
> Error: Failed to add events. (-38)
>  
> What exactly i miss to get the perf probe work correctly?
>  
> Best,
> Chen
>  
> 2013-04-01
> ______________________________________________________________________
> zhengchen
> _______________________________________________
> linuxtools-dev mailing list
> linuxtools-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/linuxtools-dev
_______________________________________________
linuxtools-dev mailing list
linuxtools-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/linuxtools-dev

Back to the top