]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
Don't output null pathname in core_target::build_file_mappings warning
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2020-08-05 Kevin Buettner <kevinb@redhat.com>
2
3 * corelow.c (core_target::build_file_mappings): Don't output
4 null pathname in warning.
5
6 2020-08-05 Simon Marchi <simon.marchi@polymtl.ca>
7
8 * gdb.dwarf2/clztest.exp, gdb.dwarf2/dw2-common-block.exp,
9 gdb.dwarf2/dw2-dup-frame.exp, gdb.dwarf2/dw2-reg-undefined.exp,
10 gdb.dwarf2/dw2-single-line-discriminators.exp,
11 dw2-undefined-ret-addr.exp: Pass nopie to compilation options.
12
13 2020-08-05 Tom Tromey <tromey@adacore.com>
14
15 PR rust/26197:
16 * dwarf2/read.c (alloc_rust_variant): Handle univariant case.
17 (quirk_rust_enum): Call alloc_rust_variant for univariant case.
18 Fix off-by-one and type size errors in ordinary case.
19
20 2020-08-05 Tom de Vries <tdevries@suse.de>
21
22 * gdbtypes.c (type_not_allocated, type_not_associated): Use
23 "prop->const_val () == 0" instead of "prop->const_val () != 0".
24
25 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
26
27 * frame.h (frame_id_p): Return bool.
28 (frame_id_artificial_p): Return bool.
29 (frame_id_eq): Return bool.
30 (has_stack_frames): Return bool.
31 (get_selected_frame): Fix typo in comment.
32 (get_frame_pc_if_available): Return bool.
33 (get_frame_address_in_block_if_available): Return bool.
34 (get_frame_func_if_available): Return bool.
35 (read_frame_register_unsigned): Return bool.
36 (get_frame_register_bytes): Return bool.
37 (safe_frame_unwind_memory): Return bool.
38 (deprecated_frame_register_read): Return bool.
39 (frame_unwinder_is): Return bool.
40 * frame.c (struct frame_info) <prev_arch::p>: Change type to
41 bool.
42 <this_id::p>: Likewise.
43 <prev_p>: Likewise.
44 (frame_stash_add): Return bool.
45 (get_frame_id): Use bool.
46 (frame_id_build_special) Use bool.
47 (frame_id_build_unavailable_stack): Use bool.
48 (frame_id_build): Use bool.
49 (frame_id_p): Return bool, use true/false instead of 1/0.
50 (frame_id_artificial_p): Likewise.
51 (frame_id_eq): Likewise.
52 (frame_id_inner): Likewise.
53 (get_frame_func_if_available): Likewise.
54 (read_frame_register_unsigned): Likewise.
55 (deprecated_frame_register_read): Likewise.
56 (get_frame_register_bytes): Likewise.
57 (has_stack_frames): Likewise.
58 (inside_main_func): Likewise.
59 (inside_entry_func): Likewise.
60 (get_frame_pc_if_available): Likewise.
61 (get_frame_address_in_block_if_available): Likewise.
62 (frame_unwinder_is): Likewise.
63 (safe_frame_unwind_memory): Likewise.
64 (frame_unwind_arch): Likewise.
65
66 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
67
68 * frame.c (frame_info) <prev_func> <p>: Rename to status, change
69 type to cached_copy_status.
70 (fprintf_frame): Adjust.
71 (get_frame_func_if_available): Adjust.
72 (frame_cleanup_after_sniffer): Adjust.
73
74 2020-08-04 Mark Wielaard <mark@klomp.org>
75
76 * MAINTAINERS (Write After Approval): Update email address.
77
78 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
79
80 * gdbtypes.h (TYPE_DYN_PROP_ADDR): Remove, replace uses with
81 dynamic_prop::const_val.
82
83 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
84
85 * gdbtypes.h (TYPE_DYN_PROP_KIND): Remove, replace uses with
86 dynamic_prop::kind.
87
88 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
89
90 * gdbtypes.h (TYPE_DYN_PROP_BATON): Remove.
91
92 2020-08-04 Jose E. Marchesi <jose.marchesi@oracle.com>
93
94 * configure.tgt: Set gdb_sim for bpf-*-* targets.
95
96 2020-08-04 Weimin Pan <weimin.pan@oracle.com>
97 Jose E. Marchesi <jose.marchesi@oracle.com>
98
99 * configure.tgt: Add entry for bpf-*-*.
100 * Makefile.in (ALL_TARGET_OBS): Add bpf-tdep.o
101 (ALLDEPFILES): Add bpf-tdep.c.
102 * bpf-tdep.c: New file.
103 * MAINTAINERS: Add bpf target and maintainer.
104 * NEWS: Mention the support for the new target.
105
106 2020-08-04 Tom de Vries <tdevries@suse.de>
107
108 PR symtab/23270
109 * dwarf2/read.c (find_partial_die): Change internal error into Dwarf
110 Error.
111
112 2020-08-03 John Baldwin <jhb@FreeBSD.org>
113
114 * syscalls/freebsd.xml: Regenerate.
115
116 2020-08-03 John Baldwin <jhb@FreeBSD.org>
117
118 * syscalls/update-freebsd.sh: Fix usage and year range.
119
120 2020-08-03 Tom de Vries <tdevries@suse.de>
121
122 PR symtab/26333
123 * dwarf2/read.c (dwarf_decode_lines_1): Ignore
124 DW_LNE_lo_user/DW_LNE_hi_user range.
125
126 2020-07-30 Simon Marchi <simon.marchi@polymtl.ca>
127
128 PR ada/26318
129 * ada-lang.c (ada_modulus): Return 0 if property is not of const
130 kind.
131
132 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
133
134 * breakpoint.c (set_breakpoint_condition): Do minor refactoring.
135
136 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
137
138 * breakpoint.c (set_breakpoint_condition): Update the condition
139 expressions after checking that the input condition string parses
140 successfully and does not contain junk at the end.
141
142 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
143
144 * breakpoint.c (set_breakpoint_condition): Update the
145 condition string after parsing the new condition successfully.
146
147 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
148
149 * proc-api.c (_STRUCTURED_PROC): Don't define.
150 * proc-events.c: Likewise.
151 * proc-flags.c: Likewise.
152 * proc-why.c: Likewise.
153 * procfs.c: Likewise.
154
155 * Makefile.in (INTERNAL_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
156 * configure, config.in: Regenerate.
157
158 2020-07-30 Tom de Vries <tdevries@suse.de>
159
160 PR build/26320
161 * ui-style.h (struct ui_file_style::color): Wrap m_value and
162 m_red/m_green/m_blue in a union.
163
164 2020-07-29 Tom de Vries <tdevries@suse.de>
165
166 PR tdep/26280
167 * s390-tdep.c (s390_displaced_step_fixup): Fix Wmaybe-uninitialized.
168
169 2020-07-28 Tom Tromey <tromey@adacore.com>
170
171 PR symtab/26270:
172 * symtab.h (find_pc_partial_function_sym): Declare.
173 * cli/cli-cmds.c (disassemble_command): Use
174 find_pc_partial_function_sym. Check asm_demangle.
175 * blockframe.c (cache_pc_function_sym): New global.
176 (cache_pc_function_name): Remove.
177 (clear_pc_function_cache): Update.
178 (find_pc_partial_function_sym): New function, from
179 find_pc_partial_function.
180 (find_pc_partial_function): Rewrite using
181 find_pc_partial_function_sym.
182
183 2020-07-28 Tom Tromey <tromey@adacore.com>
184
185 * cli/cli-cmds.c (_initialize_cli_cmds): Rearrange "disassemble"
186 help. Add usage.
187
188 2020-07-28 Tom Tromey <tromey@adacore.com>
189
190 * dwarf2/expr.c (dwarf_expr_context::execute_stack_op)
191 <DW_OP_GNU_variable_value>: Cast to address type.
192
193 2020-07-28 Kamil Rytarowski <n54@gmx.com>
194
195 * nbsd-nat.h (nbsd_nat_target::xfer_partial): New declaration.
196 * nbsd-nat.c (nbsd_nat_target::xfer_partial): New function.
197 * nbsd-tdep.c (nbsd_gdbarch_data_handle, struct nbsd_gdbarch_data)
198 (init_nbsd_gdbarch_data, get_nbsd_gdbarch_data)
199 (nbsd_get_siginfo_type): New.
200 (nbsd_init_abi): Install gdbarch "get_siginfo_type" method.
201 (_initialize_nbsd_tdep): New.
202
203 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
204
205 PR binutils/26301
206 * configure: Regenerated.
207
208 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
209
210 PR binutils/26301
211 * configure: Regenerated.
212
213 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
214
215 * python/py-frame.c: Remove 'user-regs.h' include.
216 (frapy_read_register): Rewrite to make use of
217 gdbpy_parse_register_id.
218 * python/py-registers.c (gdbpy_parse_register_id): New function,
219 moved here from python/py-unwind.c. Updated the return type, and
220 also accepts register descriptor objects.
221 * python/py-unwind.c: Remove 'user-regs.h' include.
222 (pyuw_parse_register_id): Moved to python/py-registers.c.
223 (unwind_infopy_add_saved_register): Update to use
224 gdbpy_parse_register_id.
225 (pending_framepy_read_register): Likewise.
226 * python/python-internal.h (gdbpy_parse_register_id): Declare.
227
228 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
229
230 * python/py-registers.c: Add 'user-regs.h' include.
231 (register_descriptor_iter_find): New function.
232 (register_descriptor_iterator_object_methods): New static global
233 methods array.
234 (register_descriptor_iterator_object_type): Add pointer to methods
235 array.
236
237 2020-07-27 John Baldwin <jhb@FreeBSD.org>
238
239 * fbsd-nat.h: Include <osreldate.h>. Define USE_SIGTRAP_SIGINFO
240 for all architectures on FreeBSD 11.3 and later.
241
242 2020-07-27 Tom Tromey <tromey@adacore.com>
243
244 * gcore.h (load_corefile): Don't declare.
245
246 2020-07-27 Tom de Vries <tdevries@suse.de>
247
248 * configure.ac: Fix sys/sockets.h -> sys/socket.h typo.
249 * config.in: Regenerate.
250 * configure: Regenerate.
251
252 2020-07-26 Eli Zaretskii <eliz@gnu.org>
253
254 * configure.ac (AC_CHECK_HEADERS): Check for sys/socket.h and
255 ws2tcpip.h. When checking whether socklen_t type is defined, use
256 ws2tcpip.h if it is available and sys/socket.h isn't.
257 * configure: Regenerate.
258 * config.in: Regenerate.
259
260 2020-07-25 Andrew Burgess <andrew.burgess@embecosm.com>
261
262 PR fortran/23051
263 PR fortran/26139
264 * valops.c (value_ind): Pass address to
265 readjust_indirect_value_type.
266 * value.c (readjust_indirect_value_type): Make parameter
267 non-const, and add extra address parameter. Resolve original type
268 before using it.
269 * value.h (readjust_indirect_value_type): Update function
270 signature and comment.
271
272 2020-07-25 Tom de Vries <tdevries@suse.de>
273
274 PR symtab/26243
275 * dwarf2/read.c (lnp_state_machine::record_line): Ignore zero line
276 entries.
277
278 2020-07-24 Aaron Merey <amerey@redhat.com>
279
280 * Makefile.in: Replace LIBDEBUGINFOD with DEBUGINFOD_LIBS.
281 * configure: Rebuild.
282
283 2020-07-23 Kevin Buettner <kevinb@redhat.com>
284
285 PR corefiles/26294
286 * corelow.c (_initialize_corelow): Add period to help text
287 for "maintenance print core-file-backed-mappings".
288
289 2020-07-23 Pedro Alves <pedro@palves.net>
290
291 * frame-unwind.c (frame_unwind_try_unwinder): On exception, don't
292 touch THIS_CACHE/THIS_FRAME if the frame cache was cleared
293 meanwhile.
294 * frame.c (frame_cache_generation, get_frame_cache_generation):
295 New.
296 (reinit_frame_cache): Increment FRAME_CACHE_GENERATION.
297 (get_prev_frame_if_no_cycle): On exception, don't touch
298 PREV_FRAME/THIS_FRAME if the frame cache was cleared meanwhile.
299 * frame.h (get_frame_cache_generation): Declare.
300
301 2020-07-23 Tom de Vries <tdevries@suse.de>
302
303 PR tui/26282
304 * tui/tui-winsource.h (struct tui_source_windows::tui_source_windows):
305 New default constructor.
306
307 2020-07-23 Andrew Burgess <andrew.burgess@embecosm.com>
308
309 * disasm.c (do_mixed_source_and_assembly_deprecated): Don't
310 exclude non-statement entries.
311
312 2020-07-22 Kevin Buettner <kevinb@redhat.com>
313
314 * NEWS (New commands): Mention new command
315 "maintenance print core-file-backed-mappings".
316
317 2020-07-22 Kevin Buettner <kevinb@redhat.com>
318
319 * corelow.c (gdbcmd.h): Include.
320 (core_target::info_proc_mappings): New method.
321 (get_current_core_target): New function.
322 (maintenance_print_core_file_backed_mappings): New function.
323 (_initialize_corelow): Add core-file-backed-mappings to
324 "maint print" commands.
325
326 2020-07-22 Kevin Buettner <kevinb@redhat.com>
327
328 * linux-tdep.c (dump_note_entry_p): New function.
329 (linux_dump_mapping_p_ftype): New typedef.
330 (linux_find_memory_regions_full): Add new parameter,
331 should_dump_mapping_p.
332 (linux_find_memory_regions): Adjust call to
333 linux_find_memory_regions_full.
334 (linux_make_mappings_core_file_notes): Use dump_note_entry_p in
335 call to linux_find_memory_regions_full.
336
337 2020-07-22 Kevin Buettner <kevinb@redhat.com>
338
339 * corelow.c (solist.h, unordered_map): Include.
340 (class core_target): Add field m_core_file_mappings and
341 method build_file_mappings.
342 (core_target::core_target): Call build_file_mappings.
343 (core_target::~core_target): Free memory associated with
344 m_core_file_mappings.
345 (core_target::build_file_mappings): New method.
346 (core_target::xfer_partial): Use m_core_file_mappings
347 for memory transfers.
348 * linux-tdep.c (linux_read_core_file_mappings): New
349 function.
350 (linux_core_info_proc_mappings): Rewrite to use
351 linux_read_core_file_mappings.
352 (linux_init_abi): Register linux_read_core_file_mappings.
353
354 2020-07-22 Kevin Buettner <kevinb@redhat.com>
355
356 * arch-utils.c (default_read_core_file_mappings): New function.
357 * arch-utils.c (default_read_core_file_mappings): Declare.
358 * gdbarch.sh (read_core_file_mappings): New gdbarch method.
359 * gdbarch.h, gdbarch.c: Regenerate.
360
361 2020-07-22 Kevin Buettner <kevinb@redhat.com>
362
363 PR corefiles/25631
364 * corelow.c (core_target:xfer_partial): Revise
365 TARGET_OBJECT_MEMORY case to consider non-SEC_HAS_CONTENTS
366 case after first checking the stratum beneath the core
367 target.
368 (has_all_memory): Return true.
369 * target.c (raw_memory_xfer_partial): Revise comment
370 regarding use of has_all_memory.
371
372 2020-07-22 Kevin Buettner <kevinb@redhat.com>
373
374 * exec.h (section_table_xfer_memory): Revise declaration,
375 replacing section name parameter with an optional callback
376 predicate.
377 * exec.c (section_table_xfer_memory): Likewise.
378 * bfd-target.c, exec.c, target.c, corelow.c: Adjust all callers
379 of section_table_xfer_memory.
380
381 2020-07-22 Tom Tromey <tromey@adacore.com>
382
383 * mi/mi-cmd-stack.c (list_args_or_locals): Use
384 lookup_symbol_search_name.
385
386 2020-07-22 Andrew Burgess <andrew.burgess@embecosm.com>
387
388 * python/py-registers.c (gdbpy_register_object_data_init): Remove
389 redundant local variable.
390 (gdbpy_get_register_descriptor): Extract descriptor vector as a
391 reference, not pointer, update code accordingly.
392
393 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
394 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
395
396 * objfiles.h (struct objfile) <skip_jit_symbol_lookup>: New field.
397 * jit.c (jit_breakpoint_re_set_internal): Use the
398 `skip_jit_symbol_lookup` field.
399
400 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
401 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
402
403 * jit.c (jit_read_descriptor): Define the descriptor address once,
404 use twice.
405 (jit_breakpoint_deleted): Move the declaration of the loop variable
406 `iter` into the loop header.
407 (jit_breakpoint_re_set_internal): Move the declaration of the local
408 variable `objf_data` to the first point of definition.
409 (jit_event_handler): Move the declaration of local variables
410 `code_entry`, `entry_addr`, and `objf` to their first point of use.
411 Rename `objf` to `jited`.
412
413 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
414
415 * jit.h (struct jiter_objfile_data) <jiter_objfile_data, objfile>:
416 Remove.
417 * jit.c (get_jiter_objfile_data): Update.
418
419 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
420 Simon Marchi <simon.marchi@polymtl.ca>
421
422 * jit.c (struct jit_program_space_data): Remove.
423 (jit_program_space_key): Remove.
424 (jiter_objfile_data::~jiter_objfile_data): Remove program space
425 stuff.
426 (get_jit_program_space_data): Remove.
427 (jit_breakpoint_deleted): Iterate on all of the program space's
428 objfiles.
429 (jit_inferior_init): Likewise.
430 (jit_breakpoint_re_set_internal): Likewise. Also change return
431 type to void.
432 (jit_breakpoint_re_set): Pass current_program_space to
433 jit_breakpoint_re_set_internal.
434
435 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
436
437 * jit.h (struct jiter_objfile_data) <cached_code_address,
438 jit_breakpoint>: Move to here from ...
439 * jit.c (jit_program_space_data): ... here.
440 (jiter_objfile_data::~jiter_objfile_data): Update.
441 (jit_breakpoint_deleted): Update.
442 (jit_breakpoint_re_set_internal): Update.
443
444 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
445
446 * jit.c (jiter_objfile_data::~jiter_objfile_data): Remove some
447 checks.
448 (jit_read_descriptor): Remove NULL check.
449 (jit_event_handler): Add an assertion.
450
451 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
452
453 * jit.h (struct jit_objfile_data): Split into...
454 (struct jiter_objfile_data): ... this ...
455 (struct jited_objfile_data): ... and this.
456 * objfiles.h (struct objfile) <jit_data>: Remove.
457 <jiter_data, jited_data>: New fields.
458 * jit.c (jit_objfile_data::~jit_objfile_data): Rename to ...
459 (jiter_objfile_data::~jiter_objfile_data): ... this.
460 (get_jit_objfile_data): Rename to ...
461 (get_jiter_objfile_data): ... this.
462 (add_objfile_entry): Update.
463 (jit_read_descriptor): Use get_jiter_objfile_data.
464 (jit_find_objf_with_entry_addr): Use objfile's jited_data field.
465 (jit_breakpoint_re_set_internal): Use get_jiter_objfile_data.
466 (jit_inferior_exit_hook): Use objfile's jited_data field.
467
468 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
469
470 * jit.h: Forward-declare `struct minimal_symbol`.
471 (struct jit_objfile_data): Migrate to here from jit.c; also add a
472 constructor, destructor, and an objfile* field.
473 * jit.c (jit_objfile_data): Remove.
474 (struct jit_objfile_data): Migrate from here to jit.h.
475 (jit_objfile_data::~jit_objfile_data): New destructor
476 implementation with code moved from free_objfile_data.
477 (free_objfile_data): Delete.
478 (get_jit_objfile_data): Update to use the jit_data field of objfile.
479 (jit_find_objf_with_entry_addr): Ditto.
480 (jit_inferior_exit_hook): Ditto.
481 (_initialize_jit): Remove the call to
482 register_objfile_data_with_cleanup.
483 * objfiles.h (struct objfile) <jit_data>: New field.
484
485 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
486
487 * jit.h: Forward-declare `struct objfile`.
488 (jit_event_handler): Add a second parameter, the JITer objfile.
489 * jit.c (jit_read_descriptor): Change the signature to take the
490 JITer objfile as an argument instead of the jit_program_space_data.
491 (jit_inferior_init): Update the call to jit_read_descriptor.
492 (jit_event_handler): Use the new JITer objfile argument when calling
493 jit_read_descriptor.
494 * breakpoint.c (handle_jit_event): Update the call to
495 jit_event_handler to pass the JITer objfile.
496
497 2020-07-21 John Baldwin <jhb@FreeBSD.org>
498
499 * gdbarch.c: Regenerate.
500 * gdbarch.h: Regenerate.
501 * gdbarch.sh (handle_segmentation_fault): Remove method.
502 * infrun.c (handle_segmentation_fault): Remove.
503 (print_signal_received_reason): Remove call to
504 handle_segmentation_fault.
505
506 2020-07-21 John Baldwin <jhb@FreeBSD.org>
507
508 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
509 Rename to sparc64_linux_report_signal_info and add siggnal
510 argument.
511 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
512 instead of sparc64_linux_handle_segmentation_fault.
513
514 2020-07-21 John Baldwin <jhb@FreeBSD.org>
515
516 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
517 i386_linux_report_signal_info instead of
518 i386_linux_handle_segmentation_fault.
519 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
520 to i386_linux_report_signal_info and add siggnal argument.
521 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
522 of i386_linux_handle_segmentation_fault.
523 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
524 to i386_linux_report_signal_info and add siggnal argument.
525
526 2020-07-21 John Baldwin <jhb@FreeBSD.org>
527
528 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
529 hook if present.
530
531 2020-07-21 John Baldwin <jhb@FreeBSD.org>
532
533 * gdbarch.c: Regenerate.
534 * gdbarch.h: Regenerate.
535 * gdbarch.sh (report_signal_info): New method.
536 * infrun.c (print_signal_received_reason): Invoke gdbarch
537 report_signal_info hook if present.
538
539 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
540
541 * python/py-registers.c : Add 'unordered_map' include.
542 (gdbpy_new_reggroup): Renamed to...
543 (gdbpy_get_reggroup): ...this. Update to only create register
544 group descriptors when needed.
545 (gdbpy_reggroup_iter_next): Update.
546
547 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
548
549 * python/py-registers.c (gdbpy_register_object_data): New static
550 global.
551 (gdbpy_register_object_data_init): New function.
552 (gdbpy_new_register_descriptor): Renamed to...
553 (gdbpy_get_register_descriptor): ...this, and update to reuse
554 existing register descriptors where possible.
555 (gdbpy_register_descriptor_iter_next): Update.
556 (gdbpy_initialize_registers): Register new gdbarch data.
557
558 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
559
560 * linux-nat.c (stopped_pids): Make static.
561
562 2020-07-21 Simon Marchi <simon.marchi@polymtl.ca>
563
564 PR ada/26235
565 * gdbtypes.c (ada_discrete_type_low_bound,
566 ada_discrete_type_high_bound): Handle undefined bounds.
567
568 2020-07-21 Kamil Rytarowski <n54@gmx.com>
569
570 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
571 declaration.
572 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
573 function.
574
575 2020-07-20 John Baldwin <jhb@FreeBSD.org>
576
577 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
578 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
579 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
580 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
581 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
582 method.
583
584 2020-07-20 Ludovic Courtès <ludo@gnu.org>
585
586 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
587 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
588 which are deprecated in Guile 3.0.
589 * configure.ac (try_guile_versions): Add "guile-3.0".
590 * configure (try_guile_versions): Regenerate.
591 * NEWS: Update entry.
592
593 2020-07-20 Ludovic Courtès <ludo@gnu.org>
594 Doug Evans <dje@google.com>
595
596 PR gdb/21104
597 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
598 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
599 USING_GUILE_BEFORE_2_2.
600 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
601 Change type to 'scm_t_port_type *'.
602 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
603 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
604 parameter and honor it. Update callers.
605 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
606 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
607 functions.
608 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
609 USING_GUILE_BEFORE_2_2.
610 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
611 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
612 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
613 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
614 and 'SCM_PORT_TYPE'.
615 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
616 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
617 (gdbscm_memory_port_read, gdbscm_memory_port_write)
618 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
619 [!USING_GUILE_BEFORE_2_2]: New functions.
620 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
621 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
622 'gdbscm_memory_port_read'.
623 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
624 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
625 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
626 function.
627 (ioscm_init_memory_port): Remove.
628 (ioscm_init_memory_port_stream): New function
629 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
630 function.
631 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
632 Return scm_from_uint (0).
633 (gdbscm_set_memory_port_read_buffer_size_x)
634 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
635 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
636 Return scm_from_uint (0).
637 (gdbscm_set_memory_port_write_buffer_size_x)
638 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
639 * configure.ac (try_guile_versions): Add "guile-2.2".
640 * configure: Regenerate.
641 * NEWS: Add entry.
642
643 2020-07-18 Tom Tromey <tom@tromey.com>
644
645 * linux-nat.c (linux_multi_process): Remove.
646 (linux_nat_target::supports_multi_process): Return true.
647
648 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
649
650 * arch/riscv.c (riscv_tdesc_cache): Change map type.
651 (riscv_lookup_target_description): Return pointer out of
652 unique_ptr.
653 * target-descriptions.c (allocate_target_description): Add
654 comment.
655 (target_desc_deleter::operator()): Likewise.
656 * target-descriptions.h (struct target_desc_deleter): Moved to
657 gdbsupport/tdesc.h.
658 (target_desc_up): Likewise.
659
660 2020-07-17 Tom Tromey <tromey@adacore.com>
661
662 * linux-nat.c (linux_nat_target::supports_non_stop)
663 (linux_nat_target::always_non_stop_p): Use "true".
664 (linux_nat_target::supports_disable_randomization): Use "true" and
665 "false".
666
667 2020-07-16 Caroline Tice <cmtice@google.com>
668
669 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
670 (RNGLIST_HEADER_SIZE64): New constant definition.
671 (struct dwop_section_names): Add rnglists_dwo.
672 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
673 (struct loclist_header): Rename to 'loclists_rnglists_header'.
674 (struct dwo_sections): Add rnglists field.
675 (read_attribut_reprocess): Add tag parameter.
676 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
677 (cu_debug_rnglists_section): New function (decl & definition).
678 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
679 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
680 die whose range is being checked; get rnglist section from
681 cu_debug_rnglists_section, to get from either objfile or dwo file as
682 appropriate. Add cases for DW_RLE_base_addressx,
683 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
684 the base address to DW_RLE_offset_pairs (not to all ranges), moving
685 test inside if-condition and updating complaint message.
686 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
687 dwarf2_rnglists_process.
688 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
689 dwarf2_ranges_process.
690 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
691 need_ranges_base and update comment appropriately. Also pass die tag
692 to dwarf2_ranges_read.
693 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
694 need_ranges_base and update comment appropriately. Also pass die tag
695 to dwarf2_ranges_process.
696 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
697 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
698 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
699 need_ranges_base and update comment appropriately. Also pass die tag
700 to read_attribute_reprocess and dwarf2_ranges_read.
701 (read_loclist_header): Rename function to read_loclists_rnglists_header,
702 and update function comment appropriately.
703 (read_loclist_index): Call read_loclists_rnglists_header instead of
704 read_loclist_header.
705 (read_rnglist_index): New function.
706 (read_attribute_reprocess): Add tag parameter. Add code for
707 DW_FORM_rnglistx, passing tag to read_rnglist_index.
708 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
709
710 2020-07-15 Andrew Burgess <andrew.burgess@embecosm.com>
711
712 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
713 being resolved.
714
715 2020-07-14 Andrew Burgess <andrew.burgess@embecosm.com>
716
717 * arch-utils.c (show_architecture): Update formatting of messages.
718
719 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
720
721 * gdbtypes.h (struct type) <bounds>: Handle array and string
722 types.
723 * ada-lang.c (assign_aggregate): Use type::bounds on
724 array/string type.
725 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
726 * c-varobj.c (c_number_of_children): Likewise.
727 (c_describe_child): Likewise.
728 * eval.c (evaluate_subexp_for_sizeof): Likewise.
729 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
730 (f_type_print_base): Likewise.
731 * f-valprint.c (f77_array_offset_tbl): Likewise.
732 (f77_get_upperbound): Likewise.
733 (f77_print_array_1): Likewise.
734 * guile/scm-type.c (gdbscm_type_range): Likewise.
735 * m2-typeprint.c (m2_array): Likewise.
736 (m2_is_long_set_of_type): Likewise.
737 * m2-valprint.c (get_long_set_bounds): Likewise.
738 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
739 * python/py-type.c (typy_range): Likewise.
740 * rust-lang.c (rust_internal_print_type): Likewise.
741 * type-stack.c (type_stack::follow_types): Likewise.
742 * valarith.c (value_subscripted_rvalue): Likewise.
743 * valops.c (value_cast): Likewise.
744
745 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
746
747 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
748 callers to use the equivalent accessor methods.
749
750 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
751
752 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
753 (struct type) <bit_stride>: New method.
754 (TYPE_BIT_STRIDE): Remove.
755 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
756
757 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
758
759 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
760 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
761 callers to use the equivalent accessor methods instead.
762
763 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
764
765 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
766 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
767 callers to use the equivalent accessor methods instead.
768
769 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
770
771 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
772 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
773 to use dynamic_prop::kind.
774
775 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
776
777 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
778 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
779 to get the bound property's kind and check against
780 PROP_UNDEFINED.
781
782 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
783
784 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
785 all callers to use type::range_bounds followed by
786 dynamic_prop::{low,high}.
787
788 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
789
790 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
791 const_val, set_const_val, baton, set_locexpr, set_loclist,
792 set_addr_offset, variant_parts, set_variant_parts,
793 original_type, set_original_type>: New methods.
794 <kind>: Rename to...
795 <m_kind>: ... this. Update all users to use the new methods
796 instead.
797 <data>: Rename to...
798 <m_data>: ... this. Update all users to use the new methods
799 instead.
800
801 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
802
803 * gdbtypes.c (get_discrete_bounds): Return failure if
804 the range type's bounds are not both defined and constant
805 values.
806 (get_array_bounds): Update comment. Remove undefined bound check.
807
808 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
809
810 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
811 the type::bounds method directly.
812
813 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
814
815 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
816 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
817 are used to set the range type's bounds to use set_bounds.
818
819 2020-07-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
820
821 * exec.c (_initialize_exec): Update exec-file-mismatch help.
822
823 2020-07-10 Pedro Alves <pedro@palves.net>
824
825 * gdbthread.h (inferior_ref): Define.
826 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
827 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
828 * thread.c
829 (scoped_restore_current_thread::restore):
830 Adjust to gdb::ref_ptr.
831 (scoped_restore_current_thread::~scoped_restore_current_thread):
832 Remove manual decref handling.
833 (scoped_restore_current_thread::scoped_restore_current_thread):
834 Adjust to use
835 inferior_ref::new_reference/thread_info_ref::new_reference.
836 Incref the thread before calling get_frame_id instead of after.
837 Let TARGET_CLOSE_ERROR propagate.
838
839 2020-07-10 Pedro Alves <pedro@palves.net>
840
841 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
842 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
843 NOT_AVAILABLE_ERROR.
844 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
845 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
846
847 2020-07-10 Simon Marchi <simon.marchi@polymtl.ca>
848 Pedro Alves <pedro@palves.net>
849
850 PR gdb/26199
851 * infrun.c (threads_are_resumed_pending_p): Delete.
852 (do_target_wait): Remove threads_are_executing and
853 threads_are_resumed_pending_p checks from the inferior_matches
854 lambda. Update comments.
855
856 2020-07-10 Pedro Alves <pedro@palves.net>
857
858 PR gdb/26199
859 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
860 executing threads.
861
862 2020-07-10 Pedro Alves <pedro@palves.net>
863
864 PR gdb/26199
865 * infrun.c (handle_no_resumed): Handle multiple targets.
866
867 2020-07-10 Pedro Alves <pedro@palves.net>
868
869 PR gdb/26199
870 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
871 target_is_async_p.
872
873 2020-07-10 Pedro Alves <pedro@palves.net>
874
875 PR gdb/26199
876 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
877 threads, not all threads.
878
879 2020-07-10 Pedro Alves <pedro@palves.net>
880
881 PR gdb/26199
882 * remote.c (remote_target::open_1): Pass remote target pointer as
883 data to create_async_event_handler.
884 (remote_async_inferior_event_handler): Mark async event handler
885 before returning if the remote target still has either pending
886 events or unacknowledged notifications.
887
888 2020-07-10 John Baldwin <jhb@FreeBSD.org>
889
890 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
891 declaration.
892 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
893 function.
894
895 2020-07-09 John Baldwin <jhb@FreeBSD.org>
896
897 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
898 inferior_ptid.
899
900 2020-07-09 John Baldwin <jhb@FreeBSD.org>
901
902 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
903 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
904 AT_FREEBSD_PS_STRINGS.
905
906 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
907
908 * auto-load.c (auto_load_objfile_script_1): Convert drive part
909 of debugfile path on Windows.
910
911 2020-07-08 John Baldwin <jhb@FreeBSD.org>
912
913 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
914 argument to 'data'.
915
916 2020-07-08 Tom Tromey <tromey@adacore.com>
917
918 * ada-lang.c (ada_exception_message_1): Use read_memory.
919
920 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
921
922 PR python/22748
923 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
924 special handling for inline frames.
925 * findvar.c (value_of_register_lazy): Skip inline frames when
926 creating lazy register values.
927 * frame.c (frame_id_computed_p): Delete definition.
928 * frame.h (frame_id_computed_p): Delete declaration.
929
930 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
931
932 * NEWS: Mention additions to Python API.
933 * python/py-arch.c (archpy_register_groups): New function.
934 (arch_object_methods): Add 'register_groups' method.
935 * python/py-registers.c (reggroup_iterator_object): New struct.
936 (reggroup_object): New struct.
937 (gdbpy_new_reggroup): New function.
938 (gdbpy_reggroup_to_string): New function.
939 (gdbpy_reggroup_name): New function.
940 (gdbpy_reggroup_iter): New function.
941 (gdbpy_reggroup_iter_next): New function.
942 (gdbpy_new_reggroup_iterator): New function
943 (gdbpy_initialize_registers): Register new types.
944 (reggroup_iterator_object_type): Define new Python type.
945 (gdbpy_reggroup_getset): New static global.
946 (reggroup_object_type): Define new Python type.
947 * python/python-internal.h
948
949 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
950
951 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
952 * python/py-arch.c (archpy_registers): New function.
953 (arch_object_methods): Add 'registers' method.
954 * python/py-registers.c: New file.
955 * python/python-internal.h
956 (gdbpy_new_register_descriptor_iterator): Declare.
957 (gdbpy_initialize_registers): Declare.
958 * python/python.c (do_start_initialization): Call
959 gdbpy_initialize_registers.
960 * NEWS: Mention additions to the Python API.
961
962 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
963
964 * NEWS: Mention new Python API method.
965 * python/py-unwind.c (pending_framepy_architecture): New function.
966 (pending_frame_object_methods): Add architecture method.
967
968 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
969
970 * gdbarch.c: Regenerate.
971 * gdbarch.h: Regenerate.
972 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
973 (gdbarch_data): Use internal_error for the case where
974 deprecated_set_gdbarch_data was originally needed.
975 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
976 and use passed in obstack.
977 (libunwind_frame_set_descr): Should no longer get back NULL from
978 gdbarch_data.
979 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
980 type.
981 * user-regs.c (user_regs_init): Update parameters, and use passed
982 in obstack.
983 (user_reg_add): Should no longer get back NULL from gdbarch_data.
984 (_initialize_user_regs): Register as a pre-init gdbarch data type.
985
986 2020-07-06 Tom de Vries <tdevries@suse.de>
987
988 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
989 End-Of-Sequence in lte_is_less_than.
990 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
991 "gdb: Don't reorder line table entries too much when sorting".
992
993 2020-07-06 Tom de Vries <tdevries@suse.de>
994
995 PR tui/26205
996 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
997
998 2020-07-05 Tom de Vries <tdevries@suse.de>
999
1000 PR build/26187
1001 * inferior.h (struct infcall_suspend_state_deleter): If available, use
1002 std::uncaught_exceptions instead of deprecated
1003 std::uncaught_exception.
1004
1005 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1006
1007 * macroexp.h (macro_stringify): Return
1008 gdb::unique_xmalloc_ptr<char>.
1009 * macroexp.c (macro_stringify): Likewise.
1010 * macrotab.c (fixup_definition): Update.
1011
1012 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1013
1014 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
1015 (lex_one_token): Update.
1016 * macroexp.c (struct macro_buffer) <release>: Return
1017 gdb::unique_xmalloc_ptr<char>.
1018 (macro_stringify): Update.
1019 (macro_expand): Update.
1020 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
1021 * macroexp.h (macro_expand_next): Likewise.
1022
1023 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
1024
1025 * macroexp.h (macro_lookup_ftype): Remove.
1026 (macro_expand, macro_expand_once, macro_expand_next): Remove
1027 lookup function parameters, add scope parameter.
1028 * macroexp.c (scan, substitute_args, expand, maybe_expand,
1029 macro_expand, macro_expand_once, macro_expand_next): Likewise.
1030 * macroscope.h (standard_macro_lookup): Change parameter type
1031 to macro_scope.
1032 * macroscope.c (standard_macro_lookup): Likewise.
1033 * c-exp.y (lex_one_token): Update.
1034 * macrocmd.c (macro_expand_command): Likewise.
1035 (macro_expand_once_command): Likewise.
1036
1037 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1038
1039 * inf-loop.c (inferior_event_handler): Remove client_data param.
1040 * inf-loop.h (inferior_event_handler): Likewise.
1041 * infcmd.c (step_1): Adjust.
1042 * infrun.c (proceed): Adjust.
1043 (fetch_inferior_event): Remove client_data param.
1044 (infrun_async_inferior_event_handler): Adjust.
1045 * infrun.h (fetch_inferior_event): Remove `void *` param.
1046 * linux-nat.c (handle_target_event): Adjust.
1047 * record-btrace.c (record_btrace_handle_async_inferior_event):
1048 Adjust.
1049 * record-full.c (record_full_async_inferior_event_handler):
1050 Adjust.
1051 * remote.c (remote_async_inferior_event_handler): Adjust.
1052
1053 2020-07-01 Tom Tromey <tom@tromey.com>
1054
1055 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
1056 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
1057
1058 2020-07-01 Tom Tromey <tom@tromey.com>
1059
1060 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
1061 tui_gen_win_info.
1062 (tui_win_info::make_window): Merge with
1063 tui_gen_win_info::make_window.
1064 (tui_win_info::make_visible): Move from tui_gen_win_info.
1065 * tui/tui-win.c (tui_win_info::max_width): Move from
1066 tui_gen_win_info.
1067 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
1068 type.
1069 <window_factory>: Likewise.
1070 * tui/tui-layout.c (tui_win_info::resize): Move from
1071 tui_gen_win_info.
1072 (make_standard_window): Change return type.
1073 (get_locator_window, tui_get_window_by_name): Likewise.
1074 (tui_layout_window::apply): Remove a cast.
1075 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
1076 (struct tui_win_info): Merge with tui_gen_win_info.
1077 (struct tui_gen_win_info): Remove.
1078
1079 2020-07-01 Tom Tromey <tom@tromey.com>
1080
1081 * tui/tui-stack.h (struct tui_locator_window): Derive from
1082 tui_win_info.
1083 <do_scroll_horizontal, do_scroll_vertical>: New methods.
1084 <can_box>: New method.
1085
1086 2020-07-01 Tom Tromey <tom@tromey.com>
1087
1088 * tui/tui-stack.h (struct tui_locator_window): Remove body.
1089
1090 2020-07-01 Tom Tromey <tom@tromey.com>
1091
1092 * tui/tui-regs.c (tui_data_window::display_registers_from)
1093 (tui_data_window::display_registers_from)
1094 (tui_data_window::first_data_item_displayed)
1095 (tui_data_window::delete_data_content_windows): Update.
1096 (tui_data_window::refresh_window, tui_data_window::no_refresh):
1097 Remove.
1098 (tui_data_window::check_register_values): Update.
1099 (tui_data_item_window::rerender): Add parameters. Update.
1100 (tui_data_item_window::refresh_window): Remove.
1101 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
1102 virtual.
1103 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
1104 tui_gen_win_info.
1105 <refresh_window, max_height, min_height>: Remove.
1106 <rerender>: Add parameters.
1107 <x, y, visible>: New members.
1108 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
1109 <m_item_width>: New member.
1110
1111 2020-07-01 Tom Tromey <tom@tromey.com>
1112
1113 * tui/tui-regs.c (tui_data_window::show_register_group)
1114 (tui_data_window::check_register_values): Update.
1115 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
1116 from item_no.
1117
1118 2020-07-01 Tom Tromey <tom@tromey.com>
1119
1120 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
1121 useless "if".
1122
1123 2020-07-01 Tom Tromey <tom@tromey.com>
1124
1125 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
1126 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
1127
1128 2020-07-01 Tom Tromey <tom@tromey.com>
1129
1130 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
1131 * tui/tui-winsource.h (enum tui_line_or_address_kind)
1132 (struct tui_line_or_address): Move from tui-data.h.
1133 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
1134 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
1135 (tui_cmd_window, tui_source_window_base, tui_source_window)
1136 (tui_disasm_window): Don't declare.
1137 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
1138 to tui-winsource.h.
1139 (SINGLE_KEY): Move to tui-stack.c.
1140
1141 2020-07-01 Tom Tromey <tom@tromey.com>
1142
1143 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
1144 std::string.
1145 * tui/tui-regs.c (class tab_expansion_file): New.
1146 (tab_expansion_file::write): New method.
1147 (tui_register_format): Change return type. Use
1148 tab_expansion_file.
1149 (tui_get_register, tui_data_window::display_registers_from)
1150 (tui_data_item_window::rerender): Update.
1151 * tui/tui-io.h (tui_expand_tabs): Don't declare.
1152 * tui/tui-io.c (tui_expand_tabs): Remove.
1153
1154 2020-07-01 Tom Tromey <tom@tromey.com>
1155
1156 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
1157
1158 2020-07-01 Fangrui Song <maskray@google.com>
1159
1160 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
1161
1162 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1163
1164 * dwarf2/read.c (set_die_type): Removed conditions to restrict
1165 forms for DW_AT_associated and DW_AT_allocated attributes,
1166 which is already checked in function attr_to_dynamic_prop.
1167
1168 2020-06-30 Tom Tromey <tromey@adacore.com>
1169
1170 * dwarf2/read.c (quirk_rust_enum): Correctly call
1171 alloc_rust_variant for default-less enum.
1172
1173 2020-06-30 Tom Tromey <tromey@adacore.com>
1174
1175 PR build/26183:
1176 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
1177 gdb::to_string.
1178
1179 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
1180
1181 * gdbarch.sh (displaced_step_copy_insn): Update doc.
1182 * gdbarch.h: Re-generate.
1183
1184 2020-06-28 Tom Tromey <tom@tromey.com>
1185
1186 * command.h (cmd_types): Remove.
1187 (cmd_type): Don't declare.
1188 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
1189 typedef.
1190 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
1191 * cli/cli-decode.c (cmd_type): Remove.
1192
1193 2020-06-27 Pedro Alves <palves@redhat.com>
1194
1195 * fork-child.c (prefork_hook): Adjust.
1196 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
1197 Delete.
1198 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
1199 * inferior.c (inferior::set_tty, inferior::tty): New methods.
1200 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
1201 Remove declarations.
1202 (struct inferior) <set_tty, tty>: New methods.
1203 (struct inferior) <terminal>: Rename to ...
1204 (struct inferior) <m_terminal>: ... this and make private.
1205 * main.c (captured_main_1): Adjust.
1206 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
1207 (mi_cmd_inferior_tty_show): Adjust.
1208 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
1209 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
1210
1211 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
1212
1213 * configure.ac: Add --enable-libctf: handle --disable-static
1214 properly.
1215 * acinclude.m4: sinclude ../config/enable.m4.
1216 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
1217 (LIBCTF): Substitute in.
1218 (CTF_DEPS): New, likewise.
1219 (CLIBS): libctf needs symbols from libbfd: move earlier.
1220 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
1221 flags.
1222 * ctfread.c: Surround in ENABLE_LIBCTF.
1223 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
1224 * configure: Regenerate.
1225 * config.in: Likewise.
1226
1227 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
1228
1229 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
1230
1231 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
1232
1233 * inferior.h (struct inferior) <terminal>: Change type to
1234 gdb::unique_xmalloc_ptr<char>.
1235 * inferior.c (inferior::~inferior): Don't free inf->terminal.
1236 * infcmd.c (set_inferior_io_terminal): Don't free terminal
1237 field, adjust to unique pointer.
1238 (get_inferior_io_terminal): Adjust to unique pointer.
1239
1240 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1241
1242 * riscv-tdep.c (riscv_print_registers_info): Loop over all
1243 registers, not just the known core set of registers.
1244
1245 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1246
1247 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
1248 fflags, frm, and fcsr registers.
1249 (riscv_register_reggroup_p): Remove unknown CSRs from save and
1250 restore groups.
1251 (riscv_tdesc_unknown_reg): New function.
1252 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
1253 tdesc_use_registers.
1254 * riscv-tdep.h (struct gdbarch_tdep): Add
1255 unknown_csrs_first_regnum, unknown_csrs_count,
1256 duplicate_fflags_regnum, duplicate_frm_regnum, and
1257 duplicate_fcsr_regnum fields.
1258
1259 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1260
1261 * target-descriptions.c (tdesc_use_registers): Add new parameter a
1262 callback, use the callback (when not null) to help number unknown
1263 registers.
1264 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
1265 (tdesc_use_registers): Add extra parameter to declaration.
1266
1267 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1268
1269 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
1270 in the file.
1271 (class riscv_pending_register_alias): Likewise.
1272 (riscv_register_feature::register_info): Change 'required_p' field
1273 to 'required', and change its type. Add 'check' member function.
1274 (riscv_register_feature::register_info::check): Define new member
1275 function.
1276 (riscv_xreg_feature): Change initialisation of 'required' field.
1277 (riscv_freg_feature): Likewise.
1278 (riscv_virtual_feature): Likewise.
1279 (riscv_csr_feature): Likewise.
1280 (riscv_check_tdesc_feature): Take extra parameter, the csr
1281 tdesc_feature, rewrite the function to use the new
1282 riscv_register_feature::register_info::check function.
1283 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
1284
1285 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1286
1287 * features/Makefile: Remove all references to the deleted files
1288 below.
1289 * features/riscv/32bit-csr.c: Deleted.
1290 * features/riscv/32bit-csr.xml: Deleted.
1291 * features/riscv/64bit-csr.c: Deleted.
1292 * features/riscv/64bit-csr.xml: Deleted.
1293 * features/riscv/rebuild-csr-xml.sh: Deleted.
1294
1295 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1296
1297 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
1298 whitespace error for declaration of names member variable.
1299 (struct riscv_register_feature): Add new prefer_first_name member
1300 variable, and fix whitespace error in declaration of registers.
1301 (riscv_xreg_feature): Initialize prefer_first_name field.
1302 (riscv_freg_feature): Likewise.
1303 (riscv_virtual_feature): Likewise.
1304 (riscv_csr_feature): Likewise.
1305 (riscv_register_name): Expand on comments. Remove register name
1306 modifications for CSR and virtual registers.
1307
1308 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1309
1310 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
1311 errors.
1312
1313 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1314
1315 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
1316 riscv-opc.h.
1317 (class riscv_pending_register_alias): New class.
1318 (riscv_check_tdesc_feature): Take vector of pending aliases and
1319 populate it as appropriate.
1320 (riscv_setup_register_aliases): Delete.
1321 (riscv_gdbarch_init): Create vector of pending aliases and pass it
1322 to riscv_check_tdesc_feature in all cases. Use the vector to
1323 create the register aliases.
1324
1325 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1326
1327 * sol2-tdep.c (sol2_static_transform_name): Remove.
1328 (sol2_init_abi): Don't register it.
1329 * gdbarch.sh (static_transform_name): Remove.
1330 * gdbarch.c, gdbarch.h: Regenerate.
1331
1332 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
1333 gdbarch_static_transform_name.
1334 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
1335 * stabsread.c (define_symbol) <'X'>: Remove.
1336 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
1337 handling.
1338 <'V'>: Likewise.
1339 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
1340 <'S'>: Remove call to gdbarch_static_transform_name.
1341
1342 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1343
1344 * procfs.c (procfs_pre_trace): New function.
1345 (procfs_target::create_inferior): Pass it to fork_inferior.
1346
1347 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1348
1349 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
1350 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
1351 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
1352 sol2-tdep.o, sparc-sol2-tdep.o.
1353 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
1354 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
1355 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
1356 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
1357
1358 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1359
1360 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
1361 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
1362 Call sol2_init_abi.
1363 Remove calls to set_gdbarch_skip_solib_resolver,
1364 set_gdbarch_core_pid_to_str.
1365 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
1366 (i386_sol2_static_transform_name): Remove.
1367 (i386_sol2_init_abi): Call sol2_init_abi.
1368 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1369 set_gdbarch_static_transform_name,
1370 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
1371 Use sol2_sigtramp_p.
1372 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
1373 (sol2_sigtramp_p): New function.
1374 (sol2_static_transform_name): New function.
1375 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
1376 (sol2_init_abi): New function.
1377 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
1378 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
1379 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
1380 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
1381 (sparc_sol2_static_transform_name): Remove.
1382 (sparc32_sol2_init_abi): Call sol2_init_abi.
1383 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1384 set_gdbarch_static_transform_name,
1385 set_gdbarch_skip_solib_resolver,
1386 set_gdbarch_core_pid_to_str.
1387 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
1388 (sparc_sol2_static_transform_name): Remove
1389 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
1390 call sol2_sigtramp_p.
1391 (sparc64_sol2_init_abi): Call sol2_init_abi.
1392 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1393 set_gdbarch_static_transform_name,
1394 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
1395
1396 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1397
1398 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
1399 * exec.c (validate_exec_file): If from_tty, set both
1400 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
1401 * symfile.c (symbol_file_add_with_addrs): if always_confirm
1402 and from_tty, unconditionally ask a confirmation.
1403
1404 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1405
1406 * target-descriptions.c (tdesc_architecture_name): Protect against
1407 NULL pointer dereference.
1408 (maint_print_xml_tdesc_cmd): New function.
1409 (_initialize_target_descriptions): Register new 'maint print
1410 xml-tdesc' command and give it the filename completer.
1411 * NEWS: Mention new 'maint print xml-tdesc' command.
1412
1413 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1414
1415 * target-descriptions.c (class tdesc_compatible_info): New class.
1416 (struct target_desc): Change type of compatible vector.
1417 (tdesc_compatible_p): Update for change in type of
1418 target_desc::compatible.
1419 (tdesc_compatible_info_list): New function.
1420 (tdesc_compatible_info_arch_name): New function.
1421 (tdesc_add_compatible): Update for change in type of
1422 target_desc::compatible.
1423 (print_c_tdesc::visit_pre): Likewise.
1424
1425 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1426
1427 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
1428 whitespace to underscore.
1429 (maint_print_c_tdesc_cmd): Use fake filename for target
1430 descriptions that came from the target.
1431 (_initialize_target_descriptions): Add filename command completion
1432 for 'maint print c-tdesc'.
1433
1434 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
1435
1436 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
1437 lines.
1438
1439 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
1440
1441 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
1442 lines.
1443 (dwarf2_find_location_expression): Likewise.
1444 (call_site_parameter_matches): Likewise.
1445 (dwarf2_compile_expr_to_ax): Likewise.
1446 (disassemble_dwarf_expression): Likewise.
1447 (loclist_describe_location): Likewise.
1448
1449 2020-06-23 Pedro Alves <palves@redhat.com>
1450
1451 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
1452 progspace-and-thread.h. Include scoped-mock-context.h instead.
1453 (register_to_value_test): Use scoped_mock_context.
1454 * regcache.c: Include "scoped-mock-context.h".
1455 (cooked_read_test): Don't error out if a target is already pushed.
1456 Use scoped_mock_context. Adjust.
1457 * scoped-mock-context.h: New file.
1458
1459 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1460
1461 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
1462 initializer.
1463 (ada_language::is_string_type_p): New member function.
1464 * c-lang.c (c_language_data): Delete la_is_string_type_p
1465 initializer.
1466 (cplus_language_data): Likewise.
1467 (asm_language_data): Likewise.
1468 (minimal_language_data): Likewise.
1469 * d-lang.c (d_language_data): Likewise.
1470 * f-lang.c (f_is_string_type_p): Delete function, implementation
1471 moved to f_language::is_string_type_p.
1472 (f_language_data): Delete la_is_string_type_p initializer.
1473 (f_language::is_string_type_p): New member function,
1474 implementation from f_is_string_type_p.
1475 * go-lang.c (go_is_string_type_p): Delete function, implementation
1476 moved to go_language::is_string_type_p.
1477 (go_language_data): Delete la_is_string_type_p initializer.
1478 (go_language::is_string_type_p): New member function,
1479 implementation from go_is_string_type_p.
1480 * language.c (language_defn::is_string_type_p): Define new member
1481 function.
1482 (default_is_string_type_p): Make static, add comment copied from
1483 header file.
1484 (unknown_language_data): Delete la_is_string_type_p initializer.
1485 (unknown_language::is_string_type_p): New member function.
1486 (auto_language_data): Delete la_is_string_type_p initializer.
1487 (auto_language::is_string_type_p): New member function.
1488 * language.h (language_data): Delete la_is_string_type_p field.
1489 (language_defn::is_string_type_p): Declare new function.
1490 (default_is_string_type_p): Delete desclaration, move comment to
1491 definition.
1492 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
1493 moved to m2_language::is_string_type_p.
1494 (m2_language_data): Delete la_is_string_type_p initializer.
1495 (m2_language::is_string_type_p): New member function,
1496 implementation from m2_is_string_type_p.
1497 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
1498 initializer.
1499 * opencl-lang.c (opencl_language_data): Likewise.
1500 * p-lang.c (pascal_is_string_type_p): Delete function,
1501 implementation moved to pascal_language::is_string_type_p.
1502 (pascal_language_data): Delete la_is_string_type_p initializer.
1503 (pascal_language::is_string_type_p): New member function,
1504 implementation from pascal_is_string_type_p.
1505 * rust-lang.c (rust_is_string_type_p): Delete function,
1506 implementation moved to rust_language::is_string_type_p.
1507 (rust_language_data): Delete la_is_string_type_p initializer.
1508 (rust_language::is_string_type_p): New member function,
1509 implementation from rust_is_string_type_p.
1510 * valprint.c (val_print_scalar_or_string_type_p): Update call to
1511 is_string_type_p.
1512
1513 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1514
1515 * ada-lang.c (ada_language_data): Delete la_print_typedef
1516 initializer.
1517 (ada_language::print_typedef): New member function.
1518 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
1519 (cplus_language_data): Likewise.
1520 (asm_language_data): Likewise.
1521 (minimal_language_data): Likewise.
1522 * d-lang.c (d_language_data): Likewise.
1523 * f-lang.c (f_language_data): Likewise.
1524 (f_language::print_typedef): New member function.
1525 * go-lang.c (go_language_data): Delete la_print_typedef
1526 initializer.
1527 * language.c (language_defn::print_typedef): Define member
1528 function.
1529 (unknown_language_data): Delete la_print_typedef initializer.
1530 (unknown_language::print_typedef): New member function.
1531 (auto_language_data): Delete la_print_typedef initializer.
1532 (auto_language::print_typedef): New member function.
1533 * language.h (language_data): Delete la_print_typedef field.
1534 (language_defn::print_typedef): Declare new member function.
1535 (LA_PRINT_TYPEDEF): Update call to print_typedef.
1536 (default_print_typedef): Delete declaration.
1537 * m2-lang.c (m2_language_data): Delete la_print_typedef
1538 initializer.
1539 (m2_language::print_typedef): New member function.
1540 * objc-lang.c (objc_language_data): Delete la_print_typedef
1541 initializer.
1542 * opencl-lang.c (opencl_language_data): Likewise.
1543 * p-lang.c (pascal_language_data): Likewise.
1544 (pascal_language::print_typedef): New member function.
1545 * rust-lang.c (rust_print_typedef): Delete function,
1546 implementation moved to rust_language::print_typedef.
1547 (rust_language): Delete la_print_typedef initializer.
1548 (rust_language::print_typedef): New member function,
1549 implementation from rust_print_typedef.
1550 * typeprint.c (default_print_typedef): Delete.
1551
1552 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1553
1554 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
1555 (ada_language::printstr): New member function.
1556 * c-lang.c (c_language_data): Delete la_printstr initializer.
1557 (cplus_language_data): Likewise.
1558 (asm_language_data): Likewise.
1559 (minimal_language_data): Likewise.
1560 * d-lang.c (d_language_data): Likewise.
1561 * f-lang.c (f_printstr): Rename to f_language::printstr.
1562 (f_language_data): Delete la_printstr initializer.
1563 (f_language::printstr): New member function, implementation from
1564 f_printstr.
1565 * go-lang.c (go_language_data): Delete la_printstr initializer.
1566 * language.c (language_defn::printstr): Define new member
1567 function.
1568 (unk_lang_printstr): Delete.
1569 (unknown_language_data): Delete la_printstr initializer.
1570 (unknown_language::printstr): New member function.
1571 (auto_language_data): Delete la_printstr initializer.
1572 (auto_language::printstr): New member function.
1573 * language.h (language_data): Delete la_printstr field.
1574 (language_defn::printstr): Declare new member function.
1575 (LA_PRINT_STRING): Update call to printstr.
1576 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
1577 (m2_language_data): Delete la_printstr initializer.
1578 (m2_language::printstr): New member function, implementation from
1579 m2_printstr.
1580 * objc-lang.c (objc_language_data): Delete la_printstr
1581 initializer.
1582 * opencl-lang.c (opencl_language_data): Likewise.
1583 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
1584 (pascal_language_data): Delete la_printstr initializer.
1585 (pascal_language::printstr): New member function, implementation
1586 from pascal_printstr.
1587 * p-lang.h (pascal_printstr): Delete declaration.
1588 * rust-lang.c (rust_printstr): Update header comment.
1589 (rust_language_data): Delete la_printstr initializer.
1590 (rust_language::printstr): New member function.
1591
1592 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1593
1594 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
1595 (ada_language::printchar): New member function.
1596 * c-lang.c (c_language_data): Delete la_printchar initializer.
1597 (cplus_language_data): Likewise.
1598 (asm_language_data): Likewise.
1599 (minimal_language_data): Likewise.
1600 * d-lang.c (d_language_data): Likewise.
1601 * f-lang.c (f_printchar): Rename to f_language::printchar.
1602 (f_language_data): Delete la_printchar initializer.
1603 (f_language::printchar): New member function, implementation from
1604 f_printchar.
1605 * go-lang.c (go_language_data): Delete la_printchar initializer.
1606 * language.c (unk_lang_printchar): Delete.
1607 (language_defn::printchar): Define new member function.
1608 (unknown_language_data): Delete la_printchar initializer.
1609 (unknown_language::printchar): New member function.
1610 (auto_language_data): Delete la_printchar initializer.
1611 (auto_language::printchar): New member function.
1612 * language.h (language_data): Delete la_printchar field.
1613 (language_defn::printchar): Declare new member function.
1614 (LA_PRINT_CHAR): Update call to printchar.
1615 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
1616 (m2_language::printchar): New member function.
1617 * objc-lang.c (objc_language_data): Delete la_printchar
1618 initializer.
1619 * opencl-lang.c (opencl_language_data): Likewise.
1620 * p-lang.c (pascal_language_data): Delete la_printchar
1621 initializer.
1622 (pascal_language::printchar): New member function.
1623 * rust-lang.c (rust_printchar): Rename to
1624 rust_language::printchar.
1625 (rust_language_data): Delete la_printchar initializer.
1626 (rust_language::printchar): New member function, implementation
1627 from rust_printchar.
1628
1629 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1630
1631 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
1632 (ada_language_data): Delete la_emitchar initializer.
1633 (ada_language::emitchar): New member function, implementation from
1634 emit_char.
1635 * c-lang.c (c_language_data): Delete la_emitchar initializer.
1636 (cplus_language_data): Likewise.
1637 (asm_language_data): Likewise.
1638 (minimal_language_data): Likewise.
1639 * d-lang.c (d_language_data): Likewise.
1640 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
1641 (f_language_data): Delete la_emitchar initializer.
1642 (f_language::emitchar): New member function, implementation from
1643 f_emit_char.
1644 * go-lang.c (go_language_data): Delete la_emitchar initializer.
1645 * language.c (unk_lang_emit_char): Delete.
1646 (language_defn::emitchar): New member function definition.
1647 (unknown_language_data): Delete la_emitchar initializer.
1648 (unknown_language::emitchar): New member function.
1649 (auto_language_data): Delete la_emitchar initializer.
1650 (auto_language::emitchar): New member function.
1651 * language.h (language_data): Delete la_emitchar field.
1652 (language_defn::emitchar): New member field declaration.
1653 (LA_EMIT_CHAR): Update call to emitchar.
1654 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
1655 (m2_language_data): Delete la_emitchar initializer.
1656 (m2_language::emitchar): New member function, implementation from
1657 m2_emit_char.
1658 * objc-lang.c (objc_language_data): Delete la_emitchar
1659 initializer.
1660 * opencl-lang.c (opencl_language_data): Likewise.
1661 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
1662 (pascal_language_data): Delete la_emitchar initializer.
1663 (pascal_language::emitchar): New member function, implementation
1664 from pascal_emit_char.
1665 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
1666 (rust_language_data): Delete la_emitchar initializer.
1667 (rust_language::emitchar): New member function, implementation
1668 from rust_emitchar.
1669
1670 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1671
1672 * ada-lang.c (resolve): Rename to ada_language::post_parser.
1673 (ada_language_data): Delete la_post_parser initializer.
1674 (ada_language::post_parser): New member function.
1675 * c-lang.c (c_language_data): Delete la_post_parser initializer.
1676 (cplus_language_data): Likewise.
1677 (asm_language_data): Likewise.
1678 (minimal_language_data): Likewise.
1679 * d-lang.c (d_language_data): Likewise.
1680 * f-lang.c (f_language_data): Likewise.
1681 * go-lang.c (go_language_data): Likewise.
1682 * language.c (unknown_language_data): Likewise.
1683 (auto_language_data): Likewise.
1684 * language.h (language_data): Delete la_post_parser field.
1685 (language_defn::post_parser): New member function.
1686 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
1687 * objc-lang.c (objc_language_data): Likewise.
1688 * opencl-lang.c (opencl_language_data): Likewise.
1689 * p-lang.c (pascal_language_data): Likewise.
1690 * parse.c (parse_exp_in_context): Update call to post_parser.
1691 (null_post_parser): Delete definition.
1692 * parser-defs.h (null_post_parser): Delete declaration.
1693 * rust-lang.c (rust_language_data): Delete la_post_parser
1694 initializer.
1695
1696 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1697
1698 * ada-lang.c (parse): Rename to ada_language::parser.
1699 (ada_language_data): Delete la_parser initializer.
1700 (ada_language::parser): New member function, implementation from
1701 parse.
1702 * c-lang.c (c_language_data): Delete la_parser initializer.
1703 (cplus_language_data): Likewise.
1704 (asm_language_data): Likewise.
1705 (minimal_language_data): Likewise.
1706 * d-lang.c (d_language_data): Likewise.
1707 (d_language::parser): New member function.
1708 * f-lang.c (f_language_data): Delete la_parser initializer.
1709 (f_language::parser): New member function.
1710 * go-lang.c (go_language_data): Delete la_parser initializer.
1711 (go_language::parser): New member function.
1712 * language.c (unk_lang_parser): Delete.
1713 (language_defn::parser): Define new member function.
1714 (unknown_language_data): Delete la_parser initializer.
1715 (unknown_language::parser): New member function.
1716 (auto_language_data): Delete la_parser initializer.
1717 (auto_language::parser): New member function.
1718 * language.h (language_data): Delete la_parser field.
1719 (language_defn::parser): Declare new member function.
1720 * m2-lang.c (m2_language_data): Delete la_parser initializer.
1721 (m2_language::parser): New member function.
1722 * objc-lang.c (objc_language_data): Delete la_parser initializer.
1723 * opencl-lang.c (opencl_language_data): Likewise.
1724 * p-lang.c (pascal_language_data): Likewise.
1725 (pascal_language::parser): New member function.
1726 * parse.c (parse_exp_in_context): Update call to parser.
1727 * rust-lang.c (rust_language_data): Delete la_parser initializer.
1728 (rust_language::parser): New member function.
1729
1730 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1731
1732 * top.c (print_gdb_configuration): Print --with-python-libdir
1733 configuration value.
1734
1735 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1736
1737 * NEWS: Mention change to the alias command.
1738
1739 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1740
1741 * cli/cli-cmds.c (lookup_cmd_for_default_args)
1742 (alias_command_completer)
1743 (make_alias_options_def_group): New functions.
1744 (alias_opts, alias_option_defs): New struct and array.
1745 (alias_usage_error): Update usage.
1746 (alias_command): Handles optional DEFAULT-ARGS... arguments.
1747 Use option framework.
1748 (_initialize_cli_cmds): Update alias command help.
1749 Update aliases command help.
1750 (show_user):
1751 Add NULL for new default_args lookup_cmd argument.
1752 (valid_command_p): Rename to validate_aliased_command.
1753 Add NULL for new default_args lookup_cmd argument. Verify that the
1754 aliased_command has no default args.
1755 * cli/cli-decode.c (help_cmd): Show aliases definitions.
1756 (lookup_cmd_1, lookup_cmd): New argument default_args.
1757 (add_alias_cmd):
1758 Add NULL for new default_args lookup_cmd argument.
1759 (print_help_for_command): Show default args under the layout
1760 alias some_alias = some_aliased_cmd some_alias_default_arg.
1761 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
1762 xfree default_args in destructor.
1763 * cli/cli-script.c (process_next_line, do_define_command):
1764 Add NULL for new default_args lookup_cmd argument.
1765 * command.h: Declare new default_args argument in lookup_cmd
1766 and lookup_cmd_1.
1767 * completer.c (complete_line_internal_1):
1768 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1769 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
1770 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
1771 Likewise.
1772 * infcmd.c (_initialize_infcmd): Likewise.
1773 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
1774 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
1775 * python/py-param.c (add_setshow_generic): Likewise.
1776 * remote.c (_initialize_remote): Likewise.
1777 * top.c (execute_command): Prepend default_args if command has some.
1778 (set_verbose):
1779 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1780 * tracepoint.c (validate_actionline, encode_actions_1):
1781 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1782
1783 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1784
1785 * jit.c (jit_read_descriptor): Use bool as the return type.
1786 (jit_breakpoint_re_set_internal): Use bool as the return type.
1787 Invert the return value logic; return true if the jit breakpoint
1788 has been successfully initialized.
1789 (jit_inferior_init): Update the call to
1790 jit_breakpoint_re_set_internal.
1791
1792 2020-06-22 Pedro Alves <palves@redhat.com>
1793
1794 PR gdb/25939
1795 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
1796 Use the current inferior instead. Don't return
1797 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
1798 wait again.
1799 * sol-thread.c (sol_thread_target::wait): Don't reference
1800 inferior_ptid.
1801 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
1802 (sol_update_thread_list_callback): Use the current inferior's pid
1803 instead of inferior_ptid.
1804
1805 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1806
1807 * procfs.c: Cleanup many comments.
1808
1809 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
1810 (AFTER_WATCHFLAG): Replace by value.
1811
1812 (MAIN_PROC_NAME_FORMAT): Inline ...
1813 (create_procinfo): ... here.
1814
1815 (procfs_debug_inferior): Remove SYS_exec handling.
1816 (syscall_is_exec): Likewise.
1817 (procfs_set_exec_trap): Likewise.
1818
1819 (syscall_is_lwp_exit): Inline in callers.
1820 (syscall_is_exit): Likewise.
1821 (syscall_is_exec): Likewise.
1822 (syscall_is_lwp_create): Likewise.
1823
1824 (invalidate_cache): Remove #if 0 code.
1825
1826 (make_signal_thread_runnable): Remove.
1827 (procfs_target::resume): Remove #if 0 code.
1828
1829 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1830
1831 PR gdb/25939
1832 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
1833 call ...
1834 (procfs_target::create_inferior): ... here.
1835
1836 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1837
1838 * exec.c (validate_exec_file): Ensure the build-id is up to
1839 date by calling reopen_exec_file (that checks file timestamp
1840 to decide to re-read the file).
1841
1842 2020-06-18 Pedro Alves <palves@redhat.com>
1843
1844 PR gdb/25412
1845 * gdbthread.h (delete_thread, delete_thread_silent)
1846 (find_thread_ptid): Update comments.
1847 * thread.c (current_thread_): New global.
1848 (is_current_thread): Move higher, and reimplement.
1849 (inferior_thread): Reimplement.
1850 (set_thread_exited): Use bool. Add assertions.
1851 (add_thread_silent): Simplify thread-reuse handling by always
1852 calling delete_thread.
1853 (delete_thread): Remove intro comment.
1854 (find_thread_ptid): Skip exited threads.
1855 (switch_to_thread_no_regs): Write to current_thread_.
1856 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
1857 INFERIOR_PTID. Clear current_thread_.
1858
1859 2020-06-18 Pedro Alves <palves@redhat.com>
1860
1861 * aix-thread.c (pd_update): Use switch_to_thread.
1862
1863 2020-06-18 Pedro Alves <palves@redhat.com>
1864
1865 * ravenscar-thread.c (ravenscar_thread_target): Update.
1866 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
1867 (ravenscar_thread_target::add_active_thread): ... this. Don't
1868 set m_base_ptid here. Update to avoid referencing inferior_ptid.
1869 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
1870
1871 2020-06-18 Pedro Alves <palves@redhat.com>
1872
1873 * nat/windows-nat.c (current_windows_thread): Remove.
1874 * nat/windows-nat.h (current_windows_thread): Remove.
1875 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
1876 Adjust.
1877 (display_selectors): Adjust to fetch the current
1878 windows_thread_info based on inferior_ptid.
1879 (fake_create_process): No longer write to current_windows_thread.
1880 (windows_nat_target::get_windows_debug_event):
1881 Don't set inferior_ptid or current_windows_thread.
1882 (windows_nat_target::wait): Adjust to not rely on
1883 current_windows_thread.
1884 (do_initial_windows_stuff): Now a method of windows_nat_target.
1885 Switch to the last_ptid thread.
1886 (windows_nat_target::attach): Adjust.
1887 (windows_nat_target::detach): Use switch_to_no_thread instead of
1888 writing to inferior_ptid directly.
1889 (windows_nat_target::create_inferior): Adjust.
1890
1891 2020-06-18 Pedro Alves <palves@redhat.com>
1892
1893 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
1894
1895 2020-06-18 Pedro Alves <palves@redhat.com>
1896
1897 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
1898 after creating it, instead of writing to inferior_ptid. Don't
1899 write to inferior_ptid.
1900
1901 2020-06-18 Pedro Alves <palves@redhat.com>
1902
1903 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
1904
1905 2020-06-18 Pedro Alves <palves@redhat.com>
1906
1907 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
1908 it, instead of writing to inferior_ptid.
1909
1910 2020-06-18 Pedro Alves <palves@redhat.com>
1911
1912 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
1913 to inferior_ptid.
1914
1915 2020-06-18 Pedro Alves <palves@redhat.com>
1916
1917 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
1918 instead of writing to inferior_ptid directly.
1919
1920 2020-06-18 Pedro Alves <palves@redhat.com>
1921
1922 * corelow.c (core_target::close): Use switch_to_no_thread instead
1923 of writing to inferior_ptid directly.
1924 (add_to_thread_list, core_target_open): Use switch_to_thread
1925 instead of writing to inferior_ptid directly.
1926
1927 2020-06-18 Pedro Alves <palves@redhat.com>
1928
1929 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
1930 inferior_ptid.
1931 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
1932 inferior_ptid.
1933 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
1934 inferior_ptid directly.
1935 (darwin_nat_target::init_thread_list): Switch to thread, instead
1936 of writing to inferior_ptid.
1937 (darwin_nat_target::attach): Don't write to inferior_ptid.
1938 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
1939
1940 2020-06-18 Pedro Alves <palves@redhat.com>
1941
1942 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
1943 thread.
1944 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
1945 Instead use switch_to_thread.
1946 (gnu_nat_target::detach): Use switch_to_no_thread
1947 instead of writing to inferior_ptid directly. Used passed-in
1948 inferior instead of looking up the inferior by pid.
1949
1950 2020-06-18 Pedro Alves <palves@redhat.com>
1951
1952 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
1953 inferior_ptid.
1954
1955 2020-06-18 Pedro Alves <palves@redhat.com>
1956
1957 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
1958 inferior_ptid.
1959 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
1960 thread.
1961 (nto_procfs_target::detach): Avoid referencing
1962 inferior_ptid. Use switch_to_no_thread instead of writing to
1963 inferior_ptid directly.
1964 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
1965 instead of writing to inferior_ptid directly.
1966 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
1967 to thread.
1968
1969 2020-06-18 Pedro Alves <palves@redhat.com>
1970
1971 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
1972 after creating it, instead of writing to inferior_ptid.
1973 (gdbsim_target_open): Use switch_to_no_thread instead of writing
1974 to inferior_ptid directly.
1975 (gdbsim_target::wait): Don't write to inferior_ptid.
1976
1977 2020-06-18 Pedro Alves <palves@redhat.com>
1978
1979 * remote.c (remote_target::remote_notice_new_inferior): Use
1980 switch_to_thread instead of writing to inferior_ptid directly.
1981 (remote_target::add_current_inferior_and_thread): Use
1982 switch_to_no_thread instead of writing to inferior_ptid directly.
1983 (extended_remote_target::attach): Use switch_to_inferior_no_thread
1984 and switch_to_thread instead of using set_current_inferior or
1985 writing to inferior_ptid directly.
1986
1987 2020-06-18 Pedro Alves <palves@redhat.com>
1988
1989 * tracectf.c (ctf_target_open): Switch to added thread instead of
1990 writing to inferior_ptid directly.
1991 (ctf_target::close): Use switch_to_no_thread instead of writing to
1992 inferior_ptid directly.
1993
1994 2020-06-18 Pedro Alves <palves@redhat.com>
1995
1996 * tracefile-tfile.c (tfile_target_open): Don't write to
1997 inferior_ptid directly, instead switch to added thread.
1998 (tfile_target::close): Use switch_to_no_thread instead of writing
1999 to inferior_ptid directly.
2000
2001 2020-06-18 Pedro Alves <palves@redhat.com>
2002
2003 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
2004 (procfs_target::detach): Use switch_to_no_thread
2005 instead of writing to inferior_ptid directly.
2006 (do_attach): Change return type to void. Switch to the added
2007 thread.
2008 (procfs_target::create_inferior): Switch to the added thread.
2009 (procfs_do_thread_registers): Don't write to inferior_ptid.
2010
2011 2020-06-18 Pedro Alves <palves@redhat.com>
2012
2013 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
2014 of writing to inferior_ptid.
2015 (scoped_restore_exited_inferior): Delete.
2016 (handle_vfork_child_exec_or_exit): Simplify using
2017 scoped_restore_current_pspace_and_thread. Use switch_to_thread
2018 instead of writing to inferior_ptid.
2019 (THREAD_STOPPED_BY): Delete.
2020 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
2021 (thread_stopped_by_hw_breakpoint): Delete.
2022 (save_waitstatus): Use
2023 scoped_restore_current_thread+switch_to_thread, and call
2024 target_stopped_by_watchpoint instead of
2025 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
2026 instead of thread_stopped_by_sw_breakpoint, and
2027 target_stopped_by_hw_breakpoint instead of
2028 thread_stopped_by_hw_breakpoint.
2029 (handle_inferior_event)
2030 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
2031 inferior_ptid directly, nor
2032 set_current_inferior/set_current_program_space. Use
2033 switch_to_thread / switch_to_inferior_no_thread instead.
2034
2035 2020-06-18 Pedro Alves <palves@redhat.com>
2036
2037 * target.c (generic_mourn_inferior): Use switch_to_no_thread
2038 instead of writing to inferior_ptid.
2039
2040 2020-06-18 Pedro Alves <palves@redhat.com>
2041
2042 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
2043 added thread.
2044 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
2045 to the added thread.
2046 (inf_ptrace_target::detach_success): Use switch_to_no_thread
2047 instead of writing to inferior_ptid.
2048
2049 2020-06-18 Pedro Alves <palves@redhat.com>
2050
2051 * gdbarch-selftests.c: Include "progspace-and-thread.h".
2052 (register_to_value_test): Mock a program_space too. Heap-allocate
2053 the address space. Don't write to inferior_ptid. Use
2054 switch_to_thread instead.
2055
2056 2020-06-18 Pedro Alves <palves@redhat.com>
2057
2058 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
2059 Delete.
2060 (find_signalled_thread()): New, factored out from
2061 linux_make_corefile_notes and adjusted to handle exited threads.
2062 (linux_make_corefile_notes): Adjust to use the new
2063 find_signalled_thread.
2064
2065 2020-06-18 Pedro Alves <palves@redhat.com>
2066
2067 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
2068 of saving/restoring inferior_ptid.
2069
2070 2020-06-17 Tom Tromey <tom@tromey.com>
2071
2072 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
2073 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
2074 declare.
2075 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
2076
2077 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
2078
2079 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
2080 of partial symtabs.
2081
2082 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2083
2084 * regformats/reg-arm.dat: Remove.
2085 * regformats/reg-bfin.dat: Remove.
2086 * regformats/reg-cris.dat: Remove.
2087 * regformats/reg-crisv32.dat: Remove.
2088 * regformats/reg-m32r.dat: Remove.
2089 * regformats/reg-tilegx.dat: Remove.
2090 * regformats/reg-tilegx32.dat: Remove.
2091
2092 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2093
2094 * features/Makefile (WHICH): Remove arm files.
2095 * regformats/arm/arm-with-iwmmxt.dat: Remove.
2096 * regformats/arm/arm-with-neon.dat: Remove.
2097 * regformats/arm/arm-with-vfpv2.dat: Remove.
2098 * regformats/arm/arm-with-vfpv3.dat: Remove.
2099
2100 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2101
2102 * features/Makefile (XMLTOC): Remove rx.xml.
2103
2104 2020-06-17 Pedro Alves <palves@redhat.com>
2105
2106 * gdbthread.h (thread_control_state) <trap_expected> Update
2107 comments.
2108
2109 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2110
2111 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
2112 ada_language::lookup_symbol_nonlocal.
2113 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
2114 (ada_language::lookup_symbol_nonlocal): New member function,
2115 implementation from ada_lookup_symbol_nonlocal.
2116 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
2117 initializer.
2118 (cplus_language_data): Delete la_lookup_symbol_nonlocal
2119 initializer.
2120 (cplus_language::lookup_symbol_nonlocal): New member function.
2121 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
2122 (minimal_language_data) Likewise.
2123 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
2124 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
2125 initializer.
2126 (d_language::lookup_symbol_nonlocal): New member function.
2127 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
2128 initializer.
2129 (f_language::lookup_symbol_nonlocal): New member function.
2130 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
2131 initializer.
2132 * language.c (unknown_language_data): Likewise.
2133 (auto_language_data): Likewise.
2134 * language.h (language_data): Delete la_lookup_symbol_nonlocal
2135 field.
2136 (language_defn::lookup_symbol_nonlocal): New member function.
2137 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
2138 initializer.
2139 * objc-lang.c (objc_language_data): Likewise.
2140 * opencl-lang.c (opencl_language_data): Likewise.
2141 * p-lang.c (pascal_language_data): Likewise.
2142 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
2143 rust_language::lookup_symbol_nonlocal.
2144 (rust_language_data): Delete la_lookup_symbol_nonlocal
2145 initializer.
2146 (rust_language::lookup_symbol_nonlocal): New member function,
2147 implementation from rust_lookup_symbol_nonlocal.
2148 * symtab.c (lookup_symbol_aux): Update call to
2149 lookup_symbol_nonlocal.
2150 (basic_lookup_symbol_nonlocal): Rename to...
2151 (language_defn::lookup_symbol_nonlocal): ...this, and update
2152 header comment. Remove language_defn parameter, and replace with
2153 uses of `this'.
2154 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
2155
2156 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2157
2158 * ada-lang.c (ada_language_data): Delete la_value_print_inner
2159 initializer.
2160 (ada_language::value_print_inner): New member function.
2161 * c-lang.c (c_language_data): Delete la_value_print_inner
2162 initializer.
2163 (cplus_language_data): Likewise.
2164 (asm_language_data): Likewise.
2165 (minimal_language_data): Likewise.
2166 * d-lang.c (d_language_data): Likewise.
2167 (d_language::value_print_inner): New member function.
2168 * f-lang.c (f_language_data): Delete la_value_print_inner
2169 initializer.
2170 (f_language::value_print_inner): New member function.
2171 * f-lang.h (f_value_print_innner): Rename to...
2172 (f_value_print_inner): ...this (note spelling of 'inner').
2173 * f-valprint.c (f_value_print_innner): Rename to...
2174 (f_value_print_inner): ...this (note spelling of 'inner').
2175 * go-lang.c (go_language_data): Delete la_value_print_inner
2176 initializer.
2177 (go_language::value_print_inner): New member function.
2178 * language.c (language_defn::value_print_inner): Define new member
2179 function.
2180 (unk_lang_value_print_inner): Delete.
2181 (unknown_language_data): Delete la_value_print_inner initializer.
2182 (unknown_language::value_print_inner): New member function.
2183 (auto_language_data): Delete la_value_print_inner initializer.
2184 (auto_language::value_print_inner): New member function.
2185 * language.h (language_data): Delete la_value_print_inner field.
2186 (language_defn::value_print_inner): Delcare new member function.
2187 * m2-lang.c (m2_language_data): Delete la_value_print_inner
2188 initializer.
2189 (m2_language::value_print_inner): New member function.
2190 * objc-lang.c (objc_language_data): Delete la_value_print_inner
2191 initializer.
2192 * opencl-lang.c (opencl_language_data): Likewise.
2193 * p-lang.c (pascal_language_data): Likewise.
2194 (pascal_language::value_print_inner): New member function.
2195 * rust-lang.c (rust_language_data): Delete la_value_print_inner
2196 initializer.
2197 (rust_language::value_print_inner): New member function.
2198 * valprint.c (do_val_print): Update call to value_print_inner.
2199
2200 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2201
2202 * ada-lang.c (ada_language_data): Delete la_value_print
2203 initializer.
2204 (ada_language::value_print): New member function.
2205 * c-lang.c (c_language_data): Delete la_value_print initializer.
2206 (cplus_language_data): Likewise.
2207 (asm_language_data): Likewise.
2208 (minimal_language_data): Likewise.
2209 * d-lang.c (d_language_data): Likewise.
2210 * f-lang.c (f_language_data): Likewise.
2211 * go-lang.c (go_language_data): Likewise.
2212 * language.c (unk_lang_value_print): Delete.
2213 (language_defn::value_print): Define new member function.
2214 (unknown_language_data): Delete la_value_print initializer.
2215 (unknown_language::value_print): New member function.
2216 (auto_language_data): Delete la_value_print initializer.
2217 (auto_language::value_print): New member function.
2218 * language.h (language_data): Delete la_value_print field.
2219 (language_defn::value_print): Declare new member function.
2220 (LA_VALUE_PRINT): Update call to value_print.
2221 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
2222 * objc-lang.c (objc_language_data): Likewise.
2223 * opencl-lang.c (opencl_language_data): Likewise.
2224 * p-lang.c (pascal_language_data): Likewise.
2225 (pascal_language::value_print): New member function.
2226 * rust-lang.c (rust_language_data): Delete la_value_print
2227 initializer.
2228
2229 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2230
2231 * ada-lang.c (ada_watch_location_expression): Rename to
2232 ada_language::watch_location_expression.
2233 (ada_language_data): Delete la_watch_location_expression
2234 initializer.
2235 (ada_language::watch_location_expression): New member function,
2236 implementation from ada_watch_location_expression.
2237 * breakpoint.c (watch_command_1): Update call to
2238 watch_location_expression.
2239 * c-lang.c (c_watch_location_expression): Rename to
2240 language_defn::watch_location_expression.
2241 (c_language_data): Delete la_watch_location_expression
2242 initializer.
2243 (cplus_language_data): Likewise.
2244 (asm_language_data): Likewise.
2245 (minimal_language_data): Likewise.
2246 * c-lang.h (c_watch_location_expression): Delete declaration.
2247 * d-lang.c (d_language_data): Delete la_watch_location_expression
2248 initializer.
2249 * f-lang.c (f_language_data): Likewise.
2250 * go-lang.c (go_language_data): Likewise.
2251 * language.c (language_defn::watch_location_expression): Member
2252 function implementation from c_watch_location_expression.
2253 (unknown_language_data): Delete la_watch_location_expression
2254 initializer.
2255 (auto_language_data): Likewise.
2256 * language.h (language_data): Delete la_watch_location_expression
2257 field.
2258 (language_defn::watch_location_expression): Declare new member
2259 function.
2260 * m2-lang.c (m2_language_data): Delete
2261 la_watch_location_expression initializer.
2262 * objc-lang.c (objc_language_data): Likewise.
2263 * opencl-lang.c (opencl_language_data): Likewise.
2264 * p-lang.c (pascal_language_data): Likewise.
2265 * rust-lang.c (rust_watch_location_expression): Rename to
2266 rust_language::watch_location_expression.
2267 (rust_language_data): Delete la_watch_location_expression
2268 initializer.
2269 (rust_language::watch_location_expression): New member function,
2270 implementation from rust_watch_location_expression.
2271
2272 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2273
2274 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
2275 ada_language::collect_symbol_completion_matches.
2276 (ada_language_data): Delete la_collect_symbol_completion_matches
2277 initializer.
2278 (ada_language::collect_symbol_completion_matches): New member
2279 function, implementation from
2280 ada_collect_symbol_completion_matches.
2281 * c-lang.c (c_language_data): Delete
2282 la_collect_symbol_completion_matches initializer.
2283 (cplus_language_data): Likewise.
2284 (asm_language_data): Likewise.
2285 (minimal_language_data): Likewise.
2286 * d-lang.c (d_language_data): Likewise.
2287 * f-lang.c (f_collect_symbol_completion_matches): Rename to
2288 f_language::collect_symbol_completion_matches.
2289 (f_language_data): Delete la_collect_symbol_completion_matches
2290 initializer.
2291 (f_language::collect_symbol_completion_matches) New member
2292 function, implementation from f_collect_symbol_completion_matches.
2293 * go-lang.c (go_language_data): Delete
2294 la_collect_symbol_completion_matches initializer.
2295 * language.c (unknown_language_data): Likewise.
2296 (auto_language_data): Likewise.
2297 * language.h (language_data): Delete
2298 la_collect_symbol_completion_matches field.
2299 (language_defn::collect_symbol_completion_matches): New member
2300 function.
2301 * m2-lang.c (m2_language_data): Delete
2302 la_collect_symbol_completion_matches initializer.
2303 * objc-lang.c (objc_language_data): Likewise.
2304 * opencl-lang.c (opencl_language_data): Likewise.
2305 * p-lang.c (pascal_language_data): Likewise.
2306 * rust-lang.c (rust_language_data): Likewise.
2307 * symtab.c (default_collect_symbol_completion_matches): Delete.
2308 (collect_symbol_completion_matches): Update call to
2309 collect_symbol_completion_matches.
2310 (collect_symbol_completion_matches_type): Likewise.
2311 * symtab.h (default_collect_symbol_completion_matches): Delete
2312 declaration.
2313
2314 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2315
2316 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
2317 (ada_language_data): Delete la_word_break_characters initializer.
2318 (ada_language::word_break_characters): New member function.
2319 * c-lang.c (c_language_data): Delete la_word_break_characters
2320 initializer.
2321 (cplus_language_data): Likewise.
2322 (asm_language_data): Likewise.
2323 (minimal_language_data): Likewise.
2324 * completer.c: Update global comment.
2325 (advance_to_expression_complete_word_point): Update call to
2326 word_break_characters.
2327 (complete_files_symbols): Likewise.
2328 (complete_line_internal_1): Likewise.
2329 (default_completer_handle_brkchars): Likewise.
2330 (skip_quoted_chars): Likewise.
2331 * d-lang.c (d_language_data): Delete la_word_break_characters
2332 initializer.
2333 * f-lang.c (f_word_break_characters): Delete.
2334 (f_language_data): Delete la_word_break_characters initializer.
2335 (f_language::word_break_characters): New member function.
2336 * go-lang.c (go_language_data): Delete la_word_break_characters
2337 initializer.
2338 * language.c (unknown_language_data): Likewise.
2339 (auto_language_data): Likewise.
2340 * language.h (default_word_break_characters): Move declaration to
2341 earlier in the file.
2342 (language_data): Delete la_word_break_characters field.
2343 (language_defn::word_break_characters): New member function.
2344 * m2-lang.c (m2_language_data): Delete la_word_break_characters
2345 initializer.
2346 * objc-lang.c (objc_language_data): Likewise.
2347 * opencl-lang.c (opencl_language_data): Likewise.
2348 * p-lang.c (pascal_language_data): Likewise.
2349 * rust-lang.c (rust_language_data): Likewise.
2350
2351 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2352
2353 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
2354 (ada_language_data): Delete la_get_symbol_name_matcher
2355 initializer.
2356 (language_defn::get_symbol_name_matcher_inner): New member
2357 function.
2358 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
2359 initializer.
2360 (cplus_language_data): Likewise.
2361 (cplus_language::get_symbol_name_matcher_inner): New member
2362 function.
2363 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
2364 (minimal_language_data): Likewise.
2365 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
2366 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
2367 initializer.
2368 * dictionary.c (iter_match_first_hashed): Update call to
2369 get_symbol_name_matcher.
2370 (iter_match_next_hashed): Likewise.
2371 (iter_match_next_linear): Likewise.
2372 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
2373 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
2374 initializer.
2375 (f_language::get_symbol_name_matcher_inner): New member function.
2376 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
2377 initializer.
2378 * language.c (default_symbol_name_matcher): Update header comment,
2379 make static.
2380 (language_defn::get_symbol_name_matcher): New definition.
2381 (language_defn::get_symbol_name_matcher_inner): Likewise.
2382 (get_symbol_name_matcher): Delete.
2383 (unknown_language_data): Delete la_get_symbol_name_matcher
2384 initializer.
2385 (auto_language_data): Likewise.
2386 * language.h (language_data): Delete la_get_symbol_name_matcher
2387 field.
2388 (language_defn::get_symbol_name_matcher): New member function.
2389 (language_defn::get_symbol_name_matcher_inner): Likewise.
2390 (default_symbol_name_matcher): Delete declaration.
2391 * linespec.c (find_methods): Update call to
2392 get_symbol_name_matcher.
2393 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
2394 initializer.
2395 * minsyms.c (lookup_minimal_symbol): Update call to
2396 get_symbol_name_matcher.
2397 (iterate_over_minimal_symbols): Likewise.
2398 * objc-lang.c (objc_language_data): Delete
2399 la_get_symbol_name_matcher initializer.
2400 * opencl-lang.c (opencl_language_data): Likewise.
2401 * p-lang.c (pascal_language_data): Likewise.
2402 * psymtab.c (psymbol_name_matches): Update call to
2403 get_symbol_name_matcher.
2404 * rust-lang.c (rust_language_data): Delete
2405 la_get_symbol_name_matcher initializer.
2406 * symtab.c (symbol_matches_search_name): Update call to
2407 get_symbol_name_matcher.
2408 (compare_symbol_name): Likewise.
2409
2410 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2411
2412 * ada-lang.c (ada_language_data): Delete la_compute_program
2413 initializer.
2414 * c-lang.c (c_language_data): Likewise.
2415 (c_language::compute_program): New member function.
2416 (cplus_language_data): Delete la_compute_program initializer.
2417 (cplus_language::compute_program): New member function.
2418 (asm_language_data): Delete la_compute_program initializer.
2419 (minimal_language_data): Likewise.
2420 * c-lang.h (c_compute_program): Update comment.
2421 (cplus_compute_program): Likewise.
2422 * compile/compile-c-support.c (c_compute_program): Likewise.
2423 (cplus_compute_program): Likewise.
2424 * compile/compile.c (compile_to_object): Update call to
2425 la_compute_program.
2426 * d-lang.c (d_language_data): Delete la_compute_program
2427 initializer.
2428 * f-lang.c (f_language_data): Likewise.
2429 * go-lang.c (go_language_data): Likewise.
2430 * language.c (unknown_language_data): Likewise.
2431 (auto_language_data): Likewise.
2432 * language.h (language_data): Delete la_compute_program field.
2433 (language_defn::compute_program): New member function.
2434 * m2-lang.c (m2_language_data): Delete la_compute_program
2435 initializer.
2436 * objc-lang.c (objc_language_data): Likewise.
2437 * opencl-lang.c (opencl_language_data): Likewise.
2438 * p-lang.c (pascal_language_data): Likewise.
2439 * rust-lang.c (rust_language_data): Likewise.
2440
2441 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2442
2443 * ada-lang.c (ada_language_data) Delete
2444 la_class_name_from_physname initializer.
2445 * c-lang.c (c_language_data): Likewise.
2446 (cplus_language_data): Likewise.
2447 (cplus_language::class_name_from_physname): New member function.
2448 (asm_language_data): Delete la_class_name_from_physname
2449 initializer.
2450 (minimal_language_data): Likewise.
2451 * d-lang.c (d_language_data): Likewise.
2452 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
2453 method on language_defn class.
2454 (guess_full_die_structure_name): Likewise.
2455 * f-lang.c (f_language_data): Delete la_class_name_from_physname
2456 initializer.
2457 * go-lang.c (go_language_data): Likewise.
2458 * language.c (language_class_name_from_physname): Delete.
2459 (unk_lang_class_name): Delete.
2460 (unknown_language_data): Delete la_class_name_from_physname
2461 initializer.
2462 (auto_language_data): Likewise.
2463 * language.h (language_data): Delete la_class_name_from_physname
2464 field.
2465 (language_defn::class_name_from_physname): New function.
2466 (language_class_name_from_physname): Delete declaration.
2467 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
2468 initializer.
2469 * objc-lang.c (objc_language_data): Likewise.
2470 * opencl-lang.c (opencl_language_data): Likewise.
2471 * p-lang.c (pascal_language_data): Likewise.
2472 * rust-lang.c (rust_language_data): Likewise.
2473
2474 2020-06-16 Tom Tromey <tom@tromey.com>
2475
2476 * tui/tui-data.h (STATUS_NAME): New macro.
2477 * tui/tui-layout.c (tui_remove_some_windows)
2478 (initialize_known_windows, tui_register_window)
2479 (tui_layout_split::remove_windows, initialize_layouts)
2480 (tui_new_layout_command): Don't use hard-coded window names.
2481
2482 2020-06-16 Tom Tromey <tom@tromey.com>
2483
2484 PR tui/25348:
2485 * tui/tui.c (tui_ensure_readline_initialized): Rename from
2486 tui_initialize_readline. Only run once. Call rl_initialize.
2487 * tui/tui.h (tui_ensure_readline_initialized): Rename from
2488 tui_initialize_readline.
2489 * tui/tui-io.c (tui_setup_io): Call
2490 tui_ensure_readline_initialized.
2491 * tui/tui-interp.c (tui_interp::init): Update.
2492
2493 2020-06-16 Tom Tromey <tom@tromey.com>
2494
2495 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
2496 Also preserve the status window.
2497
2498 2020-06-16 Tom Tromey <tom@tromey.com>
2499
2500 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
2501 where m_window==nullptr.
2502
2503 2020-06-15 Tom Tromey <tromey@adacore.com>
2504
2505 * windows-nat.c (windows_nat::handle_output_debug_string):
2506 Update.
2507 (windows_nat::handle_ms_vc_exception): Update.
2508 * target.h (target_read_string): Change API.
2509 * target.c (target_read_string): Change API.
2510 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
2511 Update.
2512 * solib-frv.c (frv_current_sos): Update.
2513 * solib-dsbt.c (dsbt_current_sos): Update.
2514 * solib-darwin.c (darwin_current_sos): Update.
2515 * linux-thread-db.c (inferior_has_bug): Update.
2516 * expprint.c (print_subexp_standard): Update.
2517 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
2518 (ada_exception_message_1): Update.
2519
2520 2020-06-15 Tom Tromey <tromey@adacore.com>
2521
2522 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
2523
2524 2020-06-15 Tom Tromey <tromey@adacore.com>
2525
2526 * valprint.c (read_string): Update comment.
2527 * target.c (MIN): Remove.
2528 (target_read_string): Rewrite.
2529
2530 2020-06-15 Tom Tromey <tromey@adacore.com>
2531
2532 * corefile.c (read_memory_string): Remove.
2533 * ada-valprint.c (ada_value_print_ptr): Update.
2534 * ada-lang.h (ada_tag_name): Change return type.
2535 * ada-lang.c (type_from_tag): Update.
2536 (ada_tag_name_from_tsd): Change return type. Use
2537 target_read_string.
2538 (ada_tag_name): Likewise.
2539 * gdbcore.h (read_memory_string): Don't declare.
2540
2541 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
2542
2543 * symtab.c (rbreak_command): Ignore Windows drive colon.
2544
2545 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
2546
2547 * NEWS: Mention removed GDBserver host support.
2548
2549 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
2550
2551 * features/riscv/rebuild-csr-xml.sh: Updated.
2552
2553 2020-06-11 Tom Tromey <tom@tromey.com>
2554
2555 PR gdb/18318:
2556 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
2557
2558 2020-06-09 Jonny Grant <jg@jguk.org>
2559 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
2560
2561 * main.c (captured_main_1): Don't print new line after help.
2562 (print_gdb_help): add mailing list and IRC channel information
2563 to --help. Add new lines between items in the footer. Remove
2564 quotes around bug url.
2565
2566 2020-06-11 Keith Seitz <keiths@redhat.com>
2567
2568 PR gdb/21356
2569 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
2570 Resolve typedefs for type length calculations.
2571
2572 2020-06-10 Tom de Vries <tdevries@suse.de>
2573
2574 PR ada/24713
2575 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
2576 (write_psymbols): Enable .gdb_index for ada.
2577 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
2578 ada.
2579
2580 2020-06-10 Tom de Vries <tdevries@suse.de>
2581
2582 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
2583 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
2584 namei" instead of "const char *name" argument.
2585 (dw2_map_matching_symbols): Use "offset_type namei" variant of
2586 dw2_symtab_iter_init.
2587
2588 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2589
2590 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
2591 to use type::field and field::type instead.
2592
2593 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2594
2595 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
2596 to use field::type instead.
2597
2598 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2599
2600 * gdbtypes.h (struct field) <type, set_type>: New methods.
2601 Rename `type` field to...
2602 <m_type>: ... this. Change references throughout to use type or
2603 set_type methods.
2604 (FIELD_TYPE): Use field::type. Change call sites that modify
2605 the field's type to use field::set_type instead.
2606
2607 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2608
2609 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
2610 to use type::index_type instead.
2611
2612 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2613
2614 * gdbtypes.h (struct type) <index_type, set_index_type>: New
2615 methods.
2616 (TYPE_INDEX_TYPE): Use type::index_type.
2617 * gdbtypes.c (create_array_type_with_stride): Likewise.
2618
2619 2020-06-07 Tom Tromey <tom@tromey.com>
2620
2621 * valprint.c (generic_val_print_float): Remove "embedded_offset"
2622 parameter.
2623 (generic_value_print): Update.
2624
2625 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
2626
2627 Revert commit 982a38f60b0.
2628 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
2629
2630 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
2631
2632 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
2633 avoid use after free.
2634
2635 2020-06-05 Tom de Vries <tdevries@suse.de>
2636
2637 * NEWS: Fix typos.
2638
2639 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
2640
2641 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
2642 the per_bfd object.
2643 (dwarf2_read_debug_names): Likewise.
2644 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
2645 object when re-using a per_bfd object with an index.
2646
2647 2020-06-03 Tom de Vries <tdevries@suse.de>
2648
2649 PR symtab/26046
2650 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
2651 children for C++.
2652 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
2653 DW_TAG_subprogram.
2654
2655 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2656
2657 * ada-lang.c (ada_language_data): Delete skip_trampoline
2658 initializer.
2659 * c-lang.c (c_language_data): Likewise.
2660 (cplus_language_data): Likewise.
2661 (cplus_language::skip_trampoline): New member function.
2662 (asm_language_data): Delete skip_trampoline initializer.
2663 (minimal_language_data): Likewise.
2664 * d-lang.c (d_language_data): Likewise.
2665 * f-lang.c (f_language_data): Likewise.
2666 * go-lang.c (go_language_data): Likewise.
2667 * language.c (unk_lang_trampoline): Delete function.
2668 (skip_language_trampoline): Update.
2669 (unknown_language_data): Delete skip_trampoline initializer.
2670 (auto_language_data): Likewise.
2671 * language.h (language_data): Delete skip_trampoline field.
2672 (language_defn::skip_trampoline): New function.
2673 * m2-lang.c (m2_language_data): Delete skip_trampoline
2674 initializer.
2675 * objc-lang.c (objc_skip_trampoline): Delete function, move
2676 implementation to objc_language::skip_trampoline.
2677 (objc_language_data): Delete skip_trampoline initializer.
2678 (objc_language::skip_trampoline): New member function with
2679 implementation from objc_skip_trampoline.
2680 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
2681 initializer.
2682 * p-lang.c (pascal_language_data): Likewise.
2683 * rust-lang.c (rust_language_data): Likewise.
2684
2685 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2686
2687 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
2688 (ada_language::demangle): New member function.
2689 * c-lang.c (c_language_data): Delete la_demangle initializer.
2690 (cplus_language_data): Delete la_demangle initializer.
2691 (cplus_language::demangle): New member function.
2692 (asm_language_data): Delete la_demangle initializer.
2693 (minimal_language_data): Delete la_demangle initializer.
2694 * d-lang.c (d_language_data): Delete la_demangle initializer.
2695 (d_language::demangle): New member function.
2696 * f-lang.c (f_language_data): Delete la_demangle initializer.
2697 (f_language::demangle): New member function.
2698 * go-lang.c (go_language_data): Delete la_demangle initializer.
2699 (go_language::demangle): New member function.
2700 * language.c (language_demangle): Update.
2701 (unk_lang_demangle): Delete.
2702 (unknown_language_data): Delete la_demangle initializer.
2703 (unknown_language::demangle): New member function.
2704 (auto_language_data): Delete la_demangle initializer.
2705 (auto_language::demangle): New member function.
2706 * language.h (language_data): Delete la_demangle field.
2707 (language_defn::demangle): New function.
2708 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
2709 * objc-lang.c (objc_language_data): Delete la_demangle
2710 initializer.
2711 (objc_language::demangle): New member function.
2712 * opencl-lang.c (opencl_language_data): Delete la_demangle
2713 initializer.
2714 * p-lang.c (pascal_language_data): Likewise.
2715 * rust-lang.c (rust_language_data): Likewise.
2716 (rust_language::demangle): New member function.
2717
2718 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2719
2720 * ada-lang.c (ada_language_data): Delete la_print_type
2721 initializer.
2722 (ada_language::print_type): New member function.
2723 * c-lang.c (c_language_data): Delete la_print_type initializer.
2724 (c_language::print_type): New member function.
2725 (cplus_language_data): Delete la_print_type initializer.
2726 (cplus_language::print_type): New member function.
2727 (asm_language_data): Delete la_print_type initializer.
2728 (asm_language::print_type): New member function.
2729 (minimal_language_data): Delete la_print_type initializer.
2730 (minimal_language::print_type): New member function.
2731 * d-lang.c (d_language_data): Delete la_print_type initializer.
2732 (d_language::print_type): New member function.
2733 * f-lang.c (f_language_data): Delete la_print_type initializer.
2734 (f_language::print_type): New member function.
2735 * go-lang.c (go_language_data): Delete la_print_type initializer.
2736 (go_language::print_type): New member function.
2737 * language.c (unk_lang_print_type): Delete.
2738 (unknown_language_data): Delete la_print_type initializer.
2739 (unknown_language::print_type): New member function.
2740 (auto_language_data): Delete la_print_type initializer.
2741 (auto_language::print_type): New member function.
2742 * language.h (language_data): Delete la_print_type field.
2743 (language_defn::print_type): New function.
2744 (LA_PRINT_TYPE): Update.
2745 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
2746 (m2_language::print_type): New member function.
2747 * objc-lang.c (objc_language_data): Delete la_print_type
2748 initializer.
2749 (objc_language::print_type): New member function.
2750 * opencl-lang.c (opencl_print_type): Delete, implementation moved
2751 to opencl_language::print_type.
2752 (opencl_language_data): Delete la_print_type initializer.
2753 (opencl_language::print_type): New member function, implementation
2754 from opencl_print_type.
2755 * p-lang.c (pascal_language_data): Delete la_print_type
2756 initializer.
2757 (pascal_language::print_type): New member function.
2758 * rust-lang.c (rust_print_type): Delete, implementation moved to
2759 rust_language::print_type.
2760 (rust_language_data): Delete la_print_type initializer.
2761 (rust_language::print_type): New member function, implementation
2762 from rust_print_type.
2763
2764 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2765
2766 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
2767 implementation moves to...
2768 (ada_language::sniff_from_mangled_name): ...here. Update return
2769 type.
2770 (ada_language_data): Delete la_sniff_from_mangled_name
2771 initializer.
2772 * c-lang.c (c_language_data): Likewise.
2773 (cplus_language_data): Likewise.
2774 (cplus_language::sniff_from_mangled_name): New member function,
2775 implementation taken from gdb_sniff_from_mangled_name.
2776 (asm_language_data): Delete la_sniff_from_mangled_name
2777 initializer.
2778 (minimal_language_data): Likewise.
2779 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
2780 implementation moves to cplus_language::sniff_from_mangled_name.
2781 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
2782 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
2783 moves to...
2784 (d_language::sniff_from_mangled_name): ...here.
2785 (d_language_data): Delete la_sniff_from_mangled_name initializer.
2786 * f-lang.c (f_language_data): Likewise.
2787 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
2788 moves to...
2789 (go_language::sniff_from_mangled_name): ...here.
2790 (go_language_data): Delete la_sniff_from_mangled_name initializer.
2791 * language.c (language_sniff_from_mangled_name): Delete.
2792 (unknown_language_data): Delete la_sniff_from_mangled_name
2793 initializer.
2794 (auto_language_data): Likewise.
2795 * language.h (language_data): Delete la_sniff_from_mangled_name
2796 field.
2797 (language_defn::sniff_from_mangled_name): New function.
2798 (language_sniff_from_mangled_name): Delete declaration.
2799 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
2800 field.
2801 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
2802 implementation moves to...
2803 (objc_language::sniff_from_mangled_name): ...here.
2804 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
2805 * opencl-lang.c (opencl_language_data): Likewise.
2806 * p-lang.c (pascal_language_data): Likewise.
2807 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
2808 implementation moves to...
2809 (rust_language::sniff_from_mangled_name): ...here.
2810 (rust_language_data): Delete la_sniff_from_mangled_name
2811 initializer.
2812 * symtab.c (symbol_find_demangled_name): Call
2813 sniff_from_mangled_name member function.
2814
2815 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2816
2817 * ada-lang.c (ada_language_data): Delete la_search_name_hash
2818 initializer.
2819 * c-lang.c (c_language_data): Likewise.
2820 (cplus_language_data): Likewise.
2821 (cplus_language::search_name_hash): New member function.
2822 (asm_language_data): Delete la_search_name_hash initializer.
2823 (minimal_language_data): Likewise.
2824 * d-lang.c (d_language_data): Likewise.
2825 * dictionary.c (default_search_name_hash): Rename to...
2826 (language_defn::search_name_hash): ...this.
2827 * f-lang.c (f_language_data): Likewise.
2828 (f_language::search_name_hash): New member function.
2829 * go-lang.c (go_language_data): Delete la_search_name_hash
2830 initializer.
2831 * language.c (unknown_language_data): Likewise.
2832 (auto_language_data): Likewise.
2833 * language.h (struct language_data): Delete la_search_name_hash
2834 field.
2835 (language_defn::search_name_hash): Declare new member function.
2836 (default_search_name_hash): Delete declaration.
2837 * m2-lang.c (m2_language_data): Delete la_search_name_hash
2838 initializer.
2839 * objc-lang.c (objc_language_data): Likewise.
2840 * opencl-lang.c (opencl_language_data): Likewise.
2841 * p-lang.c (pascal_language_data): Likewise.
2842 * rust-lang.c (rust_language_data): Likewise.
2843 * symtab.c (search_name_hash): Update call.
2844
2845 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2846
2847 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
2848 initializer.
2849 * c-lang.c (class compile_instance): Declare.
2850 (c_language_data): Delete la_get_compile_instance initializer.
2851 (c_language::get_compile_instance): New member function.
2852 (cplus_language_data): Delete la_get_compile_instance initializer.
2853 (cplus_language::get_compile_instance): New member function.
2854 (asm_language_data): Delete la_get_compile_instance initializer.
2855 (minimal_language_data): Likewise.
2856 * c-lang.h (c_get_compile_context): Update comment.
2857 (cplus_get_compile_context): Update comment.
2858 * compile/compile.c (compile_to_object): Update calls, don't rely
2859 on function pointer being NULL.
2860 * d-lang.c (d_language_data): Delete la_get_compile_instance
2861 initializer.
2862 * f-lang.c (f_language_data): Likewise.
2863 * go-lang.c (go_language_data): Likewise.
2864 * language.c (unknown_language_data): Likewise.
2865 (auto_language_data): Likewise.
2866 * language.h (language_data): Delete la_get_compile_instance field.
2867 (language_defn::get_compile_instance): New member function.
2868 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
2869 initializer.
2870 * objc-lang.c (objc_language_data): Likewise.
2871 * opencl-lang.c (opencl_language_data): Likewise.
2872 * p-lang.c (pascal_language_data): Likewise.
2873 * rust-lang.c (rust_language_data): Likewise.
2874
2875 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2876
2877 * ada-lang.c (ada_add_all_symbols): Update comment.
2878 (ada_iterate_over_symbols): Delete, move implementation to...
2879 (ada_language::iterate_over_symbols): ...here, a new member
2880 function, rewrite to use range based for loop.
2881 (ada_language_data): Delete la_iterate_over_symbols initializer.
2882 * c-lang.c (c_language_data): Likewise.
2883 (cplus_language_data): Likewise.
2884 (asm_language_data): Likewise.
2885 (minimal_language_data): Likewise.
2886 * d-lang.c (d_language_data): Likewise.
2887 * f-lang.c (f_language_data): Likewise.
2888 * go-lang.c (go_language_data): Likewise.
2889 * language.c (unknown_language_data): Likewise.
2890 (auto_language_data): Likewise.
2891 * language.h (language_data): Delete la_iterate_over_symbols field.
2892 (language_defn::iterate_over_symbols): New member function.
2893 (LA_ITERATE_OVER_SYMBOLS): Update.
2894 * linespec.c (iterate_over_all_matching_symtabs): Update.
2895 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
2896 initializer.
2897 * objc-lang.c (objc_language_data): Likewise.
2898 * opencl-lang.c (opencl_language_data): Likewise.
2899 * p-lang.c (pascal_language_data): Likewise.
2900 * rust-lang.c (rust_language_data): Likewise.
2901
2902 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2903
2904 * ada-lang.c (ada_language_data): Delete
2905 la_lookup_transparent_type initializer.
2906 * c-lang.c (c_language_data): Likewise.
2907 (cplus_language_data): Likewise.
2908 (cplus_language::lookup_transparent_type): New member function.
2909 (asm_language_data): Delete la_lookup_transparent_type
2910 initializer.
2911 (minimal_language_data): Likewise.
2912 * d-lang.c (d_language_data): Likewise.
2913 * f-lang.c (f_language_data): Likewise.
2914 * go-lang.c (go_language_data): Likewise.
2915 * language.c (unknown_language_data): Likewise.
2916 (auto_language_data): Likewise.
2917 * language.h (struct language_data): Delete
2918 la_lookup_transparent_type field.
2919 (language_defn::lookup_transparent_type): New member function.
2920 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
2921 initializer.
2922 * objc-lang.c (objc_language_data): Likewise.
2923 * opencl-lang.c (opencl_language_data): Likewise.
2924 * p-lang.c (pascal_language_data): Likewise.
2925 * rust-lang.c (rust_language_data): Likewise.
2926 * symtab.c (symbol_matches_domain): Update call.
2927
2928 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2929
2930 * ada-lang.c (ada_language_arch_info): Delete function, move
2931 implementation to...
2932 (ada_language::language_arch_info): ...here, a new member
2933 function.
2934 (ada_language_data): Delete la_language_arch_info.
2935 * c-lang.c (c_language_data): Likewise.
2936 (c_language::language_arch_info): New member function.
2937 (cplus_language_arch_info): Delete function, move
2938 implementation to...
2939 (cplus_language::language_arch_info): ...here, a new member
2940 function.
2941 (cplus_language_data): Delete la_language_arch_info.
2942 (asm_language_data): Likewise.
2943 (asm_language::language_arch_info): New member function.
2944 (minimal_language_data): Delete la_language_arch_info.
2945 (minimal_language::language_arch_info): New member function.
2946 * d-lang.c (d_language_arch_info): Delete function, move
2947 implementation to...
2948 (d_language::language_arch_info): ...here, a new member
2949 function.
2950 (d_language_data): Delete la_language_arch_info.
2951 * f-lang.c (f_language_arch_info): Delete function, move
2952 implementation to...
2953 (f_language::language_arch_info): ...here, a new member
2954 function.
2955 (f_language_data): Delete la_language_arch_info.
2956 * go-lang.c (go_language_arch_info): Delete function, move
2957 implementation to...
2958 (go_language::language_arch_info): ...here, a new member
2959 function.
2960 (go_language_data): Delete la_language_arch_info.
2961 * language.c (unknown_language_data): Likewise.
2962 (unknown_language::language_arch_info): New member function.
2963 (auto_language_data): Delete la_language_arch_info.
2964 (auto_language::language_arch_info): New member function.
2965 (language_gdbarch_post_init): Update call to
2966 la_language_arch_info.
2967 * language.h (language_data): Delete la_language_arch_info
2968 function pointer.
2969 (language_defn::language_arch_info): New function.
2970 * m2-lang.c (m2_language_arch_info): Delete function, move
2971 implementation to...
2972 (m2_language::language_arch_info): ...here, a new member
2973 function.
2974 (m2_language_data): Delete la_language_arch_info.
2975 * objc-lang.c (objc_language_arch_info): Delete function, move
2976 implementation to...
2977 (objc_language::language_arch_info): ...here, a new member
2978 function.
2979 (objc_language_data): Delete la_language_arch_info.
2980 * opencl-lang.c (opencl_language_arch_info): Delete function, move
2981 implementation to...
2982 (opencl_language::language_arch_info): ...here, a new member
2983 function.
2984 (opencl_language_data): Delete la_language_arch_info.
2985 * p-lang.c (pascal_language_arch_info): Delete function, move
2986 implementation to...
2987 (pascal_language::language_arch_info): ...here, a new member
2988 function.
2989 (pascal_language_data): Delete la_language_arch_info.
2990 * rust-lang.c (rust_language_arch_info): Delete function, move
2991 implementation to...
2992 (rust_language::language_arch_info): ...here, a new member
2993 function.
2994 (rust_language_data): Delete la_language_arch_info.
2995
2996 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2997
2998 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
2999 initializer.
3000 * c-lang.c (c_language_data): Likewise.
3001 (cplus_language_data): Likewise.
3002 (cplus_language::pass_by_reference_info): New method.
3003 (asm_language_data): Delete la_pass_by_reference initializer.
3004 (minimal_language_data): Likewise.
3005 * cp-abi.c (cp_pass_by_reference): Remove use of
3006 default_pass_by_reference.
3007 * d-lang.c (d_language_data): Likewise.
3008 * f-lang.c (f_language_data): Likewise.
3009 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
3010 default_pass_by_reference.
3011 * go-lang.c (go_language_data): Likewise.
3012 * language.c (language_pass_by_reference): Update.
3013 (default_pass_by_reference): Delete.
3014 (unknown_language_data): Delete la_pass_by_reference
3015 initializer.
3016 (auto_language_data): Likewise.
3017 * language.h (struct language_data): Delete la_pass_by_reference
3018 field.
3019 (language_defn::pass_by_reference_info): New member function.
3020 (default_pass_by_reference): Delete declaration.
3021 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
3022 initializer.
3023 * objc-lang.c (objc_language_data): Likewise.
3024 * opencl-lang.c (opencl_language_data): Likewise.
3025 * p-lang.c (pascal_language_data): Likewise.
3026 * rust-lang.c (rust_language_data): Likewise.
3027
3028 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3029
3030 * ada-lang.c (ada_read_var_value): Delete function, move
3031 implementation to...
3032 (ada_language::read_var_value): ...here.
3033 (ada_language_data): Delete la_read_var_value initializer.
3034 * c-lang.c (c_language_data): Likewise.
3035 (cplus_language_data): Likewise.
3036 (minimal_language_data): Likewise.
3037 * d-lang.c (d_language_data): Likewise.
3038 * f-lang.c (f_language_data): Likewise.
3039 * findvar.c (default_read_var_value): Rename to...
3040 (language_defn::read_var_value): ...this.
3041 * findvar.c (read_var_value): Update header comment, and change to
3042 call member function instead of function pointer.
3043 * go-lang.c (go_language_data): Likewise.
3044 * language.c (unknown_language_data): Delete la_read_var_value
3045 initializer.
3046 (auto_language_data): Likewise.
3047 * language.h (struct language_data): Delete la_read_var_value
3048 field.
3049 (language_defn::read_var_value): New member function.
3050 (default_read_var_value): Delete declaration.
3051 * m2-lang.c (m2_language_data): Delete la_read_var_value
3052 initializer.
3053 * objc-lang.c (objc_language_data): Likewise.
3054 * opencl-lang.c (opencl_language_data): Likewise.
3055 * p-lang.c (pascal_language_data): Likewise.
3056 * rust-lang.c (rust_language_data): Likewise.
3057 * value.h (default_read_var_value): Delete declaration.
3058
3059 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3060
3061 * ada-lang.c (ada_print_array_index): Delete function, move
3062 implementation to...
3063 (ada_language::print_array_index): ...here.
3064 (ada_language_data): Delete la_print_array_index initializer.
3065 * c-lang.c (c_language_data): Likewise.
3066 (cplus_language_data): Likewise.
3067 (minimal_language_data): Likewise.
3068 * d-lang.c (d_language_data): Likewise.
3069 * f-lang.c (f_language_data): Likewise.
3070 * go-lang.c (go_language_data): Likewise.
3071 * language.c (default_print_array_index): Delete function, move
3072 implementation to...
3073 (language_defn::print_array_index): ...here.
3074 (unknown_language_data): Delete la_print_array_index initializer.
3075 (auto_language_data): Likewise.
3076 * language.h (struct language_data): Delete la_print_array_index
3077 field.
3078 (language_defn::print_array_index): New member function.
3079 (LA_PRINT_ARRAY_INDEX): Update.
3080 (default_print_array_index): Delete declaration.
3081 * m2-lang.c (m2_language_data): Delete la_print_array_index
3082 initializer.
3083 * objc-lang.c (objc_language_data): Likewise.
3084 * opencl-lang.c (opencl_language_data): Likewise.
3085 * p-lang.c (pascal_language_data): Likewise.
3086 * rust-lang.c (rust_language_data): Likewise.
3087
3088 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3089
3090 * gdb/ada-lang.c (ada_language_defn): Convert to...
3091 (ada_language_data): ...this.
3092 (class ada_language): New class.
3093 (ada_language_defn): New static global.
3094 * gdb/c-lang.c (c_language_defn): Convert to...
3095 (c_language_data): ...this.
3096 (class c_language): New class.
3097 (c_language_defn): New static global.
3098 (cplus_language_defn): Convert to...
3099 (cplus_language_data): ...this.
3100 (class cplus_language): New class.
3101 (cplus_language_defn): New static global.
3102 (asm_language_defn): Convert to...
3103 (asm_language_data): ...this.
3104 (class asm_language): New class.
3105 (asm_language_defn): New static global.
3106 (minimal_language_defn): Convert to...
3107 (minimal_language_data): ...this.
3108 (class minimal_language): New class.
3109 (minimal_language_defn): New static global.
3110 * gdb/d-lang.c (d_language_defn): Convert to...
3111 (d_language_data): ...this.
3112 (class d_language): New class.
3113 (d_language_defn): New static global.
3114 * gdb/f-lang.c (f_language_defn): Convert to...
3115 (f_language_data): ...this.
3116 (class f_language): New class.
3117 (f_language_defn): New static global.
3118 * gdb/go-lang.c (go_language_defn): Convert to...
3119 (go_language_data): ...this.
3120 (class go_language): New class.
3121 (go_language_defn): New static global.
3122 * gdb/language.c (unknown_language_defn): Remove declaration.
3123 (current_language): Initialize to nullptr, real initialization is
3124 moved to _initialize_language.
3125 (languages): Delete global.
3126 (language_defn::languages): Define.
3127 (set_language_command): Use language_defn::languages.
3128 (set_language): Likewise.
3129 (range_error): Likewise.
3130 (language_enum): Likewise.
3131 (language_def): Likewise.
3132 (add_set_language_command): Use language_def::languages for the
3133 language list, and language_def to lookup language pointers.
3134 (skip_language_trampoline): Use language_defn::languages.
3135 (unknown_language_defn): Convert to...
3136 (unknown_language_data): ...this.
3137 (class unknown_language): New class.
3138 (unknown_language_defn): New static global.
3139 (auto_language_defn): Convert to...
3140 (auto_language_data): ...this.
3141 (class auto_language): New class.
3142 (auto_language_defn): New static global.
3143 (language_gdbarch_post_init): Use language_defn::languages.
3144 (_initialize_language): Initialize current_language.
3145 * gdb/language.h (struct language_defn): Rename to...
3146 (struct language_data): ...this.
3147 (struct language_defn): New.
3148 (auto_language_defn): Delete.
3149 (unknown_language_defn): Delete.
3150 (minimal_language_defn): Delete.
3151 (ada_language_defn): Delete.
3152 (asm_language_defn): Delete.
3153 (c_language_defn): Delete.
3154 (cplus_language_defn): Delete.
3155 (d_language_defn): Delete.
3156 (f_language_defn): Delete.
3157 (go_language_defn): Delete.
3158 (m2_language_defn): Delete.
3159 (objc_language_defn): Delete.
3160 (opencl_language_defn): Delete.
3161 (pascal_language_defn): Delete.
3162 (rust_language_defn): Delete.
3163 * gdb/m2-lang.c (m2_language_defn): Convert to...
3164 (m2_language_data): ...this.
3165 (class m2_language): New class.
3166 (m2_language_defn): New static global.
3167 * gdb/objc-lang.c (objc_language_defn): Convert to...
3168 (objc_language_data): ...this.
3169 (class objc_language): New class.
3170 (objc_language_defn): New static global.
3171 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
3172 (opencl_language_data): ...this.
3173 (class opencl_language): New class.
3174 (opencl_language_defn): New static global.
3175 * gdb/p-lang.c (pascal_language_defn): Convert to...
3176 (pascal_language_data): ...this.
3177 (class pascal_language): New class.
3178 (pascal_language_defn): New static global.
3179 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
3180 language pointer, update comment format.
3181 * gdb/rust-lang.c (rust_language_defn): Convert to...
3182 (rust_language_data): ...this.
3183 (class rust_language): New class.
3184 (rust_language_defn): New static global.
3185
3186 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
3187
3188 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
3189 member variable.
3190 <m_stmt_at_address>: New member variable.
3191 (lnp_state_machine::record_line): Don't record some lines, update
3192 tracking of is_stmt at the same address.
3193 (lnp_state_machine::lnp_state_machine): Initialise new member
3194 variables.
3195
3196 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
3197
3198 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
3199 "-include gnu-nat-mig.h".
3200 * gnu-nat-mig.h: New file.
3201 * gnu-nat.c: Include "gnu-nat-mig.h".
3202 (exc_server, msg_reply_server, notify_server,
3203 process_reply_server): Remove declarations.
3204
3205 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3206
3207 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
3208 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
3209 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
3210 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
3211 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
3212 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
3213 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
3214 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
3215 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
3216 to gnu_nat_target class.
3217 * gnu-nat.c: Likewise.
3218 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
3219 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
3220 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
3221 object.
3222 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
3223 instead of `gnu_target'.
3224
3225 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3226
3227 * i386-gnu-tdep.c: Include "gdbcore.h"
3228 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
3229 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
3230 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
3231 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
3232 i386_gnu_sigcontext_addr): New functions
3233 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
3234 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
3235 tdep.
3236
3237 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3238
3239 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
3240 before fork_inferior call. Avoid calling it if target_is_pushed returns
3241 true.
3242
3243 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3244
3245 * gnu-nat.h (gnu_target): New variable declaration.
3246 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
3247 gnu_target.
3248 * gnu-nat.c (gnu_target): New variable.
3249 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
3250 add_thread_silent, and add_thread calls.
3251 (gnu_nat_target::create_inferior): Pass gnu_target to
3252 add_thread_silent, thread_change_ptid call.
3253 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
3254 call.
3255
3256 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3257
3258 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
3259 (gnu_nat_target::find_memory_regions): Remove unused
3260 `old_address' variable.
3261
3262 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3263
3264 * gnu-nat.c: Include "gdbarch.h".
3265
3266 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3267
3268 * reply_mig_hack.awk (Error return): Cast function through
3269 void *, to bypass compiler function call check.
3270
3271 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3272
3273 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
3274 $(srcdir)/reply_mig_hack.awk.
3275
3276 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3277
3278 * gnu-nat.h (gnu_debug_flag): Set type to bool.
3279
3280 2020-05-30 Jonny Grant <jg@jguk.org>
3281
3282 * configure.ac (ACX_BUGURL): change bug URL to https.
3283
3284 2020-05-30 Pedro Alves <palves@redhat.com>
3285
3286 * cp-support.c (replace_typedefs_template): New.
3287 (replace_typedefs_qualified_name): Handle
3288 DEMANGLE_COMPONENT_TEMPLATE.
3289
3290 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
3291
3292 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
3293 dwarf2/index-cache.h, dwarf2/index-write.c,
3294 dwarf2/index-write.h, dwarf2/line-header.c,
3295 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
3296 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
3297 variables and fields from `dwarf2_per_objfile` to just
3298 `per_objfile` throughout.
3299
3300 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
3301
3302 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3303 <push_dwarf_reg_entry_value>: Add comment.
3304
3305 2020-05-28 Kevin Buettner <kevinb@redhat.com>
3306 Keith Seitz <keiths@redhat.com>
3307
3308 * python/python.c (do_start_initialization): Call PyEval_SaveThread
3309 instead of PyEval_ReleaseLock.
3310 (class gdbpy_gil): Move to earlier in file.
3311 (finalize_python): Set gdb_python_initialized.
3312 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
3313 when not initialized.
3314
3315 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
3316
3317 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3318 <push_dwarf_reg_entry_value>: Remove assert. Override
3319 per_objfile with caller_per_objfile.
3320
3321 2020-05-28 Tom de Vries <tdevries@suse.de>
3322
3323 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
3324 PR gold/15646 workaround to symbol kind "type".
3325
3326 2020-05-27 Tom Tromey <tromey@adacore.com>
3327
3328 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
3329
3330 2020-05-27 Tom Tromey <tromey@adacore.com>
3331
3332 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
3333 Use htab_find_with_hash.
3334 <add_abbrev>: Remove "abbrev_number" parameter.
3335 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
3336 "abbrev_number" parameter. Use htab_find_slot_with_hash.
3337 (hash_abbrev): Add comment.
3338 (abbrev_table::lookup_abbrev): Move to header file.
3339 (abbrev_table::read): Update.
3340
3341 2020-05-27 Tom Tromey <tromey@adacore.com>
3342
3343 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
3344 method.
3345 <canonical_name>: New member.
3346 <raw_name>: Rename from "name".
3347 (partial_die_info): Initialize canonical_name.
3348 (scan_partial_symbols): Check raw_name.
3349 (partial_die_parent_scope, partial_die_full_name)
3350 (add_partial_symbol, add_partial_subprogram)
3351 (add_partial_enumeration, load_partial_dies): Use "name" method.
3352 (partial_die_info::name): New method.
3353 (partial_die_info::read, guess_partial_die_structure_name)
3354 (partial_die_info::fixup): Update.
3355
3356 2020-05-27 Tom Tromey <tromey@adacore.com>
3357
3358 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
3359 <get_ref_die_offset>: Inline.
3360 <get_ref_die_offset_complaint>: New method.
3361 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
3362 (attribute::get_ref_die_offset_complaint): Rename from
3363 get_ref_die_offset. Just issue complaint.
3364
3365 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3366
3367 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
3368
3369 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3370
3371 * exec.c (exec_file_attach): Use errno value of first openp failure.
3372
3373 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3374
3375 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
3376 Don't close thread handle.
3377
3378 2020-05-27 Tom Tromey <tom@tromey.com>
3379 Simon Marchi <simon.marchi@efficios.com>
3380
3381 * objfiles.h (struct objfile) <partial_symtabs>: Now a
3382 shared_ptr.
3383 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
3384 member.
3385 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
3386 dwarf2_per_bfd_objfile_data_key>: New globals.
3387 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
3388 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
3389 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
3390 shared.
3391 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
3392 short-circuit when sharing.
3393 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
3394 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
3395
3396 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3397
3398 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
3399 to...
3400 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
3401 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
3402
3403 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3404
3405 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
3406 build_name_components, find_name_components_bounds>:
3407 Add per_objfile parameter.
3408 (struct mapped_index) <symbol_name_at>: Likewise.
3409 (struct mapped_debug_names): Remove constructor.
3410 <dwarf2_per_objfile>: Remove field.
3411 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
3412 (mapped_index_base::find_name_components_bounds,
3413 mapped_index_base::build_name_components,
3414 dw2_expand_symtabs_matching_symbol): Likewise.
3415 (class mock_mapped_index) <symbol_name_at>: Likewise.
3416 (check_match): Likewise.
3417 (check_find_bounds_finds): Likewise.
3418 (test_mapped_index_find_name_component_bounds): Update.
3419 (CHECK_MATCH): Update.
3420 (dw2_expand_symtabs_matching): Update.
3421 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
3422 per_objfile parameter.
3423 <find_vec_in_debug_names>: Likewise.
3424 <m_per_objfile>: New field.
3425 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
3426 parameter.
3427 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
3428 (dw2_debug_names_iterator::next): Update.
3429 (dw2_debug_names_lookup_symbol): Update.
3430 (dw2_debug_names_expand_symtabs_for_function): Update.
3431 (dw2_debug_names_map_matching_symbols): Update.
3432 (dw2_debug_names_expand_symtabs_matching): Update.
3433 (dwarf2_read_debug_names): Update.
3434
3435 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3436
3437 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
3438 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
3439 move to dwarf2_per_objfile.
3440 <read_in_chain>: Remove.
3441 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
3442 remove_all_cus, age_comp_units>: New methods.
3443 <m_dwarf2_cus>: New member.
3444 (struct dwarf2_per_cu_data) <cu>: Remove.
3445 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
3446 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
3447 moved to methods of dwarf2_per_objfile.
3448 (dwarf2_clear_marks): Remove.
3449 (dwarf2_queue_item::~dwarf2_queue_item): Update.
3450 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
3451 (dwarf2_per_bfd::free_cached_comp_units): Remove.
3452 (dwarf2_per_objfile::remove_all_cus): New.
3453 (class free_cached_comp_units) <~free_cached_comp_units>:
3454 Update.
3455 (load_cu): Update.
3456 (dw2_do_instantiate_symtab): Adjust.
3457 (fill_in_sig_entry_from_dwo_entry): Adjust.
3458 (cutu_reader::init_tu_and_read_dwo_dies): Update.
3459 (cutu_reader::cutu_reader): Likewise.
3460 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
3461 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
3462 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
3463 and dwarf2_per_objfile::age_comp_units.
3464 (load_partial_comp_unit): Update.
3465 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
3466 (process_queue): Likewise.
3467 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
3468 backlink.
3469 (dwarf2_read_addr_index): Likewise.
3470 (follow_die_offset): Likewise.
3471 (dwarf2_fetch_die_loc_sect_off): Likewise.
3472 (dwarf2_fetch_constant_bytes): Likewise.
3473 (dwarf2_fetch_die_type_sect_off): Likewise.
3474 (follow_die_sig_1): Likewise.
3475 (load_full_type_unit): Likewise.
3476 (read_signatured_type): Likewise.
3477 (dwarf2_cu::dwarf2_cu): Don't set cu field.
3478 (dwarf2_cu::~dwarf2_cu): Remove.
3479 (dwarf2_per_objfile::get_cu): New.
3480 (dwarf2_per_objfile::set_cu): New.
3481 (age_cached_comp_units): Rename to...
3482 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
3483 to std::unordered_map.
3484 (free_one_cached_comp_unit): Rename to...
3485 (dwarf2_per_objfile::remove_cu): ... this. Adjust
3486 to std::unordered_map.
3487 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
3488 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
3489 a dwarf2_per_objfile in data.
3490 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
3491 (dwarf2_clear_marks): Remove.
3492
3493 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3494
3495 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
3496 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
3497 (init_tu_and_read_dwo_dies): Likewise.
3498 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
3499 (cutu_reader::cutu_reader): Likewise.
3500 (load_partial_comp_unit): Likewise.
3501 (process_psymtab_comp_unit): Update.
3502 (build_type_psymtabs_1): Update.
3503 (process_skeletonless_type_unit): Update.
3504 (load_full_comp_unit): Update.
3505 (find_partial_die): Update.
3506 (dwarf2_read_addr_index): Update.
3507 (read_signatured_type): Update.
3508
3509 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3510
3511 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
3512 m_header_read_in>: New fields.
3513 <get_header>: New method.
3514 * dwarf2/read.c (per_cu_header_read_in): Remove.
3515 (dwarf2_per_cu_data::get_header): New.
3516 (dwarf2_per_cu_data::addr_size): Update.
3517 (dwarf2_per_cu_data::offset_size): Update.
3518 (dwarf2_per_cu_data::ref_addr_size): Update.
3519
3520 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3521
3522 * dwarf2/read.c (load_cu): Return dwarf2_cu.
3523 (dw2_do_instantiate_symtab): Update.
3524 (queue_and_load_all_dwo_tus): Change parameter from
3525 dwarf2_per_cu_data to dwarf2_cu.
3526 (dwarf2_fetch_die_loc_sect_off): Update.
3527 (dwarf2_fetch_constant_bytes): Update.
3528 (dwarf2_fetch_die_type_sect_off): Update.
3529
3530 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3531
3532 * dwarf2/read.c (process_full_comp_unit,
3533 process_full_type_unit): Remove per_cu, per_objfile paramters.
3534 Add dwarf2_cu parameter.
3535 (process_queue): Update.
3536
3537 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3538
3539 * dwarf2/read.c (create_cu_from_index_list): Replace
3540 dwarf2_per_objfile parameter with dwarf2_per_bfd.
3541 (create_cus_from_index_list): Likewise.
3542 (create_cus_from_index): Likewise.
3543 (create_signatured_type_table_from_index): Likewise.
3544 (create_cus_from_debug_names_list): Likewise.
3545 (create_cus_from_debug_names): Likewise.
3546 (dwarf2_read_gdb_index): Update.
3547 (dwarf2_read_debug_names): Update.
3548
3549 2020-05-27 Tom Tromey <tom@tromey.com>
3550 Simon Marchi <simon.marchi@efficios.com>
3551
3552 * dwarf2/read.h (struct dwarf2_per_objfile)
3553 <get_type_for_signatured_type, set_type_for_signatured_type>:
3554 New methods.
3555 <m_type_map>: New member.
3556 (struct signatured_type) <type>: Remove.
3557 * dwarf2/read.c
3558 (dwarf2_per_objfile::get_type_for_signatured_type,
3559 dwarf2_per_objfile::set_type_for_signatured_type): New.
3560 (get_signatured_type): Use new methods.
3561
3562 2020-05-27 Tom Tromey <tom@tromey.com>
3563 Simon Marchi <simon.marchi@efficios.com>
3564
3565 * dwarf2/read.h (struct type_unit_group_unshareable): New.
3566 (struct dwarf2_per_objfile) <type_units>: New member.
3567 <get_type_unit_group_unshareable>: New method.
3568 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
3569 num_symtabs, symtabs>: Remove; move to
3570 type_unit_group_unshareable.
3571 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
3572 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
3573 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
3574
3575 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3576
3577 * dwarf2/read.h (struct dwarf2_per_cu_data):
3578 <dwarf2_per_objfile>: Remove.
3579 * dwarf2/read.c (create_cu_from_index_list): Don't assign
3580 dwarf2_per_objfile.
3581 (create_signatured_type_table_from_index): Likewise.
3582 (create_signatured_type_table_from_debug_names): Likewise.
3583 (create_debug_type_hash_table): Likewise.
3584 (fill_in_sig_entry_from_dwo_entry): Likewise.
3585 (create_type_unit_group): Likewise.
3586 (read_comp_units_from_section): Likewise.
3587 (create_cus_hash_table): Likewise.
3588
3589 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3590
3591 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
3592 dwarf2_per_cu_data::dwarf2_per_objfile.
3593 (compute_compunit_symtab_includes): Likewise.
3594 (dwarf2_cu::start_symtab): Likewise.
3595
3596 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3597
3598 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
3599 parameter.
3600 * dwarf2/read.c (get_die_type_at_offset): Likewise.
3601 (read_namespace_alias): Update.
3602 (lookup_die_type): Update.
3603 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
3604 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
3605 Update.
3606 (disassemble_dwarf_expression): Update.
3607
3608 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3609
3610 * dwarf2/read.h (struct dwarf2_queue_item): Add
3611 dwarf2_per_objfile parameter, assign new parameter.
3612 <per_objfile>: New field.
3613 * dwarf2/read.c (free_one_cached_comp_unit): Add
3614 dwarf2_per_objfile parameter.
3615 (queue_comp_unit): Likewise.
3616 (dw2_do_instantiate_symtab): Update.
3617 (process_psymtab_comp_unit): Update.
3618 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
3619 (process_imported_unit_die): Update.
3620 (queue_and_load_dwo_tu): Update.
3621 (follow_die_offset): Update.
3622 (follow_die_sig_1): Update.
3623
3624 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3625
3626 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
3627 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
3628 (read_call_site_scope): Assign per_objfile.
3629 (dwarf2_per_cu_data::objfile): Remove.
3630 * gdbtypes.h (struct call_site) <per_objfile>: New member.
3631 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
3632 dwarf2_per_objfile parameter.
3633 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
3634 dwarf2_per_objfile parameter.
3635 (dwarf_expr_reg_to_entry_parameter): Add output
3636 dwarf2_per_objfile parameter.
3637 (locexpr_get_frame_base): Update.
3638 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
3639 <push_dwarf_reg_entry_value>: Update.
3640 <call_site_to_target_addr>: Update.
3641 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
3642 parameter.
3643 (value_of_dwarf_reg_entry): Update.
3644 (rw_pieced_value): Update.
3645 (indirect_synthetic_pointer): Update.
3646 (dwarf2_evaluate_property): Update.
3647 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
3648 parameter.
3649 (locexpr_read_variable): Update.
3650 (locexpr_get_symbol_read_needs): Update.
3651 (loclist_read_variable): Update.
3652
3653 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3654
3655 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
3656 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
3657 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
3658 parameter.
3659 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
3660 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
3661 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
3662 parameter.
3663 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
3664 sect_variable_value): Add dwarf2_per_objfile parameter.
3665 (class dwarf_evaluate_loc_desc) <dwarf_call,
3666 dwarf_variable_value>: Update.
3667 (fetch_const_value_from_synthetic_pointer): Add
3668 dwarf2_per_objfile parameter.
3669 (fetch_const_value_from_synthetic_pointer): Update.
3670 (coerced_pieced_ref): Update.
3671 (class symbol_needs_eval_context) <dwarf_call,
3672 dwarf_variable_value>: Update.
3673 (dwarf2_compile_expr_to_ax): Update.
3674
3675 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3676
3677 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
3678 parameter.
3679 (dwarf2_evaluate_loc_desc_full): Update.
3680
3681 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3682
3683 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
3684 parameter.
3685 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
3686 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
3687 dwarf2_per_objfile parameter.
3688 (decode_debug_loc_dwo_addresses): Likewise.
3689 (dwarf2_find_location_expression): Update.
3690 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
3691 (locexpr_describe_location_piece): Add dwarf2_per_objfile
3692 parameter.
3693 (disassemble_dwarf_expression): Add dwarf2_per_objfile
3694 parameter.
3695 (locexpr_describe_location_1): Likewise.
3696 (locexpr_describe_location): Update.
3697
3698 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3699
3700 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
3701 Remove.
3702 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
3703 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
3704 (dwarf2_compile_property_to_c): Update.
3705 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
3706 use text offset from objfile.
3707 (locexpr_tracepoint_var_ref): Update.
3708 (locexpr_generate_c_location): Update.
3709 (loclist_describe_location): Update.
3710 (loclist_tracepoint_var_ref): Update.
3711 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
3712 dwarf2_per_objfile parameter.
3713 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
3714 use text offset from objfile.
3715 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
3716
3717 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3718
3719 * dwarf2/expr.h (struct dwarf_expr_context)
3720 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
3721 <offset>: Remove.
3722 <per_objfile>: New member.
3723 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
3724 dwarf2_per_objfile parameter. Don't set offset, set
3725 per_objfile.
3726 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
3727 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
3728 a dwarf2_per_objfile object instead of an offset.
3729 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
3730 constructor.
3731 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
3732 to dwarf2_expr_executor constructor. Don't set offset.
3733 (dwarf2_fetch_cfa_info): Update.
3734 (struct dwarf2_frame_cache) <text_offset>: Remove.
3735 <per_objfile>: New field.
3736 (dwarf2_frame_cache): Update.
3737 (dwarf2_frame_prev_register): Update.
3738 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3739 <dwarf_evaluate_loc_desc>: Add constructor.
3740 (dwarf2_evaluate_loc_desc_full): Update.
3741 (dwarf2_locexpr_baton_eval): Update.
3742 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
3743 Add constructor.
3744 (dwarf2_loc_desc_get_symbol_read_needs): Update.
3745
3746 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3747
3748 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
3749 addr_sized_int_type>: Move to dwarf2_cu.
3750 <int_type>: Move to dwarf2_per_objfile.
3751 (struct dwarf2_per_objfile) <int_type>: Move here.
3752 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
3753 addr_sized_int_type>: Move here.
3754 (read_func_scope): Update.
3755 (read_array_type): Update.
3756 (read_tag_string_type): Update.
3757 (attr_to_dynamic_prop): Update.
3758 (dwarf2_per_cu_data::int_type): Rename to...
3759 (dwarf2_per_objfile::int_type): ... this.
3760 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
3761 (dwarf2_cu::addr_sized_int_type): ... this.
3762 (read_subrange_type): Update.
3763 (dwarf2_per_cu_data::addr_type): Rename to...
3764 (dwarf2_cu::addr_type): ... this.
3765 (set_die_type): Update.
3766
3767 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3768
3769 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
3770 data through per_cu->cu.
3771
3772 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3773
3774 * dwarf2/read.c (lookup_dwo_comp_unit): Change
3775 dwarf2_per_cu_data parameter fo dwarf2_cu.
3776 (lookup_dwo_type_unit): Likewise.
3777 (read_cutu_die_from_dwo): Likewise.
3778 (lookup_dwo_unit): Likewise.
3779 (open_and_init_dwo_file): Likewise.
3780 (lookup_dwo_cutu): Likewise.
3781 (lookup_dwo_comp_unit): Likewise.
3782 (lookup_dwo_type_unit): Likewise.
3783 (cutu_reader::init_tu_and_read_dwo_dies): Update.
3784 (cutu_reader::cutu_reader): Update.
3785
3786 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3787
3788 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
3789 parameter.
3790 (process_full_type_unit): Likewise.
3791 (process_queue): Update.
3792
3793 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3794
3795 * dwarf2/read.c (recursively_compute_inclusions): Add
3796 dwarf2_per_objfile parameter.
3797 (compute_compunit_symtab_includes): Likewise.
3798 (process_cu_includes): Update.
3799
3800 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3801
3802 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
3803 parameter.
3804 (create_type_unit_group): Update.
3805 (process_psymtab_comp_unit_reader): Update.
3806 (build_type_psymtabs_reader): Update.
3807
3808 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3809
3810 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
3811 object through m_this_cu->cu.
3812
3813 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3814
3815 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
3816 the info parameter.
3817 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
3818
3819 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3820
3821 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
3822 per_objfile parameter.
3823 (load_full_type_unit): Add per_objfile parameter.
3824 (read_signatured_type): Likewise.
3825 (load_full_comp_unit): Likewise.
3826 (load_cu): Likewise.
3827 (dw2_do_instantiate_symtab): Likewise.
3828 (dw2_get_file_names): Likewise.
3829 (dw2_map_symtabs_matching_filename): Update.
3830 (dw_expand_symtabs_matching_file_matcher): Update.
3831 (dw2_map_symbol_filenames): Update.
3832 (process_psymtab_comp_unit): Add per_objfile parameter.
3833 (build_type_psymtabs_1): Update.
3834 (process_skeletonless_type_unit): Update.
3835 (dwarf2_build_psymtabs_hard): Update.
3836 (load_partial_comp_unit): Add per_objfile parameter.
3837 (scan_partial_symbols): Update.
3838 (load_full_comp_unit): Add per_objfile parameter.
3839 (process_imported_unit_die): Update.
3840 (create_cus_hash_table): Update.
3841 (find_partial_die): Update.
3842 (dwarf2_read_addr_index): Update.
3843 (follow_die_offset): Update.
3844 (dwarf2_fetch_die_loc_sect_off): Update.
3845 (dwarf2_fetch_constant_bytes): Update.
3846 (dwarf2_fetch_die_type_sect_off): Update.
3847 (follow_die_sig_1): Update.
3848 (load_full_type_unit): Add per_objfile parameter.
3849 (read_signatured_type): Likewise.
3850
3851 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3852
3853 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
3854 of objfile_name.
3855
3856 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3857
3858 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
3859 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
3860 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
3861 field.
3862 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
3863 (create_cus_from_index): Update.
3864 (dwarf2_read_gdb_index): Update.
3865 (create_cus_from_debug_names): Update.
3866 (dwarf2_read_debug_names): Update.
3867 (get_abbrev_section_for_cu): Update.
3868 (create_all_comp_units): Update.
3869 (read_attribute_value): Update.
3870 (get_debug_line_section): Update.
3871 * dwarf2/index-cache.c (index_cache::store): Update.
3872 * dwarf2/index-write.c (save_gdb_index_command): Update.
3873 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
3874
3875 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3876
3877 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
3878 member.
3879 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
3880 dwarf2_per_cu_data::per_bfd.
3881 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
3882 (create_type_unit_group): Likewise.
3883 (queue_comp_unit): Remove reference to
3884 per_cu->dwarf2_per_objfile.
3885 (maybe_queue_comp_unit): Likewise.
3886 (fill_in_sig_entry_from_dwo_entry): Assign new field.
3887 (create_cus_hash_table): Assign new field.
3888
3889 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3890
3891 * dwarf2/read.c: Replace
3892 dwarf2_cu->per_cu->dwarf2_per_objfile references with
3893 dwarf2_cu->per_objfile throughout.
3894
3895 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3896
3897 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
3898 parameter, don't use per_cu->dwarf2_per_objfile.
3899 (dw2_instantiate_symtab): Likewise.
3900 (dw2_find_last_source_symtab): Update.
3901 (dw2_map_expand_apply): Update.
3902 (dw2_lookup_symbol): Update.
3903 (dw2_expand_symtabs_for_function): Update.
3904 (dw2_expand_all_symtabs): Update.
3905 (dw2_expand_symtabs_with_fullname): Update.
3906 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
3907 don't use per_cu->dwarf2_per_objfile.
3908 (dw2_expand_marked_cus): Update.
3909 (dw2_find_pc_sect_compunit_symtab): Update.
3910 (dw2_debug_names_lookup_symbol): Update.
3911 (dw2_debug_names_expand_symtabs_for_function): Update.
3912 (dw2_debug_names_map_matching_symbols): Update.
3913 (dwarf2_psymtab::expand_psymtab): Update.
3914
3915 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3916
3917 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
3918 <per_objfile>: New member.
3919 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
3920 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
3921 call to dwarf2_cu.
3922 (cutu_reader::cutu_reader): Update.
3923 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
3924
3925 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3926
3927 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
3928 struct dwarf2_per_objfile.
3929 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
3930 dwarf2_per_bfd.
3931 * dwarf2/read.c (set_die_type): Update.
3932 (get_die_type_at_offset): Update.
3933
3934 2020-05-27 Tom Tromey <tom@tromey.com>
3935 Simon Marchi <simon.marchi@efficios.com>
3936
3937 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
3938 method.
3939 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
3940 get_symtab, set_symtab>: New methods.
3941 <m_symtabs>: New field.
3942 (struct dwarf2_psymtab): Derive from partial_symtab.
3943 <readin_p, get_compunit_symtab>: Declare methods.
3944 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
3945 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
3946 New methods.
3947 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
3948 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
3949 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
3950 (dw2_symtab_iter_next, dw2_print_stats)
3951 (dw2_expand_symtabs_with_fullname)
3952 (dw2_expand_symtabs_matching_one)
3953 (dw_expand_symtabs_matching_file_matcher)
3954 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
3955 (dw2_debug_names_iterator::next)
3956 (dw2_debug_names_map_matching_symbols)
3957 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
3958 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
3959 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
3960 New methods.
3961 (get_compunit_symtab, process_full_comp_unit)
3962 (process_full_type_unit): Update.
3963 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
3964
3965 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3966
3967 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
3968 then introduce a new dwarf2_per_objfile type.
3969 <read_line_string>: Move to the new dwarf2_per_objfile type.
3970 <objfile>: Likewise.
3971 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
3972 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
3973 dwarf2_per_objfile->per_bfd.
3974 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
3975 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
3976 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
3977 (dwarf2_per_bfd::free_cached_comp_units): ... this.
3978 (dwarf2_has_info): Allocate dwarf2_per_bfd.
3979 (dwarf2_per_objfile::locate_sections): Rename to...
3980 (dwarf2_per_bfd::locate_sections): ... this.
3981 (dwarf2_per_objfile::get_cutu): Rename to...
3982 (dwarf2_per_bfd::get_cutu): ... this.
3983 (dwarf2_per_objfile::get_cu): Rename to...
3984 (dwarf2_per_bfd::get_cu): ... this.
3985 (dwarf2_per_objfile::get_tu): Rename to...
3986 (dwarf2_per_bfd::get_tu): ... this.
3987 (dwarf2_per_objfile::allocate_per_cu): Rename to...
3988 (dwarf2_per_bfd::allocate_per_cu): ... this.
3989 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
3990 (dwarf2_per_bfd::allocate_signatured_type): ... this.
3991 (get_gdb_index_contents_ftype): Change parameter from
3992 dwarf2_per_objfile to dwarf2_per_bfd.
3993 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
3994 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
3995
3996 2020-05-27 Tom Tromey <tom@tromey.com>
3997 Simon Marchi <simon.marchi@efficios.com>
3998
3999 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
4000 (allocate_piece_closure): Set "per_objfile" member.
4001 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
4002 (locexpr_describe_location, loclist_describe_location): Use new
4003 member.
4004 * dwarf2/read.c (read_call_site_scope)
4005 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
4006 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
4007 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
4008 handle_data_member_location): Set per_objfile member.
4009 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
4010 member.
4011 (struct dwarf2_loclist_baton) <per_objfile>: New member.
4012
4013 2020-05-27 Tom Tromey <tom@tromey.com>
4014
4015 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
4016 allocate_signatured_type>: Declare new methods.
4017 <m_num_psymtabs>: New member.
4018 (struct dwarf2_per_cu_data) <index>: New member.
4019 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
4020 (dwarf2_per_objfile::allocate_signatured_type): New methods.
4021 (create_cu_from_index_list): Use allocate_per_cu.
4022 (create_signatured_type_table_from_index)
4023 (create_signatured_type_table_from_debug_names)
4024 (create_debug_type_hash_table, add_type_unit)
4025 (read_comp_units_from_section): Use allocate_signatured_type.
4026
4027 2020-05-27 Tom Tromey <tom@tromey.com>
4028
4029 * psymtab.c (partial_map_expand_apply)
4030 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
4031 (psym_lookup_global_symbol_language)
4032 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
4033 (psym_print_stats, psym_expand_symtabs_for_function)
4034 (psym_map_symbol_filenames, psym_map_matching_symbols)
4035 (psym_expand_symtabs_matching)
4036 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
4037 (maintenance_check_psymtabs): Update.
4038 * psympriv.h (struct partial_symtab) <readin_p,
4039 get_compunit_symtab>: Add objfile parameter.
4040 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
4041 Likewise.
4042 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
4043 get_compunit_symtab>: Likewise.
4044 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
4045
4046 2020-05-27 Tom Tromey <tom@tromey.com>
4047
4048 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
4049 member.
4050 * dwarf2/read.c (delete_file_name_entry): Fix comment.
4051 (create_cu_from_index_list)
4052 (create_signatured_type_table_from_index)
4053 (create_signatured_type_table_from_debug_names)
4054 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
4055 (dwarf2_create_include_psymtab)
4056 (create_debug_type_hash_table, add_type_unit)
4057 (create_type_unit_group, read_comp_units_from_section)
4058 (dwarf2_compute_name, create_cus_hash_table)
4059 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
4060 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
4061 obstack.
4062 (dw2_get_real_path): Likewise. Change argument to
4063 dwarf2_per_objfile.
4064
4065 2020-05-27 Luis Machado <luis.machado@linaro.org>
4066
4067 PR tdep/26000
4068 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
4069 for ldrd (immediate).
4070
4071 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4072
4073 * command.h: Add comment giving the name of class_tui.
4074 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
4075 create the fake command for the help for class_tui.
4076
4077 2020-05-26 Tom Tromey <tromey@adacore.com>
4078
4079 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
4080 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
4081 (val_atr): New function.
4082 (value_val_atr): Use it.
4083 * ada-valprint.c (print_optional_low_bound): Change low bound
4084 handling for enums.
4085 (val_print_packed_array_elements): Don't call discrete_position.
4086 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
4087 discrete_position for enum types.
4088 * language.c (default_print_array_index): Change type.
4089 * language.h (struct language_defn) <la_print_array_index>: Add
4090 index_type parameter, change type of index_value.
4091 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
4092 (default_print_array_index): Update.
4093 * valprint.c (maybe_print_array_index): Don't call
4094 value_from_longest. Update.
4095 (value_print_array_elements): Don't call discrete_position.
4096
4097 2020-05-26 Tom Tromey <tromey@adacore.com>
4098
4099 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
4100 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
4101
4102 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
4103
4104 PR gdb/13519
4105 * avr-tdep.c (avr_integer_to_address): Return data or code
4106 address accordingly to the second 'type' argument of the
4107 function.
4108
4109 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
4110
4111 * infcmd.c, inferior.h: (construct_inferior_arguments):
4112 Moved function from here to gdbsupport/common-inferior.{h,cc}
4113
4114 2020-05-23 Tom Tromey <tom@tromey.com>
4115
4116 Revert commit eca1f90c:
4117 * NEWS: Remove entry for completion styling.
4118 * completer.c (_rl_completion_prefix_display_length): Move
4119 declaration later.
4120 (gdb_fnprint): Revert.
4121 (gdb_display_match_list_1): Likewise.
4122 * cli/cli-style.c (completion_prefix_style)
4123 (completion_difference_style, completion_suffix_style): Remove.
4124 (_initialize_cli_style): Revert.
4125 * cli/cli-style.h (completion_prefix_style)
4126 (completion_difference_style, completion_suffix_style): Don't
4127 declare.
4128
4129 2020-05-24 Pedro Alves <palves@redhat.com>
4130
4131 * symtab.c (completion_list_add_name): Return boolean indication
4132 of whether the symbol matched.
4133 (completion_list_add_symbol): Don't try to remove C++ aliases if
4134 the symbol didn't match in the first place.
4135 * symtab.h (completion_list_add_name): Return bool.
4136
4137 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
4138
4139 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
4140 type::field.
4141
4142 2020-05-23 Joel Brobecker <brobecker@adacore.com>
4143
4144 GDB 9.2 released.
4145
4146 2020-05-23 Tom Tromey <tom@tromey.com>
4147
4148 * NEWS: Add entry for completion styling.
4149 * completer.c (_rl_completion_prefix_display_length): Move
4150 declaration earlier.
4151 (gdb_fnprint): Use completion_style.
4152 (gdb_display_match_list_1): Likewise.
4153 * cli/cli-style.c (completion_prefix_style)
4154 (completion_difference_style, completion_suffix_style): New
4155 globals.
4156 (_initialize_cli_style): Register new globals.
4157 * cli/cli-style.h (completion_prefix_style)
4158 (completion_difference_style, completion_suffix_style): Declare.
4159
4160 2020-05-23 Pedro Alves <palves@redhat.com>
4161
4162 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
4163 (parse_escape): Use ISDIGIT instead of isdigit.
4164 (puts_debug): Use gdb_isprint instead of isprint.
4165 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
4166 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
4167 ISSPACE instead of isspace.
4168 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
4169 instead of isspace.
4170 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
4171 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
4172 instead of isxdigit and ISDIGIT instead of isdigit.
4173
4174 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4175
4176 * gdbtypes.h (struct type) <field>: New method.
4177 (TYPE_FIELDS): Remove, replace all uses with either type::fields
4178 or type::field.
4179
4180 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4181
4182 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
4183 (TYPE_FIELDS): Use type::fields. Change all call sites that
4184 modify the propery to use type::set_fields instead.
4185
4186 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4187
4188 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
4189 type::num_fields instead.
4190
4191 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4192
4193 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
4194 methods.
4195 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
4196 that modify the number of fields to use type::set_num_fields
4197 instead.
4198
4199 2020-05-22 Tom Tromey <tromey@adacore.com>
4200
4201 * compile/compile-object-load.h (munmap_list_free): Don't
4202 declare.
4203
4204 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
4205
4206 * annotate.c (annotate_source_line): Update return type, add call
4207 to update current symtab and line.
4208 * annotate.h (annotate_source_line): Update return type, and
4209 extend header comment.
4210 * source.c (info_line_command): Check annotation_level before
4211 calling annotate_source_line.
4212 * stack.c (print_frame_info): If calling annotate_source_line
4213 returns true, then don't print any other source line information.
4214
4215 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
4216
4217 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
4218
4219 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
4220
4221 * coffread.c (patch_type): Remove NULL check before xfree.
4222 * corefile.c (set_gnutarget): Likewise.
4223 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
4224 * exec.c (build_section_table): Likewise.
4225 * remote.c (remote_target::pass_signals): Likewise.
4226 * utils.c (n_spaces): Likewise.
4227 * cli/cli-script.c (document_command): Likewise.
4228 * i386-windows-tdep.c (core_process_module_section): Likewise.
4229 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
4230
4231 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
4232
4233 * symfile.c (reread_symbols): Clear objfile's section_offsets
4234 vector and section indices, re-compute them by calling
4235 sym_offsets.
4236
4237 2020-05-20 Tom Tromey <tromey@adacore.com>
4238
4239 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
4240 (desc_one_bound, desc_index_type): Compute field name.
4241
4242 2020-05-20 Tom de Vries <tdevries@suse.de>
4243
4244 PR symtab/25833
4245 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
4246
4247 2020-05-20 Alan Modra <amodra@gmail.com>
4248
4249 PR 25993
4250 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
4251 bfd_set_filename.
4252 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
4253 passed to bfd_set_filename.
4254 * symfile-mem.c (add_vsyscall_page): Likewise for string
4255 passed to symbol_file_add_from_memory.
4256 (symbol_file_add_from_memory): Make name param a const char* and
4257 don't strdup.
4258
4259 2020-05-20 Alan Modra <amodra@gmail.com>
4260
4261 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
4262 rather than accessing bfd->filename directly.
4263 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
4264 and use bfd_section_name.
4265 * dwarf2/frame.c (decode_frame_entry): Likewise.
4266 * exec.c (exec_set_section_address): Likewise.
4267 * solib-aix.c (solib_aix_bfd_open): Likewise.
4268 * stap-probe.c (get_stap_base_address): Likewise.
4269 * symfile.c (reread_symbols): Likewise.
4270
4271 2020-05-19 Tom Tromey <tromey@adacore.com>
4272
4273 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
4274
4275 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4276
4277 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
4278
4279 2020-05-19 Pedro Alves <palves@redhat.com>
4280
4281 * NEWS (set exec-file-mismatch): Adjust entry.
4282 * exec.c: Include "build-id.h".
4283 (validate_exec_file): Try to match build IDs instead of filenames.
4284 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
4285 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
4286 and pass down 'warn_if_slow'.
4287 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
4288 gdb_bfd_open_closure to pass it down.
4289 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
4290
4291 2020-05-19 Pedro Alves <palves@redhat.com>
4292
4293 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
4294 * target.c (target_fileio_open_1): Rename to target_fileio_open
4295 and make extern. Use bool.
4296 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
4297 (target_fileio_read_alloc_1): Adjust.
4298 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
4299 (target_fileio_open_warn_if_slow): Delete declaration.
4300
4301 2020-05-19 Pedro Alves <palves@redhat.com>
4302
4303 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
4304 Adjust all callers.
4305
4306 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
4307
4308 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
4309 whether disp is negative.
4310
4311 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4312
4313 * symfile.h (struct symfile_segment_data)
4314 <~symfile_segment_data>: Remove.
4315 <segment_info>: Change to std::vector.
4316 * symfile.c (default_symfile_segments): Update.
4317 * elfread.c (elf_symfile_segments): Update.
4318
4319 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4320
4321 * symfile.h (struct symfile_segment_data) <struct segment>: New.
4322 <segments>: New.
4323 <segment_bases, segment_sizes>: Remove.
4324 * symfile.c (default_symfile_segments): Update.
4325 * elfread.c (elf_symfile_segments): Update.
4326 * remote.c (remote_target::get_offsets): Update.
4327 * solib-target.c (solib_target_relocate_section_addresses):
4328 Update.
4329
4330 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4331
4332 * symfile.h (struct symfile_segment_data): Initialize fields.
4333 <~symfile_segment_data>: Add.
4334 (symfile_segment_data_up): New.
4335 (struct sym_fns) <sym_segments>: Return a
4336 symfile_segment_data_up.
4337 (default_symfile_segments): Return a symfile_segment_data_up.
4338 (free_symfile_segment_data): Remove.
4339 (get_symfile_segment_data): Return a symfile_segment_data_up.
4340 * symfile.c (default_symfile_segments): Likewise.
4341 (get_symfile_segment_data): Likewise.
4342 (free_symfile_segment_data): Remove.
4343 (symfile_find_segment_sections): Update.
4344 * elfread.c (elf_symfile_segments): Return a
4345 symfile_segment_data_up.
4346 * remote.c (remote_target::get_offsets): Update.
4347 * solib-target.c (solib_target_relocate_section_addresses):
4348 Update.
4349 * symfile-debug.c (debug_sym_segments): Return a
4350 symfile_segment_data_up.
4351
4352 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4353
4354 PR build/25981
4355 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
4356 Hardcode register numbers.
4357
4358 PR build/25981
4359 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
4360 procfs_find_LDT_entry): Remove.
4361 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
4362 procfs_find_LDT_entry): Remove.
4363 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
4364 Remove.
4365
4366 2020-05-17 Pedro Alves <palves@redhat.com>
4367 Andrew Burgess <andrew.burgess@embecosm.com>
4368 Keno Fischer <keno@juliacomputing.com>
4369
4370 PR gdb/25741
4371 * breakpoint.c (build_target_condition_list): Update comments.
4372 (build_target_command_list): Update comments and skip matching
4373 locations.
4374 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
4375 a separate function. Simplify "set breakpoint auto-hw off"
4376 handling.
4377 (insert_breakpoints): Update comment.
4378 (tracepoint_locations_match): New parameter. For breakpoints,
4379 compare location types too, if the caller wants to.
4380 (handle_automatic_hardware_breakpoints): New functions.
4381 (bp_location_is_less_than): Also sort by location type and
4382 hardware breakpoint length.
4383 (update_global_location_list): Handle "set breakpoint auto-hw on"
4384 here.
4385 (update_breakpoint_locations): Ask breakpoint_locations_match to
4386 ignore location types.
4387
4388 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4389
4390 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
4391 type::name instead.
4392
4393 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4394
4395 * gdbtypes.h (struct type) <name, set_name>: New methods.
4396 (TYPE_CODE): Use type::name. Change all call sites used to set
4397 the name to use type::set_name instead.
4398
4399 2020-05-16 Tom Tromey <tom@tromey.com>
4400
4401 * top.c (quit_force): Update.
4402 * infrun.c (handle_no_resumed): Update.
4403 * top.h (all_uis): New function.
4404 (ALL_UIS): Remove.
4405
4406 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4407
4408 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
4409
4410 2020-05-16 Pedro Alves <palves@redhat.com>
4411
4412 * ia64-linux-nat.c
4413 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
4414 Declare method.
4415 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
4416
4417 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
4418
4419 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
4420 (sparc64_adi_info): Likewise.
4421
4422 2020-05-15 Tom Tromey <tom@tromey.com>
4423
4424 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
4425 block_objfile.
4426 (lookup_objfile_from_block): Remove.
4427 (lookup_symbol_in_block, lookup_symbol_in_static_block)
4428 (lookup_global_symbol): Use block_objfile.
4429 * symtab.h (lookup_objfile_from_block): Don't declare.
4430 * printcmd.c (clear_dangling_display_expressions): Use
4431 block_objfile.
4432 * parse.c (operator_check_standard): Use block_objfile.
4433
4434 2020-05-15 Tom Tromey <tom@tromey.com>
4435
4436 * language.c (language_alloc_type_symbol): Set
4437 SYMBOL_SECTION.
4438 * symtab.c (initialize_objfile_symbol): Remove.
4439 (allocate_symbol): Remove.
4440 (allocate_template_symbol): Remove.
4441 * dwarf2/read.c (fixup_go_packaging): Use "new".
4442 (new_symbol): Use "new".
4443 (read_variable): Don't call initialize_objfile_symbol. Use
4444 "new".
4445 (read_func_scope): Use "new".
4446 * xcoffread.c (process_xcoff_symbol): Don't call
4447 initialize_objfile_symbol.
4448 (SYMBOL_DUP): Remove.
4449 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
4450 "new".
4451 * symtab.h (allocate_symbol, initialize_objfile_symbol)
4452 (allocate_template_symbol): Don't declare.
4453 (struct symbol): Add copy constructor. Change defaults.
4454 * jit.c (finalize_symtab): Use "new".
4455 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
4456 Use "new".
4457 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
4458 (common_block_end): Use "new".
4459 * mdebugread.c (parse_symbol): Use "new".
4460 (new_symbol): Likewise.
4461
4462 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4463
4464 * NEWS: Mention changes to help and apropos.
4465
4466 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4467
4468 * command.h (enum command_class): Improve comments, document
4469 that class_alias is for user-defined aliases, give the class
4470 name for each class, remove unused class_xdb.
4471 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
4472 * breakpoint.c (_initialize_breakpoint): Replace class_alias
4473 by a precise class.
4474 * infcmd.c (_initialize_infcmd): Likewise.
4475 * reverse.c (_initialize_reverse): Likewise.
4476 * stack.c (_initialize_stack): Likewise.
4477 * symfile.c (_initialize_symfile): Likewise.
4478 * tracepoint.c (_initialize_tracepoint): Likewise.
4479
4480 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4481
4482 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
4483 when their aliased command is traversed.
4484 (help_cmd): Add fput_command_names_styled call to
4485 output command name and aliases when command has an alias.
4486
4487 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4488
4489 * cli/cli-decode.h (help_cmd_list): Remove declaration.
4490 * cli/cli-decode.c (help_cmd_list): Declare as static,
4491 remove prefix argument, use bool for recurse arg, rework to show the aliases of
4492 a command together with the command.
4493 (fput_command_name_styled, fput_command_names_styled): New functions.
4494 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
4495 fput_command_name_styled.
4496 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
4497 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
4498
4499 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4500
4501 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
4502 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
4503 * command.h (cmd_show_list): Likewise.
4504 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
4505 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
4506
4507 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4508
4509 * unittests/command-def-selftests.c (traverse_command_structure):
4510 Verify all commands of a list have the same prefix command and
4511 that only the top cmdlist commands have a null prefix.
4512
4513 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4514
4515 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
4516 as prefix, not one of its aliases.
4517 (set_cmd_prefix): Remove.
4518 (do_add_cmd): Centralize the setting of the prefix of a command, when
4519 command is defined after its full chain of prefix commands.
4520 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
4521 (add_setshow_cmd_full): Likewise.
4522 (update_prefix_field_of_prefixed_commands): New function.
4523 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
4524 update_prefix_field_of_prefixed_commands.
4525 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
4526 addresses of remote_set_cmdlist and remote_show_cmdlist given
4527 as argument, not the address of an argument.
4528 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
4529 * gdb/remote.c (_initialize_remote): Likewise.
4530
4531 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4532
4533 * cli/cli-cmds.c (alias_command): Check for an existing alias
4534 using lookup_cmd_composition, as valid_command_p is too strict
4535 and forbids aliases that are the prefix of an existing alias
4536 or command.
4537 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
4538 command is properly recognised as a valid command.
4539
4540 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4541
4542 * unittests/help-doc-selftests.c: Rename to
4543 unittests/command-def-selftests.c
4544 * unittests/command-def-selftests.c (help_doc_tests): Update some
4545 comments.
4546 (command_structure_tests, traverse_command_structure): New namespace
4547 and function.
4548 (command_structure_invariants_tests): New function.
4549 (_initialize_command_def_selftests) Renamed from
4550 _initialize_help_doc_selftests, register command_structure_invariants
4551 selftest.
4552
4553 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4554
4555 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
4556 an alias of 'show'.
4557
4558 2020-05-15 Joel Brobecker <brobecker@adacore.com>
4559
4560 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
4561 ada_is_fixed_point_type. Update all callers.
4562 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
4563 all callers.
4564 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
4565 Update all callers.
4566 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
4567 print_fixed_point_type. Update all callers.
4568 * ada-valprint.c (ada_value_print_num): Replace call to
4569 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
4570
4571 2020-05-14 Kevin Buettner <kevinb@redhat.com>
4572
4573 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
4574 processors.
4575 (cpu_supports_bts): Add CV_AMD case.
4576
4577 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
4578 Simon Marchi <simon.marchi@efficios.com>
4579
4580 * infrun.c (stop_all_threads): Collect multiple wait events at
4581 each pass.
4582
4583 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
4584
4585 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
4586 type::code instead.
4587
4588 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
4589
4590 * gdbtypes.h (struct type) <code, set_code>: New methods.
4591 (TYPE_CODE): Use type::code. Change all call sites used to set
4592 the code to use type::set_code instead.
4593
4594 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4595 Tom de Vries <tdevries@suse.de>
4596 Pedro Alves <palves@redhat.com>
4597
4598 PR threads/25478
4599 * infrun.c (stop_all_threads): Do NOT ignore
4600 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
4601 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
4602 received.
4603 (handle_no_resumed): Remove code handling a live inferior with no
4604 threads.
4605 * remote.c (has_single_non_exited_thread): New.
4606 (remote_target::update_thread_list): Do not delete a thread if is
4607 the last thread of the process.
4608 * thread.c (thread_select): Call delete_exited_threads instead of
4609 prune_threads.
4610
4611 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4612
4613 * infrun.c (stop_all_threads): Enable/disable thread events of all
4614 targets. Move a debug message denoting the end of the function
4615 into the SCOPED_EXIT block.
4616
4617 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4618
4619 * process-stratum-target.h: Include <set>.
4620 (all_non_exited_process_targets, switch_to_target_no_thread): New
4621 function declarations.
4622 * process-stratum-target.c (all_non_exited_process_targets)
4623 (switch_to_target_no_thread): New function implementations.
4624
4625 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4626
4627 * infrun.c (handle_inferior_event): Extract out a piece of code
4628 into...
4629 (mark_non_executing_threads): ...this new function.
4630
4631 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4632
4633 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
4634 use.
4635
4636 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4637
4638 * regcache.c (regcache_read_pc_protected): New function
4639 implementation that returns 0 if the PC cannot read via
4640 'regcache_read_pc'.
4641 * infrun.c (proceed): Call 'regcache_read_pc_protected'
4642 instead of 'regcache_read_pc'.
4643 (keep_going_pass_signal): Ditto.
4644
4645 2020-05-13 Tom Tromey <tromey@adacore.com>
4646
4647 * ada-lang.c (align_value): Remove.
4648 (ada_template_to_fixed_record_type_1): Use align_up.
4649
4650 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4651
4652 * async-event.c: Update the copyright year.
4653 * async-event.h: Update the copyright year.
4654
4655 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
4656
4657 * objfiles.h (is_addr_in_objfile,
4658 shared_objfile_contains_address_p): Return bool.
4659 * objfile.c (is_addr_in_objfile,
4660 shared_objfile_contains_address_p): Return bool.
4661
4662 2020-05-11 Tom Tromey <tromey@adacore.com>
4663
4664 * cli/cli-cmds.c (info_command): Restore.
4665 (_initialize_cli_cmds): Use add_prefix_command for "info".
4666 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
4667
4668 2020-05-11 Tom Tromey <tromey@adacore.com>
4669
4670 * ada-lang.c (ada_value_primitive_field): Now public.
4671 * ada-lang.h (ada_value_primitive_field): Declare.
4672 * ada-valprint.c (print_field_values): Use
4673 ada_value_primitive_field for wrapper fields.
4674
4675 2020-05-11 Tom de Vries <tdevries@suse.de>
4676
4677 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
4678 MODULE_DOMAIN.
4679
4680 2020-05-11 Tom de Vries <tdevries@suse.de>
4681
4682 PR symtab/25941
4683 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
4684 with length 0, if not gdb-produced.
4685 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
4686
4687 2020-05-09 Tom de Vries <tdevries@suse.de>
4688
4689 PR gdb/25955
4690 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
4691 calculation.
4692
4693 2020-05-09 Tom Tromey <tom@tromey.com>
4694
4695 * top.c (server_command): Now bool.
4696 * top.h (server_command): Now bool.
4697
4698 2020-05-08 Tom Tromey <tromey@adacore.com>
4699
4700 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
4701 already being processed.
4702
4703 2020-05-08 Tom Tromey <tom@tromey.com>
4704
4705 * printcmd.c (struct display) <next>: Remove.
4706 <display>: New constructor.
4707 <exp_string>: Now a std::string.
4708 <enabled_p>: Now a bool.
4709 (display_number): Move definition earlier.
4710 (displays): Rename from display_chain. Now a std::vector.
4711 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
4712 (display_command): Update.
4713 (do_one_display, disable_display)
4714 (enable_disable_display_command, do_enable_disable_display):
4715 Update.
4716 (free_display): Remove.
4717 (clear_displays): Rewrite.
4718 (delete_display): Update.
4719 (map_display_numbers): Use function_view. Remove "data"
4720 parameter. Update.
4721 (do_delete_display): Remove.
4722 (undisplay_command): Update.
4723 (do_one_display, do_displays, disable_display)
4724 (info_display_command): Update.
4725 (do_enable_disable_display): Remove.
4726 (enable_disable_display_command)
4727 (clear_dangling_display_expressions): Update.
4728
4729 2020-05-08 Tom Tromey <tom@tromey.com>
4730
4731 * symtab.c (set_symbol_cache_size)
4732 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
4733 (maintenance_print_symbol_cache_statistics): Update.
4734 * symmisc.c (print_symbol_bcache_statistics)
4735 (print_objfile_statistics, maintenance_print_objfiles)
4736 (maintenance_info_symtabs, maintenance_check_symtabs)
4737 (maintenance_expand_symtabs, maintenance_info_line_tables):
4738 Update.
4739 * symfile-debug.c (set_debug_symfile): Update.
4740 * source.c (forget_cached_source_info): Update.
4741 * python/python.c (gdbpy_progspaces): Update.
4742 * psymtab.c (maintenance_info_psymtabs): Update.
4743 * probe.c (parse_probes): Update.
4744 * linespec.c (iterate_over_all_matching_symtabs)
4745 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
4746 * guile/scm-progspace.c (gdbscm_progspaces): Update.
4747 * exec.c (exec_target::close): Update.
4748 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
4749 * breakpoint.c (print_one_breakpoint_location)
4750 (create_longjmp_master_breakpoint)
4751 (create_std_terminate_master_breakpoint): Update.
4752 * progspace.c (program_spaces): Now a std::vector.
4753 (maybe_new_address_space): Update.
4754 (add_program_space): Remove.
4755 (program_space::program_space): Update.
4756 (remove_program_space): Update.
4757 (number_of_program_spaces): Remove.
4758 (print_program_space, update_address_spaces): Update.
4759 * progspace.h (program_spaces): Change type.
4760 (ALL_PSPACES): Remove.
4761 (number_of_program_spaces): Don't declare.
4762 (struct program_space) <next>: Remove.
4763
4764 2020-05-08 Tom Tromey <tom@tromey.com>
4765
4766 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
4767 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
4768 (enable_break): Update.
4769 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
4770 (frv_fdpic_find_canonical_descriptor): Update.
4771 (frv_fetch_objfile_link_map): Update.
4772 * progspace.c (program_space::free_all_objfiles): Update.
4773 (program_space::solibs): New method.
4774 * progspace.h (struct program_space) <solibs>: New method.
4775 * solist.h (master_so_list): Don't declare.
4776 (ALL_SO_LIBS): Remove.
4777 * solib.h (so_list_head): Remove.
4778 (update_solib_list): Update comment.
4779 * solib.c (master_so_list): Remove.
4780 (solib_used, update_solib_list, solib_add)
4781 (info_sharedlibrary_command, clear_solib)
4782 (reload_shared_libraries_1, remove_user_added_objfile): Update.
4783
4784 2020-05-08 Tom Tromey <tom@tromey.com>
4785
4786 * extension.c (extension_languages): Now a std::array.
4787 (ALL_EXTENSION_LANGUAGES): Remove.
4788 (get_ext_lang_defn, get_ext_lang_of_file)
4789 (eval_ext_lang_from_control_command): Update.
4790 (finish_ext_lang_initialization)
4791 (auto_load_ext_lang_scripts_for_objfile)
4792 (ext_lang_type_printers::ext_lang_type_printers)
4793 (apply_ext_lang_type_printers)
4794 (ext_lang_type_printers::~ext_lang_type_printers)
4795 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
4796 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
4797 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
4798 (get_matching_xmethod_workers, ext_lang_colorize)
4799 (ext_lang_before_prompt): Update.
4800 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
4801
4802 2020-05-08 Tom Tromey <tom@tromey.com>
4803
4804 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
4805 overload.
4806 <swap_string, m_string>: Remove.
4807 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
4808 Update.
4809 * stabsread.c (define_symbol, read_type): Update.
4810 * linespec.c (find_linespec_symbols): Update.
4811 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
4812 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
4813 * dbxread.c (read_dbx_symtab): Update.
4814 * cp-support.h (cp_canonicalize_string_full)
4815 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
4816 Return unique_xmalloc_ptr.
4817 * cp-support.c (inspect_type): Update.
4818 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
4819 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
4820 Likewise.
4821 * c-typeprint.c (print_name_maybe_canonical): Update.
4822 * break-catch-throw.c (check_status_exception_catchpoint):
4823 Update.
4824
4825 2020-05-08 Tom de Vries <tdevries@suse.de>
4826
4827 * infrun.c (follow_fork): Copy current_line and current_symtab to
4828 child thread.
4829
4830 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4831
4832 * async-event.c (struct async_signal_handler, struct
4833 async_event_handler): Reformat, remove typedef.
4834
4835 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4836
4837 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
4838 access thistype->main_type->dyn_prop_list directly.
4839
4840 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4841
4842 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
4843 (remove_dyn_prop): Remove. Update all users to use
4844 type::remove_dyn_prop.
4845 * gdbtypes.c (remove_dyn_prop): Rename to...
4846 (type::remove_dyn_prop): ... this.
4847
4848 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
4849
4850 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
4851 (add_dyn_prop): Remove. Update all users to use
4852 type::add_dyn_prop.
4853 * gdbtypes.c (add_dyn_prop): Rename to...
4854 (type::add_dyn_prop): ... this.
4855
4856 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4857
4858 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
4859 (get_dyn_prop): Remove. Update all users to use
4860 type::dyn_prop.
4861 * gdbtypes.c (get_dyn_prop): Rename to...
4862 (type::dyn_prop): ... this.
4863
4864 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
4865
4866 * gdbtypes.h (struct main_type) <flag_static>: Remove.
4867
4868 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
4869
4870 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
4871 instruction, skip it if it's there.
4872
4873 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
4874
4875 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
4876
4877 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
4878
4879 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
4880 * gdbtypes.c (recursive_dump_type): Remove use of
4881 TYPE_INCOMPLETE.
4882
4883 2020-05-03 Tom Tromey <tom@tromey.com>
4884
4885 * breakpoint.c (catch_command, tcatch_command): Remove.
4886 (_initialize_breakpoint): Use add_basic_prefix_cmd,
4887 add_show_prefix_cmd.
4888 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
4889 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4890 Remove.
4891 (add_internal_problem_command): Use add_basic_prefix_cmd,
4892 add_show_prefix_cmd.
4893 * mips-tdep.c (set_mipsfpu_command): Remove.
4894 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
4895 * dwarf2/index-cache.c (set_index_cache_command): Remove.
4896 (_initialize_index_cache): Use add_basic_prefix_cmd.
4897 * memattr.c (dummy_cmd): Remove.
4898 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
4899 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
4900 (_initialize_tui_win): Use add_basic_prefix_cmd,
4901 add_show_prefix_cmd.
4902 * cli/cli-logging.c (set_logging_command): Remove.
4903 (_initialize_cli_logging): Use add_basic_prefix_cmd,
4904 add_show_prefix_cmd.
4905 (show_logging_command): Remove.
4906 * target.c (target_command): Remove.
4907 (add_target): Use add_basic_prefix_cmd.
4908
4909 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
4910
4911 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
4912
4913 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4914
4915 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
4916 info_command.
4917
4918 2020-04-30 Kamil Rytarowski <n54@gmx.com>
4919
4920 * nbsd-nat.c (nbsd_enable_proc_events)
4921 (nbsd_nat_target::post_startup_inferior): Add.
4922 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
4923 (nbsd_nat_target::update_thread_list): Rewrite.
4924 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
4925 "PTRACE_LWP_CREATE".
4926 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
4927
4928 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4929
4930 * stack.c (_initialize_stack): Remove duplicated creation
4931 of "frame" command and "f" alias.
4932
4933 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4934
4935 PR gdb/18706
4936 * gdbtypes.c (check_typedef): Calculate size of array of
4937 stubbed type.
4938
4939 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4940
4941 PR gdb/15559
4942 * i386-tdep.c (i386_push_dummy_call): Call
4943 i386_thiscall_push_dummy_call.
4944 (i386_thiscall_push_dummy_call): New function.
4945 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
4946 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
4947 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
4948
4949 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4950
4951 * gdbarch.sh (do_read): Add shellcheck disable directive for
4952 warning SC2162.
4953
4954 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4955
4956 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
4957 "referenced but not assigned" warning.
4958
4959 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4960
4961 * gdbarch.sh: Remove code that sets fallbackdefault.
4962
4963 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4964
4965 * gdbarch.sh: Use shell operators && and || instead of
4966 -a and -o.
4967
4968 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4969
4970 * gdbarch.sh: Use $(...) instead of `...`.
4971
4972 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4973
4974 * gdbarch.sh: Use double quotes around variables.
4975
4976 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4977
4978 * gdbarch.sh: Use %s with printf, instead of variables in the
4979 format string.
4980
4981 2020-04-29 Tom Tromey <tromey@adacore.com>
4982
4983 PR ada/25875:
4984 * dwarf2/read.c (update_enumeration_type_from_children): Compute
4985 type fields here.
4986 (read_enumeration_type): Call
4987 update_enumeration_type_from_children later. Update comments.
4988 (process_enumeration_scope): Don't create type fields.
4989
4990 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4991
4992 * nbsd-tdep.c: Include "xml-syscall.h".
4993 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
4994
4995 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4996
4997 * nbsd-nat.c: Include "sys/wait.h".
4998 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
4999 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
5000 (nbsd_nat_target::remove_exec_catchpoint)
5001 (nbsd_nat_target::set_syscall_catchpoint): Add.
5002 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
5003 (nbsd_nat_target::insert_exec_catchpoint)
5004 (nbsd_nat_target::remove_exec_catchpoint)
5005 (nbsd_nat_target::set_syscall_catchpoint): Add.
5006 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
5007 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
5008 `nbsd_get_syscall_number'.
5009
5010 2020-04-29 Tom Tromey <tom@tromey.com>
5011
5012 * stack.c (print_block_frame_labels): Remove.
5013
5014 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
5015
5016 PR gdb/17320
5017 * ada-valprint.c (val_print_packed_array_elements): Move array
5018 end bracket to new line.
5019 (ada_val_print_string): Remove extra spaces before first array
5020 element.
5021 * c-valprint.c (c_value_print_array): Likewise.
5022 * m2-valprint.c (m2_print_array_contents): Likewise.
5023 (m2_value_print_inner): Likewise.
5024 * p-valprint.c (pascal_value_print_inner): Likewise.
5025 * valprint.c (generic_val_print_array): Likewise.
5026 (value_print_array_elements): Move first array element and array
5027 end bracket to new line.
5028
5029 2020-04-29 Tom de Vries <tdevries@suse.de>
5030
5031 PR symtab/25889
5032 * linespec.c (find_method): Fix ix calculation.
5033
5034 2020-04-28 Kamil Rytarowski <n54@gmx.com>
5035
5036 * syscalls/update-netbsd.sh: New file.
5037 * syscalls/netbsd.xml: Regenerate.
5038 * data-directory/Makefile.in: Register `netbsd.xml' in
5039 `SYSCALLS_FILES'.
5040
5041 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
5042
5043 * syscalls/update-freebsd.sh: Add double quotes.
5044
5045 2020-04-28 Tom Tromey <tom@tromey.com>
5046
5047 * NEWS: Update.
5048 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
5049 (cmdpy_init): Allow class_tui.
5050
5051 2020-04-28 Mark Williams <mark@myosotissp.com>
5052
5053 PR gdb/24480
5054 * dwarf2read.c: Add missing assingments to list_in_scope when
5055 start_symtab was already called.
5056
5057 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
5058
5059 PR gdb/25881
5060 * dwarf2/read.c (offset_map_type): Use
5061 gdb:hash_enum<sect_offset> as hash function.
5062
5063 2020-04-28 Tom de Vries <tdevries@suse.de>
5064
5065 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
5066 with DW_AT_signature.
5067
5068 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
5069
5070 * configure.ac: Remove check for fs_base/gs_base in
5071 user_regs_struct.
5072 * configure: Re-generate.
5073 * config.in: Re-generate.
5074 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
5075 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
5076 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
5077
5078 2020-04-27 Luis Machado <luis.machado@linaro.org>
5079
5080 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
5081 problematic inline frame unwinding situation.
5082 * frame.c (frame_id_computed_p): New function.
5083 * frame.h (frame_id_computed_p): New prototype.
5084
5085 2020-04-26 Tom Tromey <tom@tromey.com>
5086
5087 * command.h (enum command_class) <class_pseudo>: Remove.
5088
5089 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5090
5091 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
5092 and whitespace.
5093
5094 2020-04-25 Kamil Rytarowski <n54@gmx.com>
5095
5096 * inf-ptrace.c (inf_ptrace_target::wait): Remove
5097 `PT_GET_PROCESS_STATE' block.
5098
5099 2020-04-24 Tom Tromey <tom@tromey.com>
5100
5101 * symtab.h (symbol_get_demangled_name): Don't declare.
5102 * symtab.c (symbol_get_demangled_name): Remove.
5103 (general_symbol_info::natural_name)
5104 (general_symbol_info::demangled_name): Update.
5105
5106 2020-04-24 Tom Tromey <tom@tromey.com>
5107
5108 PR rust/25025:
5109 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
5110
5111 2020-04-24 Tom Tromey <tom@tromey.com>
5112
5113 PR symtab/12707:
5114 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
5115 exists.
5116 (new_symbol): Likewise.
5117 * compile/compile-object-load.c (get_out_value_type): Use
5118 symbol_matches_search_name.
5119
5120 2020-04-24 Tom Tromey <tom@tromey.com>
5121
5122 * dwarf2/read.c (add_partial_symbol): Do not call
5123 compute_and_set_names.
5124
5125 2020-04-24 Tom Tromey <tom@tromey.com>
5126
5127 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
5128 overload.
5129
5130 2020-04-24 Tom Tromey <tom@tromey.com>
5131
5132 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
5133 (add_psymbol_to_list): New overload. Make old overload call new
5134 one.
5135 * psympriv.h (add_psymbol_to_list): New overload.
5136
5137 2020-04-24 Tom Tromey <tom@tromey.com>
5138
5139 * dwarf2/read.c (partial_die_info::read) <case
5140 DW_AT_linkage_name>: Use value_as_string.
5141 (dwarf2_string_attr): Use value_as_string.
5142 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
5143 method.
5144 * dwarf2/attribute.c (attribute::value_as_string): New method.
5145
5146 2020-04-24 Tom Tromey <tom@tromey.com>
5147
5148 * symtab.c (general_symbol_info::natural_name)
5149 (general_symbol_info::demangled_name): Check for language_rust.
5150
5151 2020-04-24 Tom Tromey <tom@tromey.com>
5152
5153 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
5154 (dwarf2_physname): ... from here.
5155 (partial_die_info::read): Add Rust "{" hack.
5156
5157 2020-04-24 Tom Tromey <tom@tromey.com>
5158
5159 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
5160 method.
5161 (symbol_set_demangled_name): Don't declare.
5162 * symtab.c (general_symbol_info::set_demangled_name): Rename from
5163 symbol_set_demangled_name.
5164 (general_symbol_info::set_language)
5165 (general_symbol_info::compute_and_set_names): Update.
5166 * minsyms.c (minimal_symbol_reader::install): Update.
5167 * dwarf2/read.c (new_symbol): Update.
5168
5169 2020-04-24 Tom Tromey <tromey@adacore.com>
5170
5171 PR python/23662:
5172 * python/py-type.c (convert_field): Handle
5173 FIELD_LOC_KIND_DWARF_BLOCK.
5174 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
5175 (typy_get_dynamic): Nw function.
5176 (type_object_getset): Add "dynamic".
5177 * NEWS: Add entry.
5178
5179 2020-04-24 Tom Tromey <tromey@adacore.com>
5180
5181 * ada-typeprint.c (print_choices, print_variant_part)
5182 (print_record_field_types_dynamic): New functions.
5183 (print_record_field_types): Use print_record_field_types_dynamic.
5184
5185 2020-04-24 Tom Tromey <tromey@adacore.com>
5186
5187 * dwarf2/read.c (handle_data_member_location): New overload.
5188 (dwarf2_add_field): Use it.
5189 (decode_locdesc): Add "computed" parameter. Update comment.
5190 * gdbtypes.c (is_dynamic_type_internal): Also look for
5191 FIELD_LOC_KIND_DWARF_BLOCK.
5192 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
5193 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
5194 virtual base classes.
5195 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
5196 FIELD_LOC_KIND_DWARF_BLOCK.
5197
5198 2020-04-24 Tom Tromey <tromey@adacore.com>
5199
5200 * dwarf2/read.c (read_structure_type): Handle dynamic length.
5201 * gdbtypes.c (is_dynamic_type_internal): Check
5202 TYPE_HAS_DYNAMIC_LENGTH.
5203 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
5204 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
5205 New macros.
5206 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
5207 constant.
5208
5209 2020-04-24 Tom Tromey <tromey@adacore.com>
5210
5211 * dwarf2/read.c (struct variant_field): Rewrite.
5212 (struct variant_part_builder): New.
5213 (struct nextfield): Remove "variant" field. Add "offset".
5214 (struct field_info): Add "current_variant_part" and
5215 "variant_parts".
5216 (alloc_discriminant_info): Remove.
5217 (alloc_rust_variant): New function.
5218 (quirk_rust_enum): Update.
5219 (dwarf2_add_field): Set "offset" member. Don't handle
5220 DW_TAG_variant_part.
5221 (offset_map_type): New typedef.
5222 (convert_variant_range, create_one_variant)
5223 (create_one_variant_part, create_variant_parts)
5224 (add_variant_property): New functions.
5225 (dwarf2_attach_fields_to_type): Call add_variant_property.
5226 (read_structure_type): Don't handle DW_TAG_variant_part.
5227 (handle_variant_part, handle_variant): New functions.
5228 (handle_struct_member_die): Use them.
5229 (process_structure_scope): Don't handle variant parts.
5230 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
5231 (struct discriminant_info): Remove.
5232 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
5233 (struct main_type) <flag_discriminated_union>: Remove.
5234 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
5235 (rust_enum_variant): Return int. Remove "contents". Rewrite.
5236 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
5237 Update.
5238 * valops.c (value_union_variant): Remove.
5239 * value.h (value_union_variant): Don't declare.
5240
5241 2020-04-24 Tom Tromey <tromey@adacore.com>
5242
5243 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
5244 (ada_value_primitive_packed_val): Update.
5245 * ada-valprint.c (ada_value_print_1): Update.
5246 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
5247 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
5248 just an address. Use evaluate_for_locexpr_baton.
5249 (dwarf2_evaluate_property): Update.
5250 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
5251 array_view.
5252 * findvar.c (default_read_var_value): Update.
5253 * gdbtypes.c (compute_variant_fields_inner)
5254 (resolve_dynamic_type_internal): Update.
5255 (resolve_dynamic_type): Change type of valaddr parameter.
5256 * gdbtypes.h (resolve_dynamic_type): Update.
5257 * valarith.c (value_subscripted_rvalue): Update.
5258 * value.c (value_from_contents_and_address): Update.
5259
5260 2020-04-24 Tom Tromey <tromey@adacore.com>
5261
5262 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
5263 "push_initial_value" parameter.
5264 (dwarf2_evaluate_property): Likewise.
5265 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
5266
5267 2020-04-24 Tom Tromey <tromey@adacore.com>
5268
5269 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
5270 (variant::matches, compute_variant_fields_recurse)
5271 (compute_variant_fields_inner, compute_variant_fields): New
5272 functions.
5273 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
5274 Use resolved_type after type is made.
5275 (operator==): Add new cases.
5276 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
5277 (struct discriminant_range, struct variant, struct variant_part):
5278 New.
5279 (union dynamic_prop_data) <variant_parts, original_type>: New
5280 members.
5281 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
5282 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
5283 constants.
5284 * value.c (unpack_bits_as_long): Now public.
5285 * value.h (unpack_bits_as_long): Declare.
5286
5287 2020-04-24 Tom Tromey <tromey@adacore.com>
5288
5289 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
5290 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
5291
5292 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
5293
5294 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
5295
5296 2020-04-24 Kamil Rytarowski <n54@gmx.com>
5297
5298 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
5299 (remove_fork_catchpoint, post_startup_inferior)
5300 (post_attach): Move...
5301 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
5302 (remove_fork_catchpoint, post_startup_inferior)
5303 (post_attach): ...here.
5304 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
5305 (remove_fork_catchpoint, post_startup_inferior)
5306 (post_attach): Move...
5307 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
5308 (remove_fork_catchpoint, post_startup_inferior)
5309 (post_attach): ...here.
5310
5311 2020-04-24 Tom Tromey <tromey@adacore.com>
5312
5313 * nat/windows-nat.h (struct windows_thread_info)
5314 <pc_adjusted>: New member.
5315 * windows-nat.c (windows_fetch_one_register): Check
5316 pc_adjusted.
5317 (windows_nat_target::get_windows_debug_event)
5318 (windows_nat_target::wait): Set pc_adjusted.
5319
5320 2020-04-24 Tom de Vries <tdevries@suse.de>
5321
5322 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
5323 Run gdb-add-index inside temp dir.
5324
5325 2020-04-23 Tom Tromey <tromey@adacore.com>
5326
5327 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
5328 in loop.
5329
5330 2020-04-23 Luis Machado <luis.machado@linaro.org>
5331
5332 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
5333 get_frame_register instead of gdbarch_unwind_pc.
5334
5335 2020-04-23 Tom de Vries <tdevries@suse.de>
5336
5337 * symtab.c (lookup_global_symbol): Prefer def over decl.
5338
5339 2020-04-23 Tom de Vries <tdevries@suse.de>
5340
5341 PR symtab/25807
5342 * block.c (best_symbol, better_symbol): Promote to external.
5343 * block.h (best_symbol, better_symbol): Declare.
5344 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
5345 decl.
5346
5347 2020-04-23 Tom Tromey <tromey@adacore.com>
5348
5349 PR ada/25837:
5350 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
5351 "const char *", not a "const std::string &".
5352 <name_and_matcher::operator==>: Update.
5353 * unittests/lookup_name_info-selftests.c: Change type of
5354 "result".
5355
5356 2020-04-23 Tom Tromey <tom@tromey.com>
5357
5358 * inferior.h (iterate_over_inferiors): Don't declare.
5359 * inferior.c (iterate_over_inferiors): Remove.
5360 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
5361 Remove.
5362 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
5363 use iterate_over_inferiors.
5364 (darwin_resume_inferior_it)
5365 (struct resume_inferior_threads_param)
5366 (darwin_resume_inferior_threads_it): Remove.
5367 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
5368
5369 2020-04-23 Tom de Vries <tdevries@suse.de>
5370
5371 * blockframe.c (find_pc_partial_function): Use
5372 find_pc_sect_compunit_symtab rather than
5373 objfile->sf->qf->find_pc_sect_compunit_symtab.
5374
5375 2020-04-22 Tom de Vries <tdevries@suse.de>
5376
5377 PR symtab/25764
5378 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
5379 in psymtabs.
5380
5381 2020-04-22 Tom de Vries <tdevries@suse.de>
5382
5383 PR symtab/25801
5384 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
5385 symtabs.
5386
5387 2020-04-22 Tom de Vries <tdevries@suse.de>
5388
5389 PR symtab/25700
5390 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
5391 CU if already created.
5392
5393 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5394
5395 * infrun.c (displaced_step_fixup): Switch to the event_thread
5396 before calling displaced_step_restore, not after.
5397
5398 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5399
5400 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
5401 its inferior is not recorded by us.
5402 (record_btrace_target_open): Replace call to
5403 all_non_exited_threads () with call to current_inferior
5404 ()->non_exited_threads ().
5405 (record_btrace_target::stop_recording): Likewise.
5406 (record_btrace_target::close): Likewise.
5407 (record_btrace_target::wait): Likewise.
5408 (record_btrace_target::record_stop_replaying): Likewise.
5409
5410 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5411
5412 * btrace.c (btrace_enable): Throw an error on double enables and
5413 when enabling recording fails.
5414 (btrace_disable): Throw an error if the thread is not recorded.
5415
5416 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5417
5418 * record-btrace.c (record_btrace_target::fetch_registers): Forward
5419 request if we do not have a thread_info.
5420
5421 2020-04-21 Tom de Vries <tdevries@suse.de>
5422
5423 PR gdb/25471
5424 * thread.c
5425 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
5426 exception in get_frame_id.
5427
5428 2020-04-20 Tom Tromey <tromey@adacore.com>
5429
5430 * python/python.c (struct gdbpy_event): Mark move constructor as
5431 noexcept.
5432 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
5433 constructor as noexcept.
5434 * completer.h (struct completion_result): Mark move constructor as
5435 noexcept.
5436 * completer.c (completion_result::completion_result): Use
5437 initialization style. Don't call reset_match_list.
5438
5439 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
5440
5441 * MAINTAINERS (Write After Approval): Add myself.
5442
5443 2020-04-18 Tom Tromey <tom@tromey.com>
5444
5445 * windows-tdep.c (init_w32_command_list)
5446 (w32_prefix_command_valid): Restore.
5447 (_initialize_windows_tdep): Call init_w32_command_list.
5448
5449 2020-04-18 Tom Tromey <tom@tromey.com>
5450
5451 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
5452 * value.c (value_fn_field): Update.
5453 * valops.c (find_function_in_inferior)
5454 (value_allocate_space_in_inferior): Update.
5455 * tui/tui-winsource.c (tui_update_source_windows_with_line):
5456 Update.
5457 * tui/tui-source.c (tui_source_window::set_contents): Update.
5458 * symtab.c (lookup_global_or_static_symbol)
5459 (find_function_start_sal_1, skip_prologue_sal)
5460 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
5461 * symmisc.c (dump_msymbols, dump_symtab_1)
5462 (maintenance_print_one_line_table): Update.
5463 * symfile.c (init_entry_point_info, section_is_mapped)
5464 (list_overlays_command, simple_read_overlay_table)
5465 (simple_overlay_update_1): Update.
5466 * stap-probe.c (handle_stap_probe): Update.
5467 * stabsread.c (dbx_init_float_type, define_symbol)
5468 (read_one_struct_field, read_enum_type, read_range_type): Update.
5469 * source.c (info_line_command): Update.
5470 * python/python.c (gdbpy_source_objfile_script)
5471 (gdbpy_execute_objfile_script): Update.
5472 * python/py-type.c (save_objfile_types): Update.
5473 * python/py-objfile.c (py_free_objfile): Update.
5474 * python/py-inferior.c (python_new_objfile): Update.
5475 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
5476 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
5477 (maintenance_check_psymtabs): Update.
5478 * printcmd.c (info_address_command): Update.
5479 * objfiles.h (struct objfile) <arch>: New method, from
5480 get_objfile_arch.
5481 (get_objfile_arch): Don't declare.
5482 * objfiles.c (get_objfile_arch): Remove.
5483 (filter_overlapping_sections): Update.
5484 * minsyms.c (msymbol_is_function): Update.
5485 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
5486 (output_nondebug_symbol): Update.
5487 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
5488 (mdebug_expand_psymtab): Update.
5489 * machoread.c (macho_add_oso_symfile): Update.
5490 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
5491 Update.
5492 * linux-fork.c (checkpoint_command): Update.
5493 * linespec.c (convert_linespec_to_sals): Update.
5494 * jit.c (finalize_symtab): Update.
5495 * infrun.c (insert_exception_resume_from_probe): Update.
5496 * ia64-tdep.c (ia64_find_unwind_table): Update.
5497 * hppa-tdep.c (internalize_unwinds): Update.
5498 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
5499 Update.
5500 * gcore.c (call_target_sbrk): Update.
5501 * elfread.c (record_minimal_symbol, elf_symtab_read)
5502 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
5503 (elf_gnu_ifunc_resolve_by_got): Update.
5504 * dwarf2/read.c (create_addrmap_from_index)
5505 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
5506 (read_debug_names_from_section)
5507 (process_psymtab_comp_unit_reader, add_partial_symbol)
5508 (add_partial_subprogram, process_full_comp_unit)
5509 (read_file_scope, read_func_scope, read_lexical_block_scope)
5510 (read_call_site_scope, dwarf2_ranges_read)
5511 (dwarf2_record_block_ranges, dwarf2_add_field)
5512 (mark_common_block_symbol_computed, read_tag_pointer_type)
5513 (read_tag_string_type, dwarf2_init_float_type)
5514 (dwarf2_init_complex_target_type, read_base_type)
5515 (partial_die_info::read, partial_die_info::read)
5516 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
5517 (dwarf2_fetch_die_loc_sect_off): Update.
5518 * dwarf2/loc.c (dwarf2_find_location_expression)
5519 (class dwarf_evaluate_loc_desc, rw_pieced_value)
5520 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
5521 (dwarf2_loc_desc_get_symbol_read_needs)
5522 (locexpr_describe_location_piece, locexpr_describe_location_1)
5523 (loclist_describe_location): Update.
5524 * dwarf2/index-write.c (write_debug_names): Update.
5525 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
5526 * dtrace-probe.c (dtrace_process_dof): Update.
5527 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
5528 (process_one_symbol): Update.
5529 * ctfread.c (ctf_init_float_type, read_base_type): Update.
5530 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
5531 (coff_read_enum_type): Update.
5532 * cli/cli-cmds.c (edit_command, list_command): Update.
5533 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
5534 * breakpoint.c (create_overlay_event_breakpoint)
5535 (create_longjmp_master_breakpoint)
5536 (create_std_terminate_master_breakpoint)
5537 (create_exception_master_breakpoint, get_sal_arch): Update.
5538 * block.c (block_gdbarch): Update.
5539 * annotate.c (annotate_source_line): Update.
5540
5541 2020-04-17 Tom Tromey <tromey@adacore.com>
5542
5543 * auto-load.c (show_auto_load_cmd): Remove.
5544 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
5545 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
5546 (maintenance_print_arc_command): Remove.
5547 * tui/tui-win.c (tui_command): Remove.
5548 (tui_get_cmd_list): Use add_basic_prefix_cmd.
5549 * tui/tui-layout.c (tui_layout_command): Remove.
5550 (_initialize_tui_layout): Use add_basic_prefix_cmd.
5551 * python/python.c (user_set_python, user_show_python): Remove.
5552 (_initialize_python): Use add_basic_prefix_cmd,
5553 add_show_prefix_cmd.
5554 * guile/guile.c (set_guile_command, show_guile_command): Remove.
5555 (install_gdb_commands): Use add_basic_prefix_cmd,
5556 add_show_prefix_cmd.
5557 (info_guile_command): Remove.
5558 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
5559 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
5560 add_show_prefix_cmd.
5561 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
5562 Remove do_set and do_show parameters.
5563 * cli/cli-style.c (set_style, show_style): Remove.
5564 (_initialize_cli_style): Use add_basic_prefix_cmd,
5565 add_show_prefix_cmd.
5566 (cli_style_option::add_setshow_commands): Remove do_set and
5567 do_show parameters.
5568 (cli_style_option::add_setshow_commands): Use
5569 add_basic_prefix_cmd, add_show_prefix_cmd.
5570 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
5571 (set_style_name): Remove.
5572 * cli/cli-dump.c (dump_command, append_command): Remove.
5573 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5574 (tekhex_dump_command, binary_dump_command)
5575 (binary_append_command): Remove.
5576 (_initialize_cli_dump): Use add_basic_prefix_cmd.
5577 * windows-tdep.c (w32_prefix_command_valid): Remove global.
5578 (init_w32_command_list): Remove; move into ...
5579 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
5580 * valprint.c (set_print, show_print, set_print_raw)
5581 (show_print_raw): Remove.
5582 (_initialize_valprint): Use add_basic_prefix_cmd,
5583 add_show_prefix_cmd.
5584 * typeprint.c (set_print_type, show_print_type): Remove.
5585 (_initialize_typeprint): Use add_basic_prefix_cmd,
5586 add_show_prefix_cmd.
5587 * record.c (set_record_command, show_record_command): Remove.
5588 (_initialize_record): Use add_basic_prefix_cmd,
5589 add_show_prefix_cmd.
5590 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
5591 add_show_prefix_cmd.
5592 (info_command, show_command, set_debug, show_debug): Remove.
5593 * top.h (set_history, show_history): Don't declare.
5594 * top.c (set_history, show_history): Remove.
5595 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5596 (unset_tdesc_cmd): Remove.
5597 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
5598 add_show_prefix_cmd.
5599 * symtab.c (info_module_command): Remove.
5600 (_initialize_symtab): Use add_basic_prefix_cmd.
5601 * symfile.c (overlay_command): Remove.
5602 (_initialize_symfile): Use add_basic_prefix_cmd.
5603 * sparc64-tdep.c (info_adi_command): Remove.
5604 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
5605 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
5606 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
5607 add_show_prefix_cmd.
5608 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
5609 (_initialize_serial): Use add_basic_prefix_cmd,
5610 add_show_prefix_cmd.
5611 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
5612 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
5613 add_show_prefix_cmd.
5614 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
5615 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
5616 add_show_prefix_cmd.
5617 * riscv-tdep.c (show_riscv_command, set_riscv_command)
5618 (show_debug_riscv_command, set_debug_riscv_command): Remove.
5619 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
5620 add_show_prefix_cmd.
5621 * remote.c (remote_command, set_remote_cmd): Remove.
5622 (_initialize_remote): Use add_basic_prefix_cmd.
5623 * record-full.c (set_record_full_command)
5624 (show_record_full_command): Remove.
5625 (_initialize_record_full): Use add_basic_prefix_cmd,
5626 add_show_prefix_cmd.
5627 * record-btrace.c (cmd_set_record_btrace)
5628 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
5629 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
5630 (cmd_show_record_btrace_pt): Remove.
5631 (_initialize_record_btrace): Use add_basic_prefix_cmd,
5632 add_show_prefix_cmd.
5633 * ravenscar-thread.c (set_ravenscar_command)
5634 (show_ravenscar_command): Remove.
5635 (_initialize_ravenscar): Use add_basic_prefix_cmd,
5636 add_show_prefix_cmd.
5637 * mips-tdep.c (show_mips_command, set_mips_command)
5638 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
5639 add_show_prefix_cmd.
5640 * maint.c (maintenance_command, maintenance_info_command)
5641 (maintenance_check_command, maintenance_print_command)
5642 (maintenance_set_cmd, maintenance_show_cmd): Remove.
5643 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
5644 add_show_prefix_cmd.
5645 (show_per_command_cmd): Remove.
5646 * maint-test-settings.c (maintenance_set_test_settings_cmd):
5647 Remove.
5648 (maintenance_show_test_settings_cmd): Remove.
5649 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
5650 add_show_prefix_cmd.
5651 * maint-test-options.c (maintenance_test_options_command):
5652 Remove.
5653 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
5654 * macrocmd.c (macro_command): Remove
5655 (_initialize_macrocmd): Use add_basic_prefix_cmd.
5656 * language.c (set_check, show_check): Remove.
5657 (_initialize_language): Use add_basic_prefix_cmd,
5658 add_show_prefix_cmd.
5659 * infcmd.c (unset_command): Remove.
5660 (_initialize_infcmd): Use add_basic_prefix_cmd.
5661 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
5662 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
5663 add_show_prefix_cmd.
5664 * go32-nat.c (go32_info_dos_command): Remove.
5665 (_initialize_go32_nat): Use add_basic_prefix_cmd.
5666 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
5667 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
5668 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
5669 (_initialize_frame): Use add_basic_prefix_cmd,
5670 add_show_prefix_cmd.
5671 * dcache.c (set_dcache_command, show_dcache_command): Remove.
5672 (_initialize_dcache): Use add_basic_prefix_cmd,
5673 add_show_prefix_cmd.
5674 * cp-support.c (maint_cplus_command): Remove.
5675 (_initialize_cp_support): Use add_basic_prefix_cmd.
5676 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5677 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5678 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
5679 add_basic_prefix_cmd, add_show_prefix_cmd.
5680 * breakpoint.c (save_command): Remove.
5681 (_initialize_breakpoint): Use add_basic_prefix_cmd.
5682 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
5683 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
5684 add_show_prefix_cmd.
5685 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
5686 (set_ada_command, show_ada_command): Remove.
5687 (_initialize_ada_language): Use add_basic_prefix_cmd,
5688 add_show_prefix_cmd.
5689 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
5690
5691 2020-04-16 Kamil Rytarowski <n54@gmx.com>
5692
5693 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
5694 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
5695
5696 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
5697
5698 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
5699 warning messages.
5700
5701 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
5702
5703 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
5704 import table is not at beginning of .idata section.
5705
5706 2020-04-16 Pedro Alves <palves@redhat.com>
5707
5708 * inferior.c (delete_inferior): Use delete operator directly
5709 instead of delete_program_space.
5710 * progspace.c (add_program_space): New, factored out from
5711 program_space::program_space.
5712 (remove_program_space): New, factored out from
5713 delete_program_space.
5714 (program_space::program_space): Remove intro comment. Rewrite.
5715 (program_space::~program_space): Remove intro comment. Call
5716 remove_program_space.
5717 (delete_program_space): Delete.
5718 * progspace.h (program_space::program_space): Make explicit. Move
5719 intro comment here, adjusted.
5720 (program_space::~program_space): Move intro comment here,
5721 adjusted.
5722 (delete_program_space): Remove.
5723
5724 2020-04-16 Tom Tromey <tromey@adacore.com>
5725
5726 * windows-nat.c (windows_nat::handle_access_violation): New
5727 function.
5728 * nat/windows-nat.h (handle_access_violation): Declare.
5729 * nat/windows-nat.c (handle_exception): Move Cygwin code to
5730 windows-nat.c. Call handle_access_violation.
5731
5732 2020-04-16 Tom de Vries <tdevries@suse.de>
5733
5734 PR symtab/25791
5735 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
5736 CUs without psymtab.
5737
5738 2020-04-16 Kevin Buettner <kevinb@redhat.com>
5739
5740 * python/python.c (do_start_initialization): Don't call
5741 PyEval_InitThreads for Python 3.9 and beyond.
5742
5743 2020-04-15 Kamil Rytarowski <n54@gmx.com>
5744
5745 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
5746 thread functions.
5747 (obsd_nat_target::wait): Likewise.
5748
5749 2020-04-15 Tom Tromey <tromey@adacore.com>
5750
5751 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
5752 (DEBUG_EXCEPT): Use debug_printf.
5753
5754 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
5755
5756 * completer.c (class completion_tracker::completion_hash_entry)
5757 <hash_name>: New member function.
5758 (completion_tracker::discard_completions): New callback to hash a
5759 completion_hash_entry, pass this to htab_create_alloc.
5760
5761 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
5762
5763 * windows-nat.c (windows_make_so): Warn rather than stopping with
5764 an error if realpath() fails.
5765
5766 2020-04-14 Kamil Rytarowski <n54@gmx.com>
5767
5768 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
5769 (nbsd_nat_target::info_proc): Add do_status.
5770
5771 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
5772 Tom de Vries <tdevries@suse.de>
5773
5774 PR symtab/25718
5775 * psympriv.h (struct partial_symtab::read_symtab)
5776 (struct partial_symtab::expand_psymtab)
5777 (struct partial_symtab::read_dependencies): Update comments.
5778 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
5779 read_symtab for includer.
5780 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
5781 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
5782 (struct dwarf2_include_psymtab::m_readin): Remove.
5783 (struct dwarf2_include_psymtab::includer): New member function.
5784 (dwarf2_psymtab::expand_psymtab): Assert !readin.
5785
5786 2020-04-14 Tom de Vries <tdevries@suse.de>
5787
5788 PR symtab/25720
5789 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
5790 with NULL symbol_matcher and lookup_name.
5791 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
5792 and lookup_name.
5793 * dwarf2/read.c (dw2_expand_symtabs_matching)
5794 (dw2_debug_names_expand_symtabs_matching): Same.
5795 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
5796 Make lookup_name a pointer. Update comment.
5797 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
5798 lookup_name being a pointer.
5799 * symfile.c (expand_symtabs_matching): Same.
5800 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
5801 * linespec.c (iterate_over_all_matching_symtabs): Same.
5802
5803 2020-04-13 Tom Tromey <tom@tromey.com>
5804
5805 * run-on-main-thread.c: Update include.
5806 * unittests/main-thread-selftests.c: Update include.
5807 * tui/tui-win.c: Update include.
5808 * tui/tui-io.c: Update include.
5809 * tui/tui-interp.c: Update include.
5810 * tui/tui-hooks.c: Update include.
5811 * top.h: Update include.
5812 * top.c: Update include.
5813 * ser-base.c: Update include.
5814 * remote.c: Update include.
5815 * remote-notif.c: Update include.
5816 * remote-fileio.c: Update include.
5817 * record-full.c: Update include.
5818 * record-btrace.c: Update include.
5819 * python/python.c: Update include.
5820 * posix-hdep.c: Update include.
5821 * mingw-hdep.c: Update include.
5822 * mi/mi-main.c: Update include.
5823 * mi/mi-interp.c: Update include.
5824 * main.c: Update include.
5825 * linux-nat.c: Update include.
5826 * interps.c: Update include.
5827 * infrun.c: Update include.
5828 * inf-loop.c: Update include.
5829 * event-top.c: Update include.
5830 * event-loop.c: Move to ../gdbsupport/.
5831 * event-loop.h: Move to ../gdbsupport/.
5832 * async-event.h: Update include.
5833 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
5834
5835 2020-04-13 Tom Tromey <tom@tromey.com>
5836
5837 * tui/tui-win.c: Include async-event.h.
5838 * remote.c: Include async-event.h.
5839 * remote-notif.c: Include async-event.h.
5840 * record-full.c: Include async-event.h.
5841 * record-btrace.c: Include async-event.h.
5842 * infrun.c: Include async-event.h.
5843 * event-top.c: Include async-event.h.
5844 * event-loop.h: Move some declarations to async-event.h.
5845 * event-loop.c: Don't include ser-event.h or top.h. Move some
5846 code to async-event.c.
5847 * async-event.h: New file.
5848 * async-event.c: New file.
5849 * Makefile.in (COMMON_SFILES): Add async-event.c.
5850 (HFILES_NO_SRCDIR): Add async-event.h.
5851
5852 2020-04-13 Tom Tromey <tom@tromey.com>
5853
5854 * utils.c (flush_streams): New function.
5855 * event-loop.c (gdb_wait_for_event): Call flush_streams.
5856
5857 2020-04-13 Tom Tromey <tom@tromey.com>
5858
5859 * event-loop.c (handle_file_event): Use warning, not
5860 printf_unfiltered.
5861
5862 2020-04-13 Tom Tromey <tom@tromey.com>
5863
5864 * event-loop.c: Include <chrono>.
5865
5866 2020-04-13 Tom Tromey <tom@tromey.com>
5867
5868 * gdb_select.h: Move to ../gdbsupport/.
5869 * event-loop.c: Update include path.
5870 * top.c: Update include path.
5871 * ser-base.c: Update include path.
5872 * ui-file.c: Update include path.
5873 * ser-tcp.c: Update include path.
5874 * guile/scm-ports.c: Update include path.
5875 * posix-hdep.c: Update include path.
5876 * ser-unix.c: Update include path.
5877 * gdb_usleep.c: Update include path.
5878 * mingw-hdep.c: Update include path.
5879 * inflow.c: Update include path.
5880 * infrun.c: Update include path.
5881 * event-top.c: Update include path.
5882
5883 2020-04-13 Tom Tromey <tom@tromey.com>
5884
5885 * configure: Rebuild.
5886 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
5887
5888 2020-04-13 Tom Tromey <tom@tromey.com>
5889
5890 * event-loop.h (start_event_loop): Don't declare.
5891 * event-loop.c (start_event_loop): Move...
5892 * main.c (start_event_loop): ...here. Now static.
5893
5894 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
5895
5896 * MAINTAINERS: Update my email address.
5897
5898 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5899
5900 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
5901 IP_ALL.
5902
5903 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5904
5905 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
5906 (nbsd_nat_target::info_proc): Add do_cmdline.
5907
5908 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5909
5910 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
5911 (nbsd_nat_target::info_proc): Add do_cwd.
5912
5913 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5914
5915 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
5916
5917 2020-04-11 Kamil Rytarowski <n54@gmx.com>
5918
5919 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
5920 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
5921 (nbsd_nat_target::info_proc): New functions.
5922 * nbsd-nat.c (kinfo_get_vmmap): New function.
5923 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
5924 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
5925 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
5926 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
5927 functions.
5928 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
5929 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
5930 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
5931 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
5932 (KINFO_VME_FLAG_GROWS_DOWN): New.
5933
5934 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
5935
5936 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
5937 bit shift.
5938
5939 2020-04-10 Tom Tromey <tromey@adacore.com>
5940
5941 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
5942
5943 2020-04-10 Tom Tromey <tromey@adacore.com>
5944
5945 * symtab.c (get_symbol_address, get_msymbol_address): Skip
5946 separate debug files.
5947
5948 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
5949
5950 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5951 Move to...
5952 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5953 ... here.
5954 * windows-nat.c (windows_nat_target::get_windows_debug_event):
5955 Check for STATUS_WX86_BREAKPOINT.
5956 (windows_nat_target::wait): Same.
5957
5958 2020-04-10 Tom de Vries <tdevries@suse.de>
5959
5960 PR cli/25808
5961 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
5962
5963 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5964
5965 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
5966 (Write After Approval): Remove Tom de Vries.
5967
5968 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
5969
5970 revert partially:
5971 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5972
5973 * buildsym.c (record_line): Fix undefined behavior and preserve
5974 lines at eof.
5975
5976 2020-04-09 Kamil Rytarowski <n54@gmx.com>
5977
5978 * auxv.h (svr4_auxv_parse): New.
5979 * auxv.c (default_auxv_parse): Split into default_auxv_parse
5980 and generic_auxv_parse.
5981 (svr4_auxv_parse): Add.
5982 * obsd-tdep.c: Include "auxv.h".
5983 (obsd_auxv_parse): Remove.
5984 (obsd_init_abi): Remove comment.
5985 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
5986 from `obsd_auxv_parse' to `svr4_auxv_parse'.
5987 * nbsd-tdep.c: Include "auxv.h".
5988 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
5989
5990 2020-04-08 Tom Tromey <tromey@adacore.com>
5991
5992 * nat/windows-nat.h (last_wait_event): Don't declare.
5993 (wait_for_debug_event): Update comment.
5994 * nat/windows-nat.c (last_wait_event): Now static.
5995
5996 2020-04-08 Tom Tromey <tromey@adacore.com>
5997
5998 * windows-nat.c (wait_for_debug_event): Move to
5999 nat/windows-nat.c.
6000 * nat/windows-nat.h (wait_for_debug_event): Declare.
6001 * nat/windows-nat.c (wait_for_debug_event): Move from
6002 windows-nat.c. No longer static.
6003
6004 2020-04-08 Tom Tromey <tromey@adacore.com>
6005
6006 * windows-nat.c (get_windows_debug_event): Use
6007 fetch_pending_stop.
6008 * nat/windows-nat.h (fetch_pending_stop): Declare.
6009 * nat/windows-nat.c (fetch_pending_stop): New function.
6010
6011 2020-04-08 Tom Tromey <tromey@adacore.com>
6012
6013 * windows-nat.c (windows_continue): Use matching_pending_stop and
6014 continue_last_debug_event.
6015 * nat/windows-nat.h (matching_pending_stop)
6016 (continue_last_debug_event): Declare.
6017 * nat/windows-nat.c (DEBUG_EVENTS): New define.
6018 (matching_pending_stop, continue_last_debug_event): New
6019 functions.
6020
6021 2020-04-08 Tom Tromey <tromey@adacore.com>
6022
6023 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
6024 (handle_exception_result): Move to nat/windows-nat.h.
6025 (DEBUG_EXCEPTION_SIMPLE): Remove.
6026 (windows_nat::handle_ms_vc_exception): New function.
6027 (handle_exception): Move to nat/windows-nat.c.
6028 (get_windows_debug_event): Update.
6029 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
6030 nat/windows-nat.c.
6031 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
6032 (handle_exception_result): Move from windows-nat.c.
6033 (handle_exception): Declare.
6034 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
6035 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
6036 windows-nat.c.
6037
6038 2020-04-08 Tom Tromey <tromey@adacore.com>
6039
6040 * windows-nat.c (exception_count, event_count): Remove.
6041 (handle_exception, get_windows_debug_event)
6042 (do_initial_windows_stuff): Update.
6043
6044 2020-04-08 Tom Tromey <tromey@adacore.com>
6045
6046 * windows-nat.c (windows_nat::handle_load_dll)
6047 (windows_nat::handle_unload_dll): Rename. No longer static.
6048 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
6049 Declare.
6050
6051 2020-04-08 Tom Tromey <tromey@adacore.com>
6052
6053 * complaints.h (stop_whining): Declare at top-level.
6054 (complaint): Don't declare stop_whining.
6055
6056 2020-04-08 Tom Tromey <tromey@adacore.com>
6057
6058 * windows-nat.c (windows_nat::handle_output_debug_string):
6059 Rename. No longer static.
6060 * nat/windows-nat.h (handle_output_debug_string): Declare.
6061
6062 2020-04-08 Tom Tromey <tromey@adacore.com>
6063
6064 * windows-nat.c (current_process_handle, current_process_id)
6065 (main_thread_id, last_sig, current_event, last_wait_event)
6066 (current_windows_thread, desired_stop_thread_id, pending_stops)
6067 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
6068 (display_selectors, fake_create_process)
6069 (get_windows_debug_event): Update.
6070 * nat/windows-nat.h (current_process_handle, current_process_id)
6071 (main_thread_id, last_sig, current_event, last_wait_event)
6072 (current_windows_thread, desired_stop_thread_id, pending_stops)
6073 (struct pending_stop, siginfo_er): Move from windows-nat.c.
6074 * nat/windows-nat.c (current_process_handle, current_process_id)
6075 (main_thread_id, last_sig, current_event, last_wait_event)
6076 (current_windows_thread, desired_stop_thread_id, pending_stops)
6077 (siginfo_er): New globals. Move from windows-nat.c.
6078
6079 2020-04-08 Tom Tromey <tromey@adacore.com>
6080
6081 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
6082 (handle_load_dll): Update.
6083 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
6084
6085 2020-04-08 Tom Tromey <tromey@adacore.com>
6086
6087 * windows-nat.c (enum thread_disposition_type): Move to
6088 nat/windows-nat.h.
6089 (windows_nat::thread_rec): Rename from thread_rec. No longer
6090 static.
6091 (windows_add_thread, windows_nat_target::fetch_registers)
6092 (windows_nat_target::store_registers, handle_exception)
6093 (windows_nat_target::resume, get_windows_debug_event)
6094 (windows_nat_target::get_tib_address)
6095 (windows_nat_target::thread_name)
6096 (windows_nat_target::thread_alive): Update.
6097 * nat/windows-nat.h (enum thread_disposition_type): Move from
6098 windows-nat.c.
6099 (thread_rec): Declare.
6100
6101 2020-04-08 Tom Tromey <tromey@adacore.com>
6102
6103 * windows-nat.c: Add "using namespace".
6104 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
6105 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
6106
6107 2020-04-08 Tom Tromey <tromey@adacore.com>
6108
6109 * nat/windows-nat.h (struct windows_thread_info): Declare
6110 destructor.
6111 * nat/windows-nat.c (~windows_thread_info): New.
6112
6113 2020-04-08 Tom Tromey <tromey@adacore.com>
6114
6115 PR gdb/22992
6116 * windows-nat.c (current_event): Update comment.
6117 (last_wait_event, desired_stop_thread_id): New globals.
6118 (struct pending_stop): New.
6119 (pending_stops): New global.
6120 (windows_nat_target) <stopped_by_sw_breakpoint>
6121 <supports_stopped_by_sw_breakpoint>: New methods.
6122 (windows_fetch_one_register): Add assertions. Adjust PC.
6123 (windows_continue): Handle pending stops. Suspend other threads
6124 when stepping. Use last_wait_event
6125 (wait_for_debug_event): New function.
6126 (get_windows_debug_event): Use wait_for_debug_event. Handle
6127 pending stops. Queue spurious stops.
6128 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
6129 (windows_nat_target::kill): Use wait_for_debug_event.
6130 * nat/windows-nat.h (struct windows_thread_info)
6131 <stopped_at_software_breakpoint>: New field.
6132 * nat/windows-nat.c (windows_thread_info::resume): Clear
6133 stopped_at_software_breakpoint.
6134
6135 2020-04-08 Tom Tromey <tromey@adacore.com>
6136
6137 * windows-nat.c (enum thread_disposition_type): New.
6138 (thread_rec): Replace "get_context" parameter with "disposition";
6139 change type.
6140 (windows_add_thread, windows_nat_target::fetch_registers)
6141 (windows_nat_target::store_registers, handle_exception)
6142 (windows_nat_target::resume, get_windows_debug_event)
6143 (windows_nat_target::get_tib_address)
6144 (windows_nat_target::thread_name)
6145 (windows_nat_target::thread_alive): Update.
6146
6147 2020-04-08 Tom Tromey <tromey@adacore.com>
6148
6149 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
6150 (windows_continue): Use windows_continue::resume.
6151 * nat/windows-nat.h (struct windows_thread_info) <suspend,
6152 resume>: Declare new methods.
6153 * nat/windows-nat.c: New file.
6154 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
6155
6156 2020-04-08 Tom Tromey <tromey@adacore.com>
6157
6158 * windows-nat.c (windows_add_thread, windows_delete_thread)
6159 (windows_nat_target::fetch_registers)
6160 (windows_nat_target::store_registers, fake_create_process)
6161 (windows_nat_target::resume, windows_nat_target::resume)
6162 (get_windows_debug_event, windows_nat_target::wait)
6163 (windows_nat_target::pid_to_str)
6164 (windows_nat_target::get_tib_address)
6165 (windows_nat_target::get_ada_task_ptid)
6166 (windows_nat_target::thread_name)
6167 (windows_nat_target::thread_alive): Use lwp, not tid.
6168
6169 2020-04-08 Tom Tromey <tromey@adacore.com>
6170
6171 * windows-nat.c (handle_exception)
6172 (windows_nat_target::thread_name): Update.
6173 * nat/windows-nat.h (windows_thread_info): Remove destructor.
6174 <name>: Now unique_xmalloc_ptr.
6175
6176 2020-04-08 Tom Tromey <tromey@adacore.com>
6177
6178 * windows-nat.c (thread_rec)
6179 (windows_nat_target::fetch_registers): Update.
6180 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
6181 Update comment.
6182 <debug_registers_changed, reload_context>: Now bool.
6183
6184 2020-04-08 Tom Tromey <tromey@adacore.com>
6185
6186 * windows-nat.c (windows_add_thread): Use new.
6187 (windows_init_thread_list, windows_delete_thread): Use delete.
6188 (get_windows_debug_event): Update.
6189 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
6190 destructor, and initializers.
6191
6192 2020-04-08 Tom Tromey <tromey@adacore.com>
6193
6194 * windows-nat.c (struct windows_thread_info): Remove.
6195 * nat/windows-nat.h: New file.
6196
6197 2020-04-08 Tom Tromey <tromey@adacore.com>
6198
6199 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
6200 (thread_rec, windows_add_thread, windows_delete_thread)
6201 (windows_continue): Update.
6202
6203 2020-04-08 Tom Tromey <tromey@adacore.com>
6204
6205 * windows-nat.c (struct windows_thread_info): Remove typedef.
6206 (thread_head): Remove.
6207 (thread_list): New global.
6208 (thread_rec, windows_add_thread, windows_init_thread_list)
6209 (windows_delete_thread, windows_continue): Update.
6210
6211 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
6212
6213 * windows-tdep.h (windows_init_abi): Add comment.
6214 (cygwin_init_abi): New declaration.
6215 * windows-tdep.c: Split signal enumeration in two, one for
6216 Windows and one for Cygwin.
6217 (windows_gdb_signal_to_target): Only deal with signal of the
6218 Windows OS ABI.
6219 (cygwin_gdb_signal_to_target): New function.
6220 (windows_init_abi): Rename to windows_init_abi_common, don't set
6221 gdb_signal_to_target gdbarch method. Add new new function with
6222 this name.
6223 (cygwin_init_abi): New function.
6224 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
6225 comment. Don't call windows_init_abi.
6226 (amd64_windows_init_abi): Add comment, call windows_init_abi.
6227 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
6228 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
6229 i386_windows_init_abi_common, don't call windows_init_abi. Add
6230 a new function of this name.
6231 (i386_cygwin_init_abi): New function.
6232 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
6233 OS ABI Cygwin.
6234
6235 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
6236
6237 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
6238 parameter.c.
6239 (dwarf2_read_gdb_index): Update.
6240
6241 2020-04-07 Kamil Rytarowski <n54@gmx.com>
6242
6243 * nbsd-tdep.c: Include "objfiles.h".
6244 (nbsd_skip_solib_resolver): New.
6245 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
6246
6247 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6248
6249 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
6250 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
6251 with DW_LLE_base_addressx are being emitted in DWARFv5.
6252 Add the newly added kind DW_LOC_OFFSET_PAIR also.
6253 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
6254 unsigned integer.
6255
6256 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6257
6258 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
6259 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
6260 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
6261 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
6262 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
6263 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
6264 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
6265
6266
6267 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6268
6269 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
6270 (read_loclist_index): New function definition.
6271 (lookup_loclist_base): New function definition.
6272 (read_loclist_header): New function definition.
6273 (dwarf2_cu): Add loclist_base and loclist_header field.
6274 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
6275 (read_full_die_1): Read the value of DW_AT_loclists_base.
6276 (read_attribute_reprocess): Handle DW_FORM_loclistx.
6277 (read_attribute_value): Handle DW_FORM_loclistx.
6278 (skip_one_die): Handle DW_FORM_loclistx.
6279 (loclist_header): New structure declaration.
6280 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
6281
6282 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6283
6284 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
6285 constructor. Remove `addr` parameter from other constructor and
6286 add `per_cu` parameter.
6287 * dwarf2/read.c (create_partial_symtab): Update.
6288
6289 2020-04-07 Tom de Vries <tdevries@suse.de>
6290
6291 PR symtab/25796
6292 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
6293 (partial_die_info::fixup): Inherit has_const_value.
6294
6295 2020-04-07 Tom de Vries <tdevries@suse.de>
6296
6297 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
6298 symbols without address.
6299
6300 2020-04-06 Kamil Rytarowski <n54@gmx.com>
6301
6302 * nbsd-nat.h (struct thread_info): Add forward declaration.
6303 (nbsd_nat_target::thread_alive): Add.
6304 (nbsd_nat_target::thread_name): Likewise.
6305 (nbsd_nat_target::update_thread_list): Likewise.
6306 (update_thread_list::post_attach): Likewise.
6307 (post_attach::pid_to_str): Likewise.
6308 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
6309 (nbsd_thread_lister): Add.
6310 (nbsd_nat_target::thread_alive): Likewise.
6311 (nbsd_nat_target::thread_name): Likewise.
6312 (nbsd_add_threads): Likewise.
6313 (update_thread_list::post_attach): Likewise.
6314 (nbsd_nat_target::update_thread_list): Likewise.
6315 (post_attach::pid_to_str): Likewise.
6316
6317 2020-04-06 Tom Tromey <tromey@adacore.com>
6318
6319 * ada-valprint.c (print_variant_part): Extract the variant field.
6320 (print_field_values): Use the field as the outer value when
6321 recursing.
6322
6323 2020-04-06 Tom Tromey <tromey@adacore.com>
6324
6325 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
6326 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
6327 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
6328 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
6329 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
6330
6331 2020-04-06 Tom Tromey <tromey@adacore.com>
6332
6333 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
6334 TYPE_CODE_ERROR.
6335
6336 2020-04-06 Kamil Rytarowski <n54@gmx.com>
6337
6338 * nbsd-tdep.c: Include "gdbarch.h".
6339 Define enum with NetBSD signal numbers.
6340 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
6341 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
6342 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
6343 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
6344 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
6345 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
6346 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
6347 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
6348 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
6349 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
6350 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
6351 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
6352
6353 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
6354
6355 PR gdb/25325
6356 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
6357
6358 2020-04-03 Tom Tromey <tromey@adacore.com>
6359
6360 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
6361 Read constant block.
6362
6363 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
6364
6365 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
6366 (gdb_bfd_get_full_section_contents): New declaration.
6367 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
6368 * windows-tdep.c (is_linked_with_cygwin_dll): Use
6369 gdb_bfd_get_full_section_contents.
6370
6371 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
6372
6373 * exec.c (build_section_table): Replace internal_error with
6374 gdb_assert.
6375 (section_table_xfer_memory_partial): Likewise.
6376 * mdebugread.c (parse_partial_symbols): Likewise.
6377 * psymtab.c (lookup_partial_symbol): Likewise.
6378 * utils.c (wrap_here): Likewise.
6379
6380 2020-04-02 Tom Tromey <tromey@adacore.com>
6381
6382 * f-lang.c (build_fortran_types): Use arch_type to initialize
6383 builtin_complex_s32 in the TYPE_CODE_ERROR case.
6384
6385 2020-04-02 Tom Tromey <tromey@adacore.com>
6386
6387 * dwarf2/read.c (partial_die_info::read): Do not create a vector
6388 of attributes.
6389
6390 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
6391 Bernd Edlinger <bernd.edlinger@hotmail.de>
6392 Tom Tromey <tromey@adacore.com>
6393
6394 * buildsym.c (buildsym_compunit::record_line): Remove
6395 deduplication code.
6396
6397 2020-04-02 Tom de Vries <tdevries@suse.de>
6398
6399 PR ada/24671
6400 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
6401
6402 2020-04-02 Tom de Vries <tdevries@suse.de>
6403
6404 * dwarf2/read.c (dwarf2_gdb_index_functions,
6405 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
6406 NULL.
6407 * psymtab.c (psym_lookup_global_symbol_language): New function.
6408 (psym_functions): Init psym_lookup_global_symbol_language with
6409 psym_lookup_global_symbol_language.
6410 * symfile-debug.c (debug_sym_quick_functions): Init
6411 lookup_global_symbol_language with NULL.
6412 * symfile.c (set_initial_language): Remove fixme comment.
6413 * symfile.h (struct quick_symbol_functions): Add
6414 lookup_global_symbol_language.
6415 * symtab.c (find_quick_global_symbol_language): New function.
6416 (find_main_name): Use find_quick_global_symbol_language.
6417
6418 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6419
6420 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
6421
6422 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
6423
6424 * buildsym.c (record_line): Fix undefined behavior and preserve
6425 lines at eof.
6426
6427 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
6428
6429 * buildsym.c (record_line): Fix the resizing condition.
6430
6431 2020-04-01 Tom Tromey <tom@tromey.com>
6432
6433 * value.h (value_literal_complex): Add comment.
6434 * valops.c (value_literal_complex): Refer to value.h.
6435
6436 2020-04-01 Tom Tromey <tom@tromey.com>
6437
6438 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
6439 (scalar_type): New rule, from typebase.
6440 (typebase): Use scalar_type. Recognize complex types.
6441 (field_name): Handle FLOAT_KEYWORD.
6442 (ident_tokens): Add _Complex and __complex__.
6443
6444 2020-04-01 Tom Tromey <tom@tromey.com>
6445
6446 PR exp/25299:
6447 * valarith.c (promotion_type, complex_binop): New functions.
6448 (scalar_binop): Handle complex numbers. Use promotion_type.
6449 (value_pos, value_neg, value_complement): Handle complex numbers.
6450
6451 2020-04-01 Tom Tromey <tom@tromey.com>
6452
6453 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
6454 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
6455 (parse_number): Handle complex numbers.
6456
6457 2020-04-01 Tom Tromey <tom@tromey.com>
6458
6459 * c-valprint.c (c_decorations): Change complex suffix to "i".
6460
6461 2020-04-01 Tom Tromey <tom@tromey.com>
6462
6463 * valprint.c (generic_value_print_complex): Use accessors.
6464 * value.h (value_real_part, value_imaginary_part): Declare.
6465 * valops.c (value_real_part, value_imaginary_part): New
6466 functions.
6467 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
6468
6469 2020-04-01 Tom Tromey <tom@tromey.com>
6470
6471 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
6472 (read_range_type): Update.
6473 * mdebugread.c (basic_type): Update.
6474 * go-lang.c (build_go_types): Use init_complex_type.
6475 * gdbtypes.h (struct main_type) <complex_type>: New member.
6476 (init_complex_type): Update.
6477 (arch_complex_type): Don't declare.
6478 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
6479 Make name if none given. Use alloc_type_copy. Look for cached
6480 complex type.
6481 (arch_complex_type): Remove.
6482 (gdbtypes_post_init): Use init_complex_type.
6483 * f-lang.c (build_fortran_types): Use init_complex_type.
6484 * dwarf2/read.c (read_base_type): Update.
6485 * d-lang.c (build_d_types): Use init_complex_type.
6486 * ctfread.c (read_base_type): Update.
6487
6488 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6489
6490 * infrun.c (stop_all_threads): Update assertion, plus when
6491 stopping threads, take into account that we might be trying
6492 to stop an all-stop target.
6493 (stop_waiting): Call 'stop_all_threads' if there exists a
6494 non-stop target.
6495
6496 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6497
6498 * target.h (exists_non_stop_target): New function declaration.
6499 * target.c (exists_non_stop_target): New function.
6500
6501 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
6502
6503 PR gdb/24789
6504 * eval.c (is_integral_or_integral_reference): New function.
6505 (evaluate_subexp_standard): Allow integer references in
6506 pointer arithmetic.
6507
6508 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6509
6510 * remote.c (remote_target::remote_parse_stop_reply): Remove the
6511 check for no ptid in the stop reply when the target is non-stop.
6512
6513 2020-04-01 Tom Tromey <tromey@adacore.com>
6514
6515 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
6516 "name" parameter to rvalue reference. Initialize m_name_holder.
6517 <lookup_name_info>: New overloads.
6518 <name>: Return gdb::string_view.
6519 <c_str>: New method.
6520 <make_ignore_params>: Update.
6521 <search_name_hash>: Update.
6522 <language_lookup_name>: Return const char *.
6523 <m_name>: Change type.
6524 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
6525 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
6526 (lookup_name_info::match_any): Update.
6527 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
6528 Update.
6529 * minsyms.c (linkage_name_str): Update.
6530 * language.c (default_symbol_name_matcher): Update.
6531 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
6532 Update.
6533 * ada-lang.c (ada_fold_name): Change parameter to string_view.
6534 (ada_lookup_name_info::ada_lookup_name_info): Update.
6535 (literal_symbol_name_matcher): Update.
6536
6537 2020-04-01 Tom Tromey <tromey@adacore.com>
6538
6539 * psymtab.c (psymtab_search_name): Remove function.
6540 (psym_lookup_symbol): Create search name and lookup name here.
6541 (lookup_partial_symbol): Remove "name" parameter; add
6542 lookup_name.
6543 (psym_expand_symtabs_for_function): Update.
6544
6545 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
6546
6547 PR tui/25597:
6548 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
6549
6550 2020-03-31 Tom Tromey <tromey@adacore.com>
6551
6552 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
6553 memcpy.
6554
6555 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
6556
6557 * features/riscv/32bit-csr.xml: Regenerated.
6558 * features/riscv/64bit-csr.xml: Regenerated.
6559
6560 2020-03-30 Tom Tromey <tromey@adacore.com>
6561
6562 * ada-valprint.c (print_variant_part): Update.
6563 * ada-lang.h (ada_which_variant_applies): Update.
6564 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
6565 outer_valaddr parameters; replace with "outer" value parameter.
6566 (to_fixed_variant_branch_type): Update.
6567
6568 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6569
6570 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
6571 <list>. Remove inclusion of observable.h.
6572 (PPC_DEBUG_CURRENT_VERSION): Move up define.
6573 (struct arch_lwp_info): New struct.
6574 (class ppc_linux_dreg_interface): New class.
6575 (struct ppc_linux_process_info): New struct.
6576 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
6577 <low_new_clone, low_forget_process, low_prepare_to_resume>
6578 <copy_thread_dreg_state, mark_thread_stale>
6579 <mark_debug_registers_changed, register_hw_breakpoint>
6580 <clear_hw_breakpoint, register_wp, clear_wp>
6581 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
6582 <num_memory_accesses, get_trigger_type>
6583 <create_watchpoint_request, hwdebug_point_cmp>
6584 <init_arch_lwp_info, get_arch_lwp_info>
6585 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
6586 methods.
6587 <struct ptid_hash>: New inner struct.
6588 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
6589 members.
6590 (saved_dabr_value, hwdebug_info, max_slots_number)
6591 (struct hw_break_tuple, struct thread_points, ppc_threads)
6592 (have_ptrace_hwdebug_interface)
6593 (hwdebug_find_thread_points_by_tid)
6594 (hwdebug_insert_point, hwdebug_remove_point): Remove.
6595 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
6596 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
6597 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
6598 use m_dreg_interface.
6599 (hwdebug_point_cmp): Change to...
6600 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
6601 reference arguments instead of pointers.
6602 (ppc_linux_nat_target::ranged_break_num_registers): Use
6603 m_dreg_interface.
6604 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
6605 m_dreg_interface. Call register_hw_breakpoint.
6606 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
6607 m_dreg_interface. Call clear_hw_breakpoint.
6608 (get_trigger_type): Change to...
6609 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
6610 comment.
6611 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
6612 use m_dreg_interface. Call register_hw_breakpoint.
6613 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
6614 use m_dreg_interface. Call clear_hw_breakpoint.
6615 (can_use_watchpoint_cond_accel): Change to...
6616 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
6617 method. Update comment, use m_dreg_interface and
6618 m_process_info.
6619 (calculate_dvc): Change to...
6620 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
6621 m_dreg_interface.
6622 (num_memory_accesses): Change to...
6623 (ppc_linux_nat_target::num_memory_accesses): ...this method.
6624 (check_condition): Change to...
6625 (ppc_linux_nat_target::check_condition): ...this method.
6626 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
6627 comment, use m_dreg_interface.
6628 (create_watchpoint_request): Change to...
6629 (ppc_linux_nat_target::create_watchpoint_request): ...this
6630 method. Use m_dreg_interface.
6631 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
6632 m_dreg_interface. Call register_hw_breakpoint or register_wp.
6633 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
6634 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
6635 (ppc_linux_nat_target::low_forget_process)
6636 (ppc_linux_nat_target::low_new_fork)
6637 (ppc_linux_nat_target::low_new_clone)
6638 (ppc_linux_nat_target::low_delete_thread)
6639 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
6640 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
6641 only call mark_thread_stale.
6642 (ppc_linux_thread_exit): Remove.
6643 (ppc_linux_nat_target::stopped_data_address): Change to...
6644 (ppc_linux_nat_target::low_stopped_data_address): This. Add
6645 comment, use m_dreg_interface and m_thread_hw_breakpoints.
6646 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
6647 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
6648 comment. Call low_stopped_data_address.
6649 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
6650 m_dreg_interface.
6651 (ppc_linux_nat_target::masked_watch_num_registers): Use
6652 m_dreg_interface.
6653 (ppc_linux_nat_target::copy_thread_dreg_state)
6654 (ppc_linux_nat_target::mark_thread_stale)
6655 (ppc_linux_nat_target::mark_debug_registers_changed)
6656 (ppc_linux_nat_target::register_hw_breakpoint)
6657 (ppc_linux_nat_target::clear_hw_breakpoint)
6658 (ppc_linux_nat_target::register_wp)
6659 (ppc_linux_nat_target::clear_wp)
6660 (ppc_linux_nat_target::init_arch_lwp_info)
6661 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
6662 (_initialize_ppc_linux_nat): Remove observer callback.
6663
6664 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6665
6666 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
6667 (ppc_linux_nat_target::auxv_parse)
6668 (ppc_linux_nat_target::read_description)
6669 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
6670 Move up.
6671
6672 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6673
6674 * linux-nat.h (low_new_clone): New method.
6675 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
6676
6677 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6678
6679 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
6680 (dbx_expand_psymtab): ... this.
6681 (start_psymtab): Update.
6682 * mdebugread.c (psymtab_to_symtab_1): Rename to...
6683 (mdebug_expand_psymtab): ... this.
6684 (parse_partial_symbols): Update.
6685 (new_psymtab): Update.
6686 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
6687 (xcoff_expand_psymtab): ... this.
6688 (xcoff_start_psymtab): Update.
6689
6690 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6691
6692 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
6693 <expand_dependencies>: ... this.
6694 * psymtab.c (partial_symtab::read_dependencies): Rename to...
6695 (partial_symtab::expand_dependencies): ... this.
6696 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
6697 Update.
6698 (dwarf2_psymtab::expand_psymtab): Update.
6699 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
6700 * mdebugread.c (psymtab_to_symtab_1): Update.
6701 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6702
6703 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6704
6705 * psympriv.h (discard_psymtab): Remove.
6706 * dbxread.c (dbx_end_psymtab): Update.
6707 * xcoffread.c (xcoff_end_psymtab): Update.
6708
6709 2020-03-28 Tom Tromey <tom@tromey.com>
6710
6711 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
6712 comment.
6713
6714 2020-03-28 Tom Tromey <tom@tromey.com>
6715
6716 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
6717
6718 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
6719
6720 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6721
6722 2020-03-26 John Baldwin <jhb@FreeBSD.org>
6723
6724 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
6725
6726 2020-03-26 Tom Tromey <tom@tromey.com>
6727
6728 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
6729 (mark_common_block_symbol_computed, read_tag_string_type)
6730 (attr_to_dynamic_prop, read_subrange_type): Update.
6731 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
6732 to be methods on struct attribute.
6733 (skip_one_die, process_imported_unit_die, read_namespace_alias)
6734 (read_call_site_scope, partial_die_info::read)
6735 (partial_die_info::read, lookup_die_type, follow_die_ref):
6736 Update.
6737 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
6738 from dwarf2_get_ref_die_offset.
6739 (attribute::constant_value): New method, from
6740 dwarf2_get_attr_constant_value.
6741 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
6742 Declare method.
6743 <constant_value>: New method.
6744
6745 2020-03-26 Tom Tromey <tom@tromey.com>
6746
6747 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
6748 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
6749 (dwarf_type_encoding_name): Move to stringify.c.
6750 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
6751 * dwarf2/stringify.c: New file.
6752 * dwarf2/stringify.h: New file.
6753
6754 2020-03-26 Tom Tromey <tom@tromey.com>
6755
6756 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
6757 Rewrite.
6758
6759 2020-03-26 Tom Tromey <tom@tromey.com>
6760
6761 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
6762 methods.
6763 * dwarf2/read.c (lookup_addr_base): Move to die.h.
6764 (lookup_ranges_base): Likewise.
6765 (read_cutu_die_from_dwo, read_full_die_1): Update.
6766
6767 2020-03-26 Tom Tromey <tom@tromey.com>
6768
6769 * dwarf2/read.c (read_import_statement, read_file_scope)
6770 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
6771 (read_lexical_block_scope, read_call_site_scope)
6772 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
6773 (handle_struct_member_die, process_structure_scope)
6774 (update_enumeration_type_from_children)
6775 (process_enumeration_scope, read_array_type, read_common_block)
6776 (read_namespace, read_module, read_subroutine_type): Update.
6777 (sibling_die): Remove.
6778
6779 2020-03-26 Tom Tromey <tom@tromey.com>
6780
6781 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
6782 (build_type_psymtabs_reader, read_structure_type)
6783 (read_enumeration_type, read_full_die_1): Update.
6784 (dwarf2_attr_no_follow): Move to die.h.
6785 * dwarf2/die.h (struct die_info) <attr>: New method.
6786
6787 2020-03-26 Tom Tromey <tom@tromey.com>
6788
6789 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
6790 <base_address>: Now an optional.
6791 (dwarf2_find_base_address, dwarf2_rnglists_process)
6792 (dwarf2_ranges_process, fill_in_loclist_baton)
6793 (dwarf2_symbol_mark_computed): Update.
6794
6795 2020-03-26 Tom Tromey <tom@tromey.com>
6796
6797 * dwarf2/read.c (struct die_info): Move to die.h.
6798 * dwarf2/die.h: New file.
6799
6800 2020-03-26 Tom Tromey <tom@tromey.com>
6801
6802 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
6803 * dwarf2/read.c
6804 (dwarf2_statement_list_fits_in_line_number_section_complaint):
6805 Move to line-header.c.
6806 (read_checked_initial_length_and_offset, read_formatted_entries):
6807 Likewise.
6808 (dwarf_decode_line_header): Split into two.
6809 * dwarf2/line-header.c
6810 (dwarf2_statement_list_fits_in_line_number_section_complaint):
6811 Move from read.c.
6812 (read_checked_initial_length_and_offset, read_formatted_entries):
6813 Likewise.
6814 (dwarf_decode_line_header): New function, split from read.c.
6815
6816 2020-03-26 Tom Tromey <tom@tromey.com>
6817
6818 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
6819 Declare method.
6820 * dwarf2/read.c (read_attribute_value): Update.
6821 (dwarf2_per_objfile::read_line_string): Rename from
6822 read_indirect_line_string.
6823 (read_formatted_entries): Update.
6824
6825 2020-03-26 Tom Tromey <tom@tromey.com>
6826
6827 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
6828 variable.
6829
6830 2020-03-26 Tom Tromey <tom@tromey.com>
6831
6832 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
6833 const.
6834 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
6835 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
6836 parameter const.
6837
6838 2020-03-26 Tom Tromey <tom@tromey.com>
6839
6840 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
6841 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
6842 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
6843 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
6844
6845 2020-03-26 Tom Tromey <tom@tromey.com>
6846
6847 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
6848 file_names_size, file_full_name, file_file_name>: Use const.
6849 <file_name_at, file_names>: Add const overload.
6850 * dwarf2/line-header.c (line_header::file_file_name)
6851 (line_header::file_full_name): Update.
6852
6853 2020-03-26 Tom Tromey <tom@tromey.com>
6854
6855 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
6856 (macro_start_file, consume_improper_spaces)
6857 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
6858 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
6859 (dwarf_decode_macros): Move to macro.c.
6860 * dwarf2/macro.c: New file.
6861 * dwarf2/macro.h: New file.
6862 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
6863
6864 2020-03-26 Tom Tromey <tom@tromey.com>
6865
6866 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
6867 method.
6868 * dwarf2/section.c: New method. From
6869 read_indirect_string_at_offset_from.
6870 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
6871 (read_indirect_string_at_offset_from): Move to section.c.
6872 (read_indirect_string_at_offset): Rewrite.
6873 (read_indirect_line_string_at_offset): Remove.
6874 (read_indirect_string, read_indirect_line_string)
6875 (dwarf_decode_macro_bytes): Update.
6876
6877 2020-03-26 Tom Tromey <tom@tromey.com>
6878
6879 * dwarf2/section.h (struct dwarf2_section_info)
6880 <overload_complaint>: Declare.
6881 (dwarf2_section_buffer_overflow_complaint): Don't declare.
6882 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
6883 Rename from dwarf2_section_buffer_overflow_complaint.
6884 * dwarf2/read.c (skip_one_die, partial_die_info::read)
6885 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
6886
6887 2020-03-26 Tom Tromey <tom@tromey.com>
6888
6889 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
6890 Declare.
6891 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
6892 Move from read.c.
6893 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
6894 to section.c.
6895
6896 2020-03-26 Tom Tromey <tom@tromey.com>
6897
6898 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
6899
6900 2020-03-26 Tom Tromey <tom@tromey.com>
6901
6902 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
6903 "builder".
6904 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
6905 parameter.
6906 (dwarf_decode_macros): Update.
6907
6908 2020-03-26 Tom Tromey <tom@tromey.com>
6909
6910 * dwarf2/read.c (read_attribute_value): Update.
6911 (read_indirect_string_from_dwz): Move to dwz.c; change into
6912 method.
6913 (dwarf_decode_macro_bytes): Update.
6914 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
6915 * dwarf2/dwz.c: New file.
6916 * Makefile.in (COMMON_SFILES): Add dwz.c.
6917
6918 2020-03-26 Tom Tromey <tom@tromey.com>
6919
6920 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
6921 * dwarf2/read.c: Add include.
6922 * dwarf2/index-write.c: Add include.
6923 * dwarf2/index-cache.c: Add include.
6924 * dwarf2/dwz.h: New file.
6925
6926 2020-03-25 Tom Tromey <tom@tromey.com>
6927
6928 * compile/compile-object-load.c (get_out_value_type): Mention
6929 correct symbol name in error message.
6930
6931 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
6932
6933 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6934
6935 2020-03-25 Tom de Vries <tdevries@suse.de>
6936
6937 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
6938 * symmisc.c (dump_symtab_1): Print user and includes fields.
6939 (maintenance_info_symtabs): Same.
6940
6941 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
6942
6943 PR gdb/25534
6944 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
6945 (riscv_regcache_cooked_write): New function.
6946 (riscv_push_dummy_call): Use new function.
6947 (riscv_return_value): Likewise.
6948
6949 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
6950
6951 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
6952 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
6953 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
6954 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
6955 * infrun.c (follow_fork): Likewise.
6956 (follow_fork_inferior): Likewise.
6957 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
6958 * linux-nat.h (class linux_nat_target): Likewise.
6959 * remote.c (class remote_target) <follow_fork>: Likewise.
6960 (remote_target::follow_fork): Likewise.
6961 * target-delegates.c: Re-generate.
6962 * target.c (default_follow_fork): Likewise.
6963 (target_follow_fork): Likewise.
6964 * target.h (struct target_ops) <follow_fork>: Likewise.
6965 (target_follow_fork): Likewise.
6966
6967 2020-03-24 Tom de Vries <tdevries@suse.de>
6968
6969 * psymtab.c (maintenance_info_psymtabs): Print user field.
6970
6971 2020-03-20 Tom Tromey <tromey@adacore.com>
6972
6973 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
6974 const.
6975 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
6976 const.
6977
6978 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
6979
6980 * ptrace.m4: Don't check for ptrace declaration.
6981 * config.in: Re-generate.
6982 * configure: Re-generate.
6983 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
6984 not defined.
6985
6986 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6987
6988 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
6989 `PTRACE_TYPE_RET'.
6990 * i386-bsd-nat.c (gdb_ptrace): Likewise.
6991 * sparc-nat.c (gdb_ptrace): Likewise.
6992 * x86-bsd-nat.c (gdb_ptrace): Likewise.
6993
6994 2020-03-20 Tom Tromey <tromey@adacore.com>
6995
6996 * c-exp.y (lex_one_token): Fix assert.
6997
6998 2020-03-20 Tom Tromey <tromey@adacore.com>
6999
7000 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
7001 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
7002 strncpy call.
7003
7004 2020-03-20 Tom Tromey <tromey@adacore.com>
7005
7006 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
7007
7008 2020-03-20 Tom Tromey <tromey@adacore.com>
7009
7010 * ada-valprint.c (print_variant_part): Remove parameters; switch
7011 to value-based API.
7012 (print_field_values): Likewise.
7013 (ada_val_print_struct_union): Likewise.
7014 (ada_value_print_1): Update.
7015
7016 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7017
7018 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
7019 nbsd_nat_target instead of inf_ptrace_target.
7020 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7021 nbsd_nat_target.
7022
7023 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7024
7025 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
7026 it to the ptrace call.
7027 * (store_registers): Likewise.
7028
7029 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7030
7031 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
7032 it to the ptrace call.
7033 * (store_registers): Likewise.
7034
7035 2020-03-19 Luis Machado <luis.machado@linaro.org>
7036
7037 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
7038 valid, fetch vg value from ptrace.
7039
7040 2020-03-19 Kamil Rytarowski <n54@gmx.com>
7041 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
7042 * inf-ptrace.c: Likewise.
7043 * (gdb_ptrace): Add.
7044 * (inf_ptrace_target::resume): Update.
7045 * (inf_ptrace_target::xfer_partial): Likewise.
7046 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
7047 * (inf_ptrace_peek_poke): Update.
7048
7049 2020-03-19 Kamil Rytarowski <n54@gmx.com>
7050
7051 * x86-bsd-nat.c (gdb_ptrace): New.
7052 * (x86bsd_dr_set): Add new argument `ptid'.
7053 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
7054 x86bsd_dr_set_addr): Update.
7055
7056 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7057
7058 * remote.c (remote_target::process_stop_reply): Handle events for
7059 all threads differently.
7060
7061 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7062
7063 * completer.c (completion_tracker::remove_completion): Define new
7064 function.
7065 * completer.h (completion_tracker::remove_completion): Declare new
7066 function.
7067 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
7068 when adding a C++ function symbol.
7069
7070 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7071
7072 * completer.c (completion_tracker::completion_hash_entry): Define
7073 new class.
7074 (advance_to_filename_complete_word_point): Call
7075 recompute_lowest_common_denominator.
7076 (completion_tracker::completion_tracker): Call discard_completions
7077 to setup the hash table.
7078 (completion_tracker::discard_completions): Allow for being called
7079 from the constructor, pass new equal function, and element deleter
7080 when constructing the hash table. Initialise new class member
7081 variables.
7082 (completion_tracker::maybe_add_completion): Remove use of
7083 m_entries_vec, and store more information into m_entries_hash.
7084 (completion_tracker::recompute_lcd_visitor): New function, most
7085 content taken from...
7086 (completion_tracker::recompute_lowest_common_denominator):
7087 ...here, this now just visits each item in the hash calling the
7088 above visitor.
7089 (completion_tracker::build_completion_result): Remove use of
7090 m_entries_vec, call recompute_lowest_common_denominator.
7091 * completer.h (completion_tracker::have_completions): Remove use
7092 of m_entries_vec.
7093 (completion_tracker::completion_hash_entry): Declare new class.
7094 (completion_tracker::recompute_lowest_common_denominator): Change
7095 function signature.
7096 (completion_tracker::recompute_lcd_visitor): Declare new function.
7097 (completion_tracker::m_entries_vec): Delete.
7098 (completion_tracker::m_entries_hash): Initialize to NULL.
7099 (completion_tracker::m_lowest_common_denominator_valid): New
7100 member variable.
7101 (completion_tracker::m_lowest_common_denominator_max_length): New
7102 member variable.
7103
7104 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7105
7106 * regformats/regdef.h: Put reg in gdb namespace.
7107
7108 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7109
7110 * i386-bsd-nat.c (gdb_ptrace): New.
7111 * (i386bsd_fetch_inferior_registers,
7112 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
7113 * (i386bsd_fetch_inferior_registers,
7114 i386bsd_store_inferior_registers) Use gdb_ptrace.
7115
7116 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7117
7118 * amd64-bsd-nat.c (gdb_ptrace): New.
7119 * (amd64bsd_fetch_inferior_registers,
7120 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
7121 * (amd64bsd_fetch_inferior_registers,
7122 amd64bsd_store_inferior_registers) Use gdb_ptrace.
7123
7124 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7125
7126 * user-regs.c (user_reg::read): Rename to...
7127 (user_reg::xread): ...this.
7128 * (append_user_reg): Rename argument `read' to `xread'.
7129 * (user_reg_add_builtin): Likewise.
7130 * (user_reg_add): Likewise.
7131 * (value_of_user_reg): Likewise.
7132
7133 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7134
7135 * sparc-nat.c (gdb_ptrace): New.
7136 * sparc-nat.c (sparc_fetch_inferior_registers)
7137 (sparc_store_inferior_registers) Remove obsolete comment.
7138 * sparc-nat.c (sparc_fetch_inferior_registers)
7139 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
7140 * sparc-nat.c (sparc_fetch_inferior_registers)
7141 (sparc_store_inferior_registers) Use gdb_ptrace.
7142
7143 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7144
7145 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
7146 it to the ptrace call.
7147 * sh-nbsd-nat.c (store_registers): Likewise.
7148
7149 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7150
7151 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
7152 nbsd_nat_target instead of inf_ptrace_target.
7153 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7154 nbsd_nat_target.
7155
7156 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7157
7158 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
7159
7160 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7161
7162 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
7163 <sys/sysctl.h>.
7164 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
7165
7166 2020-03-17 Tom de Vries <tdevries@suse.de>
7167
7168 PR gdb/23710
7169 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
7170 fields.
7171 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
7172 fields.
7173 (process_imported_unit_die): Skip import of c++ CUs.
7174
7175 2020-03-16 Tom Tromey <tom@tromey.com>
7176
7177 * p-valprint.c (pascal_object_print_value): Initialize
7178 base_value.
7179
7180 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
7181 Shahab Vahedi <shahab@synopsys.com>
7182
7183 * Makefile.in: Add arch/arc.o
7184 * configure.tgt: Likewise.
7185 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
7186 (_initialize_arc_tdep): Don't initialize old target descriptions.
7187 (arc_read_description): New function to cache target descriptions.
7188 * arc-tdep.h (arc_read_description): Add proto type.
7189 * arch/arc.c: New file.
7190 * arch/arc.h: Likewise.
7191 * features/Makefile: Replace old target descriptions with new.
7192 * features/arc-arcompact.c: Remove.
7193 * features/arc-arcompact.xml: Likewise.
7194 * features/arc-v2.c: Likewise
7195 * features/arc-v2.xml: Likewise
7196 * features/arc/aux-arcompact.xml: New file.
7197 * features/arc/aux-v2.xml: Likewise.
7198 * features/arc/core-arcompact.xml: Likewise.
7199 * features/arc/core-v2.xml: Likewise.
7200 * features/arc/aux-arcompact.c: Generate.
7201 * features/arc/aux-v2.c: Likewise.
7202 * features/arc/core-arcompact.c: Likewise.
7203 * features/arc/core-v2.c: Likewise.
7204 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
7205
7206 2020-03-16 Tom Tromey <tromey@adacore.com>
7207
7208 PR gdb/25663:
7209 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
7210 putting value into bcache.
7211
7212 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7213
7214 PR gdb/21500
7215 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
7216 to...
7217 (amd64_windows_init_abi_common): ... this. Don't set size of
7218 long type.
7219 (amd64_windows_init_abi): New function.
7220 (amd64_cygwin_init_abi): New function.
7221 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
7222 the Cygwin OS ABI.
7223 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
7224 comment.
7225
7226 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7227
7228 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
7229 * windows-tdep.c (CYGWIN_DLL_NAME): New.
7230 (pe_import_directory_entry): New struct type.
7231 (is_linked_with_cygwin_dll): New function.
7232 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
7233 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
7234 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
7235
7236 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7237
7238 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
7239 i386_cygwin_core_osabi_sniffer.
7240
7241 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7242
7243 * i386-cygwin-tdep.c: Rename to...
7244 * i386-windows-tdep.c: ... this.
7245 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
7246 i386-windows-tdep.c.
7247 * configure.tgt: Likewise.
7248
7249 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7250
7251 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
7252 * osabi.c (gdb_osabi_names): Add "Windows".
7253 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
7254 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
7255 (i386_cygwin_core_osabi_sniffer): New function, extracted from
7256 i386_cygwin_osabi_sniffer.
7257 (_initialize_i386_cygwin_tdep): Register OS ABI
7258 GDB_OSABI_WINDOWS for i386.
7259 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
7260 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
7261 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
7262 for x86-64.
7263 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
7264 when the target matches '*-*-mingw*'.
7265
7266 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7267
7268 * defs.h (enum gdb_osabi): Move to...
7269 * osabi.h (enum gdb_osabi): ... here.
7270 * gdbarch.sh: Include osabi.h in gdbarch.h.
7271 * gdbarch.h: Re-generate.
7272
7273 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7274
7275 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
7276 function.
7277 (_initialize_amd64_windows_tdep): Register osabi sniffer.
7278
7279 2020-03-14 Tom Tromey <tom@tromey.com>
7280
7281 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
7282 for C++.
7283 (c_type_print_modifier): Likewise. Add "language" parameter.
7284 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
7285 (c_type_print_base_1): Update.
7286 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
7287 constants.
7288 * type-stack.c (type_stack::insert): Handle tp_atomic and
7289 tp_restrict.
7290 (type_stack::follow_type_instance_flags): Likewise.
7291 (type_stack::follow_types): Likewise. Merge type-following code.
7292 * c-exp.y (RESTRICT, ATOMIC): New tokens.
7293 (space_identifier, cv_with_space_id)
7294 (const_or_volatile_or_space_identifier_noopt)
7295 (const_or_volatile_or_space_identifier): Remove.
7296 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
7297 rules.
7298 (ptr_operator, typebase): Update.
7299 (enum token_flag) <FLAG_C>: New constant.
7300 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
7301 "_Atomic".
7302 (lex_one_token): Handle FLAG_C.
7303
7304 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7305
7306 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
7307 it to the ptrace call.
7308 * m68k-bsd-nat.c (store_registers): Likewise.
7309
7310 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7311
7312 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
7313 gdb_byte *.
7314 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
7315 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
7316 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
7317
7318 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7319
7320 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
7321 nbsd_nat_target instead of inf_ptrace_target.
7322 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7323 nbsd_nat_target.
7324
7325 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7326
7327 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
7328 register_t.
7329
7330 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7331
7332 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
7333 it to the ptrace call.
7334 * alpha-bsd-nat.c (store_registers): Likewise.
7335
7336 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7337
7338 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
7339 includes.
7340 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
7341 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
7342 fill_fpregset): Likewise.
7343
7344 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7345
7346 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
7347 nbsd_nat_target instead of inf_ptrace_target.
7348 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7349 nbsd_nat_target.
7350
7351 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7352
7353 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
7354 register_t.
7355
7356 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7357
7358 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
7359 it to the ptrace call.
7360 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
7361 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
7362 * arm-nbsd-nat.c (store_register): Likewise.
7363 * arm-nbsd-nat.c (store_regs): Likewise.
7364 * arm-nbsd-nat.c (store_fp_register): Likewise.
7365 * arm-nbsd-nat.c (store_fp_regs): Likewise.
7366
7367 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7368
7369 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
7370 nbsd_nat_target instead of inf_ptrace_target.
7371 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7372 nbsd_nat_target.
7373
7374 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7375
7376 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
7377 it to the ptrace call.
7378 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
7379
7380 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7381
7382 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
7383 it to the ptrace call.
7384 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
7385
7386 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7387
7388 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
7389 gdb_byte *.
7390 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
7391
7392 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7393
7394 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
7395 instead of inf_ptrace_target.
7396 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7397 nbsd_nat_target.
7398
7399 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7400
7401 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
7402 register_t.
7403
7404 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7405
7406 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
7407 register_t.
7408
7409 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7410
7411 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
7412 register_t.
7413
7414 2020-03-13 Tom Tromey <tom@tromey.com>
7415
7416 * value.h (val_print): Don't declare.
7417 * valprint.h (val_print_array_elements)
7418 (val_print_scalar_formatted, generic_val_print): Don't declare.
7419 * valprint.c (generic_val_print_array): Take a struct value.
7420 (generic_val_print_ptr, generic_val_print_memberptr)
7421 (generic_val_print_bool, generic_val_print_int)
7422 (generic_val_print_char, generic_val_print_complex)
7423 (generic_val_print): Remove.
7424 (generic_value_print): Update.
7425 (do_val_print): Remove unused parameters. Don't call
7426 la_val_print.
7427 (val_print): Remove.
7428 (common_val_print): Update. Don't call value_check_printable.
7429 (val_print_scalar_formatted, val_print_array_elements): Remove.
7430 * rust-lang.c (rust_val_print): Remove.
7431 (rust_language_defn): Update.
7432 * p-valprint.c (pascal_val_print): Remove.
7433 (pascal_value_print_inner): Update.
7434 (pascal_object_print_val_fields, pascal_object_print_val):
7435 Remove.
7436 (pascal_object_print_static_field): Update.
7437 * p-lang.h (pascal_val_print): Don't declare.
7438 * p-lang.c (pascal_language_defn): Update.
7439 * opencl-lang.c (opencl_language_defn): Update.
7440 * objc-lang.c (objc_language_defn): Update.
7441 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
7442 * m2-lang.h (m2_val_print): Don't declare.
7443 * m2-lang.c (m2_language_defn): Update.
7444 * language.h (struct language_defn) <la_val_print>: Remove.
7445 * language.c (unk_lang_value_print_inner): Rename. Change
7446 argument types.
7447 (unknown_language_defn, auto_language_defn): Update.
7448 * go-valprint.c (go_val_print): Remove.
7449 * go-lang.h (go_val_print): Don't declare.
7450 * go-lang.c (go_language_defn): Update.
7451 * f-valprint.c (f_val_print): Remove.
7452 * f-lang.h (f_value_print): Don't declare.
7453 * f-lang.c (f_language_defn): Update.
7454 * d-valprint.c (d_val_print): Remove.
7455 * d-lang.h (d_value_print): Don't declare.
7456 * d-lang.c (d_language_defn): Update.
7457 * cp-valprint.c (cp_print_value_fields)
7458 (cp_print_value_fields_rtti, cp_print_value): Remove.
7459 (cp_print_static_field): Update.
7460 * c-valprint.c (c_val_print_array, c_val_print_ptr)
7461 (c_val_print_struct, c_val_print_union, c_val_print_int)
7462 (c_val_print_memberptr, c_val_print): Remove.
7463 * c-lang.h (c_val_print_array, cp_print_value_fields)
7464 (cp_print_value_fields_rtti): Don't declare.
7465 * c-lang.c (c_language_defn, cplus_language_defn)
7466 (asm_language_defn, minimal_language_defn): Update.
7467 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
7468 (ada_val_print_enum): Take a struct value.
7469 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
7470 (ada_val_print): Remove.
7471 (ada_value_print_1): Update.
7472 (printable_val_type): Remove.
7473 * ada-lang.h (ada_val_print): Don't declare.
7474 * ada-lang.c (ada_language_defn): Update.
7475
7476 2020-03-13 Tom Tromey <tom@tromey.com>
7477
7478 * valprint.c (do_val_print): Update.
7479 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
7480 a struct value.
7481 (value_to_value_object_no_release): Declare.
7482 * python/py-value.c (value_to_value_object_no_release): New
7483 function.
7484 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
7485 struct value.
7486 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
7487 function.
7488 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
7489 a struct value.
7490 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
7491 Declare.
7492 (gdbscm_apply_val_pretty_printer): Take a struct value.
7493 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
7494 value.
7495 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
7496 value.
7497 * extension-priv.h (struct extension_language_ops)
7498 <apply_val_pretty_printer>: Take a struct value.
7499 * cp-valprint.c (cp_print_value): Create a struct value.
7500 (cp_print_value): Update.
7501
7502 2020-03-13 Tom Tromey <tom@tromey.com>
7503
7504 * ada-valprint.c (print_field_values): Call common_val_print.
7505
7506 2020-03-13 Tom Tromey <tom@tromey.com>
7507
7508 * ada-valprint.c (val_print_packed_array_elements): Remove
7509 bitoffset and val parameters. Call common_val_print.
7510 (ada_val_print_string): Remove offset, address, and original_value
7511 parameters.
7512 (ada_val_print_array): Update.
7513 (ada_value_print_array): New function.
7514 (ada_value_print_1): Call it.
7515
7516 2020-03-13 Tom Tromey <tom@tromey.com>
7517
7518 * ada-valprint.c (ada_value_print): Use common_val_print.
7519
7520 2020-03-13 Tom Tromey <tom@tromey.com>
7521
7522 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
7523
7524 2020-03-13 Tom Tromey <tom@tromey.com>
7525
7526 * ada-valprint.c (ada_value_print_num): New function.
7527 (ada_value_print_1): Use it.
7528
7529 2020-03-13 Tom Tromey <tom@tromey.com>
7530
7531 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
7532
7533 2020-03-13 Tom Tromey <tom@tromey.com>
7534
7535 * ada-valprint.c (ada_value_print_ptr): New function.
7536 (ada_value_print_1): Use it.
7537
7538 2020-03-13 Tom Tromey <tom@tromey.com>
7539
7540 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
7541 call common_val_print.
7542 (ada_val_print_1): Update.
7543 (ada_value_print_1): New function.
7544 (ada_value_print_inner): Rewrite.
7545
7546 2020-03-13 Tom Tromey <tom@tromey.com>
7547
7548 * cp-valprint.c (cp_print_value_fields): Update.
7549 (cp_print_value): New function.
7550
7551 2020-03-13 Tom Tromey <tom@tromey.com>
7552
7553 * m2-valprint.c (m2_value_print_inner): Use
7554 cp_print_value_fields.
7555 * cp-valprint.c (cp_print_value_fields): New function.
7556 * c-valprint.c (c_value_print_struct): New function.
7557 (c_value_print_inner): Use c_value_print_struct.
7558 * c-lang.h (cp_print_value_fields): Declare.
7559
7560 2020-03-13 Tom Tromey <tom@tromey.com>
7561
7562 * c-valprint.c (c_value_print_array): New function.
7563 (c_value_print_inner): Use it.
7564
7565 2020-03-13 Tom Tromey <tom@tromey.com>
7566
7567 * c-valprint.c (c_value_print_memberptr): New function.
7568 (c_value_print_inner): Use it.
7569
7570 2020-03-13 Tom Tromey <tom@tromey.com>
7571
7572 * c-valprint.c (c_value_print_int): New function.
7573 (c_value_print_inner): Use it.
7574
7575 2020-03-13 Tom Tromey <tom@tromey.com>
7576
7577 * c-valprint.c (c_value_print_ptr): New function.
7578 (c_value_print_inner): Use it.
7579
7580 2020-03-13 Tom Tromey <tom@tromey.com>
7581
7582 * c-valprint.c (c_value_print_inner): Rewrite.
7583
7584 2020-03-13 Tom Tromey <tom@tromey.com>
7585
7586 * valprint.c (generic_value_print_complex): New function.
7587 (generic_value_print): Use it.
7588
7589 2020-03-13 Tom Tromey <tom@tromey.com>
7590
7591 * valprint.c (generic_val_print_float): Don't call
7592 val_print_scalar_formatted.
7593 (generic_val_print, generic_value_print): Update.
7594
7595 2020-03-13 Tom Tromey <tom@tromey.com>
7596
7597 * valprint.c (generic_value_print_char): New function
7598 (generic_value_print): Use it.
7599
7600 2020-03-13 Tom Tromey <tom@tromey.com>
7601
7602 * valprint.c (generic_value_print_int): New function.
7603 (generic_value_print): Use it.
7604
7605 2020-03-13 Tom Tromey <tom@tromey.com>
7606
7607 * valprint.c (generic_value_print_bool): New function.
7608 (generic_value_print): Use it.
7609
7610 2020-03-13 Tom Tromey <tom@tromey.com>
7611
7612 * valprint.c (generic_val_print_func): Simplify.
7613 (generic_val_print, generic_value_print): Update.
7614
7615 2020-03-13 Tom Tromey <tom@tromey.com>
7616
7617 * valprint.c (generic_val_print_flags): Remove.
7618 (generic_val_print, generic_value_print): Update.
7619 (val_print_type_code_flags): Add original_value parameter.
7620
7621 2020-03-13 Tom Tromey <tom@tromey.com>
7622
7623 * valprint.c (generic_val_print): Update.
7624 (generic_value_print): Update.
7625 * valprint.c (generic_val_print_enum): Don't call
7626 val_print_scalar_formatted.
7627
7628 2020-03-13 Tom Tromey <tom@tromey.com>
7629
7630 * valprint.c (generic_value_print): Call generic_value_print_ptr.
7631 * valprint.c (generic_value_print_ptr): New function.
7632
7633 2020-03-13 Tom Tromey <tom@tromey.com>
7634
7635 * valprint.c (generic_value_print): Rewrite.
7636
7637 2020-03-13 Tom Tromey <tom@tromey.com>
7638
7639 * p-valprint.c (pascal_object_print_value_fields)
7640 (pascal_object_print_value): New functions.
7641
7642 2020-03-13 Tom Tromey <tom@tromey.com>
7643
7644 * p-valprint.c (pascal_value_print_inner): Rewrite.
7645
7646 2020-03-13 Tom Tromey <tom@tromey.com>
7647
7648 * f-valprint.c (f_value_print_innner): Rewrite.
7649
7650 2020-03-13 Tom Tromey <tom@tromey.com>
7651
7652 * m2-valprint.c (m2_print_unbounded_array): New overload.
7653 (m2_print_unbounded_array): Update.
7654 (m2_print_array_contents): Take a struct value.
7655 (m2_value_print_inner): Rewrite.
7656
7657 2020-03-13 Tom Tromey <tom@tromey.com>
7658
7659 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
7660 (d_value_print_inner): New function.
7661 * d-lang.h (d_value_print_inner): Declare.
7662 * d-lang.c (d_language_defn): Use d_value_print_inner.
7663
7664 2020-03-13 Tom Tromey <tom@tromey.com>
7665
7666 * go-valprint.c (go_value_print_inner): New function.
7667 * go-lang.h (go_value_print_inner): Declare.
7668 * go-lang.c (go_language_defn): Use go_value_print_inner.
7669
7670 2020-03-13 Tom Tromey <tom@tromey.com>
7671
7672 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
7673 API.
7674 (rust_val_print): Rewrite.
7675 (rust_value_print_inner): New function, from rust_val_print.
7676 (rust_language_defn): Use rust_value_print_inner.
7677
7678 2020-03-13 Tom Tromey <tom@tromey.com>
7679
7680 * ada-valprint.c (ada_value_print_inner): New function.
7681 * ada-lang.h (ada_value_print_inner): Declare.
7682 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
7683
7684 2020-03-13 Tom Tromey <tom@tromey.com>
7685
7686 * f-valprint.c (f_value_print_innner): New function.
7687 * f-lang.h (f_value_print_innner): Declare.
7688 * f-lang.c (f_language_defn): Use f_value_print_innner.
7689
7690 2020-03-13 Tom Tromey <tom@tromey.com>
7691
7692 * p-valprint.c (pascal_value_print_inner): New function.
7693 * p-lang.h (pascal_value_print_inner): Declare.
7694 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
7695
7696 2020-03-13 Tom Tromey <tom@tromey.com>
7697
7698 * m2-valprint.c (m2_value_print_inner): New function.
7699 * m2-lang.h (m2_value_print_inner): Declare.
7700 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
7701
7702 2020-03-13 Tom Tromey <tom@tromey.com>
7703
7704 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
7705 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
7706 * c-valprint.c (c_value_print_inner): New function.
7707 * c-lang.h (c_value_print_inner): Declare.
7708 * c-lang.c (c_language_defn, cplus_language_defn)
7709 (asm_language_defn, minimal_language_defn): Use
7710 c_value_print_inner.
7711
7712 2020-03-13 Tom Tromey <tom@tromey.com>
7713
7714 * p-valprint.c (pascal_object_print_value_fields): Now static.
7715 * p-lang.h (pascal_object_print_value_fields): Don't declare.
7716
7717 2020-03-13 Tom Tromey <tom@tromey.com>
7718
7719 * c-valprint.c (c_val_print_array): Simplify.
7720
7721 2020-03-13 Tom Tromey <tom@tromey.com>
7722
7723 * valprint.c (value_print_array_elements): New function.
7724 * valprint.h (value_print_array_elements): Declare.
7725
7726 2020-03-13 Tom Tromey <tom@tromey.com>
7727
7728 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
7729 * mips-tdep.c (mips_print_register): Use
7730 value_print_scalar_formatted.
7731
7732 2020-03-13 Tom Tromey <tom@tromey.com>
7733
7734 * valprint.h (value_print_scalar_formatted): Declare.
7735 * valprint.c (value_print_scalar_formatted): New function.
7736
7737 2020-03-13 Tom Tromey <tom@tromey.com>
7738
7739 * valprint.h (generic_value_print): Declare.
7740 * valprint.c (generic_value_print): New function.
7741
7742 2020-03-13 Tom Tromey <tom@tromey.com>
7743
7744 * valprint.c (do_val_print): Call la_value_print_inner, if
7745 available.
7746 * rust-lang.c (rust_language_defn): Update.
7747 * p-lang.c (pascal_language_defn): Update.
7748 * opencl-lang.c (opencl_language_defn): Update.
7749 * objc-lang.c (objc_language_defn): Update.
7750 * m2-lang.c (m2_language_defn): Update.
7751 * language.h (struct language_defn) <la_value_print_inner>: New
7752 member.
7753 * language.c (unknown_language_defn, auto_language_defn): Update.
7754 * go-lang.c (go_language_defn): Update.
7755 * f-lang.c (f_language_defn): Update.
7756 * d-lang.c (d_language_defn): Update.
7757 * c-lang.c (c_language_defn, cplus_language_defn)
7758 (asm_language_defn, minimal_language_defn): Update.
7759 * ada-lang.c (ada_language_defn): Update.
7760
7761 2020-03-13 Tom Tromey <tom@tromey.com>
7762
7763 * c-valprint.c (c_value_print): Use common_val_print.
7764
7765 2020-03-13 Tom Tromey <tom@tromey.com>
7766
7767 * cp-valprint.c (cp_print_static_field): Use common_val_print.
7768
7769 2020-03-13 Tom Tromey <tom@tromey.com>
7770
7771 * f-valprint.c (f77_print_array_1, f_val_print): Use
7772 common_val_print.
7773
7774 2020-03-13 Tom Tromey <tom@tromey.com>
7775
7776 * riscv-tdep.c (riscv_print_one_register_info): Use
7777 common_val_print.
7778
7779 2020-03-13 Tom Tromey <tom@tromey.com>
7780
7781 * mi/mi-main.c (output_register): Use common_val_print.
7782
7783 2020-03-13 Tom Tromey <tom@tromey.com>
7784
7785 * infcmd.c (default_print_one_register_info): Use
7786 common_val_print.
7787
7788 2020-03-13 Tom Tromey <tom@tromey.com>
7789
7790 * valprint.h (common_val_print_checked): Declare.
7791 * valprint.c (common_val_print_checked): New function.
7792 * stack.c (print_frame_arg): Use common_val_print_checked.
7793
7794 2020-03-13 Tom Tromey <tom@tromey.com>
7795
7796 * valprint.c (do_val_print): New function, from val_print.
7797 (val_print): Use do_val_print.
7798 (common_val_print): Use do_val_print.
7799
7800 2020-03-13 Tom Tromey <tom@tromey.com>
7801
7802 * valprint.c (value_print): Use scoped_value_mark.
7803
7804 2020-03-13 Tom de Vries <tdevries@suse.de>
7805
7806 PR symtab/25646
7807 * psymtab.c (partial_symtab::partial_symtab): Don't set
7808 globals_offset and statics_offset. Push element onto
7809 current_global_psymbols and current_static_psymbols stacks.
7810 (concat): New function.
7811 (end_psymtab_common): Set globals_offset and statics_offset. Pop
7812 element from current_global_psymbols and current_static_psymbols
7813 stacks. Concat popped elements to global_psymbols and
7814 static_symbols.
7815 (add_psymbol_to_list): Use current_global_psymbols and
7816 current_static_psymbols stacks.
7817 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
7818 current_static_psymbols fields.
7819
7820 2020-03-12 Christian Biesinger <cbiesinger@google.com>
7821
7822 * corelow.c (sniff_core_bfd): Remove.
7823 (class core_target) <m_core_vec>: Remove.
7824 (core_target::core_target): Update.
7825 (core_file_fns): Remove.
7826 (deprecated_add_core_fns): Remove.
7827 (default_core_sniffer): Remove.
7828 (sniff_core_bfd): Remove.
7829 (default_check_format): Remove.
7830 (gdb_check_format): Remove.
7831 (core_target_open): Update.
7832 (core_target::get_core_register_section): Update.
7833 (get_core_registers_cb): Update.
7834 (core_target::fetch_registers): Update.
7835 * gdbcore.h (struct core_fns): Remove.
7836 (deprecated_add_core_fns): Remove.
7837 (default_core_sniffer): Remove.
7838 (default_check_format): Remove.
7839
7840 2020-03-12 Tom Tromey <tom@tromey.com>
7841
7842 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
7843 CORE_ADDR.
7844 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
7845
7846 2020-03-12 Tom Tromey <tom@tromey.com>
7847
7848 * remote.c (remote_target::download_tracepoint)
7849 (remote_target::enable_tracepoint)
7850 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
7851 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
7852 sprintf_vma.
7853
7854 2020-03-12 Tom Tromey <tom@tromey.com>
7855
7856 * symfile-mem.c: Update CORE_ADDR size assert.
7857
7858 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7859
7860 * selftest.m4: Move to gdbsupport/.
7861 * acinclude.m4: Update path to selftest.m4.
7862
7863 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7864
7865 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
7866 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
7867 gdbarch-selfselftests.c and selftest-arch.c.
7868 (SUBDIR_UNITTESTS_OBS): Rename to...
7869 (SELFTESTS_OBS): ... this.
7870 (COMMON_SFILES): Remove disasm-selftests.c and
7871 gdbarch-selftests.c.
7872 * configure.ac: Don't add selftest-arch.{c,o} to
7873 CONFIG_{SRCS,OBS}.
7874 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
7875 preprocessor conditions.
7876
7877 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7878
7879 * configure.ac: Don't source bfd/development.sh.
7880 * selftest.m4: Modify comment.
7881 * configure: Re-generate.
7882
7883 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7884
7885 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
7886 not "true" or "false".
7887 * configure: Re-generate.
7888
7889 2020-03-12 Christian Biesinger <cbiesinger@google.com>
7890
7891 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
7892 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
7893 renamed to arm_nbsd_supply_gregset.
7894 (fetch_register): Update to call arm_nbsd_supply_gregset.
7895 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
7896 (arm_netbsd_nat_target::fetch_registers): Update.
7897 (fetch_elfcore_registers): Removed.
7898 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
7899 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
7900 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
7901 not require NetBSD system headers.
7902 (arm_nbsd_regset): New struct.
7903 (arm_nbsd_iterate_over_regset_sections): New function.
7904 (arm_netbsd_init_abi_common): Updated to call
7905 set_gdbarch_iterate_over_regset_sections.
7906 * arm-nbsd-tdep.h: New file.
7907
7908 2020-03-11 Kevin Buettner <kevinb@redhat.com>
7909
7910 * symtab.c (find_pc_sect_line): Add check which prevents infinite
7911 recursion.
7912
7913 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
7914
7915 * configure: Re-generate.
7916
7917 2020-03-11 Tom Tromey <tromey@adacore.com>
7918
7919 * ada-typeprint.c (print_choices): Fix comment.
7920
7921 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
7922
7923 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
7924 previous item in the list, when the list has no items.
7925
7926 2020-03-11 Tom de Vries <tdevries@suse.de>
7927
7928 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
7929 PROP_LOCLIST handling code.
7930
7931 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
7932
7933 * buildsym-legacy.c (record_line): Pass extra parameter to
7934 record_line.
7935 * buildsym.c (buildsym_compunit::record_line): Take an extra
7936 parameter, reduce duplication in the line table, and record the
7937 is_stmt flag in the line table.
7938 * buildsym.h (buildsym_compunit::record_line): Add extra
7939 parameter.
7940 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
7941 non-statement lines.
7942 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
7943 this to the symtab builder.
7944 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
7945 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
7946 through to dwarf_record_line_1.
7947 * infrun.c (process_event_stop_test): When stepping, don't stop at
7948 a non-statement instruction, and only refresh the step info when
7949 we land in the middle of a line's range. Also add an extra
7950 comment.
7951 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
7952 field.
7953 * record-btrace.c (btrace_find_line_range): Only record lines
7954 marked as is-statement.
7955 * stack.c (frame_show_address): Show the frame address if we are
7956 in a non-statement sal.
7957 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
7958 (maintenance_print_one_line_table): Print a header for the is_stmt
7959 column, and include is_stmt information in the output.
7960 * symtab.c (find_pc_sect_line): Find lines marked as statements in
7961 preference to non-statements.
7962 (find_pcs_for_symtab_line): Prefer is-statement entries.
7963 (find_line_common): Likewise.
7964 * symtab.h (struct linetable_entry): Add is_stmt field.
7965 (struct symtab_and_line): Likewise.
7966 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
7967 arranging the line table.
7968
7969 2020-03-07 Tom de Vries <tdevries@suse.de>
7970
7971 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
7972 DIE.
7973
7974 2020-03-07 Tom Tromey <tom@tromey.com>
7975
7976 * valops.c (value_literal_complex): Remove obsolete comment.
7977 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
7978 comment.
7979
7980 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7981
7982 * infrun.h: Forward-declare thread_info.
7983 (set_step_info): Add thread_info parameter, add doc.
7984 * infrun.c (set_step_info): Add thread_info parameter, move doc
7985 to header.
7986 * infrun.c (process_event_stop_test): Pass thread to
7987 set_step_info call.
7988 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
7989 set_step_info.
7990 (prepare_one_step): Add thread_info parameter, pass it to
7991 set_step_frame and prepare_one_step (recursive) call.
7992 (step_1): Pass thread to prepare_one_step call.
7993 (step_command_fsm::should_stop): Pass thread to
7994 prepare_one_step.
7995 (until_next_fsm): Pass thread to set_step_frame call.
7996 (finish_command): Pass thread to set_step_info call.
7997
7998 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
7999
8000 * windows-tdep.c (windows_solib_create_inferior_hook):
8001 Check if inferior is running.
8002
8003 2020-03-06 Tom de Vries <tdevries@suse.de>
8004
8005 * NEWS: Fix "the the".
8006 * ctfread.c: Same.
8007
8008 2020-03-06 Tom de Vries <tdevries@suse.de>
8009
8010 * psymtab.c (psymtab_to_symtab): Don't print "done.".
8011
8012 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8013
8014 * .dir-locals.el: Add a comment referencing the other copies of
8015 this file.
8016
8017 2020-03-05 John Baldwin <jhb@FreeBSD.org>
8018
8019 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
8020 psargs.
8021
8022 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8023
8024 * .gitattributes: New file.
8025
8026 2020-03-04 Tom Tromey <tom@tromey.com>
8027
8028 * symmisc.c (print_symbol_bcache_statistics)
8029 (print_objfile_statistics): Update.
8030 * symfile.c (allocate_symtab): Use intern.
8031 * psymtab.c (partial_symtab::partial_symtab): Use intern.
8032 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
8033 macro_cache>: Remove.
8034 <string_cache>: New member.
8035 (struct objfile) <intern>: New methods.
8036 * elfread.c (elf_symtab_read): Use intern.
8037 * dwarf2/read.c (fixup_go_packaging): Intern package name.
8038 (dwarf2_compute_name, dwarf2_physname)
8039 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
8040 names.
8041 (guess_partial_die_structure_name): Update.
8042 (partial_die_info::fixup): Intern name.
8043 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
8044 name.
8045 (dwarf2_name): Intern name. Update.
8046 * buildsym.c (buildsym_compunit::get_macro_table): Use
8047 string_cache.
8048
8049 2020-03-04 Tom Tromey <tom@tromey.com>
8050
8051 * jit.c (bfd_open_from_target_memory): Make "target" const.
8052 * corefile.c (gnutarget): Now const.
8053 * gdbcore.h (gnutarget): Now const.
8054
8055 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
8056
8057 * NEWS: Mention support for WOW64 processes.
8058 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
8059 (amd64_windows_segment_register_p): Remove static.
8060 (_initialize_amd64_windows_nat): Update.
8061 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
8062 * i386-windows-nat.c (context_offset): Update.
8063 (i386_mappings): Rename and remove static.
8064 (i386_windows_segment_register_p): Remove static.
8065 (_initialize_i386_windows_nat): Update.
8066 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
8067 (STATUS_WX86_SINGLE_STEP): New macro.
8068 (EnumProcessModulesEx): New macro.
8069 (Wow64SuspendThread): New macro.
8070 (Wow64GetThreadContext): New macro.
8071 (Wow64SetThreadContext): New macro.
8072 (Wow64GetThreadSelectorEntry): New macro.
8073 (windows_set_context_register_offsets): Add static.
8074 (windows_set_segment_register_p): Likewise.
8075 (windows_add_thread): Adapt for WOW64 processes.
8076 (windows_fetch_one_register): Likewise.
8077 (windows_nat_target::fetch_registers): Likewise.
8078 (windows_store_one_register): Likewise.
8079 (display_selector): Likewise.
8080 (display_selectors): Likewise.
8081 (handle_exception): Likewise.
8082 (windows_continue): Likewise.
8083 (windows_nat_target::resume): Likewise.
8084 (windows_add_all_dlls): Likewise.
8085 (do_initial_windows_stuff): Likewise.
8086 (windows_nat_target::attach): Likewise.
8087 (windows_get_exec_module_filename): Likewise.
8088 (windows_nat_target::create_inferior): Likewise.
8089 (windows_xfer_siginfo): Likewise.
8090 (_initialize_loadable): Initialize Wow64SuspendThread,
8091 Wow64GetThreadContext, Wow64SetThreadContext,
8092 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
8093 * windows-nat.h (windows_set_context_register_offsets):
8094 Remove declaration.
8095 (windows_set_segment_register_p): Likewise.
8096 (i386_windows_segment_register_p): Add declaration.
8097 (amd64_windows_segment_register_p): Likewise.
8098
8099 2020-03-04 Luis Machado <luis.machado@linaro.org>
8100
8101 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
8102 in "info registers" for AArch64/ARM.
8103
8104 The change caused "info registers" to not print GPR's.
8105
8106 gdb/ChangeLog:
8107
8108 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
8109
8110 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
8111 when reg->group is empty and reggroup is not.
8112
8113 2020-03-03 Tom Tromey <tromey@adacore.com>
8114
8115 * dwarf2/frame.c (struct dwarf2_frame_cache)
8116 <checked_tailcall_bottom, entry_cfa_sp_offset,
8117 entry_cfa_sp_offset_p>: Remove members.
8118 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
8119 (dwarf2_frame_prev_register): Don't call
8120 dwarf2_tailcall_sniffer_first.
8121 (dwarf2_append_unwinders): Don't append tailcall unwinder.
8122 * frame-unwind.c (add_unwinder): New fuction.
8123 (frame_unwind_init): Use it. Add tailcall unwinder.
8124
8125 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
8126 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8127
8128 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
8129 value should be printed as true.
8130
8131 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
8132
8133 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
8134 (windows_init_abi): Set and use windows_so_ops.
8135
8136 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
8137
8138 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
8139 when verifying if dealing with a convenience variable.
8140
8141 2020-03-03 Luis Machado <luis.machado@linaro.org>
8142
8143 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
8144
8145 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8146
8147 * infrun.c (gdbarch_supports_displaced_stepping): New.
8148 (use_displaced_stepping): Break up conditions in smaller pieces.
8149 Use gdbarch_supports_displaced_stepping.
8150 (displaced_step_prepare_throw): Use
8151 gdbarch_supports_displaced_stepping.
8152
8153 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
8154
8155 * NEWS: Mention new behaviour of the history filename.
8156 * top.c (write_history_p): Add comment.
8157 (show_write_history_p): Add header comment, give a different
8158 message when history writing is on, but the history filename is
8159 empty.
8160 (history_filename): Add comment.
8161 (history_filename_empty): New function.
8162 (show_history_filename): Add header comment, give a different
8163 message when the filename is empty.
8164 (init_history): Compare history_filename against nullptr, and only
8165 read history if the filename is not empty.
8166 (set_history_filename): Add header comment, and only make
8167 non-empty filenames absolute.
8168 (init_main): Make the filename argument to 'set history filename'
8169 optional.
8170
8171 2020-03-02 Christian Biesinger <cbiesinger@google.com>
8172
8173 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
8174 (arm_supply_vfpregset): ...this, and update to use VFP registers.
8175 (fetch_fp_register): Update.
8176 (fetch_fp_regs): Update.
8177 (store_fp_register): Update.
8178 (store_fp_regs): Update.
8179 (arm_netbsd_nat_target::read_description): New function.
8180 (fetch_elfcore_registers): Update.
8181
8182 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
8183
8184 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
8185 general_thread if the stop reply is missing a thread-id.
8186 (remote_target::process_stop_reply): Use the first non-exited
8187 thread if the target didn't pass a thread-id.
8188 * infrun.c (do_target_wait): Move call to
8189 switch_to_inferior_no_thread to ....
8190 (do_target_wait_1): ... here.
8191
8192 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
8193
8194 * debuginfod-support.c: Include defs.h first.
8195
8196 2020-02-28 Tom de Vries <tdevries@suse.de>
8197
8198 * symfile.c (set_initial_language): Use default language for lookup.
8199
8200 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
8201
8202 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
8203 reader variable, pass `this` to read_cutu_die_from_dwo.
8204
8205 2020-02-27 Aaron Merey <amerey@redhat.com>
8206
8207 * source.c (open_source_file): Check for nullptr when computing
8208 srcpath.
8209
8210 2020-02-27 Tom Tromey <tromey@adacore.com>
8211
8212 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
8213 member.
8214 (dwarf2_add_field): Don't update nfields.
8215 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
8216
8217 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
8218
8219 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
8220 abs.
8221
8222 2020-02-26 Tom Tromey <tom@tromey.com>
8223
8224 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
8225 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
8226 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
8227 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
8228 per_cu_data.
8229
8230 2020-02-26 Tom Tromey <tom@tromey.com>
8231
8232 * dwarf2/index-write.c (psym_index_map): Change type.
8233 (add_address_entry_worker, write_one_signatured_type)
8234 (recursively_count_psymbols, recursively_write_psymbols)
8235 (class debug_names, psyms_seen_size, write_gdbindex)
8236 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
8237
8238 2020-02-26 Aaron Merey <amerey@redhat.com>
8239
8240 * Makefile.in: Handle optional debuginfod support.
8241 * NEWS: Update.
8242 * README: Add --with-debuginfod summary.
8243 * config.in: Regenerate.
8244 * configure: Regenerate.
8245 * configure.ac: Handle optional debuginfod support.
8246 * debuginfod-support.c: debuginfod helper functions.
8247 * debuginfod-support.h: Ditto.
8248 * doc/gdb.texinfo: Add --with-debuginfod to configure options
8249 summary.
8250 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
8251 when a dwz file cannot be found.
8252 * elfread.c (elf_symfile_read): Query debuginfod servers when a
8253 debuginfo file cannot be found.
8254 * source.c (open_source_file): Query debuginfod servers when a
8255 source file cannot be found.
8256 * top.c (print_gdb_configuration): Include
8257 --{with,without}-debuginfod in the output.
8258
8259 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
8260
8261 * thread.c (thr_try_catch_cmd): Print thread name.
8262
8263 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
8264
8265 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
8266 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8267 dwarf2_fetch_die_type_sect_off): Move to...
8268 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
8269 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8270 dwarf2_fetch_die_type_sect_off): ... here.
8271 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
8272 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8273 dwarf2_fetch_die_type_sect_off): Move doc to header file.
8274
8275 2020-02-26 Tom de Vries <tdevries@suse.de>
8276
8277 PR gdb/25603
8278 * symfile.c (set_initial_language): Exit-early if
8279 language_mode == language_mode_manual.
8280
8281 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
8282
8283 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
8284 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
8285 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
8286
8287 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
8288
8289 * gdbtypes.c (create_array_type_with_stride): Handle negative
8290 array strides.
8291 * valarith.c (value_subscripted_rvalue): Likewise.
8292
8293 2020-02-25 Luis Machado <luis.machado@linaro.org>
8294
8295 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
8296
8297 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
8298
8299 * loc.h (dwarf2_get_die_type): Move to...
8300 * read.h (dwarf2_get_die_type): ... here.
8301 * read.c (dwarf2_get_die_type): Move doc to header.
8302
8303 2020-02-25 Joel Brobecker <brobecker@adacore.com>
8304
8305 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
8306 'gnulib/Makefile.in' to the list.
8307
8308 2020-02-24 Tom Tromey <tom@tromey.com>
8309
8310 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
8311 Remove.
8312 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
8313 XOBNEWVEC.
8314
8315 2020-02-24 Tom Tromey <tom@tromey.com>
8316
8317 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
8318 New method.
8319 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
8320 (dw2_do_instantiate_symtab, dw2_get_file_names)
8321 (build_type_psymtab_dependencies, load_full_type_unit): Update.
8322
8323 2020-02-24 Tom Tromey <tom@tromey.com>
8324
8325 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
8326 make_scoped_restore.
8327 (dwarf2_psymtab::read_symtab): Don't clear
8328 reading_partial_symbols.
8329
8330 2020-02-24 Tom de Vries <tdevries@suse.de>
8331
8332 PR gdb/25592
8333 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
8334
8335 2020-02-24 Tom de Vries <tdevries@suse.de>
8336
8337 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
8338 commands layout next/prev/regs.
8339
8340 2020-02-22 Tom Tromey <tom@tromey.com>
8341
8342 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
8343 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
8344
8345 2020-02-22 Tom Tromey <tom@tromey.com>
8346
8347 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
8348
8349 2020-02-22 Tom Tromey <tom@tromey.com>
8350
8351 * tui/tui-win.c (_initialize_tui_win): Add usage text.
8352 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
8353 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
8354 * tui/tui.c (_initialize_tui): Add usage text.
8355
8356 2020-02-22 Tom Tromey <tom@tromey.com>
8357
8358 * tui/tui-win.c (tui_set_focus_command)
8359 (tui_set_win_height_command): Use error_no_arg.
8360 (_initialize_tui_win): Update help text.
8361 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
8362
8363 2020-02-22 Tom Tromey <tom@tromey.com>
8364
8365 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
8366 * tui/tui-disasm.h (struct tui_disasm_window)
8367 <display_start_addr>: Declare.
8368 * tui/tui-source.h (struct tui_source_window)
8369 <display_start_addr>: Declare.
8370 * tui/tui-winsource.h (struct tui_source_window_base)
8371 <show_source_line, display_start_addr>: New methods.
8372 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
8373 Rename and move to protected section.
8374 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
8375 (tui_source_window_base::do_erase_source_content): Update.
8376 (tui_source_window_base::show_source_line): Now a method.
8377 (tui_source_window_base::show_source_content)
8378 (tui_source_window_base::tui_source_window_base)
8379 (tui_source_window_base::rerender)
8380 (tui_source_window_base::refill)
8381 (tui_source_window_base::do_scroll_horizontal)
8382 (tui_source_window_base::set_is_exec_point_at)
8383 (tui_source_window_base::update_breakpoint_info)
8384 (tui_source_window_base::update_exec_info): Update.
8385 * tui/tui-source.c (tui_source_window::set_contents)
8386 (tui_source_window::showing_source_p)
8387 (tui_source_window::do_scroll_vertical)
8388 (tui_source_window::location_matches_p)
8389 (tui_source_window::line_is_displayed): Update.
8390 (tui_source_window::display_start_addr): New method.
8391 * tui/tui-disasm.c (tui_disasm_window::set_contents)
8392 (tui_disasm_window::do_scroll_vertical)
8393 (tui_disasm_window::location_matches_p): Update.
8394 (tui_disasm_window::display_start_addr): New method.
8395
8396 2020-02-22 Tom Tromey <tom@tromey.com>
8397
8398 * NEWS: Add entry for gdb.register_window_type.
8399 * tui/tui-layout.h (window_factory): New typedef.
8400 (tui_register_window): Declare.
8401 * tui/tui-layout.c (saved_tui_windows): New global.
8402 (tui_apply_current_layout): Use it.
8403 (tui_register_window): New function.
8404 * python/python.c (do_start_initialization): Call
8405 gdbpy_initialize_tui.
8406 (python_GdbMethods): Add "register_window_type" function.
8407 * python/python-internal.h (gdbpy_register_tui_window)
8408 (gdbpy_initialize_tui): Declare.
8409 * python/py-tui.c: New file.
8410 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
8411
8412 2020-02-22 Tom Tromey <tom@tromey.com>
8413
8414 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
8415
8416 2020-02-22 Tom Tromey <tom@tromey.com>
8417
8418 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
8419 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
8420 * tui/tui-data.c (tui_set_win_with_focus): Remove.
8421 (tui_set_win_focus_to): Move from tui-win.c.
8422
8423 2020-02-22 Tom Tromey <tom@tromey.com>
8424
8425 * tui/tui-layout.c (make_standard_window, get_locator_window): New
8426 functions.
8427 (known_window_types): New global.
8428 (tui_get_window_by_name): Reimplement.
8429 (initialize_known_windows): New function.
8430 (validate_window_name): Rewrite.
8431 (_initialize_tui_layout): Call initialize_known_windows.
8432
8433 2020-02-22 Tom Tromey <tom@tromey.com>
8434
8435 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
8436 Remove constants.
8437 * tui/tui-winsource.h (struct tui_source_window_base)
8438 <tui_source_window_base>: Remove parameter.
8439 * tui/tui-winsource.c
8440 (tui_source_window_base::tui_source_window_base): Remove
8441 parameter.
8442 (tui_source_window_base::refill): Update.
8443 * tui/tui-stack.h (struct tui_locator_window)
8444 <tui_locator_window>: Update.
8445 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
8446 Default the constructor.
8447 * tui/tui-regs.h (struct tui_data_item_window)
8448 <tui_data_item_window>: Default the constructor.
8449 (struct tui_data_window) <tui_data_window>: Likewise.
8450 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
8451 Default the constructor.
8452 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
8453 Default the constructor.
8454 <type>: Remove.
8455 (struct tui_win_info) <tui_win_info>: Default the constructor.
8456 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
8457 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
8458 Default the constructor.
8459
8460 2020-02-22 Tom Tromey <tom@tromey.com>
8461
8462 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
8463 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
8464 * tui/tui-win.c (tui_resize_all): Don't call
8465 tui_delete_invisible_windows.
8466 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
8467 done.
8468 (tui_set_layout): Update.
8469 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
8470 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
8471 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
8472
8473 2020-02-22 Tom Tromey <tom@tromey.com>
8474
8475 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
8476 correctly.
8477
8478 2020-02-22 Tom Tromey <tom@tromey.com>
8479
8480 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
8481
8482 2020-02-22 Tom Tromey <tom@tromey.com>
8483
8484 * tui/tui-winsource.h (struct tui_source_window_iterator)
8485 <inner_iterator>: New etytypedef.
8486 <tui_source_window_iterator>: Take "end" parameter.
8487 <tui_source_window_iterator>: Take iterator.
8488 <operator*, advance>: Update.
8489 <m_iter>: Change type.
8490 <m_end>: New field.
8491 (struct tui_source_windows) <begin, end>: Update.
8492 * tui/tui-layout.c (tui_windows): New global.
8493 (tui_apply_current_layout): Clear tui_windows.
8494 (tui_layout_window::apply): Update tui_windows.
8495 * tui/tui-data.h (tui_windows): Declare.
8496 (all_tui_windows): Now inline function.
8497 (class tui_window_iterator, struct all_tui_windows): Remove.
8498
8499 2020-02-22 Tom Tromey <tom@tromey.com>
8500
8501 PR tui/17850:
8502 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
8503 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
8504 "height" argument.
8505 (class tui_layout_window) <get_sizes>: Likewise.
8506 (class tui_layout_split) <tui_layout_split>: Add "vertical"
8507 argument.
8508 <get_sizes>: Add "height" argument.
8509 <m_vertical>: New field.
8510 * tui/tui-layout.c (tui_layout_split::clone): Update.
8511 (tui_layout_split::get_sizes): Add "height" argument.
8512 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
8513 (tui_new_layout_command): Parse "-horizontal".
8514 (_initialize_tui_layout): Update help string.
8515 (tui_layout_split::specification): Add "-horizontal" when needed.
8516 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
8517 argument.
8518 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
8519 New methods.
8520
8521 2020-02-22 Tom Tromey <tom@tromey.com>
8522
8523 * tui/tui-layout.h (enum tui_adjust_result): New.
8524 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
8525 (class tui_layout_window) <adjust_size>: Return
8526 tui_adjust_result. Rewrite.
8527 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
8528 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
8529
8530 2020-02-22 Tom Tromey <tom@tromey.com>
8531
8532 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
8533 parameter and return types.
8534 (class tui_layout_base) <specification>: Add "depth".
8535 (class tui_layout_window) <specification>: Add "depth".
8536 (class tui_layout_split) <specification>: Add "depth".
8537 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
8538 and return types.
8539 (tui_new_layout_command): Parse sub-layouts.
8540 (_initialize_tui_layout): Update help string.
8541 (tui_layout_window::specification): Add "depth".
8542 (add_layout_command): Update.
8543
8544 2020-02-22 Tom Tromey <tom@tromey.com>
8545
8546 * NEWS: Add "tui new-layout" item.
8547 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
8548 Add new-layout command to help text.
8549 (validate_window_name): New function.
8550 (tui_new_layout_command): New function.
8551 (_initialize_tui_layout): Register "new-layout".
8552 (tui_layout_window::specification): New method.
8553 (tui_layout_window::specification): New method.
8554 * tui/tui-layout.h (class tui_layout_base) <specification>: New
8555 method.
8556 (class tui_layout_window) <specification>: New method.
8557 (class tui_layout_split) <specification>: New method.
8558
8559 2020-02-22 Tom Tromey <tom@tromey.com>
8560
8561 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
8562 * tui/tui-win.c (window_name_completer): Update comment.
8563 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
8564 Declare method.
8565 (class tui_layout_window) <replace_window>: Likewise.
8566 (class tui_layout_split) <replace_window>: Likewise.
8567 (tui_set_layout): Don't declare.
8568 (tui_set_initial_layout): Declare function.
8569 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
8570 (asm_regs_layout): New globals.
8571 (tui_current_layout, show_layout): Remove.
8572 (tui_set_layout, tui_add_win_to_layout): Rewrite.
8573 (find_layout, tui_apply_layout): New function.
8574 (layout_completer): Remove.
8575 (tui_next_layout): Reimplement.
8576 (tui_next_layout_command): New function.
8577 (tui_set_initial_layout, tui_prev_layout_command): New functions.
8578 (tui_regs_layout): Reimplement.
8579 (tui_regs_layout_command): New function.
8580 (extract_display_start_addr): Rewrite.
8581 (next_layout, prev_layout): Remove.
8582 (tui_layout_window::replace_window): New method.
8583 (tui_layout_split::replace_window): New method.
8584 (destroy_layout): New function.
8585 (layout_list): New global.
8586 (add_layout_command): New function.
8587 (initialize_layouts): Update.
8588 (tui_layout_command): New function.
8589 (_initialize_tui_layout): Install "layout" commands.
8590 * tui/tui-data.h (enum tui_layout_type): Remove.
8591 (tui_current_layout): Don't declare.
8592
8593 2020-02-22 Tom Tromey <tom@tromey.com>
8594
8595 * tui/tui-regs.c (tui_reg_layout): Remove.
8596 (tui_reg_command): Use tui_regs_layout.
8597 * tui/tui-layout.h (tui_reg_command): Declare.
8598 * tui/tui-layout.c (tui_reg_command): New function.
8599
8600 2020-02-22 Tom Tromey <tom@tromey.com>
8601
8602 * tui/tui.c (tui_rl_delete_other_windows): Call
8603 tui_remove_some_windows.
8604 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
8605 Declare method.
8606 (class tui_layout_window) <remove_windows>: New method.
8607 (class tui_layout_split) <remove_windows>: Declare.
8608 (tui_remove_some_windows): Declare.
8609 * tui/tui-layout.c (tui_remove_some_windows): New function.
8610 (tui_layout_split::remove_windows): New method.
8611
8612 2020-02-22 Tom Tromey <tom@tromey.com>
8613
8614 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
8615 * tui/tui-layout.h (tui_next_layout): Declare.
8616 * tui/tui-layout.c (tui_next_layout): New function.
8617
8618 2020-02-22 Tom Tromey <tom@tromey.com>
8619
8620 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
8621 correct coordinates.
8622
8623 2020-02-22 Tom Tromey <tom@tromey.com>
8624
8625 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
8626 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
8627 DATA_WIN case.
8628
8629 2020-02-22 Tom Tromey <tom@tromey.com>
8630
8631 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
8632 TUI_DISASM_WIN, not tui_win_list.
8633
8634 2020-02-22 Tom Tromey <tom@tromey.com>
8635
8636 * valprint.c (generic_val_print_enum_1)
8637 (val_print_type_code_flags): Style member names.
8638 * rust-lang.c (val_print_struct, rust_print_enum)
8639 (rust_print_struct_def, rust_internal_print_type): Style member
8640 names.
8641 * p-valprint.c (pascal_object_print_value_fields): Style member
8642 names. Only call fprintf_symbol_filtered for static members.
8643 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
8644 * f-valprint.c (f_val_print): Style member names.
8645 * f-typeprint.c (f_type_print_base): Style member names.
8646 * cp-valprint.c (cp_print_value_fields): Style member names. Only
8647 call fprintf_symbol_filtered for static members.
8648 (cp_print_class_member): Style member names.
8649 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
8650 member names.
8651 * ada-valprint.c (ada_print_scalar): Style enum names.
8652 (ada_val_print_enum): Likewise.
8653 * ada-typeprint.c (print_enum_type): Style enum names.
8654
8655 2020-02-21 Tom Tromey <tom@tromey.com>
8656
8657 * psympriv.h (struct partial_symtab): Update comment.
8658
8659 2020-02-21 Tom Tromey <tromey@adacore.com>
8660
8661 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
8662 type is CORE_ADDR.
8663
8664 2020-02-21 Tom de Vries <tdevries@suse.de>
8665
8666 PR gdb/25534
8667 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
8668 if dependencies[i]->user != NULL.
8669
8670 2020-02-21 Ali Tamur <tamur@google.com>
8671
8672 * dwarf2/read.c (dwarf2_name): Add null check.
8673
8674 2020-02-20 Tom Tromey <tom@tromey.com>
8675
8676 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
8677 ">=", in binary search.
8678 (dwarf2_find_containing_comp_unit): New overload.
8679 (run_test): New self-test.
8680 (_initialize_dwarf2_read): Register new test.
8681
8682 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
8683
8684 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
8685 * riscv-tdep.h: Likewise.
8686 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
8687 rv32-only CSR.
8688 * features/riscv/64bit-csr.xml: Regenerated.
8689
8690 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
8691 Tom Tromey <tom@tromey.com>
8692
8693 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
8694 of 'fputc_unfiltered'.
8695 (putchar_unfiltered): Call 'fputc_unfiltered'.
8696 (fputc_unfiltered): Call 'fputs_unfiltered'.
8697
8698 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
8699
8700 * config.in: Regenerate.
8701 * configure: Regenerate.
8702 * configure.ac: Add --with-python-libdir option.
8703 * main.c: Use WITH_PYTHON_LIBDIR.
8704
8705 2020-02-19 Tom Tromey <tom@tromey.com>
8706
8707 * symtab.c (general_symbol_info::compute_and_set_names): Use
8708 obstack_strndup. Simplify call to symbol_set_demangled_name.
8709
8710 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
8711
8712 * dwarf2/read.c (allocate_signatured_type_table,
8713 allocate_dwo_unit_table, allocate_type_unit_groups_table,
8714 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
8715 Remove objfile parameter, update all callers.
8716
8717 2020-02-19 Doug Evans <dje@google.com>
8718
8719 PR rust/25535
8720 * rust-lang.c (rust_print_enum): Apply embedded_offset to
8721 rust_enum_variant calculation.
8722
8723 2020-02-19 Tom Tromey <tromey@adacore.com>
8724
8725 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
8726
8727 2020-02-19 Tom Tromey <tromey@adacore.com>
8728
8729 * ada-lang.c (cache_symbol): Use obstack_strdup.
8730
8731 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
8732
8733 * configure: Regenerate.
8734
8735 2020-02-19 Tom Tromey <tromey@adacore.com>
8736
8737 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
8738 NULL check.
8739
8740 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
8741
8742 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
8743
8744 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
8745
8746 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
8747 if GDBSERVER is not defined.
8748 (riscv_tdesc_cache): Likewise, also store const target_desc.
8749 (STATIC_IN_GDB): Define.
8750 (riscv_create_target_description): Update declaration with
8751 STATIC_IN_GDB.
8752 (riscv_lookup_target_description): New function, only define if
8753 GDBSERVER is not defined.
8754 * arch/riscv.h (riscv_create_target_description): Declare only
8755 when GDBSERVER is defined.
8756 (riscv_lookup_target_description): New declaration when GDBSERVER
8757 is not defined.
8758 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
8759 (riscv_linux_read_features): ...this, and return
8760 riscv_gdbarch_features instead of target_desc.
8761 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
8762 (riscv_linux_read_description): Rename to...
8763 (riscv_linux_read_features): ...this.
8764 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
8765 Update to use riscv_gdbarch_features and
8766 riscv_lookup_target_description.
8767 * riscv-tdep.c (riscv_find_default_target_description): Use
8768 riscv_lookup_target_description instead of
8769 riscv_create_target_description.
8770
8771 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8772
8773 * valprint.c (generic_val_print_enum_1): When printing a flag
8774 enum with value 0 and there is no enumerator with value 0, print
8775 just "0" instead of "(unknown: 0x0)".
8776
8777 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8778
8779 * valprint.c (generic_val_print_enum_1): Print unknown part of
8780 flag enum in hex.
8781
8782 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8783
8784 * dwarf2/read.c (update_enumeration_type_from_children): Allow
8785 flag enums to contain duplicate enumerators.
8786 * valprint.c (generic_val_print_enum_1): Update comment.
8787
8788 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8789
8790 * dwarf2/read.c: Include "count-one-bits.h".
8791 (update_enumeration_type_from_children): If an enumerator has
8792 multiple bits set, don't treat the enumeration as a "flag enum".
8793 * valprint.c (generic_val_print_enum_1): Assert that enumerators
8794 of flag enums have 0 or 1 bit set.
8795
8796 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
8797
8798 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
8799 conversion.
8800 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8801 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
8802 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8803 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
8804 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8805
8806 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8807
8808 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
8809
8810 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8811
8812 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
8813 displaced_step_closure_up.
8814 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
8815 (struct displaced_step_closure_up):
8816 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8817 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
8818 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
8819 Likewise.
8820 * gdbarch.sh (displaced_step_copy_insn): Likewise.
8821 * gdbarch.c, gdbarch.h: Re-generate.
8822 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
8823 displaced_step_closure_up.
8824 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8825 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
8826 * infrun.h (displaced_step_closure_up): New type alias.
8827 (struct displaced_step_inferior_state) <step_closure>: Change
8828 type to displaced_step_closure_up.
8829 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
8830 displaced_step_closure_up.
8831 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8832
8833 2020-02-14 Tom Tromey <tom@tromey.com>
8834
8835 * minidebug.c (gnu_debug_key): New global.
8836 (find_separate_debug_file_in_section): Use it.
8837
8838 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8839
8840 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
8841 std::unique_ptr.
8842 * gdbarch.c: Re-generate.
8843 * gdbarch.h: Re-generate.
8844 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
8845 change.
8846 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
8847 type to std::unique_ptr.
8848 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
8849 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8850 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
8851 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
8852 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
8853 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8854 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
8855 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
8856 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8857
8858 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8859
8860 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
8861 std::unique_ptr.
8862 (displaced_step_clear): Rename to...
8863 (displaced_step_reset): ... this. Just call displaced->reset ().
8864 (displaced_step_clear_cleanup): Rename to...
8865 (displaced_step_reset_cleanup): ... this.
8866 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
8867 (displaced_step_fixup): Likewise.
8868 (resume_1): Likewise.
8869 (handle_inferior_event): Restore child's memory before calling
8870 displaced_step_fixup on the parent.
8871 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
8872 to std::unique_ptr.
8873 <step_closure>: Change type to std::unique_ptr.
8874
8875 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8876
8877 * arm-tdep.c: Include count-one-bits.h.
8878 (cleanup_block_store_pc): Use count_one_bits.
8879 (cleanup_block_load_pc): Use count_one_bits.
8880 (arm_copy_block_xfer): Use count_one_bits.
8881 (thumb2_copy_block_xfer): Use count_one_bits.
8882 (thumb_copy_pop_pc_16bit): Use count_one_bits.
8883 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
8884 (thumb_get_next_pcs_raw): Use count_one_bits.
8885 (arm_get_next_pcs_raw): Use count_one_bits_l.
8886 * arch/arm.c (bitcount): Remove.
8887 * arch/arm.h (bitcount): Remove.
8888
8889 2020-02-14 Tom Tromey <tromey@adacore.com>
8890
8891 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
8892 Update.
8893 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
8894 * dwarf2/loc.c (call_site_find_chain_1): Return
8895 unique_xmalloc_ptr.
8896 (call_site_find_chain): Likewise.
8897
8898 2020-02-14 Richard Biener <rguenther@suse.de>
8899
8900 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
8901 on expression with division operators.
8902
8903 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8904
8905 * MAINTAINERS (Write After Approval): Adding myself.
8906
8907 2020-02-12 Tom Tromey <tom@tromey.com>
8908
8909 * event-loop.c (event_data, gdb_event, event_handler_func):
8910 Remove.
8911
8912 2020-02-12 Tom Tromey <tom@tromey.com>
8913
8914 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
8915 (dwarf2_frame_objfile_data): Add comment.
8916 (find_comp_unit, set_comp_unit): New functions.
8917 (dwarf2_frame_find_fde): Use find_comp_unit.
8918 (dwarf2_build_frame_info): Use set_comp_unit.
8919
8920 2020-02-12 Tom Tromey <tom@tromey.com>
8921
8922 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
8923 (comp_unit): Don't initialize objfile.
8924 (execute_cfa_program): Add text_offset parameter.
8925 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
8926 (dwarf2_frame_cache): Update.
8927 (dwarf2_build_frame_info): Don't set "objfile" member.
8928
8929 2020-02-12 Tom Tromey <tom@tromey.com>
8930
8931 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
8932 (decode_frame_entry): Likewise.
8933 (dwarf2_build_frame_info): Update.
8934
8935 2020-02-12 Tom Tromey <tom@tromey.com>
8936
8937 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
8938 (decode_frame_entry_1): Use the comp_unit obstack.
8939
8940 2020-02-12 Tom Tromey <tom@tromey.com>
8941
8942 * dwarf2/frame.c (struct comp_unit): Add initializers and
8943 constructor.
8944 (dwarf2_frame_objfile_data): Store a comp_unit.
8945 (dwarf2_frame_find_fde): Update.
8946 (dwarf2_build_frame_info): Use "new".
8947
8948 2020-02-12 Tom Tromey <tom@tromey.com>
8949
8950 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
8951 (dwarf2_fde_table): Typedef for std::vector.
8952 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
8953 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
8954 (decode_frame_entry): Update.
8955 (dwarf2_build_frame_info): Use "new".
8956
8957 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8958
8959 * arm-tdep.c (arm_gdbarch_init): Update.
8960 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
8961 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
8962 have_neon, is_m>: Change to bool.
8963
8964 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8965
8966 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
8967
8968 2020-02-12 Tom Tromey <tom@tromey.com>
8969
8970 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
8971
8972 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
8973
8974 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
8975 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
8976
8977 2020-02-11 Tom Tromey <tom@tromey.com>
8978
8979 * psymtab.h: Update comment.
8980
8981 2020-02-11 Tom Tromey <tom@tromey.com>
8982
8983 * gdb_obstack.h (struct auto_obstack): Use
8984 DISABLE_COPY_AND_ASSIGN.
8985
8986 2020-02-11 Tom Tromey <tom@tromey.com>
8987
8988 * dwarf2/frame.h (struct objfile): Don't forward declare.
8989
8990 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8991
8992 * cris-tdep.c (cris_supply_gregset): Change signature to match
8993 what struct regset expects.
8994 (cris_regset): New struct.
8995 (fetch_core_registers): Remove.
8996 (cris_iterate_over_regset_sections): New function.
8997 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
8998 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
8999
9000 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9001
9002 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
9003 registers.
9004
9005 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9006
9007 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
9008
9009 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9010
9011 * configure: Re-generate.
9012
9013 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9014
9015 * configure: Re-generate.
9016
9017 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9018
9019 * acinclude: Update warning.m4 path.
9020 * warning.m4: Move to gdbsupport.
9021
9022 2020-02-11 Tom Tromey <tromey@adacore.com>
9023
9024 * remote.c (remote_console_output): Update.
9025 * printcmd.c (printf_command): Update.
9026 * event-loop.c (gdb_wait_for_event): Update.
9027 * linux-nat.c (sigchld_handler): Update.
9028 * remote-sim.c (gdb_os_write_stdout): Update.
9029 (gdb_os_flush_stdout): Update.
9030 (gdb_os_flush_stderr): Update.
9031 (gdb_os_write_stderr): Update.
9032 * exceptions.c (print_exception): Update.
9033 * remote-fileio.c (remote_fileio_func_read): Update.
9034 (remote_fileio_func_write): Update.
9035 * tui/tui.c (tui_enable): Update.
9036 * tui/tui-interp.c (tui_interp::init): Update.
9037 * utils.c (init_page_info): Update.
9038 (putchar_unfiltered, fputc_unfiltered): Update.
9039 (gdb_flush): Update.
9040 (emit_style_escape): Update.
9041 (flush_wrap_buffer, fputs_maybe_filtered): Update.
9042 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
9043 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
9044 (stderr_file::write): Update.
9045 (stderr_file::puts): Update.
9046 * ui-file.h (ui_file_isatty, ui_file_write)
9047 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
9048 (ui_file_puts): Don't declare.
9049
9050 2020-02-10 Tom de Vries <tdevries@suse.de>
9051
9052 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
9053 sentinel to char *.
9054
9055 2020-02-09 Tom de Vries <tdevries@suse.de>
9056
9057 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
9058 filename if it matches "<artificial>".
9059
9060 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
9061
9062 * windows-tdep.c (struct enum_value_name): New struct.
9063 (create_enum): New function.
9064 (windows_get_siginfo_type): Create and use enum types.
9065
9066 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
9067
9068 * NEWS: Mention $_siginfo support for Windows.
9069 * windows-nat.c (handle_exception): Set siginfo_er.
9070 (windows_nat_target::mourn_inferior): Reset siginfo_er.
9071 (windows_xfer_siginfo): New function.
9072 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
9073 * windows-tdep.c (struct windows_gdbarch_data): New struct.
9074 (init_windows_gdbarch_data): New function.
9075 (get_windows_gdbarch_data): New function.
9076 (windows_get_siginfo_type): New function.
9077 (windows_init_abi): Register windows_get_siginfo_type.
9078 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
9079
9080 2020-02-08 Tom Tromey <tom@tromey.com>
9081
9082 * dwarf2/read.c (class cutu_reader) <cutu_reader,
9083 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
9084 <keep>: Declare method.
9085 <m_keep>: Remove member.
9086 <~cutu_reader>: Remove.
9087 (cutu_reader::init_tu_and_read_dwo_dies): Update.
9088 (cutu_reader::cutu_reader): Update.
9089 (cutu_reader::keep): Rename from ~cutu_reader.
9090 (process_psymtab_comp_unit, build_type_psymtabs_1)
9091 (process_skeletonless_type_unit, load_partial_comp_unit)
9092 (load_full_comp_unit, dwarf2_read_addr_index)
9093 (read_signatured_type): Update.
9094
9095 2020-02-08 Tom Tromey <tom@tromey.com>
9096
9097 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
9098 "want_partial_unit" parameter.
9099 (process_psymtab_comp_unit): Change want_partial_unit to bool.
9100 Inline check for DW_TAG_partial_unit.
9101 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
9102
9103 2020-02-08 Tom Tromey <tom@tromey.com>
9104
9105 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
9106 read.c.
9107 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
9108 read.c.
9109
9110 2020-02-08 Tom Tromey <tom@tromey.com>
9111
9112 * dwarf2/read.c (read_address): Move to comp-unit.c.
9113 (dwarf2_rnglists_process, dwarf2_ranges_process)
9114 (read_attribute_value, dwarf_decode_lines_1)
9115 (var_decode_location, decode_locdesc): Update.
9116 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
9117 read.c. Remove "cu" parameter.
9118 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
9119 method.
9120
9121 2020-02-08 Tom Tromey <tom@tromey.com>
9122
9123 * dwarf2/read.c (read_attribute_value, read_indirect_string)
9124 (read_indirect_line_string): Update.
9125 * dwarf2/comp-unit.c (read_offset): Remove.
9126 (read_comp_unit_head): Update.
9127 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
9128 method.
9129 (read_offset): Don't declare.
9130
9131 2020-02-08 Tom Tromey <tom@tromey.com>
9132
9133 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
9134 * dwarf2/read.c (struct comp_unit_head): Move to
9135 dwarf2/comp-unit.h.
9136 (enum class rcuh_kind): Move to comp-unit.h.
9137 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
9138 (read_comp_unit_head, error_check_comp_unit_head)
9139 (read_and_check_comp_unit_head): Move to comp-unit.c.
9140 (read_offset, dwarf_unit_type_name): Likewise.
9141 (create_debug_type_hash_table, read_cutu_die_from_dwo)
9142 (cutu_reader::cutu_reader, read_call_site_scope)
9143 (find_partial_die, follow_die_offset): Update.
9144 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
9145
9146 2020-02-08 Tom Tromey <tom@tromey.com>
9147
9148 * dwarf2/read.c (read_offset_1): Move to leb.c.
9149 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
9150 (dwarf_decode_macro_bytes): Update.
9151 * dwarf2/leb.c (read_offset): Rename; move from read.c.
9152 * dwarf2/leb.h (read_offset): Declare.
9153
9154 2020-02-08 Tom Tromey <tom@tromey.com>
9155
9156 * dwarf2/read.c (dwarf2_section_size): Remove.
9157 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
9158 Update.
9159 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
9160
9161 2020-02-08 Tom Tromey <tom@tromey.com>
9162
9163 * dwarf2/read.c (read_initial_length): Move to leb.c.
9164 * dwarf2/leb.h (read_initial_length): Declare.
9165 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
9166 handle_nonstd parameter.
9167 * dwarf2/frame.c (read_initial_length): Remove.
9168 (decode_frame_entry_1): Update.
9169
9170 2020-02-08 Tom Tromey <tom@tromey.com>
9171
9172 * dwarf2/loc.c (dwarf2_find_location_expression)
9173 (dwarf_evaluate_loc_desc::get_tls_address)
9174 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
9175 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
9176 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
9177 (dwarf2_compile_property_to_c)
9178 (dwarf2_loc_desc_get_symbol_read_needs)
9179 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
9180 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
9181 (loclist_describe_location, loclist_tracepoint_var_ref)
9182 (loclist_generate_c_location): Update.
9183 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
9184 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
9185 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
9186 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
9187 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
9188 (dwarf2_per_cu_data::addr_size)
9189 (dwarf2_per_cu_data::ref_addr_size)
9190 (dwarf2_per_cu_data::text_offset)
9191 (dwarf2_per_cu_data::addr_type): Now methods.
9192 (per_cu_header_read_in): Make per_cu "const".
9193 (dwarf2_version): Remove.
9194 (dwarf2_per_cu_data::int_type): Now a method.
9195 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
9196 (set_die_type, read_array_type, read_subrange_index_type)
9197 (read_tag_string_type, read_subrange_type): Update.
9198 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
9199 offset_size, ref_addr_size, text_offset, addr_type, version,
9200 objfile, int_type, addr_sized_int_type>: Declare methods.
9201
9202 2020-02-08 Tom Tromey <tom@tromey.com>
9203
9204 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
9205 Move earlier.
9206
9207 2020-02-08 Tom Tromey <tom@tromey.com>
9208
9209 * dwarf2/read.h (dwarf_line_debug): Declare.
9210 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
9211 * dwarf2/read.c: Move line_header code to new files.
9212 (dwarf_line_debug): No longer static.
9213 * dwarf2/line-header.c: New file.
9214 * dwarf2/line-header.h: New file.
9215
9216 2020-02-08 Tom Tromey <tom@tromey.com>
9217
9218 * dwarf2/read.c (struct line_header) <file_full_name,
9219 file_file_name>: Return unique_xmalloc_ptr.
9220 (line_header::file_file_name): Update.
9221 (line_header::file_full_name): Update.
9222 (dw2_get_file_names_reader): Update.
9223 (macro_start_file): Update.
9224
9225 2020-02-08 Tom Tromey <tom@tromey.com>
9226
9227 * dwarf2/read.c (struct line_header) <file_full_name,
9228 file_file_name>: Declare methods.
9229 (dw2_get_file_names_reader): Update.
9230 (file_file_name): Now a method.
9231 (file_full_name): Likewise.
9232 (macro_start_file): Update.
9233
9234 2020-02-08 Tom Tromey <tom@tromey.com>
9235
9236 * dwarf2/read.c (dwarf_always_disassemble)
9237 (show_dwarf_always_disassemble): Move to loc.c.
9238 (_initialize_dwarf2_read): Move "always-disassemble" registration
9239 to loc.c.
9240 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
9241 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
9242 static.
9243 (show_dwarf_always_disassemble): Move from read.c.
9244 (_initialize_dwarf2loc): Move always-disassemble from read.c.
9245
9246 2020-02-08 Tom Tromey <tom@tromey.com>
9247
9248 * dwarf2/read.c (~dwarf2_per_objfile): Update.
9249 (create_quick_file_names_table): Return htab_up.
9250 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
9251 Update.
9252 * dwarf2/read.h (struct dwarf2_per_objfile)
9253 <quick_file_names_table>: Now htab_up.
9254
9255 2020-02-08 Tom Tromey <tom@tromey.com>
9256
9257 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
9258
9259 2020-02-08 Tom Tromey <tom@tromey.com>
9260
9261 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
9262 Rewrite.
9263 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
9264 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
9265 (abbrev_table::abbrev_table): No longer inline.
9266 (ABBREV_HASH_SIZE): Remove.
9267 (abbrev_table::m_abbrevs): Now an htab_up.
9268
9269 2020-02-08 Tom Tromey <tom@tromey.com>
9270
9271 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
9272 (cutu_reader): Update.
9273 (build_type_psymtabs_1): Update.
9274 * dwarf2/abbrev.c (abbrev_table::read): Rename.
9275 (abbrev_table::alloc_abbrev): Update.
9276 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
9277 (abbrev_table::read): New static method, renamed from
9278 abbrev_table_read_table.
9279 (abbrev_table::alloc_abbrev)
9280 (abbrev_table::add_abbrev): Now private.
9281 (abbrev_table::abbrev_table): Now private.
9282 (abbrev_table::m_abbrev_obstack): Now private. Rename.
9283
9284 2020-02-08 Tom Tromey <tom@tromey.com>
9285
9286 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
9287 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
9288 htab_up.
9289
9290 2020-02-08 Tom Tromey <tom@tromey.com>
9291
9292 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
9293 htab_up.
9294 (lookup_dwo_unit_in_dwp): Update.
9295 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
9296 on obstack.
9297
9298 2020-02-08 Tom Tromey <tom@tromey.com>
9299
9300 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
9301 obstack.
9302
9303 2020-02-08 Tom Tromey <tom@tromey.com>
9304
9305 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
9306 line_header_hash.
9307 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
9308 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
9309 Change type to htab_up.
9310
9311 2020-02-08 Tom Tromey <tom@tromey.com>
9312
9313 * dwarf2/read.c (allocate_type_unit_groups_table): Return
9314 htab_up. Don't allocate on obstack.
9315 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
9316 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
9317 Change type to htab_up.
9318
9319 2020-02-08 Tom Tromey <tom@tromey.com>
9320
9321 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
9322 Change type to htab_up.
9323 * dwarf2/read.c (create_signatured_type_table_from_index)
9324 (create_signatured_type_table_from_debug_names)
9325 (create_all_type_units, add_type_unit)
9326 (lookup_dwo_signatured_type, lookup_signatured_type)
9327 (process_skeletonless_type_unit): Update.
9328 (create_debug_type_hash_table, create_debug_types_hash_table):
9329 Change type of types_htab.
9330 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
9331 htab_up. Don't allocate on obstack.
9332 (create_cus_hash_table): Change type of cus_htab parameter.
9333 (struct dwo_file) <cus, tus>: Now htab_up.
9334 (lookup_dwo_signatured_type, lookup_dwo_cutu)
9335 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
9336 (queue_and_load_all_dwo_tus): Update.
9337 * dwarf2/index-write.c (write_gdbindex): Update.
9338 (write_debug_names): Update.
9339
9340 2020-02-08 Tom Tromey <tom@tromey.com>
9341
9342 * dwarf2/read.h (struct dwarf2_queue_item): Move from
9343 dwarf2/read.c. Remove "next" member. Add constructor ntad
9344 destructor.
9345 (struct dwarf2_per_objfile) <queue>: New member.
9346 * dwarf2/read.c (struct dwarf2_queue_item): Move to
9347 dwarf2/read.h.
9348 (dwarf2_queue, dwarf2_queue_tail): Remove.
9349 (class dwarf2_queue_guard): Add parameter to constructor. Use
9350 DISABLE_COPY_AND_ASSIGN.
9351 <m_per_objfile>: New member.
9352 <~dwarf2_queue_guard>: Rewrite.
9353 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
9354 Update.
9355 (~dwarf2_queue_item): New.
9356
9357 2020-02-08 Tom Tromey <tom@tromey.com>
9358
9359 * dwarf2/read.c (struct die_info) <has_children>: New member.
9360 (dw2_get_file_names_reader): Remove has_children.
9361 (dw2_get_file_names): Update.
9362 (read_cutu_die_from_dwo): Remove has_children.
9363 (cutu_reader::init_tu_and_read_dwo_dies)
9364 (cutu_reader::cutu_reader): Update.
9365 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
9366 Remove has_children.
9367 (build_type_psymtabs_1, process_skeletonless_type_unit)
9368 (load_partial_comp_unit, load_full_comp_unit): Update.
9369 (create_dwo_cu_reader): Remove has_children.
9370 (create_cus_hash_table, read_die_and_children): Update.
9371 (read_full_die_1,read_full_die): Remove has_children.
9372 (read_signatured_type): Update.
9373 (class cutu_reader) <has_children>: Remove.
9374
9375 2020-02-08 Tom Tromey <tom@tromey.com>
9376
9377 * dwarf2/expr.c: Rename from dwarf2expr.c.
9378 * dwarf2/expr.h: Rename from dwarf2expr.h.
9379 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
9380 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
9381 * dwarf2/frame.c: Rename from dwarf2-frame.c.
9382 * dwarf2/frame.h: Rename from dwarf2-frame.h.
9383 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
9384 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
9385 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
9386 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
9387 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
9388 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
9389 * dwarf2/loc.c: Rename from dwarf2loc.c.
9390 * dwarf2/loc.h: Rename from dwarf2loc.h.
9391 * dwarf2/read.c: Rename from dwarf2read.c.
9392 * dwarf2/read.h: Rename from dwarf2read.h.
9393 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
9394 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
9395 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
9396 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
9397 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
9398 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
9399 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
9400 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
9401 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
9402 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
9403 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
9404 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
9405 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
9406 Update.
9407 * Makefile.in (COMMON_SFILES): Update.
9408 (HFILES_NO_SRCDIR): Update.
9409
9410 2020-02-08 Tom Tromey <tom@tromey.com>
9411
9412 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
9413 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
9414
9415 2020-02-08 Tom Tromey <tom@tromey.com>
9416
9417 * dwarf2read.h (struct die_info): Don't declare.
9418
9419 2020-02-08 Tom Tromey <tom@tromey.com>
9420
9421 * dwarf2read.h (die_info_ptr): Remove typedef.
9422
9423 2020-02-08 Tom Tromey <tom@tromey.com>
9424
9425 * dwarf2read.c (read_call_site_scope)
9426 (handle_data_member_location, dwarf2_add_member_fn)
9427 (mark_common_block_symbol_computed, read_common_block)
9428 (attr_to_dynamic_prop, partial_die_info::read)
9429 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
9430 (dwarf2_symbol_mark_computed, set_die_type): Update.
9431 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
9432 method.
9433 (attr_form_is_block): Don't declare.
9434 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
9435
9436 2020-02-08 Tom Tromey <tom@tromey.com>
9437
9438 * dwarf2read.c (dwarf2_find_base_address, )
9439 (read_call_site_scope, rust_containing_type)
9440 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
9441 (handle_data_member_location, dwarf2_add_member_fn)
9442 (get_alignment, read_structure_type, process_structure_scope)
9443 (mark_common_block_symbol_computed, read_common_block)
9444 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
9445 (partial_die_info::read, read_attribute_value, new_symbol)
9446 (lookup_die_type, dwarf2_get_ref_die_offset)
9447 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
9448 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
9449 (dwarf2_symbol_mark_computed): Update.
9450 * dwarf2/attribute.h (struct attribute) <value_as_address,
9451 form_is_section_offset, form_is_constant, form_is_ref>: Declare
9452 methods.
9453 (value_as_address, attr_form_is_section_offset)
9454 (attr_form_is_constant, attr_form_is_ref): Don't declare.
9455 * dwarf2/attribute.c (attribute::value_as_address)
9456 (attribute::form_is_section_offset, attribute::form_is_constant)
9457 (attribute::form_is_ref): Now methods.
9458
9459 2020-02-08 Tom Tromey <tom@tromey.com>
9460
9461 * dwarf2read.c (struct attribute, DW_STRING)
9462 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
9463 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
9464 (attr_form_is_block, attr_form_is_section_offset)
9465 (attr_form_is_constant, attr_form_is_ref): Move.
9466 * dwarf2/attribute.h: New file.
9467 * dwarf2/attribute.c: New file, from dwarf2read.c.
9468 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
9469
9470 2020-02-08 Tom Tromey <tom@tromey.com>
9471
9472 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
9473 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
9474 Move.
9475 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
9476 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
9477 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
9478 abbrev.c.
9479 * dwarf2/abbrev.h: New file.
9480 * dwarf2/abbrev.c: New file, from dwarf2read.c.
9481 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
9482
9483 2020-02-08 Tom Tromey <tom@tromey.com>
9484
9485 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
9486 (dwarf2_section_size, dwarf2_get_section_info)
9487 (create_signatured_type_table_from_debug_names)
9488 (create_addrmap_from_aranges, read_debug_names_from_section)
9489 (get_gdb_index_contents_from_section, read_comp_unit_head)
9490 (error_check_comp_unit_head, read_abbrev_offset)
9491 (create_debug_type_hash_table, init_cu_die_reader)
9492 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
9493 (read_comp_units_from_section, create_cus_hash_table)
9494 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
9495 (create_dwp_v2_section, dwarf2_rnglists_process)
9496 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
9497 (abbrev_table_read_table, read_indirect_string_at_offset_from)
9498 (read_indirect_string_from_dwz, read_addr_index_1)
9499 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
9500 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9501 (fill_in_loclist_baton): Update.
9502 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
9503 get_containing_section, get_bfd_owner, get_bfd_section,
9504 get_file_name, get_id, get_flags, empty, read>: Declare methods.
9505 (dwarf2_read_section, get_section_name, get_section_file_name)
9506 (get_containing_section, get_section_bfd_owner)
9507 (get_section_bfd_section, get_section_name, get_section_file_name)
9508 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
9509 declare.
9510 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
9511 (dwarf2_section_info::get_bfd_owner)
9512 (dwarf2_section_info::get_bfd_section)
9513 (dwarf2_section_info::get_name)
9514 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
9515 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
9516 (dwarf2_section_info::read): Now methods.
9517 * dwarf-index-write.c (class debug_names): Update.
9518
9519 2020-02-08 Tom Tromey <tom@tromey.com>
9520
9521 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
9522 Move to dwarf2/section.h.
9523 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
9524 (get_section_bfd_section, get_section_name)
9525 (get_section_file_name, get_section_id, get_section_flags)
9526 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
9527 dwarf2/section.c.
9528 * dwarf2/section.h: New file.
9529 * dwarf2/section.c: New file, from dwarf2read.c.
9530 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
9531
9532 2020-02-08 Tom Tromey <tom@tromey.com>
9533
9534 * dwarf2read.h (read_unsigned_leb128): Don't declare.
9535 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
9536 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
9537 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
9538 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
9539 * dwarf2/leb.h: New file, from dwarf2read.c.
9540 * dwarf2/leb.c: New file, from dwarf2read.c.
9541 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
9542 Remove.
9543 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
9544 (COMMON_SFILES): Add dwarf2/leb.c.
9545
9546 2020-02-08 Joel Brobecker <brobecker@adacore.com>
9547
9548 GDB 9.1 released.
9549
9550 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
9551
9552 PR gdb/25190:
9553 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
9554 * gdb/remote.c (remote_console_output): Update.
9555 * gdb/ui-file.c (fputs_unfiltered): Rename to...
9556 (ui_file_puts): ...this.
9557 * gdb/ui-file.h (ui_file_puts): Add declaration.
9558 * gdb/utils.c (emit_style_escape): Update.
9559 (flush_wrap_buffer): Update.
9560 (fputs_maybe_filtered): Update.
9561 (fputs_unfiltered): Add function.
9562
9563 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
9564
9565 * gdb/event-loop.c (gdb_wait_for_event): Update.
9566 * gdb/printcmd.c (printf_command): Update.
9567 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
9568 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
9569 (gdb_os_flush_stderr): Update.
9570 * gdb/remote.c (remote_console_output): Update.
9571 * gdb/ui-file.c (gdb_flush): Rename to...
9572 (ui_file_flush): ...this.
9573 (stderr_file::write): Update.
9574 (stderr_file::puts): Update.
9575 * gdb/ui-file.h (gdb_flush): Rename to...
9576 (ui_file_flush): ...this.
9577 * gdb/utils.c (gdb_flush): Add function.
9578 * gdb/utils.h (gdb_flush): Add declaration.
9579
9580 2020-02-07 Tom Tromey <tromey@adacore.com>
9581
9582 PR breakpoints/24915:
9583 * source.c (find_and_open_source): Do not check basenames_may_differ.
9584
9585 2020-02-07 Tom Tromey <tom@tromey.com>
9586
9587 * README: Update gdbserver documentation.
9588 * gdbserver: Move to top level.
9589 * configure.tgt (build_gdbserver): Remove.
9590 * configure.ac: Remove --enable-gdbserver.
9591 * configure: Rebuild.
9592 * Makefile.in (distclean): Don't mention gdbserver.
9593
9594 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
9595
9596 * source-cache.c (source_cache::ensure): Surround
9597 get_plain_source_lines with a try/catch.
9598 (source_cache::get_line_charpos): Get rid of try/catch
9599 and only check for the return value of "ensure".
9600 * tui/tui-source.c (tui_source_window::set_contents):
9601 Simplify "nlines" calculation.
9602
9603 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
9604
9605 * MAINTAINERS (Write After Approval): Add myself.
9606
9607 2020-02-05 Christian Biesinger <cbiesinger@google.com>
9608
9609 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
9610 function call.
9611
9612 2020-02-05 Christian Biesinger <cbiesinger@google.com>
9613
9614 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
9615
9616 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
9617
9618 * nat/riscv-linux-tdesc.h: New file.
9619 * nat/riscv-linux-tdesc.c: New file, taking code from...
9620 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
9621 ... here.
9622 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
9623 NATDEPFILES.
9624
9625 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
9626
9627 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
9628 we don't set the fake simulator ptid to the null_ptid.
9629
9630 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
9631
9632 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
9633 * gdbthread.h (class thread_info) <resumed>: Likewise.
9634 * infrun.c (resume_1): Likewise.
9635 (proceed): Likewise.
9636 (infrun_thread_stop_requested): Likewise.
9637 (stop_all_threads): Likewise.
9638 (handle_inferior_event): Likewise.
9639 (restart_threads): Likewise.
9640 (finish_step_over): Likewise.
9641 (keep_going_stepped_thread): Likewise.
9642 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
9643 (linux_handle_extended_wait): Likewise.
9644 * record-btrace.c (get_thread_current_frame_id): Likewise.
9645 * record-full.c (record_full_wait_1): Likewise.
9646 * remote.c (remote_target::process_initial_stop_replies): Likewise.
9647 * target.c (target_resume): Likewise.
9648 * thread.c (set_running_thread): Likewise.
9649
9650 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
9651
9652 * f-valprint.c (f77_print_array_1): Changed datatype of index
9653 variable to LONGEST from int to enable it to contain bound
9654 values correctly.
9655
9656 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
9657
9658 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
9659 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
9660 offsets according to FLEN determined.
9661 (riscv_linux_nat_target::read_description): Determine FLEN
9662 dynamically.
9663 (riscv_linux_nat_target::fetch_registers): Size regset buffer
9664 according to FLEN determined.
9665 (riscv_linux_nat_target::store_registers): Likewise.
9666
9667 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
9668
9669 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
9670 when reg->group is empty and reggroup is not.
9671
9672 2020-01-31 Tom Tromey <tromey@adacore.com>
9673
9674 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
9675 Call beneath target's mourn_inferior after unpushing.
9676
9677 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
9678
9679 PR tui/9765
9680 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
9681 have enough lines to fill the screen, still return the lowest
9682 address we found.
9683
9684 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
9685
9686 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
9687 '-', '<', and '>' commands.
9688
9689 2020-01-29 Pedro Alves <palves@redhat.com>
9690 Sergio Durigan Junior <sergiodj@redhat.com>
9691
9692 * infcmd.c (construct_inferior_arguments): Assert that
9693 'argc' is greater than 0.
9694
9695 2020-01-29 Luis Machado <luis.machado@linaro.org>
9696
9697 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
9698 (BRK_INSN_MASK): Define to 0xd4200000.
9699 (aarch64_program_breakpoint_here_p): New function.
9700 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
9701 * arch-utils.c (default_program_breakpoint_here_p): Moved from
9702 breakpoint.c.
9703 * arch-utils.h (default_program_breakpoint_here_p): Moved from
9704 breakpoint.h
9705 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
9706 call gdbarch_program_breakpoint_here_p.
9707 (program_breakpoint_here): Moved to arch-utils.c, renamed to
9708 default_program_breakpoint_here_p, changed return type to bool and
9709 simplified.
9710 * breakpoint.h (program_breakpoint_here): Moved prototype to
9711 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
9712 return type to bool.
9713 * gdbarch.c: Regenerate.
9714 * gdbarch.h: Regenerate.
9715 * gdbarch.sh (program_breakpoint_here_p): New method.
9716 * infrun.c (handle_signal_stop): Call
9717 gdbarch_program_breakpoint_here_p.
9718
9719 2020-01-26 Tom Tromey <tom@tromey.com>
9720
9721 * ctfread.c (struct ctf_fp_info): Reindent.
9722 (_initialize_ctfread): Remove.
9723
9724 2020-01-26 Tom Tromey <tom@tromey.com>
9725
9726 * psymtab.c (partial_map_expand_apply)
9727 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
9728 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
9729 (psym_print_stats, psym_expand_symtabs_for_function)
9730 (psym_map_symbol_filenames, psym_map_matching_symbols)
9731 (psym_expand_symtabs_matching)
9732 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
9733 (maintenance_check_psymtabs): Use new methods.
9734 * psympriv.h (struct partial_symtab) <readin_p,
9735 get_compunit_symtab>: New methods.
9736 <readin, compunit_symtab>: Remove members.
9737 (struct standard_psymtab): New.
9738 (struct legacy_psymtab): Derive from standard_psymtab.
9739 * dwarf2read.h (struct dwarf2_psymtab): Derive from
9740 standard_psymtab.
9741 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
9742
9743 2020-01-26 Tom Tromey <tom@tromey.com>
9744
9745 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
9746 read_dependencies. Add assert.
9747 * psymtab.c (partial_symtab::read_dependencies): New method.
9748 * psympriv.h (struct partial_symtab) <read_dependencies>: New
9749 method.
9750 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
9751 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
9752 read_dependencies.
9753 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
9754 Add assert.
9755
9756 2020-01-26 Tom Tromey <tom@tromey.com>
9757
9758 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
9759 Call expand_psymtab.
9760 (xcoff_read_symtab): Call expand_psymtab.
9761 (xcoff_start_psymtab, xcoff_end_psymtab): Set
9762 legacy_expand_psymtab.
9763 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
9764 method.
9765 (struct legacy_psymtab) <expand_psymtab>: Implement.
9766 <legacy_expand_psymtab>: New member.
9767 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
9768 (parse_partial_symbols): Set legacy_expand_psymtab.
9769 (psymtab_to_symtab_1): Change argument order. Call
9770 expand_psymtab.
9771 (new_psymtab): Set legacy_expand_psymtab.
9772 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
9773 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
9774 expand_psymtab.
9775 (dwarf2_psymtab::expand_psymtab): Rename from
9776 psymtab_to_symtab_1. Call expand_psymtab.
9777 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
9778 (dbx_end_psymtab): Likewise.
9779 (dbx_psymtab_to_symtab_1): Change argument order. Call
9780 expand_psymtab.
9781 (dbx_read_symtab): Call expand_psymtab.
9782 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
9783 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
9784 (ctf_psymtab::read_symtab): Call expand_psymtab.
9785
9786 2020-01-26 Tom Tromey <tom@tromey.com>
9787
9788 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
9789 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
9790 messages.
9791 * mdebugread.c (mdebug_read_symtab): Remove prints.
9792 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
9793 assert.
9794 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
9795
9796 2020-01-26 Tom Tromey <tom@tromey.com>
9797
9798 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
9799 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
9800 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
9801 legacy_symtab.
9802 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
9803 * psymtab.c (psymtab_to_symtab): Call method.
9804 (dump_psymtab): Update.
9805 * psympriv.h (struct partial_symtab): Add virtual destructor.
9806 <read_symtab>: New method.
9807 (struct legacy_symtab): New.
9808 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
9809 (struct pst_map) <pst>: Now a legacy_psymtab.
9810 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
9811 (new_psymtab): Use legacy_psymtab.
9812 * dwarf2read.h (struct dwarf2_psymtab): New.
9813 (struct dwarf2_per_cu_data) <psymtab>: Use it.
9814 * dwarf2read.c (dwarf2_create_include_psymtab)
9815 (dwarf2_build_include_psymtabs, create_type_unit_group)
9816 (create_partial_symtab, process_psymtab_comp_unit_reader)
9817 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
9818 (set_partial_user): Use dwarf2_psymtab.
9819 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
9820 (psymtab_to_symtab_1, process_full_comp_unit)
9821 (process_full_type_unit, dwarf2_ranges_read)
9822 (dwarf2_get_pc_bounds, psymtab_include_file_name)
9823 (dwarf_decode_lines): Use dwarf2_psymtab.
9824 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
9825 (add_address_entry_worker, write_one_signatured_type)
9826 (recursively_count_psymbols, recursively_write_psymbols)
9827 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
9828 (write_debug_names): Likewise.
9829 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
9830 <pst>: Now a legacy_psymtab.
9831 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
9832 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
9833 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
9834 * ctfread.c (struct ctf_psymtab): New.
9835 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
9836 ctf_psymtab.
9837 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
9838 (create_partial_symtab): Return a ctf_psymtab.
9839 (scan_partial_symbols): Update.
9840
9841 2020-01-26 Tom Tromey <tom@tromey.com>
9842
9843 * xcoffread.c (xcoff_start_psymtab): Use new.
9844 * psymtab.c (partial_symtab::partial_symtab): New constructor,
9845 renamed from start_psymtab_common.
9846 * psympriv.h (struct partial_symtab): Add new constructor.
9847 (start_psymtab_common): Don't declare.
9848 * mdebugread.c (parse_partial_symbols): Use new.
9849 * dwarf2read.c (create_partial_symtab): Use new.
9850 * dbxread.c (start_psymtab): Use new.
9851 * ctfread.c (create_partial_symtab): Use new.
9852
9853 2020-01-26 Tom Tromey <tom@tromey.com>
9854
9855 * xcoffread.c (xcoff_end_psymtab): Use new.
9856 * psymtab.c (start_psymtab_common): Use new.
9857 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
9858 Update.
9859 * psympriv.h (struct partial_symtab): Add parameters to
9860 constructor. Don't inline.
9861 (allocate_psymtab): Don't declare.
9862 * mdebugread.c (new_psymtab): Use new.
9863 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
9864 * dbxread.c (dbx_end_psymtab): Use new.
9865
9866 2020-01-26 Tom Tromey <tom@tromey.com>
9867
9868 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
9869 allocate_psymtab. Update documentation.
9870 * psymtab.c (psymtab_storage::install_psymtab): Rename from
9871 allocate_psymtab. Do not use new.
9872 (allocate_psymtab): Use new. Update.
9873
9874 2020-01-26 Tom Tromey <tom@tromey.com>
9875
9876 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
9877 * psymtab.c (psym_print_stats): Update.
9878 * psympriv.h (struct partial_symtab) <readin,
9879 psymtabs_addrmap_supported, anonymous>: Now bool.
9880 * mdebugread.c (psymtab_to_symtab_1): Update.
9881 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
9882 (build_type_psymtabs_reader, psymtab_to_symtab_1)
9883 (process_full_comp_unit, process_full_type_unit): Update.
9884 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
9885 * ctfread.c (psymtab_to_symtab): Update.
9886
9887 2020-01-26 Tom Tromey <tom@tromey.com>
9888
9889 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
9890 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
9891 * psymtab.c (psymtab_storage): Delete psymtabs.
9892 (psymtab_storage::allocate_psymtab): Use new.
9893 (psymtab_storage::discard_psymtab): Use delete.
9894 * psympriv.h (struct partial_symtab): Add constructor and
9895 initializers.
9896
9897 2020-01-26 Tom Tromey <tom@tromey.com>
9898
9899 * machoread.c: Do not include psympriv.h.
9900
9901 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9902
9903 * NEWS: Mention the new option and the set/show commands.
9904
9905 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9906
9907 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
9908 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
9909 (validate_exec_file): New variables, enums, functions.
9910 (exec_file_locate_attach, print_section_info): Style the filenames.
9911 (_initialize_exec): Install show_exec_file_mismatch_command and
9912 set_exec_file_mismatch_command.
9913 * gdbcore.h (validate_exec_file): Declare.
9914 * infcmd.c (attach_command): Call validate_exec_file.
9915 * remote.c ( remote_target::remote_add_inferior): Likewise.
9916
9917 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9918
9919 * frame.c (find_frame_sal): Move call to get_next_frame into more
9920 inner scope.
9921 * inline-frame.c (inilne_state) <inline_state>: Update argument
9922 types.
9923 (inilne_state) <skipped_symbol>: Rename to...
9924 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
9925 (skip_inline_frames): Build vector of skipped symbols and use this
9926 to reate the inline_state.
9927 (inline_skipped_symbol): Add a comment and some assertions, fetch
9928 skipped symbol from the list.
9929
9930 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9931
9932 * buildsym.c (lte_is_less_than): Delete.
9933 (buildsym_compunit::end_symtab_with_blockvector): Create local
9934 lambda function to sort line table entries, and use
9935 std::stable_sort instead of std::sort.
9936 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
9937 markers when looking for a previous line.
9938
9939 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9940
9941 * dwarf2read.c (lnp_state_machine::record_line): Include
9942 end_sequence parameter in debug print out. Record the line if we
9943 are at an end_sequence marker even if it's not the start of a
9944 statement.
9945 * symmisc.c (maintenance_print_one_line_table): Print end of
9946 sequence markers with 'END' not '0'.
9947
9948 2020-01-24 Pedro Alves <palves@redhat.com>
9949
9950 PR gdb/25410
9951 * thread.c (scoped_restore_current_thread::restore): Use
9952 switch_to_inferior_no_thread.
9953 * exec.c: Include "progspace-and-thread.h".
9954 (add_target_sections, remove_target_sections):
9955 scoped_restore_current_pspace_and_thread instead of
9956 scoped_restore_current_thread.
9957 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
9958 and aspace to the inferior before calling clone_program_space.
9959 Remove stale comment.
9960
9961 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9962
9963 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
9964 (arm_netbsd_nat_target::fetch_registers): ...this.
9965 (arm_nbsd_nat_target::store_registers): Rename to...
9966 (arm_netbsd_nat_target::store_registers): ...this.
9967
9968 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9969
9970 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
9971 register_t.
9972
9973 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9974
9975 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
9976 Update comment.
9977 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
9978 Likewise.
9979 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
9980 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
9981 the correct replacement (iterate_over_regset_sections).
9982 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
9983 Update comment.
9984
9985 2020-01-24 Graham Markall <graham.markall@embecosm.com>
9986
9987 PR gdb/23718
9988 * gdb/python/python.c (execute_gdb_command): Call
9989 async_enable_stdin in catch block.
9990
9991 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9992
9993 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
9994 SWITCH_THRU_ALL_UIS.
9995
9996 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9997
9998 PR tui/9765
9999 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
10000 comment, add extra parameter, and update to store previous symbol
10001 when appropriate.
10002 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
10003 add extra parameter.
10004 * tui/tui-disasm.c (tui_disassemble): Update header comment,
10005 remove unneeded parameter, add try/catch around gdb_print_insn,
10006 rewrite to add items to asm_lines vector.
10007 (tui_find_backward_disassembly_start_address): New function.
10008 (tui_find_disassembly_address): Updated throughout.
10009 (tui_disasm_window::set_contents): Update for changes to
10010 tui_disassemble.
10011 (tui_disasm_window::do_scroll_vertical): No need to adjust the
10012 number of lines to scroll.
10013
10014 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
10015
10016 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
10017 (SECT_OFF_DATA): Likewise.
10018 (SECT_OFF_RODATA): Likewise.
10019 (SECT_OFF_TEXT): Likewise.
10020 (SECT_OFF_BSS): Likewise.
10021 (struct objfile) <text_section_offset, data_section_offset>: New
10022 methods.
10023 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
10024 objfile::text_section_offset.
10025 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
10026 * coffread.c (coff_symtab_read): Likewise.
10027 (enter_linenos): Likewise.
10028 (process_coff_symbol): Likewise.
10029 * ctfread.c (get_objfile_text_range): Likewise.
10030 * dtrace-probe.c (dtrace_probe::get_relocated_address):
10031 Use objfile::data_section_offset.
10032 * dwarf2-frame.c (execute_cfa_program): Use
10033 objfile::text_section_offset.
10034 (dwarf2_frame_find_fde): Likewise.
10035 * dwarf2read.c (create_addrmap_from_index): Likewise.
10036 (create_addrmap_from_aranges): Likewise.
10037 (dw2_find_pc_sect_compunit_symtab): Likewise.
10038 (process_psymtab_comp_unit_reader): Likewise.
10039 (add_partial_symbol): Likewise.
10040 (add_partial_subprogram): Likewise.
10041 (process_full_comp_unit): Likewise.
10042 (read_file_scope): Likewise.
10043 (read_func_scope): Likewise.
10044 (read_lexical_block_scope): Likewise.
10045 (read_call_site_scope): Likewise.
10046 (dwarf2_rnglists_process): Likewise.
10047 (dwarf2_ranges_process): Likewise.
10048 (dwarf2_ranges_read): Likewise.
10049 (dwarf_decode_lines_1): Likewise.
10050 (new_symbol): Likewise.
10051 (dwarf2_fetch_die_loc_sect_off): Likewise.
10052 (dwarf2_per_cu_text_offset): Likewise.
10053 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
10054 * hppa-tdep.c (read_unwind_info): Likewise.
10055 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
10056 * psympriv.h (struct partial_symtab): Likewise.
10057 * psymtab.c (find_pc_sect_psymtab): Likewise.
10058 * solib-svr4.c (enable_break): Likewise.
10059 * stap-probe.c (relocate_address): Use
10060 objfile::data_section_offset.
10061 * xcoffread.c (enter_line_range): Use
10062 objfile::text_section_offset.
10063 (read_xcoff_symtab): Likewise.
10064
10065 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
10066
10067 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
10068 declaration to narrower scopes.
10069
10070 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
10071
10072 * darwin-nat.h (struct darwin_exception_msg, enum
10073 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
10074 Move up.
10075 (class darwin_nat_target) <wait_1, check_new_threads,
10076 decode_exception_message, decode_message, stop_inferior,
10077 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
10078 * darwin-nat.c (darwin_check_new_threads): Rename to...
10079 (darwin_nat_target::check_new_threads): ... this.
10080 (darwin_suspend_inferior_it): Remove.
10081 (darwin_decode_exception_message): Rename to...
10082 (darwin_nat_target::decode_exception_message): ... this.
10083 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
10084 (darwin_decode_message): Rename to...
10085 (darwin_nat_target::decode_message): ... this.
10086 (cancel_breakpoint): Rename to...
10087 (darwin_nat_target::cancel_breakpoint): ... this.
10088 (darwin_wait): Rename to...
10089 (darwin_nat_target::wait_1): ... this. Use range-based for loop
10090 instead of iterate_over_inferiors.
10091 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
10092 (darwin_stop_inferior): Rename to...
10093 (darwin_nat_target::stop_inferior): ... this.
10094 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
10095 (darwin_init_thread_list): Rename to...
10096 (darwin_nat_target::init_thread_list): ... this.
10097 (darwin_ptrace_him): Rename to...
10098 (darwin_nat_target::ptrace_him): ... this.
10099 (darwin_nat_target::create_inferior): Pass lambda function to
10100 fork_inferior.
10101 (darwin_nat_target::detach): Call stop_inferior instead of
10102 darwin_stop_inferior.
10103 * fork-inferior.h (fork_inferior): Change init_trace_fun
10104 parameter to gdb::function_view.
10105 * fork-inferior.c (fork_inferior): Likewise.
10106
10107 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
10108
10109 * i386-cygwin-tdep.c (core_process_module_section): Update.
10110 * windows-nat.c (struct lm_info_windows): Add text_offset.
10111 (windows_xfer_shared_libraries): Update.
10112 * windows-tdep.c (windows_xfer_shared_library):
10113 Add text_offset_cached argument.
10114 * windows-tdep.h (windows_xfer_shared_library): Update.
10115
10116 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10117
10118 * gdbarch.sh: Add declaration for _initialize_gdbarch.
10119
10120 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10121
10122 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
10123 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
10124 replace with range-based for.
10125 (gdbsim_interrupt_inferior): Remove.
10126 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
10127 with a range-based for. Inline code from
10128 gdbsim_interrupt_inferior.
10129
10130 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10131
10132 * infrun.c (proceed): Fix indentation.
10133
10134 2020-01-21 Tom Tromey <tromey@adacore.com>
10135
10136 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
10137 * python/python.c (python_extension_ops): Update.
10138 (gdbpy_colorize): New function.
10139 * python/lib/gdb/__init__.py (colorize): New function.
10140 * extension.h (ext_lang_colorize): Declare.
10141 * extension.c (ext_lang_colorize): New function.
10142 * extension-priv.h (struct extension_language_ops) <colorize>: New
10143 member.
10144 * cli/cli-style.c (_initialize_cli_style): Update help text.
10145
10146 2020-01-21 Luis Machado <luis.machado@linaro.org>
10147
10148 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
10149 <cond>: Change type to bool.
10150 (aarch64_displaced_step_b_cond): Update cond to use bool type.
10151 (aarch64_displaced_step_cb): Likewise.
10152 (aarch64_displaced_step_tb): Likewise.
10153
10154 2020-01-21 Luis Machado <luis.machado@linaro.org>
10155
10156 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
10157 output.
10158
10159 2020-01-21 Luis Machado <luis.machado@linaro.org>
10160
10161 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
10162 <pc_adjust>: Adjust the documentation.
10163 (aarch64_displaced_step_fixup): Check if PC really moved before
10164 adjusting it.
10165
10166 2020-01-19 Tom Tromey <tom@tromey.com>
10167
10168 * disasm.c (~gdb_disassembler): New destructor.
10169 (gdb_buffered_insn_length): Call disassemble_free_target.
10170 * disasm.h (class gdb_disassembler): Declare destructor. Use
10171 DISABLE_COPY_AND_ASSIGN.
10172
10173 2020-01-19 Tom Tromey <tom@tromey.com>
10174
10175 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
10176 (die_reader_func_ftype): Remove.
10177 (cutu_reader): New class.
10178 (dw2_get_file_names_reader): Remove "data" parameter.
10179 (dw2_get_file_names): Use cutu_reader.
10180 (create_debug_type_hash_table): Update.
10181 (read_cutu_die_from_dwo): Update comment.
10182 (lookup_dwo_unit): Add dwo_name parameter.
10183 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
10184 die_reader_func_ftype and data parameters.
10185 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
10186 Remove die_reader_func_ftype and data parameters.
10187 (~cutu_reader): New; from init_cutu_and_read_dies.
10188 (cutu_reader::cutu_reader): Rename from
10189 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
10190 and data parameters.
10191 (init_cutu_and_read_dies_simple): Remove.
10192 (struct process_psymtab_comp_unit_data): Remove.
10193 (process_psymtab_comp_unit_reader): Remove data parameter; add
10194 want_partial_unit and pretend_language parameters.
10195 (process_psymtab_comp_unit): Use cutu_reader.
10196 (build_type_psymtabs_reader): Remove data parameter.
10197 (build_type_psymtabs_1): Use cutu_reader.
10198 (process_skeletonless_type_unit): Likewise.
10199 (load_partial_comp_unit_reader): Remove.
10200 (load_partial_comp_unit): Use cutu_reader.
10201 (load_full_comp_unit_reader): Remove.
10202 (load_full_comp_unit): Use cutu_reader.
10203 (struct create_dwo_cu_data): Remove.
10204 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
10205 dwo_unit parameters.
10206 (create_cus_hash_table): Use cutu_reader.
10207 (struct dwarf2_read_addr_index_data): Remove.
10208 (dwarf2_read_addr_index_reader): Remove.
10209 (dwarf2_read_addr_index): Use cutu_reader.
10210 (read_signatured_type_reader): Remove.
10211 (read_signatured_type): Use cutu_reader.
10212
10213 2020-01-19 Tom Tromey <tom@tromey.com>
10214
10215 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
10216 * tui/tui-wingeneral.h (class tui_suppress_output): New.
10217 (tui_wrefresh): Declare.
10218 * tui/tui-wingeneral.c (suppress_output): New global.
10219 (tui_suppress_output, ~tui_suppress_output): New constructor and
10220 destructor.
10221 (tui_wrefresh): New function.
10222 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
10223 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
10224 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
10225 method.
10226 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
10227 tui_wrefresh.
10228 (tui_data_window::no_refresh): New method.
10229 (tui_data_item_window::refresh_window): Call tui_wrefresh.
10230 (tui_reg_command): Use tui_suppress_output
10231 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
10232 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
10233 method.
10234 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
10235
10236 2020-01-19 Tom Tromey <tom@tromey.com>
10237
10238 * tui/tui-winsource.c (tui_update_source_windows_with_line):
10239 Handle case where symtab is null.
10240
10241 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
10242
10243 * linux-fork.c (one_fork_p): Simplify.
10244
10245 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10246
10247 * top.c (struct qt_args): Remove.
10248 (kill_or_detach): Change return type to void, replace `void *`
10249 parameter with a proper one.
10250 (print_inferior_quit_action): Likewise.
10251 (quit_confirm): Use range-based for loop to iterate over inferiors.
10252 (quit_force): Likewise.
10253
10254 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10255
10256 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
10257 `void *` parameter with proper parameters.
10258 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
10259 (print_one_inferior): Change return type to void, replace `void *`
10260 parameter with proper parameters.
10261 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
10262 inferiors.
10263 (get_other_inferior): Remove.
10264 (mi_cmd_remove_inferior): Use range-based loop to iterate over
10265 inferiors.
10266
10267 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10268
10269 * mi/mi-interp.c (report_initial_inferior): Remove.
10270 (mi_interp::init): Use range-based for to iterate over inferiors.
10271
10272 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10273
10274 * python/py-inferior.c (build_inferior_list): Remove.
10275 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
10276
10277 2020-01-16 Christian Biesinger <cbiesinger@google.com>
10278
10279 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
10280 (btrace_stitch_trace): Likewise.
10281 * charset.c (intermediate_encoding): Likewise (vaild).
10282 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
10283 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
10284 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
10285
10286 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
10287
10288 * windows-tdep.c (windows_get_tlb_type):
10289 Add rtl_user_process_parameters type.
10290
10291 2020-01-16 Pedro Alves <palves@redhat.com>
10292 Norbert Lange <nolange79@gmail.com>
10293
10294 PR build/24805
10295 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
10296 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
10297 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
10298 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
10299 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
10300 (ps_plog): Redeclare exported functions with default visibility.
10301
10302 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
10303
10304 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
10305 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
10306
10307 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
10308
10309 * infcmd.c (post_create_inferior): Use get_thread_regcache
10310 instead of get_current_regcache.
10311
10312 2020-01-14 Tom Tromey <tom@tromey.com>
10313
10314 PR symtab/12535:
10315 * python/python.c (gdbpy_decode_line): Treat empty string the same
10316 as no argument.
10317
10318 2020-01-14 Tom Tromey <tom@tromey.com>
10319
10320 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
10321
10322 2020-01-14 Tom Tromey <tom@tromey.com>
10323
10324 * nat/linux-btrace.c: Don't include <config.h>.
10325 * nat/linux-ptrace.c: Don't include <config.h>.
10326 * nat/x86-linux-dregs.c: Don't include <config.h>.
10327
10328 2020-01-14 Tom Tromey <tom@tromey.com>
10329
10330 * configure: Rebuild.
10331 * configure.ac: Move many checks to ../gdbsupport/common.m4.
10332
10333 2020-01-14 Tom Tromey <tom@tromey.com>
10334
10335 * nat/x86-linux-dregs.c: Include configh.h.
10336 * nat/linux-ptrace.c: Include configh.h.
10337 * nat/linux-btrace.c: Include configh.h.
10338 * defs.h: Include config.h, bfd.h.
10339 * configure.ac: Don't source common.host.
10340 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
10341 * configure: Rebuild.
10342 * acinclude.m4: Update path.
10343 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
10344 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
10345 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
10346 (CLIBS): Add LIBSUPPORT.
10347 (CDEPS): Likewise.
10348 (COMMON_SFILES): Remove gdbsupport files.
10349 (HFILES_NO_SRCDIR): Likewise.
10350 (stamp-version): Update path to create-version.sh.
10351 (ALLDEPFILES): Remove gdbsupport files.
10352
10353 2020-01-14 Tom Tromey <tom@tromey.com>
10354
10355 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
10356 USE_WIN32API when needed.
10357 * configure.ac (USE_WIN32API): Don't define.
10358 (WIN32LIBS): Use WIN32APILIBS.
10359 * configure: Rebuild.
10360
10361 2020-01-14 Tom Tromey <tom@tromey.com>
10362
10363 * configure: Rebuild.
10364 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
10365
10366 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10367
10368 * skip.c (skip_function_command): Make skip w/o arguments use the
10369 name of the inlined function if pc is inside any inlined function.
10370
10371 2020-01-14 Luis Machado <luis.machado@linaro.org>
10372
10373 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
10374 * infrun.c (resume_1): Likewise.
10375 (handle_inferior_event): Remove stale comment.
10376 * linux-nat.c (linux_nat_target::resume): Update comments.
10377 (save_stop_reason): Likewise.
10378 (linux_nat_filter_event): Likewise.
10379 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
10380
10381 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
10382
10383 * elfread.c (record_minimal_symbol): Set section index to 0 for
10384 non-allocatable sections.
10385
10386
10387 2020-01-13 Ali Tamur <tamur@google.com>
10388
10389 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
10390 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
10391 to gdb::optional. Update comments.
10392 (dwo_file): Update comments.
10393 (read_attribute): Update API to take an additional out parameter,
10394 need_reprocess. This is used to mark attributes that need other
10395 attributes (e.g. str_offsets_base) for correct computation which may not
10396 have been read yet.
10397 (read_attribute_reprocess): New function declaration.
10398 (read_addr_index): Likewise.
10399 (read_dwo_str_index): Likewise.
10400 (read_stub_str_index): Likewise.
10401 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
10402 (lookup_addr_base): New function definition.
10403 (lookup_ranges_base): Likewise.
10404 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
10405 lookup_ranges_base.
10406 (init_cutu_and_read_dies): Update comments.
10407 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
10408 unit. This is used to inherit parent's str_offsets_base and addr_base.
10409 Update comments.
10410 (init_cutu_and_read_dies_simple): Reflect API changes.
10411 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
10412 (create_cus_hash_table): Change API to take parent compile unit.
10413 Reflect API changes.
10414 (open_and_init_dwo_file): Reflect API changes.
10415 (dwarf2_get_pc_bounds): Update comments.
10416 (dwarf2_record_block_ranges): Likewise.
10417 (read_full_die_1): Change implementation to reprocess attributes that
10418 need str_offsets_base and addr_base.
10419 (partial_die_info::read): Likewise.
10420 (read_attribute_reprocess): New function definition.
10421 (read_attribute_value): Change API to take an additional out parameter,
10422 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
10423 when a non-dwo compile unit has index based attributes.
10424 (read_attribute): Reflect API changes.
10425 (read_addr_index_1): Reflect API changes. Update comments.
10426 (dwarf2_read_addr_index_data): Reflect API changes.
10427 (dwarf2_read_addr_index): Likewise.
10428 (read_str_index): Change API and implementation. This becomes a helper
10429 to be used by the new string index related methods. Update error
10430 message and comments.
10431 (read_dwo_str_index): New function definition.
10432 (read_stub_str_index): Likewise.
10433 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
10434 * symfile.h (dwarf2_debug_sections): Likewise.
10435 * xcoffread.c (dwarf2_debug_sections): Likewise.
10436
10437 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
10438
10439 * gdbcore.h (struct core_fns) <core_read_registers>: Change
10440 core_reg_sect type to gdb_byte *.
10441 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
10442 * cris-tdep.c (fetch_core_registers): Likewise.
10443 * corelow.c (core_target::get_core_register_section): Change
10444 type of `contents` to gdb::byte_vector.
10445
10446 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
10447
10448 * tui/tui-wingeneral.c (box_win): Position the title in the center
10449 of the border.
10450
10451 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10452
10453 * corelow.c (core_target::get_core_register_section): Use
10454 std::vector instead of alloca.
10455
10456 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
10457
10458 * warning.m4: Add -Wmissing-declarations to build_warnings.
10459 * configure: Re-generate.
10460
10461 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
10462
10463 * python/python.c (init__gdb_module): Add declaration.
10464
10465 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
10466
10467 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
10468 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
10469 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
10470 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
10471 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
10472 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
10473 * ada-exp.y (_initialize_ada_exp): Add declaration.
10474 * ada-lang.c (_initialize_ada_language): Add declaration.
10475 * ada-tasks.c (_initialize_tasks): Add declaration.
10476 * agent.c (_initialize_agent): Add declaration.
10477 * aix-thread.c (_initialize_aix_thread): Add declaration.
10478 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
10479 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
10480 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
10481 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
10482 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
10483 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
10484 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
10485 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
10486 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
10487 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
10488 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
10489 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
10490 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
10491 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
10492 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
10493 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
10494 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
10495 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
10496 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
10497 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
10498 * annotate.c (_initialize_annotate): Add declaration.
10499 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
10500 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
10501 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
10502 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
10503 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
10504 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
10505 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
10506 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
10507 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
10508 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
10509 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
10510 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
10511 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
10512 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
10513 * auto-load.c (_initialize_auto_load): Add declaration.
10514 * auxv.c (_initialize_auxv): Add declaration.
10515 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
10516 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
10517 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
10518 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
10519 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
10520 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
10521 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
10522 * breakpoint.c (_initialize_breakpoint): Add declaration.
10523 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
10524 * btrace.c (_initialize_btrace): Add declaration.
10525 * charset.c (_initialize_charset): Add declaration.
10526 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
10527 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
10528 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
10529 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
10530 * cli/cli-script.c (_initialize_cli_script): Add declaration.
10531 * cli/cli-style.c (_initialize_cli_style): Add declaration.
10532 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
10533 * coffread.c (_initialize_coffread): Add declaration.
10534 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
10535 * compile/compile.c (_initialize_compile): Add declaration.
10536 * complaints.c (_initialize_complaints): Add declaration.
10537 * completer.c (_initialize_completer): Add declaration.
10538 * copying.c (_initialize_copying): Add declaration.
10539 * corefile.c (_initialize_core): Add declaration.
10540 * corelow.c (_initialize_corelow): Add declaration.
10541 * cp-abi.c (_initialize_cp_abi): Add declaration.
10542 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
10543 * cp-support.c (_initialize_cp_support): Add declaration.
10544 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
10545 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
10546 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
10547 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
10548 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
10549 * ctfread.c (_initialize_ctfread): Add declaration.
10550 * d-lang.c (_initialize_d_language): Add declaration.
10551 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
10552 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
10553 * dbxread.c (_initialize_dbxread): Add declaration.
10554 * dcache.c (_initialize_dcache): Add declaration.
10555 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
10556 * disasm.c (_initialize_disasm): Add declaration.
10557 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
10558 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
10559 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
10560 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
10561 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
10562 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
10563 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
10564 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
10565 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
10566 * elfread.c (_initialize_elfread): Add declaration.
10567 * exec.c (_initialize_exec): Add declaration.
10568 * extension.c (_initialize_extension): Add declaration.
10569 * f-lang.c (_initialize_f_language): Add declaration.
10570 * f-valprint.c (_initialize_f_valprint): Add declaration.
10571 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
10572 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
10573 * filesystem.c (_initialize_filesystem): Add declaration.
10574 * findcmd.c (_initialize_mem_search): Add declaration.
10575 * findvar.c (_initialize_findvar): Add declaration.
10576 * fork-child.c (_initialize_fork_child): Add declaration.
10577 * frame-base.c (_initialize_frame_base): Add declaration.
10578 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
10579 * frame.c (_initialize_frame): Add declaration.
10580 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
10581 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
10582 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
10583 * gcore.c (_initialize_gcore): Add declaration.
10584 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
10585 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
10586 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
10587 * gdbarch.c (_initialize_gdbarch): Add declaration.
10588 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
10589 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
10590 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
10591 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
10592 * go-lang.c (_initialize_go_language): Add declaration.
10593 * go32-nat.c (_initialize_go32_nat): Add declaration.
10594 * guile/guile.c (_initialize_guile): Add declaration.
10595 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
10596 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
10597 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
10598 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
10599 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
10600 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
10601 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
10602 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
10603 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
10604 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
10605 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
10606 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
10607 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
10608 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
10609 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
10610 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
10611 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
10612 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
10613 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
10614 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
10615 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
10616 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
10617 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
10618 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
10619 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
10620 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
10621 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
10622 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
10623 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
10624 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
10625 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
10626 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
10627 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
10628 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
10629 * infcall.c (_initialize_infcall): Add declaration.
10630 * infcmd.c (_initialize_infcmd): Add declaration.
10631 * inflow.c (_initialize_inflow): Add declaration.
10632 * infrun.c (_initialize_infrun): Add declaration.
10633 * interps.c (_initialize_interpreter): Add declaration.
10634 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
10635 * jit.c (_initialize_jit): Add declaration.
10636 * language.c (_initialize_language): Add declaration.
10637 * linux-fork.c (_initialize_linux_fork): Add declaration.
10638 * linux-nat.c (_initialize_linux_nat): Add declaration.
10639 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
10640 * linux-thread-db.c (_initialize_thread_db): Add declaration.
10641 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
10642 * m2-lang.c (_initialize_m2_language): Add declaration.
10643 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
10644 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
10645 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
10646 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
10647 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
10648 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
10649 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
10650 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
10651 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
10652 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
10653 * machoread.c (_initialize_machoread): Add declaration.
10654 * macrocmd.c (_initialize_macrocmd): Add declaration.
10655 * macroscope.c (_initialize_macroscope): Add declaration.
10656 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
10657 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
10658 * maint.c (_initialize_maint_cmds): Add declaration.
10659 * mdebugread.c (_initialize_mdebugread): Add declaration.
10660 * memattr.c (_initialize_mem): Add declaration.
10661 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
10662 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
10663 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
10664 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
10665 * mi/mi-main.c (_initialize_mi_main): Add declaration.
10666 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
10667 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
10668 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
10669 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
10670 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
10671 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
10672 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
10673 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
10674 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
10675 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
10676 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
10677 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
10678 * mipsread.c (_initialize_mipsread): Add declaration.
10679 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
10680 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
10681 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
10682 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
10683 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
10684 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
10685 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
10686 * nto-procfs.c (_initialize_procfs): Add declaration.
10687 * objc-lang.c (_initialize_objc_language): Add declaration.
10688 * observable.c (_initialize_observer): Add declaration.
10689 * opencl-lang.c (_initialize_opencl_language): Add declaration.
10690 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
10691 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
10692 * osabi.c (_initialize_gdb_osabi): Add declaration.
10693 * osdata.c (_initialize_osdata): Add declaration.
10694 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
10695 * parse.c (_initialize_parse): Add declaration.
10696 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
10697 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
10698 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
10699 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
10700 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
10701 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
10702 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
10703 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
10704 * printcmd.c (_initialize_printcmd): Add declaration.
10705 * probe.c (_initialize_probe): Add declaration.
10706 * proc-api.c (_initialize_proc_api): Add declaration.
10707 * proc-events.c (_initialize_proc_events): Add declaration.
10708 * proc-service.c (_initialize_proc_service): Add declaration.
10709 * procfs.c (_initialize_procfs): Add declaration.
10710 * producer.c (_initialize_producer): Add declaration.
10711 * psymtab.c (_initialize_psymtab): Add declaration.
10712 * python/python.c (_initialize_python): Add declaration.
10713 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
10714 * record-btrace.c (_initialize_record_btrace): Add declaration.
10715 * record-full.c (_initialize_record_full): Add declaration.
10716 * record.c (_initialize_record): Add declaration.
10717 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
10718 * regcache.c (_initialize_regcache): Add declaration.
10719 * reggroups.c (_initialize_reggroup): Add declaration.
10720 * remote-notif.c (_initialize_notif): Add declaration.
10721 * remote-sim.c (_initialize_remote_sim): Add declaration.
10722 * remote.c (_initialize_remote): Add declaration.
10723 * reverse.c (_initialize_reverse): Add declaration.
10724 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
10725 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
10726 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
10727 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
10728 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
10729 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
10730 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
10731 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
10732 Add declaration.
10733 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
10734 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
10735 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
10736 * rust-exp.y (_initialize_rust_exp): Add declaration.
10737 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
10738 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
10739 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
10740 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
10741 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
10742 * score-tdep.c (_initialize_score_tdep): Add declaration.
10743 * ser-go32.c (_initialize_ser_dos): Add declaration.
10744 * ser-mingw.c (_initialize_ser_windows): Add declaration.
10745 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
10746 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
10747 * ser-uds.c (_initialize_ser_socket): Add declaration.
10748 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
10749 * serial.c (_initialize_serial): Add declaration.
10750 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
10751 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
10752 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
10753 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
10754 * skip.c (_initialize_step_skip): Add declaration.
10755 * sol-thread.c (_initialize_sol_thread): Add declaration.
10756 * solib-aix.c (_initialize_solib_aix): Add declaration.
10757 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
10758 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
10759 * solib-frv.c (_initialize_frv_solib): Add declaration.
10760 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
10761 * solib-target.c (_initialize_solib_target): Add declaration.
10762 * solib.c (_initialize_solib): Add declaration.
10763 * source-cache.c (_initialize_source_cache): Add declaration.
10764 * source.c (_initialize_source): Add declaration.
10765 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
10766 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
10767 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
10768 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
10769 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
10770 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
10771 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
10772 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
10773 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
10774 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
10775 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
10776 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
10777 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
10778 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
10779 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
10780 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
10781 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
10782 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
10783 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
10784 * stabsread.c (_initialize_stabsread): Add declaration.
10785 * stack.c (_initialize_stack): Add declaration.
10786 * stap-probe.c (_initialize_stap_probe): Add declaration.
10787 * std-regs.c (_initialize_frame_reg): Add declaration.
10788 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
10789 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
10790 * symfile.c (_initialize_symfile): Add declaration.
10791 * symmisc.c (_initialize_symmisc): Add declaration.
10792 * symtab.c (_initialize_symtab): Add declaration.
10793 * target.c (_initialize_target): Add declaration.
10794 * target-connection.c (_initialize_target_connection): Add
10795 declaration.
10796 * target-dcache.c (_initialize_target_dcache): Add declaration.
10797 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
10798 * thread.c (_initialize_thread): Add declaration.
10799 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
10800 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
10801 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
10802 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
10803 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
10804 * tracectf.c (_initialize_ctf): Add declaration.
10805 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
10806 * tracefile.c (_initialize_tracefile): Add declaration.
10807 * tracepoint.c (_initialize_tracepoint): Add declaration.
10808 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
10809 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
10810 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
10811 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
10812 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
10813 * tui/tui-win.c (_initialize_tui_win): Add declaration.
10814 * tui/tui.c (_initialize_tui): Add declaration.
10815 * typeprint.c (_initialize_typeprint): Add declaration.
10816 * ui-style.c (_initialize_ui_style): Add declaration.
10817 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
10818 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
10819 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
10820 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
10821 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
10822 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
10823 * unittests/filtered_iterator-selftests.c
10824 (_initialize_filtered_iterator_selftests): Add declaration.
10825 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
10826 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
10827 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
10828 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
10829 * unittests/main-thread-selftests.c
10830 (_initialize_main_thread_selftests): Add declaration.
10831 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
10832 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
10833 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
10834 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
10835 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
10836 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
10837 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
10838 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
10839 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
10840 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
10841 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
10842 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
10843 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
10844 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
10845 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
10846 declaration.
10847 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
10848 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
10849 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
10850 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
10851 * user-regs.c (_initialize_user_regs): Add declaration.
10852 * utils.c (_initialize_utils): Add declaration.
10853 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
10854 * valops.c (_initialize_valops): Add declaration.
10855 * valprint.c (_initialize_valprint): Add declaration.
10856 * value.c (_initialize_values): Add declaration.
10857 * varobj.c (_initialize_varobj): Add declaration.
10858 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
10859 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
10860 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
10861 * windows-nat.c (_initialize_windows_nat): Add declaration.
10862 (_initialize_check_for_gdb_ini): Add declaration.
10863 (_initialize_loadable): Add declaration.
10864 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
10865 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
10866 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
10867 * xcoffread.c (_initialize_xcoffread): Add declaration.
10868 * xml-support.c (_initialize_xml_support): Add declaration.
10869 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
10870 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
10871 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
10872 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
10873
10874 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10875
10876 * regformats/regdat.sh: Generate declaration for init function.
10877
10878 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10879
10880 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
10881 up.
10882 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
10883 close_one_inferior>: New methods.
10884 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
10885 pass down target to find_inferior_pid.
10886 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
10887 Pass down target to find_inferior_ptid.
10888 (gdbsim_target::create_inferior): Pass down target to
10889 add_thread_silent.
10890 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
10891 target down to find_inferior_ptid and switch_to_thread.
10892 (gdbsim_target::close): Update to call close_one_inferior.
10893 (struct resume_data): Remove.
10894 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
10895 directly, rather than through a void pointer.
10896 (gdbsim_target::resume): Update to call resume_one_inferior.
10897
10898 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
10899
10900 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
10901
10902 2020-01-12 Pedro Alves <palves@redhat.com>
10903
10904 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
10905 directly for the current inferior instead of
10906 discard_all_inferiors.
10907 (discard_all_inferiors): Delete.
10908
10909 2020-01-11 Tom Tromey <tom@tromey.com>
10910
10911 * tui/tui-wingeneral.c (box_win): Check cli_styling.
10912 * tui/tui-winsource.c (tui_source_window_base::refill): Use
10913 deprecated_safe_get_selected_frame.
10914
10915 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10916
10917 * inferior.c (print_inferior): Switch inferior before printing it.
10918
10919 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
10920 Pedro Alves <palves@redhat.com>
10921
10922 * progspace-and-thread.c (switch_to_program_space_and_thread):
10923 Assert there's an inferior for PSPACE. Use
10924 switch_to_inferior_no_thread to switch the inferior too.
10925 * progspace.c (program_space::~program_space): Call
10926 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
10927 (program_space::free_all_objfiles): Don't call clear_symtab_users
10928 here.
10929 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
10930
10931 2020-01-10 Pedro Alves <palves@redhat.com>
10932
10933 * NEWS: Mention multi-target debugging, "info connections", and
10934 "add-inferior -no-connection".
10935
10936 2020-01-10 Pedro Alves <palves@redhat.com>
10937
10938 * infrun.c: Include "target-connection.h".
10939 (check_multi_target_resumption): New.
10940 (proceed): Call it.
10941 * target-connection.c (make_target_connection_string): Make
10942 extern.
10943 * target-connection.h (make_target_connection_string): Declare.
10944
10945 2020-01-10 Pedro Alves <palves@redhat.com>
10946
10947 * Makefile.in (COMMON_SFILES): Add target-connection.c.
10948 * inferior.c (uiout_field_connection): New function.
10949 (print_inferior): Add new "connection-id" column.
10950 (add_inferior_command): Show connection number/string of added
10951 inferior.
10952 * process-stratum-target.h
10953 (process_stratum_target::connection_string): New virtual method.
10954 (process_stratum_target::connection_number): New field.
10955 * remote.c (remote_target::connection_string): New override.
10956 * target-connection.c: New file.
10957 * target-connection.h: New file.
10958 * target.c (decref_target): Remove process_stratum targets from
10959 the connection list.
10960 (target_stack::push): Add process_stratum targets to the
10961 connection list.
10962
10963 2020-01-10 Pedro Alves <palves@redhat.com>
10964
10965 Revert:
10966 2016-04-12 Pedro Alves <palves@redhat.com>
10967 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
10968 Remove references to name.
10969 * serial.h (struct serial) <name>: Delete.
10970
10971 2020-01-10 Pedro Alves <palves@redhat.com>
10972
10973 * gdbarch-selftests.c (register_to_value_test): Remove "target
10974 already pushed" check.
10975
10976 2020-01-10 Pedro Alves <palves@redhat.com>
10977 John Baldwin <jhb@FreeBSD.org>
10978
10979 * aarch64-linux-nat.c
10980 (aarch64_linux_nat_target::thread_architecture): Adjust.
10981 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
10982 (task_command_1): Likewise.
10983 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
10984 (aix_thread_target::wait, aix_thread_target::fetch_registers)
10985 (aix_thread_target::store_registers)
10986 (aix_thread_target::thread_alive): Adjust.
10987 * amd64-fbsd-tdep.c: Include "inferior.h".
10988 (amd64fbsd_get_thread_local_address): Pass down target.
10989 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
10990 thread's gdbarch instead of target_gdbarch.
10991 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
10992 get_last_target_status.
10993 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
10994 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
10995 inferiors.
10996 (update_inserted_breakpoint_locations): Skip if inferiors with no
10997 execution.
10998 (update_global_location_list): When handling moribund locations,
10999 find representative inferior for location's pspace, and use thread
11000 count of its process_stratum target.
11001 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
11002 * bsd-uthread.c (bsd_uthread_target::wait): Use
11003 as_process_stratum_target and adjust thread_change_ptid and
11004 add_thread calls.
11005 (bsd_uthread_target::update_thread_list): Use
11006 as_process_stratum_target and adjust find_thread_ptid,
11007 thread_change_ptid and add_thread calls.
11008 * btrace.c (maint_btrace_packet_history_cmd): Adjust
11009 find_thread_ptid call.
11010 * corelow.c (add_to_thread_list): Adjust add_thread call.
11011 (core_target_open): Adjust add_thread_silent and thread_count
11012 calls.
11013 (core_target::pid_to_str): Adjust find_inferior_ptid call.
11014 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
11015 * event-top.c (async_disconnect): Pop targets from all inferiors.
11016 * exec.c (add_target_sections): Push exec target on all inferiors
11017 sharing the program space.
11018 (remove_target_sections): Remove the exec target from all
11019 inferiors sharing the program space.
11020 (exec_on_vfork): New.
11021 * exec.h (exec_on_vfork): Declare.
11022 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
11023 Pass it down.
11024 (fbsd_nat_target::update_thread_list): Adjust.
11025 (fbsd_nat_target::resume): Adjust.
11026 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
11027 down.
11028 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
11029 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
11030 get_thread_arch_regcache call.
11031 * fork-child.c (gdb_startup_inferior): Pass target down to
11032 startup_inferior and set_executing.
11033 * gdbthread.h (struct process_stratum_target): Forward declare.
11034 (add_thread, add_thread_silent, add_thread_with_info)
11035 (in_thread_list): Add process_stratum_target parameter.
11036 (find_thread_ptid(inferior*, ptid_t)): New overload.
11037 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
11038 parameter.
11039 (all_threads()): Delete overload.
11040 (all_threads, all_non_exited_threads): Add process_stratum_target
11041 parameter.
11042 (all_threads_safe): Use brace initialization.
11043 (thread_count): Add process_stratum_target parameter.
11044 (set_resumed, set_running, set_stop_requested, set_executing)
11045 (threads_are_executing, finish_thread_state): Add
11046 process_stratum_target parameter.
11047 (switch_to_thread): Use is_current_thread.
11048 * i386-fbsd-tdep.c: Include "inferior.h".
11049 (i386fbsd_get_thread_local_address): Pass down target.
11050 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
11051 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
11052 have_inferiors check.
11053 * inf-ptrace.c (inf_ptrace_target::create_inferior)
11054 (inf_ptrace_target::attach): Adjust.
11055 * infcall.c (run_inferior_call): Adjust.
11056 * infcmd.c (run_command_1): Pass target to
11057 scoped_finish_thread_state.
11058 (proceed_thread_callback): Skip inferiors with no execution.
11059 (continue_command): Rename 'all_threads' local to avoid hiding
11060 'all_threads' function. Adjust get_last_target_status call.
11061 (prepare_one_step): Adjust set_running call.
11062 (signal_command): Use user_visible_resume_target. Compare thread
11063 pointers instead of inferior_ptid.
11064 (info_program_command): Adjust to pass down target.
11065 (attach_command): Mark target's 'thread_executing' flag.
11066 (stop_current_target_threads_ns): New, factored out from ...
11067 (interrupt_target_1): ... this. Switch inferior before making
11068 target calls.
11069 * inferior-iter.h
11070 (struct all_inferiors_iterator, struct all_inferiors_range)
11071 (struct all_inferiors_safe_range)
11072 (struct all_non_exited_inferiors_range): Filter on
11073 process_stratum_target too. Remove explicit.
11074 * inferior.c (inferior::inferior): Push dummy target on target
11075 stack.
11076 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
11077 Add process_stratum_target parameter, and pass it down.
11078 (have_live_inferiors): Adjust.
11079 (switch_to_inferior_and_push_target): New.
11080 (add_inferior_command, clone_inferior_command): Handle
11081 "-no-connection" parameter. Use
11082 switch_to_inferior_and_push_target.
11083 (_initialize_inferior): Mention "-no-connection" option in
11084 the help of "add-inferior" and "clone-inferior" commands.
11085 * inferior.h: Include "process-stratum-target.h".
11086 (interrupt_target_1): Use bool.
11087 (struct inferior) <push_target, unpush_target, target_is_pushed,
11088 find_target_beneath, top_target, process_target, target_at,
11089 m_stack>: New.
11090 (discard_all_inferiors): Delete.
11091 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
11092 (all_inferiors, all_non_exited_inferiors): Add
11093 process_stratum_target parameter.
11094 * infrun.c: Include "gdb_select.h" and <unordered_map>.
11095 (target_last_proc_target): New global.
11096 (follow_fork_inferior): Push target on new inferior. Pass target
11097 to add_thread_silent. Call exec_on_vfork. Handle target's
11098 reference count.
11099 (follow_fork): Adjust get_last_target_status call. Also consider
11100 target.
11101 (follow_exec): Push target on new inferior.
11102 (struct execution_control_state) <target>: New field.
11103 (user_visible_resume_target): New.
11104 (do_target_resume): Call target_async.
11105 (resume_1): Set target's threads_executing flag. Consider resume
11106 target.
11107 (commit_resume_all_targets): New.
11108 (proceed): Also consider resume target. Skip threads of inferiors
11109 with no execution. Commit resumtion in all targets.
11110 (start_remote): Pass current inferior to wait_for_inferior.
11111 (infrun_thread_stop_requested): Consider target as well. Pass
11112 thread_info pointer to clear_inline_frame_state instead of ptid.
11113 (infrun_thread_thread_exit): Consider target as well.
11114 (random_pending_event_thread): New inferior parameter. Use it.
11115 (do_target_wait): Rename to ...
11116 (do_target_wait_1): ... this. Add inferior parameter, and pass it
11117 down.
11118 (threads_are_resumed_pending_p, do_target_wait): New.
11119 (prepare_for_detach): Adjust calls.
11120 (wait_for_inferior): New inferior parameter. Handle it. Use
11121 do_target_wait_1 instead of do_target_wait.
11122 (fetch_inferior_event): Adjust. Switch to representative
11123 inferior. Pass target down.
11124 (set_last_target_status): Add process_stratum_target parameter.
11125 Save target in global.
11126 (get_last_target_status): Add process_stratum_target parameter and
11127 handle it.
11128 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
11129 (context_switch): Check inferior_ptid == null_ptid before calling
11130 inferior_thread().
11131 (get_inferior_stop_soon): Pass down target.
11132 (wait_one): Rename to ...
11133 (poll_one_curr_target): ... this.
11134 (struct wait_one_event): New.
11135 (wait_one): New.
11136 (stop_all_threads): Adjust.
11137 (handle_no_resumed, handle_inferior_event): Adjust to consider the
11138 event's target.
11139 (switch_back_to_stepped_thread): Also consider target.
11140 (print_stop_event): Update.
11141 (normal_stop): Update. Also consider the resume target.
11142 * infrun.h (wait_for_inferior): Remove declaration.
11143 (user_visible_resume_target): New declaration.
11144 (get_last_target_status, set_last_target_status): New
11145 process_stratum_target parameter.
11146 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
11147 process_stratum_target parameter, and use it.
11148 (clear_inline_frame_state (thread_info*)): New.
11149 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
11150 process_stratum_target parameter.
11151 (clear_inline_frame_state (thread_info*)): Declare.
11152 * linux-fork.c (delete_checkpoint_command): Pass target down to
11153 find_thread_ptid.
11154 (checkpoint_command): Adjust.
11155 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
11156 instead of just tweaking inferior_ptid.
11157 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
11158 (exit_lwp): Pass target down to find_thread_ptid.
11159 (attach_proc_task_lwp_callback): Pass target down to
11160 add_thread/set_running/set_executing.
11161 (linux_nat_target::attach): Pass target down to
11162 thread_change_ptid.
11163 (get_detach_signal): Pass target down to find_thread_ptid.
11164 Consider last target status's target.
11165 (linux_resume_one_lwp_throw, resume_lwp)
11166 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
11167 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
11168 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
11169 (linux_nat_target::async_wait_fd): New.
11170 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
11171 target down.
11172 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
11173 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
11174 * linux-thread-db.c (struct thread_db_info::process_target): New
11175 field.
11176 (add_thread_db_info): Save target.
11177 (get_thread_db_info): New process_stratum_target parameter. Also
11178 match target.
11179 (delete_thread_db_info): New process_stratum_target parameter.
11180 Also match target.
11181 (thread_from_lwp): Adjust to pass down target.
11182 (thread_db_notice_clone): Pass down target.
11183 (check_thread_db_callback): Pass down target.
11184 (try_thread_db_load_1): Always push the thread_db target.
11185 (try_thread_db_load, record_thread): Pass target down.
11186 (thread_db_target::detach): Pass target down. Always unpush the
11187 thread_db target.
11188 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
11189 target down. Always unpush the thread_db target.
11190 (find_new_threads_callback, thread_db_find_new_threads_2)
11191 (thread_db_target::update_thread_list): Pass target down.
11192 (thread_db_target::pid_to_str): Pass current inferior down.
11193 (thread_db_target::get_thread_local_address): Pass target down.
11194 (thread_db_target::resume, maintenance_check_libthread_db): Pass
11195 target down.
11196 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
11197 * procfs.c (procfs_target::procfs_init_inferior): Declare.
11198 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
11199 (procfs_init_inferior): Rename to ...
11200 (procfs_target::procfs_init_inferior): ... this and adjust.
11201 (procfs_target::create_inferior, procfs_notice_thread)
11202 (procfs_do_thread_registers): Adjust.
11203 * ppc-fbsd-tdep.c: Include "inferior.h".
11204 (ppcfbsd_get_thread_local_address): Pass down target.
11205 * proc-service.c (ps_xfer_memory): Switch current inferior and
11206 program space as well.
11207 (get_ps_regcache): Pass target down.
11208 * process-stratum-target.c
11209 (process_stratum_target::thread_address_space)
11210 (process_stratum_target::thread_architecture): Pass target down.
11211 * process-stratum-target.h
11212 (process_stratum_target::threads_executing): New field.
11213 (as_process_stratum_target): New.
11214 * ravenscar-thread.c
11215 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
11216 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
11217 down.
11218 * record-btrace.c (record_btrace_target::info_record): Adjust.
11219 (record_btrace_target::record_method)
11220 (record_btrace_target::record_is_replaying)
11221 (record_btrace_target::fetch_registers)
11222 (get_thread_current_frame_id, record_btrace_target::resume)
11223 (record_btrace_target::wait, record_btrace_target::stop): Pass
11224 target down.
11225 * record-full.c (record_full_wait_1): Switch to event thread.
11226 Pass target down.
11227 * regcache.c (regcache::regcache)
11228 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
11229 process_stratum_target parameter and handle it.
11230 (current_thread_target): New global.
11231 (get_thread_regcache): Add process_stratum_target parameter and
11232 handle it. Switch inferior before calling target method.
11233 (get_thread_regcache): Pass target down.
11234 (get_thread_regcache_for_ptid): Pass target down.
11235 (registers_changed_ptid): Add process_stratum_target parameter and
11236 handle it.
11237 (registers_changed_thread, registers_changed): Pass target down.
11238 (test_get_thread_arch_aspace_regcache): New.
11239 (current_regcache_test): Define a couple local test_target_ops
11240 instances and use them for testing.
11241 (readwrite_regcache): Pass process_stratum_target parameter.
11242 (cooked_read_test, cooked_write_test): Pass mock_target down.
11243 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
11244 (get_thread_arch_aspace_regcache): Add process_stratum_target
11245 parameter.
11246 (regcache::target): New method.
11247 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
11248 (regcache::registers_changed_ptid): Add process_stratum_target
11249 parameter.
11250 (regcache::m_target): New field.
11251 (registers_changed_ptid): Add process_stratum_target parameter.
11252 * remote.c (remote_state::supports_vCont_probed): New field.
11253 (remote_target::async_wait_fd): New method.
11254 (remote_unpush_and_throw): Add remote_target parameter.
11255 (get_current_remote_target): Adjust.
11256 (remote_target::remote_add_inferior): Push target.
11257 (remote_target::remote_add_thread)
11258 (remote_target::remote_notice_new_inferior)
11259 (get_remote_thread_info): Pass target down.
11260 (remote_target::update_thread_list): Skip threads of inferiors
11261 bound to other targets. (remote_target::close): Don't discard
11262 inferiors. (remote_target::add_current_inferior_and_thread)
11263 (remote_target::process_initial_stop_replies)
11264 (remote_target::start_remote)
11265 (remote_target::remote_serial_quit_handler): Pass down target.
11266 (remote_target::remote_unpush_target): New remote_target
11267 parameter. Unpush the target from all inferiors.
11268 (remote_target::remote_unpush_and_throw): New remote_target
11269 parameter. Pass it down.
11270 (remote_target::open_1): Check whether the current inferior has
11271 execution instead of checking whether any inferior is live. Pass
11272 target down.
11273 (remote_target::remote_detach_1): Pass down target. Use
11274 remote_unpush_target.
11275 (extended_remote_target::attach): Pass down target.
11276 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
11277 (remote_target::append_resumption): Pass down target.
11278 (remote_target::append_pending_thread_resumptions)
11279 (remote_target::remote_resume_with_hc, remote_target::resume)
11280 (remote_target::commit_resume): Pass down target.
11281 (remote_target::remote_stop_ns): Check supports_vCont_probed.
11282 (remote_target::interrupt_query)
11283 (remote_target::remove_new_fork_children)
11284 (remote_target::check_pending_events_prevent_wildcard_vcont)
11285 (remote_target::remote_parse_stop_reply)
11286 (remote_target::process_stop_reply): Pass down target.
11287 (first_remote_resumed_thread): New remote_target parameter. Pass
11288 it down.
11289 (remote_target::wait_as): Pass down target.
11290 (unpush_and_perror): New remote_target parameter. Pass it down.
11291 (remote_target::readchar, remote_target::remote_serial_write)
11292 (remote_target::getpkt_or_notif_sane_1)
11293 (remote_target::kill_new_fork_children, remote_target::kill): Pass
11294 down target.
11295 (remote_target::mourn_inferior): Pass down target. Use
11296 remote_unpush_target.
11297 (remote_target::core_of_thread)
11298 (remote_target::remote_btrace_maybe_reopen): Pass down target.
11299 (remote_target::pid_to_exec_file)
11300 (remote_target::thread_handle_to_thread_info): Pass down target.
11301 (remote_target::async_wait_fd): New.
11302 * riscv-fbsd-tdep.c: Include "inferior.h".
11303 (riscv_fbsd_get_thread_local_address): Pass down target.
11304 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
11305 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
11306 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
11307 Adjust.
11308 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
11309 * solib-svr4.c (enable_break): Pass down target.
11310 * spu-multiarch.c (parse_spufs_run): Pass down target.
11311 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
11312 * target-delegates.c: Regenerate.
11313 * target.c (g_target_stack): Delete.
11314 (current_top_target): Return the current inferior's top target.
11315 (target_has_execution_1): Refer to the passed-in inferior's top
11316 target.
11317 (target_supports_terminal_ours): Check whether the initial
11318 inferior was already created.
11319 (decref_target): New.
11320 (target_stack::push): Incref/decref the target.
11321 (push_target, push_target, unpush_target): Adjust.
11322 (target_stack::unpush): Defref target.
11323 (target_is_pushed): Return bool. Adjust to refer to the current
11324 inferior's target stack.
11325 (dispose_inferior): Delete, and inline parts ...
11326 (target_preopen): ... here. Only dispose of the current inferior.
11327 (target_detach): Hold strong target reference while detaching.
11328 Pass target down.
11329 (target_thread_name): Add assertion.
11330 (target_resume): Pass down target.
11331 (target_ops::beneath, find_target_at): Adjust to refer to the
11332 current inferior's target stack.
11333 (get_dummy_target): New.
11334 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
11335 has a thread running.
11336 (initialize_targets): Rename to ...
11337 (_initialize_target): ... this.
11338 * target.h: Include "gdbsupport/refcounted-object.h".
11339 (struct target_ops): Inherit refcounted_object.
11340 (target_ops::shortname, target_ops::longname): Make const.
11341 (target_ops::async_wait_fd): New method.
11342 (decref_target): Declare.
11343 (struct target_ops_ref_policy): New.
11344 (target_ops_ref): New typedef.
11345 (get_dummy_target): Declare function.
11346 (target_is_pushed): Return bool.
11347 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
11348 (all_matching_threads_iterator::all_matching_threads_iterator):
11349 Handle filter target.
11350 * thread-iter.h (struct all_matching_threads_iterator, struct
11351 all_matching_threads_range, class all_non_exited_threads_range):
11352 Filter by target too. Remove explicit.
11353 * thread.c (threads_executing): Delete.
11354 (inferior_thread): Pass down current inferior.
11355 (clear_thread_inferior_resources): Pass down thread pointer
11356 instead of ptid_t.
11357 (add_thread_silent, add_thread_with_info, add_thread): Add
11358 process_stratum_target parameter. Use it for thread and inferior
11359 searches.
11360 (is_current_thread): New.
11361 (thread_info::deletable): Use it.
11362 (find_thread_ptid, thread_count, in_thread_list)
11363 (thread_change_ptid, set_resumed, set_running): New
11364 process_stratum_target parameter. Pass it down.
11365 (set_executing): New process_stratum_target parameter. Pass it
11366 down. Adjust reference to 'threads_executing'.
11367 (threads_are_executing): New process_stratum_target parameter.
11368 Adjust reference to 'threads_executing'.
11369 (set_stop_requested, finish_thread_state): New
11370 process_stratum_target parameter. Pass it down.
11371 (switch_to_thread): Also match inferior.
11372 (switch_to_thread): New process_stratum_target parameter. Pass it
11373 down.
11374 (update_threads_executing): Reimplement.
11375 * top.c (quit_force): Pop targets from all inferior.
11376 (gdb_init): Don't call initialize_targets.
11377 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
11378 Declare.
11379 (windows_add_thread, windows_delete_thread): Adjust.
11380 (get_windows_debug_event): Rename to ...
11381 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
11382 * tracefile-tfile.c (tfile_target_open): Pass down target.
11383 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
11384 Forward declare.
11385 (switch_to_thread): Add process_stratum_target parameter.
11386 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
11387 parameter. Use it.
11388 (mi_on_resume): Pass target down.
11389 * nat/fork-inferior.c (startup_inferior): Add
11390 process_stratum_target parameter. Pass it down.
11391 * nat/fork-inferior.h (startup_inferior): Add
11392 process_stratum_target parameter.
11393 * python/py-threadevent.c (py_get_event_thread): Pass target down.
11394
11395 2020-01-10 Pedro Alves <palves@redhat.com>
11396
11397 * remote.c (remote_target::start_remote): Don't set inferior_ptid
11398 directly. Instead find the first thread in the thread list and
11399 use switch_to_thread.
11400
11401 2020-01-10 Pedro Alves <palves@redhat.com>
11402
11403 * remote.c (remote_target::remote_add_inferior): Don't bind a
11404 process to the current inferior if the current inferior is already
11405 bound to a process.
11406
11407 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
11408 Pedro Alves <palves@redhat.com>
11409
11410 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
11411 If no process is specified, return null_ptid instead of
11412 inferior_ptid.
11413 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
11414 TARGET_WAITKIND_SIGNALLED with no pid.
11415
11416 2020-01-10 Pedro Alves <palves@redhat.com>
11417
11418 * remote.c (first_remote_resumed_thread): New.
11419 (remote_target::wait_as): Use it as default event_ptid instead of
11420 inferior_ptid.
11421
11422 2020-01-10 Pedro Alves <palves@redhat.com>
11423
11424 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
11425
11426 2020-01-10 Pedro Alves <palves@redhat.com>
11427
11428 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
11429 not -1.
11430
11431 2020-01-10 Pedro Alves <palves@redhat.com>
11432
11433 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
11434 ptid to get_last_target_status.
11435 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
11436 ptid to get_last_target_status.
11437 * infcmd.c (continue_command): Don't pass a target_waitstatus to
11438 get_last_target_status.
11439 (info_program_command): Don't pass a target_waitstatus to
11440 get_last_target_status.
11441 * infrun.c (init_wait_for_inferior): Use
11442 nullify_last_target_wait_ptid.
11443 (get_last_target_status): Handle nullptr arguments.
11444 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
11445 (print_stop_event): Don't pass a ptid to get_last_target_status.
11446 (normal_stop): Don't pass a ptid to get_last_target_status.
11447 * infrun.h (get_last_target_status, set_last_target_status): Move
11448 comments here and update.
11449 (nullify_last_target_wait_ptid): Declare.
11450 * linux-fork.c (fork_load_infrun_state): Remove local extern
11451 declaration of nullify_last_target_wait_ptid.
11452 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
11453 to get_last_target_status.
11454
11455 2020-01-10 Pedro Alves <palves@redhat.com>
11456
11457 * gdbthread.h (scoped_restore_current_thread)
11458 <dont_restore, restore, m_dont_restore>: Declare.
11459 * thread.c (thread_alive): Add assertion. Return bool.
11460 (switch_to_thread_if_alive): New.
11461 (prune_threads): Switch inferior/thread.
11462 (print_thread_info_1): Switch thread before calling target methods.
11463 (scoped_restore_current_thread::restore): New, factored out from
11464 ...
11465 (scoped_restore_current_thread::~scoped_restore_current_thread):
11466 ... this.
11467 (scoped_restore_current_thread::scoped_restore_current_thread):
11468 Add assertion.
11469 (thread_apply_all_command, thread_select): Use
11470 switch_to_thread_if_alive.
11471 * infrun.c (proceed, restart_threads, handle_signal_stop)
11472 (switch_back_to_stepped_thread): Switch current thread before
11473 calling target methods.
11474
11475 2020-01-10 Pedro Alves <palves@redhat.com>
11476
11477 * inferior.c (switch_to_inferior_no_thread): New function,
11478 factored out from ...
11479 (inferior_command): ... here.
11480 * inferior.h (switch_to_inferior_no_thread): Declare.
11481 * mi/mi-main.c (run_one_inferior): Use
11482 switch_to_inferior_no_thread.
11483
11484 2020-01-10 Pedro Alves <palves@redhat.com>
11485
11486 * infcmd.c (kill_command): Remove dead code.
11487
11488 2020-01-10 Pedro Alves <palves@redhat.com>
11489
11490 * remote.c (remote_target::mourn_inferior): No longer check
11491 whether the target is running.
11492
11493 2020-01-10 Pedro Alves <palves@redhat.com>
11494
11495 * corelow.c (core_target::has_execution): Change parameter type to
11496 inferior pointer.
11497 * inferior.c (number_of_live_inferiors): Use
11498 inferior::has_execution instead of target_has_execution_1.
11499 * inferior.h (inferior::has_execution): New.
11500 * linux-thread-db.c (thread_db_target::update_thread_list): Use
11501 inferior::has_execution instead of target_has_execution_1.
11502 * process-stratum-target.c
11503 (process_stratum_target::has_execution): Change parameter type to
11504 inferior pointer. Check the inferior's PID instead of
11505 inferior_ptid.
11506 * process-stratum-target.h
11507 (process_stratum_target::has_execution): Change parameter type to
11508 inferior pointer.
11509 * record-full.c (record_full_core_target::has_execution): Change
11510 parameter type to inferior pointer.
11511 * target.c (target_has_execution_1): Change parameter type to
11512 inferior pointer.
11513 (target_has_execution_current): Adjust.
11514 * target.h (target_ops::has_execution): Change parameter type to
11515 inferior pointer.
11516 (target_has_execution_1): Change parameter type to inferior
11517 pointer. Change return type to bool.
11518 * tracefile.h (tracefile_target::has_execution): Change parameter
11519 type to inferior pointer.
11520
11521 2020-01-10 Pedro Alves <palves@redhat.com>
11522
11523 * exceptions.c (print_flush): Remove current_top_target() check.
11524
11525 2020-01-10 Pedro Alves <palves@redhat.com>
11526
11527 * remote.c (show_remote_exec_file): Show the current inferior's
11528 exec-file instead of the command variable's value.
11529
11530 2020-01-10 Pedro Alves <palves@redhat.com>
11531
11532 * record-full.c (record_full_resume_ptid): New global.
11533 (record_full_target::resume): Set it.
11534 (record_full_wait_1): Use record_full_resume_ptid instead of
11535 inferior_ptid.
11536
11537 2020-01-10 Pedro Alves <palves@redhat.com>
11538
11539 * gdbthread.h (scoped_restore_current_thread)
11540 <dont_restore, restore, m_dont_restore>: Declare.
11541 * thread.c (thread_alive): Add assertion. Return bool.
11542 (switch_to_thread_if_alive): New.
11543 (prune_threads): Switch inferior/thread.
11544 (print_thread_info_1): Switch thread before calling target methods.
11545 (scoped_restore_current_thread::restore): New, factored out from
11546 ...
11547 (scoped_restore_current_thread::~scoped_restore_current_thread):
11548 ... this.
11549 (scoped_restore_current_thread::scoped_restore_current_thread):
11550 Add assertion.
11551 (thread_apply_all_command, thread_select): Use
11552 switch_to_thread_if_alive.
11553
11554 2020-01-10 George Barrett <bob@bob131.so>
11555
11556 * stap-probe.c (stap_modify_semaphore): Don't check for null
11557 semaphores.
11558 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
11559 for null semaphores.
11560
11561 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
11562
11563 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
11564 all source windows, and maintain horizontal scroll status while
11565 doing so.
11566
11567 2020-01-09 Tom Tromey <tom@tromey.com>
11568
11569 PR tui/18932:
11570 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
11571 update_source_window, not print_source_lines.
11572
11573 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
11574
11575 * tui/tui.c (tui_enable): Register tui hooks after calling
11576 tui_display_main.
11577
11578 2020-01-09 Christian Biesinger <cbiesinger@google.com>
11579
11580 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
11581
11582 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
11583
11584 * thread.c (print_thread_info_1): Fix indentation.
11585
11586 2020-01-09 Christian Biesinger <cbiesinger@google.com>
11587
11588 * symtab.c (general_symbol_info::compute_and_set_names): Move the
11589 unique_xmalloc_ptr outside the if to always free the demangled name.
11590
11591 2020-01-08 Tom Tromey <tromey@adacore.com>
11592
11593 * xcoffread.c (enter_line_range, read_xcoff_symtab)
11594 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
11595 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
11596 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
11597 Remove.
11598 (section_offsets): New typedef.
11599 * symtab.c (fixup_section, get_msymbol_address): Update.
11600 * symmisc.c (dump_msymbols): Update.
11601 * symfile.h (relative_addr_info_to_section_offsets)
11602 (symfile_map_offsets_to_segments): Update.
11603 * symfile.c (build_section_addr_info_from_objfile)
11604 (init_objfile_sect_indices): Update.
11605 (struct place_section_arg): Change type of "offsets".
11606 (place_section): Update.
11607 (relative_addr_info_to_section_offsets): Change type of
11608 "section_offsets". Remove "num_sections" parameter.
11609 (default_symfile_offsets, syms_from_objfile_1)
11610 (set_objfile_default_section_offset): Update.
11611 (reread_symbols): No need to preserve section offsets by hand.
11612 (symfile_map_offsets_to_segments): Change type of "offsets".
11613 * stap-probe.c (relocate_address): Update.
11614 * stabsread.h (process_one_symbol): Update.
11615 * solib-target.c (struct lm_info_target) <offsets>: Change type.
11616 (solib_target_relocate_section_addresses): Update.
11617 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
11618 Update.
11619 * solib-frv.c (frv_relocate_main_executable): Update.
11620 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
11621 * solib-aix.c (solib_aix_get_section_offsets): Change return
11622 type.
11623 (solib_aix_solib_create_inferior_hook): Update.
11624 * remote.c (remote_target::get_offsets): Update.
11625 * psymtab.c (find_pc_sect_psymtab): Update.
11626 * psympriv.h (struct partial_symbol) <address, text_low,
11627 text_high>: Update.
11628 * objfiles.h (obj_section_offset): Update.
11629 (struct objfile) <section_offsets>: Change type.
11630 <num_sections>: Remove.
11631 (objfile_relocate): Update.
11632 * objfiles.c (entry_point_address_query): Update
11633 (relocate_one_symbol): Change type of "section_offsets".
11634 (objfile_relocate1, objfile_relocate1): Change type of
11635 "new_offsets".
11636 (objfile_rebase1): Update.
11637 * mipsread.c (mipscoff_symfile_read): Update.
11638 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
11639 parameter.
11640 * mdebugread.c (parse_symbol): Change type of "section_offsets".
11641 (parse_external, psymtab_to_symtab_1): Update.
11642 * machoread.c (macho_symfile_offsets): Update.
11643 * ia64-tdep.c (ia64_find_unwind_table): Update.
11644 * hppa-tdep.c (read_unwind_info): Update.
11645 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
11646 * dwarf2read.c (create_addrmap_from_index)
11647 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
11648 (process_psymtab_comp_unit_reader, add_partial_symbol)
11649 (add_partial_subprogram, process_full_comp_unit)
11650 (read_file_scope, read_func_scope, read_lexical_block_scope)
11651 (read_call_site_scope, dwarf2_rnglists_process)
11652 (dwarf2_ranges_process, dwarf2_ranges_read)
11653 (dwarf_decode_lines_1, var_decode_location, new_symbol)
11654 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
11655 Update.
11656 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
11657 Update.
11658 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
11659 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
11660 (process_one_symbol): Change type of "section_offsets".
11661 * ctfread.c (get_objfile_text_range): Update.
11662 * coffread.c (coff_symtab_read, enter_linenos)
11663 (process_coff_symbol): Update.
11664 * coff-pe-read.c (add_pe_forwarded_sym): Update.
11665 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
11666
11667 2020-01-08 Tom Tromey <tromey@adacore.com>
11668
11669 * dwarf2read.c (parse_macro_definition): Use std::string.
11670 (parse_macro_definition): Likewise.
11671
11672 2020-01-08 Tom Tromey <tromey@adacore.com>
11673
11674 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
11675 (ATTR_ALLOC_CHUNK): Remove.
11676
11677 2020-01-08 Tom Tromey <tromey@adacore.com>
11678
11679 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
11680
11681 2020-01-08 Tom Tromey <tromey@adacore.com>
11682
11683 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
11684 (dwarf2_compute_name, open_dwo_file): Likewise.
11685 (process_enumeration_scope): Use std::vector.
11686 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
11687 (partial_die_info::fixup, dwarf2_start_subfile)
11688 (guess_full_die_structure_name, dwarf2_name): Likewise.
11689 (determine_prefix): Update.
11690 (guess_full_die_structure_name): Make return type const.
11691 (partial_die_full_name): Return unique_xmalloc_ptr.
11692 (DW_FIELD_ALLOC_CHUNK): Remove.
11693
11694 2020-01-07 Tom Tromey <tromey@adacore.com>
11695
11696 PR build/24937:
11697 * stap-probe.c (class stap_static_probe_ops): Add constructor.
11698
11699 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
11700
11701 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
11702
11703 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
11704
11705 * stack.c (print_frame_info): Move disassemble_next_line code
11706 inside source_print block.
11707
11708 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11709
11710 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
11711 gdb/signals.h, as we are now using native signal symbols.
11712
11713 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
11714
11715 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
11716 overflow by an early check of content vs threshold.
11717 * tui/tui-source.c (tui_source_window::line_is_displayed):
11718 Likewise.
11719
11720 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11721
11722 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
11723
11724 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
11725
11726 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
11727 export table if no section contains it's RVA.
11728
11729 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11730
11731 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
11732
11733 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
11734
11735 * source.c (print_source_lines_base): Set last_line_listed.
11736
11737 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
11738
11739 * tui/tui-disasm.c: Remove trailing spaces.
11740
11741 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11742 Pedro Alves <palves@redhat.com>
11743
11744 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
11745 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
11746 (windows_gdb_signal_to_target): New function, uses the above
11747 enumeration to convert GDB internal signal codes to equivalent
11748 Windows codes.
11749 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
11750 * windows-nat.c: Include "gdb_wait.h".
11751 (get_windows_debug_event): Extract the fatal exception from the
11752 exit status and convert to the equivalent Posix signal number.
11753 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
11754 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
11755 * gdbsupport/gdb_wait.c: New file, implements
11756 windows_status_to_termsig.
11757 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
11758 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
11759
11760 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
11761
11762 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
11763 show_layout.
11764
11765 2020-01-05 Luis Machado <luis.machado@linaro.org>
11766
11767 * aarch64-linux-nat.c
11768 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
11769 and bfd_mach_aarch64.
11770
11771 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
11772
11773 * ui-file.c (stdio_file::can_emit_style_escape)
11774 (tee_file::can_emit_style_escape): Ensure style is used also on
11775 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
11776 to gdb_stdout.
11777 * main.c (set_gdb_data_directory): Use file style to output the
11778 warning that the given pathname is not a directory.
11779 * top.c (show_history_filename, gdb_safe_append_history)
11780 (show_gdb_datadir): Use file style.
11781
11782 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
11783
11784 * solib-target.c (struct lm_info_target):
11785 Change offsets to be a unique_xmalloc_ptr.
11786 (solib_target_relocate_section_addresses): Update.
11787
11788 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
11789
11790 * windows-nat.c (windows_clear_solib): Free so_list linked list.
11791
11792 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
11793
11794 * MAINTAINERS (Write After Approval): Add myself.
11795
11796 2020-01-02 Luis Machado <luis.machado@linaro.org>
11797
11798 * proc-service.c (get_ps_regcache): Remove reference to obsolete
11799 Cell BE architecture.
11800 * target.h (struct target_ops) <thread_architecture>: Likewise.
11801
11802 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
11803
11804 * Makefile.in: Use INSTALL_PROGRAM_ENV.
11805
11806 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
11807
11808 * MAINTAINERS (Write After Approval): Add myself.
11809
11810 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11811
11812 * gdbarch.sh: Update copyright year range of generated files.
11813
11814 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11815
11816 Update copyright year range in all GDB files.
11817
11818 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11819
11820 * copyright.py: Convert to Python 3.
11821
11822 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11823
11824 * copyright.py: Adapt after move of gnulib directory from gdb
11825 directory to toplevel directory.
11826
11827 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11828
11829 * copyright.py (main): Exit if run from the wrong directory.
11830
11831 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11832
11833 * top.c (print_gdb_version): Change copyright year to 2020.
11834
11835 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11836
11837 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
11838
11839 For older changes see ChangeLog-2019.
11840 \f
11841 Local Variables:
11842 mode: change-log
11843 left-margin: 8
11844 fill-column: 74
11845 version-control: never
11846 coding: utf-8
11847 End: