Re: latency histogram with BPF

2015-06-15 Thread Daniel Wagner
On 06/12/2015 07:17 PM, Alexei Starovoitov wrote: > On 6/12/15 7:33 AM, Daniel Wagner wrote: >> On 06/12/2015 08:12 AM, Daniel Wagner wrote: >> Attaching kprobes to trace_preempt_[on|off] works fine. Empty BPF >> programs connected to the probes is no problem as well. So I changed the >> BPF progra

Re: latency histogram with BPF

2015-06-12 Thread Alexei Starovoitov
On 6/11/15 11:58 PM, Wangnan (F) wrote: Is it possible to make 'uapi/linux/bpf.h' hold something useful for eBPF programming, so we can get rid from bpf_helpers? that won't be right. uapi headers suppose to have things needed for both kernel and user space, not user space only. I think it's bet

Re: latency histogram with BPF

2015-06-12 Thread Alexei Starovoitov
On 6/12/15 7:33 AM, Daniel Wagner wrote: On 06/12/2015 08:12 AM, Daniel Wagner wrote: On 06/12/2015 12:08 AM, Alexei Starovoitov wrote: On 6/11/15 12:25 AM, Daniel Wagner wrote: If you have any suggestions on where to look, I'm all ears. My stack traces look like: Running with 10*40 (== 400) ta

Re: latency histogram with BPF

2015-06-12 Thread Daniel Wagner
On 06/12/2015 08:12 AM, Daniel Wagner wrote: > On 06/12/2015 12:08 AM, Alexei Starovoitov wrote: >> On 6/11/15 12:25 AM, Daniel Wagner wrote: >> If you have any suggestions on where to look, I'm all ears. >> My stack traces look like: >> Running with 10*40 (== 400) tasks. >> [ 12.032571] kernel B

Re: latency histogram with BPF

2015-06-11 Thread Wangnan (F)
On 2015/6/11 15:25, Daniel Wagner wrote: Hi Steven and Tom, I was playing a bit with BPF to see if it would be possible to get a preempt off latency histogram. On paper this looks like doable but adding kprobes on trace_preempt_[on|off] is not a clever idea. Who would have thought? :) In both

Re: latency histogram with BPF

2015-06-11 Thread Daniel Wagner
On 06/12/2015 12:08 AM, Alexei Starovoitov wrote: > On 6/11/15 12:25 AM, Daniel Wagner wrote: >> In both cases BPF or based on Tom's 'hist' triggers' patches, there is >> some trickery necessary to get it working. While the first approach >> has more flexibility what you want to measure or how you

Re: latency histogram with BPF

2015-06-11 Thread Alexei Starovoitov
On 6/11/15 12:25 AM, Daniel Wagner wrote: In both cases BPF or based on Tom's 'hist' triggers' patches, there is some trickery necessary to get it working. While the first approach has more flexibility what you want to measure or how you want to present it, I suspect it will be harder to get it

latency histogram with BPF

2015-06-11 Thread Daniel Wagner
Hi Steven and Tom, I was playing a bit with BPF to see if it would be possible to get a preempt off latency histogram. On paper this looks like doable but adding kprobes on trace_preempt_[on|off] is not a clever idea. Who would have thought? :) In both cases BPF or based on Tom's 'hist' triggers'