From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
To: ltt-dev@lists.casi.polymtl.ca
Cc: Stefan Hajnoczi <stefanha@gmail.com>, qemu-devel@nongnu.org
Subject: [Qemu-devel] [RELEASE] LTTng-UST 0.15 (Qemu support & tutorial)
Date: Fri, 15 Jul 2011 15:04:25 -0400 [thread overview]
Message-ID: <20110715190425.GA1943@Krystal> (raw)
LTTng-UST, the Linux Trace Toolkit Next Generation Userspace Tracer, is
port of the low-overhead tracing capabilities of the LTTng kernel tracer
to user-space. The library "libust" enables tracing of applications and
libraries.
Changelog:
* Add backward compability for tracepoint API (still planned
for deprecation, but should make the transition smoother).
The API transition will happen when UST 2.0 is ready. There is no
point in making multiple API breakage when unneeded.
tracing qemu-kvm with UST is now working again with UST 0.15 (0.14 did
break it).
Project website: http://lttng.org/ust/
Download link: http://lttng.org/files/ust/releases/
(please refer to the UST Manual for installation instructions)
A quick walkthrough for tracing kvm-qemu with UST:
git clone git://git.lttng.org/userspace-rcu.git
(install: see README)
git clone git://git.lttng.org/ust.git
(install: see README)
In my case, I enabled qemu_malloc, qemu_realloc, qemu_free,
qemu_memalign, qemu_vmalloc, qemu_vfree by editing the "trace-events"
file in the toplevel source directory (this file is qemu-specific, not
the usual interface UST provides):
# qemu-malloc.c
qemu_malloc(size_t size, void *ptr) "size %zu ptr %p"
qemu_realloc(void *ptr, size_t size, void *newptr) "ptr %p size %zu newptr %p"
qemu_free(void *ptr) "ptr %p"
# osdep.c
qemu_memalign(size_t alignment, size_t size, void *ptr) "alignment %zu size %zu ptr %p"
qemu_vmalloc(size_t size, void *ptr) "size %zu ptr %p"
qemu_vfree(void *ptr) "ptr %p"
./configure --enable-trace-backend=ust
make
ldd x86_64-softmmu/qemu-system-x86_64
...
libust.so.0 => /usr/local/lib/libust.so.0 (0x00007fa39fc74000)
(it's linked with libust)
usttrace x86_64-softmmu/qemu-system-x86_64
...
stop it (ctrl-c)
See resulting trace in:
$HOME/.usttraces/hostname-timestamp
UST 0.15 traces can be viewed with lttv: git clone git://git.lttng.org/lttv.git
(install: view README)
To view the trace (e.g.):
% lttv -m textDump -t % /home/compudj/.usttraces/ok-20110715144748823020811/32575_5629652727107472206
...
ust.qemu_free: 1552840.525993542 (/home/compudj/.usttraces/ok-20110715144748823020811/32575_5629652727107472206/ust_6), 0, 0, , , 0, 0x0, MODE_UNKNOWN { ptr = 0x1187680 }
ust.qemu_free: 1552840.525994061 (/home/compudj/.usttraces/ok-20110715144748823020811/32575_5629652727107472206/ust_6), 0, 0, , , 0, 0x0, MODE_UNKNOWN { ptr = 0x1187660 }
--
Mathieu Desnoyers
Operating System Efficiency R&D Consultant
EfficiOS Inc.
http://www.efficios.com
reply other threads:[~2011-07-15 19:04 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=20110715190425.GA1943@Krystal \
--to=mathieu.desnoyers@efficios.com \
--cc=ltt-dev@lists.casi.polymtl.ca \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.com \
/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).