From: David Ahern <dsahern@gmail.com>
To: Rodrigo Campos <rodrigo@sdfg.com.ar>,
Junjie Qian <junjie.qian@yahoo.com>
Cc: "linux-perf-users@vger.kernel.org" <linux-perf-users@vger.kernel.org>
Subject: Re: Profile the waiting time for lock or lock stats for one application
Date: Sat, 01 Mar 2014 08:30:47 -0700 [thread overview]
Message-ID: <5311FD27.7000903@gmail.com> (raw)
In-Reply-To: <20140228184343.GD10080@sdfg.com.ar>
On 2/28/14, 11:43 AM, Rodrigo Campos wrote:
> There are ways (not sure if the patch is in) to track for lock contension using
> perf, but not sure (I think not easy at least) if the lock is not contended. As,
> if using glibc, lot of locks are implemented using futex and then solved
> entirely in userspace lot of times (at least without contention).
What patch are you referring to? You can trace system calls to catch all
contention and wakeups. You can put probes at lock entry, exit and
unlock entry to track lock accesses by address.
I started working on this end of last year, just haven't had time to
work on the analysis side -- statistical analysis of lock times with
ability to see individual events. All I have right now is python script
that pretty prints the events.
David
next prev parent reply other threads:[~2014-03-01 15:31 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-25 18:13 Profile the waiting time for lock or lock stats for one application Junjie Qian
2014-02-27 3:17 ` Junjie Qian
2014-02-27 3:29 ` David Ahern
2014-02-28 20:00 ` Junjie Qian
2014-02-28 18:43 ` Rodrigo Campos
2014-03-01 15:30 ` David Ahern [this message]
2014-03-01 16:03 ` Rodrigo Campos
2014-03-03 16:11 ` Junjie Qian
2014-03-03 16:23 ` Rodrigo Campos
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5311FD27.7000903@gmail.com \
--to=dsahern@gmail.com \
--cc=junjie.qian@yahoo.com \
--cc=linux-perf-users@vger.kernel.org \
--cc=rodrigo@sdfg.com.ar \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).