Project News: DTrace

[ Project Home  |  News  |  Downloads  |  Docs  |  Mailing Lists  |  Source Control  |  Issues ]

 

2013.10.29: DTrace 0.4.0

 

DTrace for Linux 0.4.0 is released.
 
All RPMs are available on the Unbreakable Linux Network.
 
Packaging changes:
 
 - kernel-uek-dtrace: This package is removed: DTrace now works with the
   official UEK3 kernel.
 
 - dtrace-modules-headers: This new package exports headers describing the
   DTrace user/kernel interface, so that userspace and other DTrace
   consumers can use it.
 
 - dtrace-modules-provider-headers: This new package exports headers needed to
   implement new DTrace providers (in kernel space).
 
 New features:
 
 - Support for meta-providers, such as fasttrap (used for userspace tracing).
   A meta-provider implements a framework to instantiate providers dynamically
   (on demand).
 
 - Userspace Statically Defined Tracing (USDT) provides support for SDT-alike
   probes in userspace executable and libraries.  Two types of probes are
   available: regular SDT-alike probes, and is-enabled probes.
 
 - The fasttrap provider has been implemented, although it is currently only
   supporting USDT probes.
 
 - Symbol lookup now works: stack() and ustack() now print symbols, as does &.
   ustack() can look up symbols in libraries loaded with dlopen() and dlmopen()
   as well as via DT_NEEDED.  Symbol lookup of global symbols in userspace
   processes respects symbol interposition and all other symbol-ordering
   trickery.  Some of the machinery involved in this only works with programs
   running against specific versions of the GNU C Library.  (It will always work
   with the version of glibc shipped with OEL, and falls back to a simpler
   approach which does not support symbol interposition or dlmopen() if it
   appears an incompatible glibc is in use).
 
 - -xevaltime={preinit, postinit, main} now work, with a few caveats:
 
   - postinit (the default) is equivalent to main. 
 
   - On statically linked binaries, preinit is equivalent to exec, and may
     not skip ld.so initialization (which can happen after main() on such
     binaries).
 
   - On stripped, statically linked binaries, postinit and main are equivalent
     to preinit, because we cannot look up the 'main' symbol when there is no
     symbol table.
 
 - DTrace options can now be set from environment variables named DTRACE_OPT_*.
   Example:
 
     export DTRACE_OPT_INCDIR=/usr/lib64/dtrace:/usr/include/sys
  
Bugfixes:
 
 - The -h and -G command-line options work.
 
 - Negative values passed to DTrace options that take only positive integers are
   correctly diagnosed as errors again.
 
 - It is now possible to get the correct value for the ERR registers.
 
 - The ustack() and jstack() actions were not passing the PID correctly as the
   first element in the result array.
 
 - The ustack() action implementation has been replaced.
 
 - Several obscure locking problems have been resolved.
 
Changes to kernel internals: 
 
 - What was previously defined as a meta-provider is in fact better defined as a
   multi-provider, i.e. a provider framework that handles multiple providers
   that essentially share (the majority of) a single implementation, such as SDT
   where probes are grouped together into providers even though they are all
   provided by the same provider (sdt).
 
 - The systrace provider has been updated to account for changes in the Linux
   kernel (between 2.6.39 and 3.8.13).
 
Changes to user-visible internals:
 
 - The ELF section in which CTF data is stored has changed from .dtrace_ctf to
   .ctf.
 
 - The storage representation of internal kernel symbols is improved, saving
   DTrace memory usage at startup by a megabyte or so.
 
 - The libdtrace public API header now names its arguments.  A few other
   libdtrace functions have changed prototype in minor ways.
 
 - Two undocumented libproc environment variables from Solaris are removed,
   because the code whose behaviour they adjusted no longer exists:
   _LIBPROC_INCORE_ELF and _LIBPROC_NO_QSORT.
 
 - New low-overhead debugging machinery.  Exporting DTRACE_DEBUG=signal in the
   environment will emit debugging output only when DTrace is hit by a SIGUSR1,
   avoiding all printf() locking overhead until then.  This uses a ring buffer
   to stop debugging output, by default 100Mb in size, changeable via the
   DTRACE_DEBUG_BUF_SIZE variable (which takes a size in megabytes).
 
Known bugs and limitations:
 
 - Presently, kill -9'ing a running dtrace can leave breakpoints outstanding in
   other processes, which may sooner or later kill them.  This will be fixed in
   due course (by avoiding the use of breakpoints in more cases).