Project News: DTrace
2018.04.05: DTrace userspace 1.0.0, libdtrace-ctf 0.8.0
This is a technology preview and is only available in source code form
from the Git repository.
- The pid provider is implemented for (nearly) arbitrary-location userspace
- DTrace is now supported on the AArch64 architecture for the following
providers: dtrace, profile, and syscall. The -x evaltime option is
hardwired to "preinit" on this architecture at present.
- Compile-time array bounds checking. Dereferencing arrays beyond their
declared bound is now a compile-time error. To dereference an array
regardless, use casts, e.g. ((char *)curlwpsinfo->pr_name).
- Addresses are normalized properly by mod(), so use of mod() in aggregates
works better now.
- DTrace will no longer consider symbols in built-in modules or the core kernel
to be in the wrong module: its idea of symbol addresses, sizes, and their
mapping to names is better in general, paticularly with respect to symbols
that overlap, symbols whose names are duplicates, and weak symbols.
- An interface problem has been fixed that can cause DTrace consumers to
dereference freed memory when victim processes grabbed via ustack(),
umod(), usym() or dtrace -c or -p exec(). This requires changes to
certain users of libdtrace, and relinking: see "Library interface changes"
- The ip provider's ipv6_tclass and ipv6_flow fields were wrong on little-
- Fix rare assertion failures at exit.
- dtrace -S now disassembles all actions in statements containing more than
one, rather than disassembling only the first.
- A new symbol at address zero introduced by the KPTI changes is eliminated
from symbol resolution.
- Improvements to the testsuite and testsuite runner.
Library interface changes:
- The dtrace_proc_*() functions have changed the type they take to an opaque
handle, struct dtrace_proc. There is a new function dtrace_proc_getpid() to
get the PID from this opaque handle. dtrace_proc_grab() has been renamed
to dtrace_proc_grab_pid(). See INCOMPATIBILITIES.
The library soname has been bumped to libdtrace.so.1 correspondingly.
All consumers must relink, but consumers not using the dtrace_proc_*() APIs
need no code changes. All places where code changes are needed elicit a
compile-time error, so it should be easy to see what needs changing.
- Support for systems on which char is unsigned.
- Tagging added via a new @@tag in test files: testing with specific tags can
be requested via TEST_TAGS='a !b' in the environment and --tag/--no-tag
arguments to runtest.sh. The intersection of all tags is run, so in the
example above, only tests tagged with 'a' and not tagged with 'b' would be
run. You can specify tags that apply by default in the test/tags.default
file, and tags that apply on only one architecture in
- Translators can now change in arbitrary kernel versions: you are not
restricted to having different translators only in different X.Y major
kernel versions. The means by which translators that vary across kernels is
specified is improved.