public inbox for bpf@vger.kernel.org
 help / color / mirror / Atom feed
From: Omar Sandoval <osandov@osandov.com>
To: lsf-pc@lists.linux-foundation.org, bpf@vger.kernel.org
Subject: [LSF/MM TOPIC] drgn, a scriptable debugger
Date: Fri, 22 Feb 2019 11:27:43 -0800	[thread overview]
Message-ID: <20190222192743.GA31597@vader> (raw)

Hello,

I've already sent in an attend request for the I/O track, but I'd also
like to propose my project, drgn [1], as a topic for the BPF/tracing
track.

Basically, drgn is a more intuitive replacement for crash(8) which
exposes kernel types and variables to Python. For example, one can
trivially access common kernel structures:

>>> init = find_task(prog, 1)
>>> fd = fget(init, 3)
>>> fd.f_inode.i_sb.s_type.name
(const char *)0xffffffff862bf29c = "devtmpfs"

Since it's just Python, it's also easy to do more complex analysis:

>>> sum(1 for _ in list_for_each(fd.f_inode.i_sb.s_inodes.address_of_()))
491

I've been using this to debug issues in production at Facebook. Since
the project is relatively new, some of it is still in flux. I'm
currently rewriting the core components in C for performance reasons.
Next after that is improved documentation as well as stack trace
support, which is the biggest missing feature. Regardless, it's already
proven quite useful, so I'd love a chance to talk about it and gather
feedback.

Thanks!

1: https://github.com/osandov/drgn

                 reply	other threads:[~2019-02-22 19:27 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20190222192743.GA31597@vader \
    --to=osandov@osandov.com \
    --cc=bpf@vger.kernel.org \
    --cc=lsf-pc@lists.linux-foundation.org \
    /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