-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathNEWS
More file actions
2990 lines (1962 loc) · 107 KB
/
NEWS
File metadata and controls
2990 lines (1962 loc) · 107 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
2.0.6-1 (Mar 9th, 2026)
-----------------------
Bugfixes:
- Do not allow / to be used in probe description component names.
(CVE-2026-21991)
2.0.5-2 (Feb 4th, 2026)
-----------------------
New features:
- Implement PID-specific uprobes.
Bugfixes:
- Allocate the buffers BPF map to fit highest CPU id.
- Fix argument handling for multi-location user probes.
- Change the "stack skip" to 3 for fbt (fprobe) and rawtp providers.
- Fix prvname so that both rawfbt and fbt probes are seen.
- Do not convert "__" to "-" for stapsdt provider names.
- Fix printf formatting with non-monetary grouping chars.
User-visible changes:
- Discontinue -xversion=V as an option.
- Support non-libctf environments for tcp.
Internal changes:
- Fix some memory leaks.
- Refactor some code.
Testsuite changes:
- Correct file permissions.
- Add ERROR clause to prevent hang from runtime error.
Documentation changes:
- Add the DTrace Tutorial to the git repo and install package.
- Clean up formatting.
- Add missing documentation: trunc(), stapsdt, usdt.h include path.
- Update sections: unimplemented functions, sdt provider.
- Update LLM context files to forbid "if" statements.
- Update README.md for RPM info.
Build-time:
- Clean up .spec file.
- Add testsuite dependency for perl-Net-Ping
2.0.4-1 (Oct 24th, 2025)
------------------------
New features:
- The TCP and UDP providers have been implemented.
- An stapsdt provider has been implemented for user-space static probes
defined via stapsdt ELF notes. The provider also supports probes created
dynamically via libstapsdt.
- The User's Guide is now part of the git repository in Markdown form and
part of an install.
- Example scripts are now part of the git repository and installed under
/usr/share/doc/dtrace/examples.
- One can now use [u]stack() as variable values of type "struct dt_stack"
or "dt_stack_t".
- There is now a context file, which explains DTrace, to use with LLMs.
- Comments using // are now supported.
- The return() action is now implemented, allowing error injection by forcing
a given return value for a kernel function. The kernel must be configured
with CONFIG_BPF_KPROBE_OVERRIDE and CONFIG_FUNCTION_ERROR_INJECTION.
Bugfixes:
- A commonplace problem with dynamics variables overwriting one another was
identified and fixed.
- fbt probes in the "dtrace -l" listing have been restored.
- Function names have been restored to pid return probes.
- The built-in variables caller and stackdepth have been corrected by
recognizing when additional BPF stack frames must be skipped.
- char arrays can now be used in aggregation keys.
- The use of -w is now required for destructive actions, even if a clause is
being ignored with -Z.
- Both 'cwd' and 'root' now work (and other inline vars are now tested).
- The proc:::exec args[0] argument has been corrected for the case that
execveat() is the underlying function.
User-visible changes:
- DIFO is now freed once a probe is loaded, substantially reducing memory
consumption when a lot of probes are specified.
- Per-CPU agg-map IDs are now cached, substantially improving trunc()
performance on the consumer side on many-CPU systems.
- D compilation now allows enum declarations where the last enumerator value
is followed by a comma.
- alloca() pointers are now printed as actual pointer values into kernel space
rather than as relatively small offsets into the DTrace scratch memory area.
- Strings are now handled better with regards to empty strings, the meaning of
strsize, testing, and NUL padding.
- SDT probes that were not firing because they were dependent on fbt probes
that were not firing with the fentry/freturn implementation are now dependent
on rawfbt probes (kprobes).
- The USDT parser now handles encoded hyphens.
- Function Psystem_daemon() now has better logic for detecting system daemons.
- Management of CTF and BTF data has been improved. E.g.,
- If the kernel is not compiled with CTF or BTF, there is an error message.
- There is now an -xbtfpath option, with -xbtfpath=none disabling the use
of BTF data.
- A BTF ID symbol lookup now checks that the module BTF data is loaded.
- If a pid probe description is supplied with a wildcard probe name (that is,
function offset), instructions are skipped if the kernel does not allow
probe attach.
Internal changes:
- The mechanism to skip common fields when querying tracepoint probe arguments
is now more robust.
- tstrings are now managed better, including elimination of some leaks,
thereby allowing more complex expressions.
- DTrace version numbering is now consolidated.
- References in dlibs to major_names now explicitly mention vmlinux, so as to
avoid loading modules needlessly.
- Parsing and lexical analysis has been improved.
- The subtraction of two alloca() pointers no longer receives the ALLOCA taint.
- Aggregations are now snapshot "just in time" for theoretically better
performance and for more consistent reporting.
- USDT discovery has been optimized a little. USDT memory leaks in hash
tables have been cleaned up.
- Some unused variables have been eliminated.
Testsuite changes:
- Various tests have been made more stringent, reliable, or suitable for newer
kernels.
- Test dependence on tick-* probes has once again been reduced yet further.
- New tests have been added for more coverage.
- .r.p files have been moved from /bin/sh to /bin/bash for better behavior on
more distributions.
- Script get_remote.sh is now installed for better testing of RPMs.
Build-time:
- BPF library functions are now compiled with -ffreestanding.
- The developer package now includes previous omissions.
2.0.3-1 (Jun 10th, 2025)
------------------------
New features:
- USDT probes in executables and shared libraries that are compiled with LTO
is now supported. USDT probe definitions are now recorded in .note.usdt
ELF notes.
- The pr_psargs member of the psinfo_t < struct task_struct *T > translator
is now implemented. It used the new execargs builtin variable.
- The pid provider now supports offset-based instruction probes.
Bugfixes:
- Automatic selection of fprobe vs kprobe based FBT probes has been corrected.
- Trampoline use of the BPF stack for scratch space has been corrected.
- The rawfbt provider has been fixed to perform symbol lookups on the actual
true symbol name.
- BPF attach type detection has been fixed.
- The probeprov, probemod, probefunc, and probename builtin variables now
report the correct values for late USDT processes.
- The value of arg3 for sched:::enqueue and sched:::dequeue has been
corrected.
- No longer register fbt and rawfbt twice.
- Discovery of new probes now correctly loops through all registered providers
rather than just the initial providers.
User-visible changes:
- The kernel symbol name filter has been made less strict.
- Failures in enabling a probe now report the probe name.
Internal changes:
- Builtin variables are now implemented with individual functions rather than
a single large function, reducing compiled BPF program size.
- Relocation types R_BPF_64_ABS64 and R_BPF_64_ABS32 are now supported.
- The proc provider has been implemented using the standard SDT provider
implementation.
- The fbt and rawfbt providers have been consolidated, and significan
performance improvements have been applied.
- The hashtable implementation has been moved to libcommon. It is now used
by dtprobed and libdtrace.
Testsuite changes:
- Many testcases have been improved.
- Use of bash and gawk throughout the testsuite has been made more consistent.
- Tests can now use CC, OBJCOPY, OBJDUMP, NM, ... as shell variables in
scripts to allow setting values that apply to all tests.
2.0.2-1 (Dec 6th, 2024)
-----------------------
New features:
- Translators for kernel versions 6.10 and beyond have been added. This
ensures translator support through (at least) 6.12 kernels.
- FBT return probes based on fexit probes will now report return values.
- The print() action has been enhanced with type information for its argument.
- USDT probes that are discovered after tracing started (either because of the
use of wildcards in the probe specification or with the -Z option) are now
supported.
- USDT probe argument type support has been implemented, incl. translated
types and argument mapping.
- A manpage for dtprobed has been added.
- The rawfbt provider has been implemented. This is a new provider that
allows tracing of all functions that are available through kprobes. This
includes <func>.<suffix> function names that are the result of compiler
optimizations.
Bugfixes:
- Since BPF assemvbler source is written in 'normal' assembler syntax, the
-masm=normal option is to be passed to BPF gcc invocations.
- Parsing of bpf_helper_defs.h is more tolerant of version changes.
- The BPF-to-CTF conversion works for kernel modules.
- DTrace will no longer try to obtain a return value for void functions.
- The stddev() aggregation function carry-over computation has been corrected.
- The clear() action will now only clear the aggregation for which is it
called.
- ERROR probe firings were corrupting probe arguments for the probe whose
execution triggered the error.
- ERROR probe firings did not always report the correct probe id.
- Relocations in the ERROR probe program were being done too early, causing
some values to be incorrect.
- Buffer size calculations have been corrected.
- Casting will no longer render an lvalue immutable.
- Multiple USDT providers in a single ELF object now work.
- Self-grab support has been improved.
- The umod/usym/uaddr actions have been improved.
- Various memory leaks have been resolved.
User-visible changes:
- The header files to support USDT probes (sdt.h, etc) have been moved to
/usr/lib64/dtrace/include/sys. Support for pkg-config has been added to
have a convenient way to obtain installation paths for libraries and
header files.
- DTrace will provide an appropriate error message when it is executed in
a mode that requires root privileges.
- The manpages for dtrace and dtprobed have been reworked to use better
markup.
Internal changes:
- Keys for @[mod()], @[sym()], etc are now consolidated where possible.
- Trace data consumption will now process only one set of records per
iteration, to avoid possible starvation issues.
- Various pieces of dead code have been removed.
- The association between probes and clauses now operates at the statement
level. This more accurately reflects the structure of tracing programs, and
is needed to support discovery of probes after tracing has started.
- The EPID concept has been deprecated. A value for the 'epid' built-in
variable is still generated for backwards compatibility. The value has no
semantic meaning, and simply satisfies the requirement that it is unique for
every instance of a particular probe.
- BPF tracing programs can now contain clauses that *may* be used by probes
that are discovered after tracing already started.
- The internal implementation of pid probes, USDT probes, and is-enabled USDT
probes has been consolidated (and simplified) in a single trampoline for the
underlying uprobe.
- DTrace (specifically dtprobed) no longer depends on libsystemd. It can
still report its activity status to systemd.
Testsuite changes:
- Many testcases have been adjust to not depend on optional features, and
to have more predictable behaviour.
- Use of bash and gawk throughout the testsuite has been made more consistent.
Build-time:
- All installation paths can be configured to support flexible filesystem
layouts for distributions.
- Support for valgrind is now optional.
Known problems:
- Enabling a large amount of probes (in the order of > 50,000) consumes quite
a significant amount of memory to hold the BPF programs, which may trigger
the OOM killer in the kernel.
2.0.1-1 (May 6th, 2024)
-----------------------
New features:
- Function Boundary Tracing (FBT) probes can now access function arguments
using argv[n] where n is bound by the number of arguments of the function.
The datatype of each argument is a generic uint64_t for now.
Internal changes:
- Function BOundary Tracing (FBT) probes are now implemented using the more
lightweight fentry/fexit kernel tracing facility. Fallback to kprobes is
provided for kernels that do not provide fentry/fexit probing using BPF.
Build-time:
- D translators are now included with the DTrace source code, and will be
installed for all supported kernel versions. This mens that building
DTrace no longer requires access to kernel development headers.
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.
- It is now possible to 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 (e.g. 9p`v9fs_remove).
- A basic configure script has been added to facilitate building and packaging
in a variety of distributions.
- USDT probe information maintained by dtprobed is now stored under /run to
ensure it can survive daemon restarts.
Bugfixes:
- Drop counter handling is fixed for local-only updates.
- Dedicated space has been introduced for call stacks, so that stackdepth and
temporary strings will not 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[el] instead of the (deprecated) bpf-helpers.h
header file that the gcc BPF cross provided.
- Due to 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 were not 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.
Internal changes:
- Code has been restructured to better support SDT-based providers.
While such providers (lockstat, io, etc.) used to be based on
static probes in the kernel source, they are 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
just on fbt.
- Support for compilation in older environments (esp. older compilers) has
been improved.
- There have been a number of 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.
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 multiple releases to improve the robustness of these tests.
- Fix err.* tests that force XFAIL to report so correctly.
- Skip lockstat testing prior to 5.10.
- Fix the use of syscall::execve:entry args[1][?], since there are two
levels of dereferencing userspace addresses, requiring two copyin*().
2.0.0-1.13.2 (Nov 10th, 2023)
-----------------------------
Thirteenth errata of the standalone userspace implementation.
** This is a pre-release with limited functionality. **
New features:
- 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 do not support modules.builtin.ranges yet.
- A BTF-to-CTF convertor has been added to support using DTrace with kernels
that do not provide CTF data. Note that BTF is currently more limited than
CTF. E.g. BTF does not provide datatype information for kernel variables.
Bugfixes:
- 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 will now be 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:
- The dependency on waitfd() has been replaced with a mechanism that does not
depend on this system call.
2.0.0-1.13.1 (Jun 7th, 2023)
----------------------------
Thirteenth errata of the standalone userspace implementation.
** This is a pre-release with limited functionality. **
Bugfixes:
- Upgrading DTrace using RPMs will now correctly restart dtprobed.
Testsuite changes:
- Some tests can leave orphaned tracing events registered with the kernel
if the tests timeout and the dtrace process is killed. Such probes will
now be reported and cleaned up after each test is executed.
2.0.0-1.13 (May 26th, 2023)
---------------------------
Thirteenth errata of the standalone userspace implementation.
** This is a pre-release with limited functionality. **
New features:
- Full support for is-enabled USDT probes.
- An error will be reported when a tracing script requires more space to
store aggregation data than is available per the aggsize option value.
- An error will be reported when a tracing script requires more space to
store dynamic variables than is available per the dynvarsize option value.
- Support for data drop counters for principal buffers, speculation buffers,
aggregations, and dynamic variables.
- The proc:::signal-clear probe has been implemented.
- The sched provider has been implemented for a limited set of probes (and
with some limitations). Available probes are: dequeue, enqueue, off-cpu,
on-cpu (limited trigger locations), surrender, tick, and wakeup. Note that
the cpuinfo argument for dequeue and enqueue (arg1) is NULL due to system
limitations. Future releases will incrementally expand this provider.
- The lockstat provider has been implemented. All lockstat probes are
implemented, but depending on the runtime kernel configuration, some probe
may not trigger in all cases (particularly for lock operations that are
forced to be inlined). Also, kernels prior to 5.10.0 contain a bug that
can cause kernel deadlock when a kretprobe is used on spinlock functions.
The lockstat provider is not enabled for such kernels for safety.
- True NULL strings are now supported.
- The uregs[] built-in variable is now supported on older kernels as well.
- New option 'linknommap' has been added as a workaround for elfutils bugs
related to mmap() usage.
Bugfixes:
- The error message issued by dtprobed to report incorrect helper data size
was reporting the expected and received values backwards.
- USDT probes in programs that live in different fs namespaces are now fully
supported.
- When multiple USDT probes were specified, only the first one would get
provided properly.
- Properly recognize all forms of the 'char' datatype as equivalent.
- Do not allow iregs to be increased beyond its default value (the number of
BPF registers).
- The uaddr handling has been fixed to not trigger a segmentation fault for
pid 0.
- Tracepoint argument datatypes that are expressed by the kernel using
symbolic array size specifiers are now handled correctly.
- The established behaviour of DTrace when storing data in a speculation has
been to abort clause execution at any statement that would cause a
speculation buffer overflow. Code to perform overflow checks when storing
data in a speculation are now generated correctly.
- Some faults were not reporting the PC of the fault location.
- FBT probes are no longer provided for compiler-generated internal symbols.
Such symbols cannot be probed anyway.
- Multiple memory leaks were resolved.
- Integers loaded from an associative array are now promoted to 64 bits.
- Failure to allocate a dynamic variable now reports a dynamic variable drop
warning, and aborts the clause execution.
- DOF parser crash causes were fixed in dtprobed.
- USDT probes in non-PIE executables are now fully supported.
- Multiple programs providing their DOF to dtprobed simultaneously could cause
some of their probes to not get created.
- Support for shared libraries and executables with very large numbers of
USDT probes (500+) has been improved.
Internal changes:
- DOF_VERSION_3 has been added for the new-style USDT is-enabled probe
mechanism that is not compatible with the previous versions.
- Userspace probe scanning was reworked to resolve performance issues.
- The 'cpuinfo' BPF map can now support configurations where CPU ids are not
strictly sequential.
- The GCC BPF support in some gcc/binutils releases did not offer a way to
express an atomic add operation. As a workaround, the DTrace source code
provides its own atomic_add() construct.
- The handling of associative arrays and TLS variables has been consolidated
because they are both implemented using dynamic variables.
Testsuite changes:
- The testsuite can now specify kernel modules that are needed for tests.
- A test has been added to verify whether libctf bug #30264 is present on the
system. The libctf bug breaks offsetof() for members of unnamed structs and
unions at non-zero offsets.
- A test has been added to test multiple simultaneous dtrace instances tracing
multiple processes,
- Various tests using tick-* probes without actually requiring them have been
reworked using non-timer based probes for efficiency and stability.
- Test have been added for many dtrace options.
- The testsuite can now support interpreter-style executable .d files using
#!dtrace (the actual pathname for dtrace will be substituted during test
execution).
Known problems:
- Programs and shared libraries that make use of is-enabled USDT probes and
were built using a previous version of dtrace will need to be rebuilt for
is-enabled probes to work.
2.0.0-1.12 (Feb 27th, 2023)
---------------------------
Twelfth errata of the standalone userspace implementation.
** This is a pre-release with limited functionality. **
New features:
- The bcopy() subroutine no longer enforces that its first argument (source
address) cannot be an alloca()'d memory region. While this restriction is
documented, it was never enforced in DTrace. There is no practical reason
for having this restriction.
- The clear() and tracemem() actions have been implemented.
- The 'switchrate' and 'aggrate' options have been implemented.
- The cpc and proc providers have been implemented.
- The copyout() and copyoutstr() subroutines have been implemented.
- The uregs[] built-in variable has been implemented.
Bugfixes:
- The maximum strtab size has been increased to SSIZE_MAX.
- Probe argument information will only be retrieved once per probe.
- Handling string values in alloca()'d memory has been fixed.
- The basename(), dirname(), strchr(), strrchr(), inet_ntoa() subroutines
have been updated to fully support using arbitrary address pointers.
- The return value of copyin() will now be a valid offset into scratchmem
(native representation of a pointer to alloca()'d memory).
- The arg0 and arg1 probe arguments for profile-* and tick-* probes have been
corrected. (The arg2 argument is still unimplemented.)
- The evaluation order of arguments to bcopy() has been corrected.
- Runtime bounds checking has been implemented for scalar array access.
Internal changes:
- Selection of the correct arch-dependent asm include hierarchy for building
the precompiled BPF function library has been corrected.
- A few potentially unsafe calls to printf-style functions have been fixed.
- The manpage for dtrace has been moved to section 8 (System Management
Commands).
- The error handling mechanism between libdtrace and consumer front-ends has
been amended to allow error reporting for non-probing related issues.
- The copyinstr() subroutine has been updated to make use of the temporary
string mechanism.
- The tracking of pointers to alloca()'d memory and pointer to DTrace managed
memory has been improved, and explicit tests for it have been added to the
testsuite.
- The code generator will use indirect load instructions for pointers to
alloca()'d and DTrace managed memory for efficiency and to enable the BPF
verifier to perform access checks.
Testsuite changes:
- The copyin*() tests are now more robust with the use of a distinct trigger.
- Various tests have been moved from XFAIL to PASS status to reflect the
implementation of new features and in view of some bug fixes.
- Various tests were improved.
- Various new tests were added.
Known problems:
- The uregs[] built-in variable is not supported on kernels prior to 5.15.
2.0.0-1.11.1 (Nov 9th, 2022)
----------------------------
Eleventh errata of the standalone userspace implementation.
** This is a pre-release with limited functionality. **
New features:
- The args[] built-in variable has been implemented.
- Support loading scalars from kernel space addresses.
- The copyin(), copyinto(), and copyinstr() subroutines have been implemented.
- A -xlockmem option has been added to adjust the kernel locked-memory limit.
When loading BPF maps or programs fails in a way that might indicate that
the locked-memory limit is too low, an error message is printed to suggests
using this new option.
- Support for aggregations indexed by a key (tuple) has been added.
- Disassembler annotations have been added for aggregation variables.
- The setopt() action has been implemented. A limited number of options is
currently supported.
- The pid provider has been changed to ignore compiler-generated internal
function names.
- The USDT provider has been implemented for basic use cases. Regular,
non-is-enabled probes are supported for executables that are referenced
explicitly (by pid) in the probe script. Argument mapping and wildcard
probe specifications are not supported yet.
New dependencies:
- The USDT provider support depends on the availability of libfuse version
2 or 3. At build time, preference is given to libfuse 3 if available.
The build process supports forcing building against libfuse 2 by passing
'libfuse2=yes' to the make command.
Upgrading:
- The USDT implementation depends on an always-running daemon (dtprobed):
the corresponding systemd dtprobed.service is automatically started in
relatively early boot in non-rescue scenarios, but when DTrace is first
installed, or if it is upgraded from a version before the daemon existed
(before 2.0.0-1.11), any probes in programs that were already running
before that point will not appear in DTrace's list of available probes
until such programs are restarted.
Bugfixes:
- Arguments of sdt-provider probes are now correctly populated using the
tracepoint data.
- Argument handling for dtrace:::, fbt:::return, pid:::, and syscall:::return
probes has been cleaned up.
- The dtrace utility is now able to handle multiple args after --.
- The -xcpp, -xctfpath, and -xverbose options have been fixed.
- Some bugs with typecasting and internal integer storage have been fixed.
- The libproc search of rtld_global has been improved for glibc changes.
- In procfs.d, projid_t was renamed to resolve a conflict with the kernel.
- In the parser, support has been added for slices of typedefs.
- String comparison involving non-DTrace pointers has been fixed.
- The value of the execname built-in variable is now correctly recognized as
a non-DTrace pointer.
Internal changes:
- The code generator is able to adapt to BPF-helper-function availability
differences between runtime kernels.
- Read-only blocks of zeros for initializing BPF maps have been consolidated.
- Tuples are now constructed with their component values at predictable
offsets based on their datatype rather than their value..
- Support for the BPF dt_bpf_map_next_key() helper to iterate over the keys
in a BPF map has been added.
- Support for multiple copies of aggregation data (DT_AGG_NUM_COPIES) is no
longer needed and has been removed.
- Support for creating a map (array or hash) of maps has been added, including
functions to perform lookups and updates of inner maps.
- The storage of aggregation data has been modified to make use of an array of
BPF hash maps, indexed by CPU id. As a result, aggregation data for each
CPU is stored in its own BPF hash map and can be modified without affecting
the data for other CPUs.
- Error reporting for BPF program load, map creation, CTF, and dlib load has
been cleaned up.
- Some code has been refactored and some obsolete code removed.
Testsuite changes:
- Add support for '-e' in test options.
- Tests that are expected to fail have improved xfail messages.
- Support has been added for more stringent, @@nosort checking.
- Problems with "unstable" tests are report as XFAIL.
- Tests that fire many times (historically using tick-n) are more robust.
- Various tests have been moved from XFAIL to PASS status to reflect the
implementation of new features and in view of some bug fixes.
- Various tests were improved.
Known problems:
- On some aarch64 systems the copyin(), copyinstr(), and copyinto()
subroutines may report a fault due to limitations in the BPF implementation
at the kernel level. This problem seems to be related to specific CPU
features.
2.0.0-1.10 (Apr 26th, 2022)
---------------------------
Tenth errata of the standalone userspace implementation.
** This is a pre-release with limited functionality. **
New features:
- The trace() action supports array, struct, and union values.
- The execname built-in variables is now implemented.
- The inet_ntoa() subroutine has been implemented.
- The progenyof() subroutine has been implemented.
- The getmajor() and getminor() subroutines have been implemented.
- The mutex_owned(), mutex_owner(), mutex_type_adaptive(), mutex_type_spin(),
rw_read_held(), rw_write_held(), and rw_iswriter() have been implemented.
- The alloca() and bcopy() subroutines have been implemented.
- Associative arrays have been implemented. They are supported for both
global and TLS variables.
- Disassembler annotations have been added for associative arrays, register
spills, and string constants.
- The translators have been updated to support up to kernel series 5.16.
- Faults will now report the PC (program counter) where the fault is reported.
Bugfixes:
- Register allocation leaks were fixed.
- NULL pointer verification has been optimized to avoid checking the same
pointer more than once.
- NULL pointers handling in ternary conditionals are now supported.
- Casting of pointers to integers has been fixed.
- Negative (immediate) values in signed conditionals are now printed
correctly.
- Disassembler annotations for TLS variables have been corrected.
- The DIFO strtab handling has been reworked to fix multiple bugs.
Internal changes: