Cast to bfd_vma in arm-tdep.c
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-03-12 Tom Tromey <tom@tromey.com>
2
3 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
4 CORE_ADDR.
5 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
6
7 2020-03-12 Tom Tromey <tom@tromey.com>
8
9 * remote.c (remote_target::download_tracepoint)
10 (remote_target::enable_tracepoint)
11 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
12 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
13 sprintf_vma.
14
15 2020-03-12 Tom Tromey <tom@tromey.com>
16
17 * symfile-mem.c: Update CORE_ADDR size assert.
18
19 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
20
21 * selftest.m4: Move to gdbsupport/.
22 * acinclude.m4: Update path to selftest.m4.
23
24 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
25
26 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
27 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
28 gdbarch-selfselftests.c and selftest-arch.c.
29 (SUBDIR_UNITTESTS_OBS): Rename to...
30 (SELFTESTS_OBS): ... this.
31 (COMMON_SFILES): Remove disasm-selftests.c and
32 gdbarch-selftests.c.
33 * configure.ac: Don't add selftest-arch.{c,o} to
34 CONFIG_{SRCS,OBS}.
35 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
36 preprocessor conditions.
37
38 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
39
40 * configure.ac: Don't source bfd/development.sh.
41 * selftest.m4: Modify comment.
42 * configure: Re-generate.
43
44 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
45
46 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
47 not "true" or "false".
48 * configure: Re-generate.
49
50 2020-03-12 Christian Biesinger <cbiesinger@google.com>
51
52 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
53 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
54 renamed to arm_nbsd_supply_gregset.
55 (fetch_register): Update to call arm_nbsd_supply_gregset.
56 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
57 (arm_netbsd_nat_target::fetch_registers): Update.
58 (fetch_elfcore_registers): Removed.
59 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
60 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
61 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
62 not require NetBSD system headers.
63 (arm_nbsd_regset): New struct.
64 (arm_nbsd_iterate_over_regset_sections): New function.
65 (arm_netbsd_init_abi_common): Updated to call
66 set_gdbarch_iterate_over_regset_sections.
67 * arm-nbsd-tdep.h: New file.
68
69 2020-03-11 Kevin Buettner <kevinb@redhat.com>
70
71 * symtab.c (find_pc_sect_line): Add check which prevents infinite
72 recursion.
73
74 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
75
76 * configure: Re-generate.
77
78 2020-03-11 Tom Tromey <tromey@adacore.com>
79
80 * ada-typeprint.c (print_choices): Fix comment.
81
82 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
83
84 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
85 previous item in the list, when the list has no items.
86
87 2020-03-11 Tom de Vries <tdevries@suse.de>
88
89 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
90 PROP_LOCLIST handling code.
91
92 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
93
94 * buildsym-legacy.c (record_line): Pass extra parameter to
95 record_line.
96 * buildsym.c (buildsym_compunit::record_line): Take an extra
97 parameter, reduce duplication in the line table, and record the
98 is_stmt flag in the line table.
99 * buildsym.h (buildsym_compunit::record_line): Add extra
100 parameter.
101 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
102 non-statement lines.
103 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
104 this to the symtab builder.
105 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
106 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
107 through to dwarf_record_line_1.
108 * infrun.c (process_event_stop_test): When stepping, don't stop at
109 a non-statement instruction, and only refresh the step info when
110 we land in the middle of a line's range. Also add an extra
111 comment.
112 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
113 field.
114 * record-btrace.c (btrace_find_line_range): Only record lines
115 marked as is-statement.
116 * stack.c (frame_show_address): Show the frame address if we are
117 in a non-statement sal.
118 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
119 (maintenance_print_one_line_table): Print a header for the is_stmt
120 column, and include is_stmt information in the output.
121 * symtab.c (find_pc_sect_line): Find lines marked as statements in
122 preference to non-statements.
123 (find_pcs_for_symtab_line): Prefer is-statement entries.
124 (find_line_common): Likewise.
125 * symtab.h (struct linetable_entry): Add is_stmt field.
126 (struct symtab_and_line): Likewise.
127 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
128 arranging the line table.
129
130 2020-03-07 Tom de Vries <tdevries@suse.de>
131
132 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
133 DIE.
134
135 2020-03-07 Tom Tromey <tom@tromey.com>
136
137 * valops.c (value_literal_complex): Remove obsolete comment.
138 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
139 comment.
140
141 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
142
143 * infrun.h: Forward-declare thread_info.
144 (set_step_info): Add thread_info parameter, add doc.
145 * infrun.c (set_step_info): Add thread_info parameter, move doc
146 to header.
147 * infrun.c (process_event_stop_test): Pass thread to
148 set_step_info call.
149 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
150 set_step_info.
151 (prepare_one_step): Add thread_info parameter, pass it to
152 set_step_frame and prepare_one_step (recursive) call.
153 (step_1): Pass thread to prepare_one_step call.
154 (step_command_fsm::should_stop): Pass thread to
155 prepare_one_step.
156 (until_next_fsm): Pass thread to set_step_frame call.
157 (finish_command): Pass thread to set_step_info call.
158
159 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
160
161 * windows-tdep.c (windows_solib_create_inferior_hook):
162 Check if inferior is running.
163
164 2020-03-06 Tom de Vries <tdevries@suse.de>
165
166 * NEWS: Fix "the the".
167 * ctfread.c: Same.
168
169 2020-03-06 Tom de Vries <tdevries@suse.de>
170
171 * psymtab.c (psymtab_to_symtab): Don't print "done.".
172
173 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
174
175 * .dir-locals.el: Add a comment referencing the other copies of
176 this file.
177
178 2020-03-05 John Baldwin <jhb@FreeBSD.org>
179
180 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
181 psargs.
182
183 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
184
185 * .gitattributes: New file.
186
187 2020-03-04 Tom Tromey <tom@tromey.com>
188
189 * symmisc.c (print_symbol_bcache_statistics)
190 (print_objfile_statistics): Update.
191 * symfile.c (allocate_symtab): Use intern.
192 * psymtab.c (partial_symtab::partial_symtab): Use intern.
193 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
194 macro_cache>: Remove.
195 <string_cache>: New member.
196 (struct objfile) <intern>: New methods.
197 * elfread.c (elf_symtab_read): Use intern.
198 * dwarf2/read.c (fixup_go_packaging): Intern package name.
199 (dwarf2_compute_name, dwarf2_physname)
200 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
201 names.
202 (guess_partial_die_structure_name): Update.
203 (partial_die_info::fixup): Intern name.
204 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
205 name.
206 (dwarf2_name): Intern name. Update.
207 * buildsym.c (buildsym_compunit::get_macro_table): Use
208 string_cache.
209
210 2020-03-04 Tom Tromey <tom@tromey.com>
211
212 * jit.c (bfd_open_from_target_memory): Make "target" const.
213 * corefile.c (gnutarget): Now const.
214 * gdbcore.h (gnutarget): Now const.
215
216 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
217
218 * NEWS: Mention support for WOW64 processes.
219 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
220 (amd64_windows_segment_register_p): Remove static.
221 (_initialize_amd64_windows_nat): Update.
222 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
223 * i386-windows-nat.c (context_offset): Update.
224 (i386_mappings): Rename and remove static.
225 (i386_windows_segment_register_p): Remove static.
226 (_initialize_i386_windows_nat): Update.
227 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
228 (STATUS_WX86_SINGLE_STEP): New macro.
229 (EnumProcessModulesEx): New macro.
230 (Wow64SuspendThread): New macro.
231 (Wow64GetThreadContext): New macro.
232 (Wow64SetThreadContext): New macro.
233 (Wow64GetThreadSelectorEntry): New macro.
234 (windows_set_context_register_offsets): Add static.
235 (windows_set_segment_register_p): Likewise.
236 (windows_add_thread): Adapt for WOW64 processes.
237 (windows_fetch_one_register): Likewise.
238 (windows_nat_target::fetch_registers): Likewise.
239 (windows_store_one_register): Likewise.
240 (display_selector): Likewise.
241 (display_selectors): Likewise.
242 (handle_exception): Likewise.
243 (windows_continue): Likewise.
244 (windows_nat_target::resume): Likewise.
245 (windows_add_all_dlls): Likewise.
246 (do_initial_windows_stuff): Likewise.
247 (windows_nat_target::attach): Likewise.
248 (windows_get_exec_module_filename): Likewise.
249 (windows_nat_target::create_inferior): Likewise.
250 (windows_xfer_siginfo): Likewise.
251 (_initialize_loadable): Initialize Wow64SuspendThread,
252 Wow64GetThreadContext, Wow64SetThreadContext,
253 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
254 * windows-nat.h (windows_set_context_register_offsets):
255 Remove declaration.
256 (windows_set_segment_register_p): Likewise.
257 (i386_windows_segment_register_p): Add declaration.
258 (amd64_windows_segment_register_p): Likewise.
259
260 2020-03-04 Luis Machado <luis.machado@linaro.org>
261
262 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
263 in "info registers" for AArch64/ARM.
264
265 The change caused "info registers" to not print GPR's.
266
267 gdb/ChangeLog:
268
269 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
270
271 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
272 when reg->group is empty and reggroup is not.
273
274 2020-03-03 Tom Tromey <tromey@adacore.com>
275
276 * dwarf2/frame.c (struct dwarf2_frame_cache)
277 <checked_tailcall_bottom, entry_cfa_sp_offset,
278 entry_cfa_sp_offset_p>: Remove members.
279 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
280 (dwarf2_frame_prev_register): Don't call
281 dwarf2_tailcall_sniffer_first.
282 (dwarf2_append_unwinders): Don't append tailcall unwinder.
283 * frame-unwind.c (add_unwinder): New fuction.
284 (frame_unwind_init): Use it. Add tailcall unwinder.
285
286 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
287 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
288
289 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
290 value should be printed as true.
291
292 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
293
294 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
295 (windows_init_abi): Set and use windows_so_ops.
296
297 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
298
299 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
300 when verifying if dealing with a convenience variable.
301
302 2020-03-03 Luis Machado <luis.machado@linaro.org>
303
304 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
305
306 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
307
308 * infrun.c (gdbarch_supports_displaced_stepping): New.
309 (use_displaced_stepping): Break up conditions in smaller pieces.
310 Use gdbarch_supports_displaced_stepping.
311 (displaced_step_prepare_throw): Use
312 gdbarch_supports_displaced_stepping.
313
314 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
315
316 * NEWS: Mention new behaviour of the history filename.
317 * top.c (write_history_p): Add comment.
318 (show_write_history_p): Add header comment, give a different
319 message when history writing is on, but the history filename is
320 empty.
321 (history_filename): Add comment.
322 (history_filename_empty): New function.
323 (show_history_filename): Add header comment, give a different
324 message when the filename is empty.
325 (init_history): Compare history_filename against nullptr, and only
326 read history if the filename is not empty.
327 (set_history_filename): Add header comment, and only make
328 non-empty filenames absolute.
329 (init_main): Make the filename argument to 'set history filename'
330 optional.
331
332 2020-03-02 Christian Biesinger <cbiesinger@google.com>
333
334 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
335 (arm_supply_vfpregset): ...this, and update to use VFP registers.
336 (fetch_fp_register): Update.
337 (fetch_fp_regs): Update.
338 (store_fp_register): Update.
339 (store_fp_regs): Update.
340 (arm_netbsd_nat_target::read_description): New function.
341 (fetch_elfcore_registers): Update.
342
343 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
344
345 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
346 general_thread if the stop reply is missing a thread-id.
347 (remote_target::process_stop_reply): Use the first non-exited
348 thread if the target didn't pass a thread-id.
349 * infrun.c (do_target_wait): Move call to
350 switch_to_inferior_no_thread to ....
351 (do_target_wait_1): ... here.
352
353 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
354
355 * debuginfod-support.c: Include defs.h first.
356
357 2020-02-28 Tom de Vries <tdevries@suse.de>
358
359 * symfile.c (set_initial_language): Use default language for lookup.
360
361 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
362
363 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
364 reader variable, pass `this` to read_cutu_die_from_dwo.
365
366 2020-02-27 Aaron Merey <amerey@redhat.com>
367
368 * source.c (open_source_file): Check for nullptr when computing
369 srcpath.
370
371 2020-02-27 Tom Tromey <tromey@adacore.com>
372
373 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
374 member.
375 (dwarf2_add_field): Don't update nfields.
376 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
377
378 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
379
380 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
381 abs.
382
383 2020-02-26 Tom Tromey <tom@tromey.com>
384
385 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
386 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
387 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
388 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
389 per_cu_data.
390
391 2020-02-26 Tom Tromey <tom@tromey.com>
392
393 * dwarf2/index-write.c (psym_index_map): Change type.
394 (add_address_entry_worker, write_one_signatured_type)
395 (recursively_count_psymbols, recursively_write_psymbols)
396 (class debug_names, psyms_seen_size, write_gdbindex)
397 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
398
399 2020-02-26 Aaron Merey <amerey@redhat.com>
400
401 * Makefile.in: Handle optional debuginfod support.
402 * NEWS: Update.
403 * README: Add --with-debuginfod summary.
404 * config.in: Regenerate.
405 * configure: Regenerate.
406 * configure.ac: Handle optional debuginfod support.
407 * debuginfod-support.c: debuginfod helper functions.
408 * debuginfod-support.h: Ditto.
409 * doc/gdb.texinfo: Add --with-debuginfod to configure options
410 summary.
411 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
412 when a dwz file cannot be found.
413 * elfread.c (elf_symfile_read): Query debuginfod servers when a
414 debuginfo file cannot be found.
415 * source.c (open_source_file): Query debuginfod servers when a
416 source file cannot be found.
417 * top.c (print_gdb_configuration): Include
418 --{with,without}-debuginfod in the output.
419
420 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
421
422 * thread.c (thr_try_catch_cmd): Print thread name.
423
424 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
425
426 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
427 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
428 dwarf2_fetch_die_type_sect_off): Move to...
429 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
430 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
431 dwarf2_fetch_die_type_sect_off): ... here.
432 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
433 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
434 dwarf2_fetch_die_type_sect_off): Move doc to header file.
435
436 2020-02-26 Tom de Vries <tdevries@suse.de>
437
438 PR gdb/25603
439 * symfile.c (set_initial_language): Exit-early if
440 language_mode == language_mode_manual.
441
442 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
443
444 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
445 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
446 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
447
448 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
449
450 * gdbtypes.c (create_array_type_with_stride): Handle negative
451 array strides.
452 * valarith.c (value_subscripted_rvalue): Likewise.
453
454 2020-02-25 Luis Machado <luis.machado@linaro.org>
455
456 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
457
458 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
459
460 * loc.h (dwarf2_get_die_type): Move to...
461 * read.h (dwarf2_get_die_type): ... here.
462 * read.c (dwarf2_get_die_type): Move doc to header.
463
464 2020-02-25 Joel Brobecker <brobecker@adacore.com>
465
466 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
467 'gnulib/Makefile.in' to the list.
468
469 2020-02-24 Tom Tromey <tom@tromey.com>
470
471 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
472 Remove.
473 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
474 XOBNEWVEC.
475
476 2020-02-24 Tom Tromey <tom@tromey.com>
477
478 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
479 New method.
480 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
481 (dw2_do_instantiate_symtab, dw2_get_file_names)
482 (build_type_psymtab_dependencies, load_full_type_unit): Update.
483
484 2020-02-24 Tom Tromey <tom@tromey.com>
485
486 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
487 make_scoped_restore.
488 (dwarf2_psymtab::read_symtab): Don't clear
489 reading_partial_symbols.
490
491 2020-02-24 Tom de Vries <tdevries@suse.de>
492
493 PR gdb/25592
494 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
495
496 2020-02-24 Tom de Vries <tdevries@suse.de>
497
498 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
499 commands layout next/prev/regs.
500
501 2020-02-22 Tom Tromey <tom@tromey.com>
502
503 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
504 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
505
506 2020-02-22 Tom Tromey <tom@tromey.com>
507
508 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
509
510 2020-02-22 Tom Tromey <tom@tromey.com>
511
512 * tui/tui-win.c (_initialize_tui_win): Add usage text.
513 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
514 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
515 * tui/tui.c (_initialize_tui): Add usage text.
516
517 2020-02-22 Tom Tromey <tom@tromey.com>
518
519 * tui/tui-win.c (tui_set_focus_command)
520 (tui_set_win_height_command): Use error_no_arg.
521 (_initialize_tui_win): Update help text.
522 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
523
524 2020-02-22 Tom Tromey <tom@tromey.com>
525
526 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
527 * tui/tui-disasm.h (struct tui_disasm_window)
528 <display_start_addr>: Declare.
529 * tui/tui-source.h (struct tui_source_window)
530 <display_start_addr>: Declare.
531 * tui/tui-winsource.h (struct tui_source_window_base)
532 <show_source_line, display_start_addr>: New methods.
533 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
534 Rename and move to protected section.
535 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
536 (tui_source_window_base::do_erase_source_content): Update.
537 (tui_source_window_base::show_source_line): Now a method.
538 (tui_source_window_base::show_source_content)
539 (tui_source_window_base::tui_source_window_base)
540 (tui_source_window_base::rerender)
541 (tui_source_window_base::refill)
542 (tui_source_window_base::do_scroll_horizontal)
543 (tui_source_window_base::set_is_exec_point_at)
544 (tui_source_window_base::update_breakpoint_info)
545 (tui_source_window_base::update_exec_info): Update.
546 * tui/tui-source.c (tui_source_window::set_contents)
547 (tui_source_window::showing_source_p)
548 (tui_source_window::do_scroll_vertical)
549 (tui_source_window::location_matches_p)
550 (tui_source_window::line_is_displayed): Update.
551 (tui_source_window::display_start_addr): New method.
552 * tui/tui-disasm.c (tui_disasm_window::set_contents)
553 (tui_disasm_window::do_scroll_vertical)
554 (tui_disasm_window::location_matches_p): Update.
555 (tui_disasm_window::display_start_addr): New method.
556
557 2020-02-22 Tom Tromey <tom@tromey.com>
558
559 * NEWS: Add entry for gdb.register_window_type.
560 * tui/tui-layout.h (window_factory): New typedef.
561 (tui_register_window): Declare.
562 * tui/tui-layout.c (saved_tui_windows): New global.
563 (tui_apply_current_layout): Use it.
564 (tui_register_window): New function.
565 * python/python.c (do_start_initialization): Call
566 gdbpy_initialize_tui.
567 (python_GdbMethods): Add "register_window_type" function.
568 * python/python-internal.h (gdbpy_register_tui_window)
569 (gdbpy_initialize_tui): Declare.
570 * python/py-tui.c: New file.
571 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
572
573 2020-02-22 Tom Tromey <tom@tromey.com>
574
575 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
576
577 2020-02-22 Tom Tromey <tom@tromey.com>
578
579 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
580 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
581 * tui/tui-data.c (tui_set_win_with_focus): Remove.
582 (tui_set_win_focus_to): Move from tui-win.c.
583
584 2020-02-22 Tom Tromey <tom@tromey.com>
585
586 * tui/tui-layout.c (make_standard_window, get_locator_window): New
587 functions.
588 (known_window_types): New global.
589 (tui_get_window_by_name): Reimplement.
590 (initialize_known_windows): New function.
591 (validate_window_name): Rewrite.
592 (_initialize_tui_layout): Call initialize_known_windows.
593
594 2020-02-22 Tom Tromey <tom@tromey.com>
595
596 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
597 Remove constants.
598 * tui/tui-winsource.h (struct tui_source_window_base)
599 <tui_source_window_base>: Remove parameter.
600 * tui/tui-winsource.c
601 (tui_source_window_base::tui_source_window_base): Remove
602 parameter.
603 (tui_source_window_base::refill): Update.
604 * tui/tui-stack.h (struct tui_locator_window)
605 <tui_locator_window>: Update.
606 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
607 Default the constructor.
608 * tui/tui-regs.h (struct tui_data_item_window)
609 <tui_data_item_window>: Default the constructor.
610 (struct tui_data_window) <tui_data_window>: Likewise.
611 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
612 Default the constructor.
613 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
614 Default the constructor.
615 <type>: Remove.
616 (struct tui_win_info) <tui_win_info>: Default the constructor.
617 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
618 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
619 Default the constructor.
620
621 2020-02-22 Tom Tromey <tom@tromey.com>
622
623 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
624 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
625 * tui/tui-win.c (tui_resize_all): Don't call
626 tui_delete_invisible_windows.
627 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
628 done.
629 (tui_set_layout): Update.
630 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
631 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
632 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
633
634 2020-02-22 Tom Tromey <tom@tromey.com>
635
636 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
637 correctly.
638
639 2020-02-22 Tom Tromey <tom@tromey.com>
640
641 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
642
643 2020-02-22 Tom Tromey <tom@tromey.com>
644
645 * tui/tui-winsource.h (struct tui_source_window_iterator)
646 <inner_iterator>: New etytypedef.
647 <tui_source_window_iterator>: Take "end" parameter.
648 <tui_source_window_iterator>: Take iterator.
649 <operator*, advance>: Update.
650 <m_iter>: Change type.
651 <m_end>: New field.
652 (struct tui_source_windows) <begin, end>: Update.
653 * tui/tui-layout.c (tui_windows): New global.
654 (tui_apply_current_layout): Clear tui_windows.
655 (tui_layout_window::apply): Update tui_windows.
656 * tui/tui-data.h (tui_windows): Declare.
657 (all_tui_windows): Now inline function.
658 (class tui_window_iterator, struct all_tui_windows): Remove.
659
660 2020-02-22 Tom Tromey <tom@tromey.com>
661
662 PR tui/17850:
663 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
664 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
665 "height" argument.
666 (class tui_layout_window) <get_sizes>: Likewise.
667 (class tui_layout_split) <tui_layout_split>: Add "vertical"
668 argument.
669 <get_sizes>: Add "height" argument.
670 <m_vertical>: New field.
671 * tui/tui-layout.c (tui_layout_split::clone): Update.
672 (tui_layout_split::get_sizes): Add "height" argument.
673 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
674 (tui_new_layout_command): Parse "-horizontal".
675 (_initialize_tui_layout): Update help string.
676 (tui_layout_split::specification): Add "-horizontal" when needed.
677 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
678 argument.
679 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
680 New methods.
681
682 2020-02-22 Tom Tromey <tom@tromey.com>
683
684 * tui/tui-layout.h (enum tui_adjust_result): New.
685 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
686 (class tui_layout_window) <adjust_size>: Return
687 tui_adjust_result. Rewrite.
688 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
689 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
690
691 2020-02-22 Tom Tromey <tom@tromey.com>
692
693 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
694 parameter and return types.
695 (class tui_layout_base) <specification>: Add "depth".
696 (class tui_layout_window) <specification>: Add "depth".
697 (class tui_layout_split) <specification>: Add "depth".
698 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
699 and return types.
700 (tui_new_layout_command): Parse sub-layouts.
701 (_initialize_tui_layout): Update help string.
702 (tui_layout_window::specification): Add "depth".
703 (add_layout_command): Update.
704
705 2020-02-22 Tom Tromey <tom@tromey.com>
706
707 * NEWS: Add "tui new-layout" item.
708 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
709 Add new-layout command to help text.
710 (validate_window_name): New function.
711 (tui_new_layout_command): New function.
712 (_initialize_tui_layout): Register "new-layout".
713 (tui_layout_window::specification): New method.
714 (tui_layout_window::specification): New method.
715 * tui/tui-layout.h (class tui_layout_base) <specification>: New
716 method.
717 (class tui_layout_window) <specification>: New method.
718 (class tui_layout_split) <specification>: New method.
719
720 2020-02-22 Tom Tromey <tom@tromey.com>
721
722 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
723 * tui/tui-win.c (window_name_completer): Update comment.
724 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
725 Declare method.
726 (class tui_layout_window) <replace_window>: Likewise.
727 (class tui_layout_split) <replace_window>: Likewise.
728 (tui_set_layout): Don't declare.
729 (tui_set_initial_layout): Declare function.
730 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
731 (asm_regs_layout): New globals.
732 (tui_current_layout, show_layout): Remove.
733 (tui_set_layout, tui_add_win_to_layout): Rewrite.
734 (find_layout, tui_apply_layout): New function.
735 (layout_completer): Remove.
736 (tui_next_layout): Reimplement.
737 (tui_next_layout_command): New function.
738 (tui_set_initial_layout, tui_prev_layout_command): New functions.
739 (tui_regs_layout): Reimplement.
740 (tui_regs_layout_command): New function.
741 (extract_display_start_addr): Rewrite.
742 (next_layout, prev_layout): Remove.
743 (tui_layout_window::replace_window): New method.
744 (tui_layout_split::replace_window): New method.
745 (destroy_layout): New function.
746 (layout_list): New global.
747 (add_layout_command): New function.
748 (initialize_layouts): Update.
749 (tui_layout_command): New function.
750 (_initialize_tui_layout): Install "layout" commands.
751 * tui/tui-data.h (enum tui_layout_type): Remove.
752 (tui_current_layout): Don't declare.
753
754 2020-02-22 Tom Tromey <tom@tromey.com>
755
756 * tui/tui-regs.c (tui_reg_layout): Remove.
757 (tui_reg_command): Use tui_regs_layout.
758 * tui/tui-layout.h (tui_reg_command): Declare.
759 * tui/tui-layout.c (tui_reg_command): New function.
760
761 2020-02-22 Tom Tromey <tom@tromey.com>
762
763 * tui/tui.c (tui_rl_delete_other_windows): Call
764 tui_remove_some_windows.
765 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
766 Declare method.
767 (class tui_layout_window) <remove_windows>: New method.
768 (class tui_layout_split) <remove_windows>: Declare.
769 (tui_remove_some_windows): Declare.
770 * tui/tui-layout.c (tui_remove_some_windows): New function.
771 (tui_layout_split::remove_windows): New method.
772
773 2020-02-22 Tom Tromey <tom@tromey.com>
774
775 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
776 * tui/tui-layout.h (tui_next_layout): Declare.
777 * tui/tui-layout.c (tui_next_layout): New function.
778
779 2020-02-22 Tom Tromey <tom@tromey.com>
780
781 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
782 correct coordinates.
783
784 2020-02-22 Tom Tromey <tom@tromey.com>
785
786 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
787 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
788 DATA_WIN case.
789
790 2020-02-22 Tom Tromey <tom@tromey.com>
791
792 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
793 TUI_DISASM_WIN, not tui_win_list.
794
795 2020-02-22 Tom Tromey <tom@tromey.com>
796
797 * valprint.c (generic_val_print_enum_1)
798 (val_print_type_code_flags): Style member names.
799 * rust-lang.c (val_print_struct, rust_print_enum)
800 (rust_print_struct_def, rust_internal_print_type): Style member
801 names.
802 * p-valprint.c (pascal_object_print_value_fields): Style member
803 names. Only call fprintf_symbol_filtered for static members.
804 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
805 * f-valprint.c (f_val_print): Style member names.
806 * f-typeprint.c (f_type_print_base): Style member names.
807 * cp-valprint.c (cp_print_value_fields): Style member names. Only
808 call fprintf_symbol_filtered for static members.
809 (cp_print_class_member): Style member names.
810 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
811 member names.
812 * ada-valprint.c (ada_print_scalar): Style enum names.
813 (ada_val_print_enum): Likewise.
814 * ada-typeprint.c (print_enum_type): Style enum names.
815
816 2020-02-21 Tom Tromey <tom@tromey.com>
817
818 * psympriv.h (struct partial_symtab): Update comment.
819
820 2020-02-21 Tom Tromey <tromey@adacore.com>
821
822 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
823 type is CORE_ADDR.
824
825 2020-02-21 Tom de Vries <tdevries@suse.de>
826
827 PR gdb/25534
828 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
829 if dependencies[i]->user != NULL.
830
831 2020-02-21 Ali Tamur <tamur@google.com>
832
833 * dwarf2/read.c (dwarf2_name): Add null check.
834
835 2020-02-20 Tom Tromey <tom@tromey.com>
836
837 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
838 ">=", in binary search.
839 (dwarf2_find_containing_comp_unit): New overload.
840 (run_test): New self-test.
841 (_initialize_dwarf2_read): Register new test.
842
843 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
844
845 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
846 * riscv-tdep.h: Likewise.
847 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
848 rv32-only CSR.
849 * features/riscv/64bit-csr.xml: Regenerated.
850
851 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
852 Tom Tromey <tom@tromey.com>
853
854 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
855 of 'fputc_unfiltered'.
856 (putchar_unfiltered): Call 'fputc_unfiltered'.
857 (fputc_unfiltered): Call 'fputs_unfiltered'.
858
859 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
860
861 * config.in: Regenerate.
862 * configure: Regenerate.
863 * configure.ac: Add --with-python-libdir option.
864 * main.c: Use WITH_PYTHON_LIBDIR.
865
866 2020-02-19 Tom Tromey <tom@tromey.com>
867
868 * symtab.c (general_symbol_info::compute_and_set_names): Use
869 obstack_strndup. Simplify call to symbol_set_demangled_name.
870
871 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
872
873 * dwarf2/read.c (allocate_signatured_type_table,
874 allocate_dwo_unit_table, allocate_type_unit_groups_table,
875 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
876 Remove objfile parameter, update all callers.
877
878 2020-02-19 Doug Evans <dje@google.com>
879
880 PR rust/25535
881 * rust-lang.c (rust_print_enum): Apply embedded_offset to
882 rust_enum_variant calculation.
883
884 2020-02-19 Tom Tromey <tromey@adacore.com>
885
886 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
887
888 2020-02-19 Tom Tromey <tromey@adacore.com>
889
890 * ada-lang.c (cache_symbol): Use obstack_strdup.
891
892 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
893
894 * configure: Regenerate.
895
896 2020-02-19 Tom Tromey <tromey@adacore.com>
897
898 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
899 NULL check.
900
901 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
902
903 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
904
905 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
906
907 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
908 if GDBSERVER is not defined.
909 (riscv_tdesc_cache): Likewise, also store const target_desc.
910 (STATIC_IN_GDB): Define.
911 (riscv_create_target_description): Update declaration with
912 STATIC_IN_GDB.
913 (riscv_lookup_target_description): New function, only define if
914 GDBSERVER is not defined.
915 * arch/riscv.h (riscv_create_target_description): Declare only
916 when GDBSERVER is defined.
917 (riscv_lookup_target_description): New declaration when GDBSERVER
918 is not defined.
919 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
920 (riscv_linux_read_features): ...this, and return
921 riscv_gdbarch_features instead of target_desc.
922 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
923 (riscv_linux_read_description): Rename to...
924 (riscv_linux_read_features): ...this.
925 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
926 Update to use riscv_gdbarch_features and
927 riscv_lookup_target_description.
928 * riscv-tdep.c (riscv_find_default_target_description): Use
929 riscv_lookup_target_description instead of
930 riscv_create_target_description.
931
932 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
933
934 * valprint.c (generic_val_print_enum_1): When printing a flag
935 enum with value 0 and there is no enumerator with value 0, print
936 just "0" instead of "(unknown: 0x0)".
937
938 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
939
940 * valprint.c (generic_val_print_enum_1): Print unknown part of
941 flag enum in hex.
942
943 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
944
945 * dwarf2/read.c (update_enumeration_type_from_children): Allow
946 flag enums to contain duplicate enumerators.
947 * valprint.c (generic_val_print_enum_1): Update comment.
948
949 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
950
951 * dwarf2/read.c: Include "count-one-bits.h".
952 (update_enumeration_type_from_children): If an enumerator has
953 multiple bits set, don't treat the enumeration as a "flag enum".
954 * valprint.c (generic_val_print_enum_1): Assert that enumerators
955 of flag enums have 0 or 1 bit set.
956
957 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
958
959 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
960 conversion.
961 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
962 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
963 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
964 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
965 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
966
967 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
968
969 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
970
971 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
972
973 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
974 displaced_step_closure_up.
975 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
976 (struct displaced_step_closure_up):
977 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
978 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
979 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
980 Likewise.
981 * gdbarch.sh (displaced_step_copy_insn): Likewise.
982 * gdbarch.c, gdbarch.h: Re-generate.
983 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
984 displaced_step_closure_up.
985 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
986 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
987 * infrun.h (displaced_step_closure_up): New type alias.
988 (struct displaced_step_inferior_state) <step_closure>: Change
989 type to displaced_step_closure_up.
990 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
991 displaced_step_closure_up.
992 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
993
994 2020-02-14 Tom Tromey <tom@tromey.com>
995
996 * minidebug.c (gnu_debug_key): New global.
997 (find_separate_debug_file_in_section): Use it.
998
999 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
1000
1001 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
1002 std::unique_ptr.
1003 * gdbarch.c: Re-generate.
1004 * gdbarch.h: Re-generate.
1005 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
1006 change.
1007 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
1008 type to std::unique_ptr.
1009 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
1010 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
1011 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
1012 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
1013 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
1014 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
1015 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
1016 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
1017 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
1018
1019 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
1020
1021 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
1022 std::unique_ptr.
1023 (displaced_step_clear): Rename to...
1024 (displaced_step_reset): ... this. Just call displaced->reset ().
1025 (displaced_step_clear_cleanup): Rename to...
1026 (displaced_step_reset_cleanup): ... this.
1027 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
1028 (displaced_step_fixup): Likewise.
1029 (resume_1): Likewise.
1030 (handle_inferior_event): Restore child's memory before calling
1031 displaced_step_fixup on the parent.
1032 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
1033 to std::unique_ptr.
1034 <step_closure>: Change type to std::unique_ptr.
1035
1036 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
1037
1038 * arm-tdep.c: Include count-one-bits.h.
1039 (cleanup_block_store_pc): Use count_one_bits.
1040 (cleanup_block_load_pc): Use count_one_bits.
1041 (arm_copy_block_xfer): Use count_one_bits.
1042 (thumb2_copy_block_xfer): Use count_one_bits.
1043 (thumb_copy_pop_pc_16bit): Use count_one_bits.
1044 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
1045 (thumb_get_next_pcs_raw): Use count_one_bits.
1046 (arm_get_next_pcs_raw): Use count_one_bits_l.
1047 * arch/arm.c (bitcount): Remove.
1048 * arch/arm.h (bitcount): Remove.
1049
1050 2020-02-14 Tom Tromey <tromey@adacore.com>
1051
1052 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
1053 Update.
1054 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
1055 * dwarf2/loc.c (call_site_find_chain_1): Return
1056 unique_xmalloc_ptr.
1057 (call_site_find_chain): Likewise.
1058
1059 2020-02-14 Richard Biener <rguenther@suse.de>
1060
1061 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
1062 on expression with division operators.
1063
1064 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1065
1066 * MAINTAINERS (Write After Approval): Adding myself.
1067
1068 2020-02-12 Tom Tromey <tom@tromey.com>
1069
1070 * event-loop.c (event_data, gdb_event, event_handler_func):
1071 Remove.
1072
1073 2020-02-12 Tom Tromey <tom@tromey.com>
1074
1075 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
1076 (dwarf2_frame_objfile_data): Add comment.
1077 (find_comp_unit, set_comp_unit): New functions.
1078 (dwarf2_frame_find_fde): Use find_comp_unit.
1079 (dwarf2_build_frame_info): Use set_comp_unit.
1080
1081 2020-02-12 Tom Tromey <tom@tromey.com>
1082
1083 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
1084 (comp_unit): Don't initialize objfile.
1085 (execute_cfa_program): Add text_offset parameter.
1086 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
1087 (dwarf2_frame_cache): Update.
1088 (dwarf2_build_frame_info): Don't set "objfile" member.
1089
1090 2020-02-12 Tom Tromey <tom@tromey.com>
1091
1092 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
1093 (decode_frame_entry): Likewise.
1094 (dwarf2_build_frame_info): Update.
1095
1096 2020-02-12 Tom Tromey <tom@tromey.com>
1097
1098 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
1099 (decode_frame_entry_1): Use the comp_unit obstack.
1100
1101 2020-02-12 Tom Tromey <tom@tromey.com>
1102
1103 * dwarf2/frame.c (struct comp_unit): Add initializers and
1104 constructor.
1105 (dwarf2_frame_objfile_data): Store a comp_unit.
1106 (dwarf2_frame_find_fde): Update.
1107 (dwarf2_build_frame_info): Use "new".
1108
1109 2020-02-12 Tom Tromey <tom@tromey.com>
1110
1111 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
1112 (dwarf2_fde_table): Typedef for std::vector.
1113 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
1114 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
1115 (decode_frame_entry): Update.
1116 (dwarf2_build_frame_info): Use "new".
1117
1118 2020-02-12 Christian Biesinger <cbiesinger@google.com>
1119
1120 * arm-tdep.c (arm_gdbarch_init): Update.
1121 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
1122 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
1123 have_neon, is_m>: Change to bool.
1124
1125 2020-02-12 Christian Biesinger <cbiesinger@google.com>
1126
1127 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
1128
1129 2020-02-12 Tom Tromey <tom@tromey.com>
1130
1131 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
1132
1133 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
1134
1135 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
1136 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
1137
1138 2020-02-11 Tom Tromey <tom@tromey.com>
1139
1140 * psymtab.h: Update comment.
1141
1142 2020-02-11 Tom Tromey <tom@tromey.com>
1143
1144 * gdb_obstack.h (struct auto_obstack): Use
1145 DISABLE_COPY_AND_ASSIGN.
1146
1147 2020-02-11 Tom Tromey <tom@tromey.com>
1148
1149 * dwarf2/frame.h (struct objfile): Don't forward declare.
1150
1151 2020-02-11 Christian Biesinger <cbiesinger@google.com>
1152
1153 * cris-tdep.c (cris_supply_gregset): Change signature to match
1154 what struct regset expects.
1155 (cris_regset): New struct.
1156 (fetch_core_registers): Remove.
1157 (cris_iterate_over_regset_sections): New function.
1158 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
1159 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
1160
1161 2020-02-11 Christian Biesinger <cbiesinger@google.com>
1162
1163 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
1164 registers.
1165
1166 2020-02-11 Christian Biesinger <cbiesinger@google.com>
1167
1168 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
1169
1170 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1171
1172 * configure: Re-generate.
1173
1174 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1175
1176 * configure: Re-generate.
1177
1178 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
1179
1180 * acinclude: Update warning.m4 path.
1181 * warning.m4: Move to gdbsupport.
1182
1183 2020-02-11 Tom Tromey <tromey@adacore.com>
1184
1185 * remote.c (remote_console_output): Update.
1186 * printcmd.c (printf_command): Update.
1187 * event-loop.c (gdb_wait_for_event): Update.
1188 * linux-nat.c (sigchld_handler): Update.
1189 * remote-sim.c (gdb_os_write_stdout): Update.
1190 (gdb_os_flush_stdout): Update.
1191 (gdb_os_flush_stderr): Update.
1192 (gdb_os_write_stderr): Update.
1193 * exceptions.c (print_exception): Update.
1194 * remote-fileio.c (remote_fileio_func_read): Update.
1195 (remote_fileio_func_write): Update.
1196 * tui/tui.c (tui_enable): Update.
1197 * tui/tui-interp.c (tui_interp::init): Update.
1198 * utils.c (init_page_info): Update.
1199 (putchar_unfiltered, fputc_unfiltered): Update.
1200 (gdb_flush): Update.
1201 (emit_style_escape): Update.
1202 (flush_wrap_buffer, fputs_maybe_filtered): Update.
1203 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
1204 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
1205 (stderr_file::write): Update.
1206 (stderr_file::puts): Update.
1207 * ui-file.h (ui_file_isatty, ui_file_write)
1208 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
1209 (ui_file_puts): Don't declare.
1210
1211 2020-02-10 Tom de Vries <tdevries@suse.de>
1212
1213 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
1214 sentinel to char *.
1215
1216 2020-02-09 Tom de Vries <tdevries@suse.de>
1217
1218 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
1219 filename if it matches "<artificial>".
1220
1221 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
1222
1223 * windows-tdep.c (struct enum_value_name): New struct.
1224 (create_enum): New function.
1225 (windows_get_siginfo_type): Create and use enum types.
1226
1227 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
1228
1229 * NEWS: Mention $_siginfo support for Windows.
1230 * windows-nat.c (handle_exception): Set siginfo_er.
1231 (windows_nat_target::mourn_inferior): Reset siginfo_er.
1232 (windows_xfer_siginfo): New function.
1233 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
1234 * windows-tdep.c (struct windows_gdbarch_data): New struct.
1235 (init_windows_gdbarch_data): New function.
1236 (get_windows_gdbarch_data): New function.
1237 (windows_get_siginfo_type): New function.
1238 (windows_init_abi): Register windows_get_siginfo_type.
1239 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
1240
1241 2020-02-08 Tom Tromey <tom@tromey.com>
1242
1243 * dwarf2/read.c (class cutu_reader) <cutu_reader,
1244 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
1245 <keep>: Declare method.
1246 <m_keep>: Remove member.
1247 <~cutu_reader>: Remove.
1248 (cutu_reader::init_tu_and_read_dwo_dies): Update.
1249 (cutu_reader::cutu_reader): Update.
1250 (cutu_reader::keep): Rename from ~cutu_reader.
1251 (process_psymtab_comp_unit, build_type_psymtabs_1)
1252 (process_skeletonless_type_unit, load_partial_comp_unit)
1253 (load_full_comp_unit, dwarf2_read_addr_index)
1254 (read_signatured_type): Update.
1255
1256 2020-02-08 Tom Tromey <tom@tromey.com>
1257
1258 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
1259 "want_partial_unit" parameter.
1260 (process_psymtab_comp_unit): Change want_partial_unit to bool.
1261 Inline check for DW_TAG_partial_unit.
1262 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
1263
1264 2020-02-08 Tom Tromey <tom@tromey.com>
1265
1266 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
1267 read.c.
1268 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
1269 read.c.
1270
1271 2020-02-08 Tom Tromey <tom@tromey.com>
1272
1273 * dwarf2/read.c (read_address): Move to comp-unit.c.
1274 (dwarf2_rnglists_process, dwarf2_ranges_process)
1275 (read_attribute_value, dwarf_decode_lines_1)
1276 (var_decode_location, decode_locdesc): Update.
1277 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
1278 read.c. Remove "cu" parameter.
1279 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
1280 method.
1281
1282 2020-02-08 Tom Tromey <tom@tromey.com>
1283
1284 * dwarf2/read.c (read_attribute_value, read_indirect_string)
1285 (read_indirect_line_string): Update.
1286 * dwarf2/comp-unit.c (read_offset): Remove.
1287 (read_comp_unit_head): Update.
1288 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
1289 method.
1290 (read_offset): Don't declare.
1291
1292 2020-02-08 Tom Tromey <tom@tromey.com>
1293
1294 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
1295 * dwarf2/read.c (struct comp_unit_head): Move to
1296 dwarf2/comp-unit.h.
1297 (enum class rcuh_kind): Move to comp-unit.h.
1298 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
1299 (read_comp_unit_head, error_check_comp_unit_head)
1300 (read_and_check_comp_unit_head): Move to comp-unit.c.
1301 (read_offset, dwarf_unit_type_name): Likewise.
1302 (create_debug_type_hash_table, read_cutu_die_from_dwo)
1303 (cutu_reader::cutu_reader, read_call_site_scope)
1304 (find_partial_die, follow_die_offset): Update.
1305 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
1306
1307 2020-02-08 Tom Tromey <tom@tromey.com>
1308
1309 * dwarf2/read.c (read_offset_1): Move to leb.c.
1310 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
1311 (dwarf_decode_macro_bytes): Update.
1312 * dwarf2/leb.c (read_offset): Rename; move from read.c.
1313 * dwarf2/leb.h (read_offset): Declare.
1314
1315 2020-02-08 Tom Tromey <tom@tromey.com>
1316
1317 * dwarf2/read.c (dwarf2_section_size): Remove.
1318 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
1319 Update.
1320 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
1321
1322 2020-02-08 Tom Tromey <tom@tromey.com>
1323
1324 * dwarf2/read.c (read_initial_length): Move to leb.c.
1325 * dwarf2/leb.h (read_initial_length): Declare.
1326 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
1327 handle_nonstd parameter.
1328 * dwarf2/frame.c (read_initial_length): Remove.
1329 (decode_frame_entry_1): Update.
1330
1331 2020-02-08 Tom Tromey <tom@tromey.com>
1332
1333 * dwarf2/loc.c (dwarf2_find_location_expression)
1334 (dwarf_evaluate_loc_desc::get_tls_address)
1335 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
1336 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
1337 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
1338 (dwarf2_compile_property_to_c)
1339 (dwarf2_loc_desc_get_symbol_read_needs)
1340 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
1341 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
1342 (loclist_describe_location, loclist_tracepoint_var_ref)
1343 (loclist_generate_c_location): Update.
1344 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
1345 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
1346 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
1347 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
1348 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
1349 (dwarf2_per_cu_data::addr_size)
1350 (dwarf2_per_cu_data::ref_addr_size)
1351 (dwarf2_per_cu_data::text_offset)
1352 (dwarf2_per_cu_data::addr_type): Now methods.
1353 (per_cu_header_read_in): Make per_cu "const".
1354 (dwarf2_version): Remove.
1355 (dwarf2_per_cu_data::int_type): Now a method.
1356 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
1357 (set_die_type, read_array_type, read_subrange_index_type)
1358 (read_tag_string_type, read_subrange_type): Update.
1359 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
1360 offset_size, ref_addr_size, text_offset, addr_type, version,
1361 objfile, int_type, addr_sized_int_type>: Declare methods.
1362
1363 2020-02-08 Tom Tromey <tom@tromey.com>
1364
1365 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
1366 Move earlier.
1367
1368 2020-02-08 Tom Tromey <tom@tromey.com>
1369
1370 * dwarf2/read.h (dwarf_line_debug): Declare.
1371 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
1372 * dwarf2/read.c: Move line_header code to new files.
1373 (dwarf_line_debug): No longer static.
1374 * dwarf2/line-header.c: New file.
1375 * dwarf2/line-header.h: New file.
1376
1377 2020-02-08 Tom Tromey <tom@tromey.com>
1378
1379 * dwarf2/read.c (struct line_header) <file_full_name,
1380 file_file_name>: Return unique_xmalloc_ptr.
1381 (line_header::file_file_name): Update.
1382 (line_header::file_full_name): Update.
1383 (dw2_get_file_names_reader): Update.
1384 (macro_start_file): Update.
1385
1386 2020-02-08 Tom Tromey <tom@tromey.com>
1387
1388 * dwarf2/read.c (struct line_header) <file_full_name,
1389 file_file_name>: Declare methods.
1390 (dw2_get_file_names_reader): Update.
1391 (file_file_name): Now a method.
1392 (file_full_name): Likewise.
1393 (macro_start_file): Update.
1394
1395 2020-02-08 Tom Tromey <tom@tromey.com>
1396
1397 * dwarf2/read.c (dwarf_always_disassemble)
1398 (show_dwarf_always_disassemble): Move to loc.c.
1399 (_initialize_dwarf2_read): Move "always-disassemble" registration
1400 to loc.c.
1401 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
1402 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
1403 static.
1404 (show_dwarf_always_disassemble): Move from read.c.
1405 (_initialize_dwarf2loc): Move always-disassemble from read.c.
1406
1407 2020-02-08 Tom Tromey <tom@tromey.com>
1408
1409 * dwarf2/read.c (~dwarf2_per_objfile): Update.
1410 (create_quick_file_names_table): Return htab_up.
1411 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
1412 Update.
1413 * dwarf2/read.h (struct dwarf2_per_objfile)
1414 <quick_file_names_table>: Now htab_up.
1415
1416 2020-02-08 Tom Tromey <tom@tromey.com>
1417
1418 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
1419
1420 2020-02-08 Tom Tromey <tom@tromey.com>
1421
1422 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
1423 Rewrite.
1424 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
1425 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
1426 (abbrev_table::abbrev_table): No longer inline.
1427 (ABBREV_HASH_SIZE): Remove.
1428 (abbrev_table::m_abbrevs): Now an htab_up.
1429
1430 2020-02-08 Tom Tromey <tom@tromey.com>
1431
1432 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
1433 (cutu_reader): Update.
1434 (build_type_psymtabs_1): Update.
1435 * dwarf2/abbrev.c (abbrev_table::read): Rename.
1436 (abbrev_table::alloc_abbrev): Update.
1437 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
1438 (abbrev_table::read): New static method, renamed from
1439 abbrev_table_read_table.
1440 (abbrev_table::alloc_abbrev)
1441 (abbrev_table::add_abbrev): Now private.
1442 (abbrev_table::abbrev_table): Now private.
1443 (abbrev_table::m_abbrev_obstack): Now private. Rename.
1444
1445 2020-02-08 Tom Tromey <tom@tromey.com>
1446
1447 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
1448 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
1449 htab_up.
1450
1451 2020-02-08 Tom Tromey <tom@tromey.com>
1452
1453 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
1454 htab_up.
1455 (lookup_dwo_unit_in_dwp): Update.
1456 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
1457 on obstack.
1458
1459 2020-02-08 Tom Tromey <tom@tromey.com>
1460
1461 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
1462 obstack.
1463
1464 2020-02-08 Tom Tromey <tom@tromey.com>
1465
1466 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
1467 line_header_hash.
1468 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
1469 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
1470 Change type to htab_up.
1471
1472 2020-02-08 Tom Tromey <tom@tromey.com>
1473
1474 * dwarf2/read.c (allocate_type_unit_groups_table): Return
1475 htab_up. Don't allocate on obstack.
1476 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
1477 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
1478 Change type to htab_up.
1479
1480 2020-02-08 Tom Tromey <tom@tromey.com>
1481
1482 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
1483 Change type to htab_up.
1484 * dwarf2/read.c (create_signatured_type_table_from_index)
1485 (create_signatured_type_table_from_debug_names)
1486 (create_all_type_units, add_type_unit)
1487 (lookup_dwo_signatured_type, lookup_signatured_type)
1488 (process_skeletonless_type_unit): Update.
1489 (create_debug_type_hash_table, create_debug_types_hash_table):
1490 Change type of types_htab.
1491 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
1492 htab_up. Don't allocate on obstack.
1493 (create_cus_hash_table): Change type of cus_htab parameter.
1494 (struct dwo_file) <cus, tus>: Now htab_up.
1495 (lookup_dwo_signatured_type, lookup_dwo_cutu)
1496 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
1497 (queue_and_load_all_dwo_tus): Update.
1498 * dwarf2/index-write.c (write_gdbindex): Update.
1499 (write_debug_names): Update.
1500
1501 2020-02-08 Tom Tromey <tom@tromey.com>
1502
1503 * dwarf2/read.h (struct dwarf2_queue_item): Move from
1504 dwarf2/read.c. Remove "next" member. Add constructor ntad
1505 destructor.
1506 (struct dwarf2_per_objfile) <queue>: New member.
1507 * dwarf2/read.c (struct dwarf2_queue_item): Move to
1508 dwarf2/read.h.
1509 (dwarf2_queue, dwarf2_queue_tail): Remove.
1510 (class dwarf2_queue_guard): Add parameter to constructor. Use
1511 DISABLE_COPY_AND_ASSIGN.
1512 <m_per_objfile>: New member.
1513 <~dwarf2_queue_guard>: Rewrite.
1514 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
1515 Update.
1516 (~dwarf2_queue_item): New.
1517
1518 2020-02-08 Tom Tromey <tom@tromey.com>
1519
1520 * dwarf2/read.c (struct die_info) <has_children>: New member.
1521 (dw2_get_file_names_reader): Remove has_children.
1522 (dw2_get_file_names): Update.
1523 (read_cutu_die_from_dwo): Remove has_children.
1524 (cutu_reader::init_tu_and_read_dwo_dies)
1525 (cutu_reader::cutu_reader): Update.
1526 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
1527 Remove has_children.
1528 (build_type_psymtabs_1, process_skeletonless_type_unit)
1529 (load_partial_comp_unit, load_full_comp_unit): Update.
1530 (create_dwo_cu_reader): Remove has_children.
1531 (create_cus_hash_table, read_die_and_children): Update.
1532 (read_full_die_1,read_full_die): Remove has_children.
1533 (read_signatured_type): Update.
1534 (class cutu_reader) <has_children>: Remove.
1535
1536 2020-02-08 Tom Tromey <tom@tromey.com>
1537
1538 * dwarf2/expr.c: Rename from dwarf2expr.c.
1539 * dwarf2/expr.h: Rename from dwarf2expr.h.
1540 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
1541 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
1542 * dwarf2/frame.c: Rename from dwarf2-frame.c.
1543 * dwarf2/frame.h: Rename from dwarf2-frame.h.
1544 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
1545 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
1546 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
1547 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
1548 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
1549 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
1550 * dwarf2/loc.c: Rename from dwarf2loc.c.
1551 * dwarf2/loc.h: Rename from dwarf2loc.h.
1552 * dwarf2/read.c: Rename from dwarf2read.c.
1553 * dwarf2/read.h: Rename from dwarf2read.h.
1554 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
1555 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
1556 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
1557 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
1558 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
1559 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
1560 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
1561 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
1562 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
1563 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
1564 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
1565 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
1566 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
1567 Update.
1568 * Makefile.in (COMMON_SFILES): Update.
1569 (HFILES_NO_SRCDIR): Update.
1570
1571 2020-02-08 Tom Tromey <tom@tromey.com>
1572
1573 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
1574 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
1575
1576 2020-02-08 Tom Tromey <tom@tromey.com>
1577
1578 * dwarf2read.h (struct die_info): Don't declare.
1579
1580 2020-02-08 Tom Tromey <tom@tromey.com>
1581
1582 * dwarf2read.h (die_info_ptr): Remove typedef.
1583
1584 2020-02-08 Tom Tromey <tom@tromey.com>
1585
1586 * dwarf2read.c (read_call_site_scope)
1587 (handle_data_member_location, dwarf2_add_member_fn)
1588 (mark_common_block_symbol_computed, read_common_block)
1589 (attr_to_dynamic_prop, partial_die_info::read)
1590 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
1591 (dwarf2_symbol_mark_computed, set_die_type): Update.
1592 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
1593 method.
1594 (attr_form_is_block): Don't declare.
1595 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
1596
1597 2020-02-08 Tom Tromey <tom@tromey.com>
1598
1599 * dwarf2read.c (dwarf2_find_base_address, )
1600 (read_call_site_scope, rust_containing_type)
1601 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
1602 (handle_data_member_location, dwarf2_add_member_fn)
1603 (get_alignment, read_structure_type, process_structure_scope)
1604 (mark_common_block_symbol_computed, read_common_block)
1605 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
1606 (partial_die_info::read, read_attribute_value, new_symbol)
1607 (lookup_die_type, dwarf2_get_ref_die_offset)
1608 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
1609 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
1610 (dwarf2_symbol_mark_computed): Update.
1611 * dwarf2/attribute.h (struct attribute) <value_as_address,
1612 form_is_section_offset, form_is_constant, form_is_ref>: Declare
1613 methods.
1614 (value_as_address, attr_form_is_section_offset)
1615 (attr_form_is_constant, attr_form_is_ref): Don't declare.
1616 * dwarf2/attribute.c (attribute::value_as_address)
1617 (attribute::form_is_section_offset, attribute::form_is_constant)
1618 (attribute::form_is_ref): Now methods.
1619
1620 2020-02-08 Tom Tromey <tom@tromey.com>
1621
1622 * dwarf2read.c (struct attribute, DW_STRING)
1623 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
1624 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
1625 (attr_form_is_block, attr_form_is_section_offset)
1626 (attr_form_is_constant, attr_form_is_ref): Move.
1627 * dwarf2/attribute.h: New file.
1628 * dwarf2/attribute.c: New file, from dwarf2read.c.
1629 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
1630
1631 2020-02-08 Tom Tromey <tom@tromey.com>
1632
1633 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
1634 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
1635 Move.
1636 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
1637 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
1638 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
1639 abbrev.c.
1640 * dwarf2/abbrev.h: New file.
1641 * dwarf2/abbrev.c: New file, from dwarf2read.c.
1642 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
1643
1644 2020-02-08 Tom Tromey <tom@tromey.com>
1645
1646 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
1647 (dwarf2_section_size, dwarf2_get_section_info)
1648 (create_signatured_type_table_from_debug_names)
1649 (create_addrmap_from_aranges, read_debug_names_from_section)
1650 (get_gdb_index_contents_from_section, read_comp_unit_head)
1651 (error_check_comp_unit_head, read_abbrev_offset)
1652 (create_debug_type_hash_table, init_cu_die_reader)
1653 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
1654 (read_comp_units_from_section, create_cus_hash_table)
1655 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
1656 (create_dwp_v2_section, dwarf2_rnglists_process)
1657 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
1658 (abbrev_table_read_table, read_indirect_string_at_offset_from)
1659 (read_indirect_string_from_dwz, read_addr_index_1)
1660 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
1661 (dwarf_decode_macro_bytes, dwarf_decode_macros)
1662 (fill_in_loclist_baton): Update.
1663 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
1664 get_containing_section, get_bfd_owner, get_bfd_section,
1665 get_file_name, get_id, get_flags, empty, read>: Declare methods.
1666 (dwarf2_read_section, get_section_name, get_section_file_name)
1667 (get_containing_section, get_section_bfd_owner)
1668 (get_section_bfd_section, get_section_name, get_section_file_name)
1669 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
1670 declare.
1671 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
1672 (dwarf2_section_info::get_bfd_owner)
1673 (dwarf2_section_info::get_bfd_section)
1674 (dwarf2_section_info::get_name)
1675 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
1676 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
1677 (dwarf2_section_info::read): Now methods.
1678 * dwarf-index-write.c (class debug_names): Update.
1679
1680 2020-02-08 Tom Tromey <tom@tromey.com>
1681
1682 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
1683 Move to dwarf2/section.h.
1684 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
1685 (get_section_bfd_section, get_section_name)
1686 (get_section_file_name, get_section_id, get_section_flags)
1687 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
1688 dwarf2/section.c.
1689 * dwarf2/section.h: New file.
1690 * dwarf2/section.c: New file, from dwarf2read.c.
1691 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
1692
1693 2020-02-08 Tom Tromey <tom@tromey.com>
1694
1695 * dwarf2read.h (read_unsigned_leb128): Don't declare.
1696 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
1697 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
1698 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
1699 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
1700 * dwarf2/leb.h: New file, from dwarf2read.c.
1701 * dwarf2/leb.c: New file, from dwarf2read.c.
1702 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
1703 Remove.
1704 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
1705 (COMMON_SFILES): Add dwarf2/leb.c.
1706
1707 2020-02-08 Joel Brobecker <brobecker@adacore.com>
1708
1709 GDB 9.1 released.
1710
1711 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
1712
1713 PR gdb/25190:
1714 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
1715 * gdb/remote.c (remote_console_output): Update.
1716 * gdb/ui-file.c (fputs_unfiltered): Rename to...
1717 (ui_file_puts): ...this.
1718 * gdb/ui-file.h (ui_file_puts): Add declaration.
1719 * gdb/utils.c (emit_style_escape): Update.
1720 (flush_wrap_buffer): Update.
1721 (fputs_maybe_filtered): Update.
1722 (fputs_unfiltered): Add function.
1723
1724 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
1725
1726 * gdb/event-loop.c (gdb_wait_for_event): Update.
1727 * gdb/printcmd.c (printf_command): Update.
1728 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
1729 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
1730 (gdb_os_flush_stderr): Update.
1731 * gdb/remote.c (remote_console_output): Update.
1732 * gdb/ui-file.c (gdb_flush): Rename to...
1733 (ui_file_flush): ...this.
1734 (stderr_file::write): Update.
1735 (stderr_file::puts): Update.
1736 * gdb/ui-file.h (gdb_flush): Rename to...
1737 (ui_file_flush): ...this.
1738 * gdb/utils.c (gdb_flush): Add function.
1739 * gdb/utils.h (gdb_flush): Add declaration.
1740
1741 2020-02-07 Tom Tromey <tromey@adacore.com>
1742
1743 PR breakpoints/24915:
1744 * source.c (find_and_open_source): Do not check basenames_may_differ.
1745
1746 2020-02-07 Tom Tromey <tom@tromey.com>
1747
1748 * README: Update gdbserver documentation.
1749 * gdbserver: Move to top level.
1750 * configure.tgt (build_gdbserver): Remove.
1751 * configure.ac: Remove --enable-gdbserver.
1752 * configure: Rebuild.
1753 * Makefile.in (distclean): Don't mention gdbserver.
1754
1755 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
1756
1757 * source-cache.c (source_cache::ensure): Surround
1758 get_plain_source_lines with a try/catch.
1759 (source_cache::get_line_charpos): Get rid of try/catch
1760 and only check for the return value of "ensure".
1761 * tui/tui-source.c (tui_source_window::set_contents):
1762 Simplify "nlines" calculation.
1763
1764 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
1765
1766 * MAINTAINERS (Write After Approval): Add myself.
1767
1768 2020-02-05 Christian Biesinger <cbiesinger@google.com>
1769
1770 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
1771 function call.
1772
1773 2020-02-05 Christian Biesinger <cbiesinger@google.com>
1774
1775 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
1776
1777 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
1778
1779 * nat/riscv-linux-tdesc.h: New file.
1780 * nat/riscv-linux-tdesc.c: New file, taking code from...
1781 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
1782 ... here.
1783 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
1784 NATDEPFILES.
1785
1786 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
1787
1788 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
1789 we don't set the fake simulator ptid to the null_ptid.
1790
1791 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
1792
1793 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
1794 * gdbthread.h (class thread_info) <resumed>: Likewise.
1795 * infrun.c (resume_1): Likewise.
1796 (proceed): Likewise.
1797 (infrun_thread_stop_requested): Likewise.
1798 (stop_all_threads): Likewise.
1799 (handle_inferior_event): Likewise.
1800 (restart_threads): Likewise.
1801 (finish_step_over): Likewise.
1802 (keep_going_stepped_thread): Likewise.
1803 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
1804 (linux_handle_extended_wait): Likewise.
1805 * record-btrace.c (get_thread_current_frame_id): Likewise.
1806 * record-full.c (record_full_wait_1): Likewise.
1807 * remote.c (remote_target::process_initial_stop_replies): Likewise.
1808 * target.c (target_resume): Likewise.
1809 * thread.c (set_running_thread): Likewise.
1810
1811 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1812
1813 * f-valprint.c (f77_print_array_1): Changed datatype of index
1814 variable to LONGEST from int to enable it to contain bound
1815 values correctly.
1816
1817 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
1818
1819 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
1820 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
1821 offsets according to FLEN determined.
1822 (riscv_linux_nat_target::read_description): Determine FLEN
1823 dynamically.
1824 (riscv_linux_nat_target::fetch_registers): Size regset buffer
1825 according to FLEN determined.
1826 (riscv_linux_nat_target::store_registers): Likewise.
1827
1828 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
1829
1830 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
1831 when reg->group is empty and reggroup is not.
1832
1833 2020-01-31 Tom Tromey <tromey@adacore.com>
1834
1835 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
1836 Call beneath target's mourn_inferior after unpushing.
1837
1838 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
1839
1840 PR tui/9765
1841 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
1842 have enough lines to fill the screen, still return the lowest
1843 address we found.
1844
1845 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
1846
1847 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
1848 '-', '<', and '>' commands.
1849
1850 2020-01-29 Pedro Alves <palves@redhat.com>
1851 Sergio Durigan Junior <sergiodj@redhat.com>
1852
1853 * infcmd.c (construct_inferior_arguments): Assert that
1854 'argc' is greater than 0.
1855
1856 2020-01-29 Luis Machado <luis.machado@linaro.org>
1857
1858 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
1859 (BRK_INSN_MASK): Define to 0xd4200000.
1860 (aarch64_program_breakpoint_here_p): New function.
1861 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
1862 * arch-utils.c (default_program_breakpoint_here_p): Moved from
1863 breakpoint.c.
1864 * arch-utils.h (default_program_breakpoint_here_p): Moved from
1865 breakpoint.h
1866 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
1867 call gdbarch_program_breakpoint_here_p.
1868 (program_breakpoint_here): Moved to arch-utils.c, renamed to
1869 default_program_breakpoint_here_p, changed return type to bool and
1870 simplified.
1871 * breakpoint.h (program_breakpoint_here): Moved prototype to
1872 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
1873 return type to bool.
1874 * gdbarch.c: Regenerate.
1875 * gdbarch.h: Regenerate.
1876 * gdbarch.sh (program_breakpoint_here_p): New method.
1877 * infrun.c (handle_signal_stop): Call
1878 gdbarch_program_breakpoint_here_p.
1879
1880 2020-01-26 Tom Tromey <tom@tromey.com>
1881
1882 * ctfread.c (struct ctf_fp_info): Reindent.
1883 (_initialize_ctfread): Remove.
1884
1885 2020-01-26 Tom Tromey <tom@tromey.com>
1886
1887 * psymtab.c (partial_map_expand_apply)
1888 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
1889 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
1890 (psym_print_stats, psym_expand_symtabs_for_function)
1891 (psym_map_symbol_filenames, psym_map_matching_symbols)
1892 (psym_expand_symtabs_matching)
1893 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
1894 (maintenance_check_psymtabs): Use new methods.
1895 * psympriv.h (struct partial_symtab) <readin_p,
1896 get_compunit_symtab>: New methods.
1897 <readin, compunit_symtab>: Remove members.
1898 (struct standard_psymtab): New.
1899 (struct legacy_psymtab): Derive from standard_psymtab.
1900 * dwarf2read.h (struct dwarf2_psymtab): Derive from
1901 standard_psymtab.
1902 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
1903
1904 2020-01-26 Tom Tromey <tom@tromey.com>
1905
1906 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
1907 read_dependencies. Add assert.
1908 * psymtab.c (partial_symtab::read_dependencies): New method.
1909 * psympriv.h (struct partial_symtab) <read_dependencies>: New
1910 method.
1911 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
1912 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
1913 read_dependencies.
1914 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
1915 Add assert.
1916
1917 2020-01-26 Tom Tromey <tom@tromey.com>
1918
1919 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
1920 Call expand_psymtab.
1921 (xcoff_read_symtab): Call expand_psymtab.
1922 (xcoff_start_psymtab, xcoff_end_psymtab): Set
1923 legacy_expand_psymtab.
1924 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
1925 method.
1926 (struct legacy_psymtab) <expand_psymtab>: Implement.
1927 <legacy_expand_psymtab>: New member.
1928 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
1929 (parse_partial_symbols): Set legacy_expand_psymtab.
1930 (psymtab_to_symtab_1): Change argument order. Call
1931 expand_psymtab.
1932 (new_psymtab): Set legacy_expand_psymtab.
1933 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
1934 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
1935 expand_psymtab.
1936 (dwarf2_psymtab::expand_psymtab): Rename from
1937 psymtab_to_symtab_1. Call expand_psymtab.
1938 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
1939 (dbx_end_psymtab): Likewise.
1940 (dbx_psymtab_to_symtab_1): Change argument order. Call
1941 expand_psymtab.
1942 (dbx_read_symtab): Call expand_psymtab.
1943 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
1944 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
1945 (ctf_psymtab::read_symtab): Call expand_psymtab.
1946
1947 2020-01-26 Tom Tromey <tom@tromey.com>
1948
1949 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
1950 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
1951 messages.
1952 * mdebugread.c (mdebug_read_symtab): Remove prints.
1953 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
1954 assert.
1955 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
1956
1957 2020-01-26 Tom Tromey <tom@tromey.com>
1958
1959 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
1960 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
1961 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
1962 legacy_symtab.
1963 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
1964 * psymtab.c (psymtab_to_symtab): Call method.
1965 (dump_psymtab): Update.
1966 * psympriv.h (struct partial_symtab): Add virtual destructor.
1967 <read_symtab>: New method.
1968 (struct legacy_symtab): New.
1969 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
1970 (struct pst_map) <pst>: Now a legacy_psymtab.
1971 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
1972 (new_psymtab): Use legacy_psymtab.
1973 * dwarf2read.h (struct dwarf2_psymtab): New.
1974 (struct dwarf2_per_cu_data) <psymtab>: Use it.
1975 * dwarf2read.c (dwarf2_create_include_psymtab)
1976 (dwarf2_build_include_psymtabs, create_type_unit_group)
1977 (create_partial_symtab, process_psymtab_comp_unit_reader)
1978 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
1979 (set_partial_user): Use dwarf2_psymtab.
1980 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
1981 (psymtab_to_symtab_1, process_full_comp_unit)
1982 (process_full_type_unit, dwarf2_ranges_read)
1983 (dwarf2_get_pc_bounds, psymtab_include_file_name)
1984 (dwarf_decode_lines): Use dwarf2_psymtab.
1985 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
1986 (add_address_entry_worker, write_one_signatured_type)
1987 (recursively_count_psymbols, recursively_write_psymbols)
1988 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
1989 (write_debug_names): Likewise.
1990 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
1991 <pst>: Now a legacy_psymtab.
1992 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
1993 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
1994 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
1995 * ctfread.c (struct ctf_psymtab): New.
1996 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
1997 ctf_psymtab.
1998 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
1999 (create_partial_symtab): Return a ctf_psymtab.
2000 (scan_partial_symbols): Update.
2001
2002 2020-01-26 Tom Tromey <tom@tromey.com>
2003
2004 * xcoffread.c (xcoff_start_psymtab): Use new.
2005 * psymtab.c (partial_symtab::partial_symtab): New constructor,
2006 renamed from start_psymtab_common.
2007 * psympriv.h (struct partial_symtab): Add new constructor.
2008 (start_psymtab_common): Don't declare.
2009 * mdebugread.c (parse_partial_symbols): Use new.
2010 * dwarf2read.c (create_partial_symtab): Use new.
2011 * dbxread.c (start_psymtab): Use new.
2012 * ctfread.c (create_partial_symtab): Use new.
2013
2014 2020-01-26 Tom Tromey <tom@tromey.com>
2015
2016 * xcoffread.c (xcoff_end_psymtab): Use new.
2017 * psymtab.c (start_psymtab_common): Use new.
2018 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
2019 Update.
2020 * psympriv.h (struct partial_symtab): Add parameters to
2021 constructor. Don't inline.
2022 (allocate_psymtab): Don't declare.
2023 * mdebugread.c (new_psymtab): Use new.
2024 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
2025 * dbxread.c (dbx_end_psymtab): Use new.
2026
2027 2020-01-26 Tom Tromey <tom@tromey.com>
2028
2029 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
2030 allocate_psymtab. Update documentation.
2031 * psymtab.c (psymtab_storage::install_psymtab): Rename from
2032 allocate_psymtab. Do not use new.
2033 (allocate_psymtab): Use new. Update.
2034
2035 2020-01-26 Tom Tromey <tom@tromey.com>
2036
2037 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
2038 * psymtab.c (psym_print_stats): Update.
2039 * psympriv.h (struct partial_symtab) <readin,
2040 psymtabs_addrmap_supported, anonymous>: Now bool.
2041 * mdebugread.c (psymtab_to_symtab_1): Update.
2042 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
2043 (build_type_psymtabs_reader, psymtab_to_symtab_1)
2044 (process_full_comp_unit, process_full_type_unit): Update.
2045 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
2046 * ctfread.c (psymtab_to_symtab): Update.
2047
2048 2020-01-26 Tom Tromey <tom@tromey.com>
2049
2050 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
2051 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
2052 * psymtab.c (psymtab_storage): Delete psymtabs.
2053 (psymtab_storage::allocate_psymtab): Use new.
2054 (psymtab_storage::discard_psymtab): Use delete.
2055 * psympriv.h (struct partial_symtab): Add constructor and
2056 initializers.
2057
2058 2020-01-26 Tom Tromey <tom@tromey.com>
2059
2060 * machoread.c: Do not include psympriv.h.
2061
2062 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2063
2064 * NEWS: Mention the new option and the set/show commands.
2065
2066 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2067
2068 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
2069 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
2070 (validate_exec_file): New variables, enums, functions.
2071 (exec_file_locate_attach, print_section_info): Style the filenames.
2072 (_initialize_exec): Install show_exec_file_mismatch_command and
2073 set_exec_file_mismatch_command.
2074 * gdbcore.h (validate_exec_file): Declare.
2075 * infcmd.c (attach_command): Call validate_exec_file.
2076 * remote.c ( remote_target::remote_add_inferior): Likewise.
2077
2078 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
2079
2080 * frame.c (find_frame_sal): Move call to get_next_frame into more
2081 inner scope.
2082 * inline-frame.c (inilne_state) <inline_state>: Update argument
2083 types.
2084 (inilne_state) <skipped_symbol>: Rename to...
2085 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
2086 (skip_inline_frames): Build vector of skipped symbols and use this
2087 to reate the inline_state.
2088 (inline_skipped_symbol): Add a comment and some assertions, fetch
2089 skipped symbol from the list.
2090
2091 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
2092
2093 * buildsym.c (lte_is_less_than): Delete.
2094 (buildsym_compunit::end_symtab_with_blockvector): Create local
2095 lambda function to sort line table entries, and use
2096 std::stable_sort instead of std::sort.
2097 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
2098 markers when looking for a previous line.
2099
2100 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
2101
2102 * dwarf2read.c (lnp_state_machine::record_line): Include
2103 end_sequence parameter in debug print out. Record the line if we
2104 are at an end_sequence marker even if it's not the start of a
2105 statement.
2106 * symmisc.c (maintenance_print_one_line_table): Print end of
2107 sequence markers with 'END' not '0'.
2108
2109 2020-01-24 Pedro Alves <palves@redhat.com>
2110
2111 PR gdb/25410
2112 * thread.c (scoped_restore_current_thread::restore): Use
2113 switch_to_inferior_no_thread.
2114 * exec.c: Include "progspace-and-thread.h".
2115 (add_target_sections, remove_target_sections):
2116 scoped_restore_current_pspace_and_thread instead of
2117 scoped_restore_current_thread.
2118 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
2119 and aspace to the inferior before calling clone_program_space.
2120 Remove stale comment.
2121
2122 2020-01-24 Christian Biesinger <cbiesinger@google.com>
2123
2124 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
2125 (arm_netbsd_nat_target::fetch_registers): ...this.
2126 (arm_nbsd_nat_target::store_registers): Rename to...
2127 (arm_netbsd_nat_target::store_registers): ...this.
2128
2129 2020-01-24 Christian Biesinger <cbiesinger@google.com>
2130
2131 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
2132 register_t.
2133
2134 2020-01-24 Christian Biesinger <cbiesinger@google.com>
2135
2136 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
2137 Update comment.
2138 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
2139 Likewise.
2140 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
2141 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
2142 the correct replacement (iterate_over_regset_sections).
2143 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
2144 Update comment.
2145
2146 2020-01-24 Graham Markall <graham.markall@embecosm.com>
2147
2148 PR gdb/23718
2149 * gdb/python/python.c (execute_gdb_command): Call
2150 async_enable_stdin in catch block.
2151
2152 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
2153
2154 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
2155 SWITCH_THRU_ALL_UIS.
2156
2157 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
2158
2159 PR tui/9765
2160 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
2161 comment, add extra parameter, and update to store previous symbol
2162 when appropriate.
2163 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
2164 add extra parameter.
2165 * tui/tui-disasm.c (tui_disassemble): Update header comment,
2166 remove unneeded parameter, add try/catch around gdb_print_insn,
2167 rewrite to add items to asm_lines vector.
2168 (tui_find_backward_disassembly_start_address): New function.
2169 (tui_find_disassembly_address): Updated throughout.
2170 (tui_disasm_window::set_contents): Update for changes to
2171 tui_disassemble.
2172 (tui_disasm_window::do_scroll_vertical): No need to adjust the
2173 number of lines to scroll.
2174
2175 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
2176
2177 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
2178 (SECT_OFF_DATA): Likewise.
2179 (SECT_OFF_RODATA): Likewise.
2180 (SECT_OFF_TEXT): Likewise.
2181 (SECT_OFF_BSS): Likewise.
2182 (struct objfile) <text_section_offset, data_section_offset>: New
2183 methods.
2184 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
2185 objfile::text_section_offset.
2186 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
2187 * coffread.c (coff_symtab_read): Likewise.
2188 (enter_linenos): Likewise.
2189 (process_coff_symbol): Likewise.
2190 * ctfread.c (get_objfile_text_range): Likewise.
2191 * dtrace-probe.c (dtrace_probe::get_relocated_address):
2192 Use objfile::data_section_offset.
2193 * dwarf2-frame.c (execute_cfa_program): Use
2194 objfile::text_section_offset.
2195 (dwarf2_frame_find_fde): Likewise.
2196 * dwarf2read.c (create_addrmap_from_index): Likewise.
2197 (create_addrmap_from_aranges): Likewise.
2198 (dw2_find_pc_sect_compunit_symtab): Likewise.
2199 (process_psymtab_comp_unit_reader): Likewise.
2200 (add_partial_symbol): Likewise.
2201 (add_partial_subprogram): Likewise.
2202 (process_full_comp_unit): Likewise.
2203 (read_file_scope): Likewise.
2204 (read_func_scope): Likewise.
2205 (read_lexical_block_scope): Likewise.
2206 (read_call_site_scope): Likewise.
2207 (dwarf2_rnglists_process): Likewise.
2208 (dwarf2_ranges_process): Likewise.
2209 (dwarf2_ranges_read): Likewise.
2210 (dwarf_decode_lines_1): Likewise.
2211 (new_symbol): Likewise.
2212 (dwarf2_fetch_die_loc_sect_off): Likewise.
2213 (dwarf2_per_cu_text_offset): Likewise.
2214 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
2215 * hppa-tdep.c (read_unwind_info): Likewise.
2216 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
2217 * psympriv.h (struct partial_symtab): Likewise.
2218 * psymtab.c (find_pc_sect_psymtab): Likewise.
2219 * solib-svr4.c (enable_break): Likewise.
2220 * stap-probe.c (relocate_address): Use
2221 objfile::data_section_offset.
2222 * xcoffread.c (enter_line_range): Use
2223 objfile::text_section_offset.
2224 (read_xcoff_symtab): Likewise.
2225
2226 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
2227
2228 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
2229 declaration to narrower scopes.
2230
2231 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
2232
2233 * darwin-nat.h (struct darwin_exception_msg, enum
2234 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
2235 Move up.
2236 (class darwin_nat_target) <wait_1, check_new_threads,
2237 decode_exception_message, decode_message, stop_inferior,
2238 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
2239 * darwin-nat.c (darwin_check_new_threads): Rename to...
2240 (darwin_nat_target::check_new_threads): ... this.
2241 (darwin_suspend_inferior_it): Remove.
2242 (darwin_decode_exception_message): Rename to...
2243 (darwin_nat_target::decode_exception_message): ... this.
2244 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
2245 (darwin_decode_message): Rename to...
2246 (darwin_nat_target::decode_message): ... this.
2247 (cancel_breakpoint): Rename to...
2248 (darwin_nat_target::cancel_breakpoint): ... this.
2249 (darwin_wait): Rename to...
2250 (darwin_nat_target::wait_1): ... this. Use range-based for loop
2251 instead of iterate_over_inferiors.
2252 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
2253 (darwin_stop_inferior): Rename to...
2254 (darwin_nat_target::stop_inferior): ... this.
2255 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
2256 (darwin_init_thread_list): Rename to...
2257 (darwin_nat_target::init_thread_list): ... this.
2258 (darwin_ptrace_him): Rename to...
2259 (darwin_nat_target::ptrace_him): ... this.
2260 (darwin_nat_target::create_inferior): Pass lambda function to
2261 fork_inferior.
2262 (darwin_nat_target::detach): Call stop_inferior instead of
2263 darwin_stop_inferior.
2264 * fork-inferior.h (fork_inferior): Change init_trace_fun
2265 parameter to gdb::function_view.
2266 * fork-inferior.c (fork_inferior): Likewise.
2267
2268 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
2269
2270 * i386-cygwin-tdep.c (core_process_module_section): Update.
2271 * windows-nat.c (struct lm_info_windows): Add text_offset.
2272 (windows_xfer_shared_libraries): Update.
2273 * windows-tdep.c (windows_xfer_shared_library):
2274 Add text_offset_cached argument.
2275 * windows-tdep.h (windows_xfer_shared_library): Update.
2276
2277 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
2278
2279 * gdbarch.sh: Add declaration for _initialize_gdbarch.
2280
2281 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
2282
2283 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
2284 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
2285 replace with range-based for.
2286 (gdbsim_interrupt_inferior): Remove.
2287 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
2288 with a range-based for. Inline code from
2289 gdbsim_interrupt_inferior.
2290
2291 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
2292
2293 * infrun.c (proceed): Fix indentation.
2294
2295 2020-01-21 Tom Tromey <tromey@adacore.com>
2296
2297 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
2298 * python/python.c (python_extension_ops): Update.
2299 (gdbpy_colorize): New function.
2300 * python/lib/gdb/__init__.py (colorize): New function.
2301 * extension.h (ext_lang_colorize): Declare.
2302 * extension.c (ext_lang_colorize): New function.
2303 * extension-priv.h (struct extension_language_ops) <colorize>: New
2304 member.
2305 * cli/cli-style.c (_initialize_cli_style): Update help text.
2306
2307 2020-01-21 Luis Machado <luis.machado@linaro.org>
2308
2309 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
2310 <cond>: Change type to bool.
2311 (aarch64_displaced_step_b_cond): Update cond to use bool type.
2312 (aarch64_displaced_step_cb): Likewise.
2313 (aarch64_displaced_step_tb): Likewise.
2314
2315 2020-01-21 Luis Machado <luis.machado@linaro.org>
2316
2317 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
2318 output.
2319
2320 2020-01-21 Luis Machado <luis.machado@linaro.org>
2321
2322 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
2323 <pc_adjust>: Adjust the documentation.
2324 (aarch64_displaced_step_fixup): Check if PC really moved before
2325 adjusting it.
2326
2327 2020-01-19 Tom Tromey <tom@tromey.com>
2328
2329 * disasm.c (~gdb_disassembler): New destructor.
2330 (gdb_buffered_insn_length): Call disassemble_free_target.
2331 * disasm.h (class gdb_disassembler): Declare destructor. Use
2332 DISABLE_COPY_AND_ASSIGN.
2333
2334 2020-01-19 Tom Tromey <tom@tromey.com>
2335
2336 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
2337 (die_reader_func_ftype): Remove.
2338 (cutu_reader): New class.
2339 (dw2_get_file_names_reader): Remove "data" parameter.
2340 (dw2_get_file_names): Use cutu_reader.
2341 (create_debug_type_hash_table): Update.
2342 (read_cutu_die_from_dwo): Update comment.
2343 (lookup_dwo_unit): Add dwo_name parameter.
2344 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
2345 die_reader_func_ftype and data parameters.
2346 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
2347 Remove die_reader_func_ftype and data parameters.
2348 (~cutu_reader): New; from init_cutu_and_read_dies.
2349 (cutu_reader::cutu_reader): Rename from
2350 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
2351 and data parameters.
2352 (init_cutu_and_read_dies_simple): Remove.
2353 (struct process_psymtab_comp_unit_data): Remove.
2354 (process_psymtab_comp_unit_reader): Remove data parameter; add
2355 want_partial_unit and pretend_language parameters.
2356 (process_psymtab_comp_unit): Use cutu_reader.
2357 (build_type_psymtabs_reader): Remove data parameter.
2358 (build_type_psymtabs_1): Use cutu_reader.
2359 (process_skeletonless_type_unit): Likewise.
2360 (load_partial_comp_unit_reader): Remove.
2361 (load_partial_comp_unit): Use cutu_reader.
2362 (load_full_comp_unit_reader): Remove.
2363 (load_full_comp_unit): Use cutu_reader.
2364 (struct create_dwo_cu_data): Remove.
2365 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
2366 dwo_unit parameters.
2367 (create_cus_hash_table): Use cutu_reader.
2368 (struct dwarf2_read_addr_index_data): Remove.
2369 (dwarf2_read_addr_index_reader): Remove.
2370 (dwarf2_read_addr_index): Use cutu_reader.
2371 (read_signatured_type_reader): Remove.
2372 (read_signatured_type): Use cutu_reader.
2373
2374 2020-01-19 Tom Tromey <tom@tromey.com>
2375
2376 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
2377 * tui/tui-wingeneral.h (class tui_suppress_output): New.
2378 (tui_wrefresh): Declare.
2379 * tui/tui-wingeneral.c (suppress_output): New global.
2380 (tui_suppress_output, ~tui_suppress_output): New constructor and
2381 destructor.
2382 (tui_wrefresh): New function.
2383 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
2384 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
2385 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
2386 method.
2387 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
2388 tui_wrefresh.
2389 (tui_data_window::no_refresh): New method.
2390 (tui_data_item_window::refresh_window): Call tui_wrefresh.
2391 (tui_reg_command): Use tui_suppress_output
2392 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
2393 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
2394 method.
2395 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
2396
2397 2020-01-19 Tom Tromey <tom@tromey.com>
2398
2399 * tui/tui-winsource.c (tui_update_source_windows_with_line):
2400 Handle case where symtab is null.
2401
2402 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
2403
2404 * linux-fork.c (one_fork_p): Simplify.
2405
2406 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
2407
2408 * top.c (struct qt_args): Remove.
2409 (kill_or_detach): Change return type to void, replace `void *`
2410 parameter with a proper one.
2411 (print_inferior_quit_action): Likewise.
2412 (quit_confirm): Use range-based for loop to iterate over inferiors.
2413 (quit_force): Likewise.
2414
2415 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
2416
2417 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
2418 `void *` parameter with proper parameters.
2419 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
2420 (print_one_inferior): Change return type to void, replace `void *`
2421 parameter with proper parameters.
2422 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
2423 inferiors.
2424 (get_other_inferior): Remove.
2425 (mi_cmd_remove_inferior): Use range-based loop to iterate over
2426 inferiors.
2427
2428 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
2429
2430 * mi/mi-interp.c (report_initial_inferior): Remove.
2431 (mi_interp::init): Use range-based for to iterate over inferiors.
2432
2433 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
2434
2435 * python/py-inferior.c (build_inferior_list): Remove.
2436 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
2437
2438 2020-01-16 Christian Biesinger <cbiesinger@google.com>
2439
2440 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
2441 (btrace_stitch_trace): Likewise.
2442 * charset.c (intermediate_encoding): Likewise (vaild).
2443 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
2444 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
2445 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
2446
2447 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
2448
2449 * windows-tdep.c (windows_get_tlb_type):
2450 Add rtl_user_process_parameters type.
2451
2452 2020-01-16 Pedro Alves <palves@redhat.com>
2453 Norbert Lange <nolange79@gmail.com>
2454
2455 PR build/24805
2456 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
2457 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
2458 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
2459 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
2460 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
2461 (ps_plog): Redeclare exported functions with default visibility.
2462
2463 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
2464
2465 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
2466 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
2467
2468 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
2469
2470 * infcmd.c (post_create_inferior): Use get_thread_regcache
2471 instead of get_current_regcache.
2472
2473 2020-01-14 Tom Tromey <tom@tromey.com>
2474
2475 PR symtab/12535:
2476 * python/python.c (gdbpy_decode_line): Treat empty string the same
2477 as no argument.
2478
2479 2020-01-14 Tom Tromey <tom@tromey.com>
2480
2481 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
2482
2483 2020-01-14 Tom Tromey <tom@tromey.com>
2484
2485 * nat/linux-btrace.c: Don't include <config.h>.
2486 * nat/linux-ptrace.c: Don't include <config.h>.
2487 * nat/x86-linux-dregs.c: Don't include <config.h>.
2488
2489 2020-01-14 Tom Tromey <tom@tromey.com>
2490
2491 * configure: Rebuild.
2492 * configure.ac: Move many checks to ../gdbsupport/common.m4.
2493
2494 2020-01-14 Tom Tromey <tom@tromey.com>
2495
2496 * nat/x86-linux-dregs.c: Include configh.h.
2497 * nat/linux-ptrace.c: Include configh.h.
2498 * nat/linux-btrace.c: Include configh.h.
2499 * defs.h: Include config.h, bfd.h.
2500 * configure.ac: Don't source common.host.
2501 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
2502 * configure: Rebuild.
2503 * acinclude.m4: Update path.
2504 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
2505 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
2506 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
2507 (CLIBS): Add LIBSUPPORT.
2508 (CDEPS): Likewise.
2509 (COMMON_SFILES): Remove gdbsupport files.
2510 (HFILES_NO_SRCDIR): Likewise.
2511 (stamp-version): Update path to create-version.sh.
2512 (ALLDEPFILES): Remove gdbsupport files.
2513
2514 2020-01-14 Tom Tromey <tom@tromey.com>
2515
2516 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
2517 USE_WIN32API when needed.
2518 * configure.ac (USE_WIN32API): Don't define.
2519 (WIN32LIBS): Use WIN32APILIBS.
2520 * configure: Rebuild.
2521
2522 2020-01-14 Tom Tromey <tom@tromey.com>
2523
2524 * configure: Rebuild.
2525 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
2526
2527 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
2528
2529 * skip.c (skip_function_command): Make skip w/o arguments use the
2530 name of the inlined function if pc is inside any inlined function.
2531
2532 2020-01-14 Luis Machado <luis.machado@linaro.org>
2533
2534 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
2535 * infrun.c (resume_1): Likewise.
2536 (handle_inferior_event): Remove stale comment.
2537 * linux-nat.c (linux_nat_target::resume): Update comments.
2538 (save_stop_reason): Likewise.
2539 (linux_nat_filter_event): Likewise.
2540 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
2541
2542 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
2543
2544 * elfread.c (record_minimal_symbol): Set section index to 0 for
2545 non-allocatable sections.
2546
2547
2548 2020-01-13 Ali Tamur <tamur@google.com>
2549
2550 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
2551 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
2552 to gdb::optional. Update comments.
2553 (dwo_file): Update comments.
2554 (read_attribute): Update API to take an additional out parameter,
2555 need_reprocess. This is used to mark attributes that need other
2556 attributes (e.g. str_offsets_base) for correct computation which may not
2557 have been read yet.
2558 (read_attribute_reprocess): New function declaration.
2559 (read_addr_index): Likewise.
2560 (read_dwo_str_index): Likewise.
2561 (read_stub_str_index): Likewise.
2562 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
2563 (lookup_addr_base): New function definition.
2564 (lookup_ranges_base): Likewise.
2565 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
2566 lookup_ranges_base.
2567 (init_cutu_and_read_dies): Update comments.
2568 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
2569 unit. This is used to inherit parent's str_offsets_base and addr_base.
2570 Update comments.
2571 (init_cutu_and_read_dies_simple): Reflect API changes.
2572 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
2573 (create_cus_hash_table): Change API to take parent compile unit.
2574 Reflect API changes.
2575 (open_and_init_dwo_file): Reflect API changes.
2576 (dwarf2_get_pc_bounds): Update comments.
2577 (dwarf2_record_block_ranges): Likewise.
2578 (read_full_die_1): Change implementation to reprocess attributes that
2579 need str_offsets_base and addr_base.
2580 (partial_die_info::read): Likewise.
2581 (read_attribute_reprocess): New function definition.
2582 (read_attribute_value): Change API to take an additional out parameter,
2583 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
2584 when a non-dwo compile unit has index based attributes.
2585 (read_attribute): Reflect API changes.
2586 (read_addr_index_1): Reflect API changes. Update comments.
2587 (dwarf2_read_addr_index_data): Reflect API changes.
2588 (dwarf2_read_addr_index): Likewise.
2589 (read_str_index): Change API and implementation. This becomes a helper
2590 to be used by the new string index related methods. Update error
2591 message and comments.
2592 (read_dwo_str_index): New function definition.
2593 (read_stub_str_index): Likewise.
2594 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
2595 * symfile.h (dwarf2_debug_sections): Likewise.
2596 * xcoffread.c (dwarf2_debug_sections): Likewise.
2597
2598 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2599
2600 * gdbcore.h (struct core_fns) <core_read_registers>: Change
2601 core_reg_sect type to gdb_byte *.
2602 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
2603 * cris-tdep.c (fetch_core_registers): Likewise.
2604 * corelow.c (core_target::get_core_register_section): Change
2605 type of `contents` to gdb::byte_vector.
2606
2607 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
2608
2609 * tui/tui-wingeneral.c (box_win): Position the title in the center
2610 of the border.
2611
2612 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
2613
2614 * corelow.c (core_target::get_core_register_section): Use
2615 std::vector instead of alloca.
2616
2617 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2618
2619 * warning.m4: Add -Wmissing-declarations to build_warnings.
2620 * configure: Re-generate.
2621
2622 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2623
2624 * python/python.c (init__gdb_module): Add declaration.
2625
2626 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
2627
2628 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
2629 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
2630 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
2631 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
2632 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
2633 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
2634 * ada-exp.y (_initialize_ada_exp): Add declaration.
2635 * ada-lang.c (_initialize_ada_language): Add declaration.
2636 * ada-tasks.c (_initialize_tasks): Add declaration.
2637 * agent.c (_initialize_agent): Add declaration.
2638 * aix-thread.c (_initialize_aix_thread): Add declaration.
2639 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
2640 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
2641 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
2642 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
2643 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
2644 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
2645 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
2646 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
2647 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
2648 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
2649 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
2650 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
2651 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
2652 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
2653 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
2654 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
2655 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
2656 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
2657 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
2658 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
2659 * annotate.c (_initialize_annotate): Add declaration.
2660 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
2661 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
2662 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
2663 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
2664 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
2665 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
2666 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
2667 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
2668 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
2669 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
2670 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
2671 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
2672 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
2673 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
2674 * auto-load.c (_initialize_auto_load): Add declaration.
2675 * auxv.c (_initialize_auxv): Add declaration.
2676 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
2677 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
2678 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
2679 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
2680 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
2681 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
2682 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
2683 * breakpoint.c (_initialize_breakpoint): Add declaration.
2684 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
2685 * btrace.c (_initialize_btrace): Add declaration.
2686 * charset.c (_initialize_charset): Add declaration.
2687 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
2688 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
2689 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
2690 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
2691 * cli/cli-script.c (_initialize_cli_script): Add declaration.
2692 * cli/cli-style.c (_initialize_cli_style): Add declaration.
2693 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
2694 * coffread.c (_initialize_coffread): Add declaration.
2695 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
2696 * compile/compile.c (_initialize_compile): Add declaration.
2697 * complaints.c (_initialize_complaints): Add declaration.
2698 * completer.c (_initialize_completer): Add declaration.
2699 * copying.c (_initialize_copying): Add declaration.
2700 * corefile.c (_initialize_core): Add declaration.
2701 * corelow.c (_initialize_corelow): Add declaration.
2702 * cp-abi.c (_initialize_cp_abi): Add declaration.
2703 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
2704 * cp-support.c (_initialize_cp_support): Add declaration.
2705 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
2706 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
2707 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
2708 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
2709 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
2710 * ctfread.c (_initialize_ctfread): Add declaration.
2711 * d-lang.c (_initialize_d_language): Add declaration.
2712 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
2713 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
2714 * dbxread.c (_initialize_dbxread): Add declaration.
2715 * dcache.c (_initialize_dcache): Add declaration.
2716 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
2717 * disasm.c (_initialize_disasm): Add declaration.
2718 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
2719 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
2720 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
2721 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
2722 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
2723 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
2724 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
2725 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
2726 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
2727 * elfread.c (_initialize_elfread): Add declaration.
2728 * exec.c (_initialize_exec): Add declaration.
2729 * extension.c (_initialize_extension): Add declaration.
2730 * f-lang.c (_initialize_f_language): Add declaration.
2731 * f-valprint.c (_initialize_f_valprint): Add declaration.
2732 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
2733 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
2734 * filesystem.c (_initialize_filesystem): Add declaration.
2735 * findcmd.c (_initialize_mem_search): Add declaration.
2736 * findvar.c (_initialize_findvar): Add declaration.
2737 * fork-child.c (_initialize_fork_child): Add declaration.
2738 * frame-base.c (_initialize_frame_base): Add declaration.
2739 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
2740 * frame.c (_initialize_frame): Add declaration.
2741 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
2742 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
2743 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
2744 * gcore.c (_initialize_gcore): Add declaration.
2745 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
2746 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
2747 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
2748 * gdbarch.c (_initialize_gdbarch): Add declaration.
2749 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
2750 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
2751 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
2752 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
2753 * go-lang.c (_initialize_go_language): Add declaration.
2754 * go32-nat.c (_initialize_go32_nat): Add declaration.
2755 * guile/guile.c (_initialize_guile): Add declaration.
2756 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
2757 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
2758 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
2759 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
2760 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
2761 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
2762 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
2763 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
2764 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
2765 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
2766 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
2767 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
2768 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
2769 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
2770 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
2771 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
2772 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
2773 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
2774 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
2775 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
2776 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
2777 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
2778 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
2779 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
2780 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
2781 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
2782 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
2783 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
2784 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
2785 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
2786 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
2787 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
2788 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
2789 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
2790 * infcall.c (_initialize_infcall): Add declaration.
2791 * infcmd.c (_initialize_infcmd): Add declaration.
2792 * inflow.c (_initialize_inflow): Add declaration.
2793 * infrun.c (_initialize_infrun): Add declaration.
2794 * interps.c (_initialize_interpreter): Add declaration.
2795 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
2796 * jit.c (_initialize_jit): Add declaration.
2797 * language.c (_initialize_language): Add declaration.
2798 * linux-fork.c (_initialize_linux_fork): Add declaration.
2799 * linux-nat.c (_initialize_linux_nat): Add declaration.
2800 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
2801 * linux-thread-db.c (_initialize_thread_db): Add declaration.
2802 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
2803 * m2-lang.c (_initialize_m2_language): Add declaration.
2804 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
2805 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
2806 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
2807 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
2808 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
2809 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
2810 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
2811 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
2812 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
2813 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
2814 * machoread.c (_initialize_machoread): Add declaration.
2815 * macrocmd.c (_initialize_macrocmd): Add declaration.
2816 * macroscope.c (_initialize_macroscope): Add declaration.
2817 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
2818 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
2819 * maint.c (_initialize_maint_cmds): Add declaration.
2820 * mdebugread.c (_initialize_mdebugread): Add declaration.
2821 * memattr.c (_initialize_mem): Add declaration.
2822 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
2823 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
2824 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
2825 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
2826 * mi/mi-main.c (_initialize_mi_main): Add declaration.
2827 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
2828 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
2829 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
2830 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
2831 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
2832 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
2833 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
2834 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
2835 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
2836 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
2837 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
2838 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
2839 * mipsread.c (_initialize_mipsread): Add declaration.
2840 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
2841 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
2842 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
2843 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
2844 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
2845 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
2846 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
2847 * nto-procfs.c (_initialize_procfs): Add declaration.
2848 * objc-lang.c (_initialize_objc_language): Add declaration.
2849 * observable.c (_initialize_observer): Add declaration.
2850 * opencl-lang.c (_initialize_opencl_language): Add declaration.
2851 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
2852 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
2853 * osabi.c (_initialize_gdb_osabi): Add declaration.
2854 * osdata.c (_initialize_osdata): Add declaration.
2855 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
2856 * parse.c (_initialize_parse): Add declaration.
2857 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
2858 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
2859 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
2860 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
2861 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
2862 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
2863 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
2864 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
2865 * printcmd.c (_initialize_printcmd): Add declaration.
2866 * probe.c (_initialize_probe): Add declaration.
2867 * proc-api.c (_initialize_proc_api): Add declaration.
2868 * proc-events.c (_initialize_proc_events): Add declaration.
2869 * proc-service.c (_initialize_proc_service): Add declaration.
2870 * procfs.c (_initialize_procfs): Add declaration.
2871 * producer.c (_initialize_producer): Add declaration.
2872 * psymtab.c (_initialize_psymtab): Add declaration.
2873 * python/python.c (_initialize_python): Add declaration.
2874 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
2875 * record-btrace.c (_initialize_record_btrace): Add declaration.
2876 * record-full.c (_initialize_record_full): Add declaration.
2877 * record.c (_initialize_record): Add declaration.
2878 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
2879 * regcache.c (_initialize_regcache): Add declaration.
2880 * reggroups.c (_initialize_reggroup): Add declaration.
2881 * remote-notif.c (_initialize_notif): Add declaration.
2882 * remote-sim.c (_initialize_remote_sim): Add declaration.
2883 * remote.c (_initialize_remote): Add declaration.
2884 * reverse.c (_initialize_reverse): Add declaration.
2885 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
2886 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
2887 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
2888 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
2889 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
2890 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
2891 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
2892 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
2893 Add declaration.
2894 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
2895 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
2896 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
2897 * rust-exp.y (_initialize_rust_exp): Add declaration.
2898 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
2899 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
2900 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
2901 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
2902 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
2903 * score-tdep.c (_initialize_score_tdep): Add declaration.
2904 * ser-go32.c (_initialize_ser_dos): Add declaration.
2905 * ser-mingw.c (_initialize_ser_windows): Add declaration.
2906 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
2907 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
2908 * ser-uds.c (_initialize_ser_socket): Add declaration.
2909 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
2910 * serial.c (_initialize_serial): Add declaration.
2911 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
2912 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
2913 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
2914 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
2915 * skip.c (_initialize_step_skip): Add declaration.
2916 * sol-thread.c (_initialize_sol_thread): Add declaration.
2917 * solib-aix.c (_initialize_solib_aix): Add declaration.
2918 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
2919 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
2920 * solib-frv.c (_initialize_frv_solib): Add declaration.
2921 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
2922 * solib-target.c (_initialize_solib_target): Add declaration.
2923 * solib.c (_initialize_solib): Add declaration.
2924 * source-cache.c (_initialize_source_cache): Add declaration.
2925 * source.c (_initialize_source): Add declaration.
2926 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
2927 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
2928 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
2929 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
2930 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
2931 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
2932 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
2933 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
2934 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
2935 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
2936 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
2937 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
2938 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
2939 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
2940 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
2941 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
2942 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
2943 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
2944 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
2945 * stabsread.c (_initialize_stabsread): Add declaration.
2946 * stack.c (_initialize_stack): Add declaration.
2947 * stap-probe.c (_initialize_stap_probe): Add declaration.
2948 * std-regs.c (_initialize_frame_reg): Add declaration.
2949 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
2950 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
2951 * symfile.c (_initialize_symfile): Add declaration.
2952 * symmisc.c (_initialize_symmisc): Add declaration.
2953 * symtab.c (_initialize_symtab): Add declaration.
2954 * target.c (_initialize_target): Add declaration.
2955 * target-connection.c (_initialize_target_connection): Add
2956 declaration.
2957 * target-dcache.c (_initialize_target_dcache): Add declaration.
2958 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
2959 * thread.c (_initialize_thread): Add declaration.
2960 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
2961 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
2962 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
2963 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
2964 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
2965 * tracectf.c (_initialize_ctf): Add declaration.
2966 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
2967 * tracefile.c (_initialize_tracefile): Add declaration.
2968 * tracepoint.c (_initialize_tracepoint): Add declaration.
2969 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
2970 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
2971 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
2972 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
2973 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
2974 * tui/tui-win.c (_initialize_tui_win): Add declaration.
2975 * tui/tui.c (_initialize_tui): Add declaration.
2976 * typeprint.c (_initialize_typeprint): Add declaration.
2977 * ui-style.c (_initialize_ui_style): Add declaration.
2978 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
2979 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
2980 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
2981 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
2982 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
2983 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
2984 * unittests/filtered_iterator-selftests.c
2985 (_initialize_filtered_iterator_selftests): Add declaration.
2986 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
2987 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
2988 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
2989 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
2990 * unittests/main-thread-selftests.c
2991 (_initialize_main_thread_selftests): Add declaration.
2992 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
2993 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
2994 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
2995 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
2996 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
2997 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
2998 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
2999 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
3000 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
3001 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
3002 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
3003 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
3004 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
3005 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
3006 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
3007 declaration.
3008 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
3009 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
3010 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
3011 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
3012 * user-regs.c (_initialize_user_regs): Add declaration.
3013 * utils.c (_initialize_utils): Add declaration.
3014 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
3015 * valops.c (_initialize_valops): Add declaration.
3016 * valprint.c (_initialize_valprint): Add declaration.
3017 * value.c (_initialize_values): Add declaration.
3018 * varobj.c (_initialize_varobj): Add declaration.
3019 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
3020 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
3021 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
3022 * windows-nat.c (_initialize_windows_nat): Add declaration.
3023 (_initialize_check_for_gdb_ini): Add declaration.
3024 (_initialize_loadable): Add declaration.
3025 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
3026 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
3027 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
3028 * xcoffread.c (_initialize_xcoffread): Add declaration.
3029 * xml-support.c (_initialize_xml_support): Add declaration.
3030 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
3031 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
3032 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
3033 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
3034
3035 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
3036
3037 * regformats/regdat.sh: Generate declaration for init function.
3038
3039 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
3040
3041 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
3042 up.
3043 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
3044 close_one_inferior>: New methods.
3045 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
3046 pass down target to find_inferior_pid.
3047 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
3048 Pass down target to find_inferior_ptid.
3049 (gdbsim_target::create_inferior): Pass down target to
3050 add_thread_silent.
3051 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
3052 target down to find_inferior_ptid and switch_to_thread.
3053 (gdbsim_target::close): Update to call close_one_inferior.
3054 (struct resume_data): Remove.
3055 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
3056 directly, rather than through a void pointer.
3057 (gdbsim_target::resume): Update to call resume_one_inferior.
3058
3059 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
3060
3061 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
3062
3063 2020-01-12 Pedro Alves <palves@redhat.com>
3064
3065 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
3066 directly for the current inferior instead of
3067 discard_all_inferiors.
3068 (discard_all_inferiors): Delete.
3069
3070 2020-01-11 Tom Tromey <tom@tromey.com>
3071
3072 * tui/tui-wingeneral.c (box_win): Check cli_styling.
3073 * tui/tui-winsource.c (tui_source_window_base::refill): Use
3074 deprecated_safe_get_selected_frame.
3075
3076 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3077
3078 * inferior.c (print_inferior): Switch inferior before printing it.
3079
3080 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
3081 Pedro Alves <palves@redhat.com>
3082
3083 * progspace-and-thread.c (switch_to_program_space_and_thread):
3084 Assert there's an inferior for PSPACE. Use
3085 switch_to_inferior_no_thread to switch the inferior too.
3086 * progspace.c (program_space::~program_space): Call
3087 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
3088 (program_space::free_all_objfiles): Don't call clear_symtab_users
3089 here.
3090 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
3091
3092 2020-01-10 Pedro Alves <palves@redhat.com>
3093
3094 * NEWS: Mention multi-target debugging, "info connections", and
3095 "add-inferior -no-connection".
3096
3097 2020-01-10 Pedro Alves <palves@redhat.com>
3098
3099 * infrun.c: Include "target-connection.h".
3100 (check_multi_target_resumption): New.
3101 (proceed): Call it.
3102 * target-connection.c (make_target_connection_string): Make
3103 extern.
3104 * target-connection.h (make_target_connection_string): Declare.
3105
3106 2020-01-10 Pedro Alves <palves@redhat.com>
3107
3108 * Makefile.in (COMMON_SFILES): Add target-connection.c.
3109 * inferior.c (uiout_field_connection): New function.
3110 (print_inferior): Add new "connection-id" column.
3111 (add_inferior_command): Show connection number/string of added
3112 inferior.
3113 * process-stratum-target.h
3114 (process_stratum_target::connection_string): New virtual method.
3115 (process_stratum_target::connection_number): New field.
3116 * remote.c (remote_target::connection_string): New override.
3117 * target-connection.c: New file.
3118 * target-connection.h: New file.
3119 * target.c (decref_target): Remove process_stratum targets from
3120 the connection list.
3121 (target_stack::push): Add process_stratum targets to the
3122 connection list.
3123
3124 2020-01-10 Pedro Alves <palves@redhat.com>
3125
3126 Revert:
3127 2016-04-12 Pedro Alves <palves@redhat.com>
3128 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
3129 Remove references to name.
3130 * serial.h (struct serial) <name>: Delete.
3131
3132 2020-01-10 Pedro Alves <palves@redhat.com>
3133
3134 * gdbarch-selftests.c (register_to_value_test): Remove "target
3135 already pushed" check.
3136
3137 2020-01-10 Pedro Alves <palves@redhat.com>
3138 John Baldwin <jhb@FreeBSD.org>
3139
3140 * aarch64-linux-nat.c
3141 (aarch64_linux_nat_target::thread_architecture): Adjust.
3142 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
3143 (task_command_1): Likewise.
3144 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
3145 (aix_thread_target::wait, aix_thread_target::fetch_registers)
3146 (aix_thread_target::store_registers)
3147 (aix_thread_target::thread_alive): Adjust.
3148 * amd64-fbsd-tdep.c: Include "inferior.h".
3149 (amd64fbsd_get_thread_local_address): Pass down target.
3150 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
3151 thread's gdbarch instead of target_gdbarch.
3152 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
3153 get_last_target_status.
3154 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
3155 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
3156 inferiors.
3157 (update_inserted_breakpoint_locations): Skip if inferiors with no
3158 execution.
3159 (update_global_location_list): When handling moribund locations,
3160 find representative inferior for location's pspace, and use thread
3161 count of its process_stratum target.
3162 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
3163 * bsd-uthread.c (bsd_uthread_target::wait): Use
3164 as_process_stratum_target and adjust thread_change_ptid and
3165 add_thread calls.
3166 (bsd_uthread_target::update_thread_list): Use
3167 as_process_stratum_target and adjust find_thread_ptid,
3168 thread_change_ptid and add_thread calls.
3169 * btrace.c (maint_btrace_packet_history_cmd): Adjust
3170 find_thread_ptid call.
3171 * corelow.c (add_to_thread_list): Adjust add_thread call.
3172 (core_target_open): Adjust add_thread_silent and thread_count
3173 calls.
3174 (core_target::pid_to_str): Adjust find_inferior_ptid call.
3175 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
3176 * event-top.c (async_disconnect): Pop targets from all inferiors.
3177 * exec.c (add_target_sections): Push exec target on all inferiors
3178 sharing the program space.
3179 (remove_target_sections): Remove the exec target from all
3180 inferiors sharing the program space.
3181 (exec_on_vfork): New.
3182 * exec.h (exec_on_vfork): Declare.
3183 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
3184 Pass it down.
3185 (fbsd_nat_target::update_thread_list): Adjust.
3186 (fbsd_nat_target::resume): Adjust.
3187 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
3188 down.
3189 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
3190 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
3191 get_thread_arch_regcache call.
3192 * fork-child.c (gdb_startup_inferior): Pass target down to
3193 startup_inferior and set_executing.
3194 * gdbthread.h (struct process_stratum_target): Forward declare.
3195 (add_thread, add_thread_silent, add_thread_with_info)
3196 (in_thread_list): Add process_stratum_target parameter.
3197 (find_thread_ptid(inferior*, ptid_t)): New overload.
3198 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
3199 parameter.
3200 (all_threads()): Delete overload.
3201 (all_threads, all_non_exited_threads): Add process_stratum_target
3202 parameter.
3203 (all_threads_safe): Use brace initialization.
3204 (thread_count): Add process_stratum_target parameter.
3205 (set_resumed, set_running, set_stop_requested, set_executing)
3206 (threads_are_executing, finish_thread_state): Add
3207 process_stratum_target parameter.
3208 (switch_to_thread): Use is_current_thread.
3209 * i386-fbsd-tdep.c: Include "inferior.h".
3210 (i386fbsd_get_thread_local_address): Pass down target.
3211 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
3212 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
3213 have_inferiors check.
3214 * inf-ptrace.c (inf_ptrace_target::create_inferior)
3215 (inf_ptrace_target::attach): Adjust.
3216 * infcall.c (run_inferior_call): Adjust.
3217 * infcmd.c (run_command_1): Pass target to
3218 scoped_finish_thread_state.
3219 (proceed_thread_callback): Skip inferiors with no execution.
3220 (continue_command): Rename 'all_threads' local to avoid hiding
3221 'all_threads' function. Adjust get_last_target_status call.
3222 (prepare_one_step): Adjust set_running call.
3223 (signal_command): Use user_visible_resume_target. Compare thread
3224 pointers instead of inferior_ptid.
3225 (info_program_command): Adjust to pass down target.
3226 (attach_command): Mark target's 'thread_executing' flag.
3227 (stop_current_target_threads_ns): New, factored out from ...
3228 (interrupt_target_1): ... this. Switch inferior before making
3229 target calls.
3230 * inferior-iter.h
3231 (struct all_inferiors_iterator, struct all_inferiors_range)
3232 (struct all_inferiors_safe_range)
3233 (struct all_non_exited_inferiors_range): Filter on
3234 process_stratum_target too. Remove explicit.
3235 * inferior.c (inferior::inferior): Push dummy target on target
3236 stack.
3237 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
3238 Add process_stratum_target parameter, and pass it down.
3239 (have_live_inferiors): Adjust.
3240 (switch_to_inferior_and_push_target): New.
3241 (add_inferior_command, clone_inferior_command): Handle
3242 "-no-connection" parameter. Use
3243 switch_to_inferior_and_push_target.
3244 (_initialize_inferior): Mention "-no-connection" option in
3245 the help of "add-inferior" and "clone-inferior" commands.
3246 * inferior.h: Include "process-stratum-target.h".
3247 (interrupt_target_1): Use bool.
3248 (struct inferior) <push_target, unpush_target, target_is_pushed,
3249 find_target_beneath, top_target, process_target, target_at,
3250 m_stack>: New.
3251 (discard_all_inferiors): Delete.
3252 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
3253 (all_inferiors, all_non_exited_inferiors): Add
3254 process_stratum_target parameter.
3255 * infrun.c: Include "gdb_select.h" and <unordered_map>.
3256 (target_last_proc_target): New global.
3257 (follow_fork_inferior): Push target on new inferior. Pass target
3258 to add_thread_silent. Call exec_on_vfork. Handle target's
3259 reference count.
3260 (follow_fork): Adjust get_last_target_status call. Also consider
3261 target.
3262 (follow_exec): Push target on new inferior.
3263 (struct execution_control_state) <target>: New field.
3264 (user_visible_resume_target): New.
3265 (do_target_resume): Call target_async.
3266 (resume_1): Set target's threads_executing flag. Consider resume
3267 target.
3268 (commit_resume_all_targets): New.
3269 (proceed): Also consider resume target. Skip threads of inferiors
3270 with no execution. Commit resumtion in all targets.
3271 (start_remote): Pass current inferior to wait_for_inferior.
3272 (infrun_thread_stop_requested): Consider target as well. Pass
3273 thread_info pointer to clear_inline_frame_state instead of ptid.
3274 (infrun_thread_thread_exit): Consider target as well.
3275 (random_pending_event_thread): New inferior parameter. Use it.
3276 (do_target_wait): Rename to ...
3277 (do_target_wait_1): ... this. Add inferior parameter, and pass it
3278 down.
3279 (threads_are_resumed_pending_p, do_target_wait): New.
3280 (prepare_for_detach): Adjust calls.
3281 (wait_for_inferior): New inferior parameter. Handle it. Use
3282 do_target_wait_1 instead of do_target_wait.
3283 (fetch_inferior_event): Adjust. Switch to representative
3284 inferior. Pass target down.
3285 (set_last_target_status): Add process_stratum_target parameter.
3286 Save target in global.
3287 (get_last_target_status): Add process_stratum_target parameter and
3288 handle it.
3289 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
3290 (context_switch): Check inferior_ptid == null_ptid before calling
3291 inferior_thread().
3292 (get_inferior_stop_soon): Pass down target.
3293 (wait_one): Rename to ...
3294 (poll_one_curr_target): ... this.
3295 (struct wait_one_event): New.
3296 (wait_one): New.
3297 (stop_all_threads): Adjust.
3298 (handle_no_resumed, handle_inferior_event): Adjust to consider the
3299 event's target.
3300 (switch_back_to_stepped_thread): Also consider target.
3301 (print_stop_event): Update.
3302 (normal_stop): Update. Also consider the resume target.
3303 * infrun.h (wait_for_inferior): Remove declaration.
3304 (user_visible_resume_target): New declaration.
3305 (get_last_target_status, set_last_target_status): New
3306 process_stratum_target parameter.
3307 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
3308 process_stratum_target parameter, and use it.
3309 (clear_inline_frame_state (thread_info*)): New.
3310 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
3311 process_stratum_target parameter.
3312 (clear_inline_frame_state (thread_info*)): Declare.
3313 * linux-fork.c (delete_checkpoint_command): Pass target down to
3314 find_thread_ptid.
3315 (checkpoint_command): Adjust.
3316 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
3317 instead of just tweaking inferior_ptid.
3318 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
3319 (exit_lwp): Pass target down to find_thread_ptid.
3320 (attach_proc_task_lwp_callback): Pass target down to
3321 add_thread/set_running/set_executing.
3322 (linux_nat_target::attach): Pass target down to
3323 thread_change_ptid.
3324 (get_detach_signal): Pass target down to find_thread_ptid.
3325 Consider last target status's target.
3326 (linux_resume_one_lwp_throw, resume_lwp)
3327 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
3328 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
3329 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
3330 (linux_nat_target::async_wait_fd): New.
3331 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
3332 target down.
3333 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
3334 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
3335 * linux-thread-db.c (struct thread_db_info::process_target): New
3336 field.
3337 (add_thread_db_info): Save target.
3338 (get_thread_db_info): New process_stratum_target parameter. Also
3339 match target.
3340 (delete_thread_db_info): New process_stratum_target parameter.
3341 Also match target.
3342 (thread_from_lwp): Adjust to pass down target.
3343 (thread_db_notice_clone): Pass down target.
3344 (check_thread_db_callback): Pass down target.
3345 (try_thread_db_load_1): Always push the thread_db target.
3346 (try_thread_db_load, record_thread): Pass target down.
3347 (thread_db_target::detach): Pass target down. Always unpush the
3348 thread_db target.
3349 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
3350 target down. Always unpush the thread_db target.
3351 (find_new_threads_callback, thread_db_find_new_threads_2)
3352 (thread_db_target::update_thread_list): Pass target down.
3353 (thread_db_target::pid_to_str): Pass current inferior down.
3354 (thread_db_target::get_thread_local_address): Pass target down.
3355 (thread_db_target::resume, maintenance_check_libthread_db): Pass
3356 target down.
3357 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
3358 * procfs.c (procfs_target::procfs_init_inferior): Declare.
3359 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
3360 (procfs_init_inferior): Rename to ...
3361 (procfs_target::procfs_init_inferior): ... this and adjust.
3362 (procfs_target::create_inferior, procfs_notice_thread)
3363 (procfs_do_thread_registers): Adjust.
3364 * ppc-fbsd-tdep.c: Include "inferior.h".
3365 (ppcfbsd_get_thread_local_address): Pass down target.
3366 * proc-service.c (ps_xfer_memory): Switch current inferior and
3367 program space as well.
3368 (get_ps_regcache): Pass target down.
3369 * process-stratum-target.c
3370 (process_stratum_target::thread_address_space)
3371 (process_stratum_target::thread_architecture): Pass target down.
3372 * process-stratum-target.h
3373 (process_stratum_target::threads_executing): New field.
3374 (as_process_stratum_target): New.
3375 * ravenscar-thread.c
3376 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
3377 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
3378 down.
3379 * record-btrace.c (record_btrace_target::info_record): Adjust.
3380 (record_btrace_target::record_method)
3381 (record_btrace_target::record_is_replaying)
3382 (record_btrace_target::fetch_registers)
3383 (get_thread_current_frame_id, record_btrace_target::resume)
3384 (record_btrace_target::wait, record_btrace_target::stop): Pass
3385 target down.
3386 * record-full.c (record_full_wait_1): Switch to event thread.
3387 Pass target down.
3388 * regcache.c (regcache::regcache)
3389 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
3390 process_stratum_target parameter and handle it.
3391 (current_thread_target): New global.
3392 (get_thread_regcache): Add process_stratum_target parameter and
3393 handle it. Switch inferior before calling target method.
3394 (get_thread_regcache): Pass target down.
3395 (get_thread_regcache_for_ptid): Pass target down.
3396 (registers_changed_ptid): Add process_stratum_target parameter and
3397 handle it.
3398 (registers_changed_thread, registers_changed): Pass target down.
3399 (test_get_thread_arch_aspace_regcache): New.
3400 (current_regcache_test): Define a couple local test_target_ops
3401 instances and use them for testing.
3402 (readwrite_regcache): Pass process_stratum_target parameter.
3403 (cooked_read_test, cooked_write_test): Pass mock_target down.
3404 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
3405 (get_thread_arch_aspace_regcache): Add process_stratum_target
3406 parameter.
3407 (regcache::target): New method.
3408 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
3409 (regcache::registers_changed_ptid): Add process_stratum_target
3410 parameter.
3411 (regcache::m_target): New field.
3412 (registers_changed_ptid): Add process_stratum_target parameter.
3413 * remote.c (remote_state::supports_vCont_probed): New field.
3414 (remote_target::async_wait_fd): New method.
3415 (remote_unpush_and_throw): Add remote_target parameter.
3416 (get_current_remote_target): Adjust.
3417 (remote_target::remote_add_inferior): Push target.
3418 (remote_target::remote_add_thread)
3419 (remote_target::remote_notice_new_inferior)
3420 (get_remote_thread_info): Pass target down.
3421 (remote_target::update_thread_list): Skip threads of inferiors
3422 bound to other targets. (remote_target::close): Don't discard
3423 inferiors. (remote_target::add_current_inferior_and_thread)
3424 (remote_target::process_initial_stop_replies)
3425 (remote_target::start_remote)
3426 (remote_target::remote_serial_quit_handler): Pass down target.
3427 (remote_target::remote_unpush_target): New remote_target
3428 parameter. Unpush the target from all inferiors.
3429 (remote_target::remote_unpush_and_throw): New remote_target
3430 parameter. Pass it down.
3431 (remote_target::open_1): Check whether the current inferior has
3432 execution instead of checking whether any inferior is live. Pass
3433 target down.
3434 (remote_target::remote_detach_1): Pass down target. Use
3435 remote_unpush_target.
3436 (extended_remote_target::attach): Pass down target.
3437 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
3438 (remote_target::append_resumption): Pass down target.
3439 (remote_target::append_pending_thread_resumptions)
3440 (remote_target::remote_resume_with_hc, remote_target::resume)
3441 (remote_target::commit_resume): Pass down target.
3442 (remote_target::remote_stop_ns): Check supports_vCont_probed.
3443 (remote_target::interrupt_query)
3444 (remote_target::remove_new_fork_children)
3445 (remote_target::check_pending_events_prevent_wildcard_vcont)
3446 (remote_target::remote_parse_stop_reply)
3447 (remote_target::process_stop_reply): Pass down target.
3448 (first_remote_resumed_thread): New remote_target parameter. Pass
3449 it down.
3450 (remote_target::wait_as): Pass down target.
3451 (unpush_and_perror): New remote_target parameter. Pass it down.
3452 (remote_target::readchar, remote_target::remote_serial_write)
3453 (remote_target::getpkt_or_notif_sane_1)
3454 (remote_target::kill_new_fork_children, remote_target::kill): Pass
3455 down target.
3456 (remote_target::mourn_inferior): Pass down target. Use
3457 remote_unpush_target.
3458 (remote_target::core_of_thread)
3459 (remote_target::remote_btrace_maybe_reopen): Pass down target.
3460 (remote_target::pid_to_exec_file)
3461 (remote_target::thread_handle_to_thread_info): Pass down target.
3462 (remote_target::async_wait_fd): New.
3463 * riscv-fbsd-tdep.c: Include "inferior.h".
3464 (riscv_fbsd_get_thread_local_address): Pass down target.
3465 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
3466 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
3467 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
3468 Adjust.
3469 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
3470 * solib-svr4.c (enable_break): Pass down target.
3471 * spu-multiarch.c (parse_spufs_run): Pass down target.
3472 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
3473 * target-delegates.c: Regenerate.
3474 * target.c (g_target_stack): Delete.
3475 (current_top_target): Return the current inferior's top target.
3476 (target_has_execution_1): Refer to the passed-in inferior's top
3477 target.
3478 (target_supports_terminal_ours): Check whether the initial
3479 inferior was already created.
3480 (decref_target): New.
3481 (target_stack::push): Incref/decref the target.
3482 (push_target, push_target, unpush_target): Adjust.
3483 (target_stack::unpush): Defref target.
3484 (target_is_pushed): Return bool. Adjust to refer to the current
3485 inferior's target stack.
3486 (dispose_inferior): Delete, and inline parts ...
3487 (target_preopen): ... here. Only dispose of the current inferior.
3488 (target_detach): Hold strong target reference while detaching.
3489 Pass target down.
3490 (target_thread_name): Add assertion.
3491 (target_resume): Pass down target.
3492 (target_ops::beneath, find_target_at): Adjust to refer to the
3493 current inferior's target stack.
3494 (get_dummy_target): New.
3495 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
3496 has a thread running.
3497 (initialize_targets): Rename to ...
3498 (_initialize_target): ... this.
3499 * target.h: Include "gdbsupport/refcounted-object.h".
3500 (struct target_ops): Inherit refcounted_object.
3501 (target_ops::shortname, target_ops::longname): Make const.
3502 (target_ops::async_wait_fd): New method.
3503 (decref_target): Declare.
3504 (struct target_ops_ref_policy): New.
3505 (target_ops_ref): New typedef.
3506 (get_dummy_target): Declare function.
3507 (target_is_pushed): Return bool.
3508 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
3509 (all_matching_threads_iterator::all_matching_threads_iterator):
3510 Handle filter target.
3511 * thread-iter.h (struct all_matching_threads_iterator, struct
3512 all_matching_threads_range, class all_non_exited_threads_range):
3513 Filter by target too. Remove explicit.
3514 * thread.c (threads_executing): Delete.
3515 (inferior_thread): Pass down current inferior.
3516 (clear_thread_inferior_resources): Pass down thread pointer
3517 instead of ptid_t.
3518 (add_thread_silent, add_thread_with_info, add_thread): Add
3519 process_stratum_target parameter. Use it for thread and inferior
3520 searches.
3521 (is_current_thread): New.
3522 (thread_info::deletable): Use it.
3523 (find_thread_ptid, thread_count, in_thread_list)
3524 (thread_change_ptid, set_resumed, set_running): New
3525 process_stratum_target parameter. Pass it down.
3526 (set_executing): New process_stratum_target parameter. Pass it
3527 down. Adjust reference to 'threads_executing'.
3528 (threads_are_executing): New process_stratum_target parameter.
3529 Adjust reference to 'threads_executing'.
3530 (set_stop_requested, finish_thread_state): New
3531 process_stratum_target parameter. Pass it down.
3532 (switch_to_thread): Also match inferior.
3533 (switch_to_thread): New process_stratum_target parameter. Pass it
3534 down.
3535 (update_threads_executing): Reimplement.
3536 * top.c (quit_force): Pop targets from all inferior.
3537 (gdb_init): Don't call initialize_targets.
3538 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
3539 Declare.
3540 (windows_add_thread, windows_delete_thread): Adjust.
3541 (get_windows_debug_event): Rename to ...
3542 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
3543 * tracefile-tfile.c (tfile_target_open): Pass down target.
3544 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
3545 Forward declare.
3546 (switch_to_thread): Add process_stratum_target parameter.
3547 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
3548 parameter. Use it.
3549 (mi_on_resume): Pass target down.
3550 * nat/fork-inferior.c (startup_inferior): Add
3551 process_stratum_target parameter. Pass it down.
3552 * nat/fork-inferior.h (startup_inferior): Add
3553 process_stratum_target parameter.
3554 * python/py-threadevent.c (py_get_event_thread): Pass target down.
3555
3556 2020-01-10 Pedro Alves <palves@redhat.com>
3557
3558 * remote.c (remote_target::start_remote): Don't set inferior_ptid
3559 directly. Instead find the first thread in the thread list and
3560 use switch_to_thread.
3561
3562 2020-01-10 Pedro Alves <palves@redhat.com>
3563
3564 * remote.c (remote_target::remote_add_inferior): Don't bind a
3565 process to the current inferior if the current inferior is already
3566 bound to a process.
3567
3568 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3569 Pedro Alves <palves@redhat.com>
3570
3571 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
3572 If no process is specified, return null_ptid instead of
3573 inferior_ptid.
3574 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
3575 TARGET_WAITKIND_SIGNALLED with no pid.
3576
3577 2020-01-10 Pedro Alves <palves@redhat.com>
3578
3579 * remote.c (first_remote_resumed_thread): New.
3580 (remote_target::wait_as): Use it as default event_ptid instead of
3581 inferior_ptid.
3582
3583 2020-01-10 Pedro Alves <palves@redhat.com>
3584
3585 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
3586
3587 2020-01-10 Pedro Alves <palves@redhat.com>
3588
3589 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
3590 not -1.
3591
3592 2020-01-10 Pedro Alves <palves@redhat.com>
3593
3594 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
3595 ptid to get_last_target_status.
3596 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
3597 ptid to get_last_target_status.
3598 * infcmd.c (continue_command): Don't pass a target_waitstatus to
3599 get_last_target_status.
3600 (info_program_command): Don't pass a target_waitstatus to
3601 get_last_target_status.
3602 * infrun.c (init_wait_for_inferior): Use
3603 nullify_last_target_wait_ptid.
3604 (get_last_target_status): Handle nullptr arguments.
3605 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
3606 (print_stop_event): Don't pass a ptid to get_last_target_status.
3607 (normal_stop): Don't pass a ptid to get_last_target_status.
3608 * infrun.h (get_last_target_status, set_last_target_status): Move
3609 comments here and update.
3610 (nullify_last_target_wait_ptid): Declare.
3611 * linux-fork.c (fork_load_infrun_state): Remove local extern
3612 declaration of nullify_last_target_wait_ptid.
3613 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
3614 to get_last_target_status.
3615
3616 2020-01-10 Pedro Alves <palves@redhat.com>
3617
3618 * gdbthread.h (scoped_restore_current_thread)
3619 <dont_restore, restore, m_dont_restore>: Declare.
3620 * thread.c (thread_alive): Add assertion. Return bool.
3621 (switch_to_thread_if_alive): New.
3622 (prune_threads): Switch inferior/thread.
3623 (print_thread_info_1): Switch thread before calling target methods.
3624 (scoped_restore_current_thread::restore): New, factored out from
3625 ...
3626 (scoped_restore_current_thread::~scoped_restore_current_thread):
3627 ... this.
3628 (scoped_restore_current_thread::scoped_restore_current_thread):
3629 Add assertion.
3630 (thread_apply_all_command, thread_select): Use
3631 switch_to_thread_if_alive.
3632 * infrun.c (proceed, restart_threads, handle_signal_stop)
3633 (switch_back_to_stepped_thread): Switch current thread before
3634 calling target methods.
3635
3636 2020-01-10 Pedro Alves <palves@redhat.com>
3637
3638 * inferior.c (switch_to_inferior_no_thread): New function,
3639 factored out from ...
3640 (inferior_command): ... here.
3641 * inferior.h (switch_to_inferior_no_thread): Declare.
3642 * mi/mi-main.c (run_one_inferior): Use
3643 switch_to_inferior_no_thread.
3644
3645 2020-01-10 Pedro Alves <palves@redhat.com>
3646
3647 * infcmd.c (kill_command): Remove dead code.
3648
3649 2020-01-10 Pedro Alves <palves@redhat.com>
3650
3651 * remote.c (remote_target::mourn_inferior): No longer check
3652 whether the target is running.
3653
3654 2020-01-10 Pedro Alves <palves@redhat.com>
3655
3656 * corelow.c (core_target::has_execution): Change parameter type to
3657 inferior pointer.
3658 * inferior.c (number_of_live_inferiors): Use
3659 inferior::has_execution instead of target_has_execution_1.
3660 * inferior.h (inferior::has_execution): New.
3661 * linux-thread-db.c (thread_db_target::update_thread_list): Use
3662 inferior::has_execution instead of target_has_execution_1.
3663 * process-stratum-target.c
3664 (process_stratum_target::has_execution): Change parameter type to
3665 inferior pointer. Check the inferior's PID instead of
3666 inferior_ptid.
3667 * process-stratum-target.h
3668 (process_stratum_target::has_execution): Change parameter type to
3669 inferior pointer.
3670 * record-full.c (record_full_core_target::has_execution): Change
3671 parameter type to inferior pointer.
3672 * target.c (target_has_execution_1): Change parameter type to
3673 inferior pointer.
3674 (target_has_execution_current): Adjust.
3675 * target.h (target_ops::has_execution): Change parameter type to
3676 inferior pointer.
3677 (target_has_execution_1): Change parameter type to inferior
3678 pointer. Change return type to bool.
3679 * tracefile.h (tracefile_target::has_execution): Change parameter
3680 type to inferior pointer.
3681
3682 2020-01-10 Pedro Alves <palves@redhat.com>
3683
3684 * exceptions.c (print_flush): Remove current_top_target() check.
3685
3686 2020-01-10 Pedro Alves <palves@redhat.com>
3687
3688 * remote.c (show_remote_exec_file): Show the current inferior's
3689 exec-file instead of the command variable's value.
3690
3691 2020-01-10 Pedro Alves <palves@redhat.com>
3692
3693 * record-full.c (record_full_resume_ptid): New global.
3694 (record_full_target::resume): Set it.
3695 (record_full_wait_1): Use record_full_resume_ptid instead of
3696 inferior_ptid.
3697
3698 2020-01-10 Pedro Alves <palves@redhat.com>
3699
3700 * gdbthread.h (scoped_restore_current_thread)
3701 <dont_restore, restore, m_dont_restore>: Declare.
3702 * thread.c (thread_alive): Add assertion. Return bool.
3703 (switch_to_thread_if_alive): New.
3704 (prune_threads): Switch inferior/thread.
3705 (print_thread_info_1): Switch thread before calling target methods.
3706 (scoped_restore_current_thread::restore): New, factored out from
3707 ...
3708 (scoped_restore_current_thread::~scoped_restore_current_thread):
3709 ... this.
3710 (scoped_restore_current_thread::scoped_restore_current_thread):
3711 Add assertion.
3712 (thread_apply_all_command, thread_select): Use
3713 switch_to_thread_if_alive.
3714
3715 2020-01-10 George Barrett <bob@bob131.so>
3716
3717 * stap-probe.c (stap_modify_semaphore): Don't check for null
3718 semaphores.
3719 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
3720 for null semaphores.
3721
3722 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
3723
3724 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
3725 all source windows, and maintain horizontal scroll status while
3726 doing so.
3727
3728 2020-01-09 Tom Tromey <tom@tromey.com>
3729
3730 PR tui/18932:
3731 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
3732 update_source_window, not print_source_lines.
3733
3734 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
3735
3736 * tui/tui.c (tui_enable): Register tui hooks after calling
3737 tui_display_main.
3738
3739 2020-01-09 Christian Biesinger <cbiesinger@google.com>
3740
3741 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
3742
3743 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
3744
3745 * thread.c (print_thread_info_1): Fix indentation.
3746
3747 2020-01-09 Christian Biesinger <cbiesinger@google.com>
3748
3749 * symtab.c (general_symbol_info::compute_and_set_names): Move the
3750 unique_xmalloc_ptr outside the if to always free the demangled name.
3751
3752 2020-01-08 Tom Tromey <tromey@adacore.com>
3753
3754 * xcoffread.c (enter_line_range, read_xcoff_symtab)
3755 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
3756 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
3757 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
3758 Remove.
3759 (section_offsets): New typedef.
3760 * symtab.c (fixup_section, get_msymbol_address): Update.
3761 * symmisc.c (dump_msymbols): Update.
3762 * symfile.h (relative_addr_info_to_section_offsets)
3763 (symfile_map_offsets_to_segments): Update.
3764 * symfile.c (build_section_addr_info_from_objfile)
3765 (init_objfile_sect_indices): Update.
3766 (struct place_section_arg): Change type of "offsets".
3767 (place_section): Update.
3768 (relative_addr_info_to_section_offsets): Change type of
3769 "section_offsets". Remove "num_sections" parameter.
3770 (default_symfile_offsets, syms_from_objfile_1)
3771 (set_objfile_default_section_offset): Update.
3772 (reread_symbols): No need to preserve section offsets by hand.
3773 (symfile_map_offsets_to_segments): Change type of "offsets".
3774 * stap-probe.c (relocate_address): Update.
3775 * stabsread.h (process_one_symbol): Update.
3776 * solib-target.c (struct lm_info_target) <offsets>: Change type.
3777 (solib_target_relocate_section_addresses): Update.
3778 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
3779 Update.
3780 * solib-frv.c (frv_relocate_main_executable): Update.
3781 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
3782 * solib-aix.c (solib_aix_get_section_offsets): Change return
3783 type.
3784 (solib_aix_solib_create_inferior_hook): Update.
3785 * remote.c (remote_target::get_offsets): Update.
3786 * psymtab.c (find_pc_sect_psymtab): Update.
3787 * psympriv.h (struct partial_symbol) <address, text_low,
3788 text_high>: Update.
3789 * objfiles.h (obj_section_offset): Update.
3790 (struct objfile) <section_offsets>: Change type.
3791 <num_sections>: Remove.
3792 (objfile_relocate): Update.
3793 * objfiles.c (entry_point_address_query): Update
3794 (relocate_one_symbol): Change type of "section_offsets".
3795 (objfile_relocate1, objfile_relocate1): Change type of
3796 "new_offsets".
3797 (objfile_rebase1): Update.
3798 * mipsread.c (mipscoff_symfile_read): Update.
3799 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
3800 parameter.
3801 * mdebugread.c (parse_symbol): Change type of "section_offsets".
3802 (parse_external, psymtab_to_symtab_1): Update.
3803 * machoread.c (macho_symfile_offsets): Update.
3804 * ia64-tdep.c (ia64_find_unwind_table): Update.
3805 * hppa-tdep.c (read_unwind_info): Update.
3806 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
3807 * dwarf2read.c (create_addrmap_from_index)
3808 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
3809 (process_psymtab_comp_unit_reader, add_partial_symbol)
3810 (add_partial_subprogram, process_full_comp_unit)
3811 (read_file_scope, read_func_scope, read_lexical_block_scope)
3812 (read_call_site_scope, dwarf2_rnglists_process)
3813 (dwarf2_ranges_process, dwarf2_ranges_read)
3814 (dwarf_decode_lines_1, var_decode_location, new_symbol)
3815 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
3816 Update.
3817 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
3818 Update.
3819 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
3820 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
3821 (process_one_symbol): Change type of "section_offsets".
3822 * ctfread.c (get_objfile_text_range): Update.
3823 * coffread.c (coff_symtab_read, enter_linenos)
3824 (process_coff_symbol): Update.
3825 * coff-pe-read.c (add_pe_forwarded_sym): Update.
3826 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
3827
3828 2020-01-08 Tom Tromey <tromey@adacore.com>
3829
3830 * dwarf2read.c (parse_macro_definition): Use std::string.
3831 (parse_macro_definition): Likewise.
3832
3833 2020-01-08 Tom Tromey <tromey@adacore.com>
3834
3835 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
3836 (ATTR_ALLOC_CHUNK): Remove.
3837
3838 2020-01-08 Tom Tromey <tromey@adacore.com>
3839
3840 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
3841
3842 2020-01-08 Tom Tromey <tromey@adacore.com>
3843
3844 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
3845 (dwarf2_compute_name, open_dwo_file): Likewise.
3846 (process_enumeration_scope): Use std::vector.
3847 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
3848 (partial_die_info::fixup, dwarf2_start_subfile)
3849 (guess_full_die_structure_name, dwarf2_name): Likewise.
3850 (determine_prefix): Update.
3851 (guess_full_die_structure_name): Make return type const.
3852 (partial_die_full_name): Return unique_xmalloc_ptr.
3853 (DW_FIELD_ALLOC_CHUNK): Remove.
3854
3855 2020-01-07 Tom Tromey <tromey@adacore.com>
3856
3857 PR build/24937:
3858 * stap-probe.c (class stap_static_probe_ops): Add constructor.
3859
3860 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
3861
3862 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
3863
3864 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
3865
3866 * stack.c (print_frame_info): Move disassemble_next_line code
3867 inside source_print block.
3868
3869 2020-01-06 Eli Zaretskii <eliz@gnu.org>
3870
3871 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
3872 gdb/signals.h, as we are now using native signal symbols.
3873
3874 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
3875
3876 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
3877 overflow by an early check of content vs threshold.
3878 * tui/tui-source.c (tui_source_window::line_is_displayed):
3879 Likewise.
3880
3881 2020-01-06 Eli Zaretskii <eliz@gnu.org>
3882
3883 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
3884
3885 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
3886
3887 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
3888 export table if no section contains it's RVA.
3889
3890 2020-01-06 Eli Zaretskii <eliz@gnu.org>
3891
3892 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
3893
3894 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
3895
3896 * source.c (print_source_lines_base): Set last_line_listed.
3897
3898 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
3899
3900 * tui/tui-disasm.c: Remove trailing spaces.
3901
3902 2020-01-06 Eli Zaretskii <eliz@gnu.org>
3903 Pedro Alves <palves@redhat.com>
3904
3905 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
3906 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
3907 (windows_gdb_signal_to_target): New function, uses the above
3908 enumeration to convert GDB internal signal codes to equivalent
3909 Windows codes.
3910 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
3911 * windows-nat.c: Include "gdb_wait.h".
3912 (get_windows_debug_event): Extract the fatal exception from the
3913 exit status and convert to the equivalent Posix signal number.
3914 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
3915 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
3916 * gdbsupport/gdb_wait.c: New file, implements
3917 windows_status_to_termsig.
3918 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
3919 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
3920
3921 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
3922
3923 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
3924 show_layout.
3925
3926 2020-01-05 Luis Machado <luis.machado@linaro.org>
3927
3928 * aarch64-linux-nat.c
3929 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
3930 and bfd_mach_aarch64.
3931
3932 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3933
3934 * ui-file.c (stdio_file::can_emit_style_escape)
3935 (tee_file::can_emit_style_escape): Ensure style is used also on
3936 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
3937 to gdb_stdout.
3938 * main.c (set_gdb_data_directory): Use file style to output the
3939 warning that the given pathname is not a directory.
3940 * top.c (show_history_filename, gdb_safe_append_history)
3941 (show_gdb_datadir): Use file style.
3942
3943 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
3944
3945 * solib-target.c (struct lm_info_target):
3946 Change offsets to be a unique_xmalloc_ptr.
3947 (solib_target_relocate_section_addresses): Update.
3948
3949 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
3950
3951 * windows-nat.c (windows_clear_solib): Free so_list linked list.
3952
3953 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
3954
3955 * MAINTAINERS (Write After Approval): Add myself.
3956
3957 2020-01-02 Luis Machado <luis.machado@linaro.org>
3958
3959 * proc-service.c (get_ps_regcache): Remove reference to obsolete
3960 Cell BE architecture.
3961 * target.h (struct target_ops) <thread_architecture>: Likewise.
3962
3963 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
3964
3965 * Makefile.in: Use INSTALL_PROGRAM_ENV.
3966
3967 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
3968
3969 * MAINTAINERS (Write After Approval): Add myself.
3970
3971 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3972
3973 * gdbarch.sh: Update copyright year range of generated files.
3974
3975 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3976
3977 Update copyright year range in all GDB files.
3978
3979 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3980
3981 * copyright.py: Convert to Python 3.
3982
3983 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3984
3985 * copyright.py: Adapt after move of gnulib directory from gdb
3986 directory to toplevel directory.
3987
3988 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3989
3990 * copyright.py (main): Exit if run from the wrong directory.
3991
3992 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3993
3994 * top.c (print_gdb_version): Change copyright year to 2020.
3995
3996 2020-01-01 Joel Brobecker <brobecker@adacore.com>
3997
3998 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
3999
4000 For older changes see ChangeLog-2019.
4001 \f
4002 Local Variables:
4003 mode: change-log
4004 left-margin: 8
4005 fill-column: 74
4006 version-control: never
4007 coding: utf-8
4008 End:
This page took 0.125663 seconds and 4 git commands to generate.