]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/NEWS
GDB: Add a character string limiting option
[thirdparty/binutils-gdb.git] / gdb / NEWS
CommitLineData
c906108c
SS
1 What has changed in GDB?
2 (Organized release by release)
3
4ff87a30
JB
4*** Changes since GDB 13
5
975249ff
TT
6* MI version 1 has been removed.
7
de7d7cb5
TT
8* GDB has initial built-in support for the Debugger Adapter Protocol.
9 This support requires that GDB be built with Python scripting
10 enabled.
11
e24d337e
BL
12* New commands
13
14maintenance print record-instruction [ N ]
15 Print the recorded information for a given instruction. If N is not given
16 prints how GDB would undo the last instruction executed. If N is negative,
17 prints how GDB would undo the N-th previous instruction, and if N is
18 positive, it prints how GDB will redo the N-th following instruction.
19
37f54063
BL
20* MI changes
21
22** mi now reports 'no-history' as a stop reason when hitting the end of the
23 reverse execution history.
24
4ff87a30 25*** Changes in GDB 13
ba09d2a8 26
560f8d05
TT
27* MI version 1 is deprecated, and will be removed in GDB 14.
28
68cffbbd
LM
29* GDB now supports dumping memory tag data for AArch64 MTE. It also supports
30 reading memory tag data for AArch64 MTE from core files generated by
31 the gcore command or the Linux kernel.
32
33 When a process uses memory-mapped pages protected by memory tags (for
34 example, AArch64 MTE), this additional information will be recorded in
35 the core file in the event of a crash or if GDB generates a core file
36 from the current process state. GDB will show this additional information
37 automatically, or through one of the memory-tag subcommands.
38
fbcda577
PA
39* "info breakpoints" now displays enabled breakpoint locations of
40 disabled breakpoints as in the "y-" state. For example:
41
42 (gdb) info breakpoints
43 Num Type Disp Enb Address What
44 1 breakpoint keep n <MULTIPLE>
45 1.1 y- 0x00000000000011b6 in ...
46 1.2 y- 0x00000000000011c2 in ...
47 1.3 n 0x00000000000011ce in ...
48
ed8f05ba
JB
49* Support for Thread Local Storage (TLS) variables on FreeBSD arm and
50 aarch64 architectures.
51
065a00b3
JB
52* GDB now supports hardware watchpoints on FreeBSD/Aarch64.
53
edae3fd6
SM
54* Remove support for building against Python 2, it is now only possible to
55 build GDB against Python 3.
56
49a82d50
TT
57* DBX mode has been removed.
58
cc96ae7f
LS
59* GDB now honours the DWARF prologue_end line-table entry flag the compiler can
60 emit to indicate where a breakpoint should be placed to break in a function
61 past its prologue.
62
89555e4e
MR
63* Completion now also offers "NUMBER" for "set" commands that accept
64 a numeric argument and the "unlimited" keyword. For example:
65
66 (gdb) set width <TAB>
67 NUMBER unlimited
68
69 and consequently:
70
71 (gdb) complete set width
72 set width NUMBER
73 set width unlimited
74
4cbe4ca5
AB
75* Disassembler styling using libopcodes. GDB now supports
76 disassembler styling using libopcodes. This is only available for
77 some targets (currently x86 and RISC-V). For unsupported targets
78 Python Pygments is still used. For supported targets, libopcodes
79 styling is used by default.
80
d08bae3d
TT
81* The Windows native target now supports target async.
82
2cac01e3
FS
83* gdb now supports zstd compressed debug sections (ELFCOMPRESS_ZSTD) for ELF.
84
d4ce49b7
AB
85* The format of 'disassemble /r' and 'record instruction-history /r'
86 has changed. The instruction bytes could now be grouped together,
87 and displayed in the endianness of the instruction. This is the
88 same layout as used by GNU objdump when disassembling.
89
90 There is now 'disassemble /b' and 'record instruction-history /b'
91 which will always display the instructions bytes one at a time in
92 memory order, that is, the byte at the lowest address first.
93
94 For both /r and /b GDB is now better at using whitespace in order to
95 align the disassembled instruction text.
96
92c1d07d
PA
97* The TUI no longer styles the source and assembly code highlighted by
98 the current position indicator by default. You can however
99 re-enable styling using the new "set style tui-current-position"
100 command.
101
cbda14de
AB
102* New convenience variable $_inferior_thread_count contains the number
103 of live threads in the current inferior.
104
78805ff8
PW
105* When a breakpoint with multiple code locations is hit, GDB now prints
106 the code location using the syntax <breakpoint_number>.<location_number>
107 such as in:
108 Thread 1 "zeoes" hit Breakpoint 2.3, some_func () at zeoes.c:8
109
110* When a breakpoint is hit, GDB now sets the convenience variables $_hit_bpnum
111 and $_hit_locno to the hit breakpoint number and code location number.
112 This allows to disable the last hit breakpoint using
113 (gdb) disable $_hit_bpnum
114 or disable only the specific breakpoint code location using
115 (gdb) disable $_hit_bpnum.$_hit_locno
116 These commands can be used inside the command list of a breakpoint to
117 automatically disable the just encountered breakpoint (or the just
118 encountered specific breakpoint code location).
119 When a breakpoint has only one location, $_hit_locno is set to 1 so that
120 (gdb) disable $_hit_bpnum.$_hit_locno
121 and
122 (gdb) disable $_hit_bpnum
123 are both disabling the breakpoint.
124
6109f7a3
LS
125* New commands
126
127maintenance set ignore-prologue-end-flag on|off
128maintenance show ignore-prologue-end-flag
129 This setting, which is off by default, controls whether GDB ignores the
130 PROLOGUE-END flag from the line-table when skipping prologue. This can be
131 used to force GDB to use prologue analyzers if the line-table is constructed
132 from erroneous debug information.
133
153b3c11
EL
134set print nibbles [on|off]
135show print nibbles
136 This controls whether the 'print/t' command will display binary values
137 in groups of four bits, known as "nibbles". The default is 'off'.
138
4cbe4ca5
AB
139maintenance set libopcodes-styling on|off
140maintenance show libopcodes-styling
141 These can be used to force off libopcodes based styling, the Python
142 Pygments styling will then be used instead.
143
144set style disassembler comment
145show style disassembler comment
146set style disassembler immediate
147show style disassembler immediate
148set style disassembler mnemonic
149show style disassembler mnemonic
150set style disassembler register
151show style disassembler register
152set style disassembler address
153show style disassembler address
154set style disassembler symbol
155show style disassembler symbol
156 For targets that support libopcodes based styling, these settings
157 control how various aspects of the disassembler output are styled.
158 The 'disassembler address' and 'disassembler symbol' styles are
159 aliases for the 'address' and 'function' styles respectively.
160
70175292
AB
161maintenance print frame-id [ LEVEL ]
162 Print GDB's internal frame-id for the frame at LEVEL. If LEVEL is
163 not given, then print the frame-id for the currently selected frame.
164
e4014689
AB
165set debug infcall on|off
166show debug infcall
167 Print additional debug messages about inferior function calls.
168
e26d0dab
SM
169set debug solib on|off
170show debug solib
171 Print additional debug messages about shared library handling.
172
92c1d07d
PA
173set style tui-current-position [on|off]
174 Whether to style the source and assembly code highlighted by the
175 TUI's current position indicator. The default is off.
176
76b58849
AB
177set print characters LIMIT
178show print characters
179 This new setting is like 'set print elements', but controls how many
180 characters of a string are printed. This functionality used to be
181 covered by 'set print elements', but it can be controlled separately
182 now. LIMIT can be set to a numerical value to request that particular
183 character count, to 'unlimited' to print all characters of a string,
184 or to 'elements', which is also the default, to follow the setting of
185 'set print elements' as it used to be.
186
187print -characters LIMIT
188 This new option to the 'print' command has the same effect as a temporary
189 use of 'set print characters'.
190
cc96ae7f
LS
191* Changed commands
192
effcf7b1
PW
193document user-defined
194 It is now possible to document user-defined aliases.
195 When a user-defined alias is documented, the help and apropos commands
196 use the provided documentation instead of the documentation of the
197 aliased command.
198 Documenting a user-defined alias is particularly useful when the alias
199 is a set of nested 'with' commands to avoid showing the help of
200 the with command for an alias that will in fact launch the
201 last command given in the nested commands.
202
cc96ae7f
LS
203maintenance info line-table
204 Add a PROLOGUE-END column to the output which indicates that an
205 entry corresponds to an address where a breakpoint should be placed
206 to be at the first instruction past a function's prologue.
207
e26d0dab
SM
208* Removed commands
209
210set debug aix-solib on|off
211show debug aix-solib
212set debug solib-frv on|off
213show debug solib-frv
214 Removed in favor of "set/show debug solib".
215
5d80df4a
AB
216maintenance info program-spaces
217 This command now includes a 'Core File' column which indicates the
218 name of the core file associated with each program space.
219
02e85f7a
TY
220* New targets
221
222GNU/Linux/LoongArch (gdbserver) loongarch*-*-linux*
223
02cd1b4e
JL
224GNU/Linux/CSKY (gdbserver) csky*-*linux*
225
78805ff8
PW
226* MI changes
227
228 ** The async record stating the stopped reason 'breakpoint-hit' now
229 contains an optional field locno giving the code location number
230 when the breakpoint has multiple code locations.
231
25209e2c
AB
232* Python API
233
691ade38
TT
234 ** GDB will now reformat the doc string for gdb.Command and
235 gdb.Parameter sub-classes to remove unnecessary leading
236 whitespace from each line before using the string as the help
237 output.
238
25209e2c
AB
239 ** New function gdb.format_address(ADDRESS, PROGSPACE, ARCHITECTURE),
240 that formats ADDRESS as 'address <symbol+offset>', where symbol is
241 looked up in PROGSPACE, and ARCHITECTURE is used to format address.
242 This is the same format that GDB uses when printing address, symbol,
243 and offset information from the disassembler.
244
80fa4b2a
TT
245 ** New function gdb.current_language that returns the name of the
246 current language. Unlike gdb.parameter('language'), this will
247 never return 'auto'.
248
249 ** New method gdb.Frame.language that returns the name of the
250 frame's language.
251
15e15b2d
AB
252 ** New Python API for wrapping GDB's disassembler:
253
254 - gdb.disassembler.register_disassembler(DISASSEMBLER, ARCH).
255 DISASSEMBLER is a sub-class of gdb.disassembler.Disassembler.
256 ARCH is either None or a string containing a bfd architecture
257 name. DISASSEMBLER is registered as a disassembler for
258 architecture ARCH, or for all architectures if ARCH is None.
259 The previous disassembler registered for ARCH is returned, this
260 can be None if no previous disassembler was registered.
261
262 - gdb.disassembler.Disassembler is the class from which all
263 disassemblers should inherit. Its constructor takes a string,
264 a name for the disassembler, which is currently only used in
265 some debug output. Sub-classes should override the __call__
266 method to perform disassembly, invoking __call__ on this base
267 class will raise an exception.
268
269 - gdb.disassembler.DisassembleInfo is the class used to describe
270 a single disassembly request from GDB. An instance of this
271 class is passed to the __call__ method of
272 gdb.disassembler.Disassembler and has the following read-only
273 attributes: 'address', and 'architecture', as well as the
274 following method: 'read_memory'.
275
276 - gdb.disassembler.builtin_disassemble(INFO, MEMORY_SOURCE),
277 calls GDB's builtin disassembler on INFO, which is a
278 gdb.disassembler.DisassembleInfo object. MEMORY_SOURCE is
279 optional, its default value is None. If MEMORY_SOURCE is not
280 None then it must be an object that has a 'read_memory' method.
281
282 - gdb.disassembler.DisassemblerResult is a class that can be used
283 to wrap the result of a call to a Disassembler. It has
284 read-only attributes 'length' and 'string'.
285
99298c95
TT
286 ** gdb.Objfile now has an attribute named "is_file". This is True
287 if the objfile comes from a file, and False otherwise.
288
c4a3dbaf
TT
289 ** New function gdb.print_options that returns a dictionary of the
290 prevailing print options, in the form accepted by
291 gdb.Value.format_string.
292
293 ** gdb.Value.format_string now uses the format provided by 'print',
294 if it is called during a 'print' or other similar operation.
295
72be9d6b
TT
296 ** gdb.Value.format_string now accepts the 'summary' keyword. This
297 can be used to request a shorter representation of a value, the
298 way that 'set print frame-arguments scalars' does.
299
e5213e2c
SF
300 ** New Python type gdb.BreakpointLocation.
301 The new attribute 'locations' of gdb.Breakpoint returns a list of
302 gdb.BreakpointLocation objects specifying the locations where the
303 breakpoint is inserted into the debuggee.
304
7abc6ec0
AB
305 ** The gdb.register_window_type method now restricts the set of
306 acceptable window names. The first character of a window's name
307 must start with a character in the set [a-zA-Z], every subsequent
308 character of a window's name must be in the set [-_.a-zA-Z0-9].
309
02e85f7a
TY
310* New features in the GDB remote stub, GDBserver
311
312 ** GDBserver is now supported on LoongArch GNU/Linux.
02cd1b4e
JL
313
314 ** GDBserver is now supported on CSKY GNU/Linux.
02e85f7a 315
e24500cb
TY
316* LoongArch floating-point support
317
318GDB now supports floating-point on LoongArch GNU/Linux.
319
ba09d2a8 320*** Changes in GDB 12
ccd14903 321
cfeab26e
TT
322* DBX mode is deprecated, and will be removed in GDB 13
323
807310c5
AB
324* GDB 12 is the last release of GDB that will support building against
325 Python 2. From GDB 13, it will only be possible to build GDB itself
326 with Python 3 support.
327
bcb9251f
TT
328* The disable-randomization setting now works on Windows.
329
64a97606
KS
330* Improved C++ template support
331
332 GDB now treats functions/types involving C++ templates like it does function
333 overloads. Users may omit parameter lists to set breakpoints on families of
334 template functions, including types/functions composed of multiple template types:
335
336 (gdb) break template_func(template_1, int)
337
338 The above will set breakpoints at every function `template_func' where
339 the first function parameter is any template type named `template_1' and
340 the second function parameter is `int'.
341
342 TAB completion also gains similar improvements.
343
1ead4b8e
JB
344* The FreeBSD native target now supports async mode.
345
261b0748
LM
346* Configure changes
347
348--enable-threading
349
350 Enable or disable multithreaded symbol loading. This is enabled
351 by default, but passing --disable-threading or --enable-threading=no
352 to configure will disable it.
353
354 Disabling this can cause a performance penalty when there are a lot of
355 symbols to load, but is useful for debugging purposes.
356
fde1a9a3
AB
357* New commands
358
6aa4f97c
AB
359maint set backtrace-on-fatal-signal on|off
360maint show backtrace-on-fatal-signal
361 This setting is 'on' by default. When 'on' GDB will print a limited
362 backtrace to stderr in the situation where GDB terminates with a
363 fatal signal. This only supported on some platforms where the
364 backtrace and backtrace_symbols_fd functions are available.
365
fde1a9a3
AB
366set source open on|off
367show source open
368 This setting, which is on by default, controls whether GDB will try
369 to open source code files. Switching this off will stop GDB trying
370 to open and read source code files, which can be useful if the files
371 are located over a slow network connection.
372
acbf4a58
TT
373set varsize-limit
374show varsize-limit
375 These are now deprecated aliases for "set max-value-size" and
376 "show max-value-size".
377
bc75fb44
TT
378task apply [all | TASK-IDS...] [FLAG]... COMMAND
379 Like "thread apply", but applies COMMAND to Ada tasks.
380
8a18382f
TT
381watch [...] task ID
382 Watchpoints can now be restricted to a specific Ada task.
383
91f2597b
AB
384maint set internal-error backtrace on|off
385maint show internal-error backtrace
386maint set internal-warning backtrace on|off
387maint show internal-warning backtrace
388 GDB can now print a backtrace of itself when it encounters either an
389 internal-error, or an internal-warning. This is on by default for
390 internal-error and off by default for internal-warning.
391
6ff96754
TV
392set logging on|off
393 Deprecated and replaced by "set logging enabled on|off".
394
395set logging enabled on|off
396show logging enabled
397 These commands set or show whether logging is enabled or disabled.
398
fa8f0a0f
EL
399exit
400 You can now exit GDB by using the new command "exit", in addition to
401 the existing "quit" command.
402
5b0a3d62
AB
403set debug threads on|off
404show debug threads
405 Print additional debug messages about thread creation and deletion.
406
8864ef42
AB
407set debug linux-nat on|off
408show debug linux-nat
409 These new commands replaced the old 'set debug lin-lwp' and 'show
410 debug lin-lwp' respectively. Turning this setting on prints debug
411 messages relating to GDB's handling of native Linux inferiors.
412
39370778
AB
413maint flush source-cache
414 Flush the contents of the source code cache.
415
643b1268
AB
416maint set gnu-source-highlight enabled on|off
417maint show gnu-source-highlight enabled
418 Whether GDB should use the GNU Source Highlight library for adding
419 styling to source code. When off, the library will not be used, even
420 when available. When GNU Source Highlight isn't used, or can't add
421 styling to a particular source file, then the Python Pygments
422 library will be used instead.
423
61fb7376
TBA
424set suppress-cli-notifications (on|off)
425show suppress-cli-notifications
426 This controls whether printing the notifications is suppressed for CLI.
427 CLI notifications occur when you change the selected context
428 (i.e., the current inferior, thread and/or the frame), or when
429 the program being debugged stops (e.g., because of hitting a
430 breakpoint, completing source-stepping, an interrupt, etc.).
431
e867795e
AB
432set style disassembler enabled on|off
433show style disassembler enabled
434 If GDB is compiled with Python support, and the Python Pygments
435 package is available, then, when this setting is on, disassembler
436 output will have styling applied.
437
315e4ebb
TT
438set ada source-charset
439show ada source-charset
440 Set the character set encoding that is assumed for Ada symbols. Valid
441 values for this follow the values that can be passed to the GNAT
442 compiler via the '-gnati' option. The default is ISO-8859-1.
443
51c2a9e2
AB
444tui layout
445tui focus
446tui refresh
447tui window height
448 These are the new names for the old 'layout', 'focus', 'refresh',
449 and 'winheight' tui commands respectively. The old names still
450 exist as aliases to these new commands.
451
160444ec
AB
452tui window width
453winwidth
454 The new command 'tui window width', and the alias 'winwidth' allow
455 the width of a tui window to be adjusted when windows are laid out
456 in horizontal mode.
457
7421ccda
AB
458set debug tui on|off
459show debug tui
460 Control the display of debug output about GDB's tui.
461
e5b176f2
AB
462* Changed commands
463
56262a93
TT
464print
465 Printing of floating-point values with base-modifying formats like
466 /x has been changed to display the underlying bytes of the value in
467 the desired base. This was GDB's documented behavior, but was never
468 implemented correctly.
469
e5b176f2
AB
470maint packet
471 This command can now print a reply, if the reply includes
472 non-printable characters. Any non-printable characters are printed
473 as escaped hex, e.g. \x?? where '??' is replaces with the value of
474 the non-printable character.
475
003aae07
LS
476clone-inferior
477 The clone-inferior command now ensures that the TTY, CMD and ARGS
478 settings are copied from the original inferior to the new one.
479 All modifications to the environment variables done using the 'set
480 environment' or 'unset environment' commands are also copied to the new
481 inferior.
482
8864ef42
AB
483set debug lin-lwp on|off
484show debug lin-lwp
485 These commands have been removed from GDB. The new command 'set
486 debug linux-nat' and 'show debug linux-nat' should be used
487 instead.
488
f62843d7
AB
489info win
490 This command now includes information about the width of the tui
491 windows in its output.
492
51c2a9e2
AB
493layout
494focus
495refresh
496winheight
497 These commands are now aliases for the 'tui layout', 'tui focus',
498 'tui refresh', and 'tui window height' commands respectively.
499
63fc2437
TT
500* GDB's Ada parser now supports an extension for specifying the exact
501 byte contents of a floating-point literal. This can be useful for
502 setting floating-point registers to a precise value without loss of
503 precision. The syntax is an extension of the based literal syntax.
504 Use, e.g., "16lf#0123abcd#" -- the number of "l"s controls the width
505 of the floating-point type, and the "f" is the marker for floating
506 point.
507
d43bd54d
US
508* MI changes
509
510 ** The '-add-inferior' with no option flags now inherits the
511 connection of the current inferior, this restores the behaviour of
512 GDB as it was prior to GDB 10.
513
6fd90137
AB
514 ** The '-add-inferior' command now accepts a '--no-connection'
515 option, which causes the new inferior to start without a
516 connection.
517
9db0d853
SM
518 ** The default version of the MI interpreter is now 4 (-i=mi4).
519
520 ** The "script" field in breakpoint output (which is syntactically
521 incorrect in MI 3 and below) has changed in MI 4 to become a list.
522 This affects the following commands and events:
523
524 - -break-insert
525 - -break-info
526 - =breakpoint-created
527 - =breakpoint-modified
528
529 The -fix-breakpoint-script-output command can be used to enable
530 this behavior with previous MI versions.
531
d203a064
TY
532* New targets
533
575b4c29
PA
534GNU/Linux/LoongArch loongarch*-*-linux*
535
536* Removed targets
537
538S+core score-*-*
d203a064 539
540bf37b
AB
540* Python API
541
542 ** New function gdb.add_history(), which takes a gdb.Value object
543 and adds the value it represents to GDB's history list. An
544 integer, the index of the new item in the history list, is
545 returned.
546
30a87e90
AB
547 ** New function gdb.history_count(), which returns the number of
548 values in GDB's value history.
549
b1f0f284
AB
550 ** New gdb.events.gdb_exiting event. This event is called with a
551 gdb.GdbExitingEvent object which has the read-only attribute
552 'exit_code', which contains the value of the GDB exit code. This
553 event is triggered once GDB decides it is going to exit, but
554 before GDB starts to clean up its internal state.
555
8b87fbe6
AB
556 ** New function gdb.architecture_names(), which returns a list
557 containing all of the possible Architecture.name() values. Each
558 entry is a string.
559
d3771fe2
TT
560 ** New function gdb.Architecture.integer_type(), which returns an
561 integer type given a size and a signed-ness.
562
0e3b7c25 563 ** New gdb.TargetConnection object type that represents a connection
24b2de7b
AB
564 (as displayed by the 'info connections' command). A sub-class,
565 gdb.RemoteTargetConnection, is used to represent 'remote' and
566 'extended-remote' connections.
0e3b7c25
AB
567
568 ** The gdb.Inferior type now has a 'connection' property which is an
569 instance of gdb.TargetConnection, the connection used by this
570 inferior. This can be None if the inferior has no connection.
571
572 ** New 'gdb.events.connection_removed' event registry, which emits a
573 'gdb.ConnectionEvent' when a connection is removed from GDB.
574 This event has a 'connection' property, a gdb.TargetConnection
575 object for the connection being removed.
576
577 ** New gdb.connections() function that returns a list of all
578 currently active connections.
579
24b2de7b
AB
580 ** New gdb.RemoteTargetConnection.send_packet(PACKET) method. This
581 is equivalent to the existing 'maint packet' CLI command; it
582 allows a user specified packet to be sent to the remote target.
583
61671e97
AB
584 ** New function gdb.host_charset(), returns a string, which is the
585 name of the current host charset.
586
b583c328
TT
587 ** New gdb.set_parameter(NAME, VALUE). This sets the gdb parameter
588 NAME to VALUE.
589
590 ** New gdb.with_parameter(NAME, VALUE). This returns a context
591 manager that temporarily sets the gdb parameter NAME to VALUE,
592 then resets it when the context is exited.
593
0642912e
AB
594 ** The gdb.Value.format_string method now takes a 'styling'
595 argument, which is a boolean. When true, the returned string can
596 include escape sequences to apply styling. The styling will only
597 be present if styling is otherwise turned on in GDB (see 'help
598 set styling'). When false, which is the default if the argument
599 is not given, then no styling is applied to the returned string.
600
659971cb
AB
601 ** New read-only attribute gdb.InferiorThread.details, which is
602 either a string, containing additional, target specific thread
603 state information, or None, if there is no such additional
604 information.
605
ee6a3d9e
AB
606 ** New read-only attribute gdb.Type.is_scalar, which is True for
607 scalar types, and False for all other types.
608
551b380f
AB
609 ** New read-only attribute gdb.Type.is_signed. This attribute
610 should only be read when Type.is_scalar is True, and will be True
611 for signed types, and False for all other types. Attempting to
612 read this attribute for non-scalar types will raise a ValueError.
613
740b42ce
AB
614 ** It is now possible to add GDB/MI commands implemented in Python.
615
cb22a7c3
SH
616* New features in the GDB remote stub, GDBserver
617
618 ** GDBserver is now supported on OpenRISC GNU/Linux.
619
620* New native configurations
621
622GNU/Linux/OpenRISC or1k*-*-linux*
623
ccd14903 624*** Changes in GDB 11
ed6a896c 625
ae61ef2c
SV
626* The 'set disassembler-options' command now supports specifying options
627 for the ARC target.
628
ce192338
LM
629* GDB now supports general memory tagging functionality if the underlying
630 architecture supports the proper primitives and hooks. Currently this is
631 enabled only for AArch64 MTE.
632
633 This includes:
634
635 - Additional information when the inferior crashes with a SIGSEGV caused by
636 a memory tag violation.
637
638 - A new modifier 'm' for the "x" command, which displays allocation tags for a
639 particular memory range.
640
641 - Display of memory tag mismatches by "print", for addresses and
642 pointers, if memory tagging is supported by the architecture.
643
0fb8bb02
JB
644* Building GDB now requires GMP (The GNU Multiple Precision Arithmetic
645 Library).
646
6791b117
PA
647* MI changes
648
649 ** '-break-insert --qualified' and '-dprintf-insert --qualified'
650
651 The MI -break-insert and -dprintf-insert commands now support a
652 new "--qualified" option that makes GDB interpret a specified
653 function name as a complete fully-qualified name. This is the
654 equivalent of the CLI's "break -qualified" and "dprintf
655 -qualified".
656
10e578d7
TBA
657 ** '-break-insert --force-condition' and '-dprintf-insert --force-condition'
658
659 The MI -break-insert and -dprintf-insert commands now support a
660 '--force-condition' flag to forcibly define a condition even when
661 the condition is invalid at all locations of the breakpoint. This
662 is equivalent to the '-force-condition' flag of the CLI's "break"
663 command.
664
79aabb73
TBA
665 ** '-break-condition --force'
666
667 The MI -break-condition command now supports a '--force' flag to
668 forcibly define a condition even when the condition is invalid at
669 all locations of the selected breakpoint. This is equivalent to
670 the '-force' flag of the CLI's "cond" command.
671
1fb1ce02
AB
672 ** '-file-list-exec-source-files [--group-by-objfile]
673 [--basename | --dirname]
674 [--] [REGEXP]'
0e350a05
AB
675
676 The existing -file-list-exec-source-files command now takes an
677 optional REGEXP which is used to filter the source files that are
678 included in the results.
679
680 By default REGEXP is matched against the full filename of the
681 source file. When one of --basename or --dirname is given then
682 REGEXP is only matched against the specified part of the full
683 source filename.
684
1fb1ce02
AB
685 When the optional --group-by-objfile flag is used the output
686 format is changed, the results are now a list of object files
687 (executable and libraries) with the source files that are
688 associated with each object file.
689
0e350a05
AB
690 The results from -file-list-exec-source-files now include a
691 'debug-fully-read' field which takes the value 'true' or 'false'.
692 A 'true' value indicates the source file is from a compilation
693 unit that has had its debug information fully read in by GDB, a
694 value of 'false' indicates GDB has only performed a partial scan
695 of the debug information so far.
696
d3483b43
JT
697* GDB now supports core file debugging for x86_64 Cygwin programs.
698
64aaad63
AB
699* GDB will now look for the .gdbinit file in a config directory before
700 looking for ~/.gdbinit. The file is searched for in the following
701 locations: $XDG_CONFIG_HOME/gdb/gdbinit, $HOME/.config/gdb/gdbinit,
702 $HOME/.gdbinit. On Apple hosts the search order is instead:
703 $HOME/Library/Preferences/gdb/gdbinit, $HOME/.gdbinit.
704
fa123c32
JB
705* GDB now supports fixed point types which are described in DWARF
706 as base types with a fixed-point encoding. Additionally, support
707 for the DW_AT_GNU_numerator and DW_AT_GNU_denominator has also
708 been added.
709
710 For Ada, this allows support for fixed point types without requiring
711 the use of the GNAT encoding (based on information added to the type's
712 name following a GNAT-specific format).
713
92e4e97a
AB
714* GDB will now load and process commands from ~/.config/gdb/gdbearlyinit
715 or ~/.gdbearlyinit if these files are present. These files are
716 processed earlier than any of the other initialization files and
717 can affect parts of GDB's startup that previously had already been
718 completed before the initialization files were read, for example
719 styling of the initial GDB greeting.
720
721* GDB now has two new options "--early-init-command" and
722 "--early-init-eval-command" with corresponding short options "-eix"
723 and "-eiex" that allow options (that would normally appear in a
724 gdbearlyinit file) to be passed on the command line.
725
96f842cb
AB
726* For RISC-V targets, the target feature "org.gnu.gdb.riscv.vector" is
727 now understood by GDB, and can be used to describe the vector
728 registers of a target. The precise requirements of this register
729 feature are documented in the GDB manual.
730
ae66a8f1
SP
731* For ARM targets, the "org.gnu.gdb.arm.m-profile-mve" feature is now
732 supported by GDB and describes a new VPR register from the ARM MVE
733 (Helium) extension. See the GDB manual for more information.
734
90b044ef
PA
735* TUI improvements
736
737 ** TUI windows now support mouse actions. The mouse wheel scrolls
738 the appropriate window.
739
740 ** Key combinations that do not have a specific action on the
741 focused window are passed to GDB. For example, you now can use
742 Ctrl-Left/Ctrl-Right to move between words in the command window
743 regardless of which window is in focus. Previously you would
744 need to focus on the command window for such key combinations to
745 work.
746
8d378f27
SM
747* New commands
748
749set debug event-loop
750show debug event-loop
751 Control the display of debug output about GDB's event loop.
752
ce192338
LM
753set print memory-tag-violations
754show print memory-tag-violations
755 Control whether to display additional information about memory tag violations
756 when printing pointers and addresses. Architecture support for memory
757 tagging is required for this option to have an effect.
758
50a5f187
AB
759maintenance flush symbol-cache
760maintenance flush register-cache
761 These new commands are equivalent to the already existing commands
762 'maintenance flush-symbol-cache' and 'flushregs' respectively.
763
ee9812a0
AB
764maintenance flush dcache
765 A new command to flush the dcache.
766
02a79309
AB
767maintenance info target-sections
768 Print GDB's internal target sections table.
769
ff770835
SM
770maintenance info jit
771 Print the JIT code objects in the inferior known to GDB.
772
ce192338
LM
773memory-tag show-logical-tag POINTER
774 Print the logical tag for POINTER.
775memory-tag with-logical-tag POINTER TAG
776 Print POINTER with logical tag TAG.
777memory-tag show-allocation-tag ADDRESS
778 Print the allocation tag for ADDRESS.
779memory-tag set-allocation-tag ADDRESS LENGTH TAGS
780 Set the allocation tag for [ADDRESS, ADDRESS + LENGTH) to TAGS.
781memory-tag check POINTER
782 Validate that POINTER's logical tag matches the allocation tag.
783
5809fbf2
TT
784set startup-quietly on|off
785show startup-quietly
786 When 'on', this causes GDB to act as if "-silent" were passed on the
787 command line. This command needs to be added to an early
788 initialization file (e.g. ~/.config/gdb/gdbearlyinit) in order to
789 affect GDB.
790
fbb46296
LS
791set print type hex on|off
792show print type hex
793 When 'on', the 'ptype' command uses hexadecimal notation to print sizes
794 and offsets of struct members. When 'off', decimal notation is used.
795
edeaceda
AB
796set python ignore-environment on|off
797show python ignore-environment
798 When 'on', this causes GDB's builtin Python to ignore any
8eb82ba1 799 environment variables that would otherwise affect how Python
edeaceda
AB
800 behaves. This command needs to be added to an early initialization
801 file (e.g. ~/.config/gdb/gdbearlyinit) in order to affect GDB.
802
803set python dont-write-bytecode auto|on|off
804show python dont-write-bytecode
805 When 'on', this causes GDB's builtin Python to not write any
806 byte-code (.pyc files) to disk. This command needs to be added to
807 an early initialization file (e.g. ~/.config/gdb/gdbearlyinit) in
808 order to affect GDB. When 'off' byte-code will always be written.
809 When set to 'auto' (the default) Python will check the
8eb82ba1 810 PYTHONDONTWRITEBYTECODE environment variable.
edeaceda 811
733d554a
TBA
812* Changed commands
813
814break [PROBE_MODIFIER] [LOCATION] [thread THREADNUM]
815 [-force-condition] [if CONDITION]
816 This command would previously refuse setting a breakpoint if the
817 CONDITION expression is invalid at a location. It now accepts and
818 defines the breakpoint if there is at least one location at which
819 the CONDITION is valid. The locations for which the CONDITION is
820 invalid, are automatically disabled. If CONDITION is invalid at all
821 of the locations, setting the breakpoint is still rejected. However,
822 the '-force-condition' flag can be used in this case for forcing GDB to
823 define the breakpoint, making all the current locations automatically
824 disabled. This may be useful if the user knows the condition will
825 become meaningful at a future location, e.g. due to a shared library
826 load.
827
828condition [-force] N COND
829 The behavior of this command is changed the same way for the 'break'
830 command as explained above. The '-force' flag can be used to force
831 GDB into defining the condition even when COND is invalid for all the
832 current locations of breakpoint N.
833
50a5f187
AB
834flushregs
835maintenance flush-symbol-cache
836 These commands are deprecated in favor of the new commands
837 'maintenance flush register-cache' and 'maintenance flush
838 symbol-cache' respectively.
839
9d2d8a16
AB
840set style version foreground COLOR
841set style version background COLOR
842set style version intensity VALUE
843 Control the styling of GDB's version number text.
844
2e3773ff
LS
845inferior [ID]
846 When the ID parameter is omitted, then this command prints information
847 about the current inferior. When the ID parameter is present, the
848 behavior of the command is unchanged and have the inferior ID become
849 the current inferior.
850
bf3386f0
AB
851maintenance info sections
852 The ALLOBJ keyword has been replaced with an -all-objects command
853 line flag. It is now possible to filter which sections are printed
854 even when -all-objects is passed.
855
fbb46296
LS
856ptype[/FLAGS] TYPE | EXPRESSION
857 The 'ptype' command has two new flags. When '/x' is set, hexadecimal
858 notation is used when printing sizes and offsets of struct members.
859 When '/d' is set, decimal notation is used when printing sizes and
860 offsets of struct members. Default behavior is given by 'show print
861 type hex'.
862
bd742128
AB
863info sources
864 The info sources command output has been restructured. The results
865 are now based around a list of objfiles (executable and libraries),
866 and for each objfile the source files that are part of that objfile
867 are listed.
868
18b8df43
AM
869* Removed targets and native configurations
870
871ARM Symbian arm*-*-symbianelf*
872
ce192338
LM
873* New remote packets
874
875qMemTags
876 Request the remote to send allocation tags for a particular memory range.
877QMemTags
878 Request the remote to store the specified allocation tags to the requested
879 memory range.
880
97cef6b7
GB
881* Guile API
882
883 ** Improved support for rvalue reference values:
884 TYPE_CODE_RVALUE_REF is now exported as part of the API and the
885 value-referenced-value procedure now handles rvalue reference
886 values.
887
ee35ce82
GB
888 ** New procedures for obtaining value variants:
889 value-reference-value, value-rvalue-reference-value and
890 value-const-value.
9d4fc61d 891
ad42014b
GB
892 ** Temporary breakpoints can now be created with make-breakpoint and
893 tested for using breakpoint-temporary?.
894
55789354
TBA
895* Python API
896
897 ** Inferior objects now contain a read-only 'connection_num' attribute that
898 gives the connection number as seen in 'info connections' and
899 'info inferiors'.
900
d52b8007
AB
901 ** New method gdb.Frame.level() which returns the stack level of the
902 frame object.
903
904 ** New method gdb.PendingFrame.level() which returns the stack level
905 of the frame object.
906
6b95f5ad
AB
907 ** When hitting a catchpoint, the Python API will now emit a
908 gdb.BreakpointEvent rather than a gdb.StopEvent. The
909 gdb.Breakpoint attached to the event will have type BP_CATCHPOINT.
910
90b044ef
PA
911 ** Python TUI windows can now receive mouse click events. If the
912 Window object implements the click method, it is called for each
913 mouse click event in this window.
914
ed6a896c 915*** Changes in GDB 10
4decd62b 916
995d3a19
SV
917* There are new feature names for ARC targets: "org.gnu.gdb.arc.core"
918 and "org.gnu.gdb.arc.aux". The old names are still supported but
919 must be considered obsolete. They will be deprecated after some
920 grace period.
921
5b4a1a8d
PW
922* Help and apropos commands will now show the documentation of a
923 command only once, even if that command has one or more aliases.
924 These commands now show the command name, then all of its aliases,
925 and finally the description of the command.
926
927* 'help aliases' now shows only the user defined aliases. GDB predefined
928 aliases are shown together with their aliased command.
929
0d79cdc4
AM
930* GDB now supports debuginfod, an HTTP server for distributing ELF/DWARF
931 debugging information as well as source code.
932
933 When built with debuginfod, GDB can automatically query debuginfod
934 servers for the separate debug files and source code of the executable
935 being debugged.
936
937 To build GDB with debuginfod, pass --with-debuginfod to configure (this
938 requires libdebuginfod, the debuginfod client library).
939
940 debuginfod is distributed with elfutils, starting with version 0.178.
941
942 You can get the latest version from https://sourceware.org/elfutils.
943
7cf663a9
PA
944* Multi-target debugging support
945
946 GDB now supports debugging multiple target connections
947 simultaneously. For example, you can now have each inferior
948 connected to different remote servers running in different machines,
949 or have one inferior debugging a local native process, an inferior
950 debugging a core dump, etc.
951
952 This support is experimental and comes with some limitations -- you
953 can only resume multiple targets simultaneously if all targets
954 support non-stop mode, and all remote stubs or servers must support
955 the same set of remote protocol features exactly. See also "info
956 connections" and "add-inferior -no-connection" below, and "maint set
957 target-non-stop" in the user manual.
958
bf84f706
MR
959* New features in the GDB remote stub, GDBserver
960
ada508b6
SV
961 ** GDBserver is now supported on ARC GNU/Linux.
962
bf84f706
MR
963 ** GDBserver is now supported on RISC-V GNU/Linux.
964
6a17d503
SM
965 ** GDBserver no longer supports these host triplets:
966
967 i[34567]86-*-lynxos*
968 powerpc-*-lynxos*
969 i[34567]86-*-nto*
970 bfin-*-*linux*
971 crisv32-*-linux*
972 cris-*-linux*
973 m32r*-*-linux*
974 tilegx-*-linux*
975 arm*-*-mingw32ce*
976 i[34567]86-*-mingw32ce*
977
3f602821
EZ
978* Debugging MS-Windows processes now sets $_exitsignal when the
979 inferior is terminated by a signal, instead of setting $_exitcode.
980
8fb75323
CB
981* Multithreaded symbol loading has now been enabled by default on systems
982 that support it (see entry for GDB 9, below), providing faster
983 performance for programs with many symbols.
984
7928d571
HD
985* The $_siginfo convenience variable now also works on Windows targets,
986 and will display the EXCEPTION_RECORD of the last handled exception.
987
7c043ba6 988* TUI windows can now be arranged horizontally.
63e163f2
AB
989
990* The command history filename can now be set to the empty string
991 either using 'set history filename' or by setting 'GDBHISTFILE=' in
992 the environment. The effect of setting this filename to the empty
993 string is that GDB will not try to load any previous command
994 history.
46f9f931
HD
995
996* On Windows targets, it is now possible to debug 32-bit programs with a
997 64-bit GDB.
7c043ba6 998
e47e48f6
PW
999* New commands
1000
1001set exec-file-mismatch -- Set exec-file-mismatch handling (ask|warn|off).
1002show exec-file-mismatch -- Show exec-file-mismatch handling (ask|warn|off).
98c59b52
PA
1003 Set or show the option 'exec-file-mismatch'. When GDB attaches to a
1004 running process, this new option indicates whether to detect
1005 a mismatch between the current executable file loaded by GDB and the
1006 executable file used to start the process. If 'ask', the default,
1007 display a warning and ask the user whether to load the process
1008 executable file; if 'warn', just display a warning; if 'off', don't
1009 attempt to detect a mismatch.
e47e48f6 1010
ee325b61
TT
1011tui new-layout NAME WINDOW WEIGHT [WINDOW WEIGHT]...
1012 Define a new TUI layout, specifying its name and the windows that
1013 will be displayed.
1014
caa7fd04
AB
1015maintenance print xml-tdesc [FILE]
1016 Prints the current target description as an XML document. If the
1017 optional FILE is provided (which is an XML target description) then
1018 the target description is read from FILE into GDB, and then
1019 reprinted.
1020
b089853a
KB
1021maintenance print core-file-backed-mappings
1022 Prints file-backed mappings loaded from a core file's note section.
1023 Output is expected to be similar to that of "info proc mappings".
1024
a5c641b5
AB
1025set debug fortran-array-slicing on|off
1026show debug fortran-array-slicing
1027 Print debugging when taking slices of Fortran arrays.
1028
1029set fortran repack-array-slices on|off
1030show fortran repack-array-slices
1031 When taking slices from Fortran arrays and strings, if the slice is
1032 non-contiguous within the original value then, when this option is
1033 on, the new value will be repacked into a single contiguous value.
1034 When this option is off, then the value returned will consist of a
1035 descriptor that describes the slice within the memory of the
1036 original parent value.
1037
5b860c93
PW
1038* Changed commands
1039
1040alias [-a] [--] ALIAS = COMMAND [DEFAULT-ARGS...]
1041 The alias command can now specify default args for an alias.
1042 GDB automatically prepends the alias default args to the argument list
1043 provided explicitly by the user.
1044 For example, to have a backtrace with full details, you can define
1045 an alias 'bt_ALL' as
1046 'alias bt_ALL = backtrace -entry-values both -frame-arg all
1047 -past-main -past-entry -full'.
1048 Alias default arguments can also use a set of nested 'with' commands,
1049 e.g. 'alias pp10 = with print pretty -- with print elem 10 -- print'
1050 defines the alias pp10 that will pretty print a maximum of 10 elements
1051 of the given expression (if the expression is an array).
1052
bf84f706
MR
1053* New targets
1054
1055GNU/Linux/RISC-V (gdbserver) riscv*-*-linux*
39791af2 1056BPF bpf-unknown-none
3dab9e15 1057Z80 z80-unknown-*
bf84f706 1058
01b1af32
TT
1059* Python API
1060
1061 ** gdb.register_window_type can be used to implement new TUI windows
1062 in Python.
1063
1acda803
TT
1064 ** Dynamic types can now be queried. gdb.Type has a new attribute,
1065 "dynamic", and gdb.Type.sizeof can be None for a dynamic type. A
1066 field of a dynamic type may have None for its "bitpos" attribute
1067 as well.
1068
2b2fbab8
TT
1069 ** Commands written in Python can be in the "TUI" help class by
1070 registering with the new constant gdb.COMMAND_TUI.
1071
87dbc774
AB
1072 ** New method gdb.PendingFrame.architecture () to retrieve the
1073 architecture of the pending frame.
1074
0f767f94
AB
1075 ** New gdb.Architecture.registers method that returns a
1076 gdb.RegisterDescriptorIterator object, an iterator that returns
1077 gdb.RegisterDescriptor objects. The new RegisterDescriptor is a
1078 way to query the registers available for an architecture.
1079
64cb3757
AB
1080 ** New gdb.Architecture.register_groups method that returns a
1081 gdb.RegisterGroupIterator object, an iterator that returns
1082 gdb.RegisterGroup objects. The new RegisterGroup is a way to
1083 discover the available register groups.
1084
68cf161c
LC
1085* Guile API
1086
ae5369e7 1087 ** GDB can now be built with GNU Guile 3.0 and 2.2 in addition to 2.0.
68cf161c
LC
1088
1089 ** Procedures 'memory-port-read-buffer-size',
1090 'set-memory-port-read-buffer-size!', 'memory-port-write-buffer-size',
1091 and 'set-memory-port-write-buffer-size!' are deprecated. When
1092 using Guile 2.2 and later, users who need to control the size of
1093 a memory port's internal buffer can use the 'setvbuf' procedure.
1094
4decd62b 1095*** Changes in GDB 9
9335e75a 1096
1a3da2cd
AB
1097* 'thread-exited' event is now available in the annotations interface.
1098
7734102d
EZ
1099* New built-in convenience variables $_gdb_major and $_gdb_minor
1100 provide the GDB version. They are handy for conditionally using
1101 features available only in or since specific GDB versions, in
1102 scripts that should work error-free with many different versions,
1103 such as in system-wide init files.
1104
aed61d02
PW
1105* New built-in convenience functions $_gdb_setting, $_gdb_setting_str,
1106 $_gdb_maint_setting and $_gdb_maint_setting_str provide access to values
1107 of the GDB settings and the GDB maintenance settings. They are handy
1108 for changing the logic of user defined commands depending on the
1109 current GDB settings.
1110
81a24d04
JB
1111* GDB now supports Thread Local Storage (TLS) variables on several
1112 FreeBSD architectures (amd64, i386, powerpc, riscv). Other
1113 architectures require kernel changes. TLS is not yet supported for
1114 amd64 and i386 process core dumps.
1115
3d31bc39
AH
1116* Support for Pointer Authentication (PAC) on AArch64 Linux. Return
1117 addresses that required unmasking are shown in the backtrace with the
1118 postfix [PAC].
d851aa71 1119
eb41253a 1120* Two new convenience functions $_cimag and $_creal that extract the
8bdc1658
AB
1121 imaginary and real parts respectively from complex numbers.
1122
52ce35e2
TT
1123* New built-in convenience variables $_shell_exitcode and $_shell_exitsignal
1124 provide the exitcode or exit status of the shell commands launched by
1125 GDB commands such as "shell", "pipe" and "make".
1126
bf498525
PW
1127* The command define-prefix can now define user defined prefix commands.
1128 User defined commands can now be defined using these user defined prefix
1129 commands.
1130
1131* Command names can now use the . character.
1132
e3ec872f
YS
1133* The RX port now supports XML target descriptions.
1134
4993045d
PW
1135* GDB now shows the Ada task names at more places, e.g. in task switching
1136 messages.
1137
6a062a93
CB
1138* GDB can now be compiled with Python 3 on Windows.
1139
37f6a7f4
TT
1140* New convenience variable $_ada_exception holds the address of the
1141 Ada exception being thrown. This is set by Ada-related catchpoints.
1142
179aed7f
AB
1143* GDB can now place breakpoints on nested functions and subroutines in
1144 Fortran code. The '::' operator can be used between parent and
1145 child scopes when placing breakpoints, for example:
1146
1147 (gdb) break outer_function::inner_function
1148
1149 The 'outer_function::' prefix is only needed if 'inner_function' is
1150 not visible in the current scope.
1151
ed2a2229
CB
1152* In addition to the system-wide gdbinit file, if configured with
1153 --with-system-gdbinit-dir, GDB will now also load files in that directory
1154 as system gdbinit files, unless the -nx or -n flag is provided. Files
1155 with extensions .gdb, .py and .scm are supported as long as GDB was
1156 compiled with support for that language.
1157
e49b22ff
CB
1158* GDB now supports multithreaded symbol loading for higher performance.
1159 This feature is still in testing, so it is disabled by default. You
1160 can turn it on using 'maint set worker-threads unlimited'.
1161
52093e1b
MB
1162* Python API
1163
1164 ** The gdb.Value type has a new method 'format_string' which returns a
1165 string representing the value. The formatting is controlled by the
1166 optional keyword arguments: 'raw', 'pretty_arrays', 'pretty_structs',
1167 'array_indexes', 'symbols', 'unions', 'deref_refs', 'actual_objects',
1168 'static_members', 'max_elements', 'repeat_threshold', and 'format'.
1169
e1f2e1a2
CB
1170 ** gdb.Type has a new property 'objfile' which returns the objfile the
1171 type was defined in.
1172
bc4268a5
PW
1173 ** The frame information printed by the python frame filtering code
1174 is now consistent with what the 'backtrace' command prints when
1175 there are no filters, or when the 'backtrace' '-no-filters' option
1176 is given.
1177
2906593f
CB
1178 ** The new function gdb.lookup_static_symbol can be used to look up
1179 symbols with static linkage.
1180
086baaf1
AB
1181 ** The new function gdb.lookup_static_symbols can be used to look up
1182 all static symbols with static linkage.
1183
c620ed88
CB
1184 ** gdb.Objfile has new methods 'lookup_global_symbol' and
1185 'lookup_static_symbol' to lookup a symbol from this objfile only.
1186
0b27c27d
CB
1187 ** gdb.Block now supports the dictionary syntax for accessing symbols in
1188 this block (e.g. block['local_variable']).
1189
136afab8
PW
1190* New commands
1191
e2c52041
PW
1192| [COMMAND] | SHELL_COMMAND
1193| -d DELIM COMMAND DELIM SHELL_COMMAND
1194pipe [COMMAND] | SHELL_COMMAND
1195pipe -d DELIM COMMAND DELIM SHELL_COMMAND
1196 Executes COMMAND and sends its output to SHELL_COMMAND.
1197 With no COMMAND, repeat the last executed command
1198 and send its output to SHELL_COMMAND.
1199
bf498525
PW
1200define-prefix COMMAND
1201 Define or mark a command as a user-defined prefix command.
1202
fdbc9870
PA
1203with SETTING [VALUE] [-- COMMAND]
1204w SETTING [VALUE] [-- COMMAND]
1205 Temporarily set SETTING, run COMMAND, and restore SETTING.
1206 Usage: with SETTING -- COMMAND
1207 With no COMMAND, repeats the last executed command.
1208 SETTING is any GDB setting you can change with the "set"
1209 subcommands. For example, 'with language c -- print someobj'
1210 temporarily switches to the C language in order to print someobj.
1211 Settings can be combined: 'w lang c -- w print elements unlimited --
1212 usercmd' switches to the C language and runs usercmd with no limit
1213 of array elements to print.
1214
1215maint with SETTING [VALUE] [-- COMMAND]
1216 Like "with", but works with "maintenance set" settings.
1217
136afab8
PW
1218set may-call-functions [on|off]
1219show may-call-functions
1220 This controls whether GDB will attempt to call functions in
1221 the program, such as with expressions in the print command. It
1222 defaults to on. Calling functions in the program being debugged
1223 can have undesired side effects. It is now possible to forbid
1224 such function calls. If function calls are forbidden, GDB will throw
1225 an error when a command (such as print expression) calls a function
1226 in the program.
1227
000439d5
TT
1228set print finish [on|off]
1229show print finish
1230 This controls whether the `finish' command will display the value
1231 that is returned by the current function. When `off', the value is
1232 still entered into the value history, but it is not printed. The
1233 default is `on'.
1234
1bd0c6e4
AB
1235set print max-depth
1236show print max-depth
1237 Allows deeply nested structures to be simplified when printing by
1238 replacing deeply nested parts (beyond the max-depth) with ellipses.
1239 The default max-depth is 20, but this can be set to unlimited to get
1240 the old behavior back.
1241
d8edc8b7
PW
1242set print raw-values [on|off]
1243show print raw-values
1244 By default, GDB applies the enabled pretty printers when printing a
1245 value. This allows to ignore the enabled pretty printers for a series
1246 of commands. The default is 'off'.
1247
b7060614
AH
1248set logging debugredirect [on|off]
1249 By default, GDB debug output will go to both the terminal and the logfile.
1250 Set if you want debug output to go only to the log file.
1251
e664d728
PW
1252set style title foreground COLOR
1253set style title background COLOR
1254set style title intensity VALUE
1255 Control the styling of titles.
1256
1257set style highlight foreground COLOR
1258set style highlight background COLOR
1259set style highlight intensity VALUE
1260 Control the styling of highlightings.
1261
22138db6
TT
1262maint set worker-threads
1263maint show worker-threads
1264 Control the number of worker threads that can be used by GDB. The
e49b22ff 1265 default is 0. "unlimited" lets GDB choose a number that is
22138db6
TT
1266 reasonable. Currently worker threads are only used when demangling
1267 the names of linker symbols.
1268
a2a7af0c
TT
1269set style tui-border foreground COLOR
1270set style tui-border background COLOR
1271 Control the styling of TUI borders.
1272
1273set style tui-active-border foreground COLOR
1274set style tui-active-border background COLOR
1275 Control the styling of the active TUI border.
1276
c6ac8931
PA
1277maint set test-settings KIND
1278maint show test-settings KIND
dca0f6c0
PA
1279 A set of commands used by the testsuite for exercising the settings
1280 infrastructure.
1281
45e42163
TT
1282maint set tui-resize-message [on|off]
1283maint show tui-resize-message
1284 Control whether GDB prints a message each time the terminal is
1285 resized when in TUI mode. This is primarily useful for testing the
1286 TUI.
1287
bc4268a5
PW
1288set print frame-info [short-location|location|location-and-address
1289 |source-and-location|source-line|auto]
1290show print frame-info
1291 This controls what frame information is printed by the commands printing
1292 a frame. This setting will e.g. influence the behaviour of 'backtrace',
1293 'frame', 'stepi'. The python frame filtering also respect this setting.
1294 The 'backtrace' '-frame-info' option can override this global setting.
1295
d1da6b01
TT
1296set tui compact-source
1297show tui compact-source
1298
1299 Enable the "compact" display mode for the TUI source window. The
1300 compact display uses only as much space as is needed for the line
1301 numbers in the current file, and only a single space to separate the
1302 line numbers from the source.
1303
59c35742
AB
1304info modules [-q] [REGEXP]
1305 Return a list of Fortran modules matching REGEXP, or all modules if
1306 no REGEXP is given.
1307
165f8965
AB
1308info module functions [-q] [-m MODULE_REGEXP] [-t TYPE_REGEXP] [REGEXP]
1309 Return a list of functions within all modules, grouped by module.
1310 The list of functions can be restricted with the optional regular
1311 expressions. MODULE_REGEXP matches against the module name,
1312 TYPE_REGEXP matches against the function type signature, and REGEXP
1313 matches against the function name.
1314
1315info module variables [-q] [-m MODULE_REGEXP] [-t TYPE_REGEXP] [REGEXP]
1316 Return a list of variables within all modules, grouped by module.
1317 The list of variables can be restricted with the optional regular
1318 expressions. MODULE_REGEXP matches against the module name,
1319 TYPE_REGEXP matches against the variable type, and REGEXP matches
1320 against the variable name.
1321
6cc8564b
LM
1322set debug remote-packet-max-chars
1323show debug remote-packet-max-chars
1324 Controls the number of characters to output in a remote packet when using
1325 "set debug remote".
1326 The default is 512 bytes.
1327
65c574f6
PA
1328info connections
1329 Lists the target connections currently in use.
1330
e664d728
PW
1331* Changed commands
1332
1333help
1334 The "help" command uses the title style to enhance the
1335 readibility of its output by styling the classes and
1336 command names.
1337
1338apropos [-v] REGEXP
1339 Similarly to "help", the "apropos" command also uses the
1340 title style for the command names. "apropos" accepts now
1341 a flag "-v" (verbose) to show the full documentation
1342 of matching commands and to use the highlight style to mark
1343 the documentation parts matching REGEXP.
1344
1f6f6e21
PW
1345printf
1346eval
1347 The GDB printf and eval commands can now print C-style and Ada-style
1348 string convenience variables without calling functions in the program.
1349 This allows to do formatted printing of strings without having
1350 a running inferior, or when debugging a core dump.
1351
ae60f04e
PW
1352info sources [-dirname | -basename] [--] [REGEXP]
1353 This command has now optional arguments to only print the files
1354 whose names match REGEXP. The arguments -dirname and -basename
1355 allow to restrict matching respectively to the dirname and basename
1356 parts of the files.
1357
e664d728
PW
1358show style
1359 The "show style" and its subcommands are now styling
1360 a style name in their output using its own style, to help
1361 the user visualize the different styles.
1362
bc4268a5
PW
1363set print frame-arguments
1364 The new value 'presence' indicates to only indicate the presence of
1365 arguments using ..., instead of printing argument names and values.
1366
2daf894e
PA
1367set print raw-frame-arguments
1368show print raw-frame-arguments
1369
1370 These commands replace the similarly-named "set/show print raw
1371 frame-arguments" commands (now with a dash instead of a space). The
1372 old commands are now deprecated and may be removed in a future
1373 release.
e664d728 1374
65c574f6
PA
1375add-inferior [-no-connection]
1376 The add-inferior command now supports a "-no-connection" flag that
1377 makes the new inferior start with no target connection associated.
1378 By default, the new inferior inherits the target connection of the
1379 current inferior. See also "info connections".
1380
1381info inferior
1382 This command's output now includes a new "Connection" column
1383 indicating which target connection an inferior is bound to. See
1384 "info connections" above.
1385
3345721a
PA
1386maint test-options require-delimiter
1387maint test-options unknown-is-error
1388maint test-options unknown-is-operand
1389maint show test-options-completion-result
1390 Commands used by the testsuite to validate the command options
1391 framework.
1392
78e8cb91
TT
1393focus, winheight, +, -, >, <
1394 These commands are now case-sensitive.
1395
3345721a
PA
1396* New command options, command completion
1397
1398 GDB now has a standard infrastructure to support dash-style command
1399 options ('-OPT'). One benefit is that commands that use it can
1400 easily support completion of command line arguments. Try "CMD
1401 -[TAB]" or "help CMD" to find options supported by a command. Over
1402 time, we intend to migrate most commands to this infrastructure. A
1403 number of commands got support for new command options in this
1404 release:
1405
1406 ** The "print" and "compile print" commands now support a number of
1407 options that allow overriding relevant global print settings as
1408 set by "set print" subcommands:
1409
1410 -address [on|off]
1411 -array [on|off]
1412 -array-indexes [on|off]
1413 -elements NUMBER|unlimited
1414 -null-stop [on|off]
1415 -object [on|off]
1416 -pretty [on|off]
d8edc8b7 1417 -raw-values [on|off]
3345721a
PA
1418 -repeats NUMBER|unlimited
1419 -static-members [on|off]
1420 -symbol [on|off]
1421 -union [on|off]
1422 -vtbl [on|off]
1423
1424 Note that because the "print"/"compile print" commands accept
1425 arbitrary expressions which may look like options (including
1426 abbreviations), if you specify any command option, then you must
1427 use a double dash ("--") to mark the end of argument processing.
1428
1429 ** The "backtrace" command now supports a number of options that
1430 allow overriding relevant global print settings as set by "set
1431 backtrace" and "set print" subcommands:
1432
1433 -entry-values no|only|preferred|if-needed|both|compact|default
1434 -frame-arguments all|scalars|none
1435 -raw-frame-arguments [on|off]
bc4268a5
PW
1436 -frame-info auto|source-line|location|source-and-location
1437 |location-and-address|short-location
3345721a
PA
1438 -past-main [on|off]
1439 -past-entry [on|off]
1440
1441 In addition, the full/no-filters/hide qualifiers are now also
1442 exposed as command options too:
1443
1444 -full
1445 -no-filters
1446 -hide
1447
1448 ** The "frame apply", "tfaas" and "faas" commands similarly now
1449 support the following options:
1450
1451 -past-main [on|off]
1452 -past-entry [on|off]
1453
ae60f04e
PW
1454 ** The new "info sources" options -dirname and -basename options
1455 are using the standard '-OPT' infrastructure.
1456
3345721a
PA
1457 All options above can also be abbreviated. The argument of boolean
1458 (on/off) options can be 0/1 too, and also the argument is assumed
1459 "on" if omitted. This allows writing compact command invocations,
1460 like for example:
1461
d8edc8b7 1462 (gdb) p -ra -p -o 0 -- *myptr
3345721a
PA
1463
1464 The above is equivalent to:
1465
d8edc8b7 1466 (gdb) print -raw-values -pretty -object off -- *myptr
3345721a 1467
a8eab7c6
AB
1468 ** The "info types" command now supports the '-q' flag to disable
1469 printing of some header information in a similar fashion to "info
1470 variables" and "info functions".
1471
4acfdd20
AB
1472 ** The "info variables", "info functions", and "whereis" commands
1473 now take a '-n' flag that excludes non-debug symbols (symbols
1474 from the symbol table, not from the debug info such as DWARF)
1475 from the results.
1476
3345721a
PA
1477* Completion improvements
1478
1479 ** GDB can now complete the options of the "thread apply all" and
1480 "taas" commands, and their "-ascending" option can now be
1481 abbreviated.
1482
60cfcb20
AB
1483 ** GDB can now complete the options of the "info threads", "info
1484 functions", "info variables", "info locals", and "info args"
1485 commands.
54d66006 1486
3345721a
PA
1487 ** GDB can now complete the options of the "compile file" and
1488 "compile code" commands. The "compile file" command now
1489 completes on filenames.
1490
1491 ** GDB can now complete the backtrace command's
1492 "full/no-filters/hide" qualifiers.
1493
1494* In settings, you can now abbreviate "unlimited".
1495
1496 E.g., "set print elements u" is now equivalent to "set print
1497 elements unlimited".
1498
26648588
JV
1499* New MI commands
1500
1501-complete
1502 This lists all the possible completions for the rest of the line, if it
1503 were to be given as a command itself. This is intended for use by MI
1504 frontends in cases when separate CLI and MI channels cannot be used.
1505
30056ea0
AB
1506-catch-throw, -catch-rethrow, and -catch-catch
1507 These can be used to catch C++ exceptions in a similar fashion to
1508 the CLI commands 'catch throw', 'catch rethrow', and 'catch catch'.
1509
7dc42066
AB
1510-symbol-info-functions, -symbol-info-types, and -symbol-info-variables
1511 These commands are the MI equivalent of the CLI commands 'info
1512 functions', 'info types', and 'info variables' respectively.
1513
db5960b4
AB
1514-symbol-info-modules, this is the MI equivalent of the CLI 'info
1515 modules' command.
1516
293b38d6
AB
1517-symbol-info-module-functions and -symbol-info-module-variables.
1518 These commands are the MI equivalent of the CLI commands 'info
1519 module functions' and 'info module variables'.
1520
aa7ca1bb
AH
1521* Other MI changes
1522
5a3a0d63
JB
1523 ** The default version of the MI interpreter is now 3 (-i=mi3).
1524
1525 ** The output of information about multi-location breakpoints (which is
1526 syntactically incorrect in MI 2) has changed in MI 3. This affects
1527 the following commands and events:
1528
1529 - -break-insert
1530 - -break-info
1531 - =breakpoint-created
1532 - =breakpoint-modified
1533
1534 The -fix-multi-location-breakpoint-output command can be used to enable
1535 this behavior with previous MI versions.
1536
aa7ca1bb
AH
1537 ** Backtraces and frames include a new optional field addr_flags which is
1538 given after the addr field. On AArch64 this contains PAC if the address
1539 has been masked in the frame. On all other targets the field is not
1540 present.
1541
b7060614
AH
1542* Testsuite
1543
1544 The testsuite now creates the files gdb.cmd (containing the arguments
1545 used to launch GDB) and gdb.in (containing all the commands sent to
1546 GDB) in the output directory for each test script. Multiple invocations
1547 are appended with .1, .2, .3 etc.
1548
c6bdbeb7
AH
1549* Building GDB and GDBserver now requires GNU make >= 3.82.
1550
1551 Using another implementation of the make program or an earlier version of
1552 GNU make to build GDB or GDBserver is not supported.
1553
86c6b807
TT
1554* Building GDB now requires GNU readline >= 7.0.
1555
1556 GDB now bundles GNU readline 8.0, but if you choose to use
1557 --with-system-readline, only readline >= 7.0 can be used.
1558
11061048
TT
1559* The TUI SingleKey keymap is now named "SingleKey". This can be used
1560 from .inputrc to bind keys in this keymap. This feature is only
1561 available when gdb is built against GNU readline 8.0 or later.
1562
abf516c6
UW
1563* Removed targets and native configurations
1564
1565 GDB no longer supports debugging the Cell Broadband Engine. This includes
1566 both debugging standalone Cell/B.E. SPU applications and integrated debugging
1567 of Cell/B.E. applications that use both the PPU and SPU architectures.
1568
ddd44b70
DD
1569* New Simulators
1570
1571TI PRU pru-*-elf
1572
dae8b3eb
RO
1573* Removed targets and native configurations
1574
1575Solaris 10 i?86-*-solaris2.10, x86_64-*-solaris2.10,
1576 sparc*-*-solaris2.10
1577
9335e75a 1578*** Changes in GDB 8.3
4e5b2f89 1579
8d619c01
EBM
1580* GDB and GDBserver now support access to additional registers on
1581 PowerPC GNU/Linux targets: PPR, DSCR, TAR, EBB/PMU registers, and
1582 HTM registers.
1583
078a0207
KS
1584* GDB now has experimental support for the compilation and injection of
1585 C++ source code into the inferior. This beta release does not include
1586 support for several language features, such as templates, constructors,
1587 and operators.
1588
1589 This feature requires GCC 7.1 or higher built with libcp1.so
1590 (the C++ plug-in).
1591
c7ab0aef
SDJ
1592* GDB and GDBserver now support IPv6 connections. IPv6 addresses
1593 can be passed using the '[ADDRESS]:PORT' notation, or the regular
1594 'ADDRESS:PORT' method.
1595
7d11235d
SM
1596* DWARF index cache: GDB can now automatically save indices of DWARF
1597 symbols on disk to speed up further loading of the same binaries.
1598
e8bf1ce4
JB
1599* Ada task switching is now supported on aarch64-elf targets when
1600 debugging a program using the Ravenscar Profile. For more information,
1601 see the "Tasking Support when using the Ravenscar Profile" section
1602 in the GDB user manual.
1603
b0f492b9
GB
1604* GDB in batch mode now exits with status 1 if the last command to be
1605 executed failed.
1606
b5ffee31
AB
1607* The RISC-V target now supports target descriptions.
1608
e9076973
JB
1609* System call catchpoints now support system call aliases on FreeBSD.
1610 When the ABI of a system call changes in FreeBSD, this is
1611 implemented by leaving a compatibility system call using the old ABI
1612 at the existing number and allocating a new system call number for
1613 the new ABI. For example, FreeBSD 12 altered the layout of 'struct
1614 kevent' used by the 'kevent' system call. As a result, FreeBSD 12
1615 kernels ship with both 'kevent' and 'freebsd11_kevent' system calls.
1616 The 'freebsd11_kevent' system call is assigned an alias of 'kevent'
1617 so that a system call catchpoint for the 'kevent' system call will
1618 catch invocations of both the 'kevent' and 'freebsd11_kevent'
1619 binaries. This ensures that 'kevent' system calls are caught for
1620 binaries using either the old or new ABIs.
1621
140a4bc0
TT
1622* Terminal styling is now available for the CLI and the TUI. GNU
1623 Source Highlight can additionally be used to provide styling of
1624 source code snippets. See the "set style" commands, below, for more
1625 information.
1626
041be526
SM
1627* Removed support for old demangling styles arm, edg, gnu, hp and
1628 lucid.
1629
a14c4daa
PW
1630* New commands
1631
078a0207
KS
1632set debug compile-cplus-types
1633show debug compile-cplus-types
1634 Control the display of debug output about type conversion in the
82f06518 1635 C++ compile feature. Commands have no effect while compiling
078a0207
KS
1636 for other languages.
1637
3e68067f
SM
1638set debug skip
1639show debug skip
1640 Control whether debug output about files/functions skipping is
1641 displayed.
1642
a14c4daa
PW
1643frame apply [all | COUNT | -COUNT | level LEVEL...] [FLAG]... COMMAND
1644 Apply a command to some frames.
1645 FLAG arguments allow to control what output to produce and how to handle
1646 errors raised when applying COMMAND to a frame.
1647
1648taas COMMAND
1649 Apply a command to all threads (ignoring errors and empty output).
1650 Shortcut for 'thread apply all -s COMMAND'.
1651
1652faas COMMAND
1653 Apply a command to all frames (ignoring errors and empty output).
1654 Shortcut for 'frame apply all -s COMMAND'.
1655
1656tfaas COMMAND
1657 Apply a command to all frames of all threads (ignoring errors and empty
1658 output).
1659 Shortcut for 'thread apply all -s frame apply all -s COMMAND'.
1660
3c3bb058
AB
1661maint set dwarf unwinders (on|off)
1662maint show dwarf unwinders
1663 Control whether DWARF unwinders can be used.
1664
8b113111
JB
1665info proc files
1666 Display a list of open files for a process.
1667
a14c4daa
PW
1668* Changed commands
1669
669e09f6
PW
1670Changes to the "frame", "select-frame", and "info frame" CLI commands.
1671 These commands all now take a frame specification which
1672 is either a frame level, or one of the keywords 'level', 'address',
1673 'function', or 'view' followed by a parameter. Selecting a frame by
1674 address, or viewing a frame outside the current backtrace now
1675 requires the use of a keyword. Selecting a frame by level is
1676 unchanged. The MI comment "-stack-select-frame" is unchanged.
1677
c1168a2f
JD
1678target remote FILENAME
1679target extended-remote FILENAME
1680 If FILENAME is a Unix domain socket, GDB will attempt to connect
1681 to this socket instead of opening FILENAME as a character device.
1682
e0a7911f
PW
1683info args [-q] [-t TYPEREGEXP] [NAMEREGEXP]
1684info functions [-q] [-t TYPEREGEXP] [NAMEREGEXP]
1685info locals [-q] [-t TYPEREGEXP] [NAMEREGEXP]
1686info variables [-q] [-t TYPEREGEXP] [NAMEREGEXP]
1687 These commands can now print only the searched entities
1688 matching the provided regexp(s), giving a condition
1689 on the entity names or entity types. The flag -q disables
1690 printing headers or informations messages.
1691
604c4ca9
PW
1692info functions
1693info types
1694info variables
1695rbreak
1696 These commands now determine the syntax for the shown entities
1697 according to the language chosen by `set language'. In particular,
1698 `set language auto' means to automatically choose the language of
1699 the shown entities.
1700
a14c4daa
PW
1701thread apply [all | COUNT | -COUNT] [FLAG]... COMMAND
1702 The 'thread apply' command accepts new FLAG arguments.
1703 FLAG arguments allow to control what output to produce and how to handle
1704 errors raised when applying COMMAND to a thread.
1705
7806cea7
TT
1706set tui tab-width NCHARS
1707show tui tab-width NCHARS
1708 "set tui tab-width" replaces the "tabset" command, which has been deprecated.
1709
140a4bc0
TT
1710set style enabled [on|off]
1711show style enabled
1712 Enable or disable terminal styling. Styling is enabled by default
7557a514 1713 on most hosts, but disabled by default when in batch mode.
140a4bc0 1714
d085f989
TT
1715set style sources [on|off]
1716show style sources
1717 Enable or disable source code styling. Source code styling is
1718 enabled by default, but only takes effect if styling in general is
1719 enabled, and if GDB was linked with GNU Source Highlight.
1720
140a4bc0
TT
1721set style filename foreground COLOR
1722set style filename background COLOR
1723set style filename intensity VALUE
1724 Control the styling of file names.
1725
1726set style function foreground COLOR
1727set style function background COLOR
1728set style function intensity VALUE
1729 Control the styling of function names.
1730
1731set style variable foreground COLOR
1732set style variable background COLOR
1733set style variable intensity VALUE
1734 Control the styling of variable names.
1735
1736set style address foreground COLOR
1737set style address background COLOR
1738set style address intensity VALUE
1739 Control the styling of addresses.
1740
26fb3983
JV
1741* MI changes
1742
1743 ** The '-data-disassemble' MI command now accepts an '-a' option to
1744 disassemble the whole function surrounding the given program
1745 counter value or function name. Support for this feature can be
1746 verified by using the "-list-features" command, which should
1747 contain "data-disassemble-a-option".
1748
6d52907e
JV
1749 ** Command responses and notifications that include a frame now include
1750 the frame's architecture in a new "arch" attribute.
1751
52a187f8
JW
1752* New native configurations
1753
1754GNU/Linux/RISC-V riscv*-*-linux*
74792ff7 1755FreeBSD/riscv riscv*-*-freebsd*
52a187f8
JW
1756
1757* New targets
1758
1759GNU/Linux/RISC-V riscv*-*-linux*
416a69af
HAQ
1760CSKY ELF csky*-*-elf
1761CSKY GNU/LINUX csky*-*-linux
ed65e20b 1762FreeBSD/riscv riscv*-*-freebsd*
197df35e
JB
1763NXP S12Z s12z-*-elf
1764GNU/Linux/OpenRISC or1k*-*-linux*
52a187f8 1765
742a7df5
EZ
1766* Removed targets
1767
1768GDB no longer supports native debugging on versions of MS-Windows
1769before Windows XP.
1770
a40bf0c2
SM
1771* Python API
1772
2c3fc25d
KB
1773 ** GDB no longer supports Python versions less than 2.6.
1774
a40bf0c2
SM
1775 ** The gdb.Inferior type has a new 'progspace' property, which is the program
1776 space associated to that inferior.
1777
0ae1a321
SM
1778 ** The gdb.Progspace type has a new 'objfiles' method, which returns the list
1779 of objfiles associated to that program space.
1780
51e78fc5
TT
1781 ** gdb.SYMBOL_LOC_COMMON_BLOCK, gdb.SYMBOL_MODULE_DOMAIN, and
1782 gdb.SYMBOL_COMMON_BLOCK_DOMAIN were added to reflect changes to
1783 the gdb core.
1784
1785 ** gdb.SYMBOL_VARIABLES_DOMAIN, gdb.SYMBOL_FUNCTIONS_DOMAIN, and
1786 gdb.SYMBOL_TYPES_DOMAIN are now deprecated. These were never
1787 correct and did not work properly.
1788
af54ade9
KB
1789 ** The gdb.Value type has a new constructor, which is used to construct a
1790 gdb.Value from a Python buffer object and a gdb.Type.
1791
f35d5ade
TT
1792* Configure changes
1793
1794--enable-ubsan
1795
eff98030
TT
1796 Enable or disable the undefined behavior sanitizer. This is
1797 disabled by default, but passing --enable-ubsan=yes or
1798 --enable-ubsan=auto to configure will enable it. Enabling this can
1799 cause a performance penalty. The undefined behavior sanitizer was
1800 first introduced in GCC 4.9.
f35d5ade 1801
4e5b2f89 1802*** Changes in GDB 8.2
cd385f94 1803
471b9d15
MR
1804* The 'set disassembler-options' command now supports specifying options
1805 for the MIPS target.
1806
d4d429d5
PT
1807* The 'symbol-file' command now accepts an '-o' option to add a relative
1808 offset to all sections.
1809
291f9a96
PT
1810* Similarly, the 'add-symbol-file' command also accepts an '-o' option to add
1811 a relative offset to all sections, but it allows to override the load
1812 address of individual sections using '-s'.
1813
ed6dfe51
PT
1814* The 'add-symbol-file' command no longer requires the second argument
1815 (address of the text section).
1816
4b2dfa9d
MR
1817* The endianness used with the 'set endian auto' mode in the absence of
1818 an executable selected for debugging is now the last endianness chosen
1819 either by one of the 'set endian big' and 'set endian little' commands
1820 or by inferring from the last executable used, rather than the startup
1821 default.
1822
eb6af809
TT
1823* The pager now allows a "c" response, meaning to disable the pager
1824 for the rest of the current command.
1825
b744723f
AA
1826* The commands 'info variables/functions/types' now show the source line
1827 numbers of symbol definitions when available.
1828
2d97a5d9
JB
1829* 'info proc' now works on running processes on FreeBSD systems and core
1830 files created on FreeBSD systems.
1831
007e1530
TT
1832* C expressions can now use _Alignof, and C++ expressions can now use
1833 alignof.
1834
1461bdac
AH
1835* Support for SVE on AArch64 Linux. Note that GDB does not detect changes to
1836 the vector length while the process is running.
1837
386a8676
JB
1838* New commands
1839
1840set debug fbsd-nat
1841show debug fbsd-nat
1842 Control display of debugging info regarding the FreeBSD native target.
1843
3fcded8f
JB
1844set|show varsize-limit
1845 This new setting allows the user to control the maximum size of Ada
1846 objects being printed when those objects have a variable type,
1847 instead of that maximum size being hardcoded to 65536 bytes.
1848
4a4495d6
MM
1849set|show record btrace cpu
1850 Controls the processor to be used for enabling errata workarounds for
1851 branch trace decode.
1852
5045b3d7
GB
1853maint check libthread-db
1854 Run integrity checks on the current inferior's thread debugging
1855 library
1856
1857maint set check-libthread-db (on|off)
1858maint show check-libthread-db
1859 Control whether to run integrity checks on inferior specific thread
1860 debugging libraries as they are loaded. The default is not to
1861 perform such checks.
1862
6d7bb824
TT
1863* Python API
1864
1865 ** Type alignment is now exposed via the "align" attribute of a gdb.Type.
1866
a913fffb
TT
1867 ** The commands attached to a breakpoint can be set by assigning to
1868 the breakpoint's "commands" field.
1869
56bcdbea
TT
1870 ** gdb.execute can now execute multi-line gdb commands.
1871
7729052b
TT
1872 ** The new functions gdb.convenience_variable and
1873 gdb.set_convenience_variable can be used to get and set the value
1874 of convenience variables.
1875
984ee559
TT
1876 ** A gdb.Parameter will no longer print the "set" help text on an
1877 ordinary "set"; instead by default a "set" will be silent unless
1878 the get_set_string method returns a non-empty string.
1879
dbbb1059
AB
1880* New targets
1881
1882RiscV ELF riscv*-*-elf
1883
a2a79012
PA
1884* Removed targets and native configurations
1885
1886m88k running OpenBSD m88*-*-openbsd*
8a3de5e1
PA
1887SH-5/SH64 ELF sh64-*-elf*, SH-5/SH64 support in sh*
1888SH-5/SH64 running GNU/Linux SH-5/SH64 support in sh*-*-linux*
1889SH-5/SH64 running OpenBSD SH-5/SH64 support in sh*-*-openbsd*
a2a79012 1890
a3b60e45
JK
1891* Aarch64/Linux hardware watchpoints improvements
1892
1893 Hardware watchpoints on unaligned addresses are now properly
1894 supported when running Linux kernel 4.10 or higher: read and access
1895 watchpoints are no longer spuriously missed, and all watchpoints
1896 lengths between 1 and 8 bytes are supported. On older kernels,
1897 watchpoints set on unaligned addresses are no longer missed, with
1898 the tradeoff that there is a possibility of false hits being
1899 reported.
1900
056dec39 1901* Configure changes
44cee4fd
TT
1902
1903--enable-codesign=CERT
1904 This can be used to invoke "codesign -s CERT" after building gdb.
1905 This option is useful on macOS, where code signing is required for
1906 gdb to work properly.
1907
056dec39
TT
1908--disable-gdbcli has been removed
1909 This is now silently accepted, but does nothing.
1910
cd385f94 1911*** Changes in GDB 8.1
305d16a9 1912
cef0f868
SH
1913* GDB now supports dynamically creating arbitrary register groups specified
1914 in XML target descriptions. This allows for finer grain grouping of
1915 registers on systems with a large amount of registers.
1916
7c161838
SDJ
1917* The 'ptype' command now accepts a '/o' flag, which prints the
1918 offsets and sizes of fields in a struct, like the pahole(1) tool.
1919
97cbe998
SDJ
1920* New "--readnever" command line option instructs GDB to not read each
1921 symbol file's symbolic debug information. This makes startup faster
1922 but at the expense of not being able to perform symbolic debugging.
1923 This option is intended for use cases where symbolic debugging will
1924 not be used, e.g., when you only need to dump the debuggee's core.
1925
2400729e
UW
1926* GDB now uses the GNU MPFR library, if available, to emulate target
1927 floating-point arithmetic during expression evaluation when the target
1928 uses different floating-point formats than the host. At least version
1929 3.1 of GNU MPFR is required.
1930
289e23aa
AA
1931* GDB now supports access to the guarded-storage-control registers and the
1932 software-based guarded-storage broadcast control registers on IBM z14.
1933
0a2dde4a
SDJ
1934* On Unix systems, GDB now supports transmitting environment variables
1935 that are to be set or unset to GDBserver. These variables will
1936 affect the environment to be passed to the remote inferior.
1937
1938 To inform GDB of environment variables that are to be transmitted to
1939 GDBserver, use the "set environment" command. Only user set
1940 environment variables are sent to GDBserver.
1941
1942 To inform GDB of environment variables that are to be unset before
1943 the remote inferior is started by the GDBserver, use the "unset
1944 environment" command.
1945
d044bac8
PA
1946* Completion improvements
1947
1948 ** GDB can now complete function parameters in linespecs and
1949 explicit locations without quoting. When setting breakpoints,
1950 quoting around functions names to help with TAB-completion is
1951 generally no longer necessary. For example, this now completes
1952 correctly:
1953
1954 (gdb) b function(in[TAB]
1955 (gdb) b function(int)
1956
1957 Related, GDB is no longer confused with completing functions in
1958 C++ anonymous namespaces:
1959
1960 (gdb) b (anon[TAB]
1961 (gdb) b (anonymous namespace)::[TAB][TAB]
1962 (anonymous namespace)::a_function()
1963 (anonymous namespace)::b_function()
1964
1965 ** GDB now has much improved linespec and explicit locations TAB
1966 completion support, that better understands what you're
1967 completing and offers better suggestions. For example, GDB no
1968 longer offers data symbols as possible completions when you're
1969 setting a breakpoint.
1970
1971 ** GDB now TAB-completes label symbol names.
1972
1973 ** The "complete" command now mimics TAB completion accurately.
1974
c179febe
SL
1975* New command line options (gcore)
1976
1977-a
1978 Dump all memory mappings.
1979
a20714ff
PA
1980* Breakpoints on C++ functions are now set on all scopes by default
1981
1982 By default, breakpoints on functions/methods are now interpreted as
1983 specifying all functions with the given name ignoring missing
1984 leading scopes (namespaces and classes).
1985
1986 For example, assuming a C++ program with symbols named:
1987
1988 A::B::func()
1989 B::func()
1990
1991 both commands "break func()" and "break B::func()" set a breakpoint
1992 on both symbols.
1993
1994 You can use the new flag "-qualified" to override this. This makes
1995 GDB interpret the specified function name as a complete
1996 fully-qualified name instead. For example, using the same C++
1997 program, the "break -q B::func" command sets a breakpoint on
b89641ba
SM
1998 "B::func", only. A parameter has been added to the Python
1999 gdb.Breakpoint constructor to achieve the same result when creating
2000 a breakpoint from Python.
a20714ff 2001
bd69330d
PA
2002* Breakpoints on functions marked with C++ ABI tags
2003
2004 GDB can now set breakpoints on functions marked with C++ ABI tags
2005 (e.g., [abi:cxx11]). See here for a description of ABI tags:
2006 https://developers.redhat.com/blog/2015/02/05/gcc5-and-the-c11-abi/
2007
2008 Functions with a C++11 abi tag are demangled/displayed like this:
2009
2010 function[abi:cxx11](int)
2011 ^^^^^^^^^^^
2012
2013 You can now set a breakpoint on such functions simply as if they had
2014 no tag, like:
2015
2016 (gdb) b function(int)
2017
2018 Or if you need to disambiguate between tags, like:
2019
2020 (gdb) b function[abi:other_tag](int)
2021
2022 Tab completion was adjusted accordingly as well.
2023
7c96f8c1
TT
2024* Python Scripting
2025
2026 ** New events gdb.new_inferior, gdb.inferior_deleted, and
2027 gdb.new_thread are emitted. See the manual for further
2028 description of these.
2029
4e725347
JB
2030 ** A new function, "gdb.rbreak" has been added to the Python API.
2031 This function allows the setting of a large number of breakpoints
2032 via a regex pattern in Python. See the manual for further details.
d8ae99a7 2033
824cc835
PM
2034 ** Python breakpoints can now accept explicit locations. See the
2035 manual for a further description of this feature.
2036
2037
6d580b63
YQ
2038* New features in the GDB remote stub, GDBserver
2039
bc3b087d
SDJ
2040 ** GDBserver is now able to start inferior processes with a
2041 specified initial working directory.
2042
2043 The user can set the desired working directory to be used from
2044 GDB using the new "set cwd" command.
2045
6d580b63
YQ
2046 ** New "--selftest" command line option runs some GDBserver self
2047 tests. These self tests are disabled in releases.
2048
2049 ** On Unix systems, GDBserver now does globbing expansion and variable
2050 substitution in inferior command line arguments.
2051
2052 This is done by starting inferiors using a shell, like GDB does.
2053 See "set startup-with-shell" in the user manual for how to disable
2054 this from GDB when using "target extended-remote". When using
2055 "target remote", you can disable the startup with shell by using the
2056 new "--no-startup-with-shell" GDBserver command line option.
aefd8b33 2057
0a2dde4a
SDJ
2058 ** On Unix systems, GDBserver now supports receiving environment
2059 variables that are to be set or unset from GDB. These variables
2060 will affect the environment to be passed to the inferior.
2061
e547c119
JB
2062* When catching an Ada exception raised with a message, GDB now prints
2063 the message in the catchpoint hit notification. In GDB/MI mode, that
2064 information is provided as an extra field named "exception-message"
2065 in the *stopped notification.
2066
7403715e
TT
2067* Trait objects can now be inspected When debugging Rust code. This
2068 requires compiler support which will appear in Rust 1.24.
2069
aefd8b33
SDJ
2070* New remote packets
2071
0a2dde4a
SDJ
2072QEnvironmentHexEncoded
2073 Inform GDBserver of an environment variable that is to be passed to
2074 the inferior when starting it.
2075
2076QEnvironmentUnset
2077 Inform GDBserver of an environment variable that is to be unset
2078 before starting the remote inferior.
2079
2080QEnvironmentReset
2081 Inform GDBserver that the environment should be reset (i.e.,
2082 user-set environment variables should be unset).
2083
aefd8b33
SDJ
2084QStartupWithShell
2085 Indicates whether the inferior must be started with a shell or not.
2086
bc3b087d
SDJ
2087QSetWorkingDir
2088 Tell GDBserver that the inferior to be started should use a specific
2089 working directory.
2090
8e2141c6
YQ
2091* The "maintenance print c-tdesc" command now takes an optional
2092 argument which is the file name of XML target description.
2093
1526853e
SM
2094* The "maintenance selftest" command now takes an optional argument to
2095 filter the tests to be run.
2096
d0fe4701
XR
2097* The "enable", and "disable" commands now accept a range of
2098 breakpoint locations, e.g. "enable 1.3-5".
2099
c4dcb155
SM
2100* New commands
2101
d092c5a2
SDJ
2102set|show cwd
2103 Set and show the current working directory for the inferior.
2104
6e41ddec
JK
2105set|show compile-gcc
2106 Set and show compilation command used for compiling and injecting code
2107 with the 'compile' commands.
2108
c4dcb155
SM
2109set debug separate-debug-file
2110show debug separate-debug-file
2111 Control the display of debug output about separate debug file search.
2112
1e52e849
SL
2113set dump-excluded-mappings
2114show dump-excluded-mappings
2115 Control whether mappings marked with the VM_DONTDUMP flag should be
2116 dumped when generating a core file.
2117
1526853e
SM
2118maint info selftests
2119 List the registered selftests.
2120
4e5a4f58
JB
2121starti
2122 Start the debugged program stopping at the first instruction.
2123
b282f0f2
SH
2124set|show debug or1k
2125 Control display of debugging messages related to OpenRISC targets.
2126
883fd55a
KS
2127set|show print type nested-type-limit
2128 Set and show the limit of nesting level for nested types that the
2129 type printer will show.
2130
44d0fb3a
RK
2131* TUI Single-Key mode now supports two new shortcut keys: `i' for stepi and
2132 `o' for nexti.
2133
d69cf9b2
PA
2134* Safer/improved support for debugging with no debug info
2135
2136 GDB no longer assumes functions with no debug information return
2137 'int'.
2138
2139 This means that GDB now refuses to call such functions unless you
2140 tell it the function's type, by either casting the call to the
2141 declared return type, or by casting the function to a function
2142 pointer of the right type, and calling that:
2143
2144 (gdb) p getenv ("PATH")
2145 'getenv' has unknown return type; cast the call to its declared return type
2146 (gdb) p (char *) getenv ("PATH")
2147 $1 = 0x7fffffffe "/usr/local/bin:/"...
2148 (gdb) p ((char * (*) (const char *)) getenv) ("PATH")
2149 $2 = 0x7fffffffe "/usr/local/bin:/"...
2150
2151 Similarly, GDB no longer assumes that global variables with no debug
2152 info have type 'int', and refuses to print the variable's value
2153 unless you tell it the variable's type:
2154
2155 (gdb) p var
2156 'var' has unknown type; cast it to its declared type
2157 (gdb) p (float) var
2158 $3 = 3.14
2159
351787dd
JB
2160* New native configurations
2161
2162FreeBSD/aarch64 aarch64*-*-freebsd*
4f9d9906 2163FreeBSD/arm arm*-*-freebsd*
351787dd 2164
c0f84956
JB
2165* New targets
2166
2167FreeBSD/aarch64 aarch64*-*-freebsd*
7176dfd2 2168FreeBSD/arm arm*-*-freebsd*
b282f0f2 2169OpenRISC ELF or1k*-*-elf
c0f84956 2170
281c4447
RO
2171* Removed targets and native configurations
2172
2173Solaris 2.0-9 i?86-*-solaris2.[0-9], sparc*-*-solaris2.[0-9]
2174
305d16a9 2175*** Changes in GDB 8.0
51547df6
MS
2176
2177* GDB now supports access to the PKU register on GNU/Linux. The register is
2178 added by the Memory Protection Keys for Userspace feature which will be
2179 available in future Intel CPUs.
751b375e 2180
c0f55cc6
AV
2181* GDB now supports C++11 rvalue references.
2182
0a0faf9f
TW
2183* Python Scripting
2184
2185 ** New functions to start, stop and access a running btrace recording.
c0f55cc6 2186 ** Rvalue references are now supported in gdb.Type.
0a0faf9f 2187
20b477a7
LM
2188* GDB now supports recording and replaying rdrand and rdseed Intel 64
2189 instructions.
2190
e6485aaf 2191* Building GDB and GDBserver now requires a C++11 compiler.
d2946923
PA
2192
2193 For example, GCC 4.8 or later.
cf6de44d
PA
2194
2195 It is no longer possible to build GDB or GDBserver with a C
2196 compiler. The --disable-build-with-cxx configure option has been
2197 removed.
2198
f2ff9acd
SM
2199* Building GDB and GDBserver now requires GNU make >= 3.81.
2200
2201 It is no longer supported to build GDB or GDBserver with another
2202 implementation of the make program or an earlier version of GNU make.
2203
8ba42bc5
EZ
2204* Native debugging on MS-Windows supports command-line redirection
2205
2206 Command-line arguments used for starting programs on MS-Windows can
2207 now include redirection symbols supported by native Windows shells,
2208 such as '<', '>', '>>', '2>&1', etc. This affects GDB commands such
2209 as "run", "start", and "set args", as well as the corresponding MI
2210 features.
2211
24cdb46e
РИ
2212* Support for thread names on MS-Windows.
2213
2214 GDB now catches and handles the special exception that programs
2215 running on MS-Windows use to assign names to threads in the
2216 debugger.
2217
9c37b5ae
TT
2218* Support for Java programs compiled with gcj has been removed.
2219
df3ee9ca
PA
2220* User commands now accept an unlimited number of arguments.
2221 Previously, only up to 10 was accepted.
2222
01770bbd
PA
2223* The "eval" command now expands user-defined command arguments.
2224
2225 This makes it easier to process a variable number of arguments:
2226
2227 define mycommand
2228 set $i = 0
2229 while $i < $argc
2230 eval "print $arg%d", $i
2231 set $i = $i + 1
2232 end
2233 end
2234
3f7b46f2
IR
2235* Target descriptions can now describe registers for sparc32 and sparc64.
2236
0ae60b63
JK
2237* GDB now supports DWARF version 5 (debug information format).
2238 Its .debug_names index is not yet supported.
2239
b268007c
JB
2240* New native configurations
2241
2242FreeBSD/mips mips*-*-freebsd
2243
ad0a504f
AK
2244* New targets
2245
2246Synopsys ARC arc*-*-elf32
387360da 2247FreeBSD/mips mips*-*-freebsd
ad0a504f 2248
db6be0d5
SM
2249* Removed targets and native configurations
2250
2251Alpha running FreeBSD alpha*-*-freebsd*
2252Alpha running GNU/kFreeBSD alpha*-*-kfreebsd*-gnu
2253
78cbbba8
LM
2254* New commands
2255
2256flash-erase
2257 Erases all the flash memory regions reported by the target.
2258
db6be0d5
SM
2259maint print arc arc-instruction address
2260 Print internal disassembler information about instruction at a given address.
51457a05 2261
db6be0d5 2262* New options
65b48a81
PB
2263
2264set disassembler-options
2265show disassembler-options
2266 Controls the passing of target specific information to the disassembler.
2267 If it is necessary to specify more than one disassembler option then
2268 multiple options can be placed together into a comma separated list.
2269 The default value is the empty string. Currently, the only supported
2270 targets are ARM, PowerPC and S/390.
2271
db6be0d5 2272* New MI commands
eea78757 2273
db6be0d5
SM
2274-target-flash-erase
2275 Erases all the flash memory regions reported by the target. This is
2276 equivalent to the CLI command flash-erase.
1e1a8bef 2277
db6be0d5
SM
2278-file-list-shared-libraries
2279 List the shared libraries in the program. This is
2280 equivalent to the CLI command "info shared".
1e1a8bef 2281
bea298f9
XR
2282-catch-handlers
2283 Catchpoints stopping the program when Ada exceptions are
2284 handled. This is equivalent to the CLI command "catch handlers".
2285
751b375e 2286*** Changes in GDB 7.12
1233c0ba 2287
69ffd7f2
PA
2288* GDB and GDBserver now build with a C++ compiler by default.
2289
2290 The --enable-build-with-cxx configure option is now enabled by
2291 default. One must now explicitly configure with
2292 --disable-build-with-cxx in order to build with a C compiler. This
2293 option will be removed in a future release.
2294
c0272db5
TW
2295* GDBserver now supports recording btrace without maintaining an active
2296 GDB connection.
2297
bb556f1f
TK
2298* GDB now supports a negative repeat count in the 'x' command to examine
2299 memory backward from the given address. For example:
2300
2301 (gdb) bt
2302 #0 Func1 (n=42, p=0x40061c "hogehoge") at main.cpp:4
2303 #1 0x400580 in main (argc=1, argv=0x7fffffffe5c8) at main.cpp:8
2304 (gdb) x/-5i 0x0000000000400580
2305 0x40056a <main(int, char**)+8>: mov %edi,-0x4(%rbp)
2306 0x40056d <main(int, char**)+11>: mov %rsi,-0x10(%rbp)
2307 0x400571 <main(int, char**)+15>: mov $0x40061c,%esi
2308 0x400576 <main(int, char**)+20>: mov $0x2a,%edi
2309 0x40057b <main(int, char**)+25>:
2310 callq 0x400536 <Func1(int, char const*)>
2311
9920b434
BH
2312* Fortran: Support structures with fields of dynamic types and
2313 arrays of dynamic types.
2314
34c41c68
DE
2315* The symbol dumping maintenance commands have new syntax.
2316maint print symbols [-pc address] [--] [filename]
2317maint print symbols [-objfile objfile] [-source source] [--] [filename]
2318maint print psymbols [-objfile objfile] [-pc address] [--] [filename]
2319maint print psymbols [-objfile objfile] [-source source] [--] [filename]
2320maint print msymbols [-objfile objfile] [--] [filename]
2321
81516450
DE
2322* GDB now supports multibit bitfields and enums in target register
2323 descriptions.
2324
f2f3ccb9
SM
2325* New Python-based convenience function $_as_string(val), which returns
2326 the textual representation of a value. This function is especially
2327 useful to obtain the text label of an enum value.
2328
012b3a21
WT
2329* Intel MPX bound violation handling.
2330
2331 Segmentation faults caused by a Intel MPX boundary violation
2332 now display the kind of violation (upper or lower), the memory
2333 address accessed and the memory bounds, along with the usual
2334 signal received and code location.
2335
2336 For example:
2337
2338 Program received signal SIGSEGV, Segmentation fault
2339 Upper bound violation while accessing address 0x7fffffffc3b3
2340 Bounds: [lower = 0x7fffffffc390, upper = 0x7fffffffc3a3]
2341 0x0000000000400d7c in upper () at i386-mpx-sigsegv.c:68
2342
0bdfa368
TT
2343* Rust language support.
2344 GDB now supports debugging programs written in the Rust programming
2345 language. See https://www.rust-lang.org/ for more information about
2346 Rust.
2347
86f78169
PA
2348* Support for running interpreters on specified input/output devices
2349
2350 GDB now supports a new mechanism that allows frontends to provide
2351 fully featured GDB console views, as a better alternative to
2352 building such views on top of the "-interpreter-exec console"
2353 command. See the new "new-ui" command below. With that command,
2354 frontends can now start GDB in the traditional command-line mode
2355 running in an embedded terminal emulator widget, and create a
2356 separate MI interpreter running on a specified i/o device. In this
2357 way, GDB handles line editing, history, tab completion, etc. in the
2358 console all by itself, and the GUI uses the separate MI interpreter
2359 for its own control and synchronization, invisible to the command
2360 line.
2361
e3487908
GKB
2362* The "catch syscall" command catches groups of related syscalls.
2363
2364 The "catch syscall" command now supports catching a group of related
2365 syscalls using the 'group:' or 'g:' prefix.
2366
d2dffb8d
DE
2367* New commands
2368
2369skip -file file
2370skip -gfile file-glob-pattern
2371skip -function function
2372skip -rfunction regular-expression
2373 A generalized form of the skip command, with new support for
2374 glob-style file names and regular expressions for function names.
2375 Additionally, a file spec and a function spec may now be combined.
2376
f2403c39 2377maint info line-table REGEXP
82f06518 2378 Display the contents of GDB's internal line table data structure.
f2403c39 2379
dcd1f979
TT
2380maint selftest
2381 Run any GDB unit tests that were compiled in.
2382
86f78169
PA
2383new-ui INTERP TTY
2384 Start a new user interface instance running INTERP as interpreter,
2385 using the TTY file for input/output.
2386
93daf339
TT
2387* Python Scripting
2388
2389 ** gdb.Breakpoint objects have a new attribute "pending", which
2390 indicates whether the breakpoint is pending.
8d2a0a14
TT
2391 ** Three new breakpoint-related events have been added:
2392 gdb.breakpoint_created, gdb.breakpoint_modified, and
2393 gdb.breakpoint_deleted.
93daf339 2394
463888ab
РИ
2395signal-event EVENTID
2396 Signal ("set") the given MS-Windows event object. This is used in
2397 conjunction with the Windows JIT debugging (AeDebug) support, where
2398 the OS suspends a crashing process until a debugger can attach to
2399 it. Resuming the crashing process, in order to debug it, is done by
2400 signalling an event.
2401
c37c0ba6
MK
2402* Support for tracepoints and fast tracepoints on s390-linux and s390x-linux
2403 was added in GDBserver, including JIT compiling fast tracepoint's
2404 conditional expression bytecode into native code.
2405
f7c38292
PA
2406* Support for various remote target protocols and ROM monitors has
2407 been removed:
2408
2409 target m32rsdi Remote M32R debugging over SDI
2410 target mips MIPS remote debugging protocol
2411 target pmon PMON ROM monitor
2412 target ddb NEC's DDB variant of PMON for Vr4300
2413 target rockhopper NEC RockHopper variant of PMON
2414 target lsi LSI variant of PMO
2415
22084c42
MK
2416* Support for tracepoints and fast tracepoints on powerpc-linux,
2417 powerpc64-linux, and powerpc64le-linux was added in GDBserver,
2418 including JIT compiling fast tracepoint's conditional expression
2419 bytecode into native code.
2420
38b022b4
SM
2421* MI async record =record-started now includes the method and format used for
2422 recording. For example:
2423
2424 =record-started,thread-group="i1",method="btrace",format="bts"
2425
4034d0ff
AT
2426* MI async record =thread-selected now includes the frame field. For example:
2427
2428 =thread-selected,id="3",frame={level="0",addr="0x00000000004007c0"}
2429
a28d8e50
YTL
2430* New targets
2431
2432Andes NDS32 nds32*-*-elf
2433
1233c0ba 2434*** Changes in GDB 7.11
7c79d316 2435
6e9567fe
JB
2436* GDB now supports debugging kernel-based threads on FreeBSD.
2437
5d5658a1
PA
2438* Per-inferior thread numbers
2439
2440 Thread numbers are now per inferior instead of global. If you're
2441 debugging multiple inferiors, GDB displays thread IDs using a
2442 qualified INF_NUM.THR_NUM form. For example:
2443
2444 (gdb) info threads
2445 Id Target Id Frame
2446 1.1 Thread 0x7ffff7fc2740 (LWP 8155) (running)
2447 1.2 Thread 0x7ffff7fc1700 (LWP 8168) (running)
2448 * 2.1 Thread 0x7ffff7fc2740 (LWP 8157) (running)
2449 2.2 Thread 0x7ffff7fc1700 (LWP 8190) (running)
2450
2451 As consequence, thread numbers as visible in the $_thread
2452 convenience variable and in Python's InferiorThread.num attribute
2453 are no longer unique between inferiors.
2454
2455 GDB now maintains a second thread ID per thread, referred to as the
2456 global thread ID, which is the new equivalent of thread numbers in
663f6d42 2457 previous releases. See also $_gthread below.
5d5658a1
PA
2458
2459 For backwards compatibility, MI's thread IDs always refer to global
2460 IDs.
2461
2462* Commands that accept thread IDs now accept the qualified
2463 INF_NUM.THR_NUM form as well. For example:
2464
2465 (gdb) thread 2.1
2466 [Switching to thread 2.1 (Thread 0x7ffff7fc2740 (LWP 8157))] (running)
2467 (gdb)
2468
71ef29a8
PA
2469* In commands that accept a list of thread IDs, you can now refer to
2470 all threads of an inferior using a star wildcard. GDB accepts
2471 "INF_NUM.*", to refer to all threads of inferior INF_NUM, and "*" to
2472 refer to all threads of the current inferior. For example, "info
2473 threads 2.*".
2474
c84f6bbf
PA
2475* You can use "info threads -gid" to display the global thread ID of
2476 all threads.
2477
663f6d42
PA
2478* The new convenience variable $_gthread holds the global number of
2479 the current thread.
2480
e3940304
PA
2481* The new convenience variable $_inferior holds the number of the
2482 current inferior.
2483
f303dbd6
PA
2484* GDB now displays the ID and name of the thread that hit a breakpoint
2485 or received a signal, if your program is multi-threaded. For
2486 example:
2487
2488 Thread 3 "bar" hit Breakpoint 1 at 0x40087a: file program.c, line 20.
2489 Thread 1 "main" received signal SIGINT, Interrupt.
2490
cbb55fa7
MM
2491* Record btrace now supports non-stop mode.
2492
58d2eda5
PL
2493* Support for tracepoints on aarch64-linux was added in GDBserver.
2494
da8c46d2 2495* The 'record instruction-history' command now indicates speculative execution
bc504a31 2496 when using the Intel Processor Trace recording format.
da8c46d2 2497
629500fa
KS
2498* GDB now allows users to specify explicit locations, bypassing
2499 the linespec parser. This feature is also available to GDB/MI
2500 clients.
2501
02f024f9
YQ
2502* Multi-architecture debugging is supported on AArch64 GNU/Linux.
2503 GDB now is able to debug both AArch64 applications and ARM applications
2504 at the same time.
2505
4d9d419e
PL
2506* Support for fast tracepoints on aarch64-linux was added in GDBserver,
2507 including JIT compiling fast tracepoint's conditional expression bytecode
2508 into native code.
2509
eda14cf2
YQ
2510* GDB now supports displaced stepping on AArch64 GNU/Linux.
2511
be81798b
PA
2512* "info threads", "info inferiors", "info display", "info checkpoints"
2513 and "maint info program-spaces" now list the corresponding items in
2514 ascending ID order, for consistency with all other "info" commands.
2515
3685b09f
PMR
2516* In Ada, the overloads selection menu has been enhanced to display the
2517 parameter types and the return types for the matching overloaded subprograms.
2518
fbea99ea
PA
2519* New commands
2520
2521maint set target-non-stop (on|off|auto)
2522maint show target-non-stop
2523 Control whether GDB targets always operate in non-stop mode even if
2524 "set non-stop" is "off". The default is "auto", meaning non-stop
2525 mode is enabled if supported by the target.
2526
18989b3c
AB
2527maint set bfd-sharing
2528maint show bfd-sharing
2529 Control the reuse of bfd objects.
2530
566f5e3b
AB
2531set debug bfd-cache
2532show debug bfd-cache
2533 Control display of debugging info regarding bfd caching.
2534
6e9567fe
JB
2535set debug fbsd-lwp
2536show debug fbsd-lwp
2537 Control display of debugging info regarding FreeBSD threads.
2538
73b8c1fd
PA
2539set remote multiprocess-extensions-packet
2540show remote multiprocess-extensions-packet
2541 Set/show the use of the remote protocol multiprocess extensions.
2542
65706a29
PA
2543set remote thread-events
2544show remote thread-events
2545 Set/show the use of thread create/exit events.
2546
3685b09f
PMR
2547set ada print-signatures on|off
2548show ada print-signatures"
2549 Control whether parameter types and return types are displayed in overloads
82f06518 2550 selection menus. It is activated (@code{on}) by default.
3685b09f 2551
5fdf6324
AB
2552set max-value-size
2553show max-value-size
2554 Controls the maximum size of memory, in bytes, that GDB will
2555 allocate for value contents. Prevents incorrect programs from
2556 causing GDB to allocate overly large buffers. Default is 64k.
2557
6ff0ba5f
DE
2558* The "disassemble" command accepts a new modifier: /s.
2559 It prints mixed source+disassembly like /m with two differences:
2560 - disassembled instructions are now printed in program order, and
2561 - and source for all relevant files is now printed.
2562 The "/m" option is now considered deprecated: its "source-centric"
2563 output hasn't proved useful in practice.
2564
0c532a29
MM
2565* The "record instruction-history" command accepts a new modifier: /s.
2566 It behaves exactly like /m and prints mixed source+disassembly.
2567
f2665db5
MM
2568* The "set scheduler-locking" command supports a new mode "replay".
2569 It behaves like "off" in record mode and like "on" in replay mode.
2570
40e0b271
PA
2571* Support for various ROM monitors has been removed:
2572
2573 target dbug dBUG ROM monitor for Motorola ColdFire
2574 target picobug Motorola picobug monitor
2575 target dink32 DINK32 ROM monitor for PowerPC
2576 target m32r Renesas M32R/D ROM monitor
2577 target mon2000 mon2000 ROM monitor
2578 target ppcbug PPCBUG ROM monitor for PowerPC
2579
fd2ae5d6 2580* Support for reading/writing memory and extracting values on architectures
d63dd61e 2581 whose memory is addressable in units of any integral multiple of 8 bits.
fd2ae5d6 2582
9f757bf7
XR
2583catch handlers
2584 Allows to break when an Ada exception is handled.
2585
b459a59b
DB
2586* New remote packets
2587
2588exec stop reason
2589 Indicates that an exec system call was executed.
2590
2591exec-events feature in qSupported
2592 The qSupported packet allows GDB to request support for exec
2593 events using the new 'gdbfeature' exec-event, and the qSupported
2594 response can contain the corresponding 'stubfeature'. Set and
2595 show commands can be used to display whether these features are enabled.
2596
de979965
PA
2597vCtrlC
2598 Equivalent to interrupting with the ^C character, but works in
2599 non-stop mode.
2600
65706a29
PA
2601thread created stop reason (T05 create:...)
2602 Indicates that the thread was just created and is stopped at entry.
2603
2604thread exit stop reply (w exitcode;tid)
2605 Indicates that the thread has terminated.
2606
2607QThreadEvents
2608 Enables/disables thread create and exit event reporting. For
2609 example, this is used in non-stop mode when GDB stops a set of
2610 threads and synchronously waits for the their corresponding stop
2611 replies. Without exit events, if one of the threads exits, GDB
2612 would hang forever not knowing that it should no longer expect a
2613 stop for that same thread.
2614
f2faf941 2615N stop reply
f2faf941
PA
2616 Indicates that there are no resumed threads left in the target (all
2617 threads are stopped). The remote stub reports support for this stop
2618 reply to GDB's qSupported query.
2619
aab3c527
JK
2620QCatchSyscalls
2621 Enables/disables catching syscalls from the inferior process.
2622 The remote stub reports support for this packet to GDB's qSupported query.
82075af2
JS
2623
2624syscall_entry stop reason
2625 Indicates that a syscall was just called.
2626
2627syscall_return stop reason
2628 Indicates that a syscall just returned.
2629
b459a59b
DB
2630* Extended-remote exec events
2631
2632 ** GDB now has support for exec events on extended-remote Linux targets.
2633 For such targets with Linux kernels 2.5.46 and later, this enables
2634 follow-exec-mode and exec catchpoints.
2635
2636set remote exec-event-feature-packet
2637show remote exec-event-feature-packet
2638 Set/show the use of the remote exec event feature.
2639
79efa585
SM
2640 * Thread names in remote protocol
2641
2642 The reply to qXfer:threads:read may now include a name attribute for each
2643 thread.
2644
19d9d4ef
DB
2645* Target remote mode fork and exec events
2646
2647 ** GDB now has support for fork and exec events on target remote mode
2648 Linux targets. For such targets with Linux kernels 2.5.46 and later,
2649 this enables follow-fork-mode, detach-on-fork, follow-exec-mode, and
2650 fork and exec catchpoints.
2651
82075af2
JS
2652* Remote syscall events
2653
2654 ** GDB now has support for catch syscall on remote Linux targets,
2655 currently enabled on x86/x86_64 architectures.
2656
2657set remote catch-syscall-packet
2658show remote catch-syscall-packet
2659 Set/show the use of the remote catch syscall feature.
2660
1c35a88f
LM
2661* MI changes
2662
2663 ** The -var-set-format command now accepts the zero-hexadecimal
2664 format. It outputs data in hexadecimal format with zero-padding on the
2665 left.
2666
84654457
PA
2667* Python Scripting
2668
22a02324
PA
2669 ** gdb.InferiorThread objects have a new attribute "global_num",
2670 which refers to the thread's global thread ID. The existing
2671 "num" attribute now refers to the thread's per-inferior number.
2672 See "Per-inferior thread numbers" above.
84654457
PA
2673 ** gdb.InferiorThread objects have a new attribute "inferior", which
2674 is the Inferior object the thread belongs to.
2675
7c79d316 2676*** Changes in GDB 7.10
df8411da 2677
c16a3f52
OJ
2678* Support for process record-replay and reverse debugging on aarch64*-linux*
2679 targets has been added. GDB now supports recording of A64 instruction set
2680 including advance SIMD instructions.
2681
18a94d75
DE
2682* Support for Sun's version of the "stabs" debug file format has been removed.
2683
df8411da
SDJ
2684* GDB now honors the content of the file /proc/PID/coredump_filter
2685 (PID is the process ID) on GNU/Linux systems. This file can be used
2686 to specify the types of memory mappings that will be included in a
2687 corefile. For more information, please refer to the manual page of
2688 "core(5)". GDB also has a new command: "set use-coredump-filter
2689 on|off". It allows to set whether GDB will read the content of the
2690 /proc/PID/coredump_filter file when generating a corefile.
3b2f13ff 2691
d33279b3
AT
2692* The "info os" command on GNU/Linux can now display information on
2693 cpu information :
2694 "info os cpus" Listing of all cpus/cores on the system
2695
236af5e3
YG
2696* GDB has two new commands: "set serial parity odd|even|none" and
2697 "show serial parity". These allows to set or show parity for the
2698 remote serial I/O.
2699
b6577aab
DE
2700* The "info source" command now displays the producer string if it was
2701 present in the debug info. This typically includes the compiler version
2702 and may include things like its command line arguments.
2703
b30a0bc3
JB
2704* The "info dll", an alias of the "info sharedlibrary" command,
2705 is now available on all platforms.
2706
599bd15c
GB
2707* Directory names supplied to the "set sysroot" commands may be
2708 prefixed with "target:" to tell GDB to access shared libraries from
2709 the target system, be it local or remote. This replaces the prefix
2710 "remote:". The default sysroot has been changed from "" to
2711 "target:". "remote:" is automatically converted to "target:" for
2712 backward compatibility.
2713
a9a5a3d1
GB
2714* The system root specified by "set sysroot" will be prepended to the
2715 filename of the main executable (if reported to GDB as absolute by
2716 the operating system) when starting processes remotely, and when
2717 attaching to already-running local or remote processes.
2718
1b6e6f5c
GB
2719* GDB now supports automatic location and retrieval of executable
2720 files from remote targets. Remote debugging can now be initiated
2721 using only a "target remote" or "target extended-remote" command
2722 (no "set sysroot" or "file" commands are required). See "New remote
2723 packets" below.
2724
cf75d6c3
AB
2725* The "dump" command now supports verilog hex format.
2726
417c80f9
AA
2727* GDB now supports the vector ABI on S/390 GNU/Linux targets.
2728
51aad7cc
GB
2729* On GNU/Linux, GDB and gdbserver are now able to access executable
2730 and shared library files without a "set sysroot" command when
2731 attaching to processes running in different mount namespaces from
2732 the debugger. This makes it possible to attach to processes in
2733 containers as simply as "gdb -p PID" or "gdbserver --attach PID".
2734 See "New remote packets" below.
2735
51f0e40d
AB
2736* The "tui reg" command now provides completion for all of the
2737 available register groups, including target specific groups.
2738
b58c513b
PP
2739* The HISTSIZE environment variable is no longer read when determining
2740 the size of GDB's command history. GDB now instead reads the dedicated
bc460514
PP
2741 GDBHISTSIZE environment variable. Setting GDBHISTSIZE to "-1" or to "" now
2742 disables truncation of command history. Non-numeric values of GDBHISTSIZE
2743 are ignored.
b58c513b 2744
37442ce1
DE
2745* Guile Scripting
2746
2747 ** Memory ports can now be unbuffered.
2748
3a8b707a
DE
2749* Python Scripting
2750
2751 ** gdb.Objfile objects have a new attribute "username",
2752 which is the name of the objfile as specified by the user,
2753 without, for example, resolving symlinks.
d11916aa 2754 ** You can now write frame unwinders in Python.
59fb7612
SS
2755 ** gdb.Type objects have a new method "optimized_out",
2756 returning optimized out gdb.Value instance of this type.
4c082a81
SC
2757 ** gdb.Value objects have new methods "reference_value" and
2758 "const_value" which return a reference to the value and a
2759 "const" version of the value respectively.
3a8b707a 2760
f57d2163
DE
2761* New commands
2762
2763maint print symbol-cache
2764 Print the contents of the symbol cache.
2765
2766maint print symbol-cache-statistics
2767 Print statistics of symbol cache usage.
2768
2769maint flush-symbol-cache
2770 Flush the contents of the symbol cache.
2771
f4abbc16
MM
2772record btrace bts
2773record bts
2774 Start branch trace recording using Branch Trace Store (BTS) format.
2775
36de76f9
JK
2776compile print
2777 Evaluate expression by using the compiler and print result.
2778
a4ea0946
AB
2779tui enable
2780tui disable
2781 Explicit commands for enabling and disabling tui mode.
2782
29c1c244
WT
2783show mpx bound
2784set mpx bound on i386 and amd64
bc504a31 2785 Support for bound table investigation on Intel MPX enabled applications.
29c1c244 2786
b20a6524
MM
2787record btrace pt
2788record pt
bc504a31 2789 Start branch trace recording using Intel Processor Trace format.
b20a6524 2790
b0627500
MM
2791maint info btrace
2792 Print information about branch tracing internals.
2793
2794maint btrace packet-history
2795 Print the raw branch tracing data.
2796
2797maint btrace clear-packet-history
2798 Discard the stored raw branch tracing data.
2799
2800maint btrace clear
2801 Discard all branch tracing data. It will be fetched and processed
2802 anew by the next "record" command.
2803
253828f1
JK
2804* New options
2805
b4f54984
DE
2806set debug dwarf-die
2807 Renamed from "set debug dwarf2-die".
2808show debug dwarf-die
2809 Renamed from "show debug dwarf2-die".
2810
2811set debug dwarf-read
2812 Renamed from "set debug dwarf2-read".
2813show debug dwarf-read
2814 Renamed from "show debug dwarf2-read".
2815
2816maint set dwarf always-disassemble
2817 Renamed from "maint set dwarf2 always-disassemble".
2818maint show dwarf always-disassemble
2819 Renamed from "maint show dwarf2 always-disassemble".
2820
2821maint set dwarf max-cache-age
2822 Renamed from "maint set dwarf2 max-cache-age".
2823maint show dwarf max-cache-age
2824 Renamed from "maint show dwarf2 max-cache-age".
2825
27e0867f
DE
2826set debug dwarf-line
2827show debug dwarf-line
2828 Control display of debugging info regarding DWARF line processing.
2829
ef0b411a
GB
2830set max-completions
2831show max-completions
2832 Set the maximum number of candidates to be considered during
2833 completion. The default value is 200. This limit allows GDB
2834 to avoid generating large completion lists, the computation of
2835 which can cause the debugger to become temporarily unresponsive.
2836
fc637f04
PP
2837set history remove-duplicates
2838show history remove-duplicates
2839 Control the removal of duplicate history entries.
2840
f57d2163
DE
2841maint set symbol-cache-size
2842maint show symbol-cache-size
2843 Control the size of the symbol cache.
2844
d33501a5
MM
2845set|show record btrace bts buffer-size
2846 Set and show the size of the ring buffer used for branch tracing in
2847 BTS format.
2848 The obtained size may differ from the requested size. Use "info
2849 record" to see the obtained buffer size.
2850
7a6a1731
GB
2851set debug linux-namespaces
2852show debug linux-namespaces
2853 Control display of debugging info regarding Linux namespaces.
2854
b20a6524
MM
2855set|show record btrace pt buffer-size
2856 Set and show the size of the ring buffer used for branch tracing in
bc504a31 2857 Intel Processor Trace format.
b20a6524
MM
2858 The obtained size may differ from the requested size. Use "info
2859 record" to see the obtained buffer size.
2860
b0627500
MM
2861maint set|show btrace pt skip-pad
2862 Set and show whether PAD packets are skipped when computing the
2863 packet history.
2864
253828f1
JK
2865* The command 'thread apply all' can now support new option '-ascending'
2866 to call its specified command for all threads in ascending order.
2867
9f050062
DE
2868* Python/Guile scripting
2869
2870 ** GDB now supports auto-loading of Python/Guile scripts contained in the
2871 special section named `.debug_gdb_scripts'.
2872
f4abbc16
MM
2873* New remote packets
2874
2875qXfer:btrace-conf:read
2876 Return the branch trace configuration for the current thread.
2877
d33501a5
MM
2878Qbtrace-conf:bts:size
2879 Set the requested ring buffer size for branch tracing in BTS format.
2880
b20a6524 2881Qbtrace:pt
82f06518 2882 Enable Intel Processor Trace-based branch tracing for the current
b20a6524
MM
2883 process. The remote stub reports support for this packet to GDB's
2884 qSupported query.
2885
2886Qbtrace-conf:pt:size
bc504a31 2887 Set the requested ring buffer size for branch tracing in Intel Processor
b20a6524
MM
2888 Trace format.
2889
f7e6eed5
PA
2890swbreak stop reason
2891 Indicates a memory breakpoint instruction was executed, irrespective
2892 of whether it was GDB that planted the breakpoint or the breakpoint
2893 is hardcoded in the program. This is required for correct non-stop
2894 mode operation.
2895
2896hwbreak stop reason
2897 Indicates the target stopped for a hardware breakpoint. This is
2898 required for correct non-stop mode operation.
2899
0a93529c
GB
2900vFile:fstat:
2901 Return information about files on the remote system.
2902
c78fa86a
GB
2903qXfer:exec-file:read
2904 Return the full absolute name of the file that was executed to
2905 create a process running on the remote system.
2906
15a201c8
GB
2907vFile:setfs:
2908 Select the filesystem on which vFile: operations with filename
2909 arguments will operate. This is required for GDB to be able to
2910 access files on remote targets where the remote stub does not
2911 share a common filesystem with the inferior(s).
2912
0d71eef5
DB
2913fork stop reason
2914 Indicates that a fork system call was executed.
2915
2916vfork stop reason
2917 Indicates that a vfork system call was executed.
2918
2919vforkdone stop reason
2920 Indicates that a vfork child of the specified process has executed
2921 an exec or exit, allowing the vfork parent to resume execution.
2922
2923fork-events and vfork-events features in qSupported
2924 The qSupported packet allows GDB to request support for fork and
2925 vfork events using new 'gdbfeatures' fork-events and vfork-events,
2926 and the qSupported response can contain the corresponding
2927 'stubfeatures'. Set and show commands can be used to display
2928 whether these features are enabled.
2929
2930* Extended-remote fork events
2931
2932 ** GDB now has support for fork events on extended-remote Linux
2933 targets. For targets with Linux kernels 2.5.60 and later, this
2934 enables follow-fork-mode and detach-on-fork for both fork and
2935 vfork, as well as fork and vfork catchpoints.
2936
d33501a5
MM
2937* The info record command now shows the recording format and the
2938 branch tracing configuration for the current thread when using
2939 the btrace record target.
2940 For the BTS format, it shows the ring buffer size.
2941
b05e3b0d
JM
2942* GDB now has support for DTrace USDT (Userland Static Defined
2943 Tracing) probes. The supported targets are x86_64-*-linux-gnu.
2944
550bdf96
AA
2945* GDB now supports access to vector registers on S/390 GNU/Linux
2946 targets.
2947
4f45d445
JK
2948* Removed command line options
2949
2950-xdb HP-UX XDB compatibility mode.
2951
0800b440
JK
2952* Removed targets and native configurations
2953
2954HP/PA running HP-UX hppa*-*-hpux*
2955Itanium running HP-UX ia64-*-hpux*
2956
58bfce93
MM
2957* New configure options
2958
2959--with-intel-pt
2960 This configure option allows the user to build GDB with support for
bc504a31 2961 Intel Processor Trace (default: auto). This requires libipt.
58bfce93
MM
2962
2963--with-libipt-prefix=PATH
2964 Specify the path to the version of libipt that GDB should use.
2965 $PATH/include should contain the intel-pt.h header and
2966 $PATH/lib should contain the libipt.so library.
2967
f5f85ab9
JB
2968*** Changes in GDB 7.9.1
2969
2970* Python Scripting
2971
2972 ** Xmethods can now specify a result type.
2973
3b2f13ff 2974*** Changes in GDB 7.9
919b9a93 2975
05db5edd
ST
2976* GDB now supports hardware watchpoints on x86 GNU Hurd.
2977
5f3b99cf 2978* Python Scripting
2b4fd423
DE
2979
2980 ** You can now access frame registers from Python scripts.
2981 ** New attribute 'producer' for gdb.Symtab objects.
d096d8c1
DE
2982 ** gdb.Objfile objects have a new attribute "progspace",
2983 which is the gdb.Progspace object of the containing program space.
a0be3e44 2984 ** gdb.Objfile objects have a new attribute "owner".
7c50a931
DE
2985 ** gdb.Objfile objects have a new attribute "build_id",
2986 which is the build ID generated when the file was built.
86e4ed39 2987 ** gdb.Objfile objects have a new method "add_separate_debug_file".
4ffbba72
DE
2988 ** A new event "gdb.clear_objfiles" has been added, triggered when
2989 selecting a new file to debug.
02be9a71 2990 ** You can now add attributes to gdb.Objfile and gdb.Progspace objects.
6dddd6a5 2991 ** New function gdb.lookup_objfile.
5f3b99cf 2992
8fda9068
YQ
2993 New events which are triggered when GDB modifies the state of the
2994 inferior.
2995
2996 ** gdb.events.inferior_call_pre: Function call is about to be made.
2997 ** gdb.events.inferior_call_post: Function call has just been made.
2998 ** gdb.events.memory_changed: A memory location has been altered.
2999 ** gdb.events.register_changed: A register has been altered.
3000
faa42425
DE
3001* New Python-based convenience functions:
3002
3003 ** $_caller_is(name [, number_of_frames])
3004 ** $_caller_matches(regexp [, number_of_frames])
3005 ** $_any_caller_is(name [, number_of_frames])
3006 ** $_any_caller_matches(regexp [, number_of_frames])
3007
bb2ec1b3
TT
3008* GDB now supports the compilation and injection of source code into
3009 the inferior. GDB will use GCC 5.0 or higher built with libcc1.so
3010 to compile the source code to object code, and if successful, inject
3011 and execute that code within the current context of the inferior.
3012 Currently the C language is supported. The commands used to
3013 interface with this new feature are:
3014
3015 compile code [-raw|-r] [--] [source code]
3016 compile file [-raw|-r] filename
3017
81219e53
DE
3018* New commands
3019
439250fb
DE
3020demangle [-l language] [--] name
3021 Demangle "name" in the specified language, or the current language
3022 if elided. This command is renamed from the "maint demangle" command.
3023 The latter is kept as a no-op to avoid "maint demangle" being interpreted
3024 as "maint demangler-warning".
3025
81219e53
DE
3026queue-signal signal-name-or-number
3027 Queue a signal to be delivered to the thread when it is resumed.
3028
f10c5b19
JK
3029add-auto-load-scripts-directory directory
3030 Add entries to the list of directories from which to load auto-loaded
3031 scripts.
3032
f5b95c01
AA
3033maint print user-registers
3034 List all currently available "user" registers.
3035
bb2ec1b3
TT
3036compile code [-r|-raw] [--] [source code]
3037 Compile, inject, and execute in the inferior the executable object
3038 code produced by compiling the provided source code.
3039
3040compile file [-r|-raw] filename
3041 Compile and inject into the inferior the executable object code
3042 produced by compiling the source code stored in the filename
3043 provided.
3044
70509625
PA
3045* On resume, GDB now always passes the signal the program had stopped
3046 for to the thread the signal was sent to, even if the user changed
3047 threads before resuming. Previously GDB would often (but not
3048 always) deliver the signal to the thread that happens to be current
3049 at resume time.
3050
3051* Conversely, the "signal" command now consistently delivers the
3052 requested signal to the current thread. GDB now asks for
3053 confirmation if the program had stopped for a signal and the user
3054 switched threads meanwhile.
3055
a25a5a45
PA
3056* "breakpoint always-inserted" modes "off" and "auto" merged.
3057
3058 Now, when 'breakpoint always-inserted mode' is set to "off", GDB
3059 won't remove breakpoints from the target until all threads stop,
3060 even in non-stop mode. The "auto" mode has been removed, and "off"
3061 is now the default mode.
3062
cc485e62
DE
3063* New options
3064
3065set debug symbol-lookup
3066show debug symbol-lookup
3067 Control display of debugging info regarding symbol lookup.
3068
2ddf4301
SM
3069* MI changes
3070
3071 ** The -list-thread-groups command outputs an exit-code field for
3072 inferiors that have exited.
3073
bb7e3f4d
YQ
3074* New targets
3075
3076MIPS SDE mips*-sde*-elf*
3077
3831839c
PA
3078* Removed targets
3079
3080Support for these obsolete configurations has been removed.
3081
5ab806de
PA
3082Alpha running OSF/1 (or Tru64) alpha*-*-osf*
3083SGI Irix-5.x mips-*-irix5*
3084SGI Irix-6.x mips-*-irix6*
09dd9a69
PA
3085VAX running (4.2 - 4.3 Reno) BSD vax-*-bsd*
3086VAX running Ultrix vax-*-ultrix*
3831839c 3087
6bf6fd09
JB
3088* The "dll-symbols" command, and its two aliases ("add-shared-symbol-files"
3089 and "assf"), have been removed. Use the "sharedlibrary" command, or
3090 its alias "share", instead.
3091
919b9a93 3092*** Changes in GDB 7.8
e9475ead 3093
8d551b02
DE
3094* New command line options
3095
3096-D data-directory
3097 This is an alias for the --data-directory option.
3098
e9475ead
SA
3099* GDB supports printing and modifying of variable length automatic arrays
3100 as specified in ISO C99.
3101
a75fef0e
NC
3102* The ARM simulator now supports instruction level tracing
3103 with or without disassembly.
b7bba001 3104
ed3ef339
DE
3105* Guile scripting
3106
3107 GDB now has support for scripting using Guile. Whether this is
3108 available is determined at configure time.
3109 Guile version 2.0 or greater is required.
3110 Guile version 2.0.9 is well tested, earlier 2.0 versions are not.
3111
3112* New commands (for set/show, see "New options" below)
3113
3114guile [code]
3115gu [code]
3116 Invoke CODE by passing it to the Guile interpreter.
3117
3118guile-repl
3119gr
3120 Start a Guile interactive prompt (or "repl" for "read-eval-print loop").
3121
3122info auto-load guile-scripts [regexp]
3123 Print the list of automatically loaded Guile scripts.
3124
3125* The source command is now capable of sourcing Guile scripts.
3126 This feature is dependent on the debugger being built with Guile support.
3127
c6044dd1
JB
3128* New options
3129
770e7fc7
DE
3130set print symbol-loading (off|brief|full)
3131show print symbol-loading
3132 Control whether to print informational messages when loading symbol
3133 information for a file. The default is "full", but when debugging
3134 programs with large numbers of shared libraries the amount of output
3135 becomes less useful.
3136
ed3ef339
DE
3137set guile print-stack (none|message|full)
3138show guile print-stack
3139 Show a stack trace when an error is encountered in a Guile script.
3140
3141set auto-load guile-scripts (on|off)
3142show auto-load guile-scripts
3143 Control auto-loading of Guile script files.
3144
c6044dd1
JB
3145maint ada set ignore-descriptive-types (on|off)
3146maint ada show ignore-descriptive-types
3147 Control whether the debugger should ignore descriptive types in Ada
3148 programs. The default is not to ignore the descriptive types. See
3149 the user manual for more details on descriptive types and the intended
3150 usage of this option.
3151
6a3cb8e8
PA
3152set auto-connect-native-target
3153
3154 Control whether GDB is allowed to automatically connect to the
3155 native target for the run, attach, etc. commands when not connected
3156 to any target yet. See also "target native" below.
3157
67b5c0c1
MM
3158set record btrace replay-memory-access (read-only|read-write)
3159show record btrace replay-memory-access
3160 Control what memory accesses are allowed during replay.
3161
329ea579
PA
3162maint set target-async (on|off)
3163maint show target-async
5784b3ca
JK
3164 This controls whether GDB targets operate in synchronous or
3165 asynchronous mode. Normally the default is asynchronous, if it is
329ea579 3166 available; but this can be changed to more easily debug problems
5784b3ca 3167 occurring only in synchronous mode.
329ea579
PA
3168
3169set mi-async (on|off)
3170show mi-async
3171 Control whether MI asynchronous mode is preferred. This supersedes
3172 "set target-async" of previous GDB versions.
3173
3174* "set target-async" is deprecated as a CLI option and is now an alias
3175 for "set mi-async" (only puts MI into async mode).
3176
3177* Background execution commands (e.g., "c&", "s&", etc.) are now
3178 possible ``out of the box'' if the target supports them. Previously
3179 the user would need to explicitly enable the possibility with the
3180 "set target-async on" command.
3181
87ce2a04
DE
3182* New features in the GDB remote stub, GDBserver
3183
3184 ** New option --debug-format=option1[,option2,...] allows one to add
3185 additional text to each output. At present only timestamps
3186 are supported: --debug-format=timestamps.
3187 Timestamps can also be turned on with the
3188 "monitor set debug-format timestamps" command from GDB.
3189
5de9129b
MM
3190* The 'record instruction-history' command now starts counting instructions
3191 at one. This also affects the instruction ranges reported by the
3192 'record function-call-history' command when given the /i modifier.
3193
8710b709
MM
3194* The command 'record function-call-history' supports a new modifier '/c' to
3195 indent the function names based on their call stack depth.
3196 The fields for the '/i' and '/l' modifier have been reordered.
3197 The source line range is now prefixed with 'at'.
3198 The instruction range is now prefixed with 'inst'.
3199 Both ranges are now printed as '<from>, <to>' to allow copy&paste to the
3200 "record instruction-history" and "list" commands.
3201
0688d04e
MM
3202* The ranges given as arguments to the 'record function-call-history' and
3203 'record instruction-history' commands are now inclusive.
3204
066ce621 3205* The btrace record target now supports the 'record goto' command.
0b722aec
MM
3206 For locations inside the execution trace, the back trace is computed
3207 based on the information stored in the execution trace.
066ce621 3208
52834460
MM
3209* The btrace record target supports limited reverse execution and replay.
3210 The target does not record data and therefore does not allow reading
3211 memory or registers.
3212
237b092b
AA
3213* The "catch syscall" command now works on s390*-linux* targets.
3214
936d2992
PA
3215* The "compare-sections" command is no longer specific to target
3216 remote. It now works with all targets.
3217
930ee1b1
PA
3218* All native targets are now consistently called "native".
3219 Consequently, the "target child", "target GNU", "target djgpp",
3220 "target procfs" (Solaris/Irix/OSF/AIX) and "target darwin-child"
3221 commands have been replaced with "target native". The QNX/NTO port
3222 leaves the "procfs" target in place and adds a "native" target for
3223 consistency with other ports. The impact on users should be minimal
3224 as these commands previously either throwed an error, or were
3225 no-ops. The target's name is visible in the output of the following
3226 commands: "help target", "info target", "info files", "maint print
3227 target-stack".
3228
6a3cb8e8
PA
3229* The "target native" command now connects to the native target. This
3230 can be used to launch native programs even when "set
3231 auto-connect-native-target" is set to off.
3232
bc504a31 3233* GDB now supports access to Intel MPX registers on GNU/Linux.
dc304a94 3234
bc504a31
PA
3235* Support for Intel AVX-512 registers on GNU/Linux.
3236 Support displaying and modifying Intel AVX-512 registers
dc304a94
JK
3237 $zmm0 - $zmm31 and $k0 - $k7 on GNU/Linux.
3238
969c39fb
MM
3239* New remote packets
3240
3241qXfer:btrace:read's annex
3242 The qXfer:btrace:read packet supports a new annex 'delta' to read
3243 branch trace incrementally.
3244
f7bd0f78
SC
3245* Python Scripting
3246
3247 ** Valid Python operations on gdb.Value objects representing
3248 structs/classes invoke the corresponding overloaded operators if
3249 available.
0c6e92a5
SC
3250 ** New `Xmethods' feature in the Python API. Xmethods are
3251 additional methods or replacements for existing methods of a C++
3252 class. This feature is useful for those cases where a method
3253 defined in C++ source code could be inlined or optimized out by
3254 the compiler, making it unavailable to GDB.
f7bd0f78 3255
36c24d95
UW
3256* New targets
3257PowerPC64 GNU/Linux little-endian powerpc64le-*-linux*
3258
95060284
JB
3259* The "dll-symbols" command, and its two aliases ("add-shared-symbol-files"
3260 and "assf"), have been deprecated. Use the "sharedlibrary" command, or
3261 its alias "share", instead.
3262
7f3c0343
JB
3263* The commands "set remotebaud" and "show remotebaud" are no longer
3264 supported. Use "set serial baud" and "show serial baud" (respectively)
3265 instead.
3266
329ea579
PA
3267* MI changes
3268
3269 ** A new option "-gdb-set mi-async" replaces "-gdb-set
3270 target-async". The latter is left as a deprecated alias of the
3271 former for backward compatibility. If the target supports it,
3272 CLI background execution commands are now always possible by
3273 default, independently of whether the frontend stated a
3274 preference for asynchronous execution with "-gdb-set mi-async".
3275 Previously "-gdb-set target-async off" affected both MI execution
3276 commands and CLI execution commands.
3277
b7bba001 3278*** Changes in GDB 7.7
2d450646 3279
33a97bbe
OJ
3280* Improved support for process record-replay and reverse debugging on
3281 arm*-linux* targets. Support for thumb32 and syscall instruction
3282 recording has been added.
3283
08248ca9
SDJ
3284* GDB now supports SystemTap SDT probes on AArch64 GNU/Linux.
3285
73869dc2
DE
3286* GDB now supports Fission DWP file format version 2.
3287 http://gcc.gnu.org/wiki/DebugFission
3288
a280dbd1
SDJ
3289* New convenience function "$_isvoid", to check whether an expression
3290 is void. A void expression is an expression where the type of the
3291 result is "void". For example, some convenience variables may be
3292 "void" when evaluated (e.g., "$_exitcode" before the execution of
3293 the program being debugged; or an undefined convenience variable).
3294 Another example, when calling a function whose return type is
3295 "void".
3296
52e260a3
DE
3297* The "maintenance print objfiles" command now takes an optional regexp.
3298
9f948660
SDJ
3299* The "catch syscall" command now works on arm*-linux* targets.
3300
901461f8
PA
3301* GDB now consistently shows "<not saved>" when printing values of
3302 registers the debug info indicates have not been saved in the frame
3303 and there's nowhere to retrieve them from
3304 (callee-saved/call-clobbered registers):
3305
3306 (gdb) p $rax
3307 $1 = <not saved>
3308
3309 (gdb) info registers rax
3310 rax <not saved>
3311
3312 Before, the former would print "<optimized out>", and the latter
3313 "*value not available*".
3314
caf26be9
SB
3315* New script contrib/gdb-add-index.sh for adding .gdb_index sections
3316 to binaries.
3317
1e611234
PM
3318* Python scripting
3319
3320 ** Frame filters and frame decorators have been added.
f76c27b5 3321 ** Temporary breakpoints are now supported.
bc79de95 3322 ** Line tables representation has been added.
a16b0e22
SC
3323 ** New attribute 'parent_type' for gdb.Field objects.
3324 ** gdb.Field objects can be used as subscripts on gdb.Value objects.
c0d48811 3325 ** New attribute 'name' for gdb.Type objects.
1e611234 3326
a1217d97
SL
3327* New targets
3328
3329Nios II ELF nios2*-*-elf
3330Nios II GNU/Linux nios2*-*-linux
42059f0e 3331Texas Instruments MSP430 msp430*-*-elf
a1217d97 3332
2659903b
JK
3333* Removed native configurations
3334
3335Support for these a.out NetBSD and OpenBSD obsolete configurations has
3336been removed. ELF variants of these configurations are kept supported.
3337
3338arm*-*-netbsd* but arm*-*-netbsdelf* is kept supported.
3339i[34567]86-*-netbsd* but i[34567]86-*-netbsdelf* is kept supported.
3340i[34567]86-*-openbsd[0-2].* but i[34567]86-*-openbsd* is kept supported.
3341i[34567]86-*-openbsd3.[0-3]
3342m68*-*-netbsd* but m68*-*-netbsdelf* is kept supported.
3343sparc-*-netbsd* but sparc-*-netbsdelf* is kept supported.
3344vax-*-netbsd* but vax-*-netbsdelf* is kept supported.
3345
bd712aed 3346* New commands:
b340913d
TT
3347catch rethrow
3348 Like "catch throw", but catches a re-thrown exception.
7d0c9981
DE
3349maint check-psymtabs
3350 Renamed from old "maint check-symtabs".
3351maint check-symtabs
3352 Perform consistency checks on symtabs.
3353maint expand-symtabs
3354 Expand symtabs matching an optional regexp.
b340913d 3355
dccca75d
EZ
3356show configuration
3357 Display the details of GDB configure-time options.
3358
bd712aed
DE
3359maint set|show per-command
3360maint set|show per-command space
3361maint set|show per-command time
3362maint set|show per-command symtab
3363 Enable display of per-command gdb resource usage.
3364
98297bf6
NB
3365remove-symbol-file FILENAME
3366remove-symbol-file -a ADDRESS
3367 Remove a symbol file added via add-symbol-file. The file to remove
3368 can be identified by its filename or by an address that lies within
3369 the boundaries of this symbol file in memory.
3370
58d06528
JB
3371info exceptions
3372info exceptions REGEXP
3373 Display the list of Ada exceptions defined in the program being
3374 debugged. If provided, only the exceptions whose names match REGEXP
3375 are listed.
3376
bd3eecc3
PA
3377* New options
3378
8fb8eb5c
DE
3379set debug symfile off|on
3380show debug symfile
3381 Control display of debugging info regarding reading symbol files and
3382 symbol tables within those files
3383
e7045703
DE
3384set print raw frame-arguments
3385show print raw frame-arguments
3386 Set/show whether to print frame arguments in raw mode,
3387 disregarding any defined pretty-printers.
3388
bd3eecc3
PA
3389set remote trace-status-packet
3390show remote trace-status-packet
3391 Set/show the use of remote protocol qTStatus packet.
3392
a1217d97
SL
3393set debug nios2
3394show debug nios2
3395 Control display of debugging messages related to Nios II targets.
3396
c1e36e3e
PA
3397set range-stepping
3398show range-stepping
3399 Control whether target-assisted range stepping is enabled.
3400
98882a26
PA
3401set startup-with-shell
3402show startup-with-shell
3403 Specifies whether Unix child processes are started via a shell or
3404 directly.
3405
29453a14
YQ
3406set code-cache
3407show code-cache
3408 Use the target memory cache for accesses to the code segment. This
3409 improves performance of remote debugging (particularly disassembly).
3410
1c2e4450
PA
3411* You can now use a literal value 'unlimited' for options that
3412 interpret 0 or -1 as meaning "unlimited". E.g., "set
3413 trace-buffer-size unlimited" is now an alias for "set
3414 trace-buffer-size -1" and "set height unlimited" is now an alias for
3415 "set height 0".
3416
db0fec5c
DE
3417* The "set debug symtab-create" debugging option of GDB has been changed to
3418 accept a verbosity level. 0 means "off", 1 provides basic debugging
3419 output, and values of 2 or greater provides more verbose output.
3420
dccca75d
EZ
3421* New command-line options
3422--configuration
3423 Display the details of GDB configure-time options.
3424
d0353e76
YQ
3425* The command 'tsave' can now support new option '-ctf' to save trace
3426 buffer in Common Trace Format.
3427
b292c783
JK
3428* Newly installed $prefix/bin/gcore acts as a shell interface for the
3429 GDB command gcore.
3430
09f2921c 3431* GDB now implements the C++ 'typeid' operator.
6e72ca20 3432
b340913d
TT
3433* The new convenience variable $_exception holds the exception being
3434 thrown or caught at an exception-related catchpoint.
3435
3436* The exception-related catchpoints, like "catch throw", now accept a
3437 regular expression which can be used to filter exceptions by type.
3438
0c557179
SDJ
3439* The new convenience variable $_exitsignal is automatically set to
3440 the terminating signal number when the program being debugged dies
3441 due to an uncaught signal.
3442
d0353e76
YQ
3443* MI changes
3444
403cb6b1 3445 ** All MI commands now accept an optional "--language" option.
4e35e808
JB
3446 Support for this feature can be verified by using the "-list-features"
3447 command, which should contain "language-option".
403cb6b1 3448
6b7cbff1
JB
3449 ** The new command -info-gdb-mi-command allows the user to determine
3450 whether a GDB/MI command is supported or not.
3451
2ea126fa
JB
3452 ** The "^error" result record returned when trying to execute an undefined
3453 GDB/MI command now provides a variable named "code" whose content is the
3454 "undefined-command" error code. Support for this feature can be verified
3455 by using the "-list-features" command, which should contain
3456 "undefined-command-error-code".
3457
d0353e76
YQ
3458 ** The -trace-save MI command can optionally save trace buffer in Common
3459 Trace Format now.
3460
c5867ab6
HZ
3461 ** The new command -dprintf-insert sets a dynamic printf breakpoint.
3462
c898adb7
YQ
3463 ** The command -data-list-register-values now accepts an optional
3464 "--skip-unavailable" option. When used, only the available registers
3465 are displayed.
3466
dc673c81
YQ
3467 ** The new command -trace-frame-collected dumps collected variables,
3468 computed expressions, tvars, memory and registers in a traceframe.
3469
6211c335
YQ
3470 ** The commands -stack-list-locals, -stack-list-arguments and
3471 -stack-list-variables now accept an option "--skip-unavailable".
3472 When used, only the available locals or arguments are displayed.
3473
5713b9b5
JB
3474 ** The -exec-run command now accepts an optional "--start" option.
3475 When used, the command follows the same semantics as the "start"
3476 command, stopping the program's execution at the start of its
72bfa06c
JB
3477 main subprogram. Support for this feature can be verified using
3478 the "-list-features" command, which should contain
3479 "exec-run-start-option".
5713b9b5 3480
40555925
JB
3481 ** The new commands -catch-assert and -catch-exceptions insert
3482 catchpoints stopping the program when Ada exceptions are raised.
3483
58d06528
JB
3484 ** The new command -info-ada-exceptions provides the equivalent of
3485 the new "info exceptions" command.
3486
0201faac
JB
3487* New system-wide configuration scripts
3488 A GDB installation now provides scripts suitable for use as system-wide
3489 configuration scripts for the following systems:
3490 ** ElinOS
3491 ** Wind River Linux
3492
c1e36e3e
PA
3493* GDB now supports target-assigned range stepping with remote targets.
3494 This improves the performance of stepping source lines by reducing
3495 the number of control packets from/to GDB. See "New remote packets"
3496 below.
3497
28a93511
YQ
3498* GDB now understands the element 'tvar' in the XML traceframe info.
3499 It has the id of the collected trace state variables.
3500
4ac33720
UW
3501* On S/390 targets that provide the transactional-execution feature,
3502 the program interruption transaction diagnostic block (TDB) is now
3503 represented as a number of additional "registers" in GDB.
3504
c1e36e3e
PA
3505* New remote packets
3506
3507vCont;r
3508
3509 The vCont packet supports a new 'r' action, that tells the remote
3510 stub to step through an address range itself, without GDB
3511 involvemement at each single-step.
3512
7f91dbec
GB
3513qXfer:libraries-svr4:read's annex
3514 The previously unused annex of the qXfer:libraries-svr4:read packet
3515 is now used to support passing an argument list. The remote stub
3516 reports support for this argument list to GDB's qSupported query.
3517 The defined arguments are "start" and "prev", used to reduce work
3518 necessary for library list updating, resulting in significant
3519 speedup.
3520
c2d6af84
PA
3521* New features in the GDB remote stub, GDBserver
3522
3523 ** GDBserver now supports target-assisted range stepping. Currently
3524 enabled on x86/x86_64 GNU/Linux targets.
3525
28a93511
YQ
3526 ** GDBserver now adds element 'tvar' in the XML in the reply to
3527 'qXfer:traceframe-info:read'. It has the id of the collected
3528 trace state variables.
3529
7a60ad40
YQ
3530 ** GDBserver now supports hardware watchpoints on the MIPS GNU/Linux
3531 target.
3532
6fbe845e
AB
3533* New 'z' formatter for printing and examining memory, this displays the
3534 value as hexadecimal zero padded on the left to the size of the type.
3535
9058cc3a
TG
3536* GDB can now use Windows x64 unwinding data.
3537
0d12017b
JB
3538* The "set remotebaud" command has been replaced by "set serial baud".
3539 Similarly, "show remotebaud" has been replaced by "show serial baud".
3540 The "set remotebaud" and "show remotebaud" commands are still available
3541 to provide backward compatibility with older versions of GDB.
3542
2d450646 3543*** Changes in GDB 7.6
80c8d323 3544
59ea5688
MM
3545* Target record has been renamed to record-full.
3546 Record/replay is now enabled with the "record full" command.
3547 This also affects settings that are associated with full record/replay
3548 that have been moved from "set/show record" to "set/show record full":
3549
3550set|show record full insn-number-max
3551set|show record full stop-at-limit
3552set|show record full memory-query
3553
3554* A new record target "record-btrace" has been added. The new target
3555 uses hardware support to record the control-flow of a process. It
3556 does not support replaying the execution, but it implements the
3557 below new commands for investigating the recorded execution log.
3558 This new recording method can be enabled using:
3559
3560record btrace
3561
3562 The "record-btrace" target is only available on Intel Atom processors
3563 and requires a Linux kernel 2.6.32 or later.
3564
3565* Two new commands have been added for record/replay to give information
3566 about the recorded execution without having to replay the execution.
3567 The commands are only supported by "record btrace".
3568
3569record instruction-history prints the execution history at
3570 instruction granularity
3571
3572record function-call-history prints the execution history at
3573 function granularity
3574
543bf33d
AT
3575* New native configurations
3576
51d66578 3577ARM AArch64 GNU/Linux aarch64*-*-linux-gnu
543bf33d 3578FreeBSD/powerpc powerpc*-*-freebsd
4f4352f7 3579x86_64/Cygwin x86_64-*-cygwin*
ea5f3910 3580Tilera TILE-Gx GNU/Linux tilegx*-*-linux-gnu
543bf33d 3581
249729c4
JB
3582* New targets
3583
51d66578
MS
3584ARM AArch64 aarch64*-*-elf
3585ARM AArch64 GNU/Linux aarch64*-*-linux
249729c4 3586Lynx 178 PowerPC powerpc-*-lynx*178
3c095f49 3587x86_64/Cygwin x86_64-*-cygwin*
ea5f3910 3588Tilera TILE-Gx GNU/Linux tilegx*-*-linux
249729c4 3589
e64e0392
DE
3590* If the configured location of system.gdbinit file (as given by the
3591 --with-system-gdbinit option at configure time) is in the
3592 data-directory (as specified by --with-gdb-datadir at configure
3593 time) or in one of its subdirectories, then GDB will look for the
3594 system-wide init file in the directory specified by the
3595 --data-directory command-line option.
3596
07540c15
DE
3597* New command line options:
3598
3599-nh Disables auto-loading of ~/.gdbinit, but still executes all the
3600 other initialization files, unlike -nx which disables all of them.
3601
e93a8774
TT
3602* Removed command line options
3603
3604-epoch This was used by the gdb mode in Epoch, an ancient fork of
3605 Emacs.
3606
53342f27
TT
3607* The 'ptype' and 'whatis' commands now accept an argument to control
3608 type formatting.
3609
451b7c33
TT
3610* 'info proc' now works on some core files.
3611
a72c3253
DE
3612* Python scripting
3613
3614 ** Vectors can be created with gdb.Type.vector.
3615
d7de8e3c
TT
3616 ** Python's atexit.register now works in GDB.
3617
18a9fc12
TT
3618 ** Types can be pretty-printed via a Python API.
3619
9a27f2c6
PK
3620 ** Python 3 is now supported (in addition to Python 2.4 or later)
3621
bea883fd
SCR
3622 ** New class gdb.Architecture exposes GDB's internal representation
3623 of architecture in the Python API.
3624
3625 ** New method Frame.architecture returns the gdb.Architecture object
3626 corresponding to the frame's architecture.
3627
a72c3253
DE
3628* New Python-based convenience functions:
3629
3630 ** $_memeq(buf1, buf2, length)
3631 ** $_streq(str1, str2)
3632 ** $_strlen(str)
3633 ** $_regex(str, regex)
3634
f3c8a52a
JK
3635* The 'cd' command now defaults to using '~' (the home directory) if not
3636 given an argument.
3637
1605ef26
TT
3638* The C++ ABI now defaults to the GNU v3 ABI. This has been the
3639 default for GCC since November 2000.
3640
504b36fd
YQ
3641* The command 'forward-search' can now be abbreviated as 'fo'.
3642
f2a8bc8a
YQ
3643* The command 'info tracepoints' can now display 'installed on target'
3644 or 'not installed on target' for each non-pending location of tracepoint.
3645
23a80689
JB
3646* New configure options
3647
3648--enable-libmcheck/--disable-libmcheck
3649 By default, development versions are built with -lmcheck on hosts
3650 that support it, in order to help track memory corruption issues.
3651 Release versions, on the other hand, are built without -lmcheck
3652 by default. The --enable-libmcheck/--disable-libmcheck configure
3653 options allow the user to override that default.
393fd4c3
YQ
3654--with-babeltrace/--with-babeltrace-include/--with-babeltrace-lib
3655 This configure option allows the user to build GDB with
3656 libbabeltrace using which GDB can read Common Trace Format data.
23a80689 3657
d6b28940
TT
3658* New commands (for set/show, see "New options" below)
3659
ab04a2af
TT
3660catch signal
3661 Catch signals. This is similar to "handle", but allows commands and
3662 conditions to be attached.
3663
d6b28940
TT
3664maint info bfds
3665 List the BFDs known to GDB.
3666
8315665e
YPK
3667python-interactive [command]
3668pi [command]
3669 Start a Python interactive prompt, or evaluate the optional command
3670 and print the result of expressions.
3671
3672py [command]
3673 "py" is a new alias for "python".
3674
18a9fc12
TT
3675enable type-printer [name]...
3676disable type-printer [name]...
3677 Enable or disable type printers.
3678
aa9259cc
TS
3679* Removed commands
3680
3681 ** For the Renesas Super-H architecture, the "regs" command has been removed
3682 (has been deprecated in GDB 7.5), and "info all-registers" should be used
3683 instead.
3684
53342f27
TT
3685* New options
3686
3687set print type methods (on|off)
3688show print type methods
3689 Control whether method declarations are displayed by "ptype".
3690 The default is to show them.
3691
3692set print type typedefs (on|off)
3693show print type typedefs
3694 Control whether typedef definitions are displayed by "ptype".
3695 The default is to show them.
3696
1b56eb55
JK
3697set filename-display basename|relative|absolute
3698show filename-display
3699 Control the way in which filenames is displayed.
3700 The default is "relative", which preserves previous behavior.
3701
e9f1758d
PA
3702set trace-buffer-size
3703show trace-buffer-size
3704 Request target to change the size of trace buffer.
3705
a46c1e42
PA
3706set remote trace-buffer-size-packet auto|on|off
3707show remote trace-buffer-size-packet
3708 Control the use of the remote protocol `QTBuffer:size' packet.
3709
be9a8770
PA
3710set debug aarch64
3711show debug aarch64
3712 Control display of debugging messages related to ARM AArch64.
3713 The default is off.
3714
3715set debug coff-pe-read
3716show debug coff-pe-read
3717 Control display of debugging messages related to reading of COFF/PE
3718 exported symbols.
3719
3720set debug mach-o
3721show debug mach-o
3722 Control display of debugging messages related to Mach-O symbols
3723 processing.
3724
3725set debug notification
3726show debug notification
3727 Control display of debugging info for async remote notification.
3728
5b9afe8a
YQ
3729* MI changes
3730
3731 ** Command parameter changes are now notified using new async record
3732 "=cmd-param-changed".
201b4506
YQ
3733 ** Trace frame changes caused by command "tfind" are now notified using
3734 new async record "=traceframe-changed".
134a2066
YQ
3735 ** The creation, deletion and modification of trace state variables
3736 are now notified using new async records "=tsv-created",
3737 "=tsv-deleted" and "=tsv-modified".
82a90ccf
YQ
3738 ** The start and stop of process record are now notified using new
3739 async record "=record-started" and "=record-stopped".
8de0566d
YQ
3740 ** Memory changes are now notified using new async record
3741 "=memory-changed".
ed8a1c2d 3742 ** The data-disassemble command response will include a "fullname" field
ec83d211 3743 containing the absolute file name when source has been requested.
62747a60
TT
3744 ** New optional parameter COUNT added to the "-data-write-memory-bytes"
3745 command, to allow pattern filling of memory areas.
3fa7bf06
MG
3746 ** New commands "-catch-load"/"-catch-unload" added for intercepting
3747 library load/unload events.
f2a8bc8a
YQ
3748 ** The response to breakpoint commands and breakpoint async records
3749 includes an "installed" field containing a boolean state about each
3750 non-pending tracepoint location is whether installed on target or not.
f5911ea1
HAQ
3751 ** Output of the "-trace-status" command includes a "trace-file" field
3752 containing the name of the trace file being examined. This field is
3753 optional, and only present when examining a trace file.
ec83d211
JK
3754 ** The "fullname" field is now always present along with the "file" field,
3755 even if the file cannot be found by GDB.
5b9afe8a 3756
608e2dbb
TT
3757* GDB now supports the "mini debuginfo" section, .gnu_debugdata.
3758 You must have the LZMA library available when configuring GDB for this
3759 feature to be enabled. For more information, see:
3760 http://fedoraproject.org/wiki/Features/MiniDebugInfo
3761
f6f899bf
HAQ
3762* New remote packets
3763
3764QTBuffer:size
3765 Set the size of trace buffer. The remote stub reports support for this
3766 packet to gdb's qSupported query.
3767
10782d74
MM
3768Qbtrace:bts
3769 Enable Branch Trace Store (BTS)-based branch tracing for the current
3770 thread. The remote stub reports support for this packet to gdb's
3771 qSupported query.
3772
3773Qbtrace:off
3774 Disable branch tracing for the current thread. The remote stub reports
3775 support for this packet to gdb's qSupported query.
3776
3777qXfer:btrace:read
3778 Read the traced branches for the current thread. The remote stub
3779 reports support for this packet to gdb's qSupported query.
3780
80c8d323 3781*** Changes in GDB 7.5
d6e00af6 3782
1b3371b1
L
3783* GDB now supports x32 ABI. Visit <http://sites.google.com/site/x32abi/>
3784 for more x32 ABI info.
3785
d0e64392
MR
3786* GDB now supports access to MIPS DSP registers on Linux targets.
3787
4cc0665f
MR
3788* GDB now supports debugging microMIPS binaries.
3789
85d4a676
SS
3790* The "info os" command on GNU/Linux can now display information on
3791 several new classes of objects managed by the operating system:
3792 "info os procgroups" lists process groups
3793 "info os files" lists file descriptors
3794 "info os sockets" lists internet-domain sockets
3795 "info os shm" lists shared-memory regions
3796 "info os semaphores" lists semaphores
3797 "info os msg" lists message queues
3798 "info os modules" lists loaded kernel modules
3799
55aa24fb
SDJ
3800* GDB now has support for SDT (Static Defined Tracing) probes. Currently,
3801 the only implemented backend is for SystemTap probes (<sys/sdt.h>). You
3802 can set a breakpoint using the new "-probe, "-pstap" or "-probe-stap"
3803 options and inspect the probe arguments using the new $_probe_arg family
3804 of convenience variables. You can obtain more information about SystemTap
3805 in <http://sourceware.org/systemtap/>.
3806
72508ac0
PO
3807* GDB now supports reversible debugging on ARM, it allows you to
3808 debug basic ARM and THUMB instructions, and provides
3809 record/replay support.
3810
16899756
DE
3811* The option "symbol-reloading" has been deleted as it is no longer used.
3812
4795f398
DE
3813* Python scripting
3814
7d74f244
DE
3815 ** GDB commands implemented in Python can now be put in command class
3816 "gdb.COMMAND_USER".
3817
4795f398
DE
3818 ** The "maint set python print-stack on|off" is now deleted.
3819
50897289
TT
3820 ** A new class, gdb.printing.FlagEnumerationPrinter, can be used to
3821 apply "flag enum"-style pretty-printing to any enum.
3822
64e7d9dd
TT
3823 ** gdb.lookup_symbol can now work when there is no current frame.
3824
3825 ** gdb.Symbol now has a 'line' attribute, holding the line number in
3826 the source at which the symbol was defined.
3827
f0823d2c
TT
3828 ** gdb.Symbol now has the new attribute 'needs_frame' and the new
3829 method 'value'. The former indicates whether the symbol needs a
3830 frame in order to compute its value, and the latter computes the
3831 symbol's value.
3832
7b282c5a
SCR
3833 ** A new method 'referenced_value' on gdb.Value objects which can
3834 dereference pointer as well as C++ reference values.
3835
a20ee7a4
SCR
3836 ** New methods 'global_block' and 'static_block' on gdb.Symtab objects
3837 which return the global and static blocks (as gdb.Block objects),
3838 of the underlying symbol table, respectively.
3839
7efc75aa
SCR
3840 ** New function gdb.find_pc_line which returns the gdb.Symtab_and_line
3841 object associated with a PC value.
3842
ee0bf529
SCR
3843 ** gdb.Symtab_and_line has new attribute 'last' which holds the end
3844 of the address range occupied by code for the current source line.
3845
a766d390
DE
3846* Go language support.
3847 GDB now supports debugging programs written in the Go programming
3848 language.
3849
e0f9f062
DE
3850* GDBserver now supports stdio connections.
3851 E.g. (gdb) target remote | ssh myhost gdbserver - hello
3852
217bff3e
JK
3853* The binary "gdbtui" can no longer be built or installed.
3854 Use "gdb -tui" instead.
3855
cafec441
TT
3856* GDB will now print "flag" enums specially. A flag enum is one where
3857 all the enumerator values have no bits in common when pairwise
3858 "and"ed. When printing a value whose type is a flag enum, GDB will
3859 show all the constants, e.g., for enum E { ONE = 1, TWO = 2}:
3860 (gdb) print (enum E) 3
3861 $1 = (ONE | TWO)
3862
4aac40c8
TT
3863* The filename part of a linespec will now match trailing components
3864 of a source file name. For example, "break gcc/expr.c:1000" will
3865 now set a breakpoint in build/gcc/expr.c, but not
3866 build/libcpp/expr.c.
3867
d99bd577
UW
3868* The "info proc" and "generate-core-file" commands will now also
3869 work on remote targets connected to GDBserver on Linux.
3870
53fe1783
GB
3871* The command "info catch" has been removed. It has been disabled
3872 since December 2007.
3873
e41eec66
JB
3874* The "catch exception" and "catch assert" commands now accept
3875 a condition at the end of the command, much like the "break"
3876 command does. For instance:
3877
3878 (gdb) catch exception Constraint_Error if Barrier = True
3879
3880 Previously, it was possible to add a condition to such catchpoints,
3881 but it had to be done as a second step, after the catchpoint had been
3882 created, using the "condition" command.
3883
5808517f
YQ
3884* The "info static-tracepoint-marker" command will now also work on
3885 native Linux targets with in-process agent.
3886
481860b3
GB
3887* GDB can now set breakpoints on inlined functions.
3888
3889* The .gdb_index section has been updated to include symbols for
3890 inlined functions. GDB will ignore older .gdb_index sections by
3891 default, which could cause symbol files to be loaded more slowly
e615022a
DE
3892 until their .gdb_index sections can be recreated. The new command
3893 "set use-deprecated-index-sections on" will cause GDB to use any older
3894 .gdb_index sections it finds. This will restore performance, but the
3895 ability to set breakpoints on inlined functions will be lost in symbol
3896 files with older .gdb_index sections.
481860b3 3897
156942c7
DE
3898 The .gdb_index section has also been updated to record more information
3899 about each symbol. This speeds up the "info variables", "info functions"
3900 and "info types" commands when used with programs having the .gdb_index
3901 section, as well as speeding up debugging with shared libraries using
3902 the .gdb_index section.
3903
927fbba6
JB
3904* Ada support for GDB/MI Variable Objects has been added.
3905
20388dd6
YQ
3906* GDB can now support 'breakpoint always-inserted mode' in 'record'
3907 target.
3908
f3e0e960
SS
3909* MI changes
3910
3911 ** New command -info-os is the MI equivalent of "info os".
3912
37ce89eb
SS
3913 ** Output logs ("set logging" and related) now include MI output.
3914
edcc5120
TT
3915* New commands
3916
e615022a
DE
3917 ** "set use-deprecated-index-sections on|off"
3918 "show use-deprecated-index-sections on|off"
3919 Controls the use of deprecated .gdb_index sections.
3920
edcc5120
TT
3921 ** "catch load" and "catch unload" can be used to stop when a shared
3922 library is loaded or unloaded, respectively.
3923
816338b5
SS
3924 ** "enable count" can be used to auto-disable a breakpoint after
3925 several hits.
3926
57651221 3927 ** "info vtbl" can be used to show the virtual method tables for
c4aeac85
TT
3928 C++ and Java objects.
3929
06fc020f 3930 ** "explore" and its sub commands "explore value" and "explore type"
6ea71545 3931 can be used to recursively explore values and types of
06fc020f
SCR
3932 expressions. These commands are available only if GDB is
3933 configured with '--with-python'.
3934
bf88dd68
JK
3935 ** "info auto-load" shows status of all kinds of auto-loaded files,
3936 "info auto-load gdb-scripts" shows status of auto-loading GDB canned
3937 sequences of commands files, "info auto-load python-scripts"
3938 shows status of auto-loading Python script files,
3939 "info auto-load local-gdbinit" shows status of loading init file
3940 (.gdbinit) from current directory and "info auto-load libthread-db" shows
3941 status of inferior specific thread debugging shared library loading.
3942
3943 ** "info auto-load-scripts", "set auto-load-scripts on|off"
3944 and "show auto-load-scripts" commands have been deprecated, use their
3945 "info auto-load python-scripts", "set auto-load python-scripts on|off"
3946 and "show auto-load python-scripts" counterparts instead.
3947
e7e0cddf
SS
3948 ** "dprintf location,format,args..." creates a dynamic printf, which
3949 is basically a breakpoint that does a printf and immediately
3950 resumes your program's execution, so it is like a printf that you
3951 can insert dynamically at runtime instead of at compiletime.
3952
9cb709b6
TT
3953 ** "set print symbol"
3954 "show print symbol"
3955 Controls whether GDB attempts to display the symbol, if any,
3956 corresponding to addresses it prints. This defaults to "on", but
3957 you can set it to "off" to restore GDB's previous behavior.
3958
2d4c29c5
TS
3959* Deprecated commands
3960
3961 ** For the Renesas Super-H architecture, the "regs" command has been
3962 deprecated, and "info all-registers" should be used instead.
3963
a58b110a
KB
3964* New targets
3965
3966Renesas RL78 rl78-*-elf
60c9a3c0 3967HP OpenVMS ia64 ia64-hp-openvms*
a58b110a 3968
72895ff6
LM
3969* GDBserver supports evaluation of breakpoint conditions. When
3970 support is advertised by GDBserver, GDB may be told to send the
3971 breakpoint conditions in bytecode form to GDBserver. GDBserver
3972 will only report the breakpoint trigger to GDB when its condition
3973 evaluates to true.
3974
3975* New options
3976
4cc0665f
MR
3977set mips compression
3978show mips compression
3979 Select the compressed ISA encoding used in functions that have no symbol
3980 information available. The encoding can be set to either of:
3981 mips16
3982 micromips
3983 and is updated automatically from ELF file flags if available.
3984
72895ff6
LM
3985set breakpoint condition-evaluation
3986show breakpoint condition-evaluation
cf65ecd3 3987 Control whether breakpoint conditions are evaluated by GDB ("host") or by
5b43fab2
JK
3988 GDBserver ("target"). Default option "auto" chooses the most efficient
3989 available mode.
72895ff6
LM
3990 This option can improve debugger efficiency depending on the speed of the
3991 target.
3992
bf88dd68
JK
3993set auto-load off
3994 Disable auto-loading globally.
3995
3996show auto-load
3997 Show auto-loading setting of all kinds of auto-loaded files.
3998
3999set auto-load gdb-scripts on|off
4000show auto-load gdb-scripts
4001 Control auto-loading of GDB canned sequences of commands files.
4002
4003set auto-load python-scripts on|off
4004show auto-load python-scripts
4005 Control auto-loading of Python script files.
4006
4007set auto-load local-gdbinit on|off
4008show auto-load local-gdbinit
4009 Control loading of init file (.gdbinit) from current directory.
4010
4011set auto-load libthread-db on|off
4012show auto-load libthread-db
4013 Control auto-loading of inferior specific thread debugging shared library.
4014
7349ff92 4015set auto-load scripts-directory <dir1>[:<dir2>...]
9cc815f5 4016show auto-load scripts-directory
7349ff92
JK
4017 Set a list of directories from which to load auto-loaded scripts.
4018 Automatically loaded Python scripts and GDB scripts are located in one
4019 of the directories listed by this option.
4020 The delimiter (':' above) may differ according to the host platform.
4021
bccbefd2
JK
4022set auto-load safe-path <dir1>[:<dir2>...]
4023show auto-load safe-path
4024 Set a list of directories from which it is safe to auto-load files.
4025 The delimiter (':' above) may differ according to the host platform.
4026
4dc84fd1
JK
4027set debug auto-load on|off
4028show debug auto-load
4029 Control display of debugging info for auto-loading the files above.
4030
d3ce09f5 4031set dprintf-style gdb|call|agent
e7e0cddf 4032show dprintf-style
d3ce09f5
SS
4033 Control the way in which a dynamic printf is performed; "gdb"
4034 requests a GDB printf command, while "call" causes dprintf to call a
4035 function in the inferior. "agent" requests that the target agent
4036 (such as GDBserver) do the printing.
e7e0cddf
SS
4037
4038set dprintf-function <expr>
4039show dprintf-function
4040set dprintf-channel <expr>
4041show dprintf-channel
4042 Set the function and optional first argument to the call when using
4043 the "call" style of dynamic printf.
4044
d3ce09f5
SS
4045set disconnected-dprintf on|off
4046show disconnected-dprintf
4047 Control whether agent-style dynamic printfs continue to be in effect
4048 after GDB disconnects.
4049
6dea1fbd
JK
4050* New configure options
4051
7349ff92
JK
4052--with-auto-load-dir
4053 Configure default value for the 'set auto-load scripts-directory'
1564a261
JK
4054 setting above. It defaults to '$debugdir:$datadir/auto-load',
4055 $debugdir representing global debugging info directories (available
4056 via 'show debug-file-directory') and $datadir representing GDB's data
4057 directory (available via 'show data-directory').
7349ff92 4058
6dea1fbd
JK
4059--with-auto-load-safe-path
4060 Configure default value for the 'set auto-load safe-path' setting
7349ff92 4061 above. It defaults to the --with-auto-load-dir setting.
6dea1fbd
JK
4062
4063--without-auto-load-safe-path
4064 Set 'set auto-load safe-path' to '/', effectively disabling this
4065 security feature.
4066
72895ff6
LM
4067* New remote packets
4068
74c48cbb
PA
4069z0/z1 conditional breakpoints extension
4070
72895ff6
LM
4071 The z0/z1 breakpoint insertion packets have been extended to carry
4072 a list of conditional expressions over to the remote stub depending on the
4073 condition evaluation mode. The use of this extension can be controlled
4074 via the "set remote conditional-breakpoints-packet" command.
4075
9b224c5e
PA
4076QProgramSignals:
4077
4078 Specify the signals which the remote stub may pass to the debugged
4079 program without GDB involvement.
4080
8320cc4f
JK
4081* New command line options
4082
4083--init-command=FILE, -ix Like --command, -x but execute it
4084 before loading inferior.
4085--init-eval-command=COMMAND, -iex Like --eval-command=COMMAND, -ex but
4086 execute it before loading inferior.
4087
8837a20f
JB
4088*** Changes in GDB 7.4
4089
f8eba3c6
TT
4090* GDB now handles ambiguous linespecs more consistently; the existing
4091 FILE:LINE support has been expanded to other types of linespecs. A
4092 breakpoint will now be set on all matching locations in all
4093 inferiors, and locations will be added or removed according to
4094 inferior changes.
4095
1bfeeb0f
JL
4096* GDB now allows you to skip uninteresting functions and files when
4097 stepping with the "skip function" and "skip file" commands.
4098
480a3f21
PW
4099* GDB has two new commands: "set remote hardware-watchpoint-length-limit"
4100 and "show remote hardware-watchpoint-length-limit". These allows to
4101 set or show the maximum length limit (in bytes) of a remote
4102 target hardware watchpoint.
4103
4104 This allows e.g. to use "unlimited" hardware watchpoints with the
4105 gdbserver integrated in Valgrind version >= 3.7.0. Such Valgrind
4106 watchpoints are slower than real hardware watchpoints but are
4107 significantly faster than gdb software watchpoints.
4108
3a7bf607
PM
4109* Python scripting
4110
32d1c362 4111 ** The register_pretty_printer function in module gdb.printing now takes
7d0aff21 4112 an optional `replace' argument. If True, the new printer replaces any
32d1c362
DE
4113 existing one.
4114
3a7bf607 4115 ** The "maint set python print-stack on|off" command has been
4795f398
DE
4116 deprecated and will be deleted in GDB 7.5.
4117 A new command: "set python print-stack none|full|message" has
4118 replaced it. Additionally, the default for "print-stack" is
4119 now "message", which just prints the error message without
4120 the stack trace.
3a7bf607 4121
baacfb07 4122 ** A prompt substitution hook (prompt_hook) is now available to the
3a7bf607 4123 Python API.
713389e0 4124
fa3a4f15
PM
4125 ** A new Python module, gdb.prompt has been added to the GDB Python
4126 modules library. This module provides functionality for
baacfb07 4127 escape sequences in prompts (used by set/show
fa3a4f15
PM
4128 extended-prompt). These escape sequences are replaced by their
4129 corresponding value.
4130
5e239b84
PM
4131 ** Python commands and convenience-functions located in
4132 'data-directory'/python/gdb/command and
4133 'data-directory'/python/gdb/function are now automatically loaded
4134 on GDB start-up.
4135
9df2fbc4
PM
4136 ** Blocks now provide four new attributes. global_block and
4137 static_block will return the global and static blocks
4138 respectively. is_static and is_global are boolean attributes
4139 that indicate if the block is one of those two types.
4140
457e09f0
DE
4141 ** Symbols now provide the "type" attribute, the type of the symbol.
4142
6839b47f
KP
4143 ** The "gdb.breakpoint" function has been deprecated in favor of
4144 "gdb.breakpoints".
4145
cc72b2a2
KP
4146 ** A new class "gdb.FinishBreakpoint" is provided to catch the return
4147 of a function. This class is based on the "finish" command
4148 available in the CLI.
4149
84ad80e6
PK
4150 ** Type objects for struct and union types now allow access to
4151 the fields using standard Python dictionary (mapping) methods.
4152 For example, "some_type['myfield']" now works, as does
4153 "some_type.items()".
4154
20c168b5
KP
4155 ** A new event "gdb.new_objfile" has been added, triggered by loading a
4156 new object file.
4157
03c3051a
PK
4158 ** A new function, "deep_items" has been added to the gdb.types
4159 module in the GDB Python modules library. This function returns
4160 an iterator over the fields of a struct or union type. Unlike
4161 the standard Python "iteritems" method, it will recursively traverse
4162 any anonymous fields.
4163
7376e450
TT
4164* MI changes
4165
4166 ** "*stopped" events can report several new "reason"s, such as
4167 "solib-event".
4168
4169 ** Breakpoint changes are now notified using new async records, like
4170 "=breakpoint-modified".
4171
4172 ** New command -ada-task-info.
4173
98a5dd13
DE
4174* libthread-db-search-path now supports two special values: $sdir and $pdir.
4175 $sdir specifies the default system locations of shared libraries.
4176 $pdir specifies the directory where the libpthread used by the application
4177 lives.
4178
4179 GDB no longer looks in $sdir and $pdir after it has searched the directories
4180 mentioned in libthread-db-search-path. If you want to search those
4181 directories, they must be specified in libthread-db-search-path.
4182 The default value of libthread-db-search-path on GNU/Linux and Solaris
4183 systems is now "$sdir:$pdir".
4184
4185 $pdir is not supported by gdbserver, it is currently ignored.
4186 $sdir is supported by gdbserver.
4187
478aac75
DE
4188* New configure option --with-iconv-bin.
4189 When using the internationalization support like the one in the GNU C
4190 library, GDB will invoke the "iconv" program to get a list of supported
4191 character sets. If this program lives in a non-standard location, one can
4192 use this option to specify where to find it.
4193
9c06b0b4
TJB
4194* When natively debugging programs on PowerPC BookE processors running
4195 a Linux kernel version 2.6.34 or later, GDB supports masked hardware
4196 watchpoints, which specify a mask in addition to an address to watch.
4197 The mask specifies that some bits of an address (the bits which are
4198 reset in the mask) should be ignored when matching the address accessed
4199 by the inferior against the watchpoint address. See the "PowerPC Embedded"
4200 section in the user manual for more details.
4201
03f2bd59
JK
4202* The new option --once causes GDBserver to stop listening for connections once
4203 the first connection is made. The listening port used by GDBserver will
4204 become available after that.
4205
71eba9c2 4206* New commands "info macros" and "alias" have been added.
edc84990 4207
2bda9cc5
JK
4208* New function parameters suffix @entry specifies value of function parameter
4209 at the time the function got called. Entry values are available only since
4210 gcc version 4.7.
4211
ed59ded5
DE
4212* New commands
4213
4214!SHELL COMMAND
4215 "!" is now an alias of the "shell" command.
4216 Note that no space is needed between "!" and SHELL COMMAND.
4217
9c06b0b4
TJB
4218* Changed commands
4219
4220watch EXPRESSION mask MASK_VALUE
4221 The watch command now supports the mask argument which allows creation
4222 of masked watchpoints, if the current architecture supports this feature.
4223
dbaefcf7
DE
4224info auto-load-scripts [REGEXP]
4225 This command was formerly named "maintenance print section-scripts".
4226 It is now generally useful and is no longer a maintenance-only command.
4227
71eba9c2 4228info macro [-all] [--] MACRO
4229 The info macro command has new options `-all' and `--'. The first for
4230 printing all definitions of a macro. The second for explicitly specifying
4231 the end of arguments and the beginning of the macro name in case the macro
4232 name starts with a hyphen.
4233
3065dfb6
SS
4234collect[/s] EXPRESSIONS
4235 The tracepoint collect command now takes an optional modifier "/s"
4236 that directs it to dereference pointer-to-character types and
4237 collect the bytes of memory up to a zero byte. The behavior is
4238 similar to what you see when you use the regular print command on a
4239 string. An optional integer following the "/s" sets a bound on the
4240 number of bytes that will be collected.
4241
f196051f
SS
4242tstart [NOTES]
4243 The trace start command now interprets any supplied arguments as a
4244 note to be recorded with the trace run, with an effect similar to
4245 setting the variable trace-notes.
4246
4247tstop [NOTES]
4248 The trace stop command now interprets any arguments as a note to be
4249 mentioned along with the tstatus report that the trace was stopped
4250 with a command. The effect is similar to setting the variable
4251 trace-stop-notes.
4252
d248b706
KY
4253* Tracepoints can now be enabled and disabled at any time after a trace
4254 experiment has been started using the standard "enable" and "disable"
4255 commands. It is now possible to start a trace experiment with no enabled
4256 tracepoints; GDB will display a warning, but will allow the experiment to
4257 begin, assuming that tracepoints will be enabled as needed while the trace
4258 is running.
4259
405f8e94
SS
4260* Fast tracepoints on 32-bit x86-architectures can now be placed at
4261 locations with 4-byte instructions, when they were previously
4262 limited to locations with instructions of 5 bytes or longer.
4263
2bda9cc5
JK
4264* New options
4265
45cfd468
DE
4266set debug dwarf2-read
4267show debug dwarf2-read
4268 Turns on or off display of debugging messages related to reading
4269 DWARF debug info. The default is off.
4270
4271set debug symtab-create
4272show debug symtab-create
4273 Turns on or off display of debugging messages related to symbol table
4274 creation. The default is off.
4275
baacfb07
PM
4276set extended-prompt
4277show extended-prompt
4278 Set the GDB prompt, and allow escape sequences to be inserted to
4279 display miscellaneous information (see 'help set extended-prompt'
4280 for the list of sequences). This prompt (and any information
4281 accessed through the escape sequences) is updated every time the
4282 prompt is displayed.
4283
2bda9cc5
JK
4284set print entry-values (both|compact|default|if-needed|no|only|preferred)
4285show print entry-values
4286 Set printing of frame argument values at function entry. In some cases
4287 GDB can determine the value of function argument which was passed by the
4288 function caller, even if the value was modified inside the called function.
4289
4290set debug entry-values
4291show debug entry-values
4292 Control display of debugging info for determining frame argument values at
4293 function entry and virtual tail call frames.
4294
c011a4f4
DE
4295set basenames-may-differ
4296show basenames-may-differ
4297 Set whether a source file may have multiple base names.
4298 (A "base name" is the name of a file with the directory part removed.
4299 Example: The base name of "/home/user/hello.c" is "hello.c".)
4300 If set, GDB will canonicalize file names (e.g., expand symlinks)
4301 before comparing them. Canonicalization is an expensive operation,
4302 but it allows the same file be known by more than one base name.
4303 If not set (the default), all source files are assumed to have just
4304 one base name, and gdb will do file name comparisons more efficiently.
4305
f196051f
SS
4306set trace-user
4307show trace-user
4308set trace-notes
4309show trace-notes
4310 Set a user name and notes for the current and any future trace runs.
4311 This is useful for long-running and/or disconnected traces, to
4312 inform others (or yourself) as to who is running the trace, supply
4313 contact information, or otherwise explain what is going on.
4314
4315set trace-stop-notes
4316show trace-stop-notes
4317 Set a note attached to the trace run, that is displayed when the
4318 trace has been stopped by a tstop command. This is useful for
4319 instance as an explanation, if you are stopping a trace run that was
4320 started by someone else.
4321
d248b706
KY
4322* New remote packets
4323
4324QTEnable
4325
4326 Dynamically enable a tracepoint in a started trace experiment.
4327
4328QTDisable
4329
4330 Dynamically disable a tracepoint in a started trace experiment.
4331
f196051f
SS
4332QTNotes
4333
4334 Set the user and notes of the trace run.
4335
4336qTP
4337
4338 Query the current status of a tracepoint.
4339
405f8e94
SS
4340qTMinFTPILen
4341
4342 Query the minimum length of instruction at which a fast tracepoint may
4343 be placed.
4344
1a532630
PP
4345* Dcache size (number of lines) and line-size are now runtime-configurable
4346 via "set dcache line" and "set dcache line-size" commands.
4347
11315641
YQ
4348* New targets
4349
4350Texas Instruments TMS320C6x tic6x-*-*
4351
87326c78
DD
4352* New Simulators
4353
4354Renesas RL78 rl78-*-elf
4355
e8d56f18
JB
4356*** Changes in GDB 7.3.1
4357
4358* The build failure for NetBSD and OpenBSD targets have now been fixed.
4359
d6e00af6 4360*** Changes in GDB 7.3
797054e6 4361
60f98dde
MS
4362* GDB has a new command: "thread find [REGEXP]".
4363 It finds the thread id whose name, target id, or thread extra info
4364 matches the given regular expression.
4365
eee5b35e
DD
4366* The "catch syscall" command now works on mips*-linux* targets.
4367
b716877b
AB
4368* The -data-disassemble MI command now supports modes 2 and 3 for
4369 dumping the instruction opcodes.
4370
aae1c79a
DE
4371* New command line options
4372
4373-data-directory DIR Specify DIR as the "data-directory".
4374 This is mostly for testing purposes.
4375
a86caf66
DE
4376* The "maint set python auto-load on|off" command has been renamed to
4377 "set auto-load-scripts on|off".
4378
99e7ae30
DE
4379* GDB has a new command: "set directories".
4380 It is like the "dir" command except that it replaces the
4381 source path list instead of augmenting it.
4382
4694da01
TT
4383* GDB now understands thread names.
4384
4385 On GNU/Linux, "info threads" will display the thread name as set by
4386 prctl or pthread_setname_np.
4387
4388 There is also a new command, "thread name", which can be used to
4389 assign a name internally for GDB to display.
4390
f4b8a18d
KW
4391* OpenCL C
4392 Initial support for the OpenCL C language (http://www.khronos.org/opencl)
4393 has been integrated into GDB.
4394
585d1eb8
PM
4395* Python scripting
4396
da5d4055
PM
4397 ** The function gdb.Write now accepts an optional keyword 'stream'.
4398 This keyword, when provided, will direct the output to either
4399 stdout, stderr, or GDB's logging output.
4400
9a6f1302
PM
4401 ** Parameters can now be be sub-classed in Python, and in particular
4402 you may implement the get_set_doc and get_show_doc functions.
4403 This improves how Parameter set/show documentation is processed
4404 and allows for more dynamic content.
4405
29703da4
PM
4406 ** Symbols, Symbol Table, Symbol Table and Line, Object Files,
4407 Inferior, Inferior Thread, Blocks, and Block Iterator APIs now
4408 have an is_valid method.
4409
350c6c65
PM
4410 ** Breakpoints can now be sub-classed in Python, and in particular
4411 you may implement a 'stop' function that is executed each time
4412 the inferior reaches that breakpoint.
4413
6e6fbe60
DE
4414 ** New function gdb.lookup_global_symbol looks up a global symbol.
4415
585d1eb8
PM
4416 ** GDB values in Python are now callable if the value represents a
4417 function. For example, if 'some_value' represents a function that
4418 takes two integer parameters and returns a value, you can call
4419 that function like so:
4420
4421 result = some_value (10,20)
4422
0e3509db
DE
4423 ** Module gdb.types has been added.
4424 It contains a collection of utilities for working with gdb.Types objects:
4425 get_basic_type, has_field, make_enum_dict.
4426
7b51bc51
DE
4427 ** Module gdb.printing has been added.
4428 It contains utilities for writing and registering pretty-printers.
4429 New classes: PrettyPrinter, SubPrettyPrinter,
4430 RegexpCollectionPrettyPrinter.
4431 New function: register_pretty_printer.
4432
4433 ** New commands "info pretty-printers", "enable pretty-printer" and
4434 "disable pretty-printer" have been added.
4435
99e7ae30
DE
4436 ** gdb.parameter("directories") is now available.
4437
d8e22779
TT
4438 ** New function gdb.newest_frame returns the newest frame in the
4439 selected thread.
4440
4694da01
TT
4441 ** The gdb.InferiorThread class has a new "name" attribute. This
4442 holds the thread's name.
4443
505500db
SW
4444 ** Python Support for Inferior events.
4445 Python scripts can add observers to be notified of events
824446ad 4446 occurring in the process being debugged.
c17a9e46
HZ
4447 The following events are currently supported:
4448 - gdb.events.cont Continue event.
4449 - gdb.events.exited Inferior exited event.
4450 - gdb.events.stop Signal received, and Breakpoint hit events.
4451
def98928
TT
4452* C++ Improvements:
4453
4454 ** GDB now puts template parameters in scope when debugging in an
4455 instantiation. For example, if you have:
4456
4457 template<int X> int func (void) { return X; }
4458
4459 then if you step into func<5>, "print X" will show "5". This
4460 feature requires proper debuginfo support from the compiler; it
4461 was added to GCC 4.5.
4462
66cb8159
TT
4463 ** The motion commands "next", "finish", "until", and "advance" now
4464 work better when exceptions are thrown. In particular, GDB will
4465 no longer lose control of the inferior; instead, the GDB will
4466 stop the inferior at the point at which the exception is caught.
4467 This functionality requires a change in the exception handling
4468 code that was introduced in GCC 4.5.
4469
4aac0db7
UW
4470* GDB now follows GCC's rules on accessing volatile objects when
4471 reading or writing target state during expression evaluation.
4472 One notable difference to prior behavior is that "print x = 0"
4473 no longer generates a read of x; the value of the assignment is
4474 now always taken directly from the value being assigned.
4475
283e6a52
TT
4476* GDB now has some support for using labels in the program's source in
4477 linespecs. For instance, you can use "advance label" to continue
4478 execution to a label.
4479
4480* GDB now has support for reading and writing a new .gdb_index
4481 section. This section holds a fast index of DWARF debugging
4482 information and can be used to greatly speed up GDB startup and
4483 operation. See the documentation for `save gdb-index' for details.
4484
b56df873 4485* The "watch" command now accepts an optional "-location" argument.
14c0d4e1 4486 When used, this causes GDB to watch the memory referred to by the
b56df873
TT
4487 expression. Such a watchpoint is never deleted due to it going out
4488 of scope.
4489
ae53ffa4
PA
4490* GDB now supports thread debugging of core dumps on GNU/Linux.
4491
4492 GDB now activates thread debugging using the libthread_db library
4493 when debugging GNU/Linux core dumps, similarly to when debugging
4494 live processes. As a result, when debugging a core dump file, GDB
4495 is now able to display pthread_t ids of threads. For example, "info
4496 threads" shows the same output as when debugging the process when it
4497 was live. In earlier releases, you'd see something like this:
4498
4499 (gdb) info threads
4500 * 1 LWP 6780 main () at main.c:10
4501
4502 While now you see this:
4503
4504 (gdb) info threads
4505 * 1 Thread 0x7f0f5712a700 (LWP 6780) main () at main.c:10
4506
4507 It is also now possible to inspect TLS variables when debugging core
4508 dumps.
4509
4510 When debugging a core dump generated on a machine other than the one
4511 used to run GDB, you may need to point GDB at the correct
4512 libthread_db library with the "set libthread-db-search-path"
4513 command. See the user manual for more details on this command.
4514
f1310107
TJB
4515* When natively debugging programs on PowerPC BookE processors running
4516 a Linux kernel version 2.6.34 or later, GDB supports ranged breakpoints,
4517 which stop execution of the inferior whenever it executes an instruction
4518 at any address within the specified range. See the "PowerPC Embedded"
4519 section in the user manual for more details.
4520
248c9dbc
JB
4521* New features in the GDB remote stub, GDBserver
4522
1aee7009
JB
4523 ** GDBserver is now supported on PowerPC LynxOS (versions 4.x and 5.x),
4524 and i686 LynxOS (version 5.x).
248c9dbc 4525
eb826dc6
MF
4526 ** GDBserver is now supported on Blackfin Linux.
4527
44603653
JB
4528* New native configurations
4529
4530ia64 HP-UX ia64-*-hpux*
4531
91021223
MF
4532* New targets:
4533
4534Analog Devices, Inc. Blackfin Processor bfin-*
4535
6e1bb179
JB
4536* Ada task switching is now supported on sparc-elf targets when
4537 debugging a program using the Ravenscar Profile. For more information,
4538 see the "Tasking Support when using the Ravenscar Profile" section
4539 in the GDB user manual.
4540
50c97f38
TT
4541* Guile support was removed.
4542
448a92bf
MF
4543* New features in the GNU simulator
4544
4545 ** The --map-info flag lists all known core mappings.
4546
66ee2731
MF
4547 ** CFI flashes may be simulated via the "cfi" device.
4548
76b8507d 4549*** Changes in GDB 7.2
bfbf3774 4550
ba25b921
PA
4551* Shared library support for remote targets by default
4552
4553 When GDB is configured for a generic, non-OS specific target, like
4554 for example, --target=arm-eabi or one of the many *-*-elf targets,
4555 GDB now queries remote stubs for loaded shared libraries using the
4556 `qXfer:libraries:read' packet. Previously, shared library support
4557 was always disabled for such configurations.
4558
4656f5c6
SW
4559* C++ Improvements:
4560
4561 ** Argument Dependent Lookup (ADL)
4562
4563 In C++ ADL lookup directs function search to the namespaces of its
4564 arguments even if the namespace has not been imported.
4565 For example:
4566 namespace A
4567 {
4568 class B { };
4569 void foo (B) { }
4570 }
4571 ...
4572 A::B b
4573 foo(b)
4574 Here the compiler will search for `foo' in the namespace of 'b'
4575 and find A::foo. GDB now supports this. This construct is commonly
4576 used in the Standard Template Library for operators.
4577
4578 ** Improved User Defined Operator Support
4579
4580 In addition to member operators, GDB now supports lookup of operators
4581 defined in a namespace and imported with a `using' directive, operators
4582 defined in the global scope, operators imported implicitly from an
4583 anonymous namespace, and the ADL operators mentioned in the previous
4584 entry.
4585 GDB now also supports proper overload resolution for all the previously
4586 mentioned flavors of operators.
4587
254e6b9e
DE
4588 ** static const class members
4589
4590 Printing of static const class members that are initialized in the
4591 class definition has been fixed.
4592
711e434b
PM
4593* Windows Thread Information Block access.
4594
4595 On Windows targets, GDB now supports displaying the Windows Thread
4596 Information Block (TIB) structure. This structure is visible either
4597 by using the new command `info w32 thread-information-block' or, by
4598 dereferencing the new convenience variable named `$_tlb', a
4599 thread-specific pointer to the TIB. This feature is also supported
4600 when remote debugging using GDBserver.
4601
0fb4aa4b
PA
4602* Static tracepoints
4603
4604 Static tracepoints are calls in the user program into a tracing
4605 library. One such library is a port of the LTTng kernel tracer to
4606 userspace --- UST (LTTng Userspace Tracer, http://lttng.org/ust).
4607 When debugging with GDBserver, GDB now supports combining the GDB
4608 tracepoint machinery with such libraries. For example: the user can
4609 use GDB to probe a static tracepoint marker (a call from the user
4610 program into the tracing library) with the new "strace" command (see
4611 "New commands" below). This creates a "static tracepoint" in the
4612 breakpoint list, that can be manipulated with the same feature set
4613 as fast and regular tracepoints. E.g., collect registers, local and
4614 global variables, collect trace state variables, and define
4615 tracepoint conditions. In addition, the user can collect extra
4616 static tracepoint marker specific data, by collecting the new
4617 $_sdata internal variable. When analyzing the trace buffer, you can
4618 inspect $_sdata like any other variable available to GDB. For more
4619 information, see the "Tracepoints" chapter in GDB user manual. New
4620 remote packets have been defined to support static tracepoints, see
4621 the "New remote packets" section below.
4622
ca11e899
SS
4623* Better reconstruction of tracepoints after disconnected tracing
4624
4625 GDB will attempt to download the original source form of tracepoint
4626 definitions when starting a trace run, and then will upload these
4627 upon reconnection to the target, resulting in a more accurate
4628 reconstruction of the tracepoints that are in use on the target.
4629
4630* Observer mode
4631
4632 You can now exercise direct control over the ways that GDB can
4633 affect your program. For instance, you can disallow the setting of
4634 breakpoints, so that the program can run continuously (assuming
4635 non-stop mode). In addition, the "observer" variable is available
4636 to switch all of the different controls; in observer mode, GDB
4637 cannot affect the target's behavior at all, which is useful for
4638 tasks like diagnosing live systems in the field.
4639
4640* The new convenience variable $_thread holds the number of the
4641 current thread.
4642
711e434b
PM
4643* New remote packets
4644
4645qGetTIBAddr
4646
4647 Return the address of the Windows Thread Information Block of a given thread.
4648
dde08ee1
PA
4649qRelocInsn
4650
4651 In response to several of the tracepoint packets, the target may now
4652 also respond with a number of intermediate `qRelocInsn' request
4653 packets before the final result packet, to have GDB handle
4654 relocating an instruction to execute at a different address. This
4655 is particularly useful for stubs that support fast tracepoints. GDB
4656 reports support for this feature in the qSupported packet.
4657
0fb4aa4b
PA
4658qTfSTM, qTsSTM
4659
4660 List static tracepoint markers in the target program.
4661
4662qTSTMat
4663
4664 List static tracepoint markers at a given address in the target
4665 program.
4666
4667qXfer:statictrace:read
4668
4669 Read the static trace data collected (by a `collect $_sdata'
4670 tracepoint action). The remote stub reports support for this packet
4671 to gdb's qSupported query.
4672
ca11e899
SS
4673QAllow
4674
4675 Send the current settings of GDB's permission flags.
4676
4677QTDPsrc
4678
4679 Send part of the source (textual) form of a tracepoint definition,
4680 which includes location, conditional, and action list.
4681
3f7b2faa
DE
4682* The source command now accepts a -s option to force searching for the
4683 script in the source search path even if the script name specifies
4684 a directory.
4685
d337e9f0
PA
4686* New features in the GDB remote stub, GDBserver
4687
0fb4aa4b
PA
4688 - GDBserver now support tracepoints (including fast tracepoints, and
4689 static tracepoints). The feature is currently supported by the
4690 i386-linux and amd64-linux builds. See the "Tracepoints support
4691 in gdbserver" section in the manual for more information.
4692
4693 GDBserver JIT compiles the tracepoint's conditional agent
4694 expression bytecode into native code whenever possible for low
4695 overhead dynamic tracepoints conditionals. For such tracepoints,
4696 an expression that examines program state is evaluated when the
4697 tracepoint is reached, in order to determine whether to capture
4698 trace data. If the condition is simple and false, processing the
4699 tracepoint finishes very quickly and no data is gathered.
4700
4701 GDBserver interfaces with the UST (LTTng Userspace Tracer) library
4702 for static tracepoints support.
d337e9f0 4703
c24d0242
PM
4704 - GDBserver now supports x86_64 Windows 64-bit debugging.
4705
c8d5aac9
L
4706* GDB now sends xmlRegisters= in qSupported packet to indicate that
4707 it understands register description.
4708
7c953934
TT
4709* The --batch flag now disables pagination and queries.
4710
8685c86f
L
4711* X86 general purpose registers
4712
4713 GDB now supports reading/writing byte, word and double-word x86
4714 general purpose registers directly. This means you can use, say,
4715 $ah or $ax to refer, respectively, to the byte register AH and
4716 16-bit word register AX that are actually portions of the 32-bit
4717 register EAX or 64-bit register RAX.
4718
95a42b64 4719* The `commands' command now accepts a range of breakpoints to modify.
86b17b60
PA
4720 A plain `commands' following a command that creates multiple
4721 breakpoints affects all the breakpoints set by that command. This
4722 applies to breakpoints set by `rbreak', and also applies when a
4723 single `break' command creates multiple breakpoints (e.g.,
4724 breakpoints on overloaded c++ functions).
95a42b64 4725
8bd10a10
CM
4726* The `rbreak' command now accepts a filename specification as part of
4727 its argument, limiting the functions selected by the regex to those
4728 in the specified file.
4729
ab38a727
PA
4730* Support for remote debugging Windows and SymbianOS shared libraries
4731 from Unix hosts has been improved. Non Windows GDB builds now can
4732 understand target reported file names that follow MS-DOS based file
4733 system semantics, such as file names that include drive letters and
4734 use the backslash character as directory separator. This makes it
4735 possible to transparently use the "set sysroot" and "set
4736 solib-search-path" on Unix hosts to point as host copies of the
4737 target's shared libraries. See the new command "set
4738 target-file-system-kind" described below, and the "Commands to
4739 specify files" section in the user manual for more information.
4740
6149aea9
PA
4741* New commands
4742
f1421989
HZ
4743eval template, expressions...
4744 Convert the values of one or more expressions under the control
4745 of the string template to a command line, and call it.
4746
ab38a727
PA
4747set target-file-system-kind unix|dos-based|auto
4748show target-file-system-kind
4749 Set or show the assumed file system kind for target reported file
4750 names.
4751
6149aea9
PA
4752save breakpoints <filename>
4753 Save all current breakpoint definitions to a file suitable for use
4754 in a later debugging session. To read the saved breakpoint
4755 definitions, use the `source' command.
4756
4757`save tracepoints' is a new alias for `save-tracepoints'. The latter
4758is now deprecated.
4759
0fb4aa4b
PA
4760info static-tracepoint-markers
4761 Display information about static tracepoint markers in the target.
4762
4763strace FN | FILE:LINE | *ADDR | -m MARKER_ID
4764 Define a static tracepoint by probing a marker at the given
4765 function, line, address, or marker ID.
4766
ca11e899
SS
4767set observer on|off
4768show observer
4769 Enable and disable observer mode.
4770
4771set may-write-registers on|off
4772set may-write-memory on|off
4773set may-insert-breakpoints on|off
4774set may-insert-tracepoints on|off
4775set may-insert-fast-tracepoints on|off
4776set may-interrupt on|off
4777 Set individual permissions for GDB effects on the target. Note that
4778 some of these settings can have undesirable or surprising
4779 consequences, particularly when changed in the middle of a session.
4780 For instance, disabling the writing of memory can prevent
4781 breakpoints from being inserted, cause single-stepping to fail, or
4782 even crash your program, if you disable after breakpoints have been
4783 inserted. However, GDB should not crash.
4784
4785set record memory-query on|off
4786show record memory-query
4787 Control whether to stop the inferior if memory changes caused
4788 by an instruction cannot be recorded.
4789
53a71c06
CR
4790* Changed commands
4791
4792disassemble
4793 The disassemble command now supports "start,+length" form of two arguments.
4794
f3e9a817
PM
4795* Python scripting
4796
9279c692
JB
4797** GDB now provides a new directory location, called the python directory,
4798 where Python scripts written for GDB can be installed. The location
4799 of that directory is <data-directory>/python, where <data-directory>
4800 is the GDB data directory. For more details, see section `Scripting
4801 GDB using Python' in the manual.
4802
adc36818 4803** The GDB Python API now has access to breakpoints, symbols, symbol
595939de
PM
4804 tables, program spaces, inferiors, threads and frame's code blocks.
4805 Additionally, GDB Parameters can now be created from the API, and
4806 manipulated via set/show in the CLI.
f870a310 4807
fa33c3cd 4808** New functions gdb.target_charset, gdb.target_wide_charset,
07ca107c
DE
4809 gdb.progspaces, gdb.current_progspace, and gdb.string_to_argv.
4810
4811** New exception gdb.GdbError.
fa33c3cd
DE
4812
4813** Pretty-printers are now also looked up in the current program space.
f3e9a817 4814
967cf477
DE
4815** Pretty-printers can now be individually enabled and disabled.
4816
8a1ea21f
DE
4817** GDB now looks for names of Python scripts to auto-load in a
4818 special section named `.debug_gdb_scripts', in addition to looking
4819 for a OBJFILE-gdb.py script when OBJFILE is read by the debugger.
4820
a7bdde9e
VP
4821* Tracepoint actions were unified with breakpoint commands. In particular,
4822there are no longer differences in "info break" output for breakpoints and
4823tracepoints and the "commands" command can be used for both tracepoints and
4824regular breakpoints.
4825
05071a4d
PA
4826* New targets
4827
4828ARM Symbian arm*-*-symbianelf*
4829
6aecb9c2
JB
4830* D language support.
4831 GDB now supports debugging programs written in the D programming
4832 language.
4833
431e49aa
TJB
4834* GDB now supports the extended ptrace interface for PowerPC which is
4835 available since Linux kernel version 2.6.34. This automatically enables
4836 any hardware breakpoints and additional hardware watchpoints available in
4837 the processor. The old ptrace interface exposes just one hardware
4838 watchpoint and no hardware breakpoints.
4839
4840* GDB is now able to use the Data Value Compare (DVC) register available on
4841 embedded PowerPC processors to implement in hardware simple watchpoint
4842 conditions of the form:
4843
4844 watch ADDRESS|VARIABLE if ADDRESS|VARIABLE == CONSTANT EXPRESSION
4845
4846 This works in native GDB running on Linux kernels with the extended ptrace
4847 interface mentioned above.
4848
bfbf3774 4849*** Changes in GDB 7.1
abc7453d 4850
4eef138c
TT
4851* C++ Improvements
4852
4853 ** Namespace Support
71dee663
SW
4854
4855 GDB now supports importing of namespaces in C++. This enables the
4856 user to inspect variables from imported namespaces. Support for
4857 namepace aliasing has also been added. So, if a namespace is
4858 aliased in the current scope (e.g. namepace C=A; ) the user can
4859 print variables using the alias (e.g. (gdb) print C::x).
4860
4eef138c
TT
4861 ** Bug Fixes
4862
4863 All known bugs relating to the printing of virtual base class were
4864 fixed. It is now possible to call overloaded static methods using a
4865 qualified name.
4866
4867 ** Cast Operators
4868
4869 The C++ cast operators static_cast<>, dynamic_cast<>, const_cast<>,
4870 and reinterpret_cast<> are now handled by the C++ expression parser.
4871
2d1c1221
ME
4872* New targets
4873
4874Xilinx MicroBlaze microblaze-*-*
34207b9e 4875Renesas RX rx-*-elf
2d1c1221
ME
4876
4877* New Simulators
4878
4879Xilinx MicroBlaze microblaze
34207b9e 4880Renesas RX rx
2d1c1221 4881
6c95b8df
PA
4882* Multi-program debugging.
4883
4884 GDB now has support for multi-program (a.k.a. multi-executable or
4885 multi-exec) debugging. This allows for debugging multiple inferiors
4886 simultaneously each running a different program under the same GDB
4887 session. See "Debugging Multiple Inferiors and Programs" in the
4888 manual for more information. This implied some user visible changes
4889 in the multi-inferior support. For example, "info inferiors" now
4890 lists inferiors that are not running yet or that have exited
4891 already. See also "New commands" and "New options" below.
4892
d5551862
SS
4893* New tracing features
4894
4895 GDB's tracepoint facility now includes several new features:
4896
4897 ** Trace state variables
f61e138d
SS
4898
4899 GDB tracepoints now include support for trace state variables, which
4900 are variables managed by the target agent during a tracing
4901 experiment. They are useful for tracepoints that trigger each
4902 other, so for instance one tracepoint can count hits in a variable,
4903 and then a second tracepoint has a condition that is true when the
4904 count reaches a particular value. Trace state variables share the
4905 $-syntax of GDB convenience variables, and can appear in both
4906 tracepoint actions and condition expressions. Use the "tvariable"
4907 command to create, and "info tvariables" to view; see "Trace State
4908 Variables" in the manual for more detail.
7a697b8d 4909
d5551862 4910 ** Fast tracepoints
7a697b8d
SS
4911
4912 GDB now includes an option for defining fast tracepoints, which
4913 targets may implement more efficiently, such as by installing a jump
4914 into the target agent rather than a trap instruction. The resulting
4915 speedup can be by two orders of magnitude or more, although the
4916 tradeoff is that some program locations on some target architectures
4917 might not allow fast tracepoint installation, for instance if the
4918 instruction to be replaced is shorter than the jump. To request a
4919 fast tracepoint, use the "ftrace" command, with syntax identical to
4920 the regular trace command.
4921
d5551862
SS
4922 ** Disconnected tracing
4923
4924 It is now possible to detach GDB from the target while it is running
4925 a trace experiment, then reconnect later to see how the experiment
4926 is going. In addition, a new variable disconnected-tracing lets you
4927 tell the target agent whether to continue running a trace if the
4928 connection is lost unexpectedly.
4929
00bf0b85
SS
4930 ** Trace files
4931
4932 GDB now has the ability to save the trace buffer into a file, and
4933 then use that file as a target, similarly to you can do with
4934 corefiles. You can select trace frames, print data that was
4935 collected in them, and use tstatus to display the state of the
4936 tracing run at the moment that it was saved. To create a trace
4937 file, use "tsave <filename>", and to use it, do "target tfile
4938 <name>".
4daf5ac0
SS
4939
4940 ** Circular trace buffer
4941
4942 You can ask the target agent to handle the trace buffer as a
4943 circular buffer, discarding the oldest trace frames to make room for
4944 newer ones, by setting circular-trace-buffer to on. This feature may
4945 not be available for all target agents.
4946
21a0512e
PP
4947* Changed commands
4948
4949disassemble
4950 The disassemble command, when invoked with two arguments, now requires
4951 the arguments to be comma-separated.
4952
0fe7935b
DJ
4953info variables
4954 The info variables command now displays variable definitions. Files
4955 which only declare a variable are not shown.
4956
fb2e7cb4
JB
4957source
4958 The source command is now capable of sourcing Python scripts.
4959 This feature is dependent on the debugger being build with Python
4960 support.
4961
4962 Related to this enhancement is also the introduction of a new command
4963 "set script-extension" (see below).
4964
6c95b8df
PA
4965* New commands (for set/show, see "New options" below)
4966
399cd161
MS
4967record save [<FILENAME>]
4968 Save a file (in core file format) containing the process record
4969 execution log for replay debugging at a later time.
4970
4971record restore <FILENAME>
4972 Restore the process record execution log that was saved at an
4973 earlier time, for replay debugging.
4974
6c95b8df
PA
4975add-inferior [-copies <N>] [-exec <FILENAME>]
4976 Add a new inferior.
4977
4978clone-inferior [-copies <N>] [ID]
4979 Make a new inferior ready to execute the same program another
4980 inferior has loaded.
4981
4982remove-inferior ID
4983 Remove an inferior.
4984
4985maint info program-spaces
4986 List the program spaces loaded into GDB.
4987
9a7071a8
JB
4988set remote interrupt-sequence [Ctrl-C | BREAK | BREAK-g]
4989show remote interrupt-sequence
4990 Allow the user to select one of ^C, a BREAK signal or BREAK-g
4991 as the sequence to the remote target in order to interrupt the execution.
4992 Ctrl-C is a default. Some system prefers BREAK which is high level of
4993 serial line for some certain time. Linux kernel prefers BREAK-g, a.k.a
4994 Magic SysRq g. It is BREAK signal and character 'g'.
4995
4996set remote interrupt-on-connect [on | off]
4997show remote interrupt-on-connect
4998 When interrupt-on-connect is ON, gdb sends interrupt-sequence to
4999 remote target when gdb connects to it. This is needed when you debug
5000 Linux kernel.
5001
5002set remotebreak [on | off]
5003show remotebreak
5004Deprecated. Use "set/show remote interrupt-sequence" instead.
5005
f61e138d
SS
5006tvariable $NAME [ = EXP ]
5007 Create or modify a trace state variable.
5008
5009info tvariables
5010 List trace state variables and their values.
5011
5012delete tvariable $NAME ...
5013 Delete one or more trace state variables.
5014
6da95a67
SS
5015teval EXPR, ...
5016 Evaluate the given expressions without collecting anything into the
5017 trace buffer. (Valid in tracepoint actions only.)
5018
7a697b8d
SS
5019ftrace FN / FILE:LINE / *ADDR
5020 Define a fast tracepoint at the given function, line, or address.
5021
b0f02ee9
JK
5022* New expression syntax
5023
5024 GDB now parses the 0b prefix of binary numbers the same way as GCC does.
5025 GDB now parses 0b101010 identically with 42.
5026
6c95b8df
PA
5027* New options
5028
5029set follow-exec-mode new|same
5030show follow-exec-mode
5031 Control whether GDB reuses the same inferior across an exec call or
5032 creates a new one. This is useful to be able to restart the old
5033 executable after the inferior having done an exec call.
5034
236f1d4d
SS
5035set default-collect EXPR, ...
5036show default-collect
5037 Define a list of expressions to be collected at each tracepoint.
5038 This is a useful way to ensure essential items are not overlooked,
5039 such as registers or a critical global variable.
5040
d5551862
SS
5041set disconnected-tracing
5042show disconnected-tracing
5043 If set to 1, the target is instructed to continue tracing if it
5044 loses its connection to GDB. If 0, the target is to stop tracing
5045 upon disconnection.
5046
4daf5ac0
SS
5047set circular-trace-buffer
5048show circular-trace-buffer
5049 If set to on, the target is instructed to use a circular trace buffer
5050 and discard the oldest trace frames instead of stopping the trace due
5051 to a full trace buffer. If set to off, the trace stops when the buffer
5052 fills up. Some targets may not support this.
5053
fb2e7cb4
JB
5054set script-extension off|soft|strict
5055show script-extension
5056 If set to "off", the debugger does not perform any script language
5057 recognition, and all sourced files are assumed to be GDB scripts.
5058 If set to "soft" (the default), files are sourced according to
5059 filename extension, falling back to GDB scripts if the first
5060 evaluation failed.
5061 If set to "strict", files are sourced according to filename extension.
5062
2b71fc8e
JB
5063set ada trust-PAD-over-XVS on|off
5064show ada trust-PAD-over-XVS
5065 If off, activate a workaround against a bug in the debugging information
5066 generated by the compiler for PAD types (see gcc/exp_dbug.ads in
5067 the GCC sources for more information about the GNAT encoding and
5068 PAD types in particular). It is always safe to set this option to
5069 off, but this introduces a slight performance penalty. The default
5070 is on.
5071
de2e5182
TT
5072* Python API Improvements
5073
5074 ** GDB provides the new class gdb.LazyString. This is useful in
5075 some pretty-printing cases. The new method gdb.Value.lazy_string
5076 provides a simple way to create objects of this type.
5077
5078 ** The fields returned by gdb.Type.fields now have an
5079 `is_base_class' attribute.
5080
5081 ** The new method gdb.Type.range returns the range of an array type.
5082
5083 ** The new method gdb.parse_and_eval can be used to parse and
5084 evaluate an expression.
5085
f61e138d
SS
5086* New remote packets
5087
5088QTDV
5089 Define a trace state variable.
5090
5091qTV
5092 Get the current value of a trace state variable.
5093
d5551862
SS
5094QTDisconnected
5095 Set desired tracing behavior upon disconnection.
5096
4daf5ac0
SS
5097QTBuffer:circular
5098 Set the trace buffer to be linear or circular.
5099
d5551862
SS
5100qTfP, qTsP
5101 Get data about the tracepoints currently in use.
5102
2d483d34
MS
5103* Bug fixes
5104
5105Process record now works correctly with hardware watchpoints.
5106
6e0e5977
JB
5107Multiple bug fixes have been made to the mips-irix port, making it
5108much more reliable. In particular:
5109 - Debugging threaded applications is now possible again. Previously,
5110 GDB would hang while starting the program, or while waiting for
5111 the program to stop at a breakpoint.
5112 - Attaching to a running process no longer hangs.
5113 - An error occurring while loading a core file has been fixed.
5114 - Changing the value of the PC register now works again. This fixes
5115 problems observed when using the "jump" command, or when calling
5116 a function from GDB, or even when assigning a new value to $pc.
5117 - With the "finish" and "return" commands, the return value for functions
5118 returning a small array is now correctly printed.
5119 - It is now possible to break on shared library code which gets executed
5120 during a shared library init phase (code executed while executing
5121 their .init section). Previously, the breakpoint would have no effect.
5122 - GDB is now able to backtrace through the signal handler for
5123 non-threaded programs.
5124
93c26624
JK
5125PIE (Position Independent Executable) programs debugging is now supported.
5126This includes debugging execution of PIC (Position Independent Code) shared
5127libraries although for that, it should be possible to run such libraries as an
5128executable program.
5129
abc7453d 5130*** Changes in GDB 7.0
75feb17d 5131
4efc6507
DE
5132* GDB now has an interface for JIT compilation. Applications that
5133dynamically generate code can create symbol files in memory and register
5134them with GDB. For users, the feature should work transparently, and
5135for JIT developers, the interface is documented in the GDB manual in the
5136"JIT Compilation Interface" chapter.
5137
782b2b07
SS
5138* Tracepoints may now be conditional. The syntax is as for
5139breakpoints; either an "if" clause appended to the "trace" command,
5140or the "condition" command is available. GDB sends the condition to
5141the target for evaluation using the same bytecode format as is used
5142for tracepoint actions.
5143
53a71c06
CR
5144* The disassemble command now supports: an optional /r modifier, print the
5145raw instructions in hex as well as in symbolic form, and an optional /m
5146modifier to print mixed source+assembly.
e6158f16 5147
e7a8dbfb
HZ
5148* Process record and replay
5149
5150 In a architecture environment that supports ``process record and
5151 replay'', ``process record and replay'' target can record a log of
5152 the process execution, and replay it with both forward and reverse
5153 execute commands.
5154
64644d9b
MS
5155* Reverse debugging: GDB now has new commands reverse-continue, reverse-
5156step, reverse-next, reverse-finish, reverse-stepi, reverse-nexti, and
5157set execution-direction {forward|reverse}, for targets that support
5158reverse execution.
5159
b9412953
DD
5160* GDB now supports hardware watchpoints on MIPS/Linux systems. This
5161feature is available with a native GDB running on kernel version
51622.6.28 or later.
5163
6c7a06a3
TT
5164* GDB now has support for multi-byte and wide character sets on the
5165target. Strings whose character type is wchar_t, char16_t, or
5166char32_t are now correctly printed. GDB supports wide- and unicode-
5167literals in C, that is, L'x', L"string", u'x', u"string", U'x', and
5168U"string" syntax. And, GDB allows the "%ls" and "%lc" formats in
5169`printf'. This feature requires iconv to work properly; if your
5170system does not have a working iconv, GDB can use GNU libiconv. See
5171the installation instructions for more information.
5172
f1838a98
UW
5173* GDB now supports automatic retrieval of shared library files from
5174remote targets. To use this feature, specify a system root that begins
5175with the `remote:' prefix, either via the `set sysroot' command or via
5176the `--with-sysroot' configure-time option.
5177
55333a84
DE
5178* "info sharedlibrary" now takes an optional regex of libraries to show,
5179and it now reports if a shared library has no debugging information.
5180
7f6a6314
PM
5181* Commands `set debug-file-directory', `set solib-search-path' and `set args'
5182now complete on file names.
5183
65d12d83
TT
5184* When completing in expressions, gdb will attempt to limit
5185completions to allowable structure or union fields, where appropriate.
5186For instance, consider:
5187
5188 # struct example { int f1; double f2; };
5189 # struct example variable;
5190 (gdb) p variable.
5191
5192If the user types TAB at the end of this command line, the available
5193completions will be "f1" and "f2".
5194
edb3359d
DJ
5195* Inlined functions are now supported. They show up in backtraces, and
5196the "step", "next", and "finish" commands handle them automatically.
5197
2fae03e8
TT
5198* GDB now supports the token-splicing (##) and stringification (#)
5199operators when expanding macros. It also supports variable-arity
5200macros.
5201
47a3467a 5202* GDB now supports inspecting extra signal information, exported by
58d6951d
DJ
5203the new $_siginfo convenience variable. The feature is currently
5204implemented on linux ARM, i386 and amd64.
5205
5206* GDB can now display the VFP floating point registers and NEON vector
5207registers on ARM targets. Both ARM GNU/Linux native GDB and gdbserver
5208can provide these registers (requires Linux 2.6.30 or later). Remote
5209and simulator targets may also provide them.
47a3467a 5210
08388c79
DE
5211* New remote packets
5212
5213qSearch:memory:
5214 Search memory for a sequence of bytes.
5215
a6f3e723
SL
5216QStartNoAckMode
5217 Turn off `+'/`-' protocol acknowledgments to permit more efficient
5218 operation over reliable transport links. Use of this packet is
5219 controlled by the `set remote noack-packet' command.
5220
d7713ae0
EZ
5221vKill
5222 Kill the process with the specified process ID. Use this in preference
5223 to `k' when multiprocess protocol extensions are supported.
5224
07e059b5
VP
5225qXfer:osdata:read
5226 Obtains additional operating system information
5227
47a3467a
PA
5228qXfer:siginfo:read
5229qXfer:siginfo:write
5230 Read or write additional signal information.
5231
060871df
PA
5232* Removed remote protocol undocumented extension
5233
5234 An undocumented extension to the remote protocol's `S' stop reply
82f06518 5235 packet that permitted the stub to pass a process id was removed.
060871df
PA
5236 Remote servers should use the `T' stop reply packet instead.
5237
c055b101 5238* GDB now supports multiple function calling conventions according to the
a0ef4274 5239DWARF-2 DW_AT_calling_convention function attribute.
c055b101
CV
5240
5241* The SH target utilizes the aforementioned change to distinguish between gcc
a0ef4274
DJ
5242and Renesas calling convention. It also adds the new CLI commands
5243`set/show sh calling-convention'.
c055b101 5244
31fffb02
CS
5245* GDB can now read compressed debug sections, as produced by GNU gold
5246with the --compress-debug-sections=zlib flag.
5247
88d8a8e0
JB
5248* 64-bit core files are now supported on AIX.
5249
7f99b190
JB
5250* Thread switching is now supported on Tru64.
5251
ccd213ac
DJ
5252* Watchpoints can now be set on unreadable memory locations, e.g. addresses
5253which will be allocated using malloc later in program execution.
5254
82f06518 5255* The qXfer:libraries:read remote protocol packet now allows passing a
31fffb02 5256list of section offsets.
1fddbabb 5257
a0ef4274
DJ
5258* On GNU/Linux, GDB can now attach to stopped processes. Several race
5259conditions handling signals delivered during attach or thread creation
5260have also been fixed.
5261
bfb8797a 5262* GDB now supports the use of DWARF boolean types for Ada's type Boolean.
158c7665
PH
5263From the user's standpoint, all unqualified instances of True and False
5264are treated as the standard definitions, regardless of context.
bfb8797a 5265
71c25dea
TT
5266* GDB now parses C++ symbol and type names more flexibly. For
5267example, given:
5268
5269 template<typename T> class C { };
5270 C<char const *> c;
5271
5272GDB will now correctly handle all of:
5273
5274 ptype C<char const *>
5275 ptype C<char const*>
5276 ptype C<const char *>
5277 ptype C<const char*>
5278
ccd213ac
DJ
5279* New features in the GDB remote stub, gdbserver
5280
5281 - The "--wrapper" command-line argument tells gdbserver to use a
5282 wrapper program to launch programs for debugging.
5283
7ae0e2a2
UW
5284 - On PowerPC and S/390 targets, it is now possible to use a single
5285 gdbserver executable to debug both 32-bit and 64-bit programs.
5286 (This requires gdbserver itself to be built as a 64-bit executable.)
5287
a6f3e723
SL
5288 - gdbserver uses the new noack protocol mode for TCP connections to
5289 reduce communications latency, if also supported and enabled in GDB.
5290
da8bd9a3
DJ
5291 - Support for the sparc64-linux-gnu target is now included in
5292 gdbserver.
5293
d70e31dd
DE
5294 - The amd64-linux build of gdbserver now supports debugging both
5295 32-bit and 64-bit programs.
5296
5297 - The i386-linux, amd64-linux, and i386-win32 builds of gdbserver
5298 now support hardware watchpoints, and will use them automatically
5299 as appropriate.
5300
d57a3c85
TJB
5301* Python scripting
5302
5303 GDB now has support for scripting using Python. Whether this is
5304 available is determined at configure time.
5305
d8906c6f
TJB
5306 New GDB commands can now be written in Python.
5307
aadc346a
JB
5308* Ada tasking support
5309
5310 Ada tasks can now be inspected in GDB. The following commands have
5311 been introduced:
5312
5313 info tasks
5314 Print the list of Ada tasks.
5315 info task N
5316 Print detailed information about task number N.
5317 task
5318 Print the task number of the current task.
5319 task N
5320 Switch the context of debugging to task number N.
5321
adb483fe
DJ
5322* Support for user-defined prefixed commands. The "define" command can
5323add new commands to existing prefixes, e.g. "target".
5324
2277426b
PA
5325* Multi-inferior, multi-process debugging.
5326
5327 GDB now has generalized support for multi-inferior debugging. See
5328 "Debugging Multiple Inferiors" in the manual for more information.
5329 Although availability still depends on target support, the command
5330 set is more uniform now. The GNU/Linux specific multi-forks support
5331 has been migrated to this new framework. This implied some user
5332 visible changes; see "New commands" and also "Removed commands"
5333 below.
5334
08d16641
PA
5335* Target descriptions can now describe the target OS ABI. See the
5336"Target Description Format" section in the user manual for more
5337information.
5338
e35359c5
UW
5339* Target descriptions can now describe "compatible" architectures
5340to indicate that the target can execute applications for a different
5341architecture in addition to those for the main target architecture.
5342See the "Target Description Format" section in the user manual for
5343more information.
5344
85e747d2
UW
5345* Multi-architecture debugging.
5346
5347 GDB now includes general supports for debugging applications on
5348 hybrid systems that use more than one single processor architecture
5349 at the same time. Each such hybrid architecture still requires
5350 specific support to be added. The only hybrid architecture supported
5351 in this version of GDB is the Cell Broadband Engine.
5352
5353* GDB now supports integrated debugging of Cell/B.E. applications that
5354use both the PPU and SPU architectures. To enable support for hybrid
5355Cell/B.E. debugging, you need to configure GDB to support both the
5356powerpc-linux or powerpc64-linux and the spu-elf targets, using the
5357--enable-targets configure option.
5358
11ade57a
PA
5359* Non-stop mode debugging.
5360
5361 For some targets, GDB now supports an optional mode of operation in
5362 which you can examine stopped threads while other threads continue
5363 to execute freely. This is referred to as non-stop mode, with the
5364 old mode referred to as all-stop mode. See the "Non-Stop Mode"
5365 section in the user manual for more information.
5366
5367 To be able to support remote non-stop debugging, a remote stub needs
5368 to implement the non-stop mode remote protocol extensions, as
5369 described in the "Remote Non-Stop" section of the user manual. The
5370 GDB remote stub, gdbserver, has been adjusted to support these
5371 extensions on linux targets.
5372
d7713ae0 5373* New commands (for set/show, see "New options" below)
75feb17d 5374
a96d9b2e
SDJ
5375catch syscall [NAME(S) | NUMBER(S)]
5376 Catch system calls. Arguments, which should be names of system
5377 calls or their numbers, mean catch only those syscalls. Without
5378 arguments, every syscall will be caught. When the inferior issues
5379 any of the specified syscalls, GDB will stop and announce the system
5380 call, both when it is called and when its call returns. This
5381 feature is currently available with a native GDB running on the
5382 Linux Kernel, under the following architectures: x86, x86_64,
5383 PowerPC and PowerPC64.
5384
08388c79
DE
5385find [/size-char] [/max-count] start-address, end-address|+search-space-size,
5386 val1 [, val2, ...]
5387 Search memory for a sequence of bytes.
5388
d57a3c85
TJB
5389maint set python print-stack
5390maint show python print-stack
5391 Show a stack trace when an error is encountered in a Python script.
5392
5393python [CODE]
5394 Invoke CODE by passing it to the Python interpreter.
5395
d7713ae0
EZ
5396macro define
5397macro list
5398macro undef
5399 These allow macros to be defined, undefined, and listed
5400 interactively.
5401
5402info os processes
5403 Show operating system information about processes.
5404
2277426b
PA
5405info inferiors
5406 List the inferiors currently under GDB's control.
5407
5408inferior NUM
5409 Switch focus to inferior number NUM.
5410
5411detach inferior NUM
5412 Detach from inferior number NUM.
5413
5414kill inferior NUM
5415 Kill inferior number NUM.
5416
d7713ae0
EZ
5417* New options
5418
3285f3fe
UW
5419set spu stop-on-load
5420show spu stop-on-load
5421 Control whether to stop for new SPE threads during Cell/B.E. debugging.
5422
ff1a52c6
UW
5423set spu auto-flush-cache
5424show spu auto-flush-cache
5425 Control whether to automatically flush the software-managed cache
5426 during Cell/B.E. debugging.
5427
d7713ae0
EZ
5428set sh calling-convention
5429show sh calling-convention
5430 Control the calling convention used when calling SH target functions.
5431
e0a3ce09 5432set debug timestamp
75feb17d 5433show debug timestamp
d7713ae0
EZ
5434 Control display of timestamps with GDB debugging output.
5435
5436set disassemble-next-line
5437show disassemble-next-line
5438 Control display of disassembled source lines or instructions when
5439 the debuggee stops.
5440
5441set remote noack-packet
5442show remote noack-packet
5443 Set/show the use of remote protocol QStartNoAckMode packet. See above
5444 under "New remote packets."
5445
5446set remote query-attached-packet
5447show remote query-attached-packet
5448 Control use of remote protocol `qAttached' (query-attached) packet.
5449
5450set remote read-siginfo-object
5451show remote read-siginfo-object
5452 Control use of remote protocol `qXfer:siginfo:read' (read-siginfo-object)
5453 packet.
5454
5455set remote write-siginfo-object
5456show remote write-siginfo-object
5457 Control use of remote protocol `qXfer:siginfo:write' (write-siginfo-object)
5458 packet.
5459
40ab02ce
MS
5460set remote reverse-continue
5461show remote reverse-continue
5462 Control use of remote protocol 'bc' (reverse-continue) packet.
5463
5464set remote reverse-step
5465show remote reverse-step
5466 Control use of remote protocol 'bs' (reverse-step) packet.
5467
d7713ae0
EZ
5468set displaced-stepping
5469show displaced-stepping
5470 Control displaced stepping mode. Displaced stepping is a way to
5471 single-step over breakpoints without removing them from the debuggee.
5472 Also known as "out-of-line single-stepping".
5473
5474set debug displaced
5475show debug displaced
5476 Control display of debugging info for displaced stepping.
5477
5478maint set internal-error
5479maint show internal-error
5480 Control what GDB does when an internal error is detected.
5481
5482maint set internal-warning
5483maint show internal-warning
5484 Control what GDB does when an internal warning is detected.
75feb17d 5485
ccd213ac
DJ
5486set exec-wrapper
5487show exec-wrapper
5488unset exec-wrapper
5489 Use a wrapper program to launch programs for debugging.
fa4727a6 5490
aad4b048
JB
5491set multiple-symbols (all|ask|cancel)
5492show multiple-symbols
5493 The value of this variable can be changed to adjust the debugger behavior
5494 when an expression or a breakpoint location contains an ambiguous symbol
5495 name (an overloaded function name, for instance).
5496
74960c60
VP
5497set breakpoint always-inserted
5498show breakpoint always-inserted
5499 Keep breakpoints always inserted in the target, as opposed to inserting
5500 them when resuming the target, and removing them when the target stops.
5501 This option can improve debugger performance on slow remote targets.
5502
0428b8f5
DJ
5503set arm fallback-mode (arm|thumb|auto)
5504show arm fallback-mode
5505set arm force-mode (arm|thumb|auto)
5506show arm force-mode
5507 These commands control how ARM GDB determines whether instructions
5508 are ARM or Thumb. The default for both settings is auto, which uses
5509 the current CPSR value for instructions without symbols; previous
5510 versions of GDB behaved as if "set arm fallback-mode arm".
5511
ef273377
CL
5512set arm unwind-secure-frames
5513 Enable unwinding from Non-secure to Secure mode on Cortex-M with
5514 Security extension.
5515 This can trigger security exceptions when unwinding exception stacks.
5516
10568435
JK
5517set disable-randomization
5518show disable-randomization
5519 Standalone programs run with the virtual address space randomization enabled
5520 by default on some platforms. This option keeps the addresses stable across
5521 multiple debugging sessions.
5522
d7713ae0
EZ
5523set non-stop
5524show non-stop
5525 Control whether other threads are stopped or not when some thread hits
5526 a breakpoint.
5527
b3eb342c 5528set target-async
d7713ae0 5529show target-async
b3eb342c
VP
5530 Requests that asynchronous execution is enabled in the target, if available.
5531 In this case, it's possible to resume target in the background, and interact
5532 with GDB while the target is running. "show target-async" displays the
5533 current state of asynchronous execution of the target.
5534
6c7a06a3
TT
5535set target-wide-charset
5536show target-wide-charset
5537 The target-wide-charset is the name of the character set that GDB
5538 uses when printing characters whose type is wchar_t.
5539
84603566
SL
5540set tcp auto-retry (on|off)
5541show tcp auto-retry
5542set tcp connect-timeout
5543show tcp connect-timeout
5544 These commands allow GDB to retry failed TCP connections to a remote stub
5545 with a specified timeout period; this is useful if the stub is launched
5546 in parallel with GDB but may not be ready to accept connections immediately.
5547
17a37d48
PP
5548set libthread-db-search-path
5549show libthread-db-search-path
5550 Control list of directories which GDB will search for appropriate
5551 libthread_db.
5552
d4db2f36
PA
5553set schedule-multiple (on|off)
5554show schedule-multiple
5555 Allow GDB to resume all threads of all processes or only threads of
5556 the current process.
5557
4e5d721f
DE
5558set stack-cache
5559show stack-cache
5560 Use more aggressive caching for accesses to the stack. This improves
5561 performance of remote debugging (particularly backtraces) without
5562 affecting correctness.
5563
910c5da8
JB
5564set interactive-mode (on|off|auto)
5565show interactive-mode
5566 Control whether GDB runs in interactive mode (on) or not (off).
5567 When in interactive mode, GDB waits for the user to answer all
5568 queries. Otherwise, GDB does not wait and assumes the default
5569 answer. When set to auto (the default), GDB determines which
5570 mode to use based on the stdin settings.
5571
2277426b
PA
5572* Removed commands
5573
5574info forks
5575 For program forks, this is replaced by the new more generic `info
5576 inferiors' command. To list checkpoints, you can still use the
5577 `info checkpoints' command, which was an alias for the `info forks'
5578 command.
5579
5580fork NUM
5581 Replaced by the new `inferior' command. To switch between
5582 checkpoints, you can still use the `restart' command, which was an
5583 alias for the `fork' command.
5584
5585process PID
5586 This is removed, since some targets don't have a notion of
5587 processes. To switch between processes, you can still use the
5588 `inferior' command using GDB's own inferior number.
5589
5590delete fork NUM
5591 For program forks, this is replaced by the new more generic `kill
5592 inferior' command. To delete a checkpoint, you can still use the
5593 `delete checkpoint' command, which was an alias for the `delete
5594 fork' command.
5595
5596detach fork NUM
5597 For program forks, this is replaced by the new more generic `detach
5598 inferior' command. To detach a checkpoint, you can still use the
5599 `detach checkpoint' command, which was an alias for the `detach
5600 fork' command.
5601
a80b95ba
TG
5602* New native configurations
5603
5604x86/x86_64 Darwin i[34567]86-*-darwin*
5605
b8bfd3ed
JB
5606x86_64 MinGW x86_64-*-mingw*
5607
75a2d5e7
TT
5608* New targets
5609
c28c63d8 5610Lattice Mico32 lm32-*
75a2d5e7 5611x86 DICOS i[34567]86-*-dicos*
4c1d2973 5612x86_64 DICOS x86_64-*-dicos*
5f814c3b 5613S+core 3 score-*-*
75a2d5e7 5614
6de3146c
PA
5615* The GDB remote stub, gdbserver, now supports x86 Windows CE
5616 (mingw32ce) debugging.
5617
d5cbbe6e
JB
5618* Removed commands
5619
5620catch load
5621catch unload
5622 These commands were actually not implemented on any target.
5623
75feb17d 5624*** Changes in GDB 6.8
f9ed52be 5625
af5ca30d
NH
5626* New native configurations
5627
5628NetBSD/hppa hppa*-*netbsd*
94a0e877 5629Xtensa GNU/Linux xtensa*-*-linux*
af5ca30d
NH
5630
5631* New targets
5632
5633NetBSD/hppa hppa*-*-netbsd*
82f06518 5634Xtensa GNU/Linux xtensa*-*-linux*
af5ca30d 5635
7a404eba
PA
5636* Change in command line behavior -- corefiles vs. process ids.
5637
5638 When the '-p NUMBER' or '--pid NUMBER' options are used, and
5639 attaching to process NUMBER fails, GDB no longer attempts to open a
5640 core file named NUMBER. Attaching to a program using the -c option
5641 is no longer supported. Instead, use the '-p' or '--pid' options.
5642
430ebac9
PA
5643* GDB can now be built as a native debugger for debugging Windows x86
5644(mingw32) Portable Executable (PE) programs.
5645
fe6fbf8b 5646* Pending breakpoints no longer change their number when their address
8d5f9c6f 5647is resolved.
fe6fbf8b
VP
5648
5649* GDB now supports breakpoints with multiple locations,
8d5f9c6f
DJ
5650including breakpoints on C++ constructors, inside C++ templates,
5651and in inlined functions.
fe6fbf8b 5652
10665d76
JB
5653* GDB's ability to debug optimized code has been improved. GDB more
5654accurately identifies function bodies and lexical blocks that occupy
5655more than one contiguous range of addresses.
5656
7cc46491
DJ
5657* Target descriptions can now describe registers for PowerPC.
5658
d71340b8
DJ
5659* The GDB remote stub, gdbserver, now supports the AltiVec and SPE
5660registers on PowerPC targets.
5661
523c4513
DJ
5662* The GDB remote stub, gdbserver, now supports thread debugging on GNU/Linux
5663targets even when the libthread_db library is not available.
5664
a6b151f1
DJ
5665* The GDB remote stub, gdbserver, now supports the new file transfer
5666commands (remote put, remote get, and remote delete).
5667
2d717e4f
DJ
5668* The GDB remote stub, gdbserver, now supports run and attach in
5669extended-remote mode.
5670
24a836bd 5671* hppa*64*-*-hpux11* target broken
d001be7a
DJ
5672The debugger is unable to start a program and fails with the following
5673error: "Error trying to get information about dynamic linker".
5674The gdb-6.7 release is also affected.
24a836bd 5675
d0c678e6
UW
5676* GDB now supports the --enable-targets= configure option to allow
5677building a single GDB executable that supports multiple remote
5678target architectures.
5679
d64a946d
TJB
5680* GDB now supports debugging C and C++ programs which use the
5681Decimal Floating Point extension. In addition, the PowerPC target
5682now has a set of pseudo-registers to inspect decimal float values
5683stored in two consecutive float registers.
5684
ee163bf5
VP
5685* The -break-insert MI command can optionally create pending
5686breakpoints now.
5687
b93b6ca7 5688* Improved support for debugging Ada
d001be7a
DJ
5689Many improvements to the Ada language support have been made. These
5690include:
b93b6ca7
JB
5691 - Better support for Ada2005 interface types
5692 - Improved handling of arrays and slices in general
5693 - Better support for Taft-amendment types
5694 - The '{type} ADDRESS' expression is now allowed on the left hand-side
5695 of an assignment
5696 - Improved command completion in Ada
5697 - Several bug fixes
5698
d001be7a
DJ
5699* GDB on GNU/Linux and HP/UX can now debug through "exec" of a new
5700process.
5701
a6b151f1
DJ
5702* New commands
5703
6d53d0af
JB
5704set print frame-arguments (all|scalars|none)
5705show print frame-arguments
5706 The value of this variable can be changed to control which argument
5707 values should be printed by the debugger when displaying a frame.
5708
a6b151f1
DJ
5709remote put
5710remote get
5711remote delete
5712 Transfer files to and from a remote target, and delete remote files.
5713
5714* New MI commands
5715
5716-target-file-put
5717-target-file-get
5718-target-file-delete
5719 Transfer files to and from a remote target, and delete remote files.
5720
5721* New remote packets
5722
5723vFile:open:
5724vFile:close:
5725vFile:pread:
5726vFile:pwrite:
5727vFile:unlink:
5728 Open, close, read, write, and delete files on the remote system.
d0c678e6 5729
2d717e4f
DJ
5730vAttach
5731 Attach to an existing process on the remote system, in extended-remote
5732 mode.
5733
5734vRun
5735 Run a new process on the remote system, in extended-remote mode.
5736
8d5f9c6f 5737*** Changes in GDB 6.7
6dd09645 5738
19d378fc
MS
5739* Resolved 101 resource leaks, null pointer dereferences, etc. in gdb,
5740bfd, libiberty and opcodes, as revealed by static analysis donated by
5741Coverity, Inc. (http://scan.coverity.com).
5742
3a40aaa0
UW
5743* When looking up multiply-defined global symbols, GDB will now prefer the
5744symbol definition in the current shared library if it was built using the
5745-Bsymbolic linker option.
5746
a6ec25f2
BW
5747* When the Text User Interface (TUI) is not configured, GDB will now
5748recognize the -tui command-line option and print a message that the TUI
5749is not supported.
5750
6dd09645
JB
5751* The GDB remote stub, gdbserver, now has lower overhead for high
5752frequency signals (e.g. SIGALRM) via the QPassSignals packet.
5753
c9bb8148
DJ
5754* GDB for MIPS targets now autodetects whether a remote target provides
575532-bit or 64-bit register values.
5756
0d5de010
DJ
5757* Support for C++ member pointers has been improved.
5758
23181151
DJ
5759* GDB now understands XML target descriptions, which specify the
5760target's overall architecture. GDB can read a description from
5761a local file or over the remote serial protocol.
5762
ea37ba09
DJ
5763* Vectors of single-byte data use a new integer type which is not
5764automatically displayed as character or string data.
5765
5766* The /s format now works with the print command. It displays
5767arrays of single-byte integers and pointers to single-byte integers
5768as strings.
e1f48ead 5769
123dc839
DJ
5770* Target descriptions can now describe target-specific registers,
5771for architectures which have implemented the support (currently
8d5f9c6f 5772only ARM, M68K, and MIPS).
123dc839 5773
05a4558a
DJ
5774* GDB and the GDB remote stub, gdbserver, now support the XScale
5775iWMMXt coprocessor.
fb1e4ffc 5776
7c963485
PA
5777* The GDB remote stub, gdbserver, has been updated to support
5778ARM Windows CE (mingw32ce) debugging, and GDB Windows CE support
5779has been rewritten to use the standard GDB remote protocol.
5780
b18be20d
DJ
5781* GDB can now step into C++ functions which are called through thunks.
5782
0ca420ce
UW
5783* GDB for the Cell/B.E. SPU now supports overlay debugging.
5784
31d99776
DJ
5785* The GDB remote protocol "qOffsets" packet can now honor ELF segment
5786layout. It also supports a TextSeg= and DataSeg= response when only
5787segment base addresses (rather than offsets) are available.
5788
a4642986
MR
5789* The /i format now outputs any trailing branch delay slot instructions
5790immediately following the last instruction within the count specified.
5791
cfa9d6d9
DJ
5792* The GDB remote protocol "T" stop reply packet now supports a
5793"library" response. Combined with the new "qXfer:libraries:read"
5794packet, this response allows GDB to debug shared libraries on targets
5795where the operating system manages the list of loaded libraries (e.g.
5796Windows and SymbianOS).
255e7678
DJ
5797
5798* The GDB remote stub, gdbserver, now supports dynamic link libraries
5799(DLLs) on Windows and Windows CE targets.
f5db8714
JK
5800
5801* GDB now supports a faster verification that a .debug file matches its binary
5802according to its build-id signature, if the signature is present.
cfa9d6d9 5803
c9bb8148
DJ
5804* New commands
5805
23776285
MR
5806set remoteflow
5807show remoteflow
5808 Enable or disable hardware flow control (RTS/CTS) on the serial port
5809 when debugging using remote targets.
5810
c9bb8148
DJ
5811set mem inaccessible-by-default
5812show mem inaccessible-by-default
5813 If the target supplies a memory map, for instance via the remote
5814 protocol's "qXfer:memory-map:read" packet, setting this variable
5815 prevents GDB from accessing memory outside the memory map. This
5816 is useful for targets with memory mapped registers or which react
5817 badly to accesses of unmapped address space.
5818
5819set breakpoint auto-hw
5820show breakpoint auto-hw
5821 If the target supplies a memory map, for instance via the remote
5822 protocol's "qXfer:memory-map:read" packet, setting this variable
5823 lets GDB use hardware breakpoints automatically for memory regions
5824 where it can not use software breakpoints. This covers both the
5825 "break" command and internal breakpoints used for other commands
5826 including "next" and "finish".
5827
0e420bd8
JB
5828catch exception
5829catch exception unhandled
5830 Stop the program execution when Ada exceptions are raised.
5831
5832catch assert
5833 Stop the program execution when an Ada assertion failed.
5834
f822c95b
DJ
5835set sysroot
5836show sysroot
5837 Set an alternate system root for target files. This is a more
5838 general version of "set solib-absolute-prefix", which is now
5839 an alias to "set sysroot".
5840
83cc5c53
UW
5841info spu
5842 Provide extended SPU facility status information. This set of
5843 commands is available only when debugging the Cell/B.E. SPU
5844 architecture.
5845
bd372731
MK
5846* New native configurations
5847
5848OpenBSD/sh sh*-*openbsd*
5849
23181151
DJ
5850set tdesc filename
5851unset tdesc filename
5852show tdesc filename
5853 Use the specified local file as an XML target description, and do
5854 not query the target for its built-in description.
5855
c9bb8148
DJ
5856* New targets
5857
54fe9172 5858OpenBSD/sh sh*-*-openbsd*
c9bb8148 5859MIPS64 GNU/Linux (gdbserver) mips64-linux-gnu
c077150c 5860Toshiba Media Processor mep-elf
c9bb8148 5861
6dd09645
JB
5862* New remote packets
5863
5864QPassSignals:
5865 Ignore the specified signals; pass them directly to the debugged program
5866 without stopping other threads or reporting them to GDB.
5867
23181151
DJ
5868qXfer:features:read:
5869 Read an XML target description from the target, which describes its
5870 features.
6dd09645 5871
83cc5c53
UW
5872qXfer:spu:read:
5873qXfer:spu:write:
5874 Read or write contents of an spufs file on the target system. These
5875 packets are available only on the Cell/B.E. SPU architecture.
5876
cfa9d6d9
DJ
5877qXfer:libraries:read:
5878 Report the loaded shared libraries. Combined with new "T" packet
5879 response, this packet allows GDB to debug shared libraries on
5880 targets where the operating system manages the list of loaded
5881 libraries (e.g. Windows and SymbianOS).
5882
483367ee
DJ
5883* Removed targets
5884
5885Support for these obsolete configurations has been removed.
5886
d08950c4
UW
5887alpha*-*-osf1*
5888alpha*-*-osf2*
7ce59000 5889d10v-*-*
483367ee
DJ
5890hppa*-*-hiux*
5891i[34567]86-ncr-*
5892i[34567]86-*-dgux*
5893i[34567]86-*-lynxos*
5894i[34567]86-*-netware*
5895i[34567]86-*-sco3.2v5*
5896i[34567]86-*-sco3.2v4*
5897i[34567]86-*-sco*
5898i[34567]86-*-sysv4.2*
5899i[34567]86-*-sysv4*
5900i[34567]86-*-sysv5*
5901i[34567]86-*-unixware2*
5902i[34567]86-*-unixware*
5903i[34567]86-*-sysv*
5904i[34567]86-*-isc*
5905m68*-cisco*-*
5906m68*-tandem-*
ad527d2e 5907mips*-*-pe
483367ee 5908rs6000-*-lynxos*
ad527d2e 5909sh*-*-pe
483367ee 5910
7ce59000
DJ
5911* Other removed features
5912
5913target abug
5914target cpu32bug
5915target est
5916target rom68k
5917
5918 Various m68k-only ROM monitors.
5919
ea35711c
DJ
5920target hms
5921target e7000
5922target sh3
5923target sh3e
5924
5925 Various Renesas ROM monitors and debugging interfaces for SH and
5926 H8/300.
5927
5928target ocd
5929
5930 Support for a Macraigor serial interface to on-chip debugging.
5931 GDB does not directly support the newer parallel or USB
5932 interfaces.
5933
7ce59000
DJ
5934DWARF 1 support
5935
5936 A debug information format. The predecessor to DWARF 2 and
5937 DWARF 3, which are still supported.
5938
54d61198
DJ
5939Support for the HP aCC compiler on HP-UX/PA-RISC
5940
5941 SOM-encapsulated symbolic debugging information, automatic
5942 invocation of pxdb, and the aCC custom C++ ABI. This does not
5943 affect HP-UX for Itanium or GCC for HP-UX/PA-RISC. Code compiled
5944 with aCC can still be debugged on an assembly level.
5945
ea35711c
DJ
5946MIPS ".pdr" sections
5947
5948 A MIPS-specific format used to describe stack frame layout
5949 in debugging information.
5950
5951Scheme support
5952
5953 GDB could work with an older version of Guile to debug
5954 the interpreter and Scheme programs running in it.
5955
1a69e1e4
DJ
5956set mips stack-arg-size
5957set mips saved-gpreg-size
5958
5959 Use "set mips abi" to control parameter passing for MIPS.
5960
6dd09645 5961*** Changes in GDB 6.6
e374b601 5962
ca3bf3bd
DJ
5963* New targets
5964
5965Xtensa xtensa-elf
9c309e77 5966Cell Broadband Engine SPU spu-elf
ca3bf3bd 5967
6aec2e11
DJ
5968* GDB can now be configured as a cross-debugger targeting native Windows
5969(mingw32) or Cygwin. It can communicate with a remote debugging stub
5970running on a Windows system over TCP/IP to debug Windows programs.
5971
5972* The GDB remote stub, gdbserver, has been updated to support Windows and
5973Cygwin debugging. Both single-threaded and multi-threaded programs are
5974supported.
5975
17218d91
DJ
5976* The "set trust-readonly-sections" command works again. This command was
5977broken in GDB 6.3, 6.4, and 6.5.
5978
9ebce043
DJ
5979* The "load" command now supports writing to flash memory, if the remote
5980stub provides the required support.
5981
7d3d3ece
DJ
5982* Support for GNU/Linux Thread Local Storage (TLS, per-thread variables) no
5983longer requires symbolic debug information (e.g. DWARF-2).
5984
4f8253f3
JB
5985* New commands
5986
5987set substitute-path
5988unset substitute-path
5989show substitute-path
5990 Manage a list of substitution rules that GDB uses to rewrite the name
5991 of the directories where the sources are located. This can be useful
5992 for instance when the sources were moved to a different location
5993 between compilation and debugging.
5994
9fa66fd7
AS
5995set trace-commands
5996show trace-commands
5997 Print each CLI command as it is executed. Each command is prefixed with
5998 a number of `+' symbols representing the nesting depth.
5999 The source command now has a `-v' option to enable the same feature.
6000
1f5befc1
DJ
6001* REMOVED features
6002
6003The ARM Demon monitor support (RDP protocol, "target rdp").
6004
2ec3381a
DJ
6005Kernel Object Display, an embedded debugging feature which only worked with
6006an obsolete version of Cisco IOS.
6007
3d00d119
DJ
6008The 'set download-write-size' and 'show download-write-size' commands.
6009
be2a5f71
DJ
6010* New remote packets
6011
6012qSupported:
6013 Tell a stub about GDB client features, and request remote target features.
6014 The first feature implemented is PacketSize, which allows the target to
6015 specify the size of packets it can handle - to minimize the number of
6016 packets required and improve performance when connected to a remote
6017 target.
6018
0876f84a
DJ
6019qXfer:auxv:read:
6020 Fetch an OS auxilliary vector from the remote stub. This packet is a
6021 more efficient replacement for qPart:auxv:read.
6022
9ebce043
DJ
6023qXfer:memory-map:read:
6024 Fetch a memory map from the remote stub, including information about
6025 RAM, ROM, and flash memory devices.
6026
6027vFlashErase:
6028vFlashWrite:
6029vFlashDone:
6030 Erase and program a flash memory device.
6031
0876f84a
DJ
6032* Removed remote packets
6033
6034qPart:auxv:read:
6035 This packet has been replaced by qXfer:auxv:read. Only GDB 6.4 and 6.5
6036 used it, and only gdbserver implemented it.
6037
e374b601 6038*** Changes in GDB 6.5
53e5f3cf 6039
96309189
MS
6040* New targets
6041
6042Renesas M32C/M16C m32c-elf
6043
6044Morpho Technologies ms1 ms1-elf
6045
53e5f3cf
AS
6046* New commands
6047
6048init-if-undefined Initialize a convenience variable, but
6049 only if it doesn't already have a value.
6050
ac264b3b
MS
6051The following commands are presently only implemented for native GNU/Linux:
6052
6053checkpoint Save a snapshot of the program state.
6054
6055restart <n> Return the program state to a
6056 previously saved state.
6057
6058info checkpoints List currently saved checkpoints.
6059
6060delete-checkpoint <n> Delete a previously saved checkpoint.
6061
6062set|show detach-on-fork Tell gdb whether to detach from a newly
6063 forked process, or to keep debugging it.
6064
6065info forks List forks of the user program that
6066 are available to be debugged.
6067
6068fork <n> Switch to debugging one of several
6069 forks of the user program that are
6070 available to be debugged.
6071
6072delete-fork <n> Delete a fork from the list of forks
6073 that are available to be debugged (and
6074 kill the forked process).
6075
6076detach-fork <n> Delete a fork from the list of forks
6077 that are available to be debugged (and
6078 allow the process to continue).
6079
3950dc3f
NS
6080* New architecture
6081
6082Morpho Technologies ms2 ms1-elf
6083
0ea3f30e
DJ
6084* Improved Windows host support
6085
6086GDB now builds as a cross debugger hosted on i686-mingw32, including
6087native console support, and remote communications using either
6088network sockets or serial ports.
6089
f79daebb
GM
6090* Improved Modula-2 language support
6091
6092GDB can now print most types in the Modula-2 syntax. This includes:
6093basic types, set types, record types, enumerated types, range types,
6094pointer types and ARRAY types. Procedure var parameters are correctly
6095printed and hexadecimal addresses and character constants are also
6096written in the Modula-2 syntax. Best results can be obtained by using
6097GNU Modula-2 together with the -gdwarf-2 command line option.
6098
acab6ab2
MM
6099* REMOVED features
6100
6101The ARM rdi-share module.
6102
f4267320
DJ
6103The Netware NLM debug server.
6104
53e5f3cf 6105*** Changes in GDB 6.4
156a53ca 6106
e0ecbda1
MK
6107* New native configurations
6108
02a677ac 6109OpenBSD/arm arm*-*-openbsd*
e0ecbda1
MK
6110OpenBSD/mips64 mips64-*-openbsd*
6111
d64a6579
KB
6112* New targets
6113
6114Morpho Technologies ms1 ms1-elf
6115
b33a6190
AS
6116* New command line options
6117
6118--batch-silent As for --batch, but totally silent.
6119--return-child-result The debugger will exist with the same value
6120 the child (debugged) program exited with.
6121--eval-command COMMAND, -ex COMMAND
6122 Execute a single GDB CLI command. This may be
6123 specified multiple times and in conjunction
6124 with the --command (-x) option.
6125
11dced61
AC
6126* Deprecated commands removed
6127
6128The following commands, that were deprecated in 2000, have been
6129removed:
6130
6131 Command Replacement
6132 set|show arm disassembly-flavor set|show arm disassembler
6133 othernames set arm disassembler
6134 set|show remotedebug set|show debug remote
6135 set|show archdebug set|show debug arch
6136 set|show eventdebug set|show debug event
6137 regs info registers
6138
6fe85783
MK
6139* New BSD user-level threads support
6140
6141It is now possible to debug programs using the user-level threads
6142library on OpenBSD and FreeBSD. Currently supported (target)
6143configurations are:
6144
6145FreeBSD/amd64 x86_64-*-freebsd*
6146FreeBSD/i386 i386-*-freebsd*
6147OpenBSD/i386 i386-*-openbsd*
6148
6149Note that the new kernel threads libraries introduced in FreeBSD 5.x
6150are not yet supported.
6151
5260ca71
MS
6152* New support for Matsushita MN10300 w/sim added
6153(Work in progress). mn10300-elf.
6154
e84ecc99
AC
6155* REMOVED configurations and files
6156
6157VxWorks and the XDR protocol *-*-vxworks
9445aa30 6158Motorola MCORE mcore-*-*
9445aa30 6159National Semiconductor NS32000 ns32k-*-*
156a53ca 6160
31e35378
JB
6161* New "set print array-indexes" command
6162
6163After turning this setting "on", GDB prints the index of each element
6164when displaying arrays. The default is "off" to preserve the previous
6165behavior.
6166
e85e5c83
MK
6167* VAX floating point support
6168
6169GDB now supports the not-quite-ieee VAX F and D floating point formats.
6170
d91e9901
AS
6171* User-defined command support
6172
6173In addition to using $arg0..$arg9 for argument passing, it is now possible
6174to use $argc to determine now many arguments have been passed. See the
6175section on user-defined commands in the user manual for more information.
6176
f2cb65ca
MC
6177*** Changes in GDB 6.3:
6178
f47b1503
AS
6179* New command line option
6180
6181GDB now accepts -l followed by a number to set the timeout for remote
6182debugging.
6183
f2cb65ca
MC
6184* GDB works with GCC -feliminate-dwarf2-dups
6185
6186GDB now supports a more compact representation of DWARF-2 debug
6187information using DW_FORM_ref_addr references. These are produced
6188by GCC with the option -feliminate-dwarf2-dups and also by some
6189proprietary compilers. With GCC, you must use GCC 3.3.4 or later
6190to use -feliminate-dwarf2-dups.
860660cb 6191
d08c0230
AC
6192* Internationalization
6193
6194When supported by the host system, GDB will be built with
6195internationalization (libintl). The task of marking up the sources is
6196continued, we're looking forward to our first translation.
6197
117ea3cf
PH
6198* Ada
6199
6200Initial support for debugging programs compiled with the GNAT
6201implementation of the Ada programming language has been integrated
6202into GDB. In this release, support is limited to expression evaluation.
6203
d08c0230
AC
6204* New native configurations
6205
6206GNU/Linux/m32r m32r-*-linux-gnu
6207
6208* Remote 'p' packet
6209
6210GDB's remote protocol now includes support for the 'p' packet. This
6211packet is used to fetch individual registers from a remote inferior.
6212
6213* END-OF-LIFE registers[] compatibility module
6214
6215GDB's internal register infrastructure has been completely rewritten.
6216The new infrastructure making possible the implementation of key new
6217features including 32x64 (e.g., 64-bit amd64 GDB debugging a 32-bit
6218i386 application).
6219
09f2921c 6220GDB 6.3 will be the last release to include the registers[]
d08c0230
AC
6221compatibility module that allowed out-of-date configurations to
6222continue to work. This change directly impacts the following
6223configurations:
6224
6225hppa-*-hpux
6226ia64-*-aix
6227mips-*-irix*
6228*-*-lynx
6229mips-*-linux-gnu
6230sds protocol
6231xdr protocol
6232powerpc bdm protocol
6233
6234Unless there is activity to revive these configurations, they will be
6235made OBSOLETE in GDB 6.4, and REMOVED from GDB 6.5.
6236
6237* OBSOLETE configurations and files
6238
6239Configurations that have been declared obsolete in this release have
6240been commented out. Unless there is activity to revive these
6241configurations, the next release of GDB will have their sources
6242permanently REMOVED.
6243
6244h8300-*-*
6245mcore-*-*
6246mn10300-*-*
6247ns32k-*-*
6248sh64-*-*
6249v850-*-*
6250
ebb7c577
AC
6251*** Changes in GDB 6.2.1:
6252
6253* MIPS `break main; run' gave an heuristic-fence-post warning
6254
6255When attempting to run even a simple program, a warning about
6256heuristic-fence-post being hit would be reported. This problem has
6257been fixed.
6258
6259* MIPS IRIX 'long double' crashed GDB
6260
6261When examining a long double variable, GDB would get a segmentation
6262fault. The crash has been fixed (but GDB 6.2 cannot correctly examine
6263IRIX long double values).
6264
6265* VAX and "next"
6266
6267A bug in the VAX stack code was causing problems with the "next"
6268command. This problem has been fixed.
6269
860660cb 6270*** Changes in GDB 6.2:
faae5abe 6271
0dea2468
AC
6272* Fix for ``many threads''
6273
6274On GNU/Linux systems that use the NPTL threads library, a program
6275rapidly creating and deleting threads would confuse GDB leading to the
6276error message:
6277
6278 ptrace: No such process.
6279 thread_db_get_info: cannot get thread info: generic error
6280
6281This problem has been fixed.
6282
2c07db7a
AC
6283* "-async" and "-noasync" options removed.
6284
6285Support for the broken "-noasync" option has been removed (it caused
6286GDB to dump core).
6287
c23968a2
JB
6288* New ``start'' command.
6289
82f06518 6290This command runs the program until the beginning of the main procedure.
c23968a2 6291
71009278
MK
6292* New BSD Kernel Data Access Library (libkvm) interface
6293
6294Using ``target kvm'' it is now possible to debug kernel core dumps and
6295live kernel memory images on various FreeBSD, NetBSD and OpenBSD
6296platforms. Currently supported (native-only) configurations are:
6297
6298FreeBSD/amd64 x86_64-*-freebsd*
6299FreeBSD/i386 i?86-*-freebsd*
6300NetBSD/i386 i?86-*-netbsd*
6301NetBSD/m68k m68*-*-netbsd*
6302NetBSD/sparc sparc-*-netbsd*
6303OpenBSD/amd64 x86_64-*-openbsd*
6304OpenBSD/i386 i?86-*-openbsd*
6305OpenBSD/m68k m68*-openbsd*
6306OpenBSD/sparc sparc-*-openbsd*
6307
3c0b7db2
AC
6308* Signal trampoline code overhauled
6309
6310Many generic problems with GDB's signal handling code have been fixed.
6311These include: backtraces through non-contiguous stacks; recognition
6312of sa_sigaction signal trampolines; backtrace from a NULL pointer
6313call; backtrace through a signal trampoline; step into and out of
6314signal handlers; and single-stepping in the signal trampoline.
6315
73cc75f3
AC
6316Please note that kernel bugs are a limiting factor here. These
6317features have been shown to work on an s390 GNU/Linux system that
6318include a 2.6.8-rc1 kernel. Ref PR breakpoints/1702.
3c0b7db2 6319
7243600a
BF
6320* Cygwin support for DWARF 2 added.
6321
6f606e1c
MK
6322* New native configurations
6323
97dc871c 6324GNU/Linux/hppa hppa*-*-linux*
0e56aeaf 6325OpenBSD/hppa hppa*-*-openbsd*
bf2ca189
MK
6326OpenBSD/m68k m68*-*-openbsd*
6327OpenBSD/m88k m88*-*-openbsd*
d195bc9f 6328OpenBSD/powerpc powerpc-*-openbsd*
6f606e1c 6329NetBSD/vax vax-*-netbsd*
9f076e7a 6330OpenBSD/vax vax-*-openbsd*
6f606e1c 6331
a1b461bf
AC
6332* END-OF-LIFE frame compatibility module
6333
6334GDB's internal frame infrastructure has been completely rewritten.
6335The new infrastructure making it possible to support key new features
6336including DWARF 2 Call Frame Information. To aid in the task of
6337migrating old configurations to this new infrastructure, a
6338compatibility module, that allowed old configurations to continue to
6339work, was also included.
6340
6341GDB 6.2 will be the last release to include this frame compatibility
6342module. This change directly impacts the following configurations:
6343
6344h8300-*-*
6345mcore-*-*
6346mn10300-*-*
6347ns32k-*-*
6348sh64-*-*
6349v850-*-*
6350xstormy16-*-*
6351
6352Unless there is activity to revive these configurations, they will be
6353made OBSOLETE in GDB 6.3, and REMOVED from GDB 6.4.
6354
3c7012f5
AC
6355* REMOVED configurations and files
6356
6357Sun 3, running SunOS 3 m68*-*-sunos3*
6358Sun 3, running SunOS 4 m68*-*-sunos4*
6359Sun 2, running SunOS 3 m68000-*-sunos3*
6360Sun 2, running SunOS 4 m68000-*-sunos4*
6361Motorola 680x0 running LynxOS m68*-*-lynxos*
6362AT&T 3b1/Unix pc m68*-att-*
6363Bull DPX2 (68k, System V release 3) m68*-bull-sysv*
6364decstation mips-dec-* mips-little-*
6365riscos mips-*-riscos* mips-*-sysv*
6366sonymips mips-sony-*
6367sysv mips*-*-sysv4* (IRIX 5/6 not included)
6368
e5fe55f7
AC
6369*** Changes in GDB 6.1.1:
6370
6371* TUI (Text-mode User Interface) built-in (also included in GDB 6.1)
6372
6373The TUI (Text-mode User Interface) is now built as part of a default
6374GDB configuration. It is enabled by either selecting the TUI with the
6375command line option "-i=tui" or by running the separate "gdbtui"
6376program. For more information on the TUI, see the manual "Debugging
6377with GDB".
6378
6379* Pending breakpoint support (also included in GDB 6.1)
6380
6381Support has been added to allow you to specify breakpoints in shared
6382libraries that have not yet been loaded. If a breakpoint location
6383cannot be found, and the "breakpoint pending" option is set to auto,
6384GDB queries you if you wish to make the breakpoint pending on a future
6385shared-library load. If and when GDB resolves the breakpoint symbol,
6386the pending breakpoint is removed as one or more regular breakpoints
6387are created.
6388
6389Pending breakpoints are very useful for GCJ Java debugging.
6390
6391* Fixed ISO-C build problems
6392
6393The files bfd/elf-bfd.h, gdb/dictionary.c and gdb/types.c contained
6394non ISO-C code that stopped them being built using a more strict ISO-C
6395compiler (e.g., IBM's C compiler).
6396
6397* Fixed build problem on IRIX 5
6398
6399Due to header problems with <sys/proc.h>, the file gdb/proc-api.c
6400wasn't able to compile compile on an IRIX 5 system.
6401
6402* Added execute permission to gdb/gdbserver/configure
6403
6404The shell script gdb/testsuite/gdb.stabs/configure lacked execute
6405permission. This bug would cause configure to fail on a number of
6406systems (Solaris, IRIX). Ref: server/519.
6407
6408* Fixed build problem on hpux2.0w-hp-hpux11.00 using the HP ANSI C compiler
6409
6410Older HPUX ANSI C compilers did not accept variable array sizes. somsolib.c
6411has been updated to use constant array sizes.
6412
6413* Fixed a panic in the DWARF Call Frame Info code on Solaris 2.7
6414
6415GCC 3.3.2, on Solaris 2.7, includes the DW_EH_PE_funcrel encoding in
6416its generated DWARF Call Frame Info. This encoding was causing GDB to
6417panic, that panic has been fixed. Ref: gdb/1628.
6418
6419* Fixed a problem when examining parameters in shared library code.
6420
6421When examining parameters in optimized shared library code generated
6422by a mainline GCC, GDB would incorrectly report ``Variable "..." is
6423not available''. GDB now correctly displays the variable's value.
6424
faae5abe 6425*** Changes in GDB 6.1:
f2c06f52 6426
9175c9a3
MC
6427* Removed --with-mmalloc
6428
6429Support for the mmalloc memory manager has been removed, as it
6430conflicted with the internal gdb byte cache.
6431
3cc87ec0
MK
6432* Changes in AMD64 configurations
6433
6434The AMD64 target now includes the %cs and %ss registers. As a result
6435the AMD64 remote protocol has changed; this affects the floating-point
6436and SSE registers. If you rely on those registers for your debugging,
6437you should upgrade gdbserver on the remote side.
6438
f0424ef6
MK
6439* Revised SPARC target
6440
6441The SPARC target has been completely revised, incorporating the
6442FreeBSD/sparc64 support that was added for GDB 6.0. As a result
03cebad2
MK
6443support for LynxOS and SunOS 4 has been dropped. Calling functions
6444from within GDB on operating systems with a non-executable stack
6445(Solaris, OpenBSD) now works.
f0424ef6 6446
59659be2
ILT
6447* New C++ demangler
6448
6449GDB has a new C++ demangler which does a better job on the mangled
6450names generated by current versions of g++. It also runs faster, so
6451with this and other changes gdb should now start faster on large C++
6452programs.
6453
9e08b29b
DJ
6454* DWARF 2 Location Expressions
6455
6456GDB support for location expressions has been extended to support function
6457arguments and frame bases. Older versions of GDB could crash when they
6458encountered these.
6459
8dfe8985
DC
6460* C++ nested types and namespaces
6461
6462GDB's support for nested types and namespaces in C++ has been
6463improved, especially if you use the DWARF 2 debugging format. (This
6464is the default for recent versions of GCC on most platforms.)
6465Specifically, if you have a class "Inner" defined within a class or
6466namespace "Outer", then GDB realizes that the class's name is
6467"Outer::Inner", not simply "Inner". This should greatly reduce the
6468frequency of complaints about not finding RTTI symbols. In addition,
6469if you are stopped at inside of a function defined within a namespace,
6470GDB modifies its name lookup accordingly.
6471
cced5e27
MK
6472* New native configurations
6473
6474NetBSD/amd64 x86_64-*-netbsd*
27d1e716 6475OpenBSD/amd64 x86_64-*-openbsd*
2031c21a 6476OpenBSD/alpha alpha*-*-openbsd*
f2cab569
MK
6477OpenBSD/sparc sparc-*-openbsd*
6478OpenBSD/sparc64 sparc64-*-openbsd*
cced5e27 6479
b4b4b794
KI
6480* New debugging protocols
6481
6482M32R with SDI protocol m32r-*-elf*
6483
7989c619
AC
6484* "set prompt-escape-char" command deleted.
6485
6486The command "set prompt-escape-char" has been deleted. This command,
82f06518 6487and its very obscure effect on GDB's prompt, was never documented,
7989c619
AC
6488tested, nor mentioned in the NEWS file.
6489
5994185b
AC
6490* OBSOLETE configurations and files
6491
6492Configurations that have been declared obsolete in this release have
6493been commented out. Unless there is activity to revive these
6494configurations, the next release of GDB will have their sources
6495permanently REMOVED.
6496
6497Sun 3, running SunOS 3 m68*-*-sunos3*
6498Sun 3, running SunOS 4 m68*-*-sunos4*
6499Sun 2, running SunOS 3 m68000-*-sunos3*
6500Sun 2, running SunOS 4 m68000-*-sunos4*
6501Motorola 680x0 running LynxOS m68*-*-lynxos*
6502AT&T 3b1/Unix pc m68*-att-*
6503Bull DPX2 (68k, System V release 3) m68*-bull-sysv*
0748d941
AC
6504decstation mips-dec-* mips-little-*
6505riscos mips-*-riscos* mips-*-sysv*
6506sonymips mips-sony-*
6507sysv mips*-*-sysv4* (IRIX 5/6 not included)
5994185b 6508
0ddabb4c
AC
6509* REMOVED configurations and files
6510
6511SGI Irix-4.x mips-sgi-irix4 or iris4
6512SGI Iris (MIPS) running Irix V3: mips-sgi-irix or iris
4a8269c0
AC
6513Z8000 simulator z8k-zilog-none or z8ksim
6514Matsushita MN10200 w/simulator mn10200-*-*
6515H8/500 simulator h8500-hitachi-hms or h8500hms
6516HP/PA running BSD hppa*-*-bsd*
6517HP/PA running OSF/1 hppa*-*-osf*
6518HP/PA Pro target hppa*-*-pro*
6519PMAX (MIPS) running Mach 3.0 mips*-*-mach3*
cf7c5c23 6520386BSD i[3456]86-*-bsd*
4a8269c0
AC
6521Sequent family i[3456]86-sequent-sysv4*
6522 i[3456]86-sequent-sysv*
6523 i[3456]86-sequent-bsd*
f0424ef6
MK
6524SPARC running LynxOS sparc-*-lynxos*
6525SPARC running SunOS 4 sparc-*-sunos4*
4a8269c0
AC
6526Tsqware Sparclet sparclet-*-*
6527Fujitsu SPARClite sparclite-fujitsu-none or sparclite
0ddabb4c 6528
c7f1390e
DJ
6529*** Changes in GDB 6.0:
6530
1fe43d45
AC
6531* Objective-C
6532
6533Support for debugging the Objective-C programming language has been
6534integrated into GDB.
6535
e6beb428
AC
6536* New backtrace mechanism (includes DWARF 2 Call Frame Information).
6537
6538DWARF 2's Call Frame Information makes available compiler generated
6539information that more exactly describes the program's run-time stack.
6540By using this information, GDB is able to provide more robust stack
6541backtraces.
6542
6543The i386, amd64 (nee, x86-64), Alpha, m68hc11, ia64, and m32r targets
6544have been updated to use a new backtrace mechanism which includes
6545DWARF 2 CFI support.
6546
6547* Hosted file I/O.
6548
6549GDB's remote protocol has been extended to include support for hosted
6550file I/O (where the remote target uses GDB's file system). See GDB's
6551remote protocol documentation for details.
6552
6553* All targets using the new architecture framework.
6554
6555All of GDB's targets have been updated to use the new internal
6556architecture framework. The way is now open for future GDB releases
6557to include cross-architecture native debugging support (i386 on amd64,
6558ppc32 on ppc64).
6559
6560* GNU/Linux's Thread Local Storage (TLS)
6561
6562GDB now includes support for for the GNU/Linux implementation of
6563per-thread variables.
6564
6565* GNU/Linux's Native POSIX Thread Library (NPTL)
6566
6567GDB's thread code has been updated to work with either the new
6568GNU/Linux NPTL thread library or the older "LinuxThreads" library.
6569
6570* Separate debug info.
6571
6572GDB, in conjunction with BINUTILS, now supports a mechanism for
6573automatically loading debug information from a separate file. Instead
6574of shipping full debug and non-debug versions of system libraries,
6575system integrators can now instead ship just the stripped libraries
6576and optional debug files.
6577
6578* DWARF 2 Location Expressions
6579
6580DWARF 2 Location Expressions allow the compiler to more completely
6581describe the location of variables (even in optimized code) to the
6582debugger.
6583
6584GDB now includes preliminary support for location expressions (support
6585for DW_OP_piece is still missing).
6586
6587* Java
6588
6589A number of long standing bugs that caused GDB to die while starting a
6590Java application have been fixed. GDB's Java support is now
6591considered "useable".
6592
85f8f974
DJ
6593* GNU/Linux support for fork, vfork, and exec.
6594
6595The "catch fork", "catch exec", "catch vfork", and "set follow-fork-mode"
6596commands are now implemented for GNU/Linux. They require a 2.5.x or later
6597kernel.
6598
0fac0b41
DJ
6599* GDB supports logging output to a file
6600
6601There are two new commands, "set logging" and "show logging", which can be
6602used to capture GDB's output to a file.
f2c06f52 6603
6ad8ae5c
DJ
6604* The meaning of "detach" has changed for gdbserver
6605
6606The "detach" command will now resume the application, as documented. To
6607disconnect from gdbserver and leave it stopped, use the new "disconnect"
6608command.
6609
e286caf2 6610* d10v, m68hc11 `regs' command deprecated
5f601589
AC
6611
6612The `info registers' command has been updated so that it displays the
6613registers using a format identical to the old `regs' command.
6614
d28f9cdf
DJ
6615* Profiling support
6616
6617A new command, "maint set profile on/off", has been added. This command can
6618be used to enable or disable profiling while running GDB, to profile a
6619session or a set of commands. In addition there is a new configure switch,
6620"--enable-profiling", which will cause GDB to be compiled with profiling
6621data, for more informative profiling results.
6622
da0f9dcd
AC
6623* Default MI syntax changed to "mi2".
6624
6625The default MI (machine interface) syntax, enabled by the command line
6626option "-i=mi", has been changed to "mi2". The previous MI syntax,
b68767c1 6627"mi1", can be enabled by specifying the option "-i=mi1".
da0f9dcd
AC
6628
6629Support for the original "mi0" syntax (included in GDB 5.0) has been
6630removed.
6631
fb9b6b35
JJ
6632Fix for gdb/192: removed extraneous space when displaying frame level.
6633Fix for gdb/672: update changelist is now output in mi list format.
6634Fix for gdb/702: a -var-assign that updates the value now shows up
6635 in a subsequent -var-update.
6636
954a4db8
MK
6637* New native configurations.
6638
6639FreeBSD/amd64 x86_64-*-freebsd*
6640
6760f9e6
JB
6641* Multi-arched targets.
6642
b4263afa 6643HP/PA HPUX11 hppa*-*-hpux*
85a453d5 6644Renesas M32R/D w/simulator m32r-*-elf*
6760f9e6 6645
1b831c93
AC
6646* OBSOLETE configurations and files
6647
6648Configurations that have been declared obsolete in this release have
6649been commented out. Unless there is activity to revive these
6650configurations, the next release of GDB will have their sources
6651permanently REMOVED.
6652
8b0e5691 6653Z8000 simulator z8k-zilog-none or z8ksim
67f16606 6654Matsushita MN10200 w/simulator mn10200-*-*
fd2299bd 6655H8/500 simulator h8500-hitachi-hms or h8500hms
56056df7
AC
6656HP/PA running BSD hppa*-*-bsd*
6657HP/PA running OSF/1 hppa*-*-osf*
6658HP/PA Pro target hppa*-*-pro*
78c43945 6659PMAX (MIPS) running Mach 3.0 mips*-*-mach3*
2fbce691
AC
6660Sequent family i[3456]86-sequent-sysv4*
6661 i[3456]86-sequent-sysv*
6662 i[3456]86-sequent-bsd*
f81824a9
AC
6663Tsqware Sparclet sparclet-*-*
6664Fujitsu SPARClite sparclite-fujitsu-none or sparclite
fd2299bd 6665
5835abe7
NC
6666* REMOVED configurations and files
6667
6668V850EA ISA
1b831c93
AC
6669Motorola Delta 88000 running Sys V m88k-motorola-sysv or delta88
6670IBM AIX PS/2 i[3456]86-*-aix
6671i386 running Mach 3.0 i[3456]86-*-mach3*
6672i386 running Mach i[3456]86-*-mach*
6673i386 running OSF/1 i[3456]86-*osf1mk*
6674HP/Apollo 68k Family m68*-apollo*-sysv*,
6675 m68*-apollo*-bsd*,
6676 m68*-hp-bsd*, m68*-hp-hpux*
6677Argonaut Risc Chip (ARC) arc-*-*
6678Mitsubishi D30V d30v-*-*
6679Fujitsu FR30 fr30-*-elf*
6680OS/9000 i[34]86-*-os9k
6681I960 with MON960 i960-*-coff
5835abe7 6682
a094c6fb
AC
6683* MIPS $fp behavior changed
6684
6685The convenience variable $fp, for the MIPS, now consistently returns
6686the address of the current frame's base. Previously, depending on the
6687context, $fp could refer to either $sp or the current frame's base
6688address. See ``8.10 Registers'' in the manual ``Debugging with GDB:
6689The GNU Source-Level Debugger''.
6690
299ffc64 6691*** Changes in GDB 5.3:
37057839 6692
46248966
AC
6693* GNU/Linux shared library multi-threaded performance improved.
6694
6695When debugging a multi-threaded application on GNU/Linux, GDB now uses
6696`/proc', in preference to `ptrace' for memory reads. This may result
6697in an improvement in the start-up time of multi-threaded, shared
6698library applications when run under GDB. One GDB user writes: ``loads
6699shared libs like mad''.
6700
b9d14705 6701* ``gdbserver'' now supports multi-threaded applications on some targets
6da02953 6702
b9d14705
DJ
6703Support for debugging multi-threaded applications which use
6704the GNU/Linux LinuxThreads package has been added for
6705arm*-*-linux*-gnu*, i[3456]86-*-linux*-gnu*, mips*-*-linux*-gnu*,
6706powerpc*-*-linux*-gnu*, and sh*-*-linux*-gnu*.
6da02953 6707
e0e9281e
JB
6708* GDB now supports C/C++ preprocessor macros.
6709
6710GDB now expands preprocessor macro invocations in C/C++ expressions,
6711and provides various commands for showing macro definitions and how
6712they expand.
6713
dd73b9bb
AC
6714The new command `macro expand EXPRESSION' expands any macro
6715invocations in expression, and shows the result.
6716
6717The new command `show macro MACRO-NAME' shows the definition of the
6718macro named MACRO-NAME, and where it was defined.
6719
e0e9281e
JB
6720Most compilers don't include information about macros in the debugging
6721information by default. In GCC 3.1, for example, you need to compile
6722your program with the options `-gdwarf-2 -g3'. If the macro
6723information is present in the executable, GDB will read it.
6724
2250ee0c
CV
6725* Multi-arched targets.
6726
6e3ba3b8
JT
6727DEC Alpha (partial) alpha*-*-*
6728DEC VAX (partial) vax-*-*
2250ee0c 6729NEC V850 v850-*-*
6e3ba3b8 6730National Semiconductor NS32000 (partial) ns32k-*-*
a1789893
GS
6731Motorola 68000 (partial) m68k-*-*
6732Motorola MCORE mcore-*-*
2250ee0c 6733
cd9bfe15 6734* New targets.
e33ce519 6735
456f8b9d
DB
6736Fujitsu FRV architecture added by Red Hat frv*-*-*
6737
e33ce519 6738
da8ca43d
JT
6739* New native configurations
6740
6741Alpha NetBSD alpha*-*-netbsd*
029923d4 6742SH NetBSD sh*-*-netbsdelf*
45888261 6743MIPS NetBSD mips*-*-netbsd*
9ce5c36a 6744UltraSPARC NetBSD sparc64-*-netbsd*
da8ca43d 6745
cd9bfe15
AC
6746* OBSOLETE configurations and files
6747
6748Configurations that have been declared obsolete in this release have
6749been commented out. Unless there is activity to revive these
6750configurations, the next release of GDB will have their sources
6751permanently REMOVED.
6752
92eb23c5 6753Mitsubishi D30V d30v-*-*
a99a9e1b 6754OS/9000 i[34]86-*-os9k
1c7cc583 6755IBM AIX PS/2 i[3456]86-*-aix
7a3085c1 6756Fujitsu FR30 fr30-*-elf*
7fb623f7 6757Motorola Delta 88000 running Sys V m88k-motorola-sysv or delta88
eb4c54a2 6758Argonaut Risc Chip (ARC) arc-*-*
d8ee244c
MK
6759i386 running Mach 3.0 i[3456]86-*-mach3*
6760i386 running Mach i[3456]86-*-mach*
6761i386 running OSF/1 i[3456]86-*osf1mk*
822e978b
AC
6762HP/Apollo 68k Family m68*-apollo*-sysv*,
6763 m68*-apollo*-bsd*,
6764 m68*-hp-bsd*, m68*-hp-hpux*
4d210288 6765I960 with MON960 i960-*-coff
92eb23c5 6766
db034ac5
AC
6767* OBSOLETE languages
6768
6769CHILL, a Pascal like language used by telecommunications companies.
6770
cd9bfe15
AC
6771* REMOVED configurations and files
6772
6773AMD 29k family via UDI a29k-amd-udi, udi29k
6774A29K VxWorks a29k-*-vxworks
6775AMD 29000 embedded, using EBMON a29k-none-none
6776AMD 29000 embedded with COFF a29k-none-coff
6777AMD 29000 embedded with a.out a29k-none-aout
6778
6779testsuite/gdb.hp/gdb.threads-hp/ directory
6780
20f01a46
DH
6781* New command "set max-user-call-depth <nnn>"
6782
6783This command allows the user to limit the call depth of user-defined
6784commands. The default is 1024.
6785
a5941fbf
MK
6786* Changes in FreeBSD/i386 native debugging.
6787
6788Support for the "generate-core-file" has been added.
6789
89743e04
MS
6790* New commands "dump", "append", and "restore".
6791
6792These commands allow data to be copied from target memory
6793to a bfd-format or binary file (dump and append), and back
6794from a file into memory (restore).
37057839 6795
9fb14e79
JB
6796* Improved "next/step" support on multi-processor Alpha Tru64.
6797
6798The previous single-step mechanism could cause unpredictable problems,
6799including the random appearance of SIGSEGV or SIGTRAP signals. The use
6800of a software single-step mechanism prevents this.
6801
2037aebb
AC
6802*** Changes in GDB 5.2.1:
6803
6804* New targets.
6805
6806Atmel AVR avr*-*-*
6807
6808* Bug fixes
6809
6810gdb/182: gdb/323: gdb/237: On alpha, gdb was reporting:
6811mdebugread.c:2443: gdb-internal-error: sect_index_data not initialized
6812Fix, by Joel Brobecker imported from mainline.
6813
6814gdb/439: gdb/291: On some ELF object files, gdb was reporting:
6815dwarf2read.c:1072: gdb-internal-error: sect_index_text not initialize
6816Fix, by Fred Fish, imported from mainline.
6817
6818Dwarf2 .debug_frame & .eh_frame handler improved in many ways.
6819Surprisingly enough, it works now.
6820By Michal Ludvig, imported from mainline.
6821
6822i386 hardware watchpoint support:
6823avoid misses on second run for some targets.
6824By Pierre Muller, imported from mainline.
6825
37057839 6826*** Changes in GDB 5.2:
eb7cedd9 6827
1a703748
MS
6828* New command "set trust-readonly-sections on[off]".
6829
6830This command is a hint that tells gdb that read-only sections
6831really are read-only (ie. that their contents will not change).
6832In this mode, gdb will go to the object file rather than the
6833target to read memory from read-only sections (such as ".text").
6834This can be a significant performance improvement on some
6835(notably embedded) targets.
6836
cefd4ef5
MS
6837* New command "generate-core-file" (or "gcore").
6838
55241689
AC
6839This new gdb command allows the user to drop a core file of the child
6840process state at any time. So far it's been implemented only for
6841GNU/Linux and Solaris, but should be relatively easily ported to other
6842hosts. Argument is core file name (defaults to core.<pid>).
cefd4ef5 6843
352ed7b4
MS
6844* New command line option
6845
6846GDB now accepts --pid or -p followed by a process id.
6847
6848* Change in command line behavior -- corefiles vs. process ids.
6849
6850There is a subtle behavior in the way in which GDB handles
6851command line arguments. The first non-flag argument is always
6852a program to debug, but the second non-flag argument may either
6853be a corefile or a process id. Previously, GDB would attempt to
6854open the second argument as a corefile, and if that failed, would
6855issue a superfluous error message and then attempt to attach it as
6856a process. Now, if the second argument begins with a non-digit,
6857it will be treated as a corefile. If it begins with a digit,
6858GDB will attempt to attach it as a process, and if no such process
6859is found, will then attempt to open it as a corefile.
6860
fe419ffc
RE
6861* Changes in ARM configurations.
6862
6863Multi-arch support is enabled for all ARM configurations. The ARM/NetBSD
6864configuration is fully multi-arch.
6865
eb7cedd9
MK
6866* New native configurations
6867
fe419ffc 6868ARM NetBSD arm*-*-netbsd*
eb7cedd9 6869x86 OpenBSD i[3456]86-*-openbsd*
55241689 6870AMD x86-64 running GNU/Linux x86_64-*-linux-*
768f0842 6871Sparc64 running FreeBSD sparc64-*-freebsd*
eb7cedd9 6872
c9f63e6b
CV
6873* New targets
6874
6875Sanyo XStormy16 xstormy16-elf
6876
9b4ff276
AC
6877* OBSOLETE configurations and files
6878
6879Configurations that have been declared obsolete in this release have
6880been commented out. Unless there is activity to revive these
6881configurations, the next release of GDB will have their sources
6882permanently REMOVED.
6883
6884AMD 29k family via UDI a29k-amd-udi, udi29k
6885A29K VxWorks a29k-*-vxworks
6886AMD 29000 embedded, using EBMON a29k-none-none
6887AMD 29000 embedded with COFF a29k-none-coff
6888AMD 29000 embedded with a.out a29k-none-aout
6889
b4ceaee6 6890testsuite/gdb.hp/gdb.threads-hp/ directory
9b4ff276 6891
e2caac18
AC
6892* REMOVED configurations and files
6893
6894TI TMS320C80 tic80-*-*
7bc65f05 6895WDC 65816 w65-*-*
7768dd6c
AC
6896PowerPC Solaris powerpcle-*-solaris*
6897PowerPC Windows NT powerpcle-*-cygwin32
6898PowerPC Netware powerpc-*-netware*
5e734e1f 6899Harris/CXUX m88k m88*-harris-cxux*
1406caf7
AC
6900Most ns32k hosts and targets ns32k-*-mach3* ns32k-umax-*
6901 ns32k-utek-sysv* ns32k-utek-*
7e24f0b1 6902SunOS 4.0.Xi on i386 i[3456]86-*-sunos*
9b567150 6903Ultracomputer (29K) running Sym1 a29k-nyu-sym1 a29k-*-kern*
3680c638
AC
6904Sony NEWS (68K) running NEWSOS 3.x m68*-sony-sysv news
6905ISI Optimum V (3.05) under 4.3bsd. m68*-isi-*
a752853e 6906Apple Macintosh (MPW) host and target N/A host, powerpc-*-macos*
e2caac18 6907
c2a727fa
TT
6908* Changes to command line processing
6909
6910The new `--args' feature can be used to specify command-line arguments
6911for the inferior from gdb's command line.
6912
467d8519
TT
6913* Changes to key bindings
6914
6915There is a new `operate-and-get-next' function bound to `C-o'.
6916
7072a954
AC
6917*** Changes in GDB 5.1.1
6918
6919Fix compile problem on DJGPP.
6920
6921Fix a problem with floating-point registers on the i386 being
6922corrupted.
6923
6924Fix to stop GDB crashing on .debug_str debug info.
6925
6926Numerous documentation fixes.
6927
6928Numerous testsuite fixes.
6929
34f47bc4 6930*** Changes in GDB 5.1:
139760b7
MK
6931
6932* New native configurations
6933
6934Alpha FreeBSD alpha*-*-freebsd*
6935x86 FreeBSD 3.x and 4.x i[3456]86*-freebsd[34]*
55241689 6936MIPS GNU/Linux mips*-*-linux*
e23194cb
EZ
6937MIPS SGI Irix 6.x mips*-sgi-irix6*
6938ia64 AIX ia64-*-aix*
55241689 6939s390 and s390x GNU/Linux {s390,s390x}-*-linux*
139760b7 6940
bf64bfd6
AC
6941* New targets
6942
def90278 6943Motorola 68HC11 and 68HC12 m68hc11-elf
24be5c34 6944CRIS cris-axis
55241689 6945UltraSparc running GNU/Linux sparc64-*-linux*
def90278 6946
17e78a56 6947* OBSOLETE configurations and files
bf64bfd6
AC
6948
6949x86 FreeBSD before 2.2 i[3456]86*-freebsd{1,2.[01]}*,
9b9c068d 6950Harris/CXUX m88k m88*-harris-cxux*
bb19ff3b
AC
6951Most ns32k hosts and targets ns32k-*-mach3* ns32k-umax-*
6952 ns32k-utek-sysv* ns32k-utek-*
76f4ea53
AC
6953TI TMS320C80 tic80-*-*
6954WDC 65816 w65-*-*
4a1968f4 6955Ultracomputer (29K) running Sym1 a29k-nyu-sym1 a29k-*-kern*
1b2b2c16
AC
6956PowerPC Solaris powerpcle-*-solaris*
6957PowerPC Windows NT powerpcle-*-cygwin32
6958PowerPC Netware powerpc-*-netware*
24f89b68 6959SunOS 4.0.Xi on i386 i[3456]86-*-sunos*
514e603d
AC
6960Sony NEWS (68K) running NEWSOS 3.x m68*-sony-sysv news
6961ISI Optimum V (3.05) under 4.3bsd. m68*-isi-*
d036b4d9 6962Apple Macintosh (MPW) host N/A
bf64bfd6 6963
17e78a56
AC
6964stuff.c (Program to stuff files into a specially prepared space in kdb)
6965kdb-start.c (Main loop for the standalone kernel debugger)
6966
7fcca85b
AC
6967Configurations that have been declared obsolete in this release have
6968been commented out. Unless there is activity to revive these
6969configurations, the next release of GDB will have their sources
6970permanently REMOVED.
6971
a196c81c 6972* REMOVED configurations and files
7fcca85b
AC
6973
6974Altos 3068 m68*-altos-*
6975Convex c1-*-*, c2-*-*
6976Pyramid pyramid-*-*
6977ARM RISCix arm-*-* (as host)
6978Tahoe tahoe-*-*
a196c81c 6979ser-ocd.c *-*-*
bf64bfd6 6980
6d6b80e5 6981* GDB has been converted to ISO C.
e23194cb 6982
6d6b80e5 6983GDB's source code has been converted to ISO C. In particular, the
e23194cb
EZ
6984sources are fully protoized, and rely on standard headers being
6985present.
6986
bf64bfd6
AC
6987* Other news:
6988
e23194cb
EZ
6989* "info symbol" works on platforms which use COFF, ECOFF, XCOFF, and NLM.
6990
6991* The MI enabled by default.
6992
6993The new machine oriented interface (MI) introduced in GDB 5.0 has been
6994revised and enabled by default. Packages which use GDB as a debugging
6995engine behind a UI or another front end are encouraged to switch to
6996using the GDB/MI interface, instead of the old annotations interface
6997which is now deprecated.
6998
6999* Support for debugging Pascal programs.
7000
7001GDB now includes support for debugging Pascal programs. The following
7002main features are supported:
7003
7004 - Pascal-specific data types such as sets;
7005
7006 - automatic recognition of Pascal sources based on file-name
7007 extension;
7008
7009 - Pascal-style display of data types, variables, and functions;
7010
7011 - a Pascal expression parser.
7012
7013However, some important features are not yet supported.
7014
7015 - Pascal string operations are not supported at all;
7016
7017 - there are some problems with boolean types;
7018
7019 - Pascal type hexadecimal constants are not supported
7020 because they conflict with the internal variables format;
7021
7022 - support for Pascal objects and classes is not full yet;
7023
7024 - unlike Pascal, GDB is case-sensitive for symbol names.
7025
7026* Changes in completion.
7027
7028Commands such as `shell', `run' and `set args', which pass arguments
7029to inferior programs, now complete on file names, similar to what
7030users expect at the shell prompt.
7031
7032Commands which accept locations, such as `disassemble', `print',
7033`breakpoint', `until', etc. now complete on filenames as well as
7034program symbols. Thus, if you type "break foob TAB", and the source
7035files linked into the programs include `foobar.c', that file name will
7036be one of the candidates for completion. However, file names are not
7037considered for completion after you typed a colon that delimits a file
7038name from a name of a function in that file, as in "break foo.c:bar".
7039
7040`set demangle-style' completes on available demangling styles.
7041
7042* New platform-independent commands:
7043
7044It is now possible to define a post-hook for a command as well as a
7045hook that runs before the command. For more details, see the
7046documentation of `hookpost' in the GDB manual.
7047
7048* Changes in GNU/Linux native debugging.
7049
d7275149
MK
7050Support for debugging multi-threaded programs has been completely
7051revised for all platforms except m68k and sparc. You can now debug as
7052many threads as your system allows you to have.
7053
e23194cb
EZ
7054Attach/detach is supported for multi-threaded programs.
7055
d7275149
MK
7056Support for SSE registers was added for x86. This doesn't work for
7057multi-threaded programs though.
e23194cb
EZ
7058
7059* Changes in MIPS configurations.
bf64bfd6
AC
7060
7061Multi-arch support is enabled for all MIPS configurations.
7062
e23194cb
EZ
7063GDB can now be built as native debugger on SGI Irix 6.x systems for
7064debugging n32 executables. (Debugging 64-bit executables is not yet
7065supported.)
7066
7067* Unified support for hardware watchpoints in all x86 configurations.
7068
7069Most (if not all) native x86 configurations support hardware-assisted
7070breakpoints and watchpoints in a unified manner. This support
7071implements debug register sharing between watchpoints, which allows to
7072put a virtually infinite number of watchpoints on the same address,
7073and also supports watching regions up to 16 bytes with several debug
7074registers.
7075
7076The new maintenance command `maintenance show-debug-regs' toggles
7077debugging print-outs in functions that insert, remove, and test
7078watchpoints and hardware breakpoints.
7079
7080* Changes in the DJGPP native configuration.
7081
7082New command ``info dos sysinfo'' displays assorted information about
7083the CPU, OS, memory, and DPMI server.
7084
7085New commands ``info dos gdt'', ``info dos ldt'', and ``info dos idt''
7086display information about segment descriptors stored in GDT, LDT, and
7087IDT.
7088
7089New commands ``info dos pde'' and ``info dos pte'' display entries
7090from Page Directory and Page Tables (for now works with CWSDPMI only).
7091New command ``info dos address-pte'' displays the Page Table entry for
7092a given linear address.
7093
7094GDB can now pass command lines longer than 126 characters to the
7095program being debugged (requires an update to the libdbg.a library
7096which is part of the DJGPP development kit).
7097
7098DWARF2 debug info is now supported.
7099
6c56c069
EZ
7100It is now possible to `step' and `next' through calls to `longjmp'.
7101
e23194cb
EZ
7102* Changes in documentation.
7103
7104All GDB documentation was converted to GFDL, the GNU Free
7105Documentation License.
7106
7107Tracepoints-related commands are now fully documented in the GDB
7108manual.
7109
7110TUI, the Text-mode User Interface, is now documented in the manual.
7111
7112Tracepoints-related commands are now fully documented in the GDB
7113manual.
7114
7115The "GDB Internals" manual now has an index. It also includes
7116documentation of `ui_out' functions, GDB coding standards, x86
7117hardware watchpoints, and memory region attributes.
7118
5d6640b1
AC
7119* GDB's version number moved to ``version.in''
7120
7121The Makefile variable VERSION has been replaced by the file
7122``version.in''. People creating GDB distributions should update the
7123contents of this file.
7124
1a1d8446
AC
7125* gdba.el deleted
7126
7127GUD support is now a standard part of the EMACS distribution.
139760b7 7128
9debab2f 7129*** Changes in GDB 5.0:
7a292a7a 7130
c63ce875
EZ
7131* Improved support for debugging FP programs on x86 targets
7132
7133Unified and much-improved support for debugging floating-point
7134programs on all x86 targets. In particular, ``info float'' now
7135displays the FP registers in the same format on all x86 targets, with
7136greater level of detail.
7137
7138* Improvements and bugfixes in hardware-assisted watchpoints
7139
7140It is now possible to watch array elements, struct members, and
7141bitfields with hardware-assisted watchpoints. Data-read watchpoints
7142on x86 targets no longer erroneously trigger when the address is
7143written.
7144
7145* Improvements in the native DJGPP version of GDB
7146
7147The distribution now includes all the scripts and auxiliary files
7148necessary to build the native DJGPP version on MS-DOS/MS-Windows
7149machines ``out of the box''.
7150
7151The DJGPP version can now debug programs that use signals. It is
7152possible to catch signals that happened in the debuggee, deliver
7153signals to it, interrupt it with Ctrl-C, etc. (Previously, a signal
7154would kill the program being debugged.) Programs that hook hardware
7155interrupts (keyboard, timer, etc.) can also be debugged.
7156
7157It is now possible to debug DJGPP programs that redirect their
7158standard handles or switch them to raw (as opposed to cooked) mode, or
7159even close them. The command ``run < foo > bar'' works as expected,
7160and ``info terminal'' reports useful information about the debuggee's
7161terminal, including raw/cooked mode, redirection, etc.
7162
7163The DJGPP version now uses termios functions for console I/O, which
7164enables debugging graphics programs. Interrupting GDB with Ctrl-C
7165also works.
7166
7167DOS-style file names with drive letters are now fully supported by
7168GDB.
7169
7170It is now possible to debug DJGPP programs that switch their working
7171directory. It is also possible to rerun the debuggee any number of
7172times without restarting GDB; thus, you can use the same setup,
7173breakpoints, etc. for many debugging sessions.
7174
ed9a39eb
JM
7175* New native configurations
7176
7177ARM GNU/Linux arm*-*-linux*
afc05dd4 7178PowerPC GNU/Linux powerpc-*-linux*
ed9a39eb 7179
7a292a7a
SS
7180* New targets
7181
96baa820 7182Motorola MCore mcore-*-*
adf40b2e
JM
7183x86 VxWorks i[3456]86-*-vxworks*
7184PowerPC VxWorks powerpc-*-vxworks*
7a292a7a
SS
7185TI TMS320C80 tic80-*-*
7186
085dd6e6
JM
7187* OBSOLETE configurations
7188
7189Altos 3068 m68*-altos-*
7190Convex c1-*-*, c2-*-*
9846de1b 7191Pyramid pyramid-*-*
ed9a39eb 7192ARM RISCix arm-*-* (as host)
104c1213 7193Tahoe tahoe-*-*
7a292a7a 7194
9debab2f
AC
7195Configurations that have been declared obsolete will be commented out,
7196but the code will be left in place. If there is no activity to revive
7197these configurations before the next release of GDB, the sources will
7198be permanently REMOVED.
7199
5330533d
SS
7200* Gould support removed
7201
7202Support for the Gould PowerNode and NP1 has been removed.
7203
bc9e5bbf
AC
7204* New features for SVR4
7205
7206On SVR4 native platforms (such as Solaris), if you attach to a process
7207without first loading a symbol file, GDB will now attempt to locate and
7208load symbols from the running process's executable file.
7209
7210* Many C++ enhancements
7211
7212C++ support has been greatly improved. Overload resolution now works properly
7213in almost all cases. RTTI support is on the way.
7214
adf40b2e
JM
7215* Remote targets can connect to a sub-program
7216
7217A popen(3) style serial-device has been added. This device starts a
7218sub-process (such as a stand-alone simulator) and then communicates
7219with that. The sub-program to run is specified using the syntax
7220``|<program> <args>'' vis:
7221
7222 (gdb) set remotedebug 1
7223 (gdb) target extended-remote |mn10300-elf-sim program-args
7224
43e526b9
JM
7225* MIPS 64 remote protocol
7226
7227A long standing bug in the mips64 remote protocol where by GDB
7228expected certain 32 bit registers (ex SR) to be transfered as 32
7229instead of 64 bits has been fixed.
7230
7231The command ``set remote-mips64-transfers-32bit-regs on'' has been
7232added to provide backward compatibility with older versions of GDB.
7233
96baa820
JM
7234* ``set remotebinarydownload'' replaced by ``set remote X-packet''
7235
7236The command ``set remotebinarydownload'' command has been replaced by
7237``set remote X-packet''. Other commands in ``set remote'' family
7238include ``set remote P-packet''.
7239
11cf8741
JM
7240* Breakpoint commands accept ranges.
7241
7242The breakpoint commands ``enable'', ``disable'', and ``delete'' now
7243accept a range of breakpoints, e.g. ``5-7''. The tracepoint command
7244``tracepoint passcount'' also accepts a range of tracepoints.
7245
7876dd43
DB
7246* ``apropos'' command added.
7247
7248The ``apropos'' command searches through command names and
7249documentation strings, printing out matches, making it much easier to
7250try to find a command that does what you are looking for.
7251
bc9e5bbf
AC
7252* New MI interface
7253
7254A new machine oriented interface (MI) has been added to GDB. This
7255interface is designed for debug environments running GDB as a separate
7162c0ca
EZ
7256process. This is part of the long term libGDB project. See the
7257"GDB/MI" chapter of the GDB manual for further information. It can be
7258enabled by configuring with:
bc9e5bbf
AC
7259
7260 .../configure --enable-gdbmi
7261
c906108c
SS
7262*** Changes in GDB-4.18:
7263
7264* New native configurations
7265
7266HP-UX 10.20 hppa*-*-hpux10.20
7267HP-UX 11.x hppa*-*-hpux11.0*
55241689 7268M68K GNU/Linux m68*-*-linux*
c906108c
SS
7269
7270* New targets
7271
7272Fujitsu FR30 fr30-*-elf*
7273Intel StrongARM strongarm-*-*
7274Mitsubishi D30V d30v-*-*
7275
7276* OBSOLETE configurations
7277
7278Gould PowerNode, NP1 np1-*-*, pn-*-*
7279
7280Configurations that have been declared obsolete will be commented out,
7281but the code will be left in place. If there is no activity to revive
7282these configurations before the next release of GDB, the sources will
7283be permanently REMOVED.
7284
7285* ANSI/ISO C
7286
7287As a compatibility experiment, GDB's source files buildsym.h and
7288buildsym.c have been converted to pure standard C, no longer
7289containing any K&R compatibility code. We believe that all systems in
7290use today either come with a standard C compiler, or have a GCC port
7291available. If this is not true, please report the affected
7292configuration to bug-gdb@gnu.org immediately. See the README file for
7293information about getting a standard C compiler if you don't have one
7294already.
7295
7296* Readline 2.2
7297
7298GDB now uses readline 2.2.
7299
7300* set extension-language
7301
7302You can now control the mapping between filename extensions and source
7303languages by using the `set extension-language' command. For instance,
7304you can ask GDB to treat .c files as C++ by saying
7305 set extension-language .c c++
7306The command `info extensions' lists all of the recognized extensions
7307and their associated languages.
7308
7309* Setting processor type for PowerPC and RS/6000
7310
7311When GDB is configured for a powerpc*-*-* or an rs6000*-*-* target,
7312you can use the `set processor' command to specify what variant of the
7313PowerPC family you are debugging. The command
7314
7315 set processor NAME
7316
7317sets the PowerPC/RS6000 variant to NAME. GDB knows about the
7318following PowerPC and RS6000 variants:
7319
7320 ppc-uisa PowerPC UISA - a PPC processor as viewed by user-level code
7321 rs6000 IBM RS6000 ("POWER") architecture, user-level view
7322 403 IBM PowerPC 403
7323 403GC IBM PowerPC 403GC
7324 505 Motorola PowerPC 505
7325 860 Motorola PowerPC 860 or 850
7326 601 Motorola PowerPC 601
7327 602 Motorola PowerPC 602
7328 603 Motorola/IBM PowerPC 603 or 603e
7329 604 Motorola PowerPC 604 or 604e
7330 750 Motorola/IBM PowerPC 750 or 750
7331
7332At the moment, this command just tells GDB what to name the
7333special-purpose processor registers. Since almost all the affected
7334registers are inaccessible to user-level programs, this command is
7335only useful for remote debugging in its present form.
7336
7337* HP-UX support
7338
7339Thanks to a major code donation from Hewlett-Packard, GDB now has much
7340more extensive support for HP-UX. Added features include shared
7341library support, kernel threads and hardware watchpoints for 11.00,
7342support for HP's ANSI C and C++ compilers, and a compatibility mode
7343for xdb and dbx commands.
7344
7345* Catchpoints
7346
7347HP's donation includes the new concept of catchpoints, which is a
7348generalization of the old catch command. On HP-UX, it is now possible
7349to catch exec, fork, and vfork, as well as library loading.
7350
7351This means that the existing catch command has changed; its first
7352argument now specifies the type of catch to be set up. See the
7353output of "help catch" for a list of catchpoint types.
7354
7355* Debugging across forks
7356
7357On HP-UX, you can choose which process to debug when a fork() happens
7358in the inferior.
7359
7360* TUI
7361
7362HP has donated a curses-based terminal user interface (TUI). To get
7363it, build with --enable-tui. Although this can be enabled for any
7364configuration, at present it only works for native HP debugging.
7365
7366* GDB remote protocol additions
7367
7368A new protocol packet 'X' that writes binary data is now available.
7369Default behavior is to try 'X', then drop back to 'M' if the stub
7370fails to respond. The settable variable `remotebinarydownload'
7371allows explicit control over the use of 'X'.
7372
7373For 64-bit targets, the memory packets ('M' and 'm') can now contain a
7374full 64-bit address. The command
7375
7376 set remoteaddresssize 32
7377
7378can be used to revert to the old behaviour. For existing remote stubs
7379the change should not be noticed, as the additional address information
7380will be discarded.
7381
7382In order to assist in debugging stubs, you may use the maintenance
7383command `packet' to send any text string to the stub. For instance,
7384
7385 maint packet heythere
7386
7387sends the packet "$heythere#<checksum>". Note that it is very easy to
7388disrupt a debugging session by sending the wrong packet at the wrong
7389time.
7390
7391The compare-sections command allows you to compare section data on the
7392target to what is in the executable file without uploading or
7393downloading, by comparing CRC checksums.
7394
7395* Tracing can collect general expressions
7396
7397You may now collect general expressions at tracepoints. This requires
7398further additions to the target-side stub; see tracepoint.c and
7399doc/agentexpr.texi for further details.
7400
7401* mask-address variable for Mips
7402
7403For Mips targets, you may control the zeroing of the upper 32 bits of
7404a 64-bit address by entering `set mask-address on'. This is mainly
7405of interest to users of embedded R4xxx and R5xxx processors.
7406
7407* Higher serial baud rates
7408
7409GDB's serial code now allows you to specify baud rates 57600, 115200,
7410230400, and 460800 baud. (Note that your host system may not be able
7411to achieve all of these rates.)
7412
7413* i960 simulator
7414
7415The i960 configuration now includes an initial implementation of a
7416builtin simulator, contributed by Jim Wilson.
7417
7418
7419*** Changes in GDB-4.17:
7420
7421* New native configurations
7422
7423Alpha GNU/Linux alpha*-*-linux*
7424Unixware 2.x i[3456]86-unixware2*
7425Irix 6.x mips*-sgi-irix6*
7426PowerPC GNU/Linux powerpc-*-linux*
7427PowerPC Solaris powerpcle-*-solaris*
7428Sparc GNU/Linux sparc-*-linux*
7429Motorola sysV68 R3V7.1 m68k-motorola-sysv
7430
7431* New targets
7432
7433Argonaut Risc Chip (ARC) arc-*-*
7434Hitachi H8/300S h8300*-*-*
7435Matsushita MN10200 w/simulator mn10200-*-*
7436Matsushita MN10300 w/simulator mn10300-*-*
7437MIPS NEC VR4100 mips64*vr4100*{,el}-*-elf*
7438MIPS NEC VR5000 mips64*vr5000*{,el}-*-elf*
7439MIPS Toshiba TX39 mips64*tx39*{,el}-*-elf*
7440Mitsubishi D10V w/simulator d10v-*-*
7441Mitsubishi M32R/D w/simulator m32r-*-elf*
7442Tsqware Sparclet sparclet-*-*
7443NEC V850 w/simulator v850-*-*
7444
7445* New debugging protocols
7446
7447ARM with RDI protocol arm*-*-*
7448M68K with dBUG monitor m68*-*-{aout,coff,elf}
7449DDB and LSI variants of PMON protocol mips*-*-*
7450PowerPC with DINK32 monitor powerpc{,le}-*-eabi
7451PowerPC with SDS protocol powerpc{,le}-*-eabi
7452Macraigor OCD (Wiggler) devices powerpc{,le}-*-eabi
7453
7454* DWARF 2
7455
7456All configurations can now understand and use the DWARF 2 debugging
7457format. The choice is automatic, if the symbol file contains DWARF 2
7458information.
7459
7460* Java frontend
7461
7462GDB now includes basic Java language support. This support is
7463only useful with Java compilers that produce native machine code.
7464
7465* solib-absolute-prefix and solib-search-path
7466
7467For SunOS and SVR4 shared libraries, you may now set the prefix for
7468loading absolute shared library symbol files, and the search path for
7469locating non-absolute shared library symbol files.
7470
7471* Live range splitting
7472
7473GDB can now effectively debug code for which GCC has performed live
7474range splitting as part of its optimization. See gdb/doc/LRS for
7475more details on the expected format of the stabs information.
7476
7477* Hurd support
7478
7479GDB's support for the GNU Hurd, including thread debugging, has been
7480updated to work with current versions of the Hurd.
7481
7482* ARM Thumb support
7483
7484GDB's ARM target configuration now handles the ARM7T (Thumb) 16-bit
7485instruction set. ARM GDB automatically detects when Thumb
7486instructions are in use, and adjusts disassembly and backtracing
7487accordingly.
7488
7489* MIPS16 support
7490
7491GDB's MIPS target configurations now handle the MIP16 16-bit
7492instruction set.
7493
7494* Overlay support
7495
7496GDB now includes support for overlays; if an executable has been
7497linked such that multiple sections are based at the same address, GDB
7498will decide which section to use for symbolic info. You can choose to
7499control the decision manually, using overlay commands, or implement
7500additional target-side support and use "overlay load-target" to bring
7501in the overlay mapping. Do "help overlay" for more detail.
7502
7503* info symbol
7504
7505The command "info symbol <address>" displays information about
7506the symbol at the specified address.
7507
7508* Trace support
7509
7510The standard remote protocol now includes an extension that allows
7511asynchronous collection and display of trace data. This requires
7512extensive support in the target-side debugging stub. Tracing mode
7513includes a new interaction mode in GDB and new commands: see the
7514file tracepoint.c for more details.
7515
7516* MIPS simulator
7517
7518Configurations for embedded MIPS now include a simulator contributed
7519by Cygnus Solutions. The simulator supports the instruction sets
7520of most MIPS variants.
7521
7522* Sparc simulator
7523
7524Sparc configurations may now include the ERC32 simulator contributed
7525by the European Space Agency. The simulator is not built into
7526Sparc targets by default; configure with --enable-sim to include it.
7527
7528* set architecture
7529
7530For target configurations that may include multiple variants of a
7531basic architecture (such as MIPS and SH), you may now set the
7532architecture explicitly. "set arch" sets, "info arch" lists
7533the possible architectures.
7534
7535*** Changes in GDB-4.16:
7536
7537* New native configurations
7538
7539Windows 95, x86 Windows NT i[345]86-*-cygwin32
7540M68K NetBSD m68k-*-netbsd*
7541PowerPC AIX 4.x powerpc-*-aix*
7542PowerPC MacOS powerpc-*-macos*
7543PowerPC Windows NT powerpcle-*-cygwin32
7544RS/6000 AIX 4.x rs6000-*-aix4*
7545
7546* New targets
7547
7548ARM with RDP protocol arm-*-*
7549I960 with MON960 i960-*-coff
7550MIPS VxWorks mips*-*-vxworks*
7551MIPS VR4300 with PMON mips64*vr4300{,el}-*-elf*
7552PowerPC with PPCBUG monitor powerpc{,le}-*-eabi*
7553Hitachi SH3 sh-*-*
7554Matra Sparclet sparclet-*-*
7555
7556* PowerPC simulator
7557
7558The powerpc-eabi configuration now includes the PSIM simulator,
7559contributed by Andrew Cagney, with assistance from Mike Meissner.
7560PSIM is a very elaborate model of the PowerPC, including not only
7561basic instruction set execution, but also details of execution unit
7562performance and I/O hardware. See sim/ppc/README for more details.
7563
7564* Solaris 2.5
7565
7566GDB now works with Solaris 2.5.
7567
7568* Windows 95/NT native
7569
7570GDB will now work as a native debugger on Windows 95 and Windows NT.
7571To build it from source, you must use the "gnu-win32" environment,
7572which uses a DLL to emulate enough of Unix to run the GNU tools.
7573Further information, binaries, and sources are available at
7574ftp.cygnus.com, under pub/gnu-win32.
7575
7576* dont-repeat command
7577
7578If a user-defined command includes the command `dont-repeat', then the
7579command will not be repeated if the user just types return. This is
7580useful if the command is time-consuming to run, so that accidental
7581extra keystrokes don't run the same command many times.
7582
7583* Send break instead of ^C
7584
7585The standard remote protocol now includes an option to send a break
7586rather than a ^C to the target in order to interrupt it. By default,
7587GDB will send ^C; to send a break, set the variable `remotebreak' to 1.
7588
7589* Remote protocol timeout
7590
7591The standard remote protocol includes a new variable `remotetimeout'
7592that allows you to set the number of seconds before GDB gives up trying
7593to read from the target. The default value is 2.
7594
7595* Automatic tracking of dynamic object loading (HPUX and Solaris only)
7596
7597By default GDB will automatically keep track of objects as they are
7598loaded and unloaded by the dynamic linker. By using the command `set
7599stop-on-solib-events 1' you can arrange for GDB to stop the inferior
7600when shared library events occur, thus allowing you to set breakpoints
7601in shared libraries which are explicitly loaded by the inferior.
7602
7603Note this feature does not work on hpux8. On hpux9 you must link
7604/usr/lib/end.o into your program. This feature should work
7605automatically on hpux10.
7606
7607* Irix 5.x hardware watchpoint support
7608
7609Irix 5 configurations now support the use of hardware watchpoints.
7610
7611* Mips protocol "SYN garbage limit"
7612
7613When debugging a Mips target using the `target mips' protocol, you
7614may set the number of characters that GDB will ignore by setting
7615the `syn-garbage-limit'. A value of -1 means that GDB will ignore
7616every character. The default value is 1050.
7617
7618* Recording and replaying remote debug sessions
7619
7620If you set `remotelogfile' to the name of a file, gdb will write to it
7621a recording of a remote debug session. This recording may then be
7622replayed back to gdb using "gdbreplay". See gdbserver/README for
7623details. This is useful when you have a problem with GDB while doing
7624remote debugging; you can make a recording of the session and send it
7625to someone else, who can then recreate the problem.
7626
7627* Speedups for remote debugging
7628
7629GDB includes speedups for downloading and stepping MIPS systems using
7630the IDT monitor, fast downloads to the Hitachi SH E7000 emulator,
7631and more efficient S-record downloading.
7632
7633* Memory use reductions and statistics collection
7634
7635GDB now uses less memory and reports statistics about memory usage.
7636Try the `maint print statistics' command, for example.
7637
7638*** Changes in GDB-4.15:
7639
7640* Psymtabs for XCOFF
7641
7642The symbol reader for AIX GDB now uses partial symbol tables. This
7643can greatly improve startup time, especially for large executables.
7644
7645* Remote targets use caching
7646
7647Remote targets now use a data cache to speed up communication with the
7648remote side. The data cache could lead to incorrect results because
7649it doesn't know about volatile variables, thus making it impossible to
7650debug targets which use memory mapped I/O devices. `set remotecache
09f2921c 7651off' turns the data cache off.
c906108c
SS
7652
7653* Remote targets may have threads
7654
7655The standard remote protocol now includes support for multiple threads
7656in the target system, using new protocol commands 'H' and 'T'. See
7657gdb/remote.c for details.
7658
7659* NetROM support
7660
7661If GDB is configured with `--enable-netrom', then it will include
7662support for the NetROM ROM emulator from XLNT Designs. The NetROM
7663acts as though it is a bank of ROM on the target board, but you can
7664write into it over the network. GDB's support consists only of
7665support for fast loading into the emulated ROM; to debug, you must use
7666another protocol, such as standard remote protocol. The usual
7667sequence is something like
7668
7669 target nrom <netrom-hostname>
7670 load <prog>
7671 target remote <netrom-hostname>:1235
7672
7673* Macintosh host
7674
7675GDB now includes support for the Apple Macintosh, as a host only. It
7676may be run as either an MPW tool or as a standalone application, and
7677it can debug through the serial port. All the usual GDB commands are
7678available, but to the target command, you must supply "serial" as the
7679device type instead of "/dev/ttyXX". See mpw-README in the main
7680directory for more information on how to build. The MPW configuration
7681scripts */mpw-config.in support only a few targets, and only the
7682mips-idt-ecoff target has been tested.
7683
7684* Autoconf
7685
7686GDB configuration now uses autoconf. This is not user-visible,
7687but does simplify configuration and building.
7688
7689* hpux10
7690
7691GDB now supports hpux10.
7692
7693*** Changes in GDB-4.14:
7694
7695* New native configurations
7696
7697x86 FreeBSD i[345]86-*-freebsd
7698x86 NetBSD i[345]86-*-netbsd
7699NS32k NetBSD ns32k-*-netbsd
7700Sparc NetBSD sparc-*-netbsd
7701
7702* New targets
7703
7704A29K VxWorks a29k-*-vxworks
7705HP PA PRO embedded (WinBond W89K & Oki OP50N) hppa*-*-pro*
7706CPU32 EST-300 emulator m68*-*-est*
7707PowerPC ELF powerpc-*-elf
7708WDC 65816 w65-*-*
7709
7710* Alpha OSF/1 support for procfs
7711
7712GDB now supports procfs under OSF/1-2.x and higher, which makes it
7713possible to attach to running processes. As the mounting of the /proc
7714filesystem is optional on the Alpha, GDB automatically determines
7715the availability of /proc during startup. This can lead to problems
7716if /proc is unmounted after GDB has been started.
7717
7718* Arguments to user-defined commands
7719
7720User commands may accept up to 10 arguments separated by whitespace.
7721Arguments are accessed within the user command via $arg0..$arg9. A
7722trivial example:
7723define adder
7724 print $arg0 + $arg1 + $arg2
7725
7726To execute the command use:
7727adder 1 2 3
7728
7729Defines the command "adder" which prints the sum of its three arguments.
7730Note the arguments are text substitutions, so they may reference variables,
7731use complex expressions, or even perform inferior function calls.
7732
7733* New `if' and `while' commands
7734
7735This makes it possible to write more sophisticated user-defined
7736commands. Both commands take a single argument, which is the
7737expression to evaluate, and must be followed by the commands to
7738execute, one per line, if the expression is nonzero, the list being
7739terminated by the word `end'. The `if' command list may include an
7740`else' word, which causes the following commands to be executed only
7741if the expression is zero.
7742
7743* Fortran source language mode
7744
7745GDB now includes partial support for Fortran 77. It will recognize
7746Fortran programs and can evaluate a subset of Fortran expressions, but
7747variables and functions may not be handled correctly. GDB will work
7748with G77, but does not yet know much about symbols emitted by other
7749Fortran compilers.
7750
7751* Better HPUX support
7752
7753Most debugging facilities now work on dynamic executables for HPPAs
7754running hpux9 or later. You can attach to running dynamically linked
7755processes, but by default the dynamic libraries will be read-only, so
7756for instance you won't be able to put breakpoints in them. To change
7757that behavior do the following before running the program:
7758
7759 adb -w a.out
7760 __dld_flags?W 0x5
7761 control-d
7762
7763This will cause the libraries to be mapped private and read-write.
7764To revert to the normal behavior, do this:
7765
7766 adb -w a.out
7767 __dld_flags?W 0x4
7768 control-d
7769
7770You cannot set breakpoints or examine data in the library until after
7771the library is loaded if the function/data symbols do not have
7772external linkage.
7773
7774GDB can now also read debug symbols produced by the HP C compiler on
7775HPPAs (sorry, no C++, Fortran or 68k support).
7776
7777* Target byte order now dynamically selectable
7778
7779You can choose which byte order to use with a target system, via the
7780commands "set endian big" and "set endian little", and you can see the
7781current setting by using "show endian". You can also give the command
7782"set endian auto", in which case GDB will use the byte order
7783associated with the executable. Currently, only embedded MIPS
7784configurations support dynamic selection of target byte order.
7785
7786* New DOS host serial code
7787
7788This version uses DPMI interrupts to handle buffered I/O, so you
7789no longer need to run asynctsr when debugging boards connected to
7790a PC's serial port.
7791
7792*** Changes in GDB-4.13:
7793
7794* New "complete" command
7795
7796This lists all the possible completions for the rest of the line, if it
7797were to be given as a command itself. This is intended for use by emacs.
7798
7799* Trailing space optional in prompt
7800
7801"set prompt" no longer adds a space for you after the prompt you set. This
7802allows you to set a prompt which ends in a space or one that does not.
7803
7804* Breakpoint hit counts
7805
7806"info break" now displays a count of the number of times the breakpoint
7807has been hit. This is especially useful in conjunction with "ignore"; you
7808can ignore a large number of breakpoint hits, look at the breakpoint info
7809to see how many times the breakpoint was hit, then run again, ignoring one
7810less than that number, and this will get you quickly to the last hit of
7811that breakpoint.
7812
7813* Ability to stop printing at NULL character
7814
7815"set print null-stop" will cause GDB to stop printing the characters of
7816an array when the first NULL is encountered. This is useful when large
7817arrays actually contain only short strings.
7818
7819* Shared library breakpoints
7820
7821In SunOS 4.x, SVR4, and Alpha OSF/1 configurations, you can now set
7822breakpoints in shared libraries before the executable is run.
7823
7824* Hardware watchpoints
7825
7826There is a new hardware breakpoint for the watch command for sparclite
7827targets. See gdb/sparclite/hw_breakpoint.note.
7828
55241689 7829Hardware watchpoints are also now supported under GNU/Linux.
c906108c
SS
7830
7831* Annotations
7832
7833Annotations have been added. These are for use with graphical interfaces,
7834and are still experimental. Currently only gdba.el uses these.
7835
7836* Improved Irix 5 support
7837
7838GDB now works properly with Irix 5.2.
7839
7840* Improved HPPA support
7841
7842GDB now works properly with the latest GCC and GAS.
7843
7844* New native configurations
7845
7846Sequent PTX4 i[34]86-sequent-ptx4
7847HPPA running OSF/1 hppa*-*-osf*
7848Atari TT running SVR4 m68*-*-sysv4*
7849RS/6000 LynxOS rs6000-*-lynxos*
7850
7851* New targets
7852
7853OS/9000 i[34]86-*-os9k
7854MIPS R4000 mips64*{,el}-*-{ecoff,elf}
7855Sparc64 sparc64-*-*
7856
7857* Hitachi SH7000 and E7000-PC ICE support
7858
7859There is now support for communicating with the Hitachi E7000-PC ICE.
7860This is available automatically when GDB is configured for the SH.
7861
7862* Fixes
7863
7864As usual, a variety of small fixes and improvements, both generic
7865and configuration-specific. See the ChangeLog for more detail.
7866
7867*** Changes in GDB-4.12:
7868
7869* Irix 5 is now supported
7870
7871* HPPA support
7872
7873GDB-4.12 on the HPPA has a number of changes which make it unable
7874to debug the output from the currently released versions of GCC and
7875GAS (GCC 2.5.8 and GAS-2.2 or PAGAS-1.36). Until the next major release
7876of GCC and GAS, versions of these tools designed to work with GDB-4.12
7877can be retrieved via anonymous ftp from jaguar.cs.utah.edu:/dist.
7878
7879
7880*** Changes in GDB-4.11:
7881
7882* User visible changes:
7883
7884* Remote Debugging
7885
7886The "set remotedebug" option is now consistent between the mips remote
7887target, remote targets using the gdb-specific protocol, UDI (AMD's
7888debug protocol for the 29k) and the 88k bug monitor. It is now an
7889integer specifying a debug level (normally 0 or 1, but 2 means more
7890debugging info for the mips target).
7891
7892* DEC Alpha native support
7893
7894GDB now works on the DEC Alpha. GCC 2.4.5 does not produce usable
7895debug info, but GDB works fairly well with the DEC compiler and should
7896work with a future GCC release. See the README file for a few
7897Alpha-specific notes.
7898
7899* Preliminary thread implementation
7900
7901GDB now has preliminary thread support for both SGI/Irix and LynxOS.
7902
7903* LynxOS native and target support for 386
7904
7905This release has been hosted on LynxOS 2.2, and also can be configured
7906to remotely debug programs running under LynxOS (see gdb/gdbserver/README
7907for details).
7908
7909* Improvements in C++ mangling/demangling.
7910
7911This release has much better g++ debugging, specifically in name
7912mangling/demangling, virtual function calls, print virtual table,
7913call methods, ...etc.
7914
7915*** Changes in GDB-4.10:
7916
7917 * User visible changes:
7918
7919Remote debugging using the GDB-specific (`target remote') protocol now
7920supports the `load' command. This is only useful if you have some
7921other way of getting the stub to the target system, and you can put it
7922somewhere in memory where it won't get clobbered by the download.
7923
7924Filename completion now works.
7925
7926When run under emacs mode, the "info line" command now causes the
7927arrow to point to the line specified. Also, "info line" prints
7928addresses in symbolic form (as well as hex).
7929
7930All vxworks based targets now support a user settable option, called
7931vxworks-timeout. This option represents the number of seconds gdb
7932should wait for responses to rpc's. You might want to use this if
7933your vxworks target is, perhaps, a slow software simulator or happens
7934to be on the far side of a thin network line.
7935
7936 * DEC alpha support
7937
7938This release contains support for using a DEC alpha as a GDB host for
7939cross debugging. Native alpha debugging is not supported yet.
7940
7941
7942*** Changes in GDB-4.9:
7943
7944 * Testsuite
7945
7946This is the first GDB release which is accompanied by a matching testsuite.
7947The testsuite requires installation of dejagnu, which should be available
7948via ftp from most sites that carry GNU software.
7949
7950 * C++ demangling
7951
7952'Cfront' style demangling has had its name changed to 'ARM' style, to
7953emphasize that it was written from the specifications in the C++ Annotated
7954Reference Manual, not necessarily to be compatible with AT&T cfront. Despite
7955disclaimers, it still generated too much confusion with users attempting to
7956use gdb with AT&T cfront.
7957
7958 * Simulators
7959
7960GDB now uses a standard remote interface to a simulator library.
7961So far, the library contains simulators for the Zilog Z8001/2, the
7962Hitachi H8/300, H8/500 and Super-H.
7963
7964 * New targets supported
7965
7966H8/300 simulator h8300-hitachi-hms or h8300hms
7967H8/500 simulator h8500-hitachi-hms or h8500hms
7968SH simulator sh-hitachi-hms or sh
7969Z8000 simulator z8k-zilog-none or z8ksim
7970IDT MIPS board over serial line mips-idt-ecoff
7971
7972Cross-debugging to GO32 targets is supported. It requires a custom
7973version of the i386-stub.c module which is integrated with the
7974GO32 memory extender.
7975
7976 * New remote protocols
7977
7978MIPS remote debugging protocol.
7979
7980 * New source languages supported
7981
7982This version includes preliminary support for Chill, a Pascal like language
7983used by telecommunications companies. Chill support is also being integrated
7984into the GNU compiler, but we don't know when it will be publically available.
7985
7986
7987*** Changes in GDB-4.8:
7988
7989 * HP Precision Architecture supported
7990
7991GDB now supports HP PA-RISC machines running HPUX. A preliminary
7992version of this support was available as a set of patches from the
7993University of Utah. GDB does not support debugging of programs
7994compiled with the HP compiler, because HP will not document their file
7995format. Instead, you must use GCC (version 2.3.2 or later) and PA-GAS
7996(as available from jaguar.cs.utah.edu:/dist/pa-gas.u4.tar.Z).
7997
7998Many problems in the preliminary version have been fixed.
7999
8000 * Faster and better demangling
8001
8002We have improved template demangling and fixed numerous bugs in the GNU style
8003demangler. It can now handle type modifiers such as `static' or `const'. Wide
8004character types (wchar_t) are now supported. Demangling of each symbol is now
8005only done once, and is cached when the symbol table for a file is read in.
8006This results in a small increase in memory usage for C programs, a moderate
8007increase in memory usage for C++ programs, and a fantastic speedup in
8008symbol lookups.
8009
8010`Cfront' style demangling still doesn't work with AT&T cfront. It was written
8011from the specifications in the Annotated Reference Manual, which AT&T's
8012compiler does not actually implement.
8013
8014 * G++ multiple inheritance compiler problem
8015
8016In the 2.3.2 release of gcc/g++, how the compiler resolves multiple
8017inheritance lattices was reworked to properly discover ambiguities. We
8018recently found an example which causes this new algorithm to fail in a
8019very subtle way, producing bad debug information for those classes.
8020The file 'gcc.patch' (in this directory) can be applied to gcc to
8021circumvent the problem. A future GCC release will contain a complete
8022fix.
8023
8024The previous G++ debug info problem (mentioned below for the gdb-4.7
8025release) is fixed in gcc version 2.3.2.
8026
8027 * Improved configure script
8028
8029The `configure' script will now attempt to guess your system type if
8030you don't supply a host system type. The old scheme of supplying a
8031host system triplet is preferable over using this. All the magic is
8032done in the new `config.guess' script. Examine it for details.
8033
8034We have also brought our configure script much more in line with the FSF's
8035version. It now supports the --with-xxx options. In particular,
8036`--with-minimal-bfd' can be used to make the GDB binary image smaller.
8037The resulting GDB will not be able to read arbitrary object file formats --
8038only the format ``expected'' to be used on the configured target system.
8039We hope to make this the default in a future release.
8040
8041 * Documentation improvements
8042
8043There's new internal documentation on how to modify GDB, and how to
8044produce clean changes to the code. We implore people to read it
8045before submitting changes.
8046
8047The GDB manual uses new, sexy Texinfo conditionals, rather than arcane
8048M4 macros. The new texinfo.tex is provided in this release. Pre-built
8049`info' files are also provided. To build `info' files from scratch,
8050you will need the latest `makeinfo' release, which will be available in
8051a future texinfo-X.Y release.
8052
8053*NOTE* The new texinfo.tex can cause old versions of TeX to hang.
8054We're not sure exactly which versions have this problem, but it has
8055been seen in 3.0. We highly recommend upgrading to TeX version 3.141
8056or better. If that isn't possible, there is a patch in
8057`texinfo/tex3patch' that will modify `texinfo/texinfo.tex' to work
8058around this problem.
8059
8060 * New features
8061
8062GDB now supports array constants that can be used in expressions typed in by
8063the user. The syntax is `{element, element, ...}'. Ie: you can now type
8064`print {1, 2, 3}', and it will build up an array in memory malloc'd in
8065the target program.
8066
8067The new directory `gdb/sparclite' contains a program that demonstrates
8068how the sparc-stub.c remote stub runs on a Fujitsu SPARClite processor.
8069
8070 * New native hosts supported
8071
8072HP/PA-RISC under HPUX using GNU tools hppa1.1-hp-hpux
8073386 CPUs running SCO Unix 3.2v4 i386-unknown-sco3.2v4
8074
8075 * New targets supported
8076
8077AMD 29k family via UDI a29k-amd-udi or udi29k
8078
8079 * New file formats supported
8080
8081BFD now supports reading HP/PA-RISC executables (SOM file format?),
8082HPUX core files, and SCO 3.2v2 core files.
8083
8084 * Major bug fixes
8085
8086Attaching to processes now works again; thanks for the many bug reports.
8087
8088We have also stomped on a bunch of core dumps caused by
8089printf_filtered("%s") problems.
8090
8091We eliminated a copyright problem on the rpc and ptrace header files
8092for VxWorks, which was discovered at the last minute during the 4.7
8093release. You should now be able to build a VxWorks GDB.
8094
8095You can now interrupt gdb while an attached process is running. This
8096will cause the attached process to stop, and give control back to GDB.
8097
8098We fixed problems caused by using too many file descriptors
8099for reading symbols from object files and libraries. This was
8100especially a problem for programs that used many (~100) shared
8101libraries.
8102
8103The `step' command now only enters a subroutine if there is line number
8104information for the subroutine. Otherwise it acts like the `next'
8105command. Previously, `step' would enter subroutines if there was
8106any debugging information about the routine. This avoids problems
8107when using `cc -g1' on MIPS machines.
8108
8109 * Internal improvements
8110
8111GDB's internal interfaces have been improved to make it easier to support
8112debugging of multiple languages in the future.
8113
8114GDB now uses a common structure for symbol information internally.
8115Minimal symbols (derived from linkage symbols in object files), partial
8116symbols (from a quick scan of debug information), and full symbols
8117contain a common subset of information, making it easier to write
8118shared code that handles any of them.
8119
8120 * New command line options
8121
8122We now accept --silent as an alias for --quiet.
8123
8124 * Mmalloc licensing
8125
8126The memory-mapped-malloc library is now licensed under the GNU Library
8127General Public License.
8128
8129*** Changes in GDB-4.7:
8130
8131 * Host/native/target split
8132
8133GDB has had some major internal surgery to untangle the support for
8134hosts and remote targets. Now, when you configure GDB for a remote
8135target, it will no longer load in all of the support for debugging
8136local programs on the host. When fully completed and tested, this will
8137ensure that arbitrary host/target combinations are possible.
8138
8139The primary conceptual shift is to separate the non-portable code in
8140GDB into three categories. Host specific code is required any time GDB
8141is compiled on that host, regardless of the target. Target specific
8142code relates to the peculiarities of the target, but can be compiled on
8143any host. Native specific code is everything else: it can only be
8144built when the host and target are the same system. Child process
8145handling and core file support are two common `native' examples.
8146
8147GDB's use of /proc for controlling Unix child processes is now cleaner.
8148It has been split out into a single module under the `target_ops' vector,
8149plus two native-dependent functions for each system that uses /proc.
8150
8151 * New hosts supported
8152
8153HP/Apollo 68k (under the BSD domain) m68k-apollo-bsd or apollo68bsd
8154386 CPUs running various BSD ports i386-unknown-bsd or 386bsd
8155386 CPUs running SCO Unix i386-unknown-scosysv322 or i386sco
8156
8157 * New targets supported
8158
8159Fujitsu SPARClite sparclite-fujitsu-none or sparclite
816068030 and CPU32 m68030-*-*, m68332-*-*
8161
8162 * New native hosts supported
8163
8164386 CPUs running various BSD ports i386-unknown-bsd or 386bsd
8165 (386bsd is not well tested yet)
8166386 CPUs running SCO Unix i386-unknown-scosysv322 or sco
8167
8168 * New file formats supported
8169
8170BFD now supports COFF files for the Zilog Z8000 microprocessor. It
8171supports reading of `a.out.adobe' object files, which are an a.out
8172format extended with minimal information about multiple sections.
8173
8174 * New commands
8175
8176`show copying' is the same as the old `info copying'.
8177`show warranty' is the same as `info warrantee'.
8178These were renamed for consistency. The old commands continue to work.
8179
8180`info handle' is a new alias for `info signals'.
8181
8182You can now define pre-command hooks, which attach arbitrary command
8183scripts to any command. The commands in the hook will be executed
8184prior to the user's command. You can also create a hook which will be
8185executed whenever the program stops. See gdb.texinfo.
8186
8187 * C++ improvements
8188
8189We now deal with Cfront style name mangling, and can even extract type
8190info from mangled symbols. GDB can automatically figure out which
8191symbol mangling style your C++ compiler uses.
8192
8193Calling of methods and virtual functions has been improved as well.
8194
8195 * Major bug fixes
8196
82f06518 8197The crash that occurred when debugging Sun Ansi-C compiled binaries is
c906108c
SS
8198fixed. This was due to mishandling of the extra N_SO stabs output
8199by the compiler.
8200
8201We also finally got Ultrix 4.2 running in house, and fixed core file
8202support, with help from a dozen people on the net.
8203
8204John M. Farrell discovered that the reason that single-stepping was so
8205slow on all of the Mips based platforms (primarily SGI and DEC) was
8206that we were trying to demangle and lookup a symbol used for internal
8207purposes on every instruction that was being stepped through. Changing
8208the name of that symbol so that it couldn't be mistaken for a C++
8209mangled symbol sped things up a great deal.
8210
8211Rich Pixley sped up symbol lookups in general by getting much smarter
8212about when C++ symbol mangling is necessary. This should make symbol
8213completion (TAB on the command line) much faster. It's not as fast as
8214we'd like, but it's significantly faster than gdb-4.6.
8215
8216 * AMD 29k support
8217
8218A new user controllable variable 'call_scratch_address' can
8219specify the location of a scratch area to be used when GDB
8220calls a function in the target. This is necessary because the
8221usual method of putting the scratch area on the stack does not work
8222in systems that have separate instruction and data spaces.
8223
8224We integrated changes to support the 29k UDI (Universal Debugger
8225Interface), but discovered at the last minute that we didn't have all
8226of the appropriate copyright paperwork. We are working with AMD to
8227resolve this, and hope to have it available soon.
8228
8229 * Remote interfaces
8230
8231We have sped up the remote serial line protocol, especially for targets
8232with lots of registers. It now supports a new `expedited status' ('T')
8233message which can be used in place of the existing 'S' status message.
8234This allows the remote stub to send only the registers that GDB
8235needs to make a quick decision about single-stepping or conditional
8236breakpoints, eliminating the need to fetch the entire register set for
8237each instruction being stepped through.
8238
8239The GDB remote serial protocol now implements a write-through cache for
8240registers, only re-reading the registers if the target has run.
8241
8242There is also a new remote serial stub for SPARC processors. You can
8243find it in gdb-4.7/gdb/sparc-stub.c. This was written to support the
8244Fujitsu SPARClite processor, but will run on any stand-alone SPARC
8245processor with a serial port.
8246
8247 * Configuration
8248
8249Configure.in files have become much easier to read and modify. A new
8250`table driven' format makes it more obvious what configurations are
8251supported, and what files each one uses.
8252
8253 * Library changes
8254
8255There is a new opcodes library which will eventually contain all of the
8256disassembly routines and opcode tables. At present, it only contains
8257Sparc and Z8000 routines. This will allow the assembler, debugger, and
8258disassembler (binutils/objdump) to share these routines.
8259
8260The libiberty library is now copylefted under the GNU Library General
8261Public License. This allows more liberal use, and was done so libg++
8262can use it. This makes no difference to GDB, since the Library License
8263grants all the rights from the General Public License.
8264
8265 * Documentation
8266
8267The file gdb-4.7/gdb/doc/stabs.texinfo is a (relatively) complete
8268reference to the stabs symbol info used by the debugger. It is (as far
8269as we know) the only published document on this fascinating topic. We
8270encourage you to read it, compare it to the stabs information on your
8271system, and send improvements on the document in general (to
8272bug-gdb@prep.ai.mit.edu).
8273
8274And, of course, many bugs have been fixed.
8275
8276
8277*** Changes in GDB-4.6:
8278
8279 * Better support for C++ function names
8280
8281GDB now accepts as input the "demangled form" of C++ overloaded function
8282names and member function names, and can do command completion on such names
8283(using TAB, TAB-TAB, and ESC-?). The names have to be quoted with a pair of
8284single quotes. Examples are 'func (int, long)' and 'obj::operator==(obj&)'.
8285Make use of command completion, it is your friend.
8286
8287GDB also now accepts a variety of C++ mangled symbol formats. They are
8288the GNU g++ style, the Cfront (ARM) style, and the Lucid (lcc) style.
8289You can tell GDB which format to use by doing a 'set demangle-style {gnu,
8290lucid, cfront, auto}'. 'gnu' is the default. Do a 'set demangle-style foo'
8291for the list of formats.
8292
8293 * G++ symbol mangling problem
8294
8295Recent versions of gcc have a bug in how they emit debugging information for
8296C++ methods (when using dbx-style stabs). The file 'gcc.patch' (in this
8297directory) can be applied to gcc to fix the problem. Alternatively, if you
82f06518 8298can't fix gcc, you can #define GCC_MANGLE_BUG when compiling gdb/symtab.c. The
c906108c
SS
8299usual symptom is difficulty with setting breakpoints on methods. GDB complains
8300about the method being non-existent. (We believe that version 2.2.2 of GCC has
8301this problem.)
8302
8303 * New 'maintenance' command
8304
8305All of the commands related to hacking GDB internals have been moved out of
8306the main command set, and now live behind the 'maintenance' command. This
8307can also be abbreviated as 'mt'. The following changes were made:
8308
8309 dump-me -> maintenance dump-me
8310 info all-breakpoints -> maintenance info breakpoints
8311 printmsyms -> maintenance print msyms
8312 printobjfiles -> maintenance print objfiles
8313 printpsyms -> maintenance print psymbols
8314 printsyms -> maintenance print symbols
8315
8316The following commands are new:
8317
8318 maintenance demangle Call internal GDB demangler routine to
8319 demangle a C++ link name and prints the result.
8320 maintenance print type Print a type chain for a given symbol
8321
8322 * Change to .gdbinit file processing
8323
8324We now read the $HOME/.gdbinit file before processing the argv arguments
8325(e.g. reading symbol files or core files). This allows global parameters to
8326be set, which will apply during the symbol reading. The ./.gdbinit is still
8327read after argv processing.
8328
8329 * New hosts supported
8330
8331Solaris-2.0 !!! sparc-sun-solaris2 or sun4sol2
8332
55241689 8333GNU/Linux support i386-unknown-linux or linux
c906108c
SS
8334
8335We are also including code to support the HP/PA running BSD and HPUX. This
8336is almost guaranteed not to work, as we didn't have time to test or build it
8337for this release. We are including it so that the more adventurous (or
8338masochistic) of you can play with it. We also had major problems with the
8339fact that the compiler that we got from HP doesn't support the -g option.
8340It costs extra.
8341
8342 * New targets supported
8343
8344Hitachi H8/300 h8300-hitachi-hms or h8300hms
8345
8346 * More smarts about finding #include files
8347
8348GDB now remembers the compilation directory for all include files, and for
8349all files from which C is generated (like yacc and lex sources). This
8350greatly improves GDB's ability to find yacc/lex sources, and include files,
8351especially if you are debugging your program from a directory different from
8352the one that contains your sources.
8353
8354We also fixed a bug which caused difficulty with listing and setting
8355breakpoints in include files which contain C code. (In the past, you had to
8356try twice in order to list an include file that you hadn't looked at before.)
8357
8358 * Interesting infernals change
8359
8360GDB now deals with arbitrary numbers of sections, where the symbols for each
8361section must be relocated relative to that section's landing place in the
8362target's address space. This work was needed to support ELF with embedded
8363stabs used by Solaris-2.0.
8364
8365 * Bug fixes (of course!)
8366
8367There have been loads of fixes for the following things:
8368 mips, rs6000, 29k/udi, m68k, g++, type handling, elf/dwarf, m88k,
8369 i960, stabs, DOS(GO32), procfs, etc...
8370
8371See the ChangeLog for details.
8372
8373*** Changes in GDB-4.5:
8374
8375 * New machines supported (host and target)
8376
8377IBM RS6000 running AIX rs6000-ibm-aix or rs6000
8378
8379SGI Irix-4.x mips-sgi-irix4 or iris4
8380
8381 * New malloc package
8382
8383GDB now uses a new memory manager called mmalloc, based on gmalloc.
82f06518 8384Mmalloc is capable of handling multiple heaps of memory. It is also
c906108c
SS
8385capable of saving a heap to a file, and then mapping it back in later.
8386This can be used to greatly speedup the startup of GDB by using a
8387pre-parsed symbol table which lives in a mmalloc managed heap. For
8388more details, please read mmalloc/mmalloc.texi.
8389
8390 * info proc
8391
8392The 'info proc' command (SVR4 only) has been enhanced quite a bit. See
8393'help info proc' for details.
8394
8395 * MIPS ecoff symbol table format
8396
8397The code that reads MIPS symbol table format is now supported on all hosts.
8398Thanks to MIPS for releasing the sym.h and symconst.h files to make this
8399possible.
8400
8401 * File name changes for MS-DOS
8402
8403Many files in the config directories have been renamed to make it easier to
8404support GDB on MS-DOSe systems (which have very restrictive file name
8405conventions :-( ). MS-DOSe host support (under DJ Delorie's GO32
8406environment) is close to working but has some remaining problems. Note
8407that debugging of DOS programs is not supported, due to limitations
8408in the ``operating system'', but it can be used to host cross-debugging.
8409
8410 * Cross byte order fixes
8411
8412Many fixes have been made to support cross debugging of Sparc and MIPS
8413targets from hosts whose byte order differs.
8414
8415 * New -mapped and -readnow options
8416
8417If memory-mapped files are available on your system through the 'mmap'
8418system call, you can use the -mapped option on the `file' or
8419`symbol-file' commands to cause GDB to write the symbols from your
8420program into a reusable file. If the program you are debugging is
8421called `/path/fred', the mapped symbol file will be `./fred.syms'.
8422Future GDB debugging sessions will notice the presence of this file,
8423and will quickly map in symbol information from it, rather than reading
8424the symbol table from the executable program. Using the '-mapped'
8425option in a GDB `file' or `symbol-file' command has the same effect as
8426starting GDB with the '-mapped' command-line option.
8427
8428You can cause GDB to read the entire symbol table immediately by using
8429the '-readnow' option with any of the commands that load symbol table
8430information (or on the GDB command line). This makes the command
8431slower, but makes future operations faster.
8432
8433The -mapped and -readnow options are typically combined in order to
8434build a `fred.syms' file that contains complete symbol information.
8435A simple GDB invocation to do nothing but build a `.syms' file for future
8436use is:
8437
8438 gdb -batch -nx -mapped -readnow programname
8439
8440The `.syms' file is specific to the host machine on which GDB is run.
8441It holds an exact image of GDB's internal symbol table. It cannot be
8442shared across multiple host platforms.
8443
8444 * longjmp() handling
8445
8446GDB is now capable of stepping and nexting over longjmp(), _longjmp(), and
8447siglongjmp() without losing control. This feature has not yet been ported to
8448all systems. It currently works on many 386 platforms, all MIPS-based
8449platforms (SGI, DECstation, etc), and Sun3/4.
8450
8451 * Solaris 2.0
8452
8453Preliminary work has been put in to support the new Solaris OS from Sun. At
8454this time, it can control and debug processes, but it is not capable of
8455reading symbols.
8456
8457 * Bug fixes
8458
8459As always, many many bug fixes. The major areas were with g++, and mipsread.
8460People using the MIPS-based platforms should experience fewer mysterious
8461crashes and trashed symbol tables.
8462
8463*** Changes in GDB-4.4:
8464
8465 * New machines supported (host and target)
8466
8467SCO Unix on i386 IBM PC clones i386-sco-sysv or i386sco
8468 (except core files)
8469BSD Reno on Vax vax-dec-bsd
8470Ultrix on Vax vax-dec-ultrix
8471
8472 * New machines supported (target)
8473
8474AMD 29000 embedded, using EBMON a29k-none-none
8475
8476 * C++ support
8477
8478GDB continues to improve its handling of C++. `References' work better.
8479The demangler has also been improved, and now deals with symbols mangled as
8480per the Annotated C++ Reference Guide.
8481
8482GDB also now handles `stabs' symbol information embedded in MIPS
8483`ecoff' symbol tables. Since the ecoff format was not easily
8484extensible to handle new languages such as C++, this appeared to be a
8485good way to put C++ debugging info into MIPS binaries. This option
8486will be supported in the GNU C compiler, version 2, when it is
8487released.
8488
8489 * New features for SVR4
8490
8491GDB now handles SVR4 shared libraries, in the same fashion as SunOS
8492shared libraries. Debugging dynamically linked programs should present
8493only minor differences from debugging statically linked programs.
8494
8495The `info proc' command will print out information about any process
8496on an SVR4 system (including the one you are debugging). At the moment,
8497it prints the address mappings of the process.
8498
8499If you bring up GDB on another SVR4 system, please send mail to
8500bug-gdb@prep.ai.mit.edu to let us know what changes were reqired (if any).
8501
8502 * Better dynamic linking support in SunOS
8503
8504Reading symbols from shared libraries which contain debugging symbols
8505now works properly. However, there remain issues such as automatic
8506skipping of `transfer vector' code during function calls, which
8507make it harder to debug code in a shared library, than to debug the
8508same code linked statically.
8509
8510 * New Getopt
8511
8512GDB is now using the latest `getopt' routines from the FSF. This
8513version accepts the -- prefix for options with long names. GDB will
8514continue to accept the old forms (-option and +option) as well.
8515Various single letter abbreviations for options have been explicity
8516added to the option table so that they won't get overshadowed in the
8517future by other options that begin with the same letter.
8518
8519 * Bugs fixed
8520
8521The `cleanup_undefined_types' bug that many of you noticed has been squashed.
8522Many assorted bugs have been handled. Many more remain to be handled.
8523See the various ChangeLog files (primarily in gdb and bfd) for details.
8524
8525
8526*** Changes in GDB-4.3:
8527
8528 * New machines supported (host and target)
8529
8530Amiga 3000 running Amix m68k-cbm-svr4 or amix
8531NCR 3000 386 running SVR4 i386-ncr-svr4 or ncr3000
8532Motorola Delta 88000 running Sys V m88k-motorola-sysv or delta88
8533
8534 * Almost SCO Unix support
8535
8536We had hoped to support:
8537SCO Unix on i386 IBM PC clones i386-sco-sysv or i386sco
8538(except for core file support), but we discovered very late in the release
8539that it has problems with process groups that render gdb unusable. Sorry
8540about that. I encourage people to fix it and post the fixes.
8541
8542 * Preliminary ELF and DWARF support
8543
8544GDB can read ELF object files on System V Release 4, and can handle
8545debugging records for C, in DWARF format, in ELF files. This support
8546is preliminary. If you bring up GDB on another SVR4 system, please
8547send mail to bug-gdb@prep.ai.mit.edu to let us know what changes were
8548reqired (if any).
8549
8550 * New Readline
8551
8552GDB now uses the latest `readline' library. One user-visible change
8553is that two tabs will list possible command completions, which previously
8554required typing M-? (meta-question mark, or ESC ?).
8555
8556 * Bugs fixed
8557
8558The `stepi' bug that many of you noticed has been squashed.
8559Many bugs in C++ have been handled. Many more remain to be handled.
8560See the various ChangeLog files (primarily in gdb and bfd) for details.
8561
8562 * State of the MIPS world (in case you wondered):
8563
8564GDB can understand the symbol tables emitted by the compilers
8565supplied by most vendors of MIPS-based machines, including DEC. These
8566symbol tables are in a format that essentially nobody else uses.
8567
8568Some versions of gcc come with an assembler post-processor called
8569mips-tfile. This program is required if you want to do source-level
8570debugging of gcc-compiled programs. I believe FSF does not ship
8571mips-tfile with gcc version 1, but it will eventually come with gcc
8572version 2.
8573
8574Debugging of g++ output remains a problem. g++ version 1.xx does not
8575really support it at all. (If you're lucky, you should be able to get
8576line numbers and stack traces to work, but no parameters or local
8577variables.) With some work it should be possible to improve the
8578situation somewhat.
8579
8580When gcc version 2 is released, you will have somewhat better luck.
8581However, even then you will get confusing results for inheritance and
8582methods.
8583
8584We will eventually provide full debugging of g++ output on
8585DECstations. This will probably involve some kind of stabs-in-ecoff
8586encapulation, but the details have not been worked out yet.
8587
8588
8589*** Changes in GDB-4.2:
8590
8591 * Improved configuration
8592
8593Only one copy of `configure' exists now, and it is not self-modifying.
8594Porting BFD is simpler.
8595
8596 * Stepping improved
8597
8598The `step' and `next' commands now only stop at the first instruction
8599of a source line. This prevents the multiple stops that used to occur
8600in switch statements, for-loops, etc. `Step' continues to stop if a
8601function that has debugging information is called within the line.
8602
8603 * Bug fixing
8604
8605Lots of small bugs fixed. More remain.
8606
8607 * New host supported (not target)
8608
8609Intel 386 PC clone running Mach i386-none-mach
8610
8611
8612*** Changes in GDB-4.1:
8613
8614 * Multiple source language support
8615
8616GDB now has internal scaffolding to handle several source languages.
8617It determines the type of each source file from its filename extension,
8618and will switch expression parsing and number formatting to match the
8619language of the function in the currently selected stack frame.
8620You can also specifically set the language to be used, with
8621`set language c' or `set language modula-2'.
8622
8623 * GDB and Modula-2
8624
8625GDB now has preliminary support for the GNU Modula-2 compiler,
8626currently under development at the State University of New York at
8627Buffalo. Development of both GDB and the GNU Modula-2 compiler will
8628continue through the fall of 1991 and into 1992.
8629
8630Other Modula-2 compilers are currently not supported, and attempting to
8631debug programs compiled with them will likely result in an error as the
8632symbol table is read. Feel free to work on it, though!
8633
8634There are hooks in GDB for strict type checking and range checking,
8635in the `Modula-2 philosophy', but they do not currently work.
8636
8637 * set write on/off
8638
8639GDB can now write to executable and core files (e.g. patch
8640a variable's value). You must turn this switch on, specify
8641the file ("exec foo" or "core foo"), *then* modify it, e.g.
8642by assigning a new value to a variable. Modifications take
8643effect immediately.
8644
8645 * Automatic SunOS shared library reading
8646
8647When you run your program, GDB automatically determines where its
8648shared libraries (if any) have been loaded, and reads their symbols.
8649The `share' command is no longer needed. This also works when
8650examining core files.
8651
8652 * set listsize
8653
8654You can specify the number of lines that the `list' command shows.
8655The default is 10.
8656
8657 * New machines supported (host and target)
8658
8659SGI Iris (MIPS) running Irix V3: mips-sgi-irix or iris
8660Sony NEWS (68K) running NEWSOS 3.x: m68k-sony-sysv or news
8661Ultracomputer (29K) running Sym1: a29k-nyu-sym1 or ultra3
8662
8663 * New hosts supported (not targets)
8664
8665IBM RT/PC: romp-ibm-aix or rtpc
8666
8667 * New targets supported (not hosts)
8668
8669AMD 29000 embedded with COFF a29k-none-coff
8670AMD 29000 embedded with a.out a29k-none-aout
8671Ultracomputer remote kernel debug a29k-nyu-kern
8672
8673 * New remote interfaces
8674
8675AMD 29000 Adapt
8676AMD 29000 Minimon
8677
8678
8679*** Changes in GDB-4.0:
8680
8681 * New Facilities
8682
8683Wide output is wrapped at good places to make the output more readable.
8684
8685Gdb now supports cross-debugging from a host machine of one type to a
8686target machine of another type. Communication with the target system
8687is over serial lines. The ``target'' command handles connecting to the
8688remote system; the ``load'' command will download a program into the
8689remote system. Serial stubs for the m68k and i386 are provided. Gdb
8690also supports debugging of realtime processes running under VxWorks,
8691using SunRPC Remote Procedure Calls over TCP/IP to talk to a debugger
8692stub on the target system.
8693
8694New CPUs supported include the AMD 29000 and Intel 960.
8695
8696GDB now reads object files and symbol tables via a ``binary file''
8697library, which allows a single copy of GDB to debug programs of multiple
8698object file types such as a.out and coff.
8699
8700There is now a GDB reference card in "doc/refcard.tex". (Make targets
8701refcard.dvi and refcard.ps are available to format it).
8702
8703
8704 * Control-Variable user interface simplified
8705
8706All variables that control the operation of the debugger can be set
8707by the ``set'' command, and displayed by the ``show'' command.
8708
8709For example, ``set prompt new-gdb=>'' will change your prompt to new-gdb=>.
8710``Show prompt'' produces the response:
8711Gdb's prompt is new-gdb=>.
8712
8713What follows are the NEW set commands. The command ``help set'' will
8714print a complete list of old and new set commands. ``help set FOO''
8715will give a longer description of the variable FOO. ``show'' will show
8716all of the variable descriptions and their current settings.
8717
8718confirm on/off: Enables warning questions for operations that are
8719 hard to recover from, e.g. rerunning the program while
8720 it is already running. Default is ON.
8721
8722editing on/off: Enables EMACS style command line editing
8723 of input. Previous lines can be recalled with
8724 control-P, the current line can be edited with control-B,
8725 you can search for commands with control-R, etc.
8726 Default is ON.
8727
8728history filename NAME: NAME is where the gdb command history
8729 will be stored. The default is .gdb_history,
8730 or the value of the environment variable
8731 GDBHISTFILE.
8732
8733history size N: The size, in commands, of the command history. The
8734 default is 256, or the value of the environment variable
8735 HISTSIZE.
8736
8737history save on/off: If this value is set to ON, the history file will
8738 be saved after exiting gdb. If set to OFF, the
8739 file will not be saved. The default is OFF.
8740
8741history expansion on/off: If this value is set to ON, then csh-like
8742 history expansion will be performed on
8743 command line input. The default is OFF.
8744
8745radix N: Sets the default radix for input and output. It can be set
8746 to 8, 10, or 16. Note that the argument to "radix" is interpreted
8747 in the current radix, so "set radix 10" is always a no-op.
8748
8749height N: This integer value is the number of lines on a page. Default
8750 is 24, the current `stty rows'' setting, or the ``li#''
8751 setting from the termcap entry matching the environment
8752 variable TERM.
8753
8754width N: This integer value is the number of characters on a line.
8755 Default is 80, the current `stty cols'' setting, or the ``co#''
8756 setting from the termcap entry matching the environment
8757 variable TERM.
8758
8759Note: ``set screensize'' is obsolete. Use ``set height'' and
8760``set width'' instead.
8761
8762print address on/off: Print memory addresses in various command displays,
8763 such as stack traces and structure values. Gdb looks
8764 more ``symbolic'' if you turn this off; it looks more
8765 ``machine level'' with it on. Default is ON.
8766
8767print array on/off: Prettyprint arrays. New convenient format! Default
8768 is OFF.
8769
8770print demangle on/off: Print C++ symbols in "source" form if on,
8771 "raw" form if off.
8772
8773print asm-demangle on/off: Same, for assembler level printouts
8774 like instructions.
8775
8776print vtbl on/off: Prettyprint C++ virtual function tables. Default is OFF.
8777
8778
8779 * Support for Epoch Environment.
8780
8781The epoch environment is a version of Emacs v18 with windowing. One
8782new command, ``inspect'', is identical to ``print'', except that if you
8783are running in the epoch environment, the value is printed in its own
8784window.
8785
8786
8787 * Support for Shared Libraries
8788
8789GDB can now debug programs and core files that use SunOS shared libraries.
8790Symbols from a shared library cannot be referenced
8791before the shared library has been linked with the program (this
8792happens after you type ``run'' and before the function main() is entered).
8793At any time after this linking (including when examining core files
8794from dynamically linked programs), gdb reads the symbols from each
8795shared library when you type the ``sharedlibrary'' command.
8796It can be abbreviated ``share''.
8797
8798sharedlibrary REGEXP: Load shared object library symbols for files
8799 matching a unix regular expression. No argument
8800 indicates to load symbols for all shared libraries.
8801
8802info sharedlibrary: Status of loaded shared libraries.
8803
8804
8805 * Watchpoints
8806
8807A watchpoint stops execution of a program whenever the value of an
8808expression changes. Checking for this slows down execution
8809tremendously whenever you are in the scope of the expression, but is
8810quite useful for catching tough ``bit-spreader'' or pointer misuse
8811problems. Some machines such as the 386 have hardware for doing this
8812more quickly, and future versions of gdb will use this hardware.
8813
8814watch EXP: Set a watchpoint (breakpoint) for an expression.
8815
8816info watchpoints: Information about your watchpoints.
8817
8818delete N: Deletes watchpoint number N (same as breakpoints).
8819disable N: Temporarily turns off watchpoint number N (same as breakpoints).
8820enable N: Re-enables watchpoint number N (same as breakpoints).
8821
8822
8823 * C++ multiple inheritance
8824
8825When used with a GCC version 2 compiler, GDB supports multiple inheritance
8826for C++ programs.
8827
8828 * C++ exception handling
8829
8830Gdb now supports limited C++ exception handling. Besides the existing
8831ability to breakpoint on an exception handler, gdb can breakpoint on
8832the raising of an exception (before the stack is peeled back to the
8833handler's context).
8834
8835catch FOO: If there is a FOO exception handler in the dynamic scope,
8836 set a breakpoint to catch exceptions which may be raised there.
8837 Multiple exceptions (``catch foo bar baz'') may be caught.
8838
8839info catch: Lists all exceptions which may be caught in the
8840 current stack frame.
8841
8842
8843 * Minor command changes
8844
8845The command ``call func (arg, arg, ...)'' now acts like the print
8846command, except it does not print or save a value if the function's result
8847is void. This is similar to dbx usage.
8848
8849The ``up'' and ``down'' commands now always print the frame they end up
8850at; ``up-silently'' and `down-silently'' can be used in scripts to change
8851frames without printing.
8852
8853 * New directory command
8854
8855'dir' now adds directories to the FRONT of the source search path.
8856The path starts off empty. Source files that contain debug information
8857about the directory in which they were compiled can be found even
8858with an empty path; Sun CC and GCC include this information. If GDB can't
8859find your source file in the current directory, type "dir .".
8860
8861 * Configuring GDB for compilation
8862
8863For normal use, type ``./configure host''. See README or gdb.texinfo
8864for more details.
8865
8866GDB now handles cross debugging. If you are remotely debugging between
8867two different machines, type ``./configure host -target=targ''.
8868Host is the machine where GDB will run; targ is the machine
8869where the program that you are debugging will run.