[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150607131104.GA24442@gmail.com>
Date: Sun, 7 Jun 2015 15:11:04 +0200
From: Ingo Molnar <mingo@...nel.org>
To: Arnaldo Carvalho de Melo <acme@...nel.org>
Cc: "Wangnan (F)" <wangnan0@...wei.com>,
Alexei Starovoitov <ast@...mgrid.com>,
pi3orama <pi3orama@....com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Adrian Hunter <adrian.hunter@...el.com>,
Brendan Gregg <brendan.d.gregg@...il.com>,
Daniel Borkmann <daniel@...earbox.net>,
David Ahern <dsahern@...il.com>, He Kuang <hekuang@...wei.com>,
Jiri Olsa <jolsa@...hat.com>, Kaixu Xia <xiakaixu@...wei.com>,
Madhavan Srinivasan <maddy@...ux.vnet.ibm.com>,
Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>,
Michael Ellerman <mpe@...erman.id.au>,
Namhyung Kim <namhyung@...nel.org>,
Peter Zijlstra <peterz@...radead.org>,
Sukadev Bhattiprolu <sukadev@...ux.vnet.ibm.com>,
Zefan Li <lizefan@...wei.com>,
Alexei Starovoitov <alexei.starovoitov@...il.com>
Subject: Re: [GIT PULL 0/6] perf/core improvements and fixes
* Arnaldo Carvalho de Melo <acme@...nel.org> wrote:
> Em Fri, Jun 05, 2015 at 02:05:50PM +0200, Ingo Molnar escreveu:
> > * Wangnan (F) <wangnan0@...wei.com> wrote:
> <SNIP>
> > > One problem I can find is that, the wrapper will make perf depend on llvm. I
> > > don't think the compiler will be deployed in production environments... And
> > > also, the embedded case...
>
> > What dependencies are there?
>
> > On the usage side there should be very few outright dependencies: if the llvm
> > binary is not available, or doesn't support what you need, or there's no runtime
> > environment you can use to build the bytecode, you should display an informative
> > error message so that the user knows what is missing and how to install it.
>
> Right, something like:
>
> [acme@zoo ~]$ perf trace -e nanosleep usleep 1
> Error: No permissions to read /sys/kernel/debug/tracing/events/raw_syscalls/sys_(enter|exit)
> Hint: Try 'sudo mount -o remount,mode=755 /sys/kernel/debug'
> [acme@zoo ~]$ sudo mount -o remount,mode=755 /sys/kernel/debug
> [sudo] password for acme:
> [acme@zoo ~]$ perf trace -e nanosleep usleep 1
> 0.565 ( 0.060 ms): usleep/17648 nanosleep(rqtp: 0x7fff22baebf0) = 0
> [acme@zoo ~]$ perf trace --all-cpus
> Error: Operation not permitted.
> Hint: Check /proc/sys/kernel/perf_event_paranoid setting.
> Hint: For system wide tracing it needs to be set to -1.
> Hint: Try: 'sudo sh -c "echo -1 > /proc/sys/kernel/perf_event_paranoid"'
> Hint: The current value is 1.
> [acme@zoo ~]$
> [acme@zoo ~]$ trace -a -e poll usleep 1
> [acme@zoo ~]$ trace -a -e poll usleep 1
> 0.041 ( 0.000 ms): firefox/1458 ... [continued]: poll()) = 1
> 0.267 ( 0.003 ms): firefox/1458 poll(ufds: 0x7f43d6ea1340, nfds: 5) = 0 Timeout
> 0.275 ( 0.001 ms): firefox/1458 poll(ufds: 0x7f43d6ea1340, nfds: 5) = 0 Timeout
> 0.283 ( 0.001 ms): firefox/1458 poll(ufds: 0x7f43d6ea1340, nfds: 5) = 0 Timeout
> 0.979 ( 0.000 ms): gnome-terminal/2572 ... [continued]: poll()) = 1
> 1.056 ( 0.768 ms): firefox/1458 poll(ufds: 0x7f43d6ea1340, nfds: 5, timeout_msecs: 4294967295) ...
> 1.065 ( 0.009 ms): gnome-terminal/2572 poll(ufds: 0x1934250, nfds: 23, timeout_msecs: 10) = 1
> 1.087 ( 0.007 ms): gnome-terminal/2572 poll(ufds: 0x1934250, nfds: 23, timeout_msecs: 10) = 2
> 1.132 ( 0.007 ms): gnome-terminal/2572 poll(ufds: 0x1934250, nfds: 23, timeout_msecs: 10) = 1
> 1.161 ( 0.013 ms): gnome-terminal/2572 poll(ufds: 0x1934250, nfds: 23, timeout_msecs: 10) = 1
> [acme@zoo ~]$
>
> I.e. Explain the mistake and provide a hint to solve it, as close to the actual
> commands needed to perform such corrective/enabling action as possible.
Yeah, I absolutely love such tooling hints.
Thanks,
Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists