-
Notifications
You must be signed in to change notification settings - Fork 575
/
Copy pathrelease.dox
2396 lines (2236 loc) · 129 KB
/
release.dox
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
/* ******************************************************************************
* Copyright (c) 2010-2025 Google, Inc. All rights reserved.
* Copyright (c) 2011 Massachusetts Institute of Technology All rights reserved.
* Copyright (c) 2008-2010 VMware, Inc. All rights reserved.
* ******************************************************************************/
/*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* * Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* * Neither the name of VMware, Inc. nor the names of its contributors may be
* used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
* DAMAGE.
*/
/**
***************************************************************************
***************************************************************************
***************************************************************************
\page release_notes Release Notes for Version \DR_VERSION
This section is divided into the following subsections:
- \ref sec_package
- \ref sec_changes
- \ref sec_limits
- \ref sec_future
***************************************************************************
\htmlonly
<table width=100% bgcolor="#000000" cellspacing=0 cellpadding=2 border=0>
<tr><td><table width=100% bgcolor="#0000C0" cellspacing=0 cellpadding=1 border=0>
<tr><td><table width=100% bgcolor="#0000C0" cellspacing=0 cellpadding=1 border=0>
<tr><td></td></tr></table></td></tr></table></td></tr></table>
\endhtmlonly
\section sec_package Distribution Contents
The following are part of the DynamoRIO release distribution:
\if profiling
PR 225255: list profile library too
\endif
- Four different DynamoRIO libraries: debug and release for each of
32-bit and 64-bit (for ARM or AArch64 builds, only a single bitwidth
matching the ISA is provided).
The debug library enables assertion messages to more easily diagnose
API usage errors.
- Four different IA-32/AMD64/ARM/AArch64 decoding static libraries: debug and release
for each of 32-bit and 64-bit (only 32-bit for ARM and 64-bit for AArch64).
The debug library enables assertion messages to more easily diagnose
API usage errors.
- A variety of DynamoRIO Extension libraries that augment the core
DynamoRIO API (see \ref page_ext).
- Additional Extension libraries from the Dr. Memory Framework (DRMF).
If this documentation is part of a DynamoRIO public release, <a
href="../../drmemory/drmemory/docs/html/page_drmf.html">this link</a> should
point at the local documentation for DRMF.
- The DynamoRIO configuration and execution libraries and command-line
utilities \c drconfiglib.dll, \c drinjectlib.dll, \c drfrontendlib.lib,
\c drconfig.exe, \c drrun.exe, and \c drinject.exe.
On Linux, the tools are named \c drconfig, \c drrun, and \c drinject.
- A utility \c drview.exe for viewing which processes
are running under DynamoRIO control (Windows package only).
- Header files for the DynamoRIO APIs.
- This documentation.
- \ref API_samples "Sample clients".
- A graphical statistics viewer \c DRstats.exe that displays internal
DynamoRIO statistics as well as custom statistics defined
by a client (see \ref sec_drstats) (Windows package only).
DynamoRIO exports a large number of statistics in its debug build, and
a handful in release builds.
- A binary tracedump reader, which also functions as a sample
client using DynamoRIO as a standalone library (see \ref
sec_standalone).
- A number of end-user tools including a code coverage tool (see \ref
page_drcov), a multi-process cache simulator (see \ref page_drcachesim),
a last-level cache miss analyzer (see \ref page_drcachesim),
and a legacy CPU testing tool (see \ref page_drcpusim).
If this is a DynamoRIO public release, it also includes the
Dr. Memory memory debugging tool (see \ref page_drmemory), a system call
tracer for Windows (see \ref page_drstrace), a library tracing tool (see
\ref page_drltrace), and a symbol querying tool (see \ref page_symquery).
When unpacking the release package on Windows, be aware that the Cygwin
unzip utility does not preserve executable permissions properly. After
unzipping with Cygwin, add ugo+rx permissions to all of the .dll and .exe
files in the resulting directory tree:
\code
find . -name \*.dll -exec chmod ugo+rx {} \; -o -name \*.exe -exec chmod ugo+rx {} \;
\endcode
***************************************************************************
\htmlonly
<table width=100% bgcolor="#000000" cellspacing=0 cellpadding=2 border=0>
<tr><td><table width=100% bgcolor="#0000C0" cellspacing=0 cellpadding=1 border=0>
<tr><td><table width=100% bgcolor="#0000C0" cellspacing=0 cellpadding=1 border=0>
<tr><td></td></tr></table></td></tr></table></td></tr></table>
\endhtmlonly
\section sec_changes Changes Since Prior Releases
The current version is \DR_VERSION. It includes Dr. Memory and the
Dr. Memory Framework (DRMF) in the same package as DynamoRIO. DRMF
provides the umbra, drsyscall, and drsymcache Extensions for use by
clients.
The changes between version \DR_VERSION and 11.3.0 include the following compatibility
changes:
- On 32-bit Arm the size of #dr_mcontext_t has been increased by 4 and the
struct is now required to be 8-byte aligned. The offset of the field "simd"
has changed.
- Added new fields elf_path and elf_path_size to dr_memory_dump_spec_t. When
dr_create_memory_dump() returns true and elf_path is not NULL, elf_path will be
written with the path to the memory dump file.
Further non-compatibility-affecting changes include:
- Added support for reading a single drmemtrace trace file from stdin
via "-infile -".
- Added the #dynamorio::drmemtrace::decode_cache_t library to make it easier and more
efficient for drmemtrace analysis tools to obtain decoded information about
instructions in the trace. This works for traces that have embedded instruction
encodings in them, and also for legacy traces without embedded encodings where the
encodings are obtained from the application binaries instead.
**************************************************
<hr>
The changes between version 11.3.0 and 11.2.0 include the following compatibility
changes:
- No compatibility changes yet.
Further non-compatibility-affecting changes include:
- Added support for statically linking clients and the DynamoRIO library into
a pure-static application via a new configure_DynamoRIO_static_client() CMake
function and new "_drstatic" static library CMake targets for the provided
extension libraries.
- Allow v2p.textproto file in a trace directory. This file is present in public traces.
- Allow v2p.textproto file to have one missing virtual_address field, which indicates
virtual_address == 0x0. Necessary in case a trace accesses virtual address 0x0.
- Added noise_generator_t scaffolding as a reader_t to produce synthetic trace records.
- Added -enable_noise_generator and -noise_generator_num_records as flags and scheduler
options.
**************************************************
<hr>
The changes between version 11.2.0 and 11.1.0 include the following compatibility
changes:
- Added #dynamorio::drmemtrace::TRACE_ENTRY_VERSION_RETIRED_INSTRUCTIONS_ONLY to
increase the trace version for drmemtraces with uncompleted instructions removed.
Further non-compatibility-affecting changes include:
- Added instr_get_operation_size() and instr_set_operation_size() APIs for
#DR_ISA_REGDEPS #instr_t.
**************************************************
<hr>
The changes between version 11.1.0 and 11.0.0 include the following compatibility
changes:
- Removed uncompleted instructions and the corresponding memrefs from drmemtraces.
Instructions which are fetched but not completed due to asynchronous signal or
fault are removed. A new marker
#dynamorio::drmemtrace::TRACE_MARKER_TYPE_UNCOMPLETED_INSTRUCTION was added
to indicate an uncompleted instruction was removed. The value of the marker
is the encoding of the removed instruction up to a pointer's length.
OFFLINE_FILE_VERSION_RETIRED_INSTRUCTIONS_ONLY was added by mistake and it was changed to
#OFFLINE_FILE_VERSION_NO_OP.
- Moved module file read logic into read_module_file() in raw2trace_shared, and
removed raw2trace_directory_t::initialize_module_file() since the
read_module_file() can be directly used without having to pull in the whole
raw2trace_directory_t.
Further non-compatibility-affecting changes include:
- Added X64 Linux support to dr_create_memory_dump(). This API has the same
restriction as dr_suspend_all_other_threads_ex(). For X86_64 platform, the feature is
supported only when fast FP save and restore is supported. And mixed mode is not
supported.
- Added the AArch64 FPMR register as DR_REG_FPMR.
- Added OPSZ_addr which chooses the appropriate operand size on X86 from 2/4/8 based
on the 32/64 bit mode and the presence or absence of the address size prefix.
- Fixed the order of operands for the vpexpandd/vpexpandq opcodes (previously the
source and destination operands were reversed).
- Fixed the VEX-encoded forms of vaesdec/vaesdeclast/vaesenc/vaesenclast/vpclmulqdq
to obey VEX.L, which they previously ignored.
**************************************************
<hr>
The changes between version 11.0.0 and 10.0.0 include the following compatibility
changes:
- Marked x86 rep instructions as predicated.
- The #dr_instr_category_t enum underwent changes to support new categories
such as STATE, MOVE, CONVERT, and MATH.
INT_MATH has been removed and replaced with MATH.
FP_MATH has been removed and replaced with FP|MATH.
The enumeration was organized in a different order, the old numbers become invalid
- The #dynamorio::drmemtrace::TRACE_MARKER_TYPE_FUNC_RETVAL marker for system
calls changed to contain the actual return value, rather than just whether
successful. A new marker #dynamorio::drmemtrace::TRACE_MARKER_TYPE_SYSCALL_FAILED
was added to indicate failure.
- Changed the enum value of #dynamorio::drmemtrace::scheduler_t::DEPENDENCY_TIMESTAMPS
to include direct switch dependencies. This is not a binary compatibility change
as the old value still refers purely to timestamps, but on a recompile it
refers to timestamps and direct switches, which is what most users should want.
- Rename the macro INSTR_CREATE_mul_sve to INSTR_CREATE_mul_sve_imm to
differentiate it from the other SVE MUL instructions.
- Renamed a protected data member in #dynamorio::drmemtrace::analyzer_tmpl_t from
merged_interval_snapshots_ to whole_trace_interval_snapshots_ (may be relevant for
users sub-classing analyzer_tmpl_t).
- Converted #dynamorio::drmemtrace::analysis_tool_tmpl_t::interval_state_snapshot_t
into a class with all its data members marked private with public accessor functions.
- Changed the type of the AArch64 #dr_mcontext_t members svep and ffr to #dr_svep_t.
This breaks binary compatibility with clients that were built against versions of
DynamoRIO before this change.
- Changed #dynamorio::drmemtrace::record_filter_t::record_filter_func_t
parallel_shard_filter() interface. Added a new parameter of type
#dynamorio::drmemtrace::record_filter_t::record_filter_info_t that allows
#dynamorio::drmemtrace::record_filter_t to share data with its filters.
- Changed the way we cache the feature register values on AArch64. We now use an array of
uint64 values rather than individual variables for each feature register. This
allows the code to be more readable and easier to maintain.
- Renamed dr_set_sve_vector_length() to dr_set_vector_length() to share function
signature between AArch64 and RISC-V.
- Renamed dr_get_sve_vector_length() to dr_get_vector_length() to share function
signature between AArch64 and RISC-V.
- Changed the drcachesim -LL_miss_file option by adding a process ID field to the output.
This helps in better analyzing cache misses in multi-process environments.
Further non-compatibility-affecting changes include:
- Added DWARF-5 support to the drsyms library by linking in 4 static libraries
from elfutils. These libraries have LGPL licenses.
- Added raw2trace support to inject system call kernel trace templates collected from
elsewhere (e.g., QEMU, Gem5) into the user-space drmemtrace traces at the
corresponding system call number marker. This is done by specifying the path to the
template file via the new -syscall_template_file option.
- Added a new scheme for the modoffs field in the PC trace entry which allows L0
filtering of non-module code; see
#dynamorio::drmemtrace::ENCODING_FILE_TYPE_SEPARATE_NON_MOD_INSTRS. Also added
file type entry to the header of encoding files.
- Fixed a bug in the AArch64 codec with the way that SVE scalar+immediate predicated
contiguous load and store instructions represented the immediate offset in the IR.
In 10.0.0 the memory operand in these instruction used the immediate value from the
instruction (which is an index to be scaled by the vector length) as the displacement,
whereas the displacement value in a DynamoRIO memory operand should always be a byte
offset. This has now been corrected.
Traces and other tool results created with DynamoRIO prior to this fix may have
incorrect results if the application contained these instructions.
See <a href="https://github.com/DynamoRIO/dynamorio/pull/6390">PR #6390</a> for the
full list of affected instructions.
- Added core-sharded analysis tool support where traces are sharded by
core instead of by thread, with the thread schedules onto the cores
either following how they were traced or using a dynamic schedule.
Adds #dynamorio::drmemtrace::shard_type_t passed to initialize_shard_type()
to inform tools of the shard type.
Adds a new memtrace_stream_t::get_output_cpuid() query.
Adds a number of drcachesim options to set sharding mode (-core_sharding,
-core_serial) and control the schedule
(-sched_quantum, -sched_time, sched_order_time, -record_file,
-replay_file, -cpu_schedule_file).
- Added additional timestamps to drmemtrace traces: at the end of each buffer,
and before and after each system call.
- Added type_is_read() API that returns true if a trace type reads from memory.
- Added instr_num_memory_read_access() and instr_num_memory_write_access() that return
the number of memory read and write accesses of an instruction respectively.
- Added realloc to the set of functions traced by -record_heap by default.
- Deprecated #dr_fp_type_t for Floating-Point operation types in favor of the new
#dr_instr_category_t.
Deprecated instr_is_floating_ex(), replacing it with instr_is_floating_type().
The old versions will continue to work.
- Added several routines to the #dynamorio::drmemtrace::memtrace_stream_t interface
for drmemtrace analysis tools: get_output_cpuid(), get_workload_id(),
get_input_id(), get_input_interface().
- Added -record_syscall to drmemtrace for recording syscall parameters.
- Added opportunity to run multiple drcachesim analysis tools simultaneously.
- Added support of loading separately-built analysis tools to drcachesim dynamically.
- Added instr_is_opnd_store_source().
- Added kernel context switch sequence injection support to the drmemtrace scheduler.
- Added dr_running_under_dynamorio().
- Added instr_get_category_name() API that returns the string version (as char*) of a
category.
- Added #dynamorio::drmemtrace::TRACE_MARKER_TYPE_VECTOR_LENGTH marker to indicate the
current vector length for architectures with a hardware defined or runtime changeable
vector length (such as AArch64's SVE scalable vectors).
- Added a new drmemtrace analyzer option \p -interval_instr_count that enables trace
analyzer interval results for every given count of instrs in each shard. This mode
does not support merging the shard interval snapshots to output the whole-trace
interval snapshots. Instead, the print_interval_results() API is called separately
for each shard with the interval state snapshots of that shard.
- Added a new finalize_interval_snapshots() API to
#dynamorio::drmemtrace::analysis_tool_t to allow the tool to make holistic
adjustments to the interval snapshots after all have been generated, and before
they are used for merging across shards (potentially), and printing the results.
- Added opnd_is_vector_base_disp() to test if an opnd_t is a base+disp memory operand
that uses a vector register for the base or index register.
- Added -abort_on_invariant_error flag that instructs the invariant checker drmemtrace
analysis tool to abort trace analysis when a trace invariant error is found. This
is set to true by default to match the existing behavior of the invariant checker.
- Added a new instr API instr_is_xrstor() that tells whether an instruction is any
variant of the x86 xrstor opcode.
- Added a new #dr_isa_mode_t: #DR_ISA_REGDEPS, which is a synthetic ISA with the main
purpose of preserving register dependencies.
- Added instr_convert_to_isa_regdeps() API that converts an #instr_t from a real ISA
(e.g., #DR_ISA_AMD64) to the #DR_ISA_REGDEPS synthetic ISA.
- Added encodings2regdeps_filter_t filter to #dynamorio::drmemtrace::record_filter_t to
generate #DR_ISA_REGDEPS traces.
- Added #dynamorio::drmemtrace::OFFLINE_FILE_TYPE_ARCH_REGDEPS file type for
#DR_ISA_REGDEPS traces.
- Added -tool as the preferred alias for -simulator_type for the drmemtrace/drcachesim
trace analysis tool framework.
- Added "-t drmemtrace" as the preferred launcher for the drmemtrace/drcachesim
trace analysis tool framework.
- Added func_id_filter_t to #dynamorio::drmemtrace::record_filter_t to filter function
markers based on the function ID. This filter is enabled by "-filter_keep_func_ids"
followed by a comma-separated list of function IDs to preserve in the output trace.
All function markers whose ID is not in the list are removed.
- Added -skip_to_timestamp and #dynamorio::drmemtrace::scheduler_tmpl_t::
input_workload_t::times_of_interest to the drmemtrace scheduler.
- Added v2p_reader_t to parse a virtual-to-physical mapping in textproto format and
v2p_info_t to hold that mapping in memory.
- Added -v2p_file option to drcachesim TLB tool to set the path to a v2p.textproto file,
which provides a virtual to physical mapping of addresses for an offline trace. This
option overwrites both -page_size and
#dynamorio::drmemtrace::TRACE_MARKER_TYPE_PAGE_SIZE (if present) with the page size in
v2p.textproto. Option -use_physical (in offline mode) must also be set to use the
mapping in v2p.textproto (note that -use_physical during tracing is not necessary, nor
related to -use_physical offline).
- Added -trace_instr_intervals_file option to the drmemtrace trace analysis tools
framework. The file must be in CSV format containing a <start,duration> tracing
interval per line where start and duration are expressed in number of instructions.
- Added modify_marker_value_filter_t to #dynamorio::drmemtrace::record_filter_t to modify
the value of TRACE_MARKER_TYPE_ markers. This filter takes a list of
<TRACE_MARKER_TYPE_,new_value> and changes every listed marker in the trace to its
corresponding new_value.
- Added trace_analysis_tool::preferred_shard_type() to the drmemtrace framework to
allow switching to core-sharded by default if all tools prefer that mode.
- For the drmemtrace framework, if only core-sharded-preferring tools are enabled
(these include cache and TLB simulators and the schedule_stats tool), -core_sharded or
-core_serial is automatically turned on for offline analysis to enable more
representative simulated software thread scheduling onto virtual cores.
**************************************************
<hr>
The changes between version 10.0.0 and 9.0.1 include the following compatibility
changes:
- Eliminated the -skip_syscall option to drrun and drinject, which is now always
on by default.
- Changed the drcachesim -use_physical option to not modify the regular trace
entry virtual addresses but to instead insert metadata containing translation
information for converting virtual to physical addresses.
- Changed the layout of the DR_FAST_IR struct to add an element size property
that supports more information about vectors. This changes the method of accessing
the register in the structure from struct.value.reg to
struct.value.reg_and_element_size.reg. The element size can be accessed directly
via struct.value.reg_and_element_size.element_size.
- Changed the size of the #instr_t structure by appending a field which is used
for relative offsets while encoding. The note field is no longer modified
during encoding.
- Reduced the value of #DR_NOTE_FIRST_RESERVED. This is not expected to cause
problems unless clients are directly choosing high note values without using
drmgr_reserve_note_range().
- Changed the values of the AArch64 DR_REG_Z* constants so that Z registers can be
used in base+disp operands in SVE scatter/gather instructions. This breaks binary
compatibility for clients built against an older version of opnd_api.h, but source
code compatibility is unchanged.
- Removed the drcachesim external iterator analyzer interface. Users should instead
use the new #dynamorio::drmemtrace::scheduler_tmpl_t interface for direct control
over iteration. See \ref sec_drcachesim_sched for example code.
- Refactored the drmemtrace reader and file reader classes to better fit the
new scheduler model: now each reader owns just one single stream of records
with all multi-stream interleaving owned by the scheduler.
- Replaced the AArch64 OP_reta with OP_retaa and OP_retab. "reta" is not a real
AArch64 instruction and "reta" entries in the AArch64 codec were being used to
decode "retaa" and "retab". These instructions will now encode and decode correctly
as "retaa" and "retab".
- Added a #DR_XFER_RSEQ_ABORT event for a signal generated during an rseq region.
- Changed the interrupted PC for #DR_XFER_RSEQ_ABORT for native execution aborts to be
the abort handler (a signal during the instrumented execution will continue to have
the actual interrupted PC); changed the interrupted PC for #DR_XFER_SIGNAL_DELIVERY
for a signal generated during an rseq region to be the abort handler, matching the
kernel behavior.
- Changed the arguments and decode behavior of the INSTR_CREATE_orr_sve_pred(),
INSTR_CREATE_eor_sve_pred(), INSTR_CREATE_and_sve_pred() and
INSTR_CREATE_bic_sve_pred() to use the new vector element registers and to
correctly encode the predicate mode.
- ud2a and ud2b have been renamed to ud2 and ud1, respectively. The old constants
#OP_ud2a and #OP_ud2b, as well as the #INSTR_CREATE_ud2a()/#INSTR_CREATE_ud2b()
macros, are \#defined to the new names, #OP_ud2, #OP_ud1, #INSTR_CREATE_ud2(),
and #INSTR_CREATE_ud1() respectively. ud1 now correctly accounts for its operands
so manipulation of ud1 is not backwards compatible.
- All drcachesim/ code was changed to use the dynamorio::drmemtrace namespace.
External code using any drcachesim or drmemtrace library will need to be
recompiled.
- The droption header library is now inside the dynamorio::droption namespace.
- The drmemtrace record type #dynamorio::drmemtrace::TRACE_TYPE_INSTR_CONDITIONAL_JUMP
is deprecated in offline traces where it is replaced by
#dynamorio::drmemtrace::TRACE_TYPE_INSTR_TAKEN_JUMP and
#dynamorio::drmemtrace::TRACE_TYPE_INSTR_UNTAKEN_JUMP.
- All int_least64_t and uint_least64_t types in drcachesim were replaced with
their precise counterparts int64_t and uint64_t.
- The #dynamorio::drmemtrace::memref_t structure has a new field appended for
holding the actual target of each indirect branch.
- Increased the size of dr_simd_t to accommodate AArch64's Scalable Vector
Extension (SVE) as well as adding two new dr_simd_t instances to
#dr_mcontext_t: SVE predicate registers svep[] and the SVE first-fault
register, ffr. This is a significant binary compatibility change and will
require re-building clients built before SVE was added.
- The #instr_t structure has a new field inserted for holding the category type
#dr_instr_category_t which changes the size and the offsets of most fields
in 32-bit. 64-bit compatibility is not affected.
Further non-compatibility-affecting changes include:
- Added new drmemtrace option -L0_filter_until_instrs which enables filtering
for the specified instruction count before switching to full instruction tracing.
Such bimodal filtered traces have #dynamorio::drmemtrace::OFFLINE_FILE_TYPE_BIMODAL_FILTERED_WARMUP
in their file type, and a #dynamorio::drmemtrace::TRACE_MARKER_TYPE_FILTER_ENDPOINT marker
at the point in the trace when filtering ended.
- Added AArchXX support for attaching to a running process.
- Added new fields analyze_case_ex and instrument_instr_ex to #drbbdup_options_t.
- Added drbbdup support to drwrap via #DRWRAP_INVERT_CONTROL, drwrap_invoke_insert(),
and drwrap_invoke_insert_cleanup_only().
- Added -trace_for_instrs and -retrace_every_instrs options to drcachesim
for periodic trace bustrs of an unmodified application.
- Added compression of drmemtrace raw offline files with various compression
choices under the -raw_compress option. Compressing with lz4 is now the
default (if built with lz4 support).
- Added drmodtrack_lookup_pc_from_index().
- Added -use_physical support to drcachesim offline traces using three new
marker types: #dynamorio::drmemtrace::TRACE_MARKER_TYPE_PHYSICAL_ADDRESS,
#dynamorio::drmemtrace::TRACE_MARKER_TYPE_VIRTUAL_ADDRESS, and
#dynamorio::drmemtrace::TRACE_MARKER_TYPE_PHYSICAL_ADDRESS_NOT_AVAILABLE.
- Added an open-address hashtable implementation for cases where third-party
libraries must be avoided and open addressing is best: dr_hashtable_create(),
dr_hashtable_destroy(), dr_hashtable_clear(), dr_hashtable_lookup(),
dr_hashtable_add(), dr_hashtable_remove().
- Added a new #dynamorio::drmemtrace::TRACE_MARKER_TYPE_PAGE_SIZE record to drcachesim offline traces.
- Added new drmemtrace options -L0I_filter and -L0D_filter that allow enabling
online filtering for only instruction or only data entries respectively. The
old option -L0_filter is deprecated but still supported for backward
compatibility. It simply sets both the new options.
- Added a new DR extension, namely "drpttracer", which provides clients with tracing
functionality via Intel's PT instruction tracing feature. This feature is still
experimental and available only on Intel processors.
- Added a new drmemtrace option -enable_kernel_tracing that allows recording each
syscall's Kernel PT and writes every syscall's PT and metadata to files in
-outdir/kernel.raw/ for later offline analysis. This feature is still experimental
and available only on Intel processors that support the Intel@ Processor Trace
feature.
- Added drmemtrace_get_encoding_path().
- Added preliminary support for generated code to drmemtrace.
- Changed the default drmemtrace offline file format from .gz to .zip and
added the option -chunk_instr_count to control the split of a file within
the .zip, which sets the granularity of a fast seek.
- Added dr_register_post_attach_event(), dr_unregister_post_attach_event(),
dr_register_pre_detach_event(), and dr_unregister_pre_detach_event().
- Added instruction encodings to drmemtrace offline traces.
- Added drmemtrace_replace_file_ops_ex().
- Added -align_endpoints to drmemtrace to avoid uneven attach/detach periods.
- Added a method of representing vector registers with element sizes.
They can be created with opnd_create_reg_element_vector(), detected with
opnd_is_element_vector_reg() and have their element size retrieved by
opnd_get_vector_element_size().
- Deprecated the drmemtrace analysis tool functions initialize() and
parallel_shard_init(), replacing them with initialize_stream() and
parallel_shard_init_stream(). The old versions will continue to work.
The stream interface passed to analysis tools provides tools with the
record and instruction ordinals along with the values of top-level
headers.
- Added #dynamorio::drmemtrace::record_analyzer_t and #dynamorio::drmemtrace::record_analysis_tool_t for analyzing the
sequence of #dynamorio::drmemtrace::trace_entry_t exactly as present in a stored offline trace.
- Added opnd_size_to_shift_amount() and opnd_create_base_disp_shift_aarch64()
for explicitly specifying shift amounts in the creation of operands for
AArch64 memory addresses.
- Added opnd_create_increment_reg() to create a register from an existing
register whose register number is incremented by some amount, wrapping
at the max register number for that register.
- Added opnd_create_vector_base_disp_aarch64() and reg_is_z() for creating
memory address operands that use SVE Z registers with a specified element
size.
- Added a new #dynamorio::drmemtrace::scheduler_tmpl_t interface providing scheduling
of drmemtrace offline files onto configurable output streams, meant for use by
microarchitectural simulators.
- Added a #dynamorio::drmemtrace::memtrace_stream_t interface for drmemtrace analysis tools to
query key attributes of each input trace.
- Added instr_create_1dst_6src() convenience function that returns an instr_t
with one destination and six sources.
- Added a new label to help in handling "rseq" (Linux restartable sequence) regions:
#DR_NOTE_RSEQ_ENTRY.
- Added instr_get_offset() API for getting the offset of an instr in an instrlist that
has been encoded with instrlist_encode* set of APIs.
- Added a new drmemtrace analyzer option \p -interval_microseconds and various new
#dynamorio::drmemtrace::analysis_tool_t APIs for producing per-interval results. The analyzer framework
invokes the generate_interval_snapshot() and generate_shard_interval_snapshot()
analysis tool APIs periodically every \p -interval_microseconds of the trace as
measured by the #dynamorio::drmemtrace::TRACE_MARKER_TYPE_TIMESTAMP marker values. In these callbacks, the
tool creates and returns a snapshot of their internal state that is required to
produce and print per-interval results in a later print_interval_results() call.
The tool's internal state is a struct derived from the
#dynamorio::drmemtrace::analysis_tool_tmpl_t::interval_state_snapshot_t base struct. Additionally, the tool
implements combine_interval_snapshot() to combine two interval snapshot structs,
which is required for producing whole-trace results in the parallel mode of analyzer
operation, and also release_interval_snapshot() which is used to release the
analyzer framework's claim to the interval snapshot objects.
- Added a new drmemtrace analysis tool: syscall_mix, to count frequency of system
calls in a trace. This tool works in both the online and offline modes of
drmemtrace.
- Added proc_get_vector_length_bytes() for AArch64. This returns the current
vector length on all ARMv8 hardware including hardware which supports the
Scalable Vector Extension (SVE).
**************************************************
<hr>
The changes between version 9.0.1 and 9.0.0 include the following compatibility
changes:
- Introduced a new CMake option called BUILD_PACKAGE to skip glibc
compatibility checks. This is off by default such that building DynamoRIO
from source is straight-forward to do on rolling release Linux
distributions, and enabled by make/package.cmake when building a
distributable version of DynamoRIO.
Further non-compatibility-affecting changes include:
- Fixed a significant performance regression between 8.0.0 and 9.0.0
(between 8.0.18740 and 8.0.18747) affecting Windows programs with
varying indirect branches on hot code paths.
- Added alias support to droption.
- The drcpusim option -blacklist was renamed to -blocklist but the old name
is still accepted.
- Added droption_parser_t::clear_values() for re-setting accumulating option
values on re-attach for statically linked clients.
- Added the count of cache exits to #dr_stats_t.
- Added dr_register_inject_paths() and a corresponding -use_alt_dll drrun/drconfig
parameter for control over DynamoRIO library paths, in particular the other
bitwidth path, when configuring target processes.
- Added -tool_dir drrun/drconfig parameter to control where to look for tool
config files.
**************************************************
<hr>
The changes between version 9.0.0 and 8.0.0 include the following compatibility
changes:
- The AArch64 opcode enum ordering changed.
- A source compatibilty change in drcachesim analysis tools for users
who have created derived classes from existing analysis tools:
member fields of classes are now following a consistent style with
an underscore suffix. References to renamed fields will need to be
updated.
- A change in the load callbacks used with drmodtrack_add_custom_data()
and drmemtrace_custom_module_data(): they each take an additional parameter, the
segment index. The custom data field is now per-segment and not per-module,
and all callbacks are invoked separately for each segment.
The changes between version \DR_VERSION and 8.0.0 include the following minor
compatibility changes:
- drconfiglib (and thus drrun and drconfig) now sets only the new client path
options which are added in this release to support other-bitwidth child processes.
This means that a drconfiglib from this version will not properly configure for a
DynamoRIO core library from a prior version.
- A new option -ldstex2cas is on by default on ARM and AArch64. This converts
load-exclusive store-exclusive sequences to use compare-and-swap instead,
which enables normal instrumentation of such sequences without clearing
the exclusive monitor and causing infinite loops. However, the compare-
and-swap's semantics are not identical: it does not detect "ABA" changes and
could cause errors in lock-free data structures or other application constructs.
See \ref sec_ldrex for more information.
- The header file dr_tools.h has been split up, with module information now in a new
file dr_modules.h, os-specific queries in dr_os_api.h, and tracedump types in
dr_tracedump.h. dr_api.h includes the new files, so users including dr_api.h are
unaffected.
- The header files dr_ir_utils.h, dr_ir_opnd.h, dr_ir_instr.h, and dr_ir_instrlist.h
have been split up, with encoding routines now in a new file dr_ir_encode.h,
decoding routines in dr_ir_decode.h, disassembly routines in dr_ir_disassemble.h.
dr_api.h includes the new files, so users including dr_api.h are unaffected.
- The routines dr_insert_save_fpstate(), dr_insert_restore_fpstate(),
and dr_insert_get_seg_base() moved from dr_proc.h to dr_ir_utils.h.
- Added a flags field to #emulated_instr_t and two emulator-set flags values:
#DR_EMULATE_REST_OF_BLOCK, indicating an emulation sequence that has no end label
and includes the rest of the block; and #DR_EMULATE_INSTR_ONLY, indicating
an emulation for which instrumentation should still examine the
emulation sequence for observing data operations. A third value is set by
drmgr_in_emulation_region(): #DR_EMULATE_IS_FIRST_INSTR. This flag addition preserves
binary compatibility, but source code that did not zero the structure could end
up with an uninitialized flags field when calling drmgr_insert_emulation_start().
- drcov's output now uses a module segment offset, rather than a module base offset.
This better supports modules with code beyond the first segment and with
gaps between segments.
- Changed the drcachesim view tool's behavior to count all trace entries, rather
than just instructions, with respect to the -skip_refs and -sim_refs flags.
This matches the cache and TLB simulator behavior.
- drcachesim's child cache statistics now include hits from all lower levels and
not just the immediately lower level child caches.
- For AArch64 the OP_sys opcode is still implemented but has been split up
into its data and instruction cache opcodes. In cases where OP_sys was used
with enums representing data and instruction cache opcodes, OP_sys is no
longer used, replaced by the relevant data and instruction cache opcodes
starting with OP_dc_ and OP_ic_, e.g. OP_ic_ivau, OP_dc_zva.
Further non-compatibility-affecting changes include:
- On x86 Windows, different-bitwidth child processes are now followed into.
The default injection method has also changed to a new method relying on
an image entry hook in some cases. The old behavior can be requested by
passing "-late" to drrun or calling dr_inject_use_late_injection().
- Added drmgr_register_opcode_instrumentation_event() and
drmgr_unregister_opcode_instrumentation_event() so that drmgr supports
opcode event instrumentation.
- Added dr_num_app_args(), dr_get_app_args() and dr_app_arg_as_cstring() to
enable the gathering of application command-line args. Currently, implemented
for Unix systems only.
- Added dr_get_error_code() to obtain the error code of the last failed API routine.
Not all API routines support the setting of error codes. Please look at their
documentation to check if they do.
- Added -instr_only_trace option to drcachesim.
- Added other-bitwidth child process support, with the other client library
specified by "-c32" "-c64" to drrun or drdeploy, by dr_register_client_ex()
with #dr_config_client_t.is_alt_bitwidth=true to drconfiglib, and by
CLIENT{32,64}_{ABS,REL} in tool files.
Added dr_get_client_info_ex() and dr_client_iterator_next_ex() to support
querying other-bitwidth client registration.
- Added a new drcachesim option \p -max_global_trace_refs for specifying a global
trace size limit that does not terminate the process.
- Added opnd_create_immed_double(), opnd_get_immed_double() and
opnd_is_immed_double() to enable the creation and handling of double
precision floating-point operands.
- Added dr_flush_region_ex API that accepts a callback to be executed after synch
flush but before the threads are resumed. The existing dr_flush_region API
is modified to invoke dr_flush_region_ex with a NULL callback.
- Added instr_is_exclusive_load().
- Added XINST_CREATE_store_pair() and XINST_CREATE_load_pair().
- Added instr_replace_reg_resize() and opnd_replace_reg_resize().
- Added #DRX_COUNTER_REL_ACQ flag to optionally enable release-acquire semantics for
drx_insert_counter_update() on AArchXX.
- Added a preferred base field to the #_module_data_t struct and to the
#_drmodtrack_info_t struct.
- Added support for running under QEMU via the \ref op_xarch_root "-xarch_root"
runtime option which locates guest system libraries and enables workarounds for
problems with QEMU's threads.
- Added dr_is_detaching(), an API to query whether detach is in progress.
- Added instr_zeroes_zmmh() that returns true if an instruction clears the
upper bits of a ZMM register with zeros.
- Added instr_clear_label_callback().
- Added #DRREG_HANDLE_MULTI_PHASE_SLOT_RESERVATIONS to #drreg_bb_properties_t to
enable logic that avoids conflicts in spill slots when drreg is used to reserve
registers in multiple phases.
- Added drmgr_in_emulation_region(), drmgr_orig_app_instr_for_fetch(), and
drmgr_orig_app_instr_for_operands() for more conveniently handling emulation.
- Added the reconstructed #instrlist_t when available for the faulting fragment
to #dr_fault_fragment_info_t. This makes it available to the restore state
event callback(s) via the #dr_restore_state_info_t arg.
- Added the source context for restartable sequence aborts (#DR_XFER_RSEQ_ABORT)
which was previously missing.
- Added a #dynamorio::drmemtrace::TRACE_MARKER_TYPE_VERSION entry to drmemtrace traces.
- Augmented drmemtrace #dynamorio::drmemtrace::TRACE_MARKER_TYPE_KERNEL_EVENT entries with the absolute
PC of the interruption point, including for restartable sequence aborts, which
now also have an additional #dynamorio::drmemtrace::TRACE_MARKER_TYPE_RSEQ_ABORT identifier.
- Added a fifth instrumentation phase (meta_instru) that executes after the
insertion of instrumentation and instrumentation optimizations. Its primary purpose
is to enable debugging of instrumentation sequences and detection of
instrumentation-induced bugs.
- Added \p drstatecmp Extension which provides mechanisms to enable systematic
and exhaustive machine state comparisons across instrumentation sequences.
- Added drmodtrack_lookup_segment().
- Added a new drrun option \p -attach for attaching to a running process.
This is currently an experimental option and is not yet as well-supported
as launching a new process. It is only supported on x86 at this time.
- Added \ref page_drcallstack Extension for walking application callstacks, with
an initial Linux-only implementation.
- Added new #dr_cleancall_save_t flags which are required for proper interaction
between clean calls and drreg: #DR_CLEANCALL_READS_APP_CONTEXT must be set for
dr_get_mcontext() to obtain the proper values, and #DR_CLEANCALL_WRITES_APP_CONTEXT
must be set to ensure that dr_set_mcontext() is persistent.
If the call may be skipped by tool-inserted control flow, #DR_CLEANCALL_MULTIPATH
must additionally be set.
- Added a new event dr_register_clean_call_insertion_event(), meant for use by
register management libraries.
- Added drreg_statelessly_restore_all().
- Completed drx_expand_scatter_gather() support for emulating x86 scatter/gather
instructions using a sequence of scalar stores/loads. The scalar store/load
sequence makes it easier for clients to instrument each memory access.
**************************************************
<hr>
Version 8.0.0 includes Dr. Memory and the
Dr. Memory Framework (DRMF) in the same package as DynamoRIO. DRMF
provides the umbra, drsyscall, and drsymcache Extensions for use by
clients.
The changes between version 8.0.0 and 7.1.0 include the following compatibility
changes:
- Changed the enumeration of the DR_REG_ enum by adding x86 AVX-512 registers as well
as reserved ranges for future extensions.
This is a binary compatibility change for the DR_REG_ enum.
- Changed the enumeration of the OPSZ_ enum by moving its start back to 0. The OPSZ_
enum now completely overlaps the DR_REG_ enum.
This is a binary compatibility change for the OPSZ_ enum.
- Added a new encoding hint field to #instr_t.
- Added a requirement that a C++11-compliant compiler be used with \ref page_droption.
- Changed the syntax of the drcachesim -record_function option. It no longer takes
in an identifier: the identifier is computed by the tracer. It thus takes pairs,
with an optional third argument for flags such as "noret" to indicate that the
return value should not be recorded.
The tracer writes out a file listing functions traced and their identifiers
with "id,library!symbol" on each line of the file.
- Added free_key_func to the drcontainers hashtable_configure(), which adds a field
to #hashtable_config_t. Binary compatibility is maintained via the size field
of the struct, but users who were not zeroing the whole structure and who update
and recompile without setting the field may see crashes due to
free_key_func being uninitialized.
- Changed the 32-bit x86 stack alignment of DynamoRIO and clients built using
DR's CMake configuration from 4 to 16 on Linux to match modern conventions.
The changes between version 8.0.0 and 7.1.0 include the following minor
compatibility changes:
- Added the define #MCXT_NUM_SIMD_SLOTS that was renamed from NUM_SIMD_SLOTS.
#MCXT_NUM_SIMD_SLOTS is now a constant that shall be used only to determine
the number of SIMD slots in DynamoRIO's mcontext.
- Replaced NUM_SIMD_SLOTS with proc_num_simd_saved().
Clients may set(DynamoRIO_NUM_SIMD_SLOTS_COMPATIBILITY ON) in order to provide
the define NUM_SIMD_SLOTS using proc_num_simd_saved(). The macro is not a constant
expression and code relying on this needs to be rewritten.
DynamoRIO_NUM_SIMD_SLOTS_COMPATIBILITY is set automatically if clients target
version 7.1.0 or earlier.
- Renamed mcontext's "ymm" structure to "simd".
- Deprecated reg_is_xmm() and reg_is_ymm().
- The function reg_is_extended() now returns true for the upper 8 simd registers
as part of AVX-512, e.g. xmm16 - xmm31.
- Dropped support for clients used with statically linked DynamoRIO to reach
the code cache with 32-bit displacements.
- An additional parameter in the accessors to the drcachesim cache stats
(namely cache_stats_t and caching_device_stats_t) that passes a pointer to
the cache block being accessed (on a hit) or being replaced (on a miss).
This allows users to extend the cache block and stats classes in order to
collect more stats.
- Moves the immediate operand of the VEX encoded version of vextractps and vinsertps
to be the first source.
- The GPR versions of the vmovd and vmovq AVX opcodes are no longer combined into a
single vmovd.
- Changed the #PFX format string specifier to use %p rather than %x internally.
- DR no longer forwards _snprintf, _snwprintf, _vsnprintf, sprintf, or sscanf to
ntdll. Clients should use the dr_-prefixed versions of these functions.
- PC-relative control transfer instructions are now auto-re-relativized by the
general decoder and encoder. This affects clients and standalone tools that use
decode_from_copy() or instr_encode_to_copy() or instrlist_encode_to_copy().
Previously, re-relativization for instruction references only happened when an
instruction was re-encoded. This auto-PC-relativization can be avoided by calling
instr_set_rip_rel_valid() and setting the validity of the PC-relative data to false.
- Fixed major synchronization bugs on ARM and AArch64.
Further non-compatibility-affecting changes include:
- Added the function proc_num_simd_registers().
- Added drfront_set_verbose() to obtain diagnostics from drfrontendlib.
- Added new fields to #dr_os_version_info_t which contain the build number,
edition, and Windows 10 release identifier.
- Added the function instr_is_xsave().
- Added the type #dr_zmm_t.
- Added the type #dr_opmask_t.
- Added the define #MCXT_NUM_OPMASK_SLOTS for the number of AVX-512 OpMask registers.
- Renamed mcontext's ymm structure into simd.
- Added a new option -logprefix to drcov.
- Added the AVX-512 registers #DR_REG_XMM16 - #DR_REG_XMM31, #DR_REG_YMM16 -
#DR_REG_YMM31 and their #DR_REG_ZMM0 - #DR_REG_ZMM31 siblings as well as
#DR_REG_K0 - #DR_REG_K7.
- Added the function reg_is_opmask().
- Added the functions reg_is_strictly_xmm(), reg_is_strictly_ymm() and
reg_is_strictly_zmm().
- Added the function reg_is_avx512_extended().
- Added the function instr_is_opmask().
- Added reg_set_value_ex() to set XMM, YMM and ZMM values.
- Added the functions instr_set_encoding_hint(), instr_has_encoding_hint().
- Added the type #dr_encoding_hint_type_t.
- Added #INSTR_ENCODING_HINT macro.
- Added dr_standalone_exit() with support for re-attaching afterward.
- Added dr_register_low_on_memory_event() for tracking low on memory events.
- Added dr_mcontext_zmm_fields_valid() to query the state of lazy AVX-512 context
switching.
- Added the function proc_avx512_enabled().
- Added support for applications using the Linux kernel's restartable sequence
("rseq") feature, subject to the limitations listed in \ref sec_rseq.
- Added coherence support in drcachesim.
- Added the function proc_num_opmask_registers();
- reg_get_value_ex() now supports reading AVX-512 mask registers.
- Added the function reg_is_bnd().
- Added the functions instr_is_gather() and instr_is_scatter().
- Added the function drx_expand_scatter_gather().
- Added the function dr_atomic_add64_return_sum().
- Added the function instr_reads_from_exact_reg() to test whether instructions
read from exact registers.
- Added the function reg_is_vector_simd() to test whether registers are
either XMM, YMM or ZMM, excluding any MMX register checks.
- Added DR_NUM_SIMD_VECTOR_REGS as an alias to MCXT_NUM_SIMD_SLOTS in order
to get the static number of supported SIMD vectors.
- Added drmgr_register_low_on_memory_event(), drmgr_unregister_low_on_memory_event()
and their variants so that drmgr can support low-on-memory events.
- Added drmgr_is_first_nonlabel_instr() and instrlist_first_nonlabel().
- Added a new standalone tool "drdisas" which disassembles raw bytes using
DR's decoder.
- Added decode_sizeof_ex() and instr_get_rel_data_or_instr_target() handling
relative instruction references.
- Added drx_instrlist_size() and drx_instrlist_app_size() to obtain the size
of a basic block.
- Added drreg_restore_all() to restore all unreserved registers currently
maintained by drreg.
- Added a func_view tool to drcachesim for analyzing function traces.
- Added a non-heap-using instruction structure #instr_noalloc_t for use when
decoding in a signal handler, along with instr_noalloc_init() and
instr_from_noalloc().
- Added drwrap_get_stats().
- Added #DRWRAP_NO_DYNAMIC_RETADDRS for reducing drwrap overhead at the cost
of missing some post-call callbacks.
- Added #DRWRAP_REPLACE_RETADDR for an alternative method of setting up post-call
control points by replacing return addresses. This does not work for every
application, but reduces overhead.
- Added -record_dynsym_only to drcachesim for faster function tracing symbol
lookups when internal symbols are not needed.
- Added -record_replace_retaddr_only to drcachesim for faster function tracing
wrapping for well-behaved applications.
- Added dr_merge_arith_flags() as a convenience routine to merge arithmetic flags
for restoration done by outlined code.
- Added dr_annotation_pass_pc() to obtain the interrupted PC in an annotation
handler.
- Added atomics for safe and visible aligned loads and stores on all platforms:
dr_atomic_load32(), dr_atomic_store32(), dr_atomic_load64() dr_atomic_store64().
- The state restore event (dr_register_restore_state_event()) is now called for
all translation attempts, even when the register state already contains
application values, to allow clients to restore memory.
- Added the function dr_get_process_id_from_drcontext() for obtaining a process ID
associated with the given drcontext, which may be different from the current
dr_get_process_id() in some contexts.
- The private loader's malloc redirection now guarantees double-pointer-sized
alignment, to match what system-provided allocators use.
- Added a new DR extension, namely "drbbdup", which enables different case
instrumentation of the same basic block by duplicating code.
**************************************************
<hr>
Version 7.1.0 includes Dr. Memory and the Dr. Memory Framework (DRMF) in
the same package as DynamoRIO. DRMF provides the umbra, drsyscall, and
drsymcache Extensions for use by clients.
The changes between version 7.1.0 and 7.0.0 include the following minor
compatibility changes:
- The drltrace tool has been moved to the Dr.Memory Framework.
- Removed DRMGR_PRIORITY_INSERT_CLS_ENTRY, DRMGR_PRIORITY_INSERT_CLS_EXIT,
DRMGR_PRIORITY_NAME_CLS_ENTRY, and DRMGR_PRIORITY_NAME_CLS_EXIT, as
the new kernel xfer event (drmgr_register_kernel_xfer_event()) removes the
need for them.
- Renamed the LOG_ macros (#LOG_NONE, #LOG_ALL, etc.) to have a DR_ prefix
to avoid name conflicts. Clients should set(DynamoRIO_LOG_COMPATIBILITY ON)
prior to configure_DynamoRIO_client() to use the old constants and avoid
any source changes; this will happen automatically if the client
targets version 7.0.0 or earlier. Binary compatibility is unaffected.
- Added a parameter to cmake functions DynamoRIO_get_target_path_for_execution and
DynamoRIO_copy_target_to_device. External projects outside of DynamoRIO need
to pass _DR_location_suffix.
- The drcachesim tool's offline traces are now stored in separate files per traced
application thread, rather than a single interleaved file. Reading and analyzing
a legacy interleaved file is still supported, but all new generated traces are
split. Splitting enables parallelized post-processing and trace analysis.
- In standalone mode, there are no 32-bit-displacement reachability guarantees
regarding DynamoRIO's heap.
Further non-compatibility-affecting changes include:
- Added drx_buf_insert_buf_memcpy().
- Added XINST_CREATE_add_sll(), XINST_CREATE_jump_cond(), and XINST_CREATE_slr_s().
- Added thread synchronization events via dr_event_create(), dr_event_destroy(),
dr_event_wait(), dr_event_signal(), and dr_event_reset().
- Added drmodtrack customization via drmodtrack_add_custom_data() and
post-processing support via drmodtrack_offline_write().
- Added drcachesim customization via drmemtrace_replace_file_ops(),
drmemtrace_custom_module_data(), drmemtrace_get_output_path(),
drmemtrace_get_modlist_path(), and a separate rawtrace library for
post-processing customization with raw2trace_t::handle_custom_data(),
raw2trace_t::do_module_parsing(), raw2trace_t::do_conversion(), and
raw2trace_directory_t. The raw2trace library also includes an interface
for obtaining further instruction information than is stored in the
trace via raw2trace_t::do_module_parsing_and_mapping() and
raw2trace_t::find_mapped_trace_address().
A corresponding CMake function for finding the
tracer customization header is use_DynamoRIO_drmemtrace_tracer().
- Added drreg_restore_app_aflags().
- Added a set_value() function to the \ref page_droption.
- Added instrlist_get_auto_predicate() and instrlist_set_auto_predicate().
- Globally enabled auto predication in the drmgr instrumentation insertion event by
default.
- Added drmgr_disable_auto_predication().
- Added a new option -signal_stack_size with a smaller default value than
before, to save space on applications with many threads.
- Added instr_predicate_is_cond().
- Added a hardware data next-line prefetcher to drcachesim. It is on by
default, so simulation results may not match those in prior releases.
It can be disabled by running with "-data_prefetcher none" (see \ref
sec_drcachesim_ops).
- Added a last-level cache miss recording feature to drcachesim.
- Added a delayed tracing feature to drcachesim.
- Added an option to drcachesim to specify cache warmup by loaded fraction of the
last level cache.
- On Linux, the VDSO module is now included in the module list at program
startup.
- Added support for Windows 10 1703. We provide an artificial version
identifier #DR_WINDOWS_VERSION_10_1703 to distinguish this major update.
- Added support for Windows 10 1709. We provide an artificial version
identifier #DR_WINDOWS_VERSION_10_1709 to distinguish this major update.
- Added an event for kernel-mediated control flow via
dr_register_kernel_xfer_event() with corresponding routines
drmgr_register_kernel_xfer_event() and drmgr_register_kernel_xfer_event_ex().
- Added a new option -ignore_all_libs to drcpusim.
- Added several new trace analysis tools to drcachesim: reuse distance,
reuse time, histogram, and trace basic counts.
- Added a trace analysis tool framework to facilitate creating custom
trace tools using the CMake function use_DynamoRIO_drmemtrace() and
exported drmemtrace_analyzer and analysis tool libraries.
- Added the CMake function configure_DynamoRIO_main_headers() to
facilitate using drfrontendlib by itself.
- Added instr_is_string_op() and instr_is_rep_string_op().
- Added dr_app_recurlock_lock().
- Added hashtable_apply_to_all_payloads() to iterate over all payloads in a
hashtable.
- Added drutil_insert_get_mem_addr_ex().
- Added dr_vfprintf().
- Added drmgr_register_thread_init_event_user_data() and
drmgr_unregister_thread_init_event_user_data() to enable passing of user data.
- Added drmgr_register_thread_exit_event_user_data() and
drmgr_unregister_thread_exit_event_usr_data() to enable passing of user data.
- Added drmgr_register_module_load_event_user_data() and
drmgr_unregister_module_load_event_user_data() to enable passing of user data.
- Added drmgr_register_module_unload_event_user_data() and
drmgr_unregister_module_unload_event() to enable passing of user data.
- Added a new drcachesim feature that records which cpu each thread
executed on along with an optional simulator scheduling feature to
schedule threads on simulated cores to match the recorded execution on
physical cpus.
- Added #DR_DISALLOW_UNSAFE_STATIC and dr_allow_unsafe_static_behavior()
for sanity checks to help support statically-linked clients.
- Added drmgr_register_pre_syscall_event_user_data() and
drmgr_unregister_pre_syscall_event_user_data() to enable passing of user data.
- Added drmgr_register_post_syscall_event_user_data() and
drmgr_unregister_post_syscall_event_user_data() to enable passing of user data.
- Added dr_where_am_i(), dr_track_where_am_i(), and dr_is_tracking_where_am_i()
better support client self-profiling via sampling.
- Added dr_get_stats() to retrieve runtime stats. Currently limited to number
of built basic blocks.
- Added drreg_reservation_info_ex(), drreg_statelessly_restore_app_value(),
and drreg_is_instr_spill_or_restore().
- Added dr_app_stop_and_cleanup_with_stats() to obtain stats values right before
cleanup.
- drmodtrack now allocates an entry per segment for each loaded module.
Added a file offset field to module_segment_data_t for UNIX platforms.
drcachesim saves file offset information in modules.log on UNIX platforms.
- Added dr_prepopulate_cache() and dr_prepopulate_indirect_targets() for
setting up the code cache prior to execution.
- Added support for Windows 10 1803. We provide an artificial version
identifier #DR_WINDOWS_VERSION_10_1803 to distinguish this major update.
- Generalization of the drcachesim #dynamorio::drmemtrace::raw2trace_t API (Issue #3129):
- Added #dynamorio::drmemtrace::module_mapper_t, which factors out the module mapping functionality
out of #dynamorio::drmemtrace::raw2trace_t, replacing the following #dynamorio::drmemtrace::raw2trace_t APIs:
#dynamorio::drmemtrace::raw2trace_t::handle_custom_data(), #dynamorio::drmemtrace::raw2trace_t::do_module_parsing(),
#dynamorio::drmemtrace::raw2trace_t::do_module_parsing_and_mapping(), and
#dynamorio::drmemtrace::raw2trace_t::find_mapped_trace_address().
- Added #dynamorio::drmemtrace::trace_metadata_writer_t, a set of utility functions used by drcachesim's
#dynamorio::drmemtrace::raw2trace_t for writing trace metadata: process/thread ids, timestamps, etc.
- Added #dynamorio::drmemtrace::trace_metadata_reader_t, a set of utilities for checking and validating
thread start successions of offline entries in a raw data file.
- Added trace_converter_t, an extensibility mechanism for raw trace conversion.
- Added drmemtrace_get_timestamp_from_offline_trace(), an API for fetching the timestamp
from the beginning of a raw trace bundle (regardless of whether it is a thread start
or just a subsequent bundle).
- Added dr_abort_with_code().
- Added support for interoperability between emulation clients and observational