2.0.0-1.14 (Mar 5th, 2024)

Fourteenth errata of the standalone userspace implementation.

This is a pre-release with limited functionality.

New features

  • The io provider has been implemented.

  • The print() action has been implemented.

  • The link_ntop() subroutine has been implemented.

  • The cleanpath() subroutine has been implemented.

  • The d_path() subroutine has been implemented to always return "<unknown>". This is needed to ensure that the io and procfs translators compile.

  • The -xcpu option has been implemented.

  • The -xaggpercpu option has been implemented.

  • The -xlockmem option has been improved. The limit is set before retrieving probe info, and the default behavior is now "unlimited" (meaning most users will not have to worry about this option).

  • The pid provider now supports offset-based probe names.

  • Aggregations of stacks are now supported.

  • The retrieval of rawtp argument information has been improved.

  • You can now delete an element in an associative array by assigning a literal 0 to it, regardless of the element datatype.

  • The lexer has been improved to support module names that start with a numeral so that they can be used. For example, 9p`v9fs_remove.

  • A basic configure script has been added to help building and packaging in various distributions.

  • USDT probe information maintained by dtprobed is now stored under /run to ensure it can survive daemon restarts.

  • DTrace can now be used for tracing with upstream kernels without requiring any additional patches, albeit with some limitations.

  • The ip provider has been implemented.

  • The trunc() action has been implemented.

  • The pcap() action has been implemented.

  • The inet_ntoa6() subroutine has been implemented.

  • The inet_ntop() subroutine has been implemented.

  • Support for modules.builtin.ranges data from the kernel has been added. This is the new way to determine module name association for kernel symbols that are built into the kernel. Support for kallmodsyms is retained for kernel that don't support modules.builtin.ranges yet.

  • A BTF-to-CTF convertor has been added to support using DTrace with kernels that don't provide CTF data. Note that BTF is currently more limited than CTF. For example, BTF doesn't provide datatype information for kernel variables.

Bugfixes

  • Drop counter handling is fixed for local-only updates.

  • Dedicated space has been introduced for call stacks so that stackdepth and temporary strings don't overwrite one another.

  • dt_tp_event_info() has been corrected so as not to overrun its buffer.

  • Compilation of BPF code that uses BPF helpers now uses the bpf_helpers.h header file from libbpf-dev[] instead of the (deprecated) bpf-helpers.h header file that the gcc BPF cross provided.

  • Because of the need to support DTrace on older kernels, BPF source code files are now compiled using -mcpu=v3 to ensure that the object code is acceptable to the BPF verifier in older kernels.

  • When a DTrace instance would trigger the END probe to be processed, any and all other dtrace instances on the system would have their END probe fire as well because the dtrace provider trampolines weren't validating the tgid of the task triggering the probe.

  • The initialization of the cpuinfo BPF map could cause a buffer overrun on systems with non-sequential online CPU ids.

  • On kernels that support preemptive BPF program execution, probe data could get corrupted. As a temporary fix, concurrent BPF program execution for DTrace probes is blocked.

  • Struct and union member access in alloca()-allocated memory no longer cause a BPF verifier violation.

  • Bitfield offset calculations have been corrected.

  • Disassembler output for endianness conversion instructions has been corrected.

  • Bounds checking of array datatypes of size 0 or 1 in the kernel is now skipped because they are commonly used in the kernel as anchors for dynamically sized arrays.

  • Zero constants are now checked at compile time wherever NULL pointer argument checking is done.

  • Uprobes are now created using the offset in the inode rather than based on an absolute address.

  • Building in various forms of kernel builds is now more streamlined.

Internal changes

  • Code has been restructured to better support SDT-based providers. While such providers (lockstat, io, and so on.) used to be based on static probes in the kernel source, they're now implemented with fbt, rawtp, and even syscall probes. Probe trampolines can become involved. Changes, notably in cg, better support these providers. Also, the underlying probes are using rawtp more rather than relying solely on fbt.

  • Support for compilation in older environments (esp. older compilers) has been improved.

  • There have been several build improvements, especially for cross compilation and to build with upstream kernels.

  • A bunch of code to parse strings has been removed, relying instead on flex for this support.

  • The creation and deletion of USDT probes has moved from dtprobed to dtrace.

  • The dtprobed now uses presets for daemon restarting.

  • The dependency on waitfd() has been replaced with a mechanism that doesn't depend on this system call.

Testsuite changes

  • Test dependence on tick-* probes has further been reduced. The tick-* probes can behave poorly on some kernels, depending on how their timers subsystem is configured (CONFIG*_HZ*). Reducing this dependence has gone on over several releases to improve the robustness of these tests.

  • Fix err.* tests that force XFAIL to report so correctly.

  • Skip lockstat testing before 5.10.

  • Fix the use of syscall::execve:entry args[], because there are two levels of dereferencing userspace addresses, requiring two copyin*().