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