Not logged in
Log in now
Create an account
Subscribe to LWN
LWN.net Weekly Edition for May 23, 2013
An "enum" for Python 3
An unexpected perf feature
LWN.net Weekly Edition for May 16, 2013
A look at the PyPy 2.0 release
Well that will be possible and nice to have when we'll have uprobes merged upstream.
Announcing a new utility: 'trace'
Posted Nov 17, 2010 12:19 UTC (Wed) by nix (subscriber, #2304)
Posted Nov 17, 2010 13:24 UTC (Wed) by jdahlin (guest, #14990)
However, I think you're confusing ltrace with latrace, only the latter uses the LD_AUDIT interface.
Posted Nov 17, 2010 18:16 UTC (Wed) by nix (subscriber, #2304)
Posted Nov 17, 2010 19:35 UTC (Wed) by oak (subscriber, #2786)
 The latrace based tracing downside is that you need to start the process under latrace as it's depending on dynamic linker (LD_AUDIT-feature) whereas ltrace can be attached to an already running process.
Downsides of ptrace() based ltrace are that it doesn't work for threaded processes and that it cannot trace library -> library calls, only binary -> library calls. Both are pretty huge downsides.
 ltrace toggles the breakpoints to let programs continue, this means that it can miss other threads calling same functions at the same time. Whereas e.g. functracer executes the instruction that was under breakpoint out-of-line (i.e. needs arch-specific code to emulate code using relative addressing) so that it doesn't need to be disabled.
One more problem with ltrace & functracer are that Linux ptrace() is somewhat broken for tracing. Utrace is supposed to fix/make ptrace() robust, but unfortunately it's still not in mainline.
Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds