lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 11 Jul 2012 16:55:08 +0200
From:	Peter Zijlstra <peterz@...radead.org>
To:	Frederic Weisbecker <fweisbec@...il.com>
Cc:	Andrew Vagin <avagin@...nvz.org>, linux-kernel@...r.kernel.org,
	Ingo Molnar <mingo@...nel.org>,
	Steven Rostedt <rostedt@...dmis.org>,
	Paul Mackerras <paulus@...ba.org>,
	Arnaldo Carvalho de Melo <acme@...stprotocols.net>,
	Arun Sharma <asharma@...com>
Subject: Re: [PATCH] trace: add ability to set a target task for events (v2)

On Wed, 2012-07-11 at 16:48 +0200, Frederic Weisbecker wrote:
> On Wed, Jul 11, 2012 at 04:38:19PM +0200, Peter Zijlstra wrote:
> > On Wed, 2012-07-11 at 16:36 +0200, Frederic Weisbecker wrote:
> > > 
> > > In this case he can just record sched wakeup as well. With sched_switch
> > > + sched_wakeup, he'll unlikely lose events.
> > > 
> > > With sched_stat_sleep he will lose events, unless we fix this period
> > > demux thing. 
> > 
> > But without this patch, the sched_wakeup will belong to another task, so
> > if you trace task A, and B wakes you, you'll never see the wakeup.
> 
> Ah so the goal is to minimize the amount of events by only tracing task A?

Right, or just not having sufficient privs to trace the world. And a
wakeup of A is very much also part of A, not only the task doing the
wakeup.

Hence the proposed mechanism.

> Ok then. Still we need to fix these events that use __perf_count() because
> wide tracing of sched_switch/wake_up still generate less events than
> sched stat sleep.
> 
> I believe:
> 
> 	perf record -e sched:sched_stat_sleep sleep 1
> 
> produces 1 billion events because we sleep 1 billion nanosecs. Or
> something like that.

Right.. back when I did that the plan was to make PERF_SAMPLE_PERIOD fix
that, of course that never seemed to have happened.

With PERF_SAMPLE_PERIOD you can simply write the 1b into the period of 1
event and be done with it.
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ