Fix inline frame unwinding breakage
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-04-23 Luis Machado <luis.machado@linaro.org>
2
3 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
4 get_frame_register instead of gdbarch_unwind_pc.
5
6 2020-04-23 Tom de Vries <tdevries@suse.de>
7
8 * symtab.c (lookup_global_symbol): Prefer def over decl.
9
10 2020-04-23 Tom de Vries <tdevries@suse.de>
11
12 PR symtab/25807
13 * block.c (best_symbol, better_symbol): Promote to external.
14 * block.h (best_symbol, better_symbol): Declare.
15 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
16 decl.
17
18 2020-04-23 Tom Tromey <tromey@adacore.com>
19
20 PR ada/25837:
21 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
22 "const char *", not a "const std::string &".
23 <name_and_matcher::operator==>: Update.
24 * unittests/lookup_name_info-selftests.c: Change type of
25 "result".
26
27 2020-04-23 Tom Tromey <tom@tromey.com>
28
29 * inferior.h (iterate_over_inferiors): Don't declare.
30 * inferior.c (iterate_over_inferiors): Remove.
31 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
32 Remove.
33 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
34 use iterate_over_inferiors.
35 (darwin_resume_inferior_it)
36 (struct resume_inferior_threads_param)
37 (darwin_resume_inferior_threads_it): Remove.
38 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
39
40 2020-04-23 Tom de Vries <tdevries@suse.de>
41
42 * blockframe.c (find_pc_partial_function): Use
43 find_pc_sect_compunit_symtab rather than
44 objfile->sf->qf->find_pc_sect_compunit_symtab.
45
46 2020-04-22 Tom de Vries <tdevries@suse.de>
47
48 PR symtab/25764
49 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
50 in psymtabs.
51
52 2020-04-22 Tom de Vries <tdevries@suse.de>
53
54 PR symtab/25801
55 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
56 symtabs.
57
58 2020-04-22 Tom de Vries <tdevries@suse.de>
59
60 PR symtab/25700
61 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
62 CU if already created.
63
64 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
65
66 * infrun.c (displaced_step_fixup): Switch to the event_thread
67 before calling displaced_step_restore, not after.
68
69 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
70
71 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
72 its inferior is not recorded by us.
73 (record_btrace_target_open): Replace call to
74 all_non_exited_threads () with call to current_inferior
75 ()->non_exited_threads ().
76 (record_btrace_target::stop_recording): Likewise.
77 (record_btrace_target::close): Likewise.
78 (record_btrace_target::wait): Likewise.
79 (record_btrace_target::record_stop_replaying): Likewise.
80
81 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
82
83 * btrace.c (btrace_enable): Throw an error on double enables and
84 when enabling recording fails.
85 (btrace_disable): Throw an error if the thread is not recorded.
86
87 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
88
89 * record-btrace.c (record_btrace_target::fetch_registers): Forward
90 request if we do not have a thread_info.
91
92 2020-04-21 Tom de Vries <tdevries@suse.de>
93
94 PR gdb/25471
95 * thread.c
96 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
97 exception in get_frame_id.
98
99 2020-04-20 Tom Tromey <tromey@adacore.com>
100
101 * python/python.c (struct gdbpy_event): Mark move constructor as
102 noexcept.
103 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
104 constructor as noexcept.
105 * completer.h (struct completion_result): Mark move constructor as
106 noexcept.
107 * completer.c (completion_result::completion_result): Use
108 initialization style. Don't call reset_match_list.
109
110 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
111
112 * MAINTAINERS (Write After Approval): Add myself.
113
114 2020-04-18 Tom Tromey <tom@tromey.com>
115
116 * windows-tdep.c (init_w32_command_list)
117 (w32_prefix_command_valid): Restore.
118 (_initialize_windows_tdep): Call init_w32_command_list.
119
120 2020-04-18 Tom Tromey <tom@tromey.com>
121
122 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
123 * value.c (value_fn_field): Update.
124 * valops.c (find_function_in_inferior)
125 (value_allocate_space_in_inferior): Update.
126 * tui/tui-winsource.c (tui_update_source_windows_with_line):
127 Update.
128 * tui/tui-source.c (tui_source_window::set_contents): Update.
129 * symtab.c (lookup_global_or_static_symbol)
130 (find_function_start_sal_1, skip_prologue_sal)
131 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
132 * symmisc.c (dump_msymbols, dump_symtab_1)
133 (maintenance_print_one_line_table): Update.
134 * symfile.c (init_entry_point_info, section_is_mapped)
135 (list_overlays_command, simple_read_overlay_table)
136 (simple_overlay_update_1): Update.
137 * stap-probe.c (handle_stap_probe): Update.
138 * stabsread.c (dbx_init_float_type, define_symbol)
139 (read_one_struct_field, read_enum_type, read_range_type): Update.
140 * source.c (info_line_command): Update.
141 * python/python.c (gdbpy_source_objfile_script)
142 (gdbpy_execute_objfile_script): Update.
143 * python/py-type.c (save_objfile_types): Update.
144 * python/py-objfile.c (py_free_objfile): Update.
145 * python/py-inferior.c (python_new_objfile): Update.
146 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
147 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
148 (maintenance_check_psymtabs): Update.
149 * printcmd.c (info_address_command): Update.
150 * objfiles.h (struct objfile) <arch>: New method, from
151 get_objfile_arch.
152 (get_objfile_arch): Don't declare.
153 * objfiles.c (get_objfile_arch): Remove.
154 (filter_overlapping_sections): Update.
155 * minsyms.c (msymbol_is_function): Update.
156 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
157 (output_nondebug_symbol): Update.
158 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
159 (mdebug_expand_psymtab): Update.
160 * machoread.c (macho_add_oso_symfile): Update.
161 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
162 Update.
163 * linux-fork.c (checkpoint_command): Update.
164 * linespec.c (convert_linespec_to_sals): Update.
165 * jit.c (finalize_symtab): Update.
166 * infrun.c (insert_exception_resume_from_probe): Update.
167 * ia64-tdep.c (ia64_find_unwind_table): Update.
168 * hppa-tdep.c (internalize_unwinds): Update.
169 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
170 Update.
171 * gcore.c (call_target_sbrk): Update.
172 * elfread.c (record_minimal_symbol, elf_symtab_read)
173 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
174 (elf_gnu_ifunc_resolve_by_got): Update.
175 * dwarf2/read.c (create_addrmap_from_index)
176 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
177 (read_debug_names_from_section)
178 (process_psymtab_comp_unit_reader, add_partial_symbol)
179 (add_partial_subprogram, process_full_comp_unit)
180 (read_file_scope, read_func_scope, read_lexical_block_scope)
181 (read_call_site_scope, dwarf2_ranges_read)
182 (dwarf2_record_block_ranges, dwarf2_add_field)
183 (mark_common_block_symbol_computed, read_tag_pointer_type)
184 (read_tag_string_type, dwarf2_init_float_type)
185 (dwarf2_init_complex_target_type, read_base_type)
186 (partial_die_info::read, partial_die_info::read)
187 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
188 (dwarf2_fetch_die_loc_sect_off): Update.
189 * dwarf2/loc.c (dwarf2_find_location_expression)
190 (class dwarf_evaluate_loc_desc, rw_pieced_value)
191 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
192 (dwarf2_loc_desc_get_symbol_read_needs)
193 (locexpr_describe_location_piece, locexpr_describe_location_1)
194 (loclist_describe_location): Update.
195 * dwarf2/index-write.c (write_debug_names): Update.
196 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
197 * dtrace-probe.c (dtrace_process_dof): Update.
198 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
199 (process_one_symbol): Update.
200 * ctfread.c (ctf_init_float_type, read_base_type): Update.
201 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
202 (coff_read_enum_type): Update.
203 * cli/cli-cmds.c (edit_command, list_command): Update.
204 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
205 * breakpoint.c (create_overlay_event_breakpoint)
206 (create_longjmp_master_breakpoint)
207 (create_std_terminate_master_breakpoint)
208 (create_exception_master_breakpoint, get_sal_arch): Update.
209 * block.c (block_gdbarch): Update.
210 * annotate.c (annotate_source_line): Update.
211
212 2020-04-17 Tom Tromey <tromey@adacore.com>
213
214 * auto-load.c (show_auto_load_cmd): Remove.
215 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
216 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
217 (maintenance_print_arc_command): Remove.
218 * tui/tui-win.c (tui_command): Remove.
219 (tui_get_cmd_list): Use add_basic_prefix_cmd.
220 * tui/tui-layout.c (tui_layout_command): Remove.
221 (_initialize_tui_layout): Use add_basic_prefix_cmd.
222 * python/python.c (user_set_python, user_show_python): Remove.
223 (_initialize_python): Use add_basic_prefix_cmd,
224 add_show_prefix_cmd.
225 * guile/guile.c (set_guile_command, show_guile_command): Remove.
226 (install_gdb_commands): Use add_basic_prefix_cmd,
227 add_show_prefix_cmd.
228 (info_guile_command): Remove.
229 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
230 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
231 add_show_prefix_cmd.
232 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
233 Remove do_set and do_show parameters.
234 * cli/cli-style.c (set_style, show_style): Remove.
235 (_initialize_cli_style): Use add_basic_prefix_cmd,
236 add_show_prefix_cmd.
237 (cli_style_option::add_setshow_commands): Remove do_set and
238 do_show parameters.
239 (cli_style_option::add_setshow_commands): Use
240 add_basic_prefix_cmd, add_show_prefix_cmd.
241 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
242 (set_style_name): Remove.
243 * cli/cli-dump.c (dump_command, append_command): Remove.
244 (srec_dump_command, ihex_dump_command, verilog_dump_command)
245 (tekhex_dump_command, binary_dump_command)
246 (binary_append_command): Remove.
247 (_initialize_cli_dump): Use add_basic_prefix_cmd.
248 * windows-tdep.c (w32_prefix_command_valid): Remove global.
249 (init_w32_command_list): Remove; move into ...
250 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
251 * valprint.c (set_print, show_print, set_print_raw)
252 (show_print_raw): Remove.
253 (_initialize_valprint): Use add_basic_prefix_cmd,
254 add_show_prefix_cmd.
255 * typeprint.c (set_print_type, show_print_type): Remove.
256 (_initialize_typeprint): Use add_basic_prefix_cmd,
257 add_show_prefix_cmd.
258 * record.c (set_record_command, show_record_command): Remove.
259 (_initialize_record): Use add_basic_prefix_cmd,
260 add_show_prefix_cmd.
261 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
262 add_show_prefix_cmd.
263 (info_command, show_command, set_debug, show_debug): Remove.
264 * top.h (set_history, show_history): Don't declare.
265 * top.c (set_history, show_history): Remove.
266 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
267 (unset_tdesc_cmd): Remove.
268 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
269 add_show_prefix_cmd.
270 * symtab.c (info_module_command): Remove.
271 (_initialize_symtab): Use add_basic_prefix_cmd.
272 * symfile.c (overlay_command): Remove.
273 (_initialize_symfile): Use add_basic_prefix_cmd.
274 * sparc64-tdep.c (info_adi_command): Remove.
275 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
276 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
277 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
278 add_show_prefix_cmd.
279 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
280 (_initialize_serial): Use add_basic_prefix_cmd,
281 add_show_prefix_cmd.
282 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
283 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
284 add_show_prefix_cmd.
285 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
286 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
287 add_show_prefix_cmd.
288 * riscv-tdep.c (show_riscv_command, set_riscv_command)
289 (show_debug_riscv_command, set_debug_riscv_command): Remove.
290 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
291 add_show_prefix_cmd.
292 * remote.c (remote_command, set_remote_cmd): Remove.
293 (_initialize_remote): Use add_basic_prefix_cmd.
294 * record-full.c (set_record_full_command)
295 (show_record_full_command): Remove.
296 (_initialize_record_full): Use add_basic_prefix_cmd,
297 add_show_prefix_cmd.
298 * record-btrace.c (cmd_set_record_btrace)
299 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
300 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
301 (cmd_show_record_btrace_pt): Remove.
302 (_initialize_record_btrace): Use add_basic_prefix_cmd,
303 add_show_prefix_cmd.
304 * ravenscar-thread.c (set_ravenscar_command)
305 (show_ravenscar_command): Remove.
306 (_initialize_ravenscar): Use add_basic_prefix_cmd,
307 add_show_prefix_cmd.
308 * mips-tdep.c (show_mips_command, set_mips_command)
309 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
310 add_show_prefix_cmd.
311 * maint.c (maintenance_command, maintenance_info_command)
312 (maintenance_check_command, maintenance_print_command)
313 (maintenance_set_cmd, maintenance_show_cmd): Remove.
314 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
315 add_show_prefix_cmd.
316 (show_per_command_cmd): Remove.
317 * maint-test-settings.c (maintenance_set_test_settings_cmd):
318 Remove.
319 (maintenance_show_test_settings_cmd): Remove.
320 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
321 add_show_prefix_cmd.
322 * maint-test-options.c (maintenance_test_options_command):
323 Remove.
324 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
325 * macrocmd.c (macro_command): Remove
326 (_initialize_macrocmd): Use add_basic_prefix_cmd.
327 * language.c (set_check, show_check): Remove.
328 (_initialize_language): Use add_basic_prefix_cmd,
329 add_show_prefix_cmd.
330 * infcmd.c (unset_command): Remove.
331 (_initialize_infcmd): Use add_basic_prefix_cmd.
332 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
333 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
334 add_show_prefix_cmd.
335 * go32-nat.c (go32_info_dos_command): Remove.
336 (_initialize_go32_nat): Use add_basic_prefix_cmd.
337 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
338 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
339 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
340 (_initialize_frame): Use add_basic_prefix_cmd,
341 add_show_prefix_cmd.
342 * dcache.c (set_dcache_command, show_dcache_command): Remove.
343 (_initialize_dcache): Use add_basic_prefix_cmd,
344 add_show_prefix_cmd.
345 * cp-support.c (maint_cplus_command): Remove.
346 (_initialize_cp_support): Use add_basic_prefix_cmd.
347 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
348 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
349 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
350 add_basic_prefix_cmd, add_show_prefix_cmd.
351 * breakpoint.c (save_command): Remove.
352 (_initialize_breakpoint): Use add_basic_prefix_cmd.
353 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
354 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
355 add_show_prefix_cmd.
356 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
357 (set_ada_command, show_ada_command): Remove.
358 (_initialize_ada_language): Use add_basic_prefix_cmd,
359 add_show_prefix_cmd.
360 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
361
362 2020-04-16 Kamil Rytarowski <n54@gmx.com>
363
364 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
365 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
366
367 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
368
369 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
370 warning messages.
371
372 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
373
374 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
375 import table is not at beginning of .idata section.
376
377 2020-04-16 Pedro Alves <palves@redhat.com>
378
379 * inferior.c (delete_inferior): Use delete operator directly
380 instead of delete_program_space.
381 * progspace.c (add_program_space): New, factored out from
382 program_space::program_space.
383 (remove_program_space): New, factored out from
384 delete_program_space.
385 (program_space::program_space): Remove intro comment. Rewrite.
386 (program_space::~program_space): Remove intro comment. Call
387 remove_program_space.
388 (delete_program_space): Delete.
389 * progspace.h (program_space::program_space): Make explicit. Move
390 intro comment here, adjusted.
391 (program_space::~program_space): Move intro comment here,
392 adjusted.
393 (delete_program_space): Remove.
394
395 2020-04-16 Tom Tromey <tromey@adacore.com>
396
397 * windows-nat.c (windows_nat::handle_access_violation): New
398 function.
399 * nat/windows-nat.h (handle_access_violation): Declare.
400 * nat/windows-nat.c (handle_exception): Move Cygwin code to
401 windows-nat.c. Call handle_access_violation.
402
403 2020-04-16 Tom de Vries <tdevries@suse.de>
404
405 PR symtab/25791
406 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
407 CUs without psymtab.
408
409 2020-04-16 Kevin Buettner <kevinb@redhat.com>
410
411 * python/python.c (do_start_initialization): Don't call
412 PyEval_InitThreads for Python 3.9 and beyond.
413
414 2020-04-15 Kamil Rytarowski <n54@gmx.com>
415
416 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
417 thread functions.
418 (obsd_nat_target::wait): Likewise.
419
420 2020-04-15 Tom Tromey <tromey@adacore.com>
421
422 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
423 (DEBUG_EXCEPT): Use debug_printf.
424
425 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
426
427 * completer.c (class completion_tracker::completion_hash_entry)
428 <hash_name>: New member function.
429 (completion_tracker::discard_completions): New callback to hash a
430 completion_hash_entry, pass this to htab_create_alloc.
431
432 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
433
434 * windows-nat.c (windows_make_so): Warn rather than stopping with
435 an error if realpath() fails.
436
437 2020-04-14 Kamil Rytarowski <n54@gmx.com>
438
439 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
440 (nbsd_nat_target::info_proc): Add do_status.
441
442 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
443 Tom de Vries <tdevries@suse.de>
444
445 PR symtab/25718
446 * psympriv.h (struct partial_symtab::read_symtab)
447 (struct partial_symtab::expand_psymtab)
448 (struct partial_symtab::read_dependencies): Update comments.
449 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
450 read_symtab for includer.
451 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
452 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
453 (struct dwarf2_include_psymtab::m_readin): Remove.
454 (struct dwarf2_include_psymtab::includer): New member function.
455 (dwarf2_psymtab::expand_psymtab): Assert !readin.
456
457 2020-04-14 Tom de Vries <tdevries@suse.de>
458
459 PR symtab/25720
460 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
461 with NULL symbol_matcher and lookup_name.
462 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
463 and lookup_name.
464 * dwarf2/read.c (dw2_expand_symtabs_matching)
465 (dw2_debug_names_expand_symtabs_matching): Same.
466 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
467 Make lookup_name a pointer. Update comment.
468 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
469 lookup_name being a pointer.
470 * symfile.c (expand_symtabs_matching): Same.
471 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
472 * linespec.c (iterate_over_all_matching_symtabs): Same.
473
474 2020-04-13 Tom Tromey <tom@tromey.com>
475
476 * run-on-main-thread.c: Update include.
477 * unittests/main-thread-selftests.c: Update include.
478 * tui/tui-win.c: Update include.
479 * tui/tui-io.c: Update include.
480 * tui/tui-interp.c: Update include.
481 * tui/tui-hooks.c: Update include.
482 * top.h: Update include.
483 * top.c: Update include.
484 * ser-base.c: Update include.
485 * remote.c: Update include.
486 * remote-notif.c: Update include.
487 * remote-fileio.c: Update include.
488 * record-full.c: Update include.
489 * record-btrace.c: Update include.
490 * python/python.c: Update include.
491 * posix-hdep.c: Update include.
492 * mingw-hdep.c: Update include.
493 * mi/mi-main.c: Update include.
494 * mi/mi-interp.c: Update include.
495 * main.c: Update include.
496 * linux-nat.c: Update include.
497 * interps.c: Update include.
498 * infrun.c: Update include.
499 * inf-loop.c: Update include.
500 * event-top.c: Update include.
501 * event-loop.c: Move to ../gdbsupport/.
502 * event-loop.h: Move to ../gdbsupport/.
503 * async-event.h: Update include.
504 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
505
506 2020-04-13 Tom Tromey <tom@tromey.com>
507
508 * tui/tui-win.c: Include async-event.h.
509 * remote.c: Include async-event.h.
510 * remote-notif.c: Include async-event.h.
511 * record-full.c: Include async-event.h.
512 * record-btrace.c: Include async-event.h.
513 * infrun.c: Include async-event.h.
514 * event-top.c: Include async-event.h.
515 * event-loop.h: Move some declarations to async-event.h.
516 * event-loop.c: Don't include ser-event.h or top.h. Move some
517 code to async-event.c.
518 * async-event.h: New file.
519 * async-event.c: New file.
520 * Makefile.in (COMMON_SFILES): Add async-event.c.
521 (HFILES_NO_SRCDIR): Add async-event.h.
522
523 2020-04-13 Tom Tromey <tom@tromey.com>
524
525 * utils.c (flush_streams): New function.
526 * event-loop.c (gdb_wait_for_event): Call flush_streams.
527
528 2020-04-13 Tom Tromey <tom@tromey.com>
529
530 * event-loop.c (handle_file_event): Use warning, not
531 printf_unfiltered.
532
533 2020-04-13 Tom Tromey <tom@tromey.com>
534
535 * event-loop.c: Include <chrono>.
536
537 2020-04-13 Tom Tromey <tom@tromey.com>
538
539 * gdb_select.h: Move to ../gdbsupport/.
540 * event-loop.c: Update include path.
541 * top.c: Update include path.
542 * ser-base.c: Update include path.
543 * ui-file.c: Update include path.
544 * ser-tcp.c: Update include path.
545 * guile/scm-ports.c: Update include path.
546 * posix-hdep.c: Update include path.
547 * ser-unix.c: Update include path.
548 * gdb_usleep.c: Update include path.
549 * mingw-hdep.c: Update include path.
550 * inflow.c: Update include path.
551 * infrun.c: Update include path.
552 * event-top.c: Update include path.
553
554 2020-04-13 Tom Tromey <tom@tromey.com>
555
556 * configure: Rebuild.
557 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
558
559 2020-04-13 Tom Tromey <tom@tromey.com>
560
561 * event-loop.h (start_event_loop): Don't declare.
562 * event-loop.c (start_event_loop): Move...
563 * main.c (start_event_loop): ...here. Now static.
564
565 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
566
567 * MAINTAINERS: Update my email address.
568
569 2020-04-12 Kamil Rytarowski <n54@gmx.com>
570
571 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
572 IP_ALL.
573
574 2020-04-12 Kamil Rytarowski <n54@gmx.com>
575
576 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
577 (nbsd_nat_target::info_proc): Add do_cmdline.
578
579 2020-04-12 Kamil Rytarowski <n54@gmx.com>
580
581 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
582 (nbsd_nat_target::info_proc): Add do_cwd.
583
584 2020-04-12 Kamil Rytarowski <n54@gmx.com>
585
586 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
587
588 2020-04-11 Kamil Rytarowski <n54@gmx.com>
589
590 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
591 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
592 (nbsd_nat_target::info_proc): New functions.
593 * nbsd-nat.c (kinfo_get_vmmap): New function.
594 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
595 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
596 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
597 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
598 functions.
599 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
600 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
601 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
602 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
603 (KINFO_VME_FLAG_GROWS_DOWN): New.
604
605 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
606
607 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
608 bit shift.
609
610 2020-04-10 Tom Tromey <tromey@adacore.com>
611
612 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
613
614 2020-04-10 Tom Tromey <tromey@adacore.com>
615
616 * symtab.c (get_symbol_address, get_msymbol_address): Skip
617 separate debug files.
618
619 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
620
621 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
622 Move to...
623 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
624 ... here.
625 * windows-nat.c (windows_nat_target::get_windows_debug_event):
626 Check for STATUS_WX86_BREAKPOINT.
627 (windows_nat_target::wait): Same.
628
629 2020-04-10 Tom de Vries <tdevries@suse.de>
630
631 PR cli/25808
632 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
633
634 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
635
636 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
637 (Write After Approval): Remove Tom de Vries.
638
639 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
640
641 revert partially:
642 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
643
644 * buildsym.c (record_line): Fix undefined behavior and preserve
645 lines at eof.
646
647 2020-04-09 Kamil Rytarowski <n54@gmx.com>
648
649 * auxv.h (svr4_auxv_parse): New.
650 * auxv.c (default_auxv_parse): Split into default_auxv_parse
651 and generic_auxv_parse.
652 (svr4_auxv_parse): Add.
653 * obsd-tdep.c: Include "auxv.h".
654 (obsd_auxv_parse): Remove.
655 (obsd_init_abi): Remove comment.
656 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
657 from `obsd_auxv_parse' to `svr4_auxv_parse'.
658 * nbsd-tdep.c: Include "auxv.h".
659 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
660
661 2020-04-08 Tom Tromey <tromey@adacore.com>
662
663 * nat/windows-nat.h (last_wait_event): Don't declare.
664 (wait_for_debug_event): Update comment.
665 * nat/windows-nat.c (last_wait_event): Now static.
666
667 2020-04-08 Tom Tromey <tromey@adacore.com>
668
669 * windows-nat.c (wait_for_debug_event): Move to
670 nat/windows-nat.c.
671 * nat/windows-nat.h (wait_for_debug_event): Declare.
672 * nat/windows-nat.c (wait_for_debug_event): Move from
673 windows-nat.c. No longer static.
674
675 2020-04-08 Tom Tromey <tromey@adacore.com>
676
677 * windows-nat.c (get_windows_debug_event): Use
678 fetch_pending_stop.
679 * nat/windows-nat.h (fetch_pending_stop): Declare.
680 * nat/windows-nat.c (fetch_pending_stop): New function.
681
682 2020-04-08 Tom Tromey <tromey@adacore.com>
683
684 * windows-nat.c (windows_continue): Use matching_pending_stop and
685 continue_last_debug_event.
686 * nat/windows-nat.h (matching_pending_stop)
687 (continue_last_debug_event): Declare.
688 * nat/windows-nat.c (DEBUG_EVENTS): New define.
689 (matching_pending_stop, continue_last_debug_event): New
690 functions.
691
692 2020-04-08 Tom Tromey <tromey@adacore.com>
693
694 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
695 (handle_exception_result): Move to nat/windows-nat.h.
696 (DEBUG_EXCEPTION_SIMPLE): Remove.
697 (windows_nat::handle_ms_vc_exception): New function.
698 (handle_exception): Move to nat/windows-nat.c.
699 (get_windows_debug_event): Update.
700 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
701 nat/windows-nat.c.
702 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
703 (handle_exception_result): Move from windows-nat.c.
704 (handle_exception): Declare.
705 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
706 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
707 windows-nat.c.
708
709 2020-04-08 Tom Tromey <tromey@adacore.com>
710
711 * windows-nat.c (exception_count, event_count): Remove.
712 (handle_exception, get_windows_debug_event)
713 (do_initial_windows_stuff): Update.
714
715 2020-04-08 Tom Tromey <tromey@adacore.com>
716
717 * windows-nat.c (windows_nat::handle_load_dll)
718 (windows_nat::handle_unload_dll): Rename. No longer static.
719 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
720 Declare.
721
722 2020-04-08 Tom Tromey <tromey@adacore.com>
723
724 * complaints.h (stop_whining): Declare at top-level.
725 (complaint): Don't declare stop_whining.
726
727 2020-04-08 Tom Tromey <tromey@adacore.com>
728
729 * windows-nat.c (windows_nat::handle_output_debug_string):
730 Rename. No longer static.
731 * nat/windows-nat.h (handle_output_debug_string): Declare.
732
733 2020-04-08 Tom Tromey <tromey@adacore.com>
734
735 * windows-nat.c (current_process_handle, current_process_id)
736 (main_thread_id, last_sig, current_event, last_wait_event)
737 (current_windows_thread, desired_stop_thread_id, pending_stops)
738 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
739 (display_selectors, fake_create_process)
740 (get_windows_debug_event): Update.
741 * nat/windows-nat.h (current_process_handle, current_process_id)
742 (main_thread_id, last_sig, current_event, last_wait_event)
743 (current_windows_thread, desired_stop_thread_id, pending_stops)
744 (struct pending_stop, siginfo_er): Move from windows-nat.c.
745 * nat/windows-nat.c (current_process_handle, current_process_id)
746 (main_thread_id, last_sig, current_event, last_wait_event)
747 (current_windows_thread, desired_stop_thread_id, pending_stops)
748 (siginfo_er): New globals. Move from windows-nat.c.
749
750 2020-04-08 Tom Tromey <tromey@adacore.com>
751
752 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
753 (handle_load_dll): Update.
754 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
755
756 2020-04-08 Tom Tromey <tromey@adacore.com>
757
758 * windows-nat.c (enum thread_disposition_type): Move to
759 nat/windows-nat.h.
760 (windows_nat::thread_rec): Rename from thread_rec. No longer
761 static.
762 (windows_add_thread, windows_nat_target::fetch_registers)
763 (windows_nat_target::store_registers, handle_exception)
764 (windows_nat_target::resume, get_windows_debug_event)
765 (windows_nat_target::get_tib_address)
766 (windows_nat_target::thread_name)
767 (windows_nat_target::thread_alive): Update.
768 * nat/windows-nat.h (enum thread_disposition_type): Move from
769 windows-nat.c.
770 (thread_rec): Declare.
771
772 2020-04-08 Tom Tromey <tromey@adacore.com>
773
774 * windows-nat.c: Add "using namespace".
775 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
776 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
777
778 2020-04-08 Tom Tromey <tromey@adacore.com>
779
780 * nat/windows-nat.h (struct windows_thread_info): Declare
781 destructor.
782 * nat/windows-nat.c (~windows_thread_info): New.
783
784 2020-04-08 Tom Tromey <tromey@adacore.com>
785
786 PR gdb/22992
787 * windows-nat.c (current_event): Update comment.
788 (last_wait_event, desired_stop_thread_id): New globals.
789 (struct pending_stop): New.
790 (pending_stops): New global.
791 (windows_nat_target) <stopped_by_sw_breakpoint>
792 <supports_stopped_by_sw_breakpoint>: New methods.
793 (windows_fetch_one_register): Add assertions. Adjust PC.
794 (windows_continue): Handle pending stops. Suspend other threads
795 when stepping. Use last_wait_event
796 (wait_for_debug_event): New function.
797 (get_windows_debug_event): Use wait_for_debug_event. Handle
798 pending stops. Queue spurious stops.
799 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
800 (windows_nat_target::kill): Use wait_for_debug_event.
801 * nat/windows-nat.h (struct windows_thread_info)
802 <stopped_at_software_breakpoint>: New field.
803 * nat/windows-nat.c (windows_thread_info::resume): Clear
804 stopped_at_software_breakpoint.
805
806 2020-04-08 Tom Tromey <tromey@adacore.com>
807
808 * windows-nat.c (enum thread_disposition_type): New.
809 (thread_rec): Replace "get_context" parameter with "disposition";
810 change type.
811 (windows_add_thread, windows_nat_target::fetch_registers)
812 (windows_nat_target::store_registers, handle_exception)
813 (windows_nat_target::resume, get_windows_debug_event)
814 (windows_nat_target::get_tib_address)
815 (windows_nat_target::thread_name)
816 (windows_nat_target::thread_alive): Update.
817
818 2020-04-08 Tom Tromey <tromey@adacore.com>
819
820 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
821 (windows_continue): Use windows_continue::resume.
822 * nat/windows-nat.h (struct windows_thread_info) <suspend,
823 resume>: Declare new methods.
824 * nat/windows-nat.c: New file.
825 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
826
827 2020-04-08 Tom Tromey <tromey@adacore.com>
828
829 * windows-nat.c (windows_add_thread, windows_delete_thread)
830 (windows_nat_target::fetch_registers)
831 (windows_nat_target::store_registers, fake_create_process)
832 (windows_nat_target::resume, windows_nat_target::resume)
833 (get_windows_debug_event, windows_nat_target::wait)
834 (windows_nat_target::pid_to_str)
835 (windows_nat_target::get_tib_address)
836 (windows_nat_target::get_ada_task_ptid)
837 (windows_nat_target::thread_name)
838 (windows_nat_target::thread_alive): Use lwp, not tid.
839
840 2020-04-08 Tom Tromey <tromey@adacore.com>
841
842 * windows-nat.c (handle_exception)
843 (windows_nat_target::thread_name): Update.
844 * nat/windows-nat.h (windows_thread_info): Remove destructor.
845 <name>: Now unique_xmalloc_ptr.
846
847 2020-04-08 Tom Tromey <tromey@adacore.com>
848
849 * windows-nat.c (thread_rec)
850 (windows_nat_target::fetch_registers): Update.
851 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
852 Update comment.
853 <debug_registers_changed, reload_context>: Now bool.
854
855 2020-04-08 Tom Tromey <tromey@adacore.com>
856
857 * windows-nat.c (windows_add_thread): Use new.
858 (windows_init_thread_list, windows_delete_thread): Use delete.
859 (get_windows_debug_event): Update.
860 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
861 destructor, and initializers.
862
863 2020-04-08 Tom Tromey <tromey@adacore.com>
864
865 * windows-nat.c (struct windows_thread_info): Remove.
866 * nat/windows-nat.h: New file.
867
868 2020-04-08 Tom Tromey <tromey@adacore.com>
869
870 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
871 (thread_rec, windows_add_thread, windows_delete_thread)
872 (windows_continue): Update.
873
874 2020-04-08 Tom Tromey <tromey@adacore.com>
875
876 * windows-nat.c (struct windows_thread_info): Remove typedef.
877 (thread_head): Remove.
878 (thread_list): New global.
879 (thread_rec, windows_add_thread, windows_init_thread_list)
880 (windows_delete_thread, windows_continue): Update.
881
882 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
883
884 * windows-tdep.h (windows_init_abi): Add comment.
885 (cygwin_init_abi): New declaration.
886 * windows-tdep.c: Split signal enumeration in two, one for
887 Windows and one for Cygwin.
888 (windows_gdb_signal_to_target): Only deal with signal of the
889 Windows OS ABI.
890 (cygwin_gdb_signal_to_target): New function.
891 (windows_init_abi): Rename to windows_init_abi_common, don't set
892 gdb_signal_to_target gdbarch method. Add new new function with
893 this name.
894 (cygwin_init_abi): New function.
895 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
896 comment. Don't call windows_init_abi.
897 (amd64_windows_init_abi): Add comment, call windows_init_abi.
898 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
899 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
900 i386_windows_init_abi_common, don't call windows_init_abi. Add
901 a new function of this name.
902 (i386_cygwin_init_abi): New function.
903 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
904 OS ABI Cygwin.
905
906 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
907
908 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
909 parameter.c.
910 (dwarf2_read_gdb_index): Update.
911
912 2020-04-07 Kamil Rytarowski <n54@gmx.com>
913
914 * nbsd-tdep.c: Include "objfiles.h".
915 (nbsd_skip_solib_resolver): New.
916 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
917
918 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
919
920 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
921 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
922 with DW_LLE_base_addressx are being emitted in DWARFv5.
923 Add the newly added kind DW_LOC_OFFSET_PAIR also.
924 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
925 unsigned integer.
926
927 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
928
929 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
930 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
931 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
932 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
933 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
934 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
935 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
936
937
938 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
939
940 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
941 (read_loclist_index): New function definition.
942 (lookup_loclist_base): New function definition.
943 (read_loclist_header): New function definition.
944 (dwarf2_cu): Add loclist_base and loclist_header field.
945 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
946 (read_full_die_1): Read the value of DW_AT_loclists_base.
947 (read_attribute_reprocess): Handle DW_FORM_loclistx.
948 (read_attribute_value): Handle DW_FORM_loclistx.
949 (skip_one_die): Handle DW_FORM_loclistx.
950 (loclist_header): New structure declaration.
951 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
952
953 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
954
955 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
956 constructor. Remove `addr` parameter from other constructor and
957 add `per_cu` parameter.
958 * dwarf2/read.c (create_partial_symtab): Update.
959
960 2020-04-07 Tom de Vries <tdevries@suse.de>
961
962 PR symtab/25796
963 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
964 (partial_die_info::fixup): Inherit has_const_value.
965
966 2020-04-07 Tom de Vries <tdevries@suse.de>
967
968 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
969 symbols without address.
970
971 2020-04-06 Kamil Rytarowski <n54@gmx.com>
972
973 * nbsd-nat.h (struct thread_info): Add forward declaration.
974 (nbsd_nat_target::thread_alive): Add.
975 (nbsd_nat_target::thread_name): Likewise.
976 (nbsd_nat_target::update_thread_list): Likewise.
977 (update_thread_list::post_attach): Likewise.
978 (post_attach::pid_to_str): Likewise.
979 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
980 (nbsd_thread_lister): Add.
981 (nbsd_nat_target::thread_alive): Likewise.
982 (nbsd_nat_target::thread_name): Likewise.
983 (nbsd_add_threads): Likewise.
984 (update_thread_list::post_attach): Likewise.
985 (nbsd_nat_target::update_thread_list): Likewise.
986 (post_attach::pid_to_str): Likewise.
987
988 2020-04-06 Tom Tromey <tromey@adacore.com>
989
990 * ada-valprint.c (print_variant_part): Extract the variant field.
991 (print_field_values): Use the field as the outer value when
992 recursing.
993
994 2020-04-06 Tom Tromey <tromey@adacore.com>
995
996 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
997 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
998 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
999 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
1000 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
1001
1002 2020-04-06 Tom Tromey <tromey@adacore.com>
1003
1004 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
1005 TYPE_CODE_ERROR.
1006
1007 2020-04-06 Kamil Rytarowski <n54@gmx.com>
1008
1009 * nbsd-tdep.c: Include "gdbarch.h".
1010 Define enum with NetBSD signal numbers.
1011 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
1012 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
1013 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
1014 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
1015 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
1016 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
1017 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
1018 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
1019 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
1020 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
1021 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
1022 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
1023
1024 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
1025
1026 PR gdb/25325
1027 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
1028
1029 2020-04-03 Tom Tromey <tromey@adacore.com>
1030
1031 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
1032 Read constant block.
1033
1034 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
1035
1036 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
1037 (gdb_bfd_get_full_section_contents): New declaration.
1038 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
1039 * windows-tdep.c (is_linked_with_cygwin_dll): Use
1040 gdb_bfd_get_full_section_contents.
1041
1042 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
1043
1044 * exec.c (build_section_table): Replace internal_error with
1045 gdb_assert.
1046 (section_table_xfer_memory_partial): Likewise.
1047 * mdebugread.c (parse_partial_symbols): Likewise.
1048 * psymtab.c (lookup_partial_symbol): Likewise.
1049 * utils.c (wrap_here): Likewise.
1050
1051 2020-04-02 Tom Tromey <tromey@adacore.com>
1052
1053 * f-lang.c (build_fortran_types): Use arch_type to initialize
1054 builtin_complex_s32 in the TYPE_CODE_ERROR case.
1055
1056 2020-04-02 Tom Tromey <tromey@adacore.com>
1057
1058 * dwarf2/read.c (partial_die_info::read): Do not create a vector
1059 of attributes.
1060
1061 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
1062 Bernd Edlinger <bernd.edlinger@hotmail.de>
1063 Tom Tromey <tromey@adacore.com>
1064
1065 * buildsym.c (buildsym_compunit::record_line): Remove
1066 deduplication code.
1067
1068 2020-04-02 Tom de Vries <tdevries@suse.de>
1069
1070 PR ada/24671
1071 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
1072
1073 2020-04-02 Tom de Vries <tdevries@suse.de>
1074
1075 * dwarf2/read.c (dwarf2_gdb_index_functions,
1076 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
1077 NULL.
1078 * psymtab.c (psym_lookup_global_symbol_language): New function.
1079 (psym_functions): Init psym_lookup_global_symbol_language with
1080 psym_lookup_global_symbol_language.
1081 * symfile-debug.c (debug_sym_quick_functions): Init
1082 lookup_global_symbol_language with NULL.
1083 * symfile.c (set_initial_language): Remove fixme comment.
1084 * symfile.h (struct quick_symbol_functions): Add
1085 lookup_global_symbol_language.
1086 * symtab.c (find_quick_global_symbol_language): New function.
1087 (find_main_name): Use find_quick_global_symbol_language.
1088
1089 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
1090
1091 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
1092
1093 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
1094
1095 * buildsym.c (record_line): Fix undefined behavior and preserve
1096 lines at eof.
1097
1098 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
1099
1100 * buildsym.c (record_line): Fix the resizing condition.
1101
1102 2020-04-01 Tom Tromey <tom@tromey.com>
1103
1104 * value.h (value_literal_complex): Add comment.
1105 * valops.c (value_literal_complex): Refer to value.h.
1106
1107 2020-04-01 Tom Tromey <tom@tromey.com>
1108
1109 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
1110 (scalar_type): New rule, from typebase.
1111 (typebase): Use scalar_type. Recognize complex types.
1112 (field_name): Handle FLOAT_KEYWORD.
1113 (ident_tokens): Add _Complex and __complex__.
1114
1115 2020-04-01 Tom Tromey <tom@tromey.com>
1116
1117 PR exp/25299:
1118 * valarith.c (promotion_type, complex_binop): New functions.
1119 (scalar_binop): Handle complex numbers. Use promotion_type.
1120 (value_pos, value_neg, value_complement): Handle complex numbers.
1121
1122 2020-04-01 Tom Tromey <tom@tromey.com>
1123
1124 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
1125 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
1126 (parse_number): Handle complex numbers.
1127
1128 2020-04-01 Tom Tromey <tom@tromey.com>
1129
1130 * c-valprint.c (c_decorations): Change complex suffix to "i".
1131
1132 2020-04-01 Tom Tromey <tom@tromey.com>
1133
1134 * valprint.c (generic_value_print_complex): Use accessors.
1135 * value.h (value_real_part, value_imaginary_part): Declare.
1136 * valops.c (value_real_part, value_imaginary_part): New
1137 functions.
1138 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
1139
1140 2020-04-01 Tom Tromey <tom@tromey.com>
1141
1142 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
1143 (read_range_type): Update.
1144 * mdebugread.c (basic_type): Update.
1145 * go-lang.c (build_go_types): Use init_complex_type.
1146 * gdbtypes.h (struct main_type) <complex_type>: New member.
1147 (init_complex_type): Update.
1148 (arch_complex_type): Don't declare.
1149 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
1150 Make name if none given. Use alloc_type_copy. Look for cached
1151 complex type.
1152 (arch_complex_type): Remove.
1153 (gdbtypes_post_init): Use init_complex_type.
1154 * f-lang.c (build_fortran_types): Use init_complex_type.
1155 * dwarf2/read.c (read_base_type): Update.
1156 * d-lang.c (build_d_types): Use init_complex_type.
1157 * ctfread.c (read_base_type): Update.
1158
1159 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1160
1161 * infrun.c (stop_all_threads): Update assertion, plus when
1162 stopping threads, take into account that we might be trying
1163 to stop an all-stop target.
1164 (stop_waiting): Call 'stop_all_threads' if there exists a
1165 non-stop target.
1166
1167 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1168
1169 * target.h (exists_non_stop_target): New function declaration.
1170 * target.c (exists_non_stop_target): New function.
1171
1172 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
1173
1174 PR gdb/24789
1175 * eval.c (is_integral_or_integral_reference): New function.
1176 (evaluate_subexp_standard): Allow integer references in
1177 pointer arithmetic.
1178
1179 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1180
1181 * remote.c (remote_target::remote_parse_stop_reply): Remove the
1182 check for no ptid in the stop reply when the target is non-stop.
1183
1184 2020-04-01 Tom Tromey <tromey@adacore.com>
1185
1186 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
1187 "name" parameter to rvalue reference. Initialize m_name_holder.
1188 <lookup_name_info>: New overloads.
1189 <name>: Return gdb::string_view.
1190 <c_str>: New method.
1191 <make_ignore_params>: Update.
1192 <search_name_hash>: Update.
1193 <language_lookup_name>: Return const char *.
1194 <m_name>: Change type.
1195 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
1196 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
1197 (lookup_name_info::match_any): Update.
1198 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
1199 Update.
1200 * minsyms.c (linkage_name_str): Update.
1201 * language.c (default_symbol_name_matcher): Update.
1202 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
1203 Update.
1204 * ada-lang.c (ada_fold_name): Change parameter to string_view.
1205 (ada_lookup_name_info::ada_lookup_name_info): Update.
1206 (literal_symbol_name_matcher): Update.
1207
1208 2020-04-01 Tom Tromey <tromey@adacore.com>
1209
1210 * psymtab.c (psymtab_search_name): Remove function.
1211 (psym_lookup_symbol): Create search name and lookup name here.
1212 (lookup_partial_symbol): Remove "name" parameter; add
1213 lookup_name.
1214 (psym_expand_symtabs_for_function): Update.
1215
1216 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
1217
1218 PR tui/25597:
1219 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
1220
1221 2020-03-31 Tom Tromey <tromey@adacore.com>
1222
1223 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
1224 memcpy.
1225
1226 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
1227
1228 * features/riscv/32bit-csr.xml: Regenerated.
1229 * features/riscv/64bit-csr.xml: Regenerated.
1230
1231 2020-03-30 Tom Tromey <tromey@adacore.com>
1232
1233 * ada-valprint.c (print_variant_part): Update.
1234 * ada-lang.h (ada_which_variant_applies): Update.
1235 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
1236 outer_valaddr parameters; replace with "outer" value parameter.
1237 (to_fixed_variant_branch_type): Update.
1238
1239 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1240
1241 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
1242 <list>. Remove inclusion of observable.h.
1243 (PPC_DEBUG_CURRENT_VERSION): Move up define.
1244 (struct arch_lwp_info): New struct.
1245 (class ppc_linux_dreg_interface): New class.
1246 (struct ppc_linux_process_info): New struct.
1247 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
1248 <low_new_clone, low_forget_process, low_prepare_to_resume>
1249 <copy_thread_dreg_state, mark_thread_stale>
1250 <mark_debug_registers_changed, register_hw_breakpoint>
1251 <clear_hw_breakpoint, register_wp, clear_wp>
1252 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
1253 <num_memory_accesses, get_trigger_type>
1254 <create_watchpoint_request, hwdebug_point_cmp>
1255 <init_arch_lwp_info, get_arch_lwp_info>
1256 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
1257 methods.
1258 <struct ptid_hash>: New inner struct.
1259 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
1260 members.
1261 (saved_dabr_value, hwdebug_info, max_slots_number)
1262 (struct hw_break_tuple, struct thread_points, ppc_threads)
1263 (have_ptrace_hwdebug_interface)
1264 (hwdebug_find_thread_points_by_tid)
1265 (hwdebug_insert_point, hwdebug_remove_point): Remove.
1266 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
1267 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
1268 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
1269 use m_dreg_interface.
1270 (hwdebug_point_cmp): Change to...
1271 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
1272 reference arguments instead of pointers.
1273 (ppc_linux_nat_target::ranged_break_num_registers): Use
1274 m_dreg_interface.
1275 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
1276 m_dreg_interface. Call register_hw_breakpoint.
1277 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
1278 m_dreg_interface. Call clear_hw_breakpoint.
1279 (get_trigger_type): Change to...
1280 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
1281 comment.
1282 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
1283 use m_dreg_interface. Call register_hw_breakpoint.
1284 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
1285 use m_dreg_interface. Call clear_hw_breakpoint.
1286 (can_use_watchpoint_cond_accel): Change to...
1287 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
1288 method. Update comment, use m_dreg_interface and
1289 m_process_info.
1290 (calculate_dvc): Change to...
1291 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
1292 m_dreg_interface.
1293 (num_memory_accesses): Change to...
1294 (ppc_linux_nat_target::num_memory_accesses): ...this method.
1295 (check_condition): Change to...
1296 (ppc_linux_nat_target::check_condition): ...this method.
1297 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
1298 comment, use m_dreg_interface.
1299 (create_watchpoint_request): Change to...
1300 (ppc_linux_nat_target::create_watchpoint_request): ...this
1301 method. Use m_dreg_interface.
1302 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
1303 m_dreg_interface. Call register_hw_breakpoint or register_wp.
1304 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
1305 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
1306 (ppc_linux_nat_target::low_forget_process)
1307 (ppc_linux_nat_target::low_new_fork)
1308 (ppc_linux_nat_target::low_new_clone)
1309 (ppc_linux_nat_target::low_delete_thread)
1310 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
1311 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
1312 only call mark_thread_stale.
1313 (ppc_linux_thread_exit): Remove.
1314 (ppc_linux_nat_target::stopped_data_address): Change to...
1315 (ppc_linux_nat_target::low_stopped_data_address): This. Add
1316 comment, use m_dreg_interface and m_thread_hw_breakpoints.
1317 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
1318 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
1319 comment. Call low_stopped_data_address.
1320 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
1321 m_dreg_interface.
1322 (ppc_linux_nat_target::masked_watch_num_registers): Use
1323 m_dreg_interface.
1324 (ppc_linux_nat_target::copy_thread_dreg_state)
1325 (ppc_linux_nat_target::mark_thread_stale)
1326 (ppc_linux_nat_target::mark_debug_registers_changed)
1327 (ppc_linux_nat_target::register_hw_breakpoint)
1328 (ppc_linux_nat_target::clear_hw_breakpoint)
1329 (ppc_linux_nat_target::register_wp)
1330 (ppc_linux_nat_target::clear_wp)
1331 (ppc_linux_nat_target::init_arch_lwp_info)
1332 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
1333 (_initialize_ppc_linux_nat): Remove observer callback.
1334
1335 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1336
1337 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
1338 (ppc_linux_nat_target::auxv_parse)
1339 (ppc_linux_nat_target::read_description)
1340 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
1341 Move up.
1342
1343 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1344
1345 * linux-nat.h (low_new_clone): New method.
1346 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
1347
1348 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
1349
1350 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
1351 (dbx_expand_psymtab): ... this.
1352 (start_psymtab): Update.
1353 * mdebugread.c (psymtab_to_symtab_1): Rename to...
1354 (mdebug_expand_psymtab): ... this.
1355 (parse_partial_symbols): Update.
1356 (new_psymtab): Update.
1357 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
1358 (xcoff_expand_psymtab): ... this.
1359 (xcoff_start_psymtab): Update.
1360
1361 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
1362
1363 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
1364 <expand_dependencies>: ... this.
1365 * psymtab.c (partial_symtab::read_dependencies): Rename to...
1366 (partial_symtab::expand_dependencies): ... this.
1367 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
1368 Update.
1369 (dwarf2_psymtab::expand_psymtab): Update.
1370 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
1371 * mdebugread.c (psymtab_to_symtab_1): Update.
1372 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
1373
1374 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
1375
1376 * psympriv.h (discard_psymtab): Remove.
1377 * dbxread.c (dbx_end_psymtab): Update.
1378 * xcoffread.c (xcoff_end_psymtab): Update.
1379
1380 2020-03-28 Tom Tromey <tom@tromey.com>
1381
1382 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
1383 comment.
1384
1385 2020-03-28 Tom Tromey <tom@tromey.com>
1386
1387 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
1388
1389 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
1390
1391 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
1392
1393 2020-03-26 John Baldwin <jhb@FreeBSD.org>
1394
1395 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
1396
1397 2020-03-26 Tom Tromey <tom@tromey.com>
1398
1399 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
1400 (mark_common_block_symbol_computed, read_tag_string_type)
1401 (attr_to_dynamic_prop, read_subrange_type): Update.
1402 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
1403 to be methods on struct attribute.
1404 (skip_one_die, process_imported_unit_die, read_namespace_alias)
1405 (read_call_site_scope, partial_die_info::read)
1406 (partial_die_info::read, lookup_die_type, follow_die_ref):
1407 Update.
1408 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
1409 from dwarf2_get_ref_die_offset.
1410 (attribute::constant_value): New method, from
1411 dwarf2_get_attr_constant_value.
1412 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
1413 Declare method.
1414 <constant_value>: New method.
1415
1416 2020-03-26 Tom Tromey <tom@tromey.com>
1417
1418 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
1419 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
1420 (dwarf_type_encoding_name): Move to stringify.c.
1421 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
1422 * dwarf2/stringify.c: New file.
1423 * dwarf2/stringify.h: New file.
1424
1425 2020-03-26 Tom Tromey <tom@tromey.com>
1426
1427 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
1428 Rewrite.
1429
1430 2020-03-26 Tom Tromey <tom@tromey.com>
1431
1432 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
1433 methods.
1434 * dwarf2/read.c (lookup_addr_base): Move to die.h.
1435 (lookup_ranges_base): Likewise.
1436 (read_cutu_die_from_dwo, read_full_die_1): Update.
1437
1438 2020-03-26 Tom Tromey <tom@tromey.com>
1439
1440 * dwarf2/read.c (read_import_statement, read_file_scope)
1441 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
1442 (read_lexical_block_scope, read_call_site_scope)
1443 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
1444 (handle_struct_member_die, process_structure_scope)
1445 (update_enumeration_type_from_children)
1446 (process_enumeration_scope, read_array_type, read_common_block)
1447 (read_namespace, read_module, read_subroutine_type): Update.
1448 (sibling_die): Remove.
1449
1450 2020-03-26 Tom Tromey <tom@tromey.com>
1451
1452 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
1453 (build_type_psymtabs_reader, read_structure_type)
1454 (read_enumeration_type, read_full_die_1): Update.
1455 (dwarf2_attr_no_follow): Move to die.h.
1456 * dwarf2/die.h (struct die_info) <attr>: New method.
1457
1458 2020-03-26 Tom Tromey <tom@tromey.com>
1459
1460 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
1461 <base_address>: Now an optional.
1462 (dwarf2_find_base_address, dwarf2_rnglists_process)
1463 (dwarf2_ranges_process, fill_in_loclist_baton)
1464 (dwarf2_symbol_mark_computed): Update.
1465
1466 2020-03-26 Tom Tromey <tom@tromey.com>
1467
1468 * dwarf2/read.c (struct die_info): Move to die.h.
1469 * dwarf2/die.h: New file.
1470
1471 2020-03-26 Tom Tromey <tom@tromey.com>
1472
1473 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
1474 * dwarf2/read.c
1475 (dwarf2_statement_list_fits_in_line_number_section_complaint):
1476 Move to line-header.c.
1477 (read_checked_initial_length_and_offset, read_formatted_entries):
1478 Likewise.
1479 (dwarf_decode_line_header): Split into two.
1480 * dwarf2/line-header.c
1481 (dwarf2_statement_list_fits_in_line_number_section_complaint):
1482 Move from read.c.
1483 (read_checked_initial_length_and_offset, read_formatted_entries):
1484 Likewise.
1485 (dwarf_decode_line_header): New function, split from read.c.
1486
1487 2020-03-26 Tom Tromey <tom@tromey.com>
1488
1489 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
1490 Declare method.
1491 * dwarf2/read.c (read_attribute_value): Update.
1492 (dwarf2_per_objfile::read_line_string): Rename from
1493 read_indirect_line_string.
1494 (read_formatted_entries): Update.
1495
1496 2020-03-26 Tom Tromey <tom@tromey.com>
1497
1498 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
1499 variable.
1500
1501 2020-03-26 Tom Tromey <tom@tromey.com>
1502
1503 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
1504 const.
1505 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
1506 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
1507 parameter const.
1508
1509 2020-03-26 Tom Tromey <tom@tromey.com>
1510
1511 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
1512 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
1513 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
1514 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
1515
1516 2020-03-26 Tom Tromey <tom@tromey.com>
1517
1518 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
1519 file_names_size, file_full_name, file_file_name>: Use const.
1520 <file_name_at, file_names>: Add const overload.
1521 * dwarf2/line-header.c (line_header::file_file_name)
1522 (line_header::file_full_name): Update.
1523
1524 2020-03-26 Tom Tromey <tom@tromey.com>
1525
1526 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
1527 (macro_start_file, consume_improper_spaces)
1528 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
1529 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
1530 (dwarf_decode_macros): Move to macro.c.
1531 * dwarf2/macro.c: New file.
1532 * dwarf2/macro.h: New file.
1533 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
1534
1535 2020-03-26 Tom Tromey <tom@tromey.com>
1536
1537 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
1538 method.
1539 * dwarf2/section.c: New method. From
1540 read_indirect_string_at_offset_from.
1541 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
1542 (read_indirect_string_at_offset_from): Move to section.c.
1543 (read_indirect_string_at_offset): Rewrite.
1544 (read_indirect_line_string_at_offset): Remove.
1545 (read_indirect_string, read_indirect_line_string)
1546 (dwarf_decode_macro_bytes): Update.
1547
1548 2020-03-26 Tom Tromey <tom@tromey.com>
1549
1550 * dwarf2/section.h (struct dwarf2_section_info)
1551 <overload_complaint>: Declare.
1552 (dwarf2_section_buffer_overflow_complaint): Don't declare.
1553 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
1554 Rename from dwarf2_section_buffer_overflow_complaint.
1555 * dwarf2/read.c (skip_one_die, partial_die_info::read)
1556 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
1557
1558 2020-03-26 Tom Tromey <tom@tromey.com>
1559
1560 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
1561 Declare.
1562 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
1563 Move from read.c.
1564 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
1565 to section.c.
1566
1567 2020-03-26 Tom Tromey <tom@tromey.com>
1568
1569 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
1570
1571 2020-03-26 Tom Tromey <tom@tromey.com>
1572
1573 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
1574 "builder".
1575 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
1576 parameter.
1577 (dwarf_decode_macros): Update.
1578
1579 2020-03-26 Tom Tromey <tom@tromey.com>
1580
1581 * dwarf2/read.c (read_attribute_value): Update.
1582 (read_indirect_string_from_dwz): Move to dwz.c; change into
1583 method.
1584 (dwarf_decode_macro_bytes): Update.
1585 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
1586 * dwarf2/dwz.c: New file.
1587 * Makefile.in (COMMON_SFILES): Add dwz.c.
1588
1589 2020-03-26 Tom Tromey <tom@tromey.com>
1590
1591 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
1592 * dwarf2/read.c: Add include.
1593 * dwarf2/index-write.c: Add include.
1594 * dwarf2/index-cache.c: Add include.
1595 * dwarf2/dwz.h: New file.
1596
1597 2020-03-25 Tom Tromey <tom@tromey.com>
1598
1599 * compile/compile-object-load.c (get_out_value_type): Mention
1600 correct symbol name in error message.
1601
1602 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
1603
1604 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
1605
1606 2020-03-25 Tom de Vries <tdevries@suse.de>
1607
1608 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
1609 * symmisc.c (dump_symtab_1): Print user and includes fields.
1610 (maintenance_info_symtabs): Same.
1611
1612 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
1613
1614 PR gdb/25534
1615 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
1616 (riscv_regcache_cooked_write): New function.
1617 (riscv_push_dummy_call): Use new function.
1618 (riscv_return_value): Likewise.
1619
1620 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
1621
1622 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
1623 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
1624 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
1625 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
1626 * infrun.c (follow_fork): Likewise.
1627 (follow_fork_inferior): Likewise.
1628 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
1629 * linux-nat.h (class linux_nat_target): Likewise.
1630 * remote.c (class remote_target) <follow_fork>: Likewise.
1631 (remote_target::follow_fork): Likewise.
1632 * target-delegates.c: Re-generate.
1633 * target.c (default_follow_fork): Likewise.
1634 (target_follow_fork): Likewise.
1635 * target.h (struct target_ops) <follow_fork>: Likewise.
1636 (target_follow_fork): Likewise.
1637
1638 2020-03-24 Tom de Vries <tdevries@suse.de>
1639
1640 * psymtab.c (maintenance_info_psymtabs): Print user field.
1641
1642 2020-03-20 Tom Tromey <tromey@adacore.com>
1643
1644 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
1645 const.
1646 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
1647 const.
1648
1649 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
1650
1651 * ptrace.m4: Don't check for ptrace declaration.
1652 * config.in: Re-generate.
1653 * configure: Re-generate.
1654 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
1655 not defined.
1656
1657 2020-03-20 Kamil Rytarowski <n54@gmx.com>
1658
1659 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
1660 `PTRACE_TYPE_RET'.
1661 * i386-bsd-nat.c (gdb_ptrace): Likewise.
1662 * sparc-nat.c (gdb_ptrace): Likewise.
1663 * x86-bsd-nat.c (gdb_ptrace): Likewise.
1664
1665 2020-03-20 Tom Tromey <tromey@adacore.com>
1666
1667 * c-exp.y (lex_one_token): Fix assert.
1668
1669 2020-03-20 Tom Tromey <tromey@adacore.com>
1670
1671 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
1672 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
1673 strncpy call.
1674
1675 2020-03-20 Tom Tromey <tromey@adacore.com>
1676
1677 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
1678
1679 2020-03-20 Tom Tromey <tromey@adacore.com>
1680
1681 * ada-valprint.c (print_variant_part): Remove parameters; switch
1682 to value-based API.
1683 (print_field_values): Likewise.
1684 (ada_val_print_struct_union): Likewise.
1685 (ada_value_print_1): Update.
1686
1687 2020-03-20 Kamil Rytarowski <n54@gmx.com>
1688
1689 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
1690 nbsd_nat_target instead of inf_ptrace_target.
1691 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
1692 nbsd_nat_target.
1693
1694 2020-03-20 Kamil Rytarowski <n54@gmx.com>
1695
1696 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
1697 it to the ptrace call.
1698 * (store_registers): Likewise.
1699
1700 2020-03-20 Kamil Rytarowski <n54@gmx.com>
1701
1702 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
1703 it to the ptrace call.
1704 * (store_registers): Likewise.
1705
1706 2020-03-19 Luis Machado <luis.machado@linaro.org>
1707
1708 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
1709 valid, fetch vg value from ptrace.
1710
1711 2020-03-19 Kamil Rytarowski <n54@gmx.com>
1712 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
1713 * inf-ptrace.c: Likewise.
1714 * (gdb_ptrace): Add.
1715 * (inf_ptrace_target::resume): Update.
1716 * (inf_ptrace_target::xfer_partial): Likewise.
1717 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
1718 * (inf_ptrace_peek_poke): Update.
1719
1720 2020-03-19 Kamil Rytarowski <n54@gmx.com>
1721
1722 * x86-bsd-nat.c (gdb_ptrace): New.
1723 * (x86bsd_dr_set): Add new argument `ptid'.
1724 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
1725 x86bsd_dr_set_addr): Update.
1726
1727 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
1728
1729 * remote.c (remote_target::process_stop_reply): Handle events for
1730 all threads differently.
1731
1732 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
1733
1734 * completer.c (completion_tracker::remove_completion): Define new
1735 function.
1736 * completer.h (completion_tracker::remove_completion): Declare new
1737 function.
1738 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
1739 when adding a C++ function symbol.
1740
1741 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
1742
1743 * completer.c (completion_tracker::completion_hash_entry): Define
1744 new class.
1745 (advance_to_filename_complete_word_point): Call
1746 recompute_lowest_common_denominator.
1747 (completion_tracker::completion_tracker): Call discard_completions
1748 to setup the hash table.
1749 (completion_tracker::discard_completions): Allow for being called
1750 from the constructor, pass new equal function, and element deleter
1751 when constructing the hash table. Initialise new class member
1752 variables.
1753 (completion_tracker::maybe_add_completion): Remove use of
1754 m_entries_vec, and store more information into m_entries_hash.
1755 (completion_tracker::recompute_lcd_visitor): New function, most
1756 content taken from...
1757 (completion_tracker::recompute_lowest_common_denominator):
1758 ...here, this now just visits each item in the hash calling the
1759 above visitor.
1760 (completion_tracker::build_completion_result): Remove use of
1761 m_entries_vec, call recompute_lowest_common_denominator.
1762 * completer.h (completion_tracker::have_completions): Remove use
1763 of m_entries_vec.
1764 (completion_tracker::completion_hash_entry): Declare new class.
1765 (completion_tracker::recompute_lowest_common_denominator): Change
1766 function signature.
1767 (completion_tracker::recompute_lcd_visitor): Declare new function.
1768 (completion_tracker::m_entries_vec): Delete.
1769 (completion_tracker::m_entries_hash): Initialize to NULL.
1770 (completion_tracker::m_lowest_common_denominator_valid): New
1771 member variable.
1772 (completion_tracker::m_lowest_common_denominator_max_length): New
1773 member variable.
1774
1775 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1776
1777 * regformats/regdef.h: Put reg in gdb namespace.
1778
1779 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1780
1781 * i386-bsd-nat.c (gdb_ptrace): New.
1782 * (i386bsd_fetch_inferior_registers,
1783 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
1784 * (i386bsd_fetch_inferior_registers,
1785 i386bsd_store_inferior_registers) Use gdb_ptrace.
1786
1787 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1788
1789 * amd64-bsd-nat.c (gdb_ptrace): New.
1790 * (amd64bsd_fetch_inferior_registers,
1791 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
1792 * (amd64bsd_fetch_inferior_registers,
1793 amd64bsd_store_inferior_registers) Use gdb_ptrace.
1794
1795 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1796
1797 * user-regs.c (user_reg::read): Rename to...
1798 (user_reg::xread): ...this.
1799 * (append_user_reg): Rename argument `read' to `xread'.
1800 * (user_reg_add_builtin): Likewise.
1801 * (user_reg_add): Likewise.
1802 * (value_of_user_reg): Likewise.
1803
1804 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1805
1806 * sparc-nat.c (gdb_ptrace): New.
1807 * sparc-nat.c (sparc_fetch_inferior_registers)
1808 (sparc_store_inferior_registers) Remove obsolete comment.
1809 * sparc-nat.c (sparc_fetch_inferior_registers)
1810 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
1811 * sparc-nat.c (sparc_fetch_inferior_registers)
1812 (sparc_store_inferior_registers) Use gdb_ptrace.
1813
1814 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1815
1816 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
1817 it to the ptrace call.
1818 * sh-nbsd-nat.c (store_registers): Likewise.
1819
1820 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1821
1822 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
1823 nbsd_nat_target instead of inf_ptrace_target.
1824 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
1825 nbsd_nat_target.
1826
1827 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1828
1829 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
1830
1831 2020-03-17 Kamil Rytarowski <n54@gmx.com>
1832
1833 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
1834 <sys/sysctl.h>.
1835 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
1836
1837 2020-03-17 Tom de Vries <tdevries@suse.de>
1838
1839 PR gdb/23710
1840 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
1841 fields.
1842 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
1843 fields.
1844 (process_imported_unit_die): Skip import of c++ CUs.
1845
1846 2020-03-16 Tom Tromey <tom@tromey.com>
1847
1848 * p-valprint.c (pascal_object_print_value): Initialize
1849 base_value.
1850
1851 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
1852 Shahab Vahedi <shahab@synopsys.com>
1853
1854 * Makefile.in: Add arch/arc.o
1855 * configure.tgt: Likewise.
1856 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
1857 (_initialize_arc_tdep): Don't initialize old target descriptions.
1858 (arc_read_description): New function to cache target descriptions.
1859 * arc-tdep.h (arc_read_description): Add proto type.
1860 * arch/arc.c: New file.
1861 * arch/arc.h: Likewise.
1862 * features/Makefile: Replace old target descriptions with new.
1863 * features/arc-arcompact.c: Remove.
1864 * features/arc-arcompact.xml: Likewise.
1865 * features/arc-v2.c: Likewise
1866 * features/arc-v2.xml: Likewise
1867 * features/arc/aux-arcompact.xml: New file.
1868 * features/arc/aux-v2.xml: Likewise.
1869 * features/arc/core-arcompact.xml: Likewise.
1870 * features/arc/core-v2.xml: Likewise.
1871 * features/arc/aux-arcompact.c: Generate.
1872 * features/arc/aux-v2.c: Likewise.
1873 * features/arc/core-arcompact.c: Likewise.
1874 * features/arc/core-v2.c: Likewise.
1875 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
1876
1877 2020-03-16 Tom Tromey <tromey@adacore.com>
1878
1879 PR gdb/25663:
1880 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
1881 putting value into bcache.
1882
1883 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1884
1885 PR gdb/21500
1886 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
1887 to...
1888 (amd64_windows_init_abi_common): ... this. Don't set size of
1889 long type.
1890 (amd64_windows_init_abi): New function.
1891 (amd64_cygwin_init_abi): New function.
1892 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
1893 the Cygwin OS ABI.
1894 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
1895 comment.
1896
1897 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1898
1899 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
1900 * windows-tdep.c (CYGWIN_DLL_NAME): New.
1901 (pe_import_directory_entry): New struct type.
1902 (is_linked_with_cygwin_dll): New function.
1903 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
1904 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
1905 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
1906
1907 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1908
1909 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
1910 i386_cygwin_core_osabi_sniffer.
1911
1912 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1913
1914 * i386-cygwin-tdep.c: Rename to...
1915 * i386-windows-tdep.c: ... this.
1916 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
1917 i386-windows-tdep.c.
1918 * configure.tgt: Likewise.
1919
1920 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1921
1922 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
1923 * osabi.c (gdb_osabi_names): Add "Windows".
1924 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
1925 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
1926 (i386_cygwin_core_osabi_sniffer): New function, extracted from
1927 i386_cygwin_osabi_sniffer.
1928 (_initialize_i386_cygwin_tdep): Register OS ABI
1929 GDB_OSABI_WINDOWS for i386.
1930 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
1931 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
1932 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
1933 for x86-64.
1934 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
1935 when the target matches '*-*-mingw*'.
1936
1937 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1938
1939 * defs.h (enum gdb_osabi): Move to...
1940 * osabi.h (enum gdb_osabi): ... here.
1941 * gdbarch.sh: Include osabi.h in gdbarch.h.
1942 * gdbarch.h: Re-generate.
1943
1944 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
1945
1946 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
1947 function.
1948 (_initialize_amd64_windows_tdep): Register osabi sniffer.
1949
1950 2020-03-14 Tom Tromey <tom@tromey.com>
1951
1952 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
1953 for C++.
1954 (c_type_print_modifier): Likewise. Add "language" parameter.
1955 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
1956 (c_type_print_base_1): Update.
1957 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
1958 constants.
1959 * type-stack.c (type_stack::insert): Handle tp_atomic and
1960 tp_restrict.
1961 (type_stack::follow_type_instance_flags): Likewise.
1962 (type_stack::follow_types): Likewise. Merge type-following code.
1963 * c-exp.y (RESTRICT, ATOMIC): New tokens.
1964 (space_identifier, cv_with_space_id)
1965 (const_or_volatile_or_space_identifier_noopt)
1966 (const_or_volatile_or_space_identifier): Remove.
1967 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
1968 rules.
1969 (ptr_operator, typebase): Update.
1970 (enum token_flag) <FLAG_C>: New constant.
1971 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
1972 "_Atomic".
1973 (lex_one_token): Handle FLAG_C.
1974
1975 2020-03-14 Kamil Rytarowski <n54@gmx.com>
1976
1977 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
1978 it to the ptrace call.
1979 * m68k-bsd-nat.c (store_registers): Likewise.
1980
1981 2020-03-14 Kamil Rytarowski <n54@gmx.com>
1982
1983 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
1984 gdb_byte *.
1985 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
1986 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
1987 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
1988
1989 2020-03-14 Kamil Rytarowski <n54@gmx.com>
1990
1991 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
1992 nbsd_nat_target instead of inf_ptrace_target.
1993 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
1994 nbsd_nat_target.
1995
1996 2020-03-14 Kamil Rytarowski <n54@gmx.com>
1997
1998 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
1999 register_t.
2000
2001 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2002
2003 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
2004 it to the ptrace call.
2005 * alpha-bsd-nat.c (store_registers): Likewise.
2006
2007 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2008
2009 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
2010 includes.
2011 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
2012 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
2013 fill_fpregset): Likewise.
2014
2015 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2016
2017 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
2018 nbsd_nat_target instead of inf_ptrace_target.
2019 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
2020 nbsd_nat_target.
2021
2022 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2023
2024 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
2025 register_t.
2026
2027 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2028
2029 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
2030 it to the ptrace call.
2031 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
2032 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
2033 * arm-nbsd-nat.c (store_register): Likewise.
2034 * arm-nbsd-nat.c (store_regs): Likewise.
2035 * arm-nbsd-nat.c (store_fp_register): Likewise.
2036 * arm-nbsd-nat.c (store_fp_regs): Likewise.
2037
2038 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2039
2040 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
2041 nbsd_nat_target instead of inf_ptrace_target.
2042 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
2043 nbsd_nat_target.
2044
2045 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2046
2047 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
2048 it to the ptrace call.
2049 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
2050
2051 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2052
2053 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
2054 it to the ptrace call.
2055 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
2056
2057 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2058
2059 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
2060 gdb_byte *.
2061 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
2062
2063 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2064
2065 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
2066 instead of inf_ptrace_target.
2067 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
2068 nbsd_nat_target.
2069
2070 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2071
2072 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
2073 register_t.
2074
2075 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2076
2077 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
2078 register_t.
2079
2080 2020-03-14 Kamil Rytarowski <n54@gmx.com>
2081
2082 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
2083 register_t.
2084
2085 2020-03-13 Tom Tromey <tom@tromey.com>
2086
2087 * value.h (val_print): Don't declare.
2088 * valprint.h (val_print_array_elements)
2089 (val_print_scalar_formatted, generic_val_print): Don't declare.
2090 * valprint.c (generic_val_print_array): Take a struct value.
2091 (generic_val_print_ptr, generic_val_print_memberptr)
2092 (generic_val_print_bool, generic_val_print_int)
2093 (generic_val_print_char, generic_val_print_complex)
2094 (generic_val_print): Remove.
2095 (generic_value_print): Update.
2096 (do_val_print): Remove unused parameters. Don't call
2097 la_val_print.
2098 (val_print): Remove.
2099 (common_val_print): Update. Don't call value_check_printable.
2100 (val_print_scalar_formatted, val_print_array_elements): Remove.
2101 * rust-lang.c (rust_val_print): Remove.
2102 (rust_language_defn): Update.
2103 * p-valprint.c (pascal_val_print): Remove.
2104 (pascal_value_print_inner): Update.
2105 (pascal_object_print_val_fields, pascal_object_print_val):
2106 Remove.
2107 (pascal_object_print_static_field): Update.
2108 * p-lang.h (pascal_val_print): Don't declare.
2109 * p-lang.c (pascal_language_defn): Update.
2110 * opencl-lang.c (opencl_language_defn): Update.
2111 * objc-lang.c (objc_language_defn): Update.
2112 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
2113 * m2-lang.h (m2_val_print): Don't declare.
2114 * m2-lang.c (m2_language_defn): Update.
2115 * language.h (struct language_defn) <la_val_print>: Remove.
2116 * language.c (unk_lang_value_print_inner): Rename. Change
2117 argument types.
2118 (unknown_language_defn, auto_language_defn): Update.
2119 * go-valprint.c (go_val_print): Remove.
2120 * go-lang.h (go_val_print): Don't declare.
2121 * go-lang.c (go_language_defn): Update.
2122 * f-valprint.c (f_val_print): Remove.
2123 * f-lang.h (f_value_print): Don't declare.
2124 * f-lang.c (f_language_defn): Update.
2125 * d-valprint.c (d_val_print): Remove.
2126 * d-lang.h (d_value_print): Don't declare.
2127 * d-lang.c (d_language_defn): Update.
2128 * cp-valprint.c (cp_print_value_fields)
2129 (cp_print_value_fields_rtti, cp_print_value): Remove.
2130 (cp_print_static_field): Update.
2131 * c-valprint.c (c_val_print_array, c_val_print_ptr)
2132 (c_val_print_struct, c_val_print_union, c_val_print_int)
2133 (c_val_print_memberptr, c_val_print): Remove.
2134 * c-lang.h (c_val_print_array, cp_print_value_fields)
2135 (cp_print_value_fields_rtti): Don't declare.
2136 * c-lang.c (c_language_defn, cplus_language_defn)
2137 (asm_language_defn, minimal_language_defn): Update.
2138 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
2139 (ada_val_print_enum): Take a struct value.
2140 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
2141 (ada_val_print): Remove.
2142 (ada_value_print_1): Update.
2143 (printable_val_type): Remove.
2144 * ada-lang.h (ada_val_print): Don't declare.
2145 * ada-lang.c (ada_language_defn): Update.
2146
2147 2020-03-13 Tom Tromey <tom@tromey.com>
2148
2149 * valprint.c (do_val_print): Update.
2150 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
2151 a struct value.
2152 (value_to_value_object_no_release): Declare.
2153 * python/py-value.c (value_to_value_object_no_release): New
2154 function.
2155 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
2156 struct value.
2157 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
2158 function.
2159 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
2160 a struct value.
2161 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
2162 Declare.
2163 (gdbscm_apply_val_pretty_printer): Take a struct value.
2164 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
2165 value.
2166 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
2167 value.
2168 * extension-priv.h (struct extension_language_ops)
2169 <apply_val_pretty_printer>: Take a struct value.
2170 * cp-valprint.c (cp_print_value): Create a struct value.
2171 (cp_print_value): Update.
2172
2173 2020-03-13 Tom Tromey <tom@tromey.com>
2174
2175 * ada-valprint.c (print_field_values): Call common_val_print.
2176
2177 2020-03-13 Tom Tromey <tom@tromey.com>
2178
2179 * ada-valprint.c (val_print_packed_array_elements): Remove
2180 bitoffset and val parameters. Call common_val_print.
2181 (ada_val_print_string): Remove offset, address, and original_value
2182 parameters.
2183 (ada_val_print_array): Update.
2184 (ada_value_print_array): New function.
2185 (ada_value_print_1): Call it.
2186
2187 2020-03-13 Tom Tromey <tom@tromey.com>
2188
2189 * ada-valprint.c (ada_value_print): Use common_val_print.
2190
2191 2020-03-13 Tom Tromey <tom@tromey.com>
2192
2193 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
2194
2195 2020-03-13 Tom Tromey <tom@tromey.com>
2196
2197 * ada-valprint.c (ada_value_print_num): New function.
2198 (ada_value_print_1): Use it.
2199
2200 2020-03-13 Tom Tromey <tom@tromey.com>
2201
2202 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
2203
2204 2020-03-13 Tom Tromey <tom@tromey.com>
2205
2206 * ada-valprint.c (ada_value_print_ptr): New function.
2207 (ada_value_print_1): Use it.
2208
2209 2020-03-13 Tom Tromey <tom@tromey.com>
2210
2211 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
2212 call common_val_print.
2213 (ada_val_print_1): Update.
2214 (ada_value_print_1): New function.
2215 (ada_value_print_inner): Rewrite.
2216
2217 2020-03-13 Tom Tromey <tom@tromey.com>
2218
2219 * cp-valprint.c (cp_print_value_fields): Update.
2220 (cp_print_value): New function.
2221
2222 2020-03-13 Tom Tromey <tom@tromey.com>
2223
2224 * m2-valprint.c (m2_value_print_inner): Use
2225 cp_print_value_fields.
2226 * cp-valprint.c (cp_print_value_fields): New function.
2227 * c-valprint.c (c_value_print_struct): New function.
2228 (c_value_print_inner): Use c_value_print_struct.
2229 * c-lang.h (cp_print_value_fields): Declare.
2230
2231 2020-03-13 Tom Tromey <tom@tromey.com>
2232
2233 * c-valprint.c (c_value_print_array): New function.
2234 (c_value_print_inner): Use it.
2235
2236 2020-03-13 Tom Tromey <tom@tromey.com>
2237
2238 * c-valprint.c (c_value_print_memberptr): New function.
2239 (c_value_print_inner): Use it.
2240
2241 2020-03-13 Tom Tromey <tom@tromey.com>
2242
2243 * c-valprint.c (c_value_print_int): New function.
2244 (c_value_print_inner): Use it.
2245
2246 2020-03-13 Tom Tromey <tom@tromey.com>
2247
2248 * c-valprint.c (c_value_print_ptr): New function.
2249 (c_value_print_inner): Use it.
2250
2251 2020-03-13 Tom Tromey <tom@tromey.com>
2252
2253 * c-valprint.c (c_value_print_inner): Rewrite.
2254
2255 2020-03-13 Tom Tromey <tom@tromey.com>
2256
2257 * valprint.c (generic_value_print_complex): New function.
2258 (generic_value_print): Use it.
2259
2260 2020-03-13 Tom Tromey <tom@tromey.com>
2261
2262 * valprint.c (generic_val_print_float): Don't call
2263 val_print_scalar_formatted.
2264 (generic_val_print, generic_value_print): Update.
2265
2266 2020-03-13 Tom Tromey <tom@tromey.com>
2267
2268 * valprint.c (generic_value_print_char): New function
2269 (generic_value_print): Use it.
2270
2271 2020-03-13 Tom Tromey <tom@tromey.com>
2272
2273 * valprint.c (generic_value_print_int): New function.
2274 (generic_value_print): Use it.
2275
2276 2020-03-13 Tom Tromey <tom@tromey.com>
2277
2278 * valprint.c (generic_value_print_bool): New function.
2279 (generic_value_print): Use it.
2280
2281 2020-03-13 Tom Tromey <tom@tromey.com>
2282
2283 * valprint.c (generic_val_print_func): Simplify.
2284 (generic_val_print, generic_value_print): Update.
2285
2286 2020-03-13 Tom Tromey <tom@tromey.com>
2287
2288 * valprint.c (generic_val_print_flags): Remove.
2289 (generic_val_print, generic_value_print): Update.
2290 (val_print_type_code_flags): Add original_value parameter.
2291
2292 2020-03-13 Tom Tromey <tom@tromey.com>
2293
2294 * valprint.c (generic_val_print): Update.
2295 (generic_value_print): Update.
2296 * valprint.c (generic_val_print_enum): Don't call
2297 val_print_scalar_formatted.
2298
2299 2020-03-13 Tom Tromey <tom@tromey.com>
2300
2301 * valprint.c (generic_value_print): Call generic_value_print_ptr.
2302 * valprint.c (generic_value_print_ptr): New function.
2303
2304 2020-03-13 Tom Tromey <tom@tromey.com>
2305
2306 * valprint.c (generic_value_print): Rewrite.
2307
2308 2020-03-13 Tom Tromey <tom@tromey.com>
2309
2310 * p-valprint.c (pascal_object_print_value_fields)
2311 (pascal_object_print_value): New functions.
2312
2313 2020-03-13 Tom Tromey <tom@tromey.com>
2314
2315 * p-valprint.c (pascal_value_print_inner): Rewrite.
2316
2317 2020-03-13 Tom Tromey <tom@tromey.com>
2318
2319 * f-valprint.c (f_value_print_innner): Rewrite.
2320
2321 2020-03-13 Tom Tromey <tom@tromey.com>
2322
2323 * m2-valprint.c (m2_print_unbounded_array): New overload.
2324 (m2_print_unbounded_array): Update.
2325 (m2_print_array_contents): Take a struct value.
2326 (m2_value_print_inner): Rewrite.
2327
2328 2020-03-13 Tom Tromey <tom@tromey.com>
2329
2330 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
2331 (d_value_print_inner): New function.
2332 * d-lang.h (d_value_print_inner): Declare.
2333 * d-lang.c (d_language_defn): Use d_value_print_inner.
2334
2335 2020-03-13 Tom Tromey <tom@tromey.com>
2336
2337 * go-valprint.c (go_value_print_inner): New function.
2338 * go-lang.h (go_value_print_inner): Declare.
2339 * go-lang.c (go_language_defn): Use go_value_print_inner.
2340
2341 2020-03-13 Tom Tromey <tom@tromey.com>
2342
2343 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
2344 API.
2345 (rust_val_print): Rewrite.
2346 (rust_value_print_inner): New function, from rust_val_print.
2347 (rust_language_defn): Use rust_value_print_inner.
2348
2349 2020-03-13 Tom Tromey <tom@tromey.com>
2350
2351 * ada-valprint.c (ada_value_print_inner): New function.
2352 * ada-lang.h (ada_value_print_inner): Declare.
2353 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
2354
2355 2020-03-13 Tom Tromey <tom@tromey.com>
2356
2357 * f-valprint.c (f_value_print_innner): New function.
2358 * f-lang.h (f_value_print_innner): Declare.
2359 * f-lang.c (f_language_defn): Use f_value_print_innner.
2360
2361 2020-03-13 Tom Tromey <tom@tromey.com>
2362
2363 * p-valprint.c (pascal_value_print_inner): New function.
2364 * p-lang.h (pascal_value_print_inner): Declare.
2365 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
2366
2367 2020-03-13 Tom Tromey <tom@tromey.com>
2368
2369 * m2-valprint.c (m2_value_print_inner): New function.
2370 * m2-lang.h (m2_value_print_inner): Declare.
2371 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
2372
2373 2020-03-13 Tom Tromey <tom@tromey.com>
2374
2375 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
2376 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
2377 * c-valprint.c (c_value_print_inner): New function.
2378 * c-lang.h (c_value_print_inner): Declare.
2379 * c-lang.c (c_language_defn, cplus_language_defn)
2380 (asm_language_defn, minimal_language_defn): Use
2381 c_value_print_inner.
2382
2383 2020-03-13 Tom Tromey <tom@tromey.com>
2384
2385 * p-valprint.c (pascal_object_print_value_fields): Now static.
2386 * p-lang.h (pascal_object_print_value_fields): Don't declare.
2387
2388 2020-03-13 Tom Tromey <tom@tromey.com>
2389
2390 * c-valprint.c (c_val_print_array): Simplify.
2391
2392 2020-03-13 Tom Tromey <tom@tromey.com>
2393
2394 * valprint.c (value_print_array_elements): New function.
2395 * valprint.h (value_print_array_elements): Declare.
2396
2397 2020-03-13 Tom Tromey <tom@tromey.com>
2398
2399 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
2400 * mips-tdep.c (mips_print_register): Use
2401 value_print_scalar_formatted.
2402
2403 2020-03-13 Tom Tromey <tom@tromey.com>
2404
2405 * valprint.h (value_print_scalar_formatted): Declare.
2406 * valprint.c (value_print_scalar_formatted): New function.
2407
2408 2020-03-13 Tom Tromey <tom@tromey.com>
2409
2410 * valprint.h (generic_value_print): Declare.
2411 * valprint.c (generic_value_print): New function.
2412
2413 2020-03-13 Tom Tromey <tom@tromey.com>
2414
2415 * valprint.c (do_val_print): Call la_value_print_inner, if
2416 available.
2417 * rust-lang.c (rust_language_defn): Update.
2418 * p-lang.c (pascal_language_defn): Update.
2419 * opencl-lang.c (opencl_language_defn): Update.
2420 * objc-lang.c (objc_language_defn): Update.
2421 * m2-lang.c (m2_language_defn): Update.
2422 * language.h (struct language_defn) <la_value_print_inner>: New
2423 member.
2424 * language.c (unknown_language_defn, auto_language_defn): Update.
2425 * go-lang.c (go_language_defn): Update.
2426 * f-lang.c (f_language_defn): Update.
2427 * d-lang.c (d_language_defn): Update.
2428 * c-lang.c (c_language_defn, cplus_language_defn)
2429 (asm_language_defn, minimal_language_defn): Update.
2430 * ada-lang.c (ada_language_defn): Update.
2431
2432 2020-03-13 Tom Tromey <tom@tromey.com>
2433
2434 * c-valprint.c (c_value_print): Use common_val_print.
2435
2436 2020-03-13 Tom Tromey <tom@tromey.com>
2437
2438 * cp-valprint.c (cp_print_static_field): Use common_val_print.
2439
2440 2020-03-13 Tom Tromey <tom@tromey.com>
2441
2442 * f-valprint.c (f77_print_array_1, f_val_print): Use
2443 common_val_print.
2444
2445 2020-03-13 Tom Tromey <tom@tromey.com>
2446
2447 * riscv-tdep.c (riscv_print_one_register_info): Use
2448 common_val_print.
2449
2450 2020-03-13 Tom Tromey <tom@tromey.com>
2451
2452 * mi/mi-main.c (output_register): Use common_val_print.
2453
2454 2020-03-13 Tom Tromey <tom@tromey.com>
2455
2456 * infcmd.c (default_print_one_register_info): Use
2457 common_val_print.
2458
2459 2020-03-13 Tom Tromey <tom@tromey.com>
2460
2461 * valprint.h (common_val_print_checked): Declare.
2462 * valprint.c (common_val_print_checked): New function.
2463 * stack.c (print_frame_arg): Use common_val_print_checked.
2464
2465 2020-03-13 Tom Tromey <tom@tromey.com>
2466
2467 * valprint.c (do_val_print): New function, from val_print.
2468 (val_print): Use do_val_print.
2469 (common_val_print): Use do_val_print.
2470
2471 2020-03-13 Tom Tromey <tom@tromey.com>
2472
2473 * valprint.c (value_print): Use scoped_value_mark.
2474
2475 2020-03-13 Tom de Vries <tdevries@suse.de>
2476
2477 PR symtab/25646
2478 * psymtab.c (partial_symtab::partial_symtab): Don't set
2479 globals_offset and statics_offset. Push element onto
2480 current_global_psymbols and current_static_psymbols stacks.
2481 (concat): New function.
2482 (end_psymtab_common): Set globals_offset and statics_offset. Pop
2483 element from current_global_psymbols and current_static_psymbols
2484 stacks. Concat popped elements to global_psymbols and
2485 static_symbols.
2486 (add_psymbol_to_list): Use current_global_psymbols and
2487 current_static_psymbols stacks.
2488 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
2489 current_static_psymbols fields.
2490
2491 2020-03-12 Christian Biesinger <cbiesinger@google.com>
2492
2493 * corelow.c (sniff_core_bfd): Remove.
2494 (class core_target) <m_core_vec>: Remove.
2495 (core_target::core_target): Update.
2496 (core_file_fns): Remove.
2497 (deprecated_add_core_fns): Remove.
2498 (default_core_sniffer): Remove.
2499 (sniff_core_bfd): Remove.
2500 (default_check_format): Remove.
2501 (gdb_check_format): Remove.
2502 (core_target_open): Update.
2503 (core_target::get_core_register_section): Update.
2504 (get_core_registers_cb): Update.
2505 (core_target::fetch_registers): Update.
2506 * gdbcore.h (struct core_fns): Remove.
2507 (deprecated_add_core_fns): Remove.
2508 (default_core_sniffer): Remove.
2509 (default_check_format): Remove.
2510
2511 2020-03-12 Tom Tromey <tom@tromey.com>
2512
2513 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
2514 CORE_ADDR.
2515 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
2516
2517 2020-03-12 Tom Tromey <tom@tromey.com>
2518
2519 * remote.c (remote_target::download_tracepoint)
2520 (remote_target::enable_tracepoint)
2521 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
2522 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
2523 sprintf_vma.
2524
2525 2020-03-12 Tom Tromey <tom@tromey.com>
2526
2527 * symfile-mem.c: Update CORE_ADDR size assert.
2528
2529 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2530
2531 * selftest.m4: Move to gdbsupport/.
2532 * acinclude.m4: Update path to selftest.m4.
2533
2534 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2535
2536 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
2537 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
2538 gdbarch-selfselftests.c and selftest-arch.c.
2539 (SUBDIR_UNITTESTS_OBS): Rename to...
2540 (SELFTESTS_OBS): ... this.
2541 (COMMON_SFILES): Remove disasm-selftests.c and
2542 gdbarch-selftests.c.
2543 * configure.ac: Don't add selftest-arch.{c,o} to
2544 CONFIG_{SRCS,OBS}.
2545 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
2546 preprocessor conditions.
2547
2548 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2549
2550 * configure.ac: Don't source bfd/development.sh.
2551 * selftest.m4: Modify comment.
2552 * configure: Re-generate.
2553
2554 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
2555
2556 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
2557 not "true" or "false".
2558 * configure: Re-generate.
2559
2560 2020-03-12 Christian Biesinger <cbiesinger@google.com>
2561
2562 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
2563 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
2564 renamed to arm_nbsd_supply_gregset.
2565 (fetch_register): Update to call arm_nbsd_supply_gregset.
2566 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
2567 (arm_netbsd_nat_target::fetch_registers): Update.
2568 (fetch_elfcore_registers): Removed.
2569 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
2570 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
2571 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
2572 not require NetBSD system headers.
2573 (arm_nbsd_regset): New struct.
2574 (arm_nbsd_iterate_over_regset_sections): New function.
2575 (arm_netbsd_init_abi_common): Updated to call
2576 set_gdbarch_iterate_over_regset_sections.
2577 * arm-nbsd-tdep.h: New file.
2578
2579 2020-03-11 Kevin Buettner <kevinb@redhat.com>
2580
2581 * symtab.c (find_pc_sect_line): Add check which prevents infinite
2582 recursion.
2583
2584 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
2585
2586 * configure: Re-generate.
2587
2588 2020-03-11 Tom Tromey <tromey@adacore.com>
2589
2590 * ada-typeprint.c (print_choices): Fix comment.
2591
2592 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
2593
2594 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
2595 previous item in the list, when the list has no items.
2596
2597 2020-03-11 Tom de Vries <tdevries@suse.de>
2598
2599 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
2600 PROP_LOCLIST handling code.
2601
2602 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
2603
2604 * buildsym-legacy.c (record_line): Pass extra parameter to
2605 record_line.
2606 * buildsym.c (buildsym_compunit::record_line): Take an extra
2607 parameter, reduce duplication in the line table, and record the
2608 is_stmt flag in the line table.
2609 * buildsym.h (buildsym_compunit::record_line): Add extra
2610 parameter.
2611 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
2612 non-statement lines.
2613 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
2614 this to the symtab builder.
2615 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
2616 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
2617 through to dwarf_record_line_1.
2618 * infrun.c (process_event_stop_test): When stepping, don't stop at
2619 a non-statement instruction, and only refresh the step info when
2620 we land in the middle of a line's range. Also add an extra
2621 comment.
2622 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
2623 field.
2624 * record-btrace.c (btrace_find_line_range): Only record lines
2625 marked as is-statement.
2626 * stack.c (frame_show_address): Show the frame address if we are
2627 in a non-statement sal.
2628 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
2629 (maintenance_print_one_line_table): Print a header for the is_stmt
2630 column, and include is_stmt information in the output.
2631 * symtab.c (find_pc_sect_line): Find lines marked as statements in
2632 preference to non-statements.
2633 (find_pcs_for_symtab_line): Prefer is-statement entries.
2634 (find_line_common): Likewise.
2635 * symtab.h (struct linetable_entry): Add is_stmt field.
2636 (struct symtab_and_line): Likewise.
2637 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
2638 arranging the line table.
2639
2640 2020-03-07 Tom de Vries <tdevries@suse.de>
2641
2642 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
2643 DIE.
2644
2645 2020-03-07 Tom Tromey <tom@tromey.com>
2646
2647 * valops.c (value_literal_complex): Remove obsolete comment.
2648 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
2649 comment.
2650
2651 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
2652
2653 * infrun.h: Forward-declare thread_info.
2654 (set_step_info): Add thread_info parameter, add doc.
2655 * infrun.c (set_step_info): Add thread_info parameter, move doc
2656 to header.
2657 * infrun.c (process_event_stop_test): Pass thread to
2658 set_step_info call.
2659 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
2660 set_step_info.
2661 (prepare_one_step): Add thread_info parameter, pass it to
2662 set_step_frame and prepare_one_step (recursive) call.
2663 (step_1): Pass thread to prepare_one_step call.
2664 (step_command_fsm::should_stop): Pass thread to
2665 prepare_one_step.
2666 (until_next_fsm): Pass thread to set_step_frame call.
2667 (finish_command): Pass thread to set_step_info call.
2668
2669 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
2670
2671 * windows-tdep.c (windows_solib_create_inferior_hook):
2672 Check if inferior is running.
2673
2674 2020-03-06 Tom de Vries <tdevries@suse.de>
2675
2676 * NEWS: Fix "the the".
2677 * ctfread.c: Same.
2678
2679 2020-03-06 Tom de Vries <tdevries@suse.de>
2680
2681 * psymtab.c (psymtab_to_symtab): Don't print "done.".
2682
2683 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
2684
2685 * .dir-locals.el: Add a comment referencing the other copies of
2686 this file.
2687
2688 2020-03-05 John Baldwin <jhb@FreeBSD.org>
2689
2690 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
2691 psargs.
2692
2693 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2694
2695 * .gitattributes: New file.
2696
2697 2020-03-04 Tom Tromey <tom@tromey.com>
2698
2699 * symmisc.c (print_symbol_bcache_statistics)
2700 (print_objfile_statistics): Update.
2701 * symfile.c (allocate_symtab): Use intern.
2702 * psymtab.c (partial_symtab::partial_symtab): Use intern.
2703 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
2704 macro_cache>: Remove.
2705 <string_cache>: New member.
2706 (struct objfile) <intern>: New methods.
2707 * elfread.c (elf_symtab_read): Use intern.
2708 * dwarf2/read.c (fixup_go_packaging): Intern package name.
2709 (dwarf2_compute_name, dwarf2_physname)
2710 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
2711 names.
2712 (guess_partial_die_structure_name): Update.
2713 (partial_die_info::fixup): Intern name.
2714 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
2715 name.
2716 (dwarf2_name): Intern name. Update.
2717 * buildsym.c (buildsym_compunit::get_macro_table): Use
2718 string_cache.
2719
2720 2020-03-04 Tom Tromey <tom@tromey.com>
2721
2722 * jit.c (bfd_open_from_target_memory): Make "target" const.
2723 * corefile.c (gnutarget): Now const.
2724 * gdbcore.h (gnutarget): Now const.
2725
2726 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
2727
2728 * NEWS: Mention support for WOW64 processes.
2729 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
2730 (amd64_windows_segment_register_p): Remove static.
2731 (_initialize_amd64_windows_nat): Update.
2732 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
2733 * i386-windows-nat.c (context_offset): Update.
2734 (i386_mappings): Rename and remove static.
2735 (i386_windows_segment_register_p): Remove static.
2736 (_initialize_i386_windows_nat): Update.
2737 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
2738 (STATUS_WX86_SINGLE_STEP): New macro.
2739 (EnumProcessModulesEx): New macro.
2740 (Wow64SuspendThread): New macro.
2741 (Wow64GetThreadContext): New macro.
2742 (Wow64SetThreadContext): New macro.
2743 (Wow64GetThreadSelectorEntry): New macro.
2744 (windows_set_context_register_offsets): Add static.
2745 (windows_set_segment_register_p): Likewise.
2746 (windows_add_thread): Adapt for WOW64 processes.
2747 (windows_fetch_one_register): Likewise.
2748 (windows_nat_target::fetch_registers): Likewise.
2749 (windows_store_one_register): Likewise.
2750 (display_selector): Likewise.
2751 (display_selectors): Likewise.
2752 (handle_exception): Likewise.
2753 (windows_continue): Likewise.
2754 (windows_nat_target::resume): Likewise.
2755 (windows_add_all_dlls): Likewise.
2756 (do_initial_windows_stuff): Likewise.
2757 (windows_nat_target::attach): Likewise.
2758 (windows_get_exec_module_filename): Likewise.
2759 (windows_nat_target::create_inferior): Likewise.
2760 (windows_xfer_siginfo): Likewise.
2761 (_initialize_loadable): Initialize Wow64SuspendThread,
2762 Wow64GetThreadContext, Wow64SetThreadContext,
2763 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
2764 * windows-nat.h (windows_set_context_register_offsets):
2765 Remove declaration.
2766 (windows_set_segment_register_p): Likewise.
2767 (i386_windows_segment_register_p): Add declaration.
2768 (amd64_windows_segment_register_p): Likewise.
2769
2770 2020-03-04 Luis Machado <luis.machado@linaro.org>
2771
2772 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
2773 in "info registers" for AArch64/ARM.
2774
2775 The change caused "info registers" to not print GPR's.
2776
2777 gdb/ChangeLog:
2778
2779 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
2780
2781 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
2782 when reg->group is empty and reggroup is not.
2783
2784 2020-03-03 Tom Tromey <tromey@adacore.com>
2785
2786 * dwarf2/frame.c (struct dwarf2_frame_cache)
2787 <checked_tailcall_bottom, entry_cfa_sp_offset,
2788 entry_cfa_sp_offset_p>: Remove members.
2789 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
2790 (dwarf2_frame_prev_register): Don't call
2791 dwarf2_tailcall_sniffer_first.
2792 (dwarf2_append_unwinders): Don't append tailcall unwinder.
2793 * frame-unwind.c (add_unwinder): New fuction.
2794 (frame_unwind_init): Use it. Add tailcall unwinder.
2795
2796 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
2797 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
2798
2799 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
2800 value should be printed as true.
2801
2802 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
2803
2804 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
2805 (windows_init_abi): Set and use windows_so_ops.
2806
2807 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
2808
2809 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
2810 when verifying if dealing with a convenience variable.
2811
2812 2020-03-03 Luis Machado <luis.machado@linaro.org>
2813
2814 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
2815
2816 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
2817
2818 * infrun.c (gdbarch_supports_displaced_stepping): New.
2819 (use_displaced_stepping): Break up conditions in smaller pieces.
2820 Use gdbarch_supports_displaced_stepping.
2821 (displaced_step_prepare_throw): Use
2822 gdbarch_supports_displaced_stepping.
2823
2824 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2825
2826 * NEWS: Mention new behaviour of the history filename.
2827 * top.c (write_history_p): Add comment.
2828 (show_write_history_p): Add header comment, give a different
2829 message when history writing is on, but the history filename is
2830 empty.
2831 (history_filename): Add comment.
2832 (history_filename_empty): New function.
2833 (show_history_filename): Add header comment, give a different
2834 message when the filename is empty.
2835 (init_history): Compare history_filename against nullptr, and only
2836 read history if the filename is not empty.
2837 (set_history_filename): Add header comment, and only make
2838 non-empty filenames absolute.
2839 (init_main): Make the filename argument to 'set history filename'
2840 optional.
2841
2842 2020-03-02 Christian Biesinger <cbiesinger@google.com>
2843
2844 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
2845 (arm_supply_vfpregset): ...this, and update to use VFP registers.
2846 (fetch_fp_register): Update.
2847 (fetch_fp_regs): Update.
2848 (store_fp_register): Update.
2849 (store_fp_regs): Update.
2850 (arm_netbsd_nat_target::read_description): New function.
2851 (fetch_elfcore_registers): Update.
2852
2853 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
2854
2855 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
2856 general_thread if the stop reply is missing a thread-id.
2857 (remote_target::process_stop_reply): Use the first non-exited
2858 thread if the target didn't pass a thread-id.
2859 * infrun.c (do_target_wait): Move call to
2860 switch_to_inferior_no_thread to ....
2861 (do_target_wait_1): ... here.
2862
2863 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
2864
2865 * debuginfod-support.c: Include defs.h first.
2866
2867 2020-02-28 Tom de Vries <tdevries@suse.de>
2868
2869 * symfile.c (set_initial_language): Use default language for lookup.
2870
2871 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
2872
2873 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
2874 reader variable, pass `this` to read_cutu_die_from_dwo.
2875
2876 2020-02-27 Aaron Merey <amerey@redhat.com>
2877
2878 * source.c (open_source_file): Check for nullptr when computing
2879 srcpath.
2880
2881 2020-02-27 Tom Tromey <tromey@adacore.com>
2882
2883 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
2884 member.
2885 (dwarf2_add_field): Don't update nfields.
2886 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
2887
2888 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
2889
2890 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
2891 abs.
2892
2893 2020-02-26 Tom Tromey <tom@tromey.com>
2894
2895 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
2896 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
2897 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
2898 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
2899 per_cu_data.
2900
2901 2020-02-26 Tom Tromey <tom@tromey.com>
2902
2903 * dwarf2/index-write.c (psym_index_map): Change type.
2904 (add_address_entry_worker, write_one_signatured_type)
2905 (recursively_count_psymbols, recursively_write_psymbols)
2906 (class debug_names, psyms_seen_size, write_gdbindex)
2907 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
2908
2909 2020-02-26 Aaron Merey <amerey@redhat.com>
2910
2911 * Makefile.in: Handle optional debuginfod support.
2912 * NEWS: Update.
2913 * README: Add --with-debuginfod summary.
2914 * config.in: Regenerate.
2915 * configure: Regenerate.
2916 * configure.ac: Handle optional debuginfod support.
2917 * debuginfod-support.c: debuginfod helper functions.
2918 * debuginfod-support.h: Ditto.
2919 * doc/gdb.texinfo: Add --with-debuginfod to configure options
2920 summary.
2921 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
2922 when a dwz file cannot be found.
2923 * elfread.c (elf_symfile_read): Query debuginfod servers when a
2924 debuginfo file cannot be found.
2925 * source.c (open_source_file): Query debuginfod servers when a
2926 source file cannot be found.
2927 * top.c (print_gdb_configuration): Include
2928 --{with,without}-debuginfod in the output.
2929
2930 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
2931
2932 * thread.c (thr_try_catch_cmd): Print thread name.
2933
2934 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
2935
2936 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
2937 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2938 dwarf2_fetch_die_type_sect_off): Move to...
2939 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
2940 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2941 dwarf2_fetch_die_type_sect_off): ... here.
2942 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
2943 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2944 dwarf2_fetch_die_type_sect_off): Move doc to header file.
2945
2946 2020-02-26 Tom de Vries <tdevries@suse.de>
2947
2948 PR gdb/25603
2949 * symfile.c (set_initial_language): Exit-early if
2950 language_mode == language_mode_manual.
2951
2952 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
2953
2954 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
2955 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
2956 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
2957
2958 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
2959
2960 * gdbtypes.c (create_array_type_with_stride): Handle negative
2961 array strides.
2962 * valarith.c (value_subscripted_rvalue): Likewise.
2963
2964 2020-02-25 Luis Machado <luis.machado@linaro.org>
2965
2966 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
2967
2968 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
2969
2970 * loc.h (dwarf2_get_die_type): Move to...
2971 * read.h (dwarf2_get_die_type): ... here.
2972 * read.c (dwarf2_get_die_type): Move doc to header.
2973
2974 2020-02-25 Joel Brobecker <brobecker@adacore.com>
2975
2976 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
2977 'gnulib/Makefile.in' to the list.
2978
2979 2020-02-24 Tom Tromey <tom@tromey.com>
2980
2981 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
2982 Remove.
2983 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
2984 XOBNEWVEC.
2985
2986 2020-02-24 Tom Tromey <tom@tromey.com>
2987
2988 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
2989 New method.
2990 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
2991 (dw2_do_instantiate_symtab, dw2_get_file_names)
2992 (build_type_psymtab_dependencies, load_full_type_unit): Update.
2993
2994 2020-02-24 Tom Tromey <tom@tromey.com>
2995
2996 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
2997 make_scoped_restore.
2998 (dwarf2_psymtab::read_symtab): Don't clear
2999 reading_partial_symbols.
3000
3001 2020-02-24 Tom de Vries <tdevries@suse.de>
3002
3003 PR gdb/25592
3004 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
3005
3006 2020-02-24 Tom de Vries <tdevries@suse.de>
3007
3008 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
3009 commands layout next/prev/regs.
3010
3011 2020-02-22 Tom Tromey <tom@tromey.com>
3012
3013 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
3014 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
3015
3016 2020-02-22 Tom Tromey <tom@tromey.com>
3017
3018 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
3019
3020 2020-02-22 Tom Tromey <tom@tromey.com>
3021
3022 * tui/tui-win.c (_initialize_tui_win): Add usage text.
3023 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
3024 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
3025 * tui/tui.c (_initialize_tui): Add usage text.
3026
3027 2020-02-22 Tom Tromey <tom@tromey.com>
3028
3029 * tui/tui-win.c (tui_set_focus_command)
3030 (tui_set_win_height_command): Use error_no_arg.
3031 (_initialize_tui_win): Update help text.
3032 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
3033
3034 2020-02-22 Tom Tromey <tom@tromey.com>
3035
3036 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
3037 * tui/tui-disasm.h (struct tui_disasm_window)
3038 <display_start_addr>: Declare.
3039 * tui/tui-source.h (struct tui_source_window)
3040 <display_start_addr>: Declare.
3041 * tui/tui-winsource.h (struct tui_source_window_base)
3042 <show_source_line, display_start_addr>: New methods.
3043 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
3044 Rename and move to protected section.
3045 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
3046 (tui_source_window_base::do_erase_source_content): Update.
3047 (tui_source_window_base::show_source_line): Now a method.
3048 (tui_source_window_base::show_source_content)
3049 (tui_source_window_base::tui_source_window_base)
3050 (tui_source_window_base::rerender)
3051 (tui_source_window_base::refill)
3052 (tui_source_window_base::do_scroll_horizontal)
3053 (tui_source_window_base::set_is_exec_point_at)
3054 (tui_source_window_base::update_breakpoint_info)
3055 (tui_source_window_base::update_exec_info): Update.
3056 * tui/tui-source.c (tui_source_window::set_contents)
3057 (tui_source_window::showing_source_p)
3058 (tui_source_window::do_scroll_vertical)
3059 (tui_source_window::location_matches_p)
3060 (tui_source_window::line_is_displayed): Update.
3061 (tui_source_window::display_start_addr): New method.
3062 * tui/tui-disasm.c (tui_disasm_window::set_contents)
3063 (tui_disasm_window::do_scroll_vertical)
3064 (tui_disasm_window::location_matches_p): Update.
3065 (tui_disasm_window::display_start_addr): New method.
3066
3067 2020-02-22 Tom Tromey <tom@tromey.com>
3068
3069 * NEWS: Add entry for gdb.register_window_type.
3070 * tui/tui-layout.h (window_factory): New typedef.
3071 (tui_register_window): Declare.
3072 * tui/tui-layout.c (saved_tui_windows): New global.
3073 (tui_apply_current_layout): Use it.
3074 (tui_register_window): New function.
3075 * python/python.c (do_start_initialization): Call
3076 gdbpy_initialize_tui.
3077 (python_GdbMethods): Add "register_window_type" function.
3078 * python/python-internal.h (gdbpy_register_tui_window)
3079 (gdbpy_initialize_tui): Declare.
3080 * python/py-tui.c: New file.
3081 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
3082
3083 2020-02-22 Tom Tromey <tom@tromey.com>
3084
3085 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
3086
3087 2020-02-22 Tom Tromey <tom@tromey.com>
3088
3089 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
3090 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
3091 * tui/tui-data.c (tui_set_win_with_focus): Remove.
3092 (tui_set_win_focus_to): Move from tui-win.c.
3093
3094 2020-02-22 Tom Tromey <tom@tromey.com>
3095
3096 * tui/tui-layout.c (make_standard_window, get_locator_window): New
3097 functions.
3098 (known_window_types): New global.
3099 (tui_get_window_by_name): Reimplement.
3100 (initialize_known_windows): New function.
3101 (validate_window_name): Rewrite.
3102 (_initialize_tui_layout): Call initialize_known_windows.
3103
3104 2020-02-22 Tom Tromey <tom@tromey.com>
3105
3106 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
3107 Remove constants.
3108 * tui/tui-winsource.h (struct tui_source_window_base)
3109 <tui_source_window_base>: Remove parameter.
3110 * tui/tui-winsource.c
3111 (tui_source_window_base::tui_source_window_base): Remove
3112 parameter.
3113 (tui_source_window_base::refill): Update.
3114 * tui/tui-stack.h (struct tui_locator_window)
3115 <tui_locator_window>: Update.
3116 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
3117 Default the constructor.
3118 * tui/tui-regs.h (struct tui_data_item_window)
3119 <tui_data_item_window>: Default the constructor.
3120 (struct tui_data_window) <tui_data_window>: Likewise.
3121 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
3122 Default the constructor.
3123 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
3124 Default the constructor.
3125 <type>: Remove.
3126 (struct tui_win_info) <tui_win_info>: Default the constructor.
3127 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
3128 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
3129 Default the constructor.
3130
3131 2020-02-22 Tom Tromey <tom@tromey.com>
3132
3133 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
3134 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
3135 * tui/tui-win.c (tui_resize_all): Don't call
3136 tui_delete_invisible_windows.
3137 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
3138 done.
3139 (tui_set_layout): Update.
3140 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
3141 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
3142 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
3143
3144 2020-02-22 Tom Tromey <tom@tromey.com>
3145
3146 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
3147 correctly.
3148
3149 2020-02-22 Tom Tromey <tom@tromey.com>
3150
3151 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
3152
3153 2020-02-22 Tom Tromey <tom@tromey.com>
3154
3155 * tui/tui-winsource.h (struct tui_source_window_iterator)
3156 <inner_iterator>: New etytypedef.
3157 <tui_source_window_iterator>: Take "end" parameter.
3158 <tui_source_window_iterator>: Take iterator.
3159 <operator*, advance>: Update.
3160 <m_iter>: Change type.
3161 <m_end>: New field.
3162 (struct tui_source_windows) <begin, end>: Update.
3163 * tui/tui-layout.c (tui_windows): New global.
3164 (tui_apply_current_layout): Clear tui_windows.
3165 (tui_layout_window::apply): Update tui_windows.
3166 * tui/tui-data.h (tui_windows): Declare.
3167 (all_tui_windows): Now inline function.
3168 (class tui_window_iterator, struct all_tui_windows): Remove.
3169
3170 2020-02-22 Tom Tromey <tom@tromey.com>
3171
3172 PR tui/17850:
3173 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
3174 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
3175 "height" argument.
3176 (class tui_layout_window) <get_sizes>: Likewise.
3177 (class tui_layout_split) <tui_layout_split>: Add "vertical"
3178 argument.
3179 <get_sizes>: Add "height" argument.
3180 <m_vertical>: New field.
3181 * tui/tui-layout.c (tui_layout_split::clone): Update.
3182 (tui_layout_split::get_sizes): Add "height" argument.
3183 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
3184 (tui_new_layout_command): Parse "-horizontal".
3185 (_initialize_tui_layout): Update help string.
3186 (tui_layout_split::specification): Add "-horizontal" when needed.
3187 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
3188 argument.
3189 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
3190 New methods.
3191
3192 2020-02-22 Tom Tromey <tom@tromey.com>
3193
3194 * tui/tui-layout.h (enum tui_adjust_result): New.
3195 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
3196 (class tui_layout_window) <adjust_size>: Return
3197 tui_adjust_result. Rewrite.
3198 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
3199 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
3200
3201 2020-02-22 Tom Tromey <tom@tromey.com>
3202
3203 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
3204 parameter and return types.
3205 (class tui_layout_base) <specification>: Add "depth".
3206 (class tui_layout_window) <specification>: Add "depth".
3207 (class tui_layout_split) <specification>: Add "depth".
3208 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
3209 and return types.
3210 (tui_new_layout_command): Parse sub-layouts.
3211 (_initialize_tui_layout): Update help string.
3212 (tui_layout_window::specification): Add "depth".
3213 (add_layout_command): Update.
3214
3215 2020-02-22 Tom Tromey <tom@tromey.com>
3216
3217 * NEWS: Add "tui new-layout" item.
3218 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
3219 Add new-layout command to help text.
3220 (validate_window_name): New function.
3221 (tui_new_layout_command): New function.
3222 (_initialize_tui_layout): Register "new-layout".
3223 (tui_layout_window::specification): New method.
3224 (tui_layout_window::specification): New method.
3225 * tui/tui-layout.h (class tui_layout_base) <specification>: New
3226 method.
3227 (class tui_layout_window) <specification>: New method.
3228 (class tui_layout_split) <specification>: New method.
3229
3230 2020-02-22 Tom Tromey <tom@tromey.com>
3231
3232 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
3233 * tui/tui-win.c (window_name_completer): Update comment.
3234 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
3235 Declare method.
3236 (class tui_layout_window) <replace_window>: Likewise.
3237 (class tui_layout_split) <replace_window>: Likewise.
3238 (tui_set_layout): Don't declare.
3239 (tui_set_initial_layout): Declare function.
3240 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
3241 (asm_regs_layout): New globals.
3242 (tui_current_layout, show_layout): Remove.
3243 (tui_set_layout, tui_add_win_to_layout): Rewrite.
3244 (find_layout, tui_apply_layout): New function.
3245 (layout_completer): Remove.
3246 (tui_next_layout): Reimplement.
3247 (tui_next_layout_command): New function.
3248 (tui_set_initial_layout, tui_prev_layout_command): New functions.
3249 (tui_regs_layout): Reimplement.
3250 (tui_regs_layout_command): New function.
3251 (extract_display_start_addr): Rewrite.
3252 (next_layout, prev_layout): Remove.
3253 (tui_layout_window::replace_window): New method.
3254 (tui_layout_split::replace_window): New method.
3255 (destroy_layout): New function.
3256 (layout_list): New global.
3257 (add_layout_command): New function.
3258 (initialize_layouts): Update.
3259 (tui_layout_command): New function.
3260 (_initialize_tui_layout): Install "layout" commands.
3261 * tui/tui-data.h (enum tui_layout_type): Remove.
3262 (tui_current_layout): Don't declare.
3263
3264 2020-02-22 Tom Tromey <tom@tromey.com>
3265
3266 * tui/tui-regs.c (tui_reg_layout): Remove.
3267 (tui_reg_command): Use tui_regs_layout.
3268 * tui/tui-layout.h (tui_reg_command): Declare.
3269 * tui/tui-layout.c (tui_reg_command): New function.
3270
3271 2020-02-22 Tom Tromey <tom@tromey.com>
3272
3273 * tui/tui.c (tui_rl_delete_other_windows): Call
3274 tui_remove_some_windows.
3275 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
3276 Declare method.
3277 (class tui_layout_window) <remove_windows>: New method.
3278 (class tui_layout_split) <remove_windows>: Declare.
3279 (tui_remove_some_windows): Declare.
3280 * tui/tui-layout.c (tui_remove_some_windows): New function.
3281 (tui_layout_split::remove_windows): New method.
3282
3283 2020-02-22 Tom Tromey <tom@tromey.com>
3284
3285 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
3286 * tui/tui-layout.h (tui_next_layout): Declare.
3287 * tui/tui-layout.c (tui_next_layout): New function.
3288
3289 2020-02-22 Tom Tromey <tom@tromey.com>
3290
3291 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
3292 correct coordinates.
3293
3294 2020-02-22 Tom Tromey <tom@tromey.com>
3295
3296 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
3297 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
3298 DATA_WIN case.
3299
3300 2020-02-22 Tom Tromey <tom@tromey.com>
3301
3302 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
3303 TUI_DISASM_WIN, not tui_win_list.
3304
3305 2020-02-22 Tom Tromey <tom@tromey.com>
3306
3307 * valprint.c (generic_val_print_enum_1)
3308 (val_print_type_code_flags): Style member names.
3309 * rust-lang.c (val_print_struct, rust_print_enum)
3310 (rust_print_struct_def, rust_internal_print_type): Style member
3311 names.
3312 * p-valprint.c (pascal_object_print_value_fields): Style member
3313 names. Only call fprintf_symbol_filtered for static members.
3314 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
3315 * f-valprint.c (f_val_print): Style member names.
3316 * f-typeprint.c (f_type_print_base): Style member names.
3317 * cp-valprint.c (cp_print_value_fields): Style member names. Only
3318 call fprintf_symbol_filtered for static members.
3319 (cp_print_class_member): Style member names.
3320 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
3321 member names.
3322 * ada-valprint.c (ada_print_scalar): Style enum names.
3323 (ada_val_print_enum): Likewise.
3324 * ada-typeprint.c (print_enum_type): Style enum names.
3325
3326 2020-02-21 Tom Tromey <tom@tromey.com>
3327
3328 * psympriv.h (struct partial_symtab): Update comment.
3329
3330 2020-02-21 Tom Tromey <tromey@adacore.com>
3331
3332 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
3333 type is CORE_ADDR.
3334
3335 2020-02-21 Tom de Vries <tdevries@suse.de>
3336
3337 PR gdb/25534
3338 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
3339 if dependencies[i]->user != NULL.
3340
3341 2020-02-21 Ali Tamur <tamur@google.com>
3342
3343 * dwarf2/read.c (dwarf2_name): Add null check.
3344
3345 2020-02-20 Tom Tromey <tom@tromey.com>
3346
3347 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
3348 ">=", in binary search.
3349 (dwarf2_find_containing_comp_unit): New overload.
3350 (run_test): New self-test.
3351 (_initialize_dwarf2_read): Register new test.
3352
3353 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
3354
3355 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
3356 * riscv-tdep.h: Likewise.
3357 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
3358 rv32-only CSR.
3359 * features/riscv/64bit-csr.xml: Regenerated.
3360
3361 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
3362 Tom Tromey <tom@tromey.com>
3363
3364 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
3365 of 'fputc_unfiltered'.
3366 (putchar_unfiltered): Call 'fputc_unfiltered'.
3367 (fputc_unfiltered): Call 'fputs_unfiltered'.
3368
3369 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
3370
3371 * config.in: Regenerate.
3372 * configure: Regenerate.
3373 * configure.ac: Add --with-python-libdir option.
3374 * main.c: Use WITH_PYTHON_LIBDIR.
3375
3376 2020-02-19 Tom Tromey <tom@tromey.com>
3377
3378 * symtab.c (general_symbol_info::compute_and_set_names): Use
3379 obstack_strndup. Simplify call to symbol_set_demangled_name.
3380
3381 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
3382
3383 * dwarf2/read.c (allocate_signatured_type_table,
3384 allocate_dwo_unit_table, allocate_type_unit_groups_table,
3385 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
3386 Remove objfile parameter, update all callers.
3387
3388 2020-02-19 Doug Evans <dje@google.com>
3389
3390 PR rust/25535
3391 * rust-lang.c (rust_print_enum): Apply embedded_offset to
3392 rust_enum_variant calculation.
3393
3394 2020-02-19 Tom Tromey <tromey@adacore.com>
3395
3396 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
3397
3398 2020-02-19 Tom Tromey <tromey@adacore.com>
3399
3400 * ada-lang.c (cache_symbol): Use obstack_strdup.
3401
3402 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3403
3404 * configure: Regenerate.
3405
3406 2020-02-19 Tom Tromey <tromey@adacore.com>
3407
3408 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
3409 NULL check.
3410
3411 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
3412
3413 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
3414
3415 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
3416
3417 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
3418 if GDBSERVER is not defined.
3419 (riscv_tdesc_cache): Likewise, also store const target_desc.
3420 (STATIC_IN_GDB): Define.
3421 (riscv_create_target_description): Update declaration with
3422 STATIC_IN_GDB.
3423 (riscv_lookup_target_description): New function, only define if
3424 GDBSERVER is not defined.
3425 * arch/riscv.h (riscv_create_target_description): Declare only
3426 when GDBSERVER is defined.
3427 (riscv_lookup_target_description): New declaration when GDBSERVER
3428 is not defined.
3429 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
3430 (riscv_linux_read_features): ...this, and return
3431 riscv_gdbarch_features instead of target_desc.
3432 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
3433 (riscv_linux_read_description): Rename to...
3434 (riscv_linux_read_features): ...this.
3435 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
3436 Update to use riscv_gdbarch_features and
3437 riscv_lookup_target_description.
3438 * riscv-tdep.c (riscv_find_default_target_description): Use
3439 riscv_lookup_target_description instead of
3440 riscv_create_target_description.
3441
3442 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
3443
3444 * valprint.c (generic_val_print_enum_1): When printing a flag
3445 enum with value 0 and there is no enumerator with value 0, print
3446 just "0" instead of "(unknown: 0x0)".
3447
3448 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
3449
3450 * valprint.c (generic_val_print_enum_1): Print unknown part of
3451 flag enum in hex.
3452
3453 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
3454
3455 * dwarf2/read.c (update_enumeration_type_from_children): Allow
3456 flag enums to contain duplicate enumerators.
3457 * valprint.c (generic_val_print_enum_1): Update comment.
3458
3459 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
3460
3461 * dwarf2/read.c: Include "count-one-bits.h".
3462 (update_enumeration_type_from_children): If an enumerator has
3463 multiple bits set, don't treat the enumeration as a "flag enum".
3464 * valprint.c (generic_val_print_enum_1): Assert that enumerators
3465 of flag enums have 0 or 1 bit set.
3466
3467 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
3468
3469 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
3470 conversion.
3471 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
3472 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
3473 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
3474 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
3475 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
3476
3477 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
3478
3479 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
3480
3481 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
3482
3483 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
3484 displaced_step_closure_up.
3485 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
3486 (struct displaced_step_closure_up):
3487 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
3488 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
3489 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
3490 Likewise.
3491 * gdbarch.sh (displaced_step_copy_insn): Likewise.
3492 * gdbarch.c, gdbarch.h: Re-generate.
3493 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
3494 displaced_step_closure_up.
3495 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
3496 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
3497 * infrun.h (displaced_step_closure_up): New type alias.
3498 (struct displaced_step_inferior_state) <step_closure>: Change
3499 type to displaced_step_closure_up.
3500 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
3501 displaced_step_closure_up.
3502 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
3503
3504 2020-02-14 Tom Tromey <tom@tromey.com>
3505
3506 * minidebug.c (gnu_debug_key): New global.
3507 (find_separate_debug_file_in_section): Use it.
3508
3509 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
3510
3511 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
3512 std::unique_ptr.
3513 * gdbarch.c: Re-generate.
3514 * gdbarch.h: Re-generate.
3515 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
3516 change.
3517 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
3518 type to std::unique_ptr.
3519 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
3520 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
3521 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
3522 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
3523 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
3524 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
3525 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
3526 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
3527 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
3528
3529 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
3530
3531 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
3532 std::unique_ptr.
3533 (displaced_step_clear): Rename to...
3534 (displaced_step_reset): ... this. Just call displaced->reset ().
3535 (displaced_step_clear_cleanup): Rename to...
3536 (displaced_step_reset_cleanup): ... this.
3537 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
3538 (displaced_step_fixup): Likewise.
3539 (resume_1): Likewise.
3540 (handle_inferior_event): Restore child's memory before calling
3541 displaced_step_fixup on the parent.
3542 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
3543 to std::unique_ptr.
3544 <step_closure>: Change type to std::unique_ptr.
3545
3546 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
3547
3548 * arm-tdep.c: Include count-one-bits.h.
3549 (cleanup_block_store_pc): Use count_one_bits.
3550 (cleanup_block_load_pc): Use count_one_bits.
3551 (arm_copy_block_xfer): Use count_one_bits.
3552 (thumb2_copy_block_xfer): Use count_one_bits.
3553 (thumb_copy_pop_pc_16bit): Use count_one_bits.
3554 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
3555 (thumb_get_next_pcs_raw): Use count_one_bits.
3556 (arm_get_next_pcs_raw): Use count_one_bits_l.
3557 * arch/arm.c (bitcount): Remove.
3558 * arch/arm.h (bitcount): Remove.
3559
3560 2020-02-14 Tom Tromey <tromey@adacore.com>
3561
3562 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
3563 Update.
3564 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
3565 * dwarf2/loc.c (call_site_find_chain_1): Return
3566 unique_xmalloc_ptr.
3567 (call_site_find_chain): Likewise.
3568
3569 2020-02-14 Richard Biener <rguenther@suse.de>
3570
3571 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
3572 on expression with division operators.
3573
3574 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
3575
3576 * MAINTAINERS (Write After Approval): Adding myself.
3577
3578 2020-02-12 Tom Tromey <tom@tromey.com>
3579
3580 * event-loop.c (event_data, gdb_event, event_handler_func):
3581 Remove.
3582
3583 2020-02-12 Tom Tromey <tom@tromey.com>
3584
3585 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
3586 (dwarf2_frame_objfile_data): Add comment.
3587 (find_comp_unit, set_comp_unit): New functions.
3588 (dwarf2_frame_find_fde): Use find_comp_unit.
3589 (dwarf2_build_frame_info): Use set_comp_unit.
3590
3591 2020-02-12 Tom Tromey <tom@tromey.com>
3592
3593 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
3594 (comp_unit): Don't initialize objfile.
3595 (execute_cfa_program): Add text_offset parameter.
3596 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
3597 (dwarf2_frame_cache): Update.
3598 (dwarf2_build_frame_info): Don't set "objfile" member.
3599
3600 2020-02-12 Tom Tromey <tom@tromey.com>
3601
3602 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
3603 (decode_frame_entry): Likewise.
3604 (dwarf2_build_frame_info): Update.
3605
3606 2020-02-12 Tom Tromey <tom@tromey.com>
3607
3608 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
3609 (decode_frame_entry_1): Use the comp_unit obstack.
3610
3611 2020-02-12 Tom Tromey <tom@tromey.com>
3612
3613 * dwarf2/frame.c (struct comp_unit): Add initializers and
3614 constructor.
3615 (dwarf2_frame_objfile_data): Store a comp_unit.
3616 (dwarf2_frame_find_fde): Update.
3617 (dwarf2_build_frame_info): Use "new".
3618
3619 2020-02-12 Tom Tromey <tom@tromey.com>
3620
3621 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
3622 (dwarf2_fde_table): Typedef for std::vector.
3623 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
3624 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
3625 (decode_frame_entry): Update.
3626 (dwarf2_build_frame_info): Use "new".
3627
3628 2020-02-12 Christian Biesinger <cbiesinger@google.com>
3629
3630 * arm-tdep.c (arm_gdbarch_init): Update.
3631 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
3632 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
3633 have_neon, is_m>: Change to bool.
3634
3635 2020-02-12 Christian Biesinger <cbiesinger@google.com>
3636
3637 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
3638
3639 2020-02-12 Tom Tromey <tom@tromey.com>
3640
3641 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
3642
3643 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
3644
3645 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
3646 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
3647
3648 2020-02-11 Tom Tromey <tom@tromey.com>
3649
3650 * psymtab.h: Update comment.
3651
3652 2020-02-11 Tom Tromey <tom@tromey.com>
3653
3654 * gdb_obstack.h (struct auto_obstack): Use
3655 DISABLE_COPY_AND_ASSIGN.
3656
3657 2020-02-11 Tom Tromey <tom@tromey.com>
3658
3659 * dwarf2/frame.h (struct objfile): Don't forward declare.
3660
3661 2020-02-11 Christian Biesinger <cbiesinger@google.com>
3662
3663 * cris-tdep.c (cris_supply_gregset): Change signature to match
3664 what struct regset expects.
3665 (cris_regset): New struct.
3666 (fetch_core_registers): Remove.
3667 (cris_iterate_over_regset_sections): New function.
3668 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
3669 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
3670
3671 2020-02-11 Christian Biesinger <cbiesinger@google.com>
3672
3673 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
3674 registers.
3675
3676 2020-02-11 Christian Biesinger <cbiesinger@google.com>
3677
3678 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
3679
3680 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3681
3682 * configure: Re-generate.
3683
3684 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3685
3686 * configure: Re-generate.
3687
3688 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
3689
3690 * acinclude: Update warning.m4 path.
3691 * warning.m4: Move to gdbsupport.
3692
3693 2020-02-11 Tom Tromey <tromey@adacore.com>
3694
3695 * remote.c (remote_console_output): Update.
3696 * printcmd.c (printf_command): Update.
3697 * event-loop.c (gdb_wait_for_event): Update.
3698 * linux-nat.c (sigchld_handler): Update.
3699 * remote-sim.c (gdb_os_write_stdout): Update.
3700 (gdb_os_flush_stdout): Update.
3701 (gdb_os_flush_stderr): Update.
3702 (gdb_os_write_stderr): Update.
3703 * exceptions.c (print_exception): Update.
3704 * remote-fileio.c (remote_fileio_func_read): Update.
3705 (remote_fileio_func_write): Update.
3706 * tui/tui.c (tui_enable): Update.
3707 * tui/tui-interp.c (tui_interp::init): Update.
3708 * utils.c (init_page_info): Update.
3709 (putchar_unfiltered, fputc_unfiltered): Update.
3710 (gdb_flush): Update.
3711 (emit_style_escape): Update.
3712 (flush_wrap_buffer, fputs_maybe_filtered): Update.
3713 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
3714 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
3715 (stderr_file::write): Update.
3716 (stderr_file::puts): Update.
3717 * ui-file.h (ui_file_isatty, ui_file_write)
3718 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
3719 (ui_file_puts): Don't declare.
3720
3721 2020-02-10 Tom de Vries <tdevries@suse.de>
3722
3723 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
3724 sentinel to char *.
3725
3726 2020-02-09 Tom de Vries <tdevries@suse.de>
3727
3728 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
3729 filename if it matches "<artificial>".
3730
3731 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3732
3733 * windows-tdep.c (struct enum_value_name): New struct.
3734 (create_enum): New function.
3735 (windows_get_siginfo_type): Create and use enum types.
3736
3737 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
3738
3739 * NEWS: Mention $_siginfo support for Windows.
3740 * windows-nat.c (handle_exception): Set siginfo_er.
3741 (windows_nat_target::mourn_inferior): Reset siginfo_er.
3742 (windows_xfer_siginfo): New function.
3743 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
3744 * windows-tdep.c (struct windows_gdbarch_data): New struct.
3745 (init_windows_gdbarch_data): New function.
3746 (get_windows_gdbarch_data): New function.
3747 (windows_get_siginfo_type): New function.
3748 (windows_init_abi): Register windows_get_siginfo_type.
3749 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
3750
3751 2020-02-08 Tom Tromey <tom@tromey.com>
3752
3753 * dwarf2/read.c (class cutu_reader) <cutu_reader,
3754 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
3755 <keep>: Declare method.
3756 <m_keep>: Remove member.
3757 <~cutu_reader>: Remove.
3758 (cutu_reader::init_tu_and_read_dwo_dies): Update.
3759 (cutu_reader::cutu_reader): Update.
3760 (cutu_reader::keep): Rename from ~cutu_reader.
3761 (process_psymtab_comp_unit, build_type_psymtabs_1)
3762 (process_skeletonless_type_unit, load_partial_comp_unit)
3763 (load_full_comp_unit, dwarf2_read_addr_index)
3764 (read_signatured_type): Update.
3765
3766 2020-02-08 Tom Tromey <tom@tromey.com>
3767
3768 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
3769 "want_partial_unit" parameter.
3770 (process_psymtab_comp_unit): Change want_partial_unit to bool.
3771 Inline check for DW_TAG_partial_unit.
3772 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
3773
3774 2020-02-08 Tom Tromey <tom@tromey.com>
3775
3776 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
3777 read.c.
3778 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
3779 read.c.
3780
3781 2020-02-08 Tom Tromey <tom@tromey.com>
3782
3783 * dwarf2/read.c (read_address): Move to comp-unit.c.
3784 (dwarf2_rnglists_process, dwarf2_ranges_process)
3785 (read_attribute_value, dwarf_decode_lines_1)
3786 (var_decode_location, decode_locdesc): Update.
3787 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
3788 read.c. Remove "cu" parameter.
3789 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
3790 method.
3791
3792 2020-02-08 Tom Tromey <tom@tromey.com>
3793
3794 * dwarf2/read.c (read_attribute_value, read_indirect_string)
3795 (read_indirect_line_string): Update.
3796 * dwarf2/comp-unit.c (read_offset): Remove.
3797 (read_comp_unit_head): Update.
3798 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
3799 method.
3800 (read_offset): Don't declare.
3801
3802 2020-02-08 Tom Tromey <tom@tromey.com>
3803
3804 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
3805 * dwarf2/read.c (struct comp_unit_head): Move to
3806 dwarf2/comp-unit.h.
3807 (enum class rcuh_kind): Move to comp-unit.h.
3808 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
3809 (read_comp_unit_head, error_check_comp_unit_head)
3810 (read_and_check_comp_unit_head): Move to comp-unit.c.
3811 (read_offset, dwarf_unit_type_name): Likewise.
3812 (create_debug_type_hash_table, read_cutu_die_from_dwo)
3813 (cutu_reader::cutu_reader, read_call_site_scope)
3814 (find_partial_die, follow_die_offset): Update.
3815 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
3816
3817 2020-02-08 Tom Tromey <tom@tromey.com>
3818
3819 * dwarf2/read.c (read_offset_1): Move to leb.c.
3820 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
3821 (dwarf_decode_macro_bytes): Update.
3822 * dwarf2/leb.c (read_offset): Rename; move from read.c.
3823 * dwarf2/leb.h (read_offset): Declare.
3824
3825 2020-02-08 Tom Tromey <tom@tromey.com>
3826
3827 * dwarf2/read.c (dwarf2_section_size): Remove.
3828 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
3829 Update.
3830 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
3831
3832 2020-02-08 Tom Tromey <tom@tromey.com>
3833
3834 * dwarf2/read.c (read_initial_length): Move to leb.c.
3835 * dwarf2/leb.h (read_initial_length): Declare.
3836 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
3837 handle_nonstd parameter.
3838 * dwarf2/frame.c (read_initial_length): Remove.
3839 (decode_frame_entry_1): Update.
3840
3841 2020-02-08 Tom Tromey <tom@tromey.com>
3842
3843 * dwarf2/loc.c (dwarf2_find_location_expression)
3844 (dwarf_evaluate_loc_desc::get_tls_address)
3845 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
3846 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
3847 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
3848 (dwarf2_compile_property_to_c)
3849 (dwarf2_loc_desc_get_symbol_read_needs)
3850 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
3851 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
3852 (loclist_describe_location, loclist_tracepoint_var_ref)
3853 (loclist_generate_c_location): Update.
3854 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
3855 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
3856 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
3857 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
3858 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
3859 (dwarf2_per_cu_data::addr_size)
3860 (dwarf2_per_cu_data::ref_addr_size)
3861 (dwarf2_per_cu_data::text_offset)
3862 (dwarf2_per_cu_data::addr_type): Now methods.
3863 (per_cu_header_read_in): Make per_cu "const".
3864 (dwarf2_version): Remove.
3865 (dwarf2_per_cu_data::int_type): Now a method.
3866 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
3867 (set_die_type, read_array_type, read_subrange_index_type)
3868 (read_tag_string_type, read_subrange_type): Update.
3869 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
3870 offset_size, ref_addr_size, text_offset, addr_type, version,
3871 objfile, int_type, addr_sized_int_type>: Declare methods.
3872
3873 2020-02-08 Tom Tromey <tom@tromey.com>
3874
3875 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
3876 Move earlier.
3877
3878 2020-02-08 Tom Tromey <tom@tromey.com>
3879
3880 * dwarf2/read.h (dwarf_line_debug): Declare.
3881 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
3882 * dwarf2/read.c: Move line_header code to new files.
3883 (dwarf_line_debug): No longer static.
3884 * dwarf2/line-header.c: New file.
3885 * dwarf2/line-header.h: New file.
3886
3887 2020-02-08 Tom Tromey <tom@tromey.com>
3888
3889 * dwarf2/read.c (struct line_header) <file_full_name,
3890 file_file_name>: Return unique_xmalloc_ptr.
3891 (line_header::file_file_name): Update.
3892 (line_header::file_full_name): Update.
3893 (dw2_get_file_names_reader): Update.
3894 (macro_start_file): Update.
3895
3896 2020-02-08 Tom Tromey <tom@tromey.com>
3897
3898 * dwarf2/read.c (struct line_header) <file_full_name,
3899 file_file_name>: Declare methods.
3900 (dw2_get_file_names_reader): Update.
3901 (file_file_name): Now a method.
3902 (file_full_name): Likewise.
3903 (macro_start_file): Update.
3904
3905 2020-02-08 Tom Tromey <tom@tromey.com>
3906
3907 * dwarf2/read.c (dwarf_always_disassemble)
3908 (show_dwarf_always_disassemble): Move to loc.c.
3909 (_initialize_dwarf2_read): Move "always-disassemble" registration
3910 to loc.c.
3911 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
3912 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
3913 static.
3914 (show_dwarf_always_disassemble): Move from read.c.
3915 (_initialize_dwarf2loc): Move always-disassemble from read.c.
3916
3917 2020-02-08 Tom Tromey <tom@tromey.com>
3918
3919 * dwarf2/read.c (~dwarf2_per_objfile): Update.
3920 (create_quick_file_names_table): Return htab_up.
3921 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
3922 Update.
3923 * dwarf2/read.h (struct dwarf2_per_objfile)
3924 <quick_file_names_table>: Now htab_up.
3925
3926 2020-02-08 Tom Tromey <tom@tromey.com>
3927
3928 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
3929
3930 2020-02-08 Tom Tromey <tom@tromey.com>
3931
3932 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
3933 Rewrite.
3934 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
3935 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
3936 (abbrev_table::abbrev_table): No longer inline.
3937 (ABBREV_HASH_SIZE): Remove.
3938 (abbrev_table::m_abbrevs): Now an htab_up.
3939
3940 2020-02-08 Tom Tromey <tom@tromey.com>
3941
3942 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
3943 (cutu_reader): Update.
3944 (build_type_psymtabs_1): Update.
3945 * dwarf2/abbrev.c (abbrev_table::read): Rename.
3946 (abbrev_table::alloc_abbrev): Update.
3947 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
3948 (abbrev_table::read): New static method, renamed from
3949 abbrev_table_read_table.
3950 (abbrev_table::alloc_abbrev)
3951 (abbrev_table::add_abbrev): Now private.
3952 (abbrev_table::abbrev_table): Now private.
3953 (abbrev_table::m_abbrev_obstack): Now private. Rename.
3954
3955 2020-02-08 Tom Tromey <tom@tromey.com>
3956
3957 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
3958 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
3959 htab_up.
3960
3961 2020-02-08 Tom Tromey <tom@tromey.com>
3962
3963 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
3964 htab_up.
3965 (lookup_dwo_unit_in_dwp): Update.
3966 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
3967 on obstack.
3968
3969 2020-02-08 Tom Tromey <tom@tromey.com>
3970
3971 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
3972 obstack.
3973
3974 2020-02-08 Tom Tromey <tom@tromey.com>
3975
3976 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
3977 line_header_hash.
3978 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
3979 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
3980 Change type to htab_up.
3981
3982 2020-02-08 Tom Tromey <tom@tromey.com>
3983
3984 * dwarf2/read.c (allocate_type_unit_groups_table): Return
3985 htab_up. Don't allocate on obstack.
3986 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
3987 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
3988 Change type to htab_up.
3989
3990 2020-02-08 Tom Tromey <tom@tromey.com>
3991
3992 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
3993 Change type to htab_up.
3994 * dwarf2/read.c (create_signatured_type_table_from_index)
3995 (create_signatured_type_table_from_debug_names)
3996 (create_all_type_units, add_type_unit)
3997 (lookup_dwo_signatured_type, lookup_signatured_type)
3998 (process_skeletonless_type_unit): Update.
3999 (create_debug_type_hash_table, create_debug_types_hash_table):
4000 Change type of types_htab.
4001 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
4002 htab_up. Don't allocate on obstack.
4003 (create_cus_hash_table): Change type of cus_htab parameter.
4004 (struct dwo_file) <cus, tus>: Now htab_up.
4005 (lookup_dwo_signatured_type, lookup_dwo_cutu)
4006 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
4007 (queue_and_load_all_dwo_tus): Update.
4008 * dwarf2/index-write.c (write_gdbindex): Update.
4009 (write_debug_names): Update.
4010
4011 2020-02-08 Tom Tromey <tom@tromey.com>
4012
4013 * dwarf2/read.h (struct dwarf2_queue_item): Move from
4014 dwarf2/read.c. Remove "next" member. Add constructor ntad
4015 destructor.
4016 (struct dwarf2_per_objfile) <queue>: New member.
4017 * dwarf2/read.c (struct dwarf2_queue_item): Move to
4018 dwarf2/read.h.
4019 (dwarf2_queue, dwarf2_queue_tail): Remove.
4020 (class dwarf2_queue_guard): Add parameter to constructor. Use
4021 DISABLE_COPY_AND_ASSIGN.
4022 <m_per_objfile>: New member.
4023 <~dwarf2_queue_guard>: Rewrite.
4024 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
4025 Update.
4026 (~dwarf2_queue_item): New.
4027
4028 2020-02-08 Tom Tromey <tom@tromey.com>
4029
4030 * dwarf2/read.c (struct die_info) <has_children>: New member.
4031 (dw2_get_file_names_reader): Remove has_children.
4032 (dw2_get_file_names): Update.
4033 (read_cutu_die_from_dwo): Remove has_children.
4034 (cutu_reader::init_tu_and_read_dwo_dies)
4035 (cutu_reader::cutu_reader): Update.
4036 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
4037 Remove has_children.
4038 (build_type_psymtabs_1, process_skeletonless_type_unit)
4039 (load_partial_comp_unit, load_full_comp_unit): Update.
4040 (create_dwo_cu_reader): Remove has_children.
4041 (create_cus_hash_table, read_die_and_children): Update.
4042 (read_full_die_1,read_full_die): Remove has_children.
4043 (read_signatured_type): Update.
4044 (class cutu_reader) <has_children>: Remove.
4045
4046 2020-02-08 Tom Tromey <tom@tromey.com>
4047
4048 * dwarf2/expr.c: Rename from dwarf2expr.c.
4049 * dwarf2/expr.h: Rename from dwarf2expr.h.
4050 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
4051 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
4052 * dwarf2/frame.c: Rename from dwarf2-frame.c.
4053 * dwarf2/frame.h: Rename from dwarf2-frame.h.
4054 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
4055 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
4056 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
4057 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
4058 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
4059 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
4060 * dwarf2/loc.c: Rename from dwarf2loc.c.
4061 * dwarf2/loc.h: Rename from dwarf2loc.h.
4062 * dwarf2/read.c: Rename from dwarf2read.c.
4063 * dwarf2/read.h: Rename from dwarf2read.h.
4064 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
4065 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
4066 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
4067 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
4068 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
4069 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
4070 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
4071 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
4072 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
4073 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
4074 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
4075 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
4076 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
4077 Update.
4078 * Makefile.in (COMMON_SFILES): Update.
4079 (HFILES_NO_SRCDIR): Update.
4080
4081 2020-02-08 Tom Tromey <tom@tromey.com>
4082
4083 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
4084 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
4085
4086 2020-02-08 Tom Tromey <tom@tromey.com>
4087
4088 * dwarf2read.h (struct die_info): Don't declare.
4089
4090 2020-02-08 Tom Tromey <tom@tromey.com>
4091
4092 * dwarf2read.h (die_info_ptr): Remove typedef.
4093
4094 2020-02-08 Tom Tromey <tom@tromey.com>
4095
4096 * dwarf2read.c (read_call_site_scope)
4097 (handle_data_member_location, dwarf2_add_member_fn)
4098 (mark_common_block_symbol_computed, read_common_block)
4099 (attr_to_dynamic_prop, partial_die_info::read)
4100 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
4101 (dwarf2_symbol_mark_computed, set_die_type): Update.
4102 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
4103 method.
4104 (attr_form_is_block): Don't declare.
4105 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
4106
4107 2020-02-08 Tom Tromey <tom@tromey.com>
4108
4109 * dwarf2read.c (dwarf2_find_base_address, )
4110 (read_call_site_scope, rust_containing_type)
4111 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
4112 (handle_data_member_location, dwarf2_add_member_fn)
4113 (get_alignment, read_structure_type, process_structure_scope)
4114 (mark_common_block_symbol_computed, read_common_block)
4115 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
4116 (partial_die_info::read, read_attribute_value, new_symbol)
4117 (lookup_die_type, dwarf2_get_ref_die_offset)
4118 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
4119 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
4120 (dwarf2_symbol_mark_computed): Update.
4121 * dwarf2/attribute.h (struct attribute) <value_as_address,
4122 form_is_section_offset, form_is_constant, form_is_ref>: Declare
4123 methods.
4124 (value_as_address, attr_form_is_section_offset)
4125 (attr_form_is_constant, attr_form_is_ref): Don't declare.
4126 * dwarf2/attribute.c (attribute::value_as_address)
4127 (attribute::form_is_section_offset, attribute::form_is_constant)
4128 (attribute::form_is_ref): Now methods.
4129
4130 2020-02-08 Tom Tromey <tom@tromey.com>
4131
4132 * dwarf2read.c (struct attribute, DW_STRING)
4133 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
4134 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
4135 (attr_form_is_block, attr_form_is_section_offset)
4136 (attr_form_is_constant, attr_form_is_ref): Move.
4137 * dwarf2/attribute.h: New file.
4138 * dwarf2/attribute.c: New file, from dwarf2read.c.
4139 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
4140
4141 2020-02-08 Tom Tromey <tom@tromey.com>
4142
4143 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
4144 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
4145 Move.
4146 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
4147 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
4148 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
4149 abbrev.c.
4150 * dwarf2/abbrev.h: New file.
4151 * dwarf2/abbrev.c: New file, from dwarf2read.c.
4152 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
4153
4154 2020-02-08 Tom Tromey <tom@tromey.com>
4155
4156 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
4157 (dwarf2_section_size, dwarf2_get_section_info)
4158 (create_signatured_type_table_from_debug_names)
4159 (create_addrmap_from_aranges, read_debug_names_from_section)
4160 (get_gdb_index_contents_from_section, read_comp_unit_head)
4161 (error_check_comp_unit_head, read_abbrev_offset)
4162 (create_debug_type_hash_table, init_cu_die_reader)
4163 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
4164 (read_comp_units_from_section, create_cus_hash_table)
4165 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
4166 (create_dwp_v2_section, dwarf2_rnglists_process)
4167 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
4168 (abbrev_table_read_table, read_indirect_string_at_offset_from)
4169 (read_indirect_string_from_dwz, read_addr_index_1)
4170 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
4171 (dwarf_decode_macro_bytes, dwarf_decode_macros)
4172 (fill_in_loclist_baton): Update.
4173 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
4174 get_containing_section, get_bfd_owner, get_bfd_section,
4175 get_file_name, get_id, get_flags, empty, read>: Declare methods.
4176 (dwarf2_read_section, get_section_name, get_section_file_name)
4177 (get_containing_section, get_section_bfd_owner)
4178 (get_section_bfd_section, get_section_name, get_section_file_name)
4179 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
4180 declare.
4181 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
4182 (dwarf2_section_info::get_bfd_owner)
4183 (dwarf2_section_info::get_bfd_section)
4184 (dwarf2_section_info::get_name)
4185 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
4186 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
4187 (dwarf2_section_info::read): Now methods.
4188 * dwarf-index-write.c (class debug_names): Update.
4189
4190 2020-02-08 Tom Tromey <tom@tromey.com>
4191
4192 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
4193 Move to dwarf2/section.h.
4194 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
4195 (get_section_bfd_section, get_section_name)
4196 (get_section_file_name, get_section_id, get_section_flags)
4197 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
4198 dwarf2/section.c.
4199 * dwarf2/section.h: New file.
4200 * dwarf2/section.c: New file, from dwarf2read.c.
4201 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
4202
4203 2020-02-08 Tom Tromey <tom@tromey.com>
4204
4205 * dwarf2read.h (read_unsigned_leb128): Don't declare.
4206 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
4207 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
4208 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
4209 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
4210 * dwarf2/leb.h: New file, from dwarf2read.c.
4211 * dwarf2/leb.c: New file, from dwarf2read.c.
4212 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
4213 Remove.
4214 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
4215 (COMMON_SFILES): Add dwarf2/leb.c.
4216
4217 2020-02-08 Joel Brobecker <brobecker@adacore.com>
4218
4219 GDB 9.1 released.
4220
4221 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
4222
4223 PR gdb/25190:
4224 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
4225 * gdb/remote.c (remote_console_output): Update.
4226 * gdb/ui-file.c (fputs_unfiltered): Rename to...
4227 (ui_file_puts): ...this.
4228 * gdb/ui-file.h (ui_file_puts): Add declaration.
4229 * gdb/utils.c (emit_style_escape): Update.
4230 (flush_wrap_buffer): Update.
4231 (fputs_maybe_filtered): Update.
4232 (fputs_unfiltered): Add function.
4233
4234 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
4235
4236 * gdb/event-loop.c (gdb_wait_for_event): Update.
4237 * gdb/printcmd.c (printf_command): Update.
4238 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
4239 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
4240 (gdb_os_flush_stderr): Update.
4241 * gdb/remote.c (remote_console_output): Update.
4242 * gdb/ui-file.c (gdb_flush): Rename to...
4243 (ui_file_flush): ...this.
4244 (stderr_file::write): Update.
4245 (stderr_file::puts): Update.
4246 * gdb/ui-file.h (gdb_flush): Rename to...
4247 (ui_file_flush): ...this.
4248 * gdb/utils.c (gdb_flush): Add function.
4249 * gdb/utils.h (gdb_flush): Add declaration.
4250
4251 2020-02-07 Tom Tromey <tromey@adacore.com>
4252
4253 PR breakpoints/24915:
4254 * source.c (find_and_open_source): Do not check basenames_may_differ.
4255
4256 2020-02-07 Tom Tromey <tom@tromey.com>
4257
4258 * README: Update gdbserver documentation.
4259 * gdbserver: Move to top level.
4260 * configure.tgt (build_gdbserver): Remove.
4261 * configure.ac: Remove --enable-gdbserver.
4262 * configure: Rebuild.
4263 * Makefile.in (distclean): Don't mention gdbserver.
4264
4265 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
4266
4267 * source-cache.c (source_cache::ensure): Surround
4268 get_plain_source_lines with a try/catch.
4269 (source_cache::get_line_charpos): Get rid of try/catch
4270 and only check for the return value of "ensure".
4271 * tui/tui-source.c (tui_source_window::set_contents):
4272 Simplify "nlines" calculation.
4273
4274 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
4275
4276 * MAINTAINERS (Write After Approval): Add myself.
4277
4278 2020-02-05 Christian Biesinger <cbiesinger@google.com>
4279
4280 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
4281 function call.
4282
4283 2020-02-05 Christian Biesinger <cbiesinger@google.com>
4284
4285 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
4286
4287 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
4288
4289 * nat/riscv-linux-tdesc.h: New file.
4290 * nat/riscv-linux-tdesc.c: New file, taking code from...
4291 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
4292 ... here.
4293 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
4294 NATDEPFILES.
4295
4296 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
4297
4298 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
4299 we don't set the fake simulator ptid to the null_ptid.
4300
4301 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
4302
4303 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
4304 * gdbthread.h (class thread_info) <resumed>: Likewise.
4305 * infrun.c (resume_1): Likewise.
4306 (proceed): Likewise.
4307 (infrun_thread_stop_requested): Likewise.
4308 (stop_all_threads): Likewise.
4309 (handle_inferior_event): Likewise.
4310 (restart_threads): Likewise.
4311 (finish_step_over): Likewise.
4312 (keep_going_stepped_thread): Likewise.
4313 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
4314 (linux_handle_extended_wait): Likewise.
4315 * record-btrace.c (get_thread_current_frame_id): Likewise.
4316 * record-full.c (record_full_wait_1): Likewise.
4317 * remote.c (remote_target::process_initial_stop_replies): Likewise.
4318 * target.c (target_resume): Likewise.
4319 * thread.c (set_running_thread): Likewise.
4320
4321 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
4322
4323 * f-valprint.c (f77_print_array_1): Changed datatype of index
4324 variable to LONGEST from int to enable it to contain bound
4325 values correctly.
4326
4327 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
4328
4329 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
4330 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
4331 offsets according to FLEN determined.
4332 (riscv_linux_nat_target::read_description): Determine FLEN
4333 dynamically.
4334 (riscv_linux_nat_target::fetch_registers): Size regset buffer
4335 according to FLEN determined.
4336 (riscv_linux_nat_target::store_registers): Likewise.
4337
4338 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
4339
4340 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
4341 when reg->group is empty and reggroup is not.
4342
4343 2020-01-31 Tom Tromey <tromey@adacore.com>
4344
4345 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
4346 Call beneath target's mourn_inferior after unpushing.
4347
4348 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
4349
4350 PR tui/9765
4351 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
4352 have enough lines to fill the screen, still return the lowest
4353 address we found.
4354
4355 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
4356
4357 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
4358 '-', '<', and '>' commands.
4359
4360 2020-01-29 Pedro Alves <palves@redhat.com>
4361 Sergio Durigan Junior <sergiodj@redhat.com>
4362
4363 * infcmd.c (construct_inferior_arguments): Assert that
4364 'argc' is greater than 0.
4365
4366 2020-01-29 Luis Machado <luis.machado@linaro.org>
4367
4368 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
4369 (BRK_INSN_MASK): Define to 0xd4200000.
4370 (aarch64_program_breakpoint_here_p): New function.
4371 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
4372 * arch-utils.c (default_program_breakpoint_here_p): Moved from
4373 breakpoint.c.
4374 * arch-utils.h (default_program_breakpoint_here_p): Moved from
4375 breakpoint.h
4376 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
4377 call gdbarch_program_breakpoint_here_p.
4378 (program_breakpoint_here): Moved to arch-utils.c, renamed to
4379 default_program_breakpoint_here_p, changed return type to bool and
4380 simplified.
4381 * breakpoint.h (program_breakpoint_here): Moved prototype to
4382 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
4383 return type to bool.
4384 * gdbarch.c: Regenerate.
4385 * gdbarch.h: Regenerate.
4386 * gdbarch.sh (program_breakpoint_here_p): New method.
4387 * infrun.c (handle_signal_stop): Call
4388 gdbarch_program_breakpoint_here_p.
4389
4390 2020-01-26 Tom Tromey <tom@tromey.com>
4391
4392 * ctfread.c (struct ctf_fp_info): Reindent.
4393 (_initialize_ctfread): Remove.
4394
4395 2020-01-26 Tom Tromey <tom@tromey.com>
4396
4397 * psymtab.c (partial_map_expand_apply)
4398 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
4399 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
4400 (psym_print_stats, psym_expand_symtabs_for_function)
4401 (psym_map_symbol_filenames, psym_map_matching_symbols)
4402 (psym_expand_symtabs_matching)
4403 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
4404 (maintenance_check_psymtabs): Use new methods.
4405 * psympriv.h (struct partial_symtab) <readin_p,
4406 get_compunit_symtab>: New methods.
4407 <readin, compunit_symtab>: Remove members.
4408 (struct standard_psymtab): New.
4409 (struct legacy_psymtab): Derive from standard_psymtab.
4410 * dwarf2read.h (struct dwarf2_psymtab): Derive from
4411 standard_psymtab.
4412 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
4413
4414 2020-01-26 Tom Tromey <tom@tromey.com>
4415
4416 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
4417 read_dependencies. Add assert.
4418 * psymtab.c (partial_symtab::read_dependencies): New method.
4419 * psympriv.h (struct partial_symtab) <read_dependencies>: New
4420 method.
4421 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
4422 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
4423 read_dependencies.
4424 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
4425 Add assert.
4426
4427 2020-01-26 Tom Tromey <tom@tromey.com>
4428
4429 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
4430 Call expand_psymtab.
4431 (xcoff_read_symtab): Call expand_psymtab.
4432 (xcoff_start_psymtab, xcoff_end_psymtab): Set
4433 legacy_expand_psymtab.
4434 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
4435 method.
4436 (struct legacy_psymtab) <expand_psymtab>: Implement.
4437 <legacy_expand_psymtab>: New member.
4438 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
4439 (parse_partial_symbols): Set legacy_expand_psymtab.
4440 (psymtab_to_symtab_1): Change argument order. Call
4441 expand_psymtab.
4442 (new_psymtab): Set legacy_expand_psymtab.
4443 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
4444 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
4445 expand_psymtab.
4446 (dwarf2_psymtab::expand_psymtab): Rename from
4447 psymtab_to_symtab_1. Call expand_psymtab.
4448 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
4449 (dbx_end_psymtab): Likewise.
4450 (dbx_psymtab_to_symtab_1): Change argument order. Call
4451 expand_psymtab.
4452 (dbx_read_symtab): Call expand_psymtab.
4453 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
4454 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
4455 (ctf_psymtab::read_symtab): Call expand_psymtab.
4456
4457 2020-01-26 Tom Tromey <tom@tromey.com>
4458
4459 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
4460 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
4461 messages.
4462 * mdebugread.c (mdebug_read_symtab): Remove prints.
4463 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
4464 assert.
4465 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
4466
4467 2020-01-26 Tom Tromey <tom@tromey.com>
4468
4469 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
4470 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
4471 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
4472 legacy_symtab.
4473 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
4474 * psymtab.c (psymtab_to_symtab): Call method.
4475 (dump_psymtab): Update.
4476 * psympriv.h (struct partial_symtab): Add virtual destructor.
4477 <read_symtab>: New method.
4478 (struct legacy_symtab): New.
4479 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
4480 (struct pst_map) <pst>: Now a legacy_psymtab.
4481 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
4482 (new_psymtab): Use legacy_psymtab.
4483 * dwarf2read.h (struct dwarf2_psymtab): New.
4484 (struct dwarf2_per_cu_data) <psymtab>: Use it.
4485 * dwarf2read.c (dwarf2_create_include_psymtab)
4486 (dwarf2_build_include_psymtabs, create_type_unit_group)
4487 (create_partial_symtab, process_psymtab_comp_unit_reader)
4488 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
4489 (set_partial_user): Use dwarf2_psymtab.
4490 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
4491 (psymtab_to_symtab_1, process_full_comp_unit)
4492 (process_full_type_unit, dwarf2_ranges_read)
4493 (dwarf2_get_pc_bounds, psymtab_include_file_name)
4494 (dwarf_decode_lines): Use dwarf2_psymtab.
4495 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
4496 (add_address_entry_worker, write_one_signatured_type)
4497 (recursively_count_psymbols, recursively_write_psymbols)
4498 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
4499 (write_debug_names): Likewise.
4500 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
4501 <pst>: Now a legacy_psymtab.
4502 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
4503 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
4504 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
4505 * ctfread.c (struct ctf_psymtab): New.
4506 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
4507 ctf_psymtab.
4508 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
4509 (create_partial_symtab): Return a ctf_psymtab.
4510 (scan_partial_symbols): Update.
4511
4512 2020-01-26 Tom Tromey <tom@tromey.com>
4513
4514 * xcoffread.c (xcoff_start_psymtab): Use new.
4515 * psymtab.c (partial_symtab::partial_symtab): New constructor,
4516 renamed from start_psymtab_common.
4517 * psympriv.h (struct partial_symtab): Add new constructor.
4518 (start_psymtab_common): Don't declare.
4519 * mdebugread.c (parse_partial_symbols): Use new.
4520 * dwarf2read.c (create_partial_symtab): Use new.
4521 * dbxread.c (start_psymtab): Use new.
4522 * ctfread.c (create_partial_symtab): Use new.
4523
4524 2020-01-26 Tom Tromey <tom@tromey.com>
4525
4526 * xcoffread.c (xcoff_end_psymtab): Use new.
4527 * psymtab.c (start_psymtab_common): Use new.
4528 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
4529 Update.
4530 * psympriv.h (struct partial_symtab): Add parameters to
4531 constructor. Don't inline.
4532 (allocate_psymtab): Don't declare.
4533 * mdebugread.c (new_psymtab): Use new.
4534 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
4535 * dbxread.c (dbx_end_psymtab): Use new.
4536
4537 2020-01-26 Tom Tromey <tom@tromey.com>
4538
4539 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
4540 allocate_psymtab. Update documentation.
4541 * psymtab.c (psymtab_storage::install_psymtab): Rename from
4542 allocate_psymtab. Do not use new.
4543 (allocate_psymtab): Use new. Update.
4544
4545 2020-01-26 Tom Tromey <tom@tromey.com>
4546
4547 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
4548 * psymtab.c (psym_print_stats): Update.
4549 * psympriv.h (struct partial_symtab) <readin,
4550 psymtabs_addrmap_supported, anonymous>: Now bool.
4551 * mdebugread.c (psymtab_to_symtab_1): Update.
4552 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
4553 (build_type_psymtabs_reader, psymtab_to_symtab_1)
4554 (process_full_comp_unit, process_full_type_unit): Update.
4555 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
4556 * ctfread.c (psymtab_to_symtab): Update.
4557
4558 2020-01-26 Tom Tromey <tom@tromey.com>
4559
4560 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
4561 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
4562 * psymtab.c (psymtab_storage): Delete psymtabs.
4563 (psymtab_storage::allocate_psymtab): Use new.
4564 (psymtab_storage::discard_psymtab): Use delete.
4565 * psympriv.h (struct partial_symtab): Add constructor and
4566 initializers.
4567
4568 2020-01-26 Tom Tromey <tom@tromey.com>
4569
4570 * machoread.c: Do not include psympriv.h.
4571
4572 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4573
4574 * NEWS: Mention the new option and the set/show commands.
4575
4576 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4577
4578 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
4579 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
4580 (validate_exec_file): New variables, enums, functions.
4581 (exec_file_locate_attach, print_section_info): Style the filenames.
4582 (_initialize_exec): Install show_exec_file_mismatch_command and
4583 set_exec_file_mismatch_command.
4584 * gdbcore.h (validate_exec_file): Declare.
4585 * infcmd.c (attach_command): Call validate_exec_file.
4586 * remote.c ( remote_target::remote_add_inferior): Likewise.
4587
4588 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
4589
4590 * frame.c (find_frame_sal): Move call to get_next_frame into more
4591 inner scope.
4592 * inline-frame.c (inilne_state) <inline_state>: Update argument
4593 types.
4594 (inilne_state) <skipped_symbol>: Rename to...
4595 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
4596 (skip_inline_frames): Build vector of skipped symbols and use this
4597 to reate the inline_state.
4598 (inline_skipped_symbol): Add a comment and some assertions, fetch
4599 skipped symbol from the list.
4600
4601 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
4602
4603 * buildsym.c (lte_is_less_than): Delete.
4604 (buildsym_compunit::end_symtab_with_blockvector): Create local
4605 lambda function to sort line table entries, and use
4606 std::stable_sort instead of std::sort.
4607 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
4608 markers when looking for a previous line.
4609
4610 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
4611
4612 * dwarf2read.c (lnp_state_machine::record_line): Include
4613 end_sequence parameter in debug print out. Record the line if we
4614 are at an end_sequence marker even if it's not the start of a
4615 statement.
4616 * symmisc.c (maintenance_print_one_line_table): Print end of
4617 sequence markers with 'END' not '0'.
4618
4619 2020-01-24 Pedro Alves <palves@redhat.com>
4620
4621 PR gdb/25410
4622 * thread.c (scoped_restore_current_thread::restore): Use
4623 switch_to_inferior_no_thread.
4624 * exec.c: Include "progspace-and-thread.h".
4625 (add_target_sections, remove_target_sections):
4626 scoped_restore_current_pspace_and_thread instead of
4627 scoped_restore_current_thread.
4628 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
4629 and aspace to the inferior before calling clone_program_space.
4630 Remove stale comment.
4631
4632 2020-01-24 Christian Biesinger <cbiesinger@google.com>
4633
4634 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
4635 (arm_netbsd_nat_target::fetch_registers): ...this.
4636 (arm_nbsd_nat_target::store_registers): Rename to...
4637 (arm_netbsd_nat_target::store_registers): ...this.
4638
4639 2020-01-24 Christian Biesinger <cbiesinger@google.com>
4640
4641 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
4642 register_t.
4643
4644 2020-01-24 Christian Biesinger <cbiesinger@google.com>
4645
4646 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
4647 Update comment.
4648 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
4649 Likewise.
4650 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
4651 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
4652 the correct replacement (iterate_over_regset_sections).
4653 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
4654 Update comment.
4655
4656 2020-01-24 Graham Markall <graham.markall@embecosm.com>
4657
4658 PR gdb/23718
4659 * gdb/python/python.c (execute_gdb_command): Call
4660 async_enable_stdin in catch block.
4661
4662 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
4663
4664 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
4665 SWITCH_THRU_ALL_UIS.
4666
4667 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
4668
4669 PR tui/9765
4670 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
4671 comment, add extra parameter, and update to store previous symbol
4672 when appropriate.
4673 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
4674 add extra parameter.
4675 * tui/tui-disasm.c (tui_disassemble): Update header comment,
4676 remove unneeded parameter, add try/catch around gdb_print_insn,
4677 rewrite to add items to asm_lines vector.
4678 (tui_find_backward_disassembly_start_address): New function.
4679 (tui_find_disassembly_address): Updated throughout.
4680 (tui_disasm_window::set_contents): Update for changes to
4681 tui_disassemble.
4682 (tui_disasm_window::do_scroll_vertical): No need to adjust the
4683 number of lines to scroll.
4684
4685 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
4686
4687 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
4688 (SECT_OFF_DATA): Likewise.
4689 (SECT_OFF_RODATA): Likewise.
4690 (SECT_OFF_TEXT): Likewise.
4691 (SECT_OFF_BSS): Likewise.
4692 (struct objfile) <text_section_offset, data_section_offset>: New
4693 methods.
4694 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
4695 objfile::text_section_offset.
4696 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
4697 * coffread.c (coff_symtab_read): Likewise.
4698 (enter_linenos): Likewise.
4699 (process_coff_symbol): Likewise.
4700 * ctfread.c (get_objfile_text_range): Likewise.
4701 * dtrace-probe.c (dtrace_probe::get_relocated_address):
4702 Use objfile::data_section_offset.
4703 * dwarf2-frame.c (execute_cfa_program): Use
4704 objfile::text_section_offset.
4705 (dwarf2_frame_find_fde): Likewise.
4706 * dwarf2read.c (create_addrmap_from_index): Likewise.
4707 (create_addrmap_from_aranges): Likewise.
4708 (dw2_find_pc_sect_compunit_symtab): Likewise.
4709 (process_psymtab_comp_unit_reader): Likewise.
4710 (add_partial_symbol): Likewise.
4711 (add_partial_subprogram): Likewise.
4712 (process_full_comp_unit): Likewise.
4713 (read_file_scope): Likewise.
4714 (read_func_scope): Likewise.
4715 (read_lexical_block_scope): Likewise.
4716 (read_call_site_scope): Likewise.
4717 (dwarf2_rnglists_process): Likewise.
4718 (dwarf2_ranges_process): Likewise.
4719 (dwarf2_ranges_read): Likewise.
4720 (dwarf_decode_lines_1): Likewise.
4721 (new_symbol): Likewise.
4722 (dwarf2_fetch_die_loc_sect_off): Likewise.
4723 (dwarf2_per_cu_text_offset): Likewise.
4724 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
4725 * hppa-tdep.c (read_unwind_info): Likewise.
4726 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
4727 * psympriv.h (struct partial_symtab): Likewise.
4728 * psymtab.c (find_pc_sect_psymtab): Likewise.
4729 * solib-svr4.c (enable_break): Likewise.
4730 * stap-probe.c (relocate_address): Use
4731 objfile::data_section_offset.
4732 * xcoffread.c (enter_line_range): Use
4733 objfile::text_section_offset.
4734 (read_xcoff_symtab): Likewise.
4735
4736 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
4737
4738 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
4739 declaration to narrower scopes.
4740
4741 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
4742
4743 * darwin-nat.h (struct darwin_exception_msg, enum
4744 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
4745 Move up.
4746 (class darwin_nat_target) <wait_1, check_new_threads,
4747 decode_exception_message, decode_message, stop_inferior,
4748 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
4749 * darwin-nat.c (darwin_check_new_threads): Rename to...
4750 (darwin_nat_target::check_new_threads): ... this.
4751 (darwin_suspend_inferior_it): Remove.
4752 (darwin_decode_exception_message): Rename to...
4753 (darwin_nat_target::decode_exception_message): ... this.
4754 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
4755 (darwin_decode_message): Rename to...
4756 (darwin_nat_target::decode_message): ... this.
4757 (cancel_breakpoint): Rename to...
4758 (darwin_nat_target::cancel_breakpoint): ... this.
4759 (darwin_wait): Rename to...
4760 (darwin_nat_target::wait_1): ... this. Use range-based for loop
4761 instead of iterate_over_inferiors.
4762 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
4763 (darwin_stop_inferior): Rename to...
4764 (darwin_nat_target::stop_inferior): ... this.
4765 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
4766 (darwin_init_thread_list): Rename to...
4767 (darwin_nat_target::init_thread_list): ... this.
4768 (darwin_ptrace_him): Rename to...
4769 (darwin_nat_target::ptrace_him): ... this.
4770 (darwin_nat_target::create_inferior): Pass lambda function to
4771 fork_inferior.
4772 (darwin_nat_target::detach): Call stop_inferior instead of
4773 darwin_stop_inferior.
4774 * fork-inferior.h (fork_inferior): Change init_trace_fun
4775 parameter to gdb::function_view.
4776 * fork-inferior.c (fork_inferior): Likewise.
4777
4778 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
4779
4780 * i386-cygwin-tdep.c (core_process_module_section): Update.
4781 * windows-nat.c (struct lm_info_windows): Add text_offset.
4782 (windows_xfer_shared_libraries): Update.
4783 * windows-tdep.c (windows_xfer_shared_library):
4784 Add text_offset_cached argument.
4785 * windows-tdep.h (windows_xfer_shared_library): Update.
4786
4787 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
4788
4789 * gdbarch.sh: Add declaration for _initialize_gdbarch.
4790
4791 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
4792
4793 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
4794 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
4795 replace with range-based for.
4796 (gdbsim_interrupt_inferior): Remove.
4797 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
4798 with a range-based for. Inline code from
4799 gdbsim_interrupt_inferior.
4800
4801 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
4802
4803 * infrun.c (proceed): Fix indentation.
4804
4805 2020-01-21 Tom Tromey <tromey@adacore.com>
4806
4807 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
4808 * python/python.c (python_extension_ops): Update.
4809 (gdbpy_colorize): New function.
4810 * python/lib/gdb/__init__.py (colorize): New function.
4811 * extension.h (ext_lang_colorize): Declare.
4812 * extension.c (ext_lang_colorize): New function.
4813 * extension-priv.h (struct extension_language_ops) <colorize>: New
4814 member.
4815 * cli/cli-style.c (_initialize_cli_style): Update help text.
4816
4817 2020-01-21 Luis Machado <luis.machado@linaro.org>
4818
4819 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
4820 <cond>: Change type to bool.
4821 (aarch64_displaced_step_b_cond): Update cond to use bool type.
4822 (aarch64_displaced_step_cb): Likewise.
4823 (aarch64_displaced_step_tb): Likewise.
4824
4825 2020-01-21 Luis Machado <luis.machado@linaro.org>
4826
4827 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
4828 output.
4829
4830 2020-01-21 Luis Machado <luis.machado@linaro.org>
4831
4832 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
4833 <pc_adjust>: Adjust the documentation.
4834 (aarch64_displaced_step_fixup): Check if PC really moved before
4835 adjusting it.
4836
4837 2020-01-19 Tom Tromey <tom@tromey.com>
4838
4839 * disasm.c (~gdb_disassembler): New destructor.
4840 (gdb_buffered_insn_length): Call disassemble_free_target.
4841 * disasm.h (class gdb_disassembler): Declare destructor. Use
4842 DISABLE_COPY_AND_ASSIGN.
4843
4844 2020-01-19 Tom Tromey <tom@tromey.com>
4845
4846 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
4847 (die_reader_func_ftype): Remove.
4848 (cutu_reader): New class.
4849 (dw2_get_file_names_reader): Remove "data" parameter.
4850 (dw2_get_file_names): Use cutu_reader.
4851 (create_debug_type_hash_table): Update.
4852 (read_cutu_die_from_dwo): Update comment.
4853 (lookup_dwo_unit): Add dwo_name parameter.
4854 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
4855 die_reader_func_ftype and data parameters.
4856 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
4857 Remove die_reader_func_ftype and data parameters.
4858 (~cutu_reader): New; from init_cutu_and_read_dies.
4859 (cutu_reader::cutu_reader): Rename from
4860 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
4861 and data parameters.
4862 (init_cutu_and_read_dies_simple): Remove.
4863 (struct process_psymtab_comp_unit_data): Remove.
4864 (process_psymtab_comp_unit_reader): Remove data parameter; add
4865 want_partial_unit and pretend_language parameters.
4866 (process_psymtab_comp_unit): Use cutu_reader.
4867 (build_type_psymtabs_reader): Remove data parameter.
4868 (build_type_psymtabs_1): Use cutu_reader.
4869 (process_skeletonless_type_unit): Likewise.
4870 (load_partial_comp_unit_reader): Remove.
4871 (load_partial_comp_unit): Use cutu_reader.
4872 (load_full_comp_unit_reader): Remove.
4873 (load_full_comp_unit): Use cutu_reader.
4874 (struct create_dwo_cu_data): Remove.
4875 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
4876 dwo_unit parameters.
4877 (create_cus_hash_table): Use cutu_reader.
4878 (struct dwarf2_read_addr_index_data): Remove.
4879 (dwarf2_read_addr_index_reader): Remove.
4880 (dwarf2_read_addr_index): Use cutu_reader.
4881 (read_signatured_type_reader): Remove.
4882 (read_signatured_type): Use cutu_reader.
4883
4884 2020-01-19 Tom Tromey <tom@tromey.com>
4885
4886 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
4887 * tui/tui-wingeneral.h (class tui_suppress_output): New.
4888 (tui_wrefresh): Declare.
4889 * tui/tui-wingeneral.c (suppress_output): New global.
4890 (tui_suppress_output, ~tui_suppress_output): New constructor and
4891 destructor.
4892 (tui_wrefresh): New function.
4893 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
4894 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
4895 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
4896 method.
4897 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
4898 tui_wrefresh.
4899 (tui_data_window::no_refresh): New method.
4900 (tui_data_item_window::refresh_window): Call tui_wrefresh.
4901 (tui_reg_command): Use tui_suppress_output
4902 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
4903 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
4904 method.
4905 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
4906
4907 2020-01-19 Tom Tromey <tom@tromey.com>
4908
4909 * tui/tui-winsource.c (tui_update_source_windows_with_line):
4910 Handle case where symtab is null.
4911
4912 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
4913
4914 * linux-fork.c (one_fork_p): Simplify.
4915
4916 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
4917
4918 * top.c (struct qt_args): Remove.
4919 (kill_or_detach): Change return type to void, replace `void *`
4920 parameter with a proper one.
4921 (print_inferior_quit_action): Likewise.
4922 (quit_confirm): Use range-based for loop to iterate over inferiors.
4923 (quit_force): Likewise.
4924
4925 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
4926
4927 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
4928 `void *` parameter with proper parameters.
4929 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
4930 (print_one_inferior): Change return type to void, replace `void *`
4931 parameter with proper parameters.
4932 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
4933 inferiors.
4934 (get_other_inferior): Remove.
4935 (mi_cmd_remove_inferior): Use range-based loop to iterate over
4936 inferiors.
4937
4938 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
4939
4940 * mi/mi-interp.c (report_initial_inferior): Remove.
4941 (mi_interp::init): Use range-based for to iterate over inferiors.
4942
4943 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
4944
4945 * python/py-inferior.c (build_inferior_list): Remove.
4946 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
4947
4948 2020-01-16 Christian Biesinger <cbiesinger@google.com>
4949
4950 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
4951 (btrace_stitch_trace): Likewise.
4952 * charset.c (intermediate_encoding): Likewise (vaild).
4953 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
4954 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
4955 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
4956
4957 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
4958
4959 * windows-tdep.c (windows_get_tlb_type):
4960 Add rtl_user_process_parameters type.
4961
4962 2020-01-16 Pedro Alves <palves@redhat.com>
4963 Norbert Lange <nolange79@gmail.com>
4964
4965 PR build/24805
4966 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
4967 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
4968 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
4969 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
4970 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
4971 (ps_plog): Redeclare exported functions with default visibility.
4972
4973 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
4974
4975 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
4976 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
4977
4978 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
4979
4980 * infcmd.c (post_create_inferior): Use get_thread_regcache
4981 instead of get_current_regcache.
4982
4983 2020-01-14 Tom Tromey <tom@tromey.com>
4984
4985 PR symtab/12535:
4986 * python/python.c (gdbpy_decode_line): Treat empty string the same
4987 as no argument.
4988
4989 2020-01-14 Tom Tromey <tom@tromey.com>
4990
4991 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
4992
4993 2020-01-14 Tom Tromey <tom@tromey.com>
4994
4995 * nat/linux-btrace.c: Don't include <config.h>.
4996 * nat/linux-ptrace.c: Don't include <config.h>.
4997 * nat/x86-linux-dregs.c: Don't include <config.h>.
4998
4999 2020-01-14 Tom Tromey <tom@tromey.com>
5000
5001 * configure: Rebuild.
5002 * configure.ac: Move many checks to ../gdbsupport/common.m4.
5003
5004 2020-01-14 Tom Tromey <tom@tromey.com>
5005
5006 * nat/x86-linux-dregs.c: Include configh.h.
5007 * nat/linux-ptrace.c: Include configh.h.
5008 * nat/linux-btrace.c: Include configh.h.
5009 * defs.h: Include config.h, bfd.h.
5010 * configure.ac: Don't source common.host.
5011 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
5012 * configure: Rebuild.
5013 * acinclude.m4: Update path.
5014 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
5015 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
5016 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
5017 (CLIBS): Add LIBSUPPORT.
5018 (CDEPS): Likewise.
5019 (COMMON_SFILES): Remove gdbsupport files.
5020 (HFILES_NO_SRCDIR): Likewise.
5021 (stamp-version): Update path to create-version.sh.
5022 (ALLDEPFILES): Remove gdbsupport files.
5023
5024 2020-01-14 Tom Tromey <tom@tromey.com>
5025
5026 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
5027 USE_WIN32API when needed.
5028 * configure.ac (USE_WIN32API): Don't define.
5029 (WIN32LIBS): Use WIN32APILIBS.
5030 * configure: Rebuild.
5031
5032 2020-01-14 Tom Tromey <tom@tromey.com>
5033
5034 * configure: Rebuild.
5035 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
5036
5037 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
5038
5039 * skip.c (skip_function_command): Make skip w/o arguments use the
5040 name of the inlined function if pc is inside any inlined function.
5041
5042 2020-01-14 Luis Machado <luis.machado@linaro.org>
5043
5044 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
5045 * infrun.c (resume_1): Likewise.
5046 (handle_inferior_event): Remove stale comment.
5047 * linux-nat.c (linux_nat_target::resume): Update comments.
5048 (save_stop_reason): Likewise.
5049 (linux_nat_filter_event): Likewise.
5050 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
5051
5052 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
5053
5054 * elfread.c (record_minimal_symbol): Set section index to 0 for
5055 non-allocatable sections.
5056
5057
5058 2020-01-13 Ali Tamur <tamur@google.com>
5059
5060 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
5061 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
5062 to gdb::optional. Update comments.
5063 (dwo_file): Update comments.
5064 (read_attribute): Update API to take an additional out parameter,
5065 need_reprocess. This is used to mark attributes that need other
5066 attributes (e.g. str_offsets_base) for correct computation which may not
5067 have been read yet.
5068 (read_attribute_reprocess): New function declaration.
5069 (read_addr_index): Likewise.
5070 (read_dwo_str_index): Likewise.
5071 (read_stub_str_index): Likewise.
5072 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
5073 (lookup_addr_base): New function definition.
5074 (lookup_ranges_base): Likewise.
5075 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
5076 lookup_ranges_base.
5077 (init_cutu_and_read_dies): Update comments.
5078 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
5079 unit. This is used to inherit parent's str_offsets_base and addr_base.
5080 Update comments.
5081 (init_cutu_and_read_dies_simple): Reflect API changes.
5082 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
5083 (create_cus_hash_table): Change API to take parent compile unit.
5084 Reflect API changes.
5085 (open_and_init_dwo_file): Reflect API changes.
5086 (dwarf2_get_pc_bounds): Update comments.
5087 (dwarf2_record_block_ranges): Likewise.
5088 (read_full_die_1): Change implementation to reprocess attributes that
5089 need str_offsets_base and addr_base.
5090 (partial_die_info::read): Likewise.
5091 (read_attribute_reprocess): New function definition.
5092 (read_attribute_value): Change API to take an additional out parameter,
5093 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
5094 when a non-dwo compile unit has index based attributes.
5095 (read_attribute): Reflect API changes.
5096 (read_addr_index_1): Reflect API changes. Update comments.
5097 (dwarf2_read_addr_index_data): Reflect API changes.
5098 (dwarf2_read_addr_index): Likewise.
5099 (read_str_index): Change API and implementation. This becomes a helper
5100 to be used by the new string index related methods. Update error
5101 message and comments.
5102 (read_dwo_str_index): New function definition.
5103 (read_stub_str_index): Likewise.
5104 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
5105 * symfile.h (dwarf2_debug_sections): Likewise.
5106 * xcoffread.c (dwarf2_debug_sections): Likewise.
5107
5108 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
5109
5110 * gdbcore.h (struct core_fns) <core_read_registers>: Change
5111 core_reg_sect type to gdb_byte *.
5112 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
5113 * cris-tdep.c (fetch_core_registers): Likewise.
5114 * corelow.c (core_target::get_core_register_section): Change
5115 type of `contents` to gdb::byte_vector.
5116
5117 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
5118
5119 * tui/tui-wingeneral.c (box_win): Position the title in the center
5120 of the border.
5121
5122 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
5123
5124 * corelow.c (core_target::get_core_register_section): Use
5125 std::vector instead of alloca.
5126
5127 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
5128
5129 * warning.m4: Add -Wmissing-declarations to build_warnings.
5130 * configure: Re-generate.
5131
5132 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
5133
5134 * python/python.c (init__gdb_module): Add declaration.
5135
5136 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
5137
5138 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
5139 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
5140 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
5141 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
5142 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
5143 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
5144 * ada-exp.y (_initialize_ada_exp): Add declaration.
5145 * ada-lang.c (_initialize_ada_language): Add declaration.
5146 * ada-tasks.c (_initialize_tasks): Add declaration.
5147 * agent.c (_initialize_agent): Add declaration.
5148 * aix-thread.c (_initialize_aix_thread): Add declaration.
5149 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
5150 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
5151 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
5152 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
5153 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
5154 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
5155 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
5156 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
5157 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
5158 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
5159 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
5160 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
5161 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
5162 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
5163 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
5164 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
5165 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
5166 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
5167 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
5168 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
5169 * annotate.c (_initialize_annotate): Add declaration.
5170 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
5171 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
5172 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
5173 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
5174 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
5175 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
5176 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
5177 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
5178 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
5179 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
5180 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
5181 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
5182 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
5183 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
5184 * auto-load.c (_initialize_auto_load): Add declaration.
5185 * auxv.c (_initialize_auxv): Add declaration.
5186 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
5187 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
5188 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
5189 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
5190 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
5191 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
5192 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
5193 * breakpoint.c (_initialize_breakpoint): Add declaration.
5194 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
5195 * btrace.c (_initialize_btrace): Add declaration.
5196 * charset.c (_initialize_charset): Add declaration.
5197 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
5198 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
5199 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
5200 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
5201 * cli/cli-script.c (_initialize_cli_script): Add declaration.
5202 * cli/cli-style.c (_initialize_cli_style): Add declaration.
5203 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
5204 * coffread.c (_initialize_coffread): Add declaration.
5205 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
5206 * compile/compile.c (_initialize_compile): Add declaration.
5207 * complaints.c (_initialize_complaints): Add declaration.
5208 * completer.c (_initialize_completer): Add declaration.
5209 * copying.c (_initialize_copying): Add declaration.
5210 * corefile.c (_initialize_core): Add declaration.
5211 * corelow.c (_initialize_corelow): Add declaration.
5212 * cp-abi.c (_initialize_cp_abi): Add declaration.
5213 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
5214 * cp-support.c (_initialize_cp_support): Add declaration.
5215 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
5216 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
5217 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
5218 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
5219 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
5220 * ctfread.c (_initialize_ctfread): Add declaration.
5221 * d-lang.c (_initialize_d_language): Add declaration.
5222 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
5223 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
5224 * dbxread.c (_initialize_dbxread): Add declaration.
5225 * dcache.c (_initialize_dcache): Add declaration.
5226 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
5227 * disasm.c (_initialize_disasm): Add declaration.
5228 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
5229 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
5230 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
5231 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
5232 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
5233 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
5234 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
5235 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
5236 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
5237 * elfread.c (_initialize_elfread): Add declaration.
5238 * exec.c (_initialize_exec): Add declaration.
5239 * extension.c (_initialize_extension): Add declaration.
5240 * f-lang.c (_initialize_f_language): Add declaration.
5241 * f-valprint.c (_initialize_f_valprint): Add declaration.
5242 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
5243 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
5244 * filesystem.c (_initialize_filesystem): Add declaration.
5245 * findcmd.c (_initialize_mem_search): Add declaration.
5246 * findvar.c (_initialize_findvar): Add declaration.
5247 * fork-child.c (_initialize_fork_child): Add declaration.
5248 * frame-base.c (_initialize_frame_base): Add declaration.
5249 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
5250 * frame.c (_initialize_frame): Add declaration.
5251 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
5252 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
5253 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
5254 * gcore.c (_initialize_gcore): Add declaration.
5255 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
5256 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
5257 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
5258 * gdbarch.c (_initialize_gdbarch): Add declaration.
5259 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
5260 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
5261 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
5262 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
5263 * go-lang.c (_initialize_go_language): Add declaration.
5264 * go32-nat.c (_initialize_go32_nat): Add declaration.
5265 * guile/guile.c (_initialize_guile): Add declaration.
5266 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
5267 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
5268 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
5269 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
5270 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
5271 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
5272 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
5273 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
5274 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
5275 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
5276 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
5277 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
5278 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
5279 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
5280 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
5281 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
5282 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
5283 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
5284 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
5285 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
5286 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
5287 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
5288 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
5289 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
5290 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
5291 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
5292 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
5293 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
5294 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
5295 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
5296 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
5297 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
5298 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
5299 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
5300 * infcall.c (_initialize_infcall): Add declaration.
5301 * infcmd.c (_initialize_infcmd): Add declaration.
5302 * inflow.c (_initialize_inflow): Add declaration.
5303 * infrun.c (_initialize_infrun): Add declaration.
5304 * interps.c (_initialize_interpreter): Add declaration.
5305 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
5306 * jit.c (_initialize_jit): Add declaration.
5307 * language.c (_initialize_language): Add declaration.
5308 * linux-fork.c (_initialize_linux_fork): Add declaration.
5309 * linux-nat.c (_initialize_linux_nat): Add declaration.
5310 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
5311 * linux-thread-db.c (_initialize_thread_db): Add declaration.
5312 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
5313 * m2-lang.c (_initialize_m2_language): Add declaration.
5314 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
5315 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
5316 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
5317 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
5318 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
5319 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
5320 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
5321 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
5322 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
5323 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
5324 * machoread.c (_initialize_machoread): Add declaration.
5325 * macrocmd.c (_initialize_macrocmd): Add declaration.
5326 * macroscope.c (_initialize_macroscope): Add declaration.
5327 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
5328 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
5329 * maint.c (_initialize_maint_cmds): Add declaration.
5330 * mdebugread.c (_initialize_mdebugread): Add declaration.
5331 * memattr.c (_initialize_mem): Add declaration.
5332 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
5333 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
5334 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
5335 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
5336 * mi/mi-main.c (_initialize_mi_main): Add declaration.
5337 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
5338 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
5339 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
5340 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
5341 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
5342 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
5343 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
5344 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
5345 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
5346 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
5347 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
5348 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
5349 * mipsread.c (_initialize_mipsread): Add declaration.
5350 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
5351 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
5352 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
5353 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
5354 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
5355 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
5356 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
5357 * nto-procfs.c (_initialize_procfs): Add declaration.
5358 * objc-lang.c (_initialize_objc_language): Add declaration.
5359 * observable.c (_initialize_observer): Add declaration.
5360 * opencl-lang.c (_initialize_opencl_language): Add declaration.
5361 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
5362 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
5363 * osabi.c (_initialize_gdb_osabi): Add declaration.
5364 * osdata.c (_initialize_osdata): Add declaration.
5365 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
5366 * parse.c (_initialize_parse): Add declaration.
5367 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
5368 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
5369 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
5370 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
5371 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
5372 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
5373 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
5374 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
5375 * printcmd.c (_initialize_printcmd): Add declaration.
5376 * probe.c (_initialize_probe): Add declaration.
5377 * proc-api.c (_initialize_proc_api): Add declaration.
5378 * proc-events.c (_initialize_proc_events): Add declaration.
5379 * proc-service.c (_initialize_proc_service): Add declaration.
5380 * procfs.c (_initialize_procfs): Add declaration.
5381 * producer.c (_initialize_producer): Add declaration.
5382 * psymtab.c (_initialize_psymtab): Add declaration.
5383 * python/python.c (_initialize_python): Add declaration.
5384 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
5385 * record-btrace.c (_initialize_record_btrace): Add declaration.
5386 * record-full.c (_initialize_record_full): Add declaration.
5387 * record.c (_initialize_record): Add declaration.
5388 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
5389 * regcache.c (_initialize_regcache): Add declaration.
5390 * reggroups.c (_initialize_reggroup): Add declaration.
5391 * remote-notif.c (_initialize_notif): Add declaration.
5392 * remote-sim.c (_initialize_remote_sim): Add declaration.
5393 * remote.c (_initialize_remote): Add declaration.
5394 * reverse.c (_initialize_reverse): Add declaration.
5395 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
5396 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
5397 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
5398 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
5399 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
5400 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
5401 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
5402 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
5403 Add declaration.
5404 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
5405 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
5406 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
5407 * rust-exp.y (_initialize_rust_exp): Add declaration.
5408 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
5409 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
5410 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
5411 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
5412 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
5413 * score-tdep.c (_initialize_score_tdep): Add declaration.
5414 * ser-go32.c (_initialize_ser_dos): Add declaration.
5415 * ser-mingw.c (_initialize_ser_windows): Add declaration.
5416 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
5417 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
5418 * ser-uds.c (_initialize_ser_socket): Add declaration.
5419 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
5420 * serial.c (_initialize_serial): Add declaration.
5421 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
5422 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
5423 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
5424 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
5425 * skip.c (_initialize_step_skip): Add declaration.
5426 * sol-thread.c (_initialize_sol_thread): Add declaration.
5427 * solib-aix.c (_initialize_solib_aix): Add declaration.
5428 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
5429 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
5430 * solib-frv.c (_initialize_frv_solib): Add declaration.
5431 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
5432 * solib-target.c (_initialize_solib_target): Add declaration.
5433 * solib.c (_initialize_solib): Add declaration.
5434 * source-cache.c (_initialize_source_cache): Add declaration.
5435 * source.c (_initialize_source): Add declaration.
5436 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
5437 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
5438 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
5439 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
5440 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
5441 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
5442 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
5443 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
5444 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
5445 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
5446 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
5447 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
5448 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
5449 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
5450 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
5451 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
5452 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
5453 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
5454 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
5455 * stabsread.c (_initialize_stabsread): Add declaration.
5456 * stack.c (_initialize_stack): Add declaration.
5457 * stap-probe.c (_initialize_stap_probe): Add declaration.
5458 * std-regs.c (_initialize_frame_reg): Add declaration.
5459 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
5460 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
5461 * symfile.c (_initialize_symfile): Add declaration.
5462 * symmisc.c (_initialize_symmisc): Add declaration.
5463 * symtab.c (_initialize_symtab): Add declaration.
5464 * target.c (_initialize_target): Add declaration.
5465 * target-connection.c (_initialize_target_connection): Add
5466 declaration.
5467 * target-dcache.c (_initialize_target_dcache): Add declaration.
5468 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
5469 * thread.c (_initialize_thread): Add declaration.
5470 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
5471 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
5472 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
5473 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
5474 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
5475 * tracectf.c (_initialize_ctf): Add declaration.
5476 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
5477 * tracefile.c (_initialize_tracefile): Add declaration.
5478 * tracepoint.c (_initialize_tracepoint): Add declaration.
5479 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
5480 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
5481 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
5482 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
5483 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
5484 * tui/tui-win.c (_initialize_tui_win): Add declaration.
5485 * tui/tui.c (_initialize_tui): Add declaration.
5486 * typeprint.c (_initialize_typeprint): Add declaration.
5487 * ui-style.c (_initialize_ui_style): Add declaration.
5488 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
5489 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
5490 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
5491 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
5492 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
5493 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
5494 * unittests/filtered_iterator-selftests.c
5495 (_initialize_filtered_iterator_selftests): Add declaration.
5496 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
5497 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
5498 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
5499 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
5500 * unittests/main-thread-selftests.c
5501 (_initialize_main_thread_selftests): Add declaration.
5502 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
5503 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
5504 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
5505 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
5506 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
5507 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
5508 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
5509 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
5510 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
5511 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
5512 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
5513 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
5514 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
5515 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
5516 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
5517 declaration.
5518 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
5519 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
5520 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
5521 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
5522 * user-regs.c (_initialize_user_regs): Add declaration.
5523 * utils.c (_initialize_utils): Add declaration.
5524 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
5525 * valops.c (_initialize_valops): Add declaration.
5526 * valprint.c (_initialize_valprint): Add declaration.
5527 * value.c (_initialize_values): Add declaration.
5528 * varobj.c (_initialize_varobj): Add declaration.
5529 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
5530 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
5531 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
5532 * windows-nat.c (_initialize_windows_nat): Add declaration.
5533 (_initialize_check_for_gdb_ini): Add declaration.
5534 (_initialize_loadable): Add declaration.
5535 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
5536 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
5537 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
5538 * xcoffread.c (_initialize_xcoffread): Add declaration.
5539 * xml-support.c (_initialize_xml_support): Add declaration.
5540 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
5541 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
5542 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
5543 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
5544
5545 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
5546
5547 * regformats/regdat.sh: Generate declaration for init function.
5548
5549 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
5550
5551 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
5552 up.
5553 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
5554 close_one_inferior>: New methods.
5555 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
5556 pass down target to find_inferior_pid.
5557 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
5558 Pass down target to find_inferior_ptid.
5559 (gdbsim_target::create_inferior): Pass down target to
5560 add_thread_silent.
5561 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
5562 target down to find_inferior_ptid and switch_to_thread.
5563 (gdbsim_target::close): Update to call close_one_inferior.
5564 (struct resume_data): Remove.
5565 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
5566 directly, rather than through a void pointer.
5567 (gdbsim_target::resume): Update to call resume_one_inferior.
5568
5569 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
5570
5571 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
5572
5573 2020-01-12 Pedro Alves <palves@redhat.com>
5574
5575 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
5576 directly for the current inferior instead of
5577 discard_all_inferiors.
5578 (discard_all_inferiors): Delete.
5579
5580 2020-01-11 Tom Tromey <tom@tromey.com>
5581
5582 * tui/tui-wingeneral.c (box_win): Check cli_styling.
5583 * tui/tui-winsource.c (tui_source_window_base::refill): Use
5584 deprecated_safe_get_selected_frame.
5585
5586 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5587
5588 * inferior.c (print_inferior): Switch inferior before printing it.
5589
5590 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
5591 Pedro Alves <palves@redhat.com>
5592
5593 * progspace-and-thread.c (switch_to_program_space_and_thread):
5594 Assert there's an inferior for PSPACE. Use
5595 switch_to_inferior_no_thread to switch the inferior too.
5596 * progspace.c (program_space::~program_space): Call
5597 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
5598 (program_space::free_all_objfiles): Don't call clear_symtab_users
5599 here.
5600 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
5601
5602 2020-01-10 Pedro Alves <palves@redhat.com>
5603
5604 * NEWS: Mention multi-target debugging, "info connections", and
5605 "add-inferior -no-connection".
5606
5607 2020-01-10 Pedro Alves <palves@redhat.com>
5608
5609 * infrun.c: Include "target-connection.h".
5610 (check_multi_target_resumption): New.
5611 (proceed): Call it.
5612 * target-connection.c (make_target_connection_string): Make
5613 extern.
5614 * target-connection.h (make_target_connection_string): Declare.
5615
5616 2020-01-10 Pedro Alves <palves@redhat.com>
5617
5618 * Makefile.in (COMMON_SFILES): Add target-connection.c.
5619 * inferior.c (uiout_field_connection): New function.
5620 (print_inferior): Add new "connection-id" column.
5621 (add_inferior_command): Show connection number/string of added
5622 inferior.
5623 * process-stratum-target.h
5624 (process_stratum_target::connection_string): New virtual method.
5625 (process_stratum_target::connection_number): New field.
5626 * remote.c (remote_target::connection_string): New override.
5627 * target-connection.c: New file.
5628 * target-connection.h: New file.
5629 * target.c (decref_target): Remove process_stratum targets from
5630 the connection list.
5631 (target_stack::push): Add process_stratum targets to the
5632 connection list.
5633
5634 2020-01-10 Pedro Alves <palves@redhat.com>
5635
5636 Revert:
5637 2016-04-12 Pedro Alves <palves@redhat.com>
5638 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
5639 Remove references to name.
5640 * serial.h (struct serial) <name>: Delete.
5641
5642 2020-01-10 Pedro Alves <palves@redhat.com>
5643
5644 * gdbarch-selftests.c (register_to_value_test): Remove "target
5645 already pushed" check.
5646
5647 2020-01-10 Pedro Alves <palves@redhat.com>
5648 John Baldwin <jhb@FreeBSD.org>
5649
5650 * aarch64-linux-nat.c
5651 (aarch64_linux_nat_target::thread_architecture): Adjust.
5652 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
5653 (task_command_1): Likewise.
5654 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
5655 (aix_thread_target::wait, aix_thread_target::fetch_registers)
5656 (aix_thread_target::store_registers)
5657 (aix_thread_target::thread_alive): Adjust.
5658 * amd64-fbsd-tdep.c: Include "inferior.h".
5659 (amd64fbsd_get_thread_local_address): Pass down target.
5660 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
5661 thread's gdbarch instead of target_gdbarch.
5662 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
5663 get_last_target_status.
5664 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
5665 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
5666 inferiors.
5667 (update_inserted_breakpoint_locations): Skip if inferiors with no
5668 execution.
5669 (update_global_location_list): When handling moribund locations,
5670 find representative inferior for location's pspace, and use thread
5671 count of its process_stratum target.
5672 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
5673 * bsd-uthread.c (bsd_uthread_target::wait): Use
5674 as_process_stratum_target and adjust thread_change_ptid and
5675 add_thread calls.
5676 (bsd_uthread_target::update_thread_list): Use
5677 as_process_stratum_target and adjust find_thread_ptid,
5678 thread_change_ptid and add_thread calls.
5679 * btrace.c (maint_btrace_packet_history_cmd): Adjust
5680 find_thread_ptid call.
5681 * corelow.c (add_to_thread_list): Adjust add_thread call.
5682 (core_target_open): Adjust add_thread_silent and thread_count
5683 calls.
5684 (core_target::pid_to_str): Adjust find_inferior_ptid call.
5685 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
5686 * event-top.c (async_disconnect): Pop targets from all inferiors.
5687 * exec.c (add_target_sections): Push exec target on all inferiors
5688 sharing the program space.
5689 (remove_target_sections): Remove the exec target from all
5690 inferiors sharing the program space.
5691 (exec_on_vfork): New.
5692 * exec.h (exec_on_vfork): Declare.
5693 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
5694 Pass it down.
5695 (fbsd_nat_target::update_thread_list): Adjust.
5696 (fbsd_nat_target::resume): Adjust.
5697 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
5698 down.
5699 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
5700 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
5701 get_thread_arch_regcache call.
5702 * fork-child.c (gdb_startup_inferior): Pass target down to
5703 startup_inferior and set_executing.
5704 * gdbthread.h (struct process_stratum_target): Forward declare.
5705 (add_thread, add_thread_silent, add_thread_with_info)
5706 (in_thread_list): Add process_stratum_target parameter.
5707 (find_thread_ptid(inferior*, ptid_t)): New overload.
5708 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
5709 parameter.
5710 (all_threads()): Delete overload.
5711 (all_threads, all_non_exited_threads): Add process_stratum_target
5712 parameter.
5713 (all_threads_safe): Use brace initialization.
5714 (thread_count): Add process_stratum_target parameter.
5715 (set_resumed, set_running, set_stop_requested, set_executing)
5716 (threads_are_executing, finish_thread_state): Add
5717 process_stratum_target parameter.
5718 (switch_to_thread): Use is_current_thread.
5719 * i386-fbsd-tdep.c: Include "inferior.h".
5720 (i386fbsd_get_thread_local_address): Pass down target.
5721 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
5722 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
5723 have_inferiors check.
5724 * inf-ptrace.c (inf_ptrace_target::create_inferior)
5725 (inf_ptrace_target::attach): Adjust.
5726 * infcall.c (run_inferior_call): Adjust.
5727 * infcmd.c (run_command_1): Pass target to
5728 scoped_finish_thread_state.
5729 (proceed_thread_callback): Skip inferiors with no execution.
5730 (continue_command): Rename 'all_threads' local to avoid hiding
5731 'all_threads' function. Adjust get_last_target_status call.
5732 (prepare_one_step): Adjust set_running call.
5733 (signal_command): Use user_visible_resume_target. Compare thread
5734 pointers instead of inferior_ptid.
5735 (info_program_command): Adjust to pass down target.
5736 (attach_command): Mark target's 'thread_executing' flag.
5737 (stop_current_target_threads_ns): New, factored out from ...
5738 (interrupt_target_1): ... this. Switch inferior before making
5739 target calls.
5740 * inferior-iter.h
5741 (struct all_inferiors_iterator, struct all_inferiors_range)
5742 (struct all_inferiors_safe_range)
5743 (struct all_non_exited_inferiors_range): Filter on
5744 process_stratum_target too. Remove explicit.
5745 * inferior.c (inferior::inferior): Push dummy target on target
5746 stack.
5747 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
5748 Add process_stratum_target parameter, and pass it down.
5749 (have_live_inferiors): Adjust.
5750 (switch_to_inferior_and_push_target): New.
5751 (add_inferior_command, clone_inferior_command): Handle
5752 "-no-connection" parameter. Use
5753 switch_to_inferior_and_push_target.
5754 (_initialize_inferior): Mention "-no-connection" option in
5755 the help of "add-inferior" and "clone-inferior" commands.
5756 * inferior.h: Include "process-stratum-target.h".
5757 (interrupt_target_1): Use bool.
5758 (struct inferior) <push_target, unpush_target, target_is_pushed,
5759 find_target_beneath, top_target, process_target, target_at,
5760 m_stack>: New.
5761 (discard_all_inferiors): Delete.
5762 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
5763 (all_inferiors, all_non_exited_inferiors): Add
5764 process_stratum_target parameter.
5765 * infrun.c: Include "gdb_select.h" and <unordered_map>.
5766 (target_last_proc_target): New global.
5767 (follow_fork_inferior): Push target on new inferior. Pass target
5768 to add_thread_silent. Call exec_on_vfork. Handle target's
5769 reference count.
5770 (follow_fork): Adjust get_last_target_status call. Also consider
5771 target.
5772 (follow_exec): Push target on new inferior.
5773 (struct execution_control_state) <target>: New field.
5774 (user_visible_resume_target): New.
5775 (do_target_resume): Call target_async.
5776 (resume_1): Set target's threads_executing flag. Consider resume
5777 target.
5778 (commit_resume_all_targets): New.
5779 (proceed): Also consider resume target. Skip threads of inferiors
5780 with no execution. Commit resumtion in all targets.
5781 (start_remote): Pass current inferior to wait_for_inferior.
5782 (infrun_thread_stop_requested): Consider target as well. Pass
5783 thread_info pointer to clear_inline_frame_state instead of ptid.
5784 (infrun_thread_thread_exit): Consider target as well.
5785 (random_pending_event_thread): New inferior parameter. Use it.
5786 (do_target_wait): Rename to ...
5787 (do_target_wait_1): ... this. Add inferior parameter, and pass it
5788 down.
5789 (threads_are_resumed_pending_p, do_target_wait): New.
5790 (prepare_for_detach): Adjust calls.
5791 (wait_for_inferior): New inferior parameter. Handle it. Use
5792 do_target_wait_1 instead of do_target_wait.
5793 (fetch_inferior_event): Adjust. Switch to representative
5794 inferior. Pass target down.
5795 (set_last_target_status): Add process_stratum_target parameter.
5796 Save target in global.
5797 (get_last_target_status): Add process_stratum_target parameter and
5798 handle it.
5799 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
5800 (context_switch): Check inferior_ptid == null_ptid before calling
5801 inferior_thread().
5802 (get_inferior_stop_soon): Pass down target.
5803 (wait_one): Rename to ...
5804 (poll_one_curr_target): ... this.
5805 (struct wait_one_event): New.
5806 (wait_one): New.
5807 (stop_all_threads): Adjust.
5808 (handle_no_resumed, handle_inferior_event): Adjust to consider the
5809 event's target.
5810 (switch_back_to_stepped_thread): Also consider target.
5811 (print_stop_event): Update.
5812 (normal_stop): Update. Also consider the resume target.
5813 * infrun.h (wait_for_inferior): Remove declaration.
5814 (user_visible_resume_target): New declaration.
5815 (get_last_target_status, set_last_target_status): New
5816 process_stratum_target parameter.
5817 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
5818 process_stratum_target parameter, and use it.
5819 (clear_inline_frame_state (thread_info*)): New.
5820 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
5821 process_stratum_target parameter.
5822 (clear_inline_frame_state (thread_info*)): Declare.
5823 * linux-fork.c (delete_checkpoint_command): Pass target down to
5824 find_thread_ptid.
5825 (checkpoint_command): Adjust.
5826 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
5827 instead of just tweaking inferior_ptid.
5828 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
5829 (exit_lwp): Pass target down to find_thread_ptid.
5830 (attach_proc_task_lwp_callback): Pass target down to
5831 add_thread/set_running/set_executing.
5832 (linux_nat_target::attach): Pass target down to
5833 thread_change_ptid.
5834 (get_detach_signal): Pass target down to find_thread_ptid.
5835 Consider last target status's target.
5836 (linux_resume_one_lwp_throw, resume_lwp)
5837 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
5838 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
5839 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
5840 (linux_nat_target::async_wait_fd): New.
5841 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
5842 target down.
5843 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
5844 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
5845 * linux-thread-db.c (struct thread_db_info::process_target): New
5846 field.
5847 (add_thread_db_info): Save target.
5848 (get_thread_db_info): New process_stratum_target parameter. Also
5849 match target.
5850 (delete_thread_db_info): New process_stratum_target parameter.
5851 Also match target.
5852 (thread_from_lwp): Adjust to pass down target.
5853 (thread_db_notice_clone): Pass down target.
5854 (check_thread_db_callback): Pass down target.
5855 (try_thread_db_load_1): Always push the thread_db target.
5856 (try_thread_db_load, record_thread): Pass target down.
5857 (thread_db_target::detach): Pass target down. Always unpush the
5858 thread_db target.
5859 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
5860 target down. Always unpush the thread_db target.
5861 (find_new_threads_callback, thread_db_find_new_threads_2)
5862 (thread_db_target::update_thread_list): Pass target down.
5863 (thread_db_target::pid_to_str): Pass current inferior down.
5864 (thread_db_target::get_thread_local_address): Pass target down.
5865 (thread_db_target::resume, maintenance_check_libthread_db): Pass
5866 target down.
5867 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
5868 * procfs.c (procfs_target::procfs_init_inferior): Declare.
5869 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
5870 (procfs_init_inferior): Rename to ...
5871 (procfs_target::procfs_init_inferior): ... this and adjust.
5872 (procfs_target::create_inferior, procfs_notice_thread)
5873 (procfs_do_thread_registers): Adjust.
5874 * ppc-fbsd-tdep.c: Include "inferior.h".
5875 (ppcfbsd_get_thread_local_address): Pass down target.
5876 * proc-service.c (ps_xfer_memory): Switch current inferior and
5877 program space as well.
5878 (get_ps_regcache): Pass target down.
5879 * process-stratum-target.c
5880 (process_stratum_target::thread_address_space)
5881 (process_stratum_target::thread_architecture): Pass target down.
5882 * process-stratum-target.h
5883 (process_stratum_target::threads_executing): New field.
5884 (as_process_stratum_target): New.
5885 * ravenscar-thread.c
5886 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
5887 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
5888 down.
5889 * record-btrace.c (record_btrace_target::info_record): Adjust.
5890 (record_btrace_target::record_method)
5891 (record_btrace_target::record_is_replaying)
5892 (record_btrace_target::fetch_registers)
5893 (get_thread_current_frame_id, record_btrace_target::resume)
5894 (record_btrace_target::wait, record_btrace_target::stop): Pass
5895 target down.
5896 * record-full.c (record_full_wait_1): Switch to event thread.
5897 Pass target down.
5898 * regcache.c (regcache::regcache)
5899 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
5900 process_stratum_target parameter and handle it.
5901 (current_thread_target): New global.
5902 (get_thread_regcache): Add process_stratum_target parameter and
5903 handle it. Switch inferior before calling target method.
5904 (get_thread_regcache): Pass target down.
5905 (get_thread_regcache_for_ptid): Pass target down.
5906 (registers_changed_ptid): Add process_stratum_target parameter and
5907 handle it.
5908 (registers_changed_thread, registers_changed): Pass target down.
5909 (test_get_thread_arch_aspace_regcache): New.
5910 (current_regcache_test): Define a couple local test_target_ops
5911 instances and use them for testing.
5912 (readwrite_regcache): Pass process_stratum_target parameter.
5913 (cooked_read_test, cooked_write_test): Pass mock_target down.
5914 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
5915 (get_thread_arch_aspace_regcache): Add process_stratum_target
5916 parameter.
5917 (regcache::target): New method.
5918 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
5919 (regcache::registers_changed_ptid): Add process_stratum_target
5920 parameter.
5921 (regcache::m_target): New field.
5922 (registers_changed_ptid): Add process_stratum_target parameter.
5923 * remote.c (remote_state::supports_vCont_probed): New field.
5924 (remote_target::async_wait_fd): New method.
5925 (remote_unpush_and_throw): Add remote_target parameter.
5926 (get_current_remote_target): Adjust.
5927 (remote_target::remote_add_inferior): Push target.
5928 (remote_target::remote_add_thread)
5929 (remote_target::remote_notice_new_inferior)
5930 (get_remote_thread_info): Pass target down.
5931 (remote_target::update_thread_list): Skip threads of inferiors
5932 bound to other targets. (remote_target::close): Don't discard
5933 inferiors. (remote_target::add_current_inferior_and_thread)
5934 (remote_target::process_initial_stop_replies)
5935 (remote_target::start_remote)
5936 (remote_target::remote_serial_quit_handler): Pass down target.
5937 (remote_target::remote_unpush_target): New remote_target
5938 parameter. Unpush the target from all inferiors.
5939 (remote_target::remote_unpush_and_throw): New remote_target
5940 parameter. Pass it down.
5941 (remote_target::open_1): Check whether the current inferior has
5942 execution instead of checking whether any inferior is live. Pass
5943 target down.
5944 (remote_target::remote_detach_1): Pass down target. Use
5945 remote_unpush_target.
5946 (extended_remote_target::attach): Pass down target.
5947 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
5948 (remote_target::append_resumption): Pass down target.
5949 (remote_target::append_pending_thread_resumptions)
5950 (remote_target::remote_resume_with_hc, remote_target::resume)
5951 (remote_target::commit_resume): Pass down target.
5952 (remote_target::remote_stop_ns): Check supports_vCont_probed.
5953 (remote_target::interrupt_query)
5954 (remote_target::remove_new_fork_children)
5955 (remote_target::check_pending_events_prevent_wildcard_vcont)
5956 (remote_target::remote_parse_stop_reply)
5957 (remote_target::process_stop_reply): Pass down target.
5958 (first_remote_resumed_thread): New remote_target parameter. Pass
5959 it down.
5960 (remote_target::wait_as): Pass down target.
5961 (unpush_and_perror): New remote_target parameter. Pass it down.
5962 (remote_target::readchar, remote_target::remote_serial_write)
5963 (remote_target::getpkt_or_notif_sane_1)
5964 (remote_target::kill_new_fork_children, remote_target::kill): Pass
5965 down target.
5966 (remote_target::mourn_inferior): Pass down target. Use
5967 remote_unpush_target.
5968 (remote_target::core_of_thread)
5969 (remote_target::remote_btrace_maybe_reopen): Pass down target.
5970 (remote_target::pid_to_exec_file)
5971 (remote_target::thread_handle_to_thread_info): Pass down target.
5972 (remote_target::async_wait_fd): New.
5973 * riscv-fbsd-tdep.c: Include "inferior.h".
5974 (riscv_fbsd_get_thread_local_address): Pass down target.
5975 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
5976 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
5977 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
5978 Adjust.
5979 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
5980 * solib-svr4.c (enable_break): Pass down target.
5981 * spu-multiarch.c (parse_spufs_run): Pass down target.
5982 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
5983 * target-delegates.c: Regenerate.
5984 * target.c (g_target_stack): Delete.
5985 (current_top_target): Return the current inferior's top target.
5986 (target_has_execution_1): Refer to the passed-in inferior's top
5987 target.
5988 (target_supports_terminal_ours): Check whether the initial
5989 inferior was already created.
5990 (decref_target): New.
5991 (target_stack::push): Incref/decref the target.
5992 (push_target, push_target, unpush_target): Adjust.
5993 (target_stack::unpush): Defref target.
5994 (target_is_pushed): Return bool. Adjust to refer to the current
5995 inferior's target stack.
5996 (dispose_inferior): Delete, and inline parts ...
5997 (target_preopen): ... here. Only dispose of the current inferior.
5998 (target_detach): Hold strong target reference while detaching.
5999 Pass target down.
6000 (target_thread_name): Add assertion.
6001 (target_resume): Pass down target.
6002 (target_ops::beneath, find_target_at): Adjust to refer to the
6003 current inferior's target stack.
6004 (get_dummy_target): New.
6005 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
6006 has a thread running.
6007 (initialize_targets): Rename to ...
6008 (_initialize_target): ... this.
6009 * target.h: Include "gdbsupport/refcounted-object.h".
6010 (struct target_ops): Inherit refcounted_object.
6011 (target_ops::shortname, target_ops::longname): Make const.
6012 (target_ops::async_wait_fd): New method.
6013 (decref_target): Declare.
6014 (struct target_ops_ref_policy): New.
6015 (target_ops_ref): New typedef.
6016 (get_dummy_target): Declare function.
6017 (target_is_pushed): Return bool.
6018 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
6019 (all_matching_threads_iterator::all_matching_threads_iterator):
6020 Handle filter target.
6021 * thread-iter.h (struct all_matching_threads_iterator, struct
6022 all_matching_threads_range, class all_non_exited_threads_range):
6023 Filter by target too. Remove explicit.
6024 * thread.c (threads_executing): Delete.
6025 (inferior_thread): Pass down current inferior.
6026 (clear_thread_inferior_resources): Pass down thread pointer
6027 instead of ptid_t.
6028 (add_thread_silent, add_thread_with_info, add_thread): Add
6029 process_stratum_target parameter. Use it for thread and inferior
6030 searches.
6031 (is_current_thread): New.
6032 (thread_info::deletable): Use it.
6033 (find_thread_ptid, thread_count, in_thread_list)
6034 (thread_change_ptid, set_resumed, set_running): New
6035 process_stratum_target parameter. Pass it down.
6036 (set_executing): New process_stratum_target parameter. Pass it
6037 down. Adjust reference to 'threads_executing'.
6038 (threads_are_executing): New process_stratum_target parameter.
6039 Adjust reference to 'threads_executing'.
6040 (set_stop_requested, finish_thread_state): New
6041 process_stratum_target parameter. Pass it down.
6042 (switch_to_thread): Also match inferior.
6043 (switch_to_thread): New process_stratum_target parameter. Pass it
6044 down.
6045 (update_threads_executing): Reimplement.
6046 * top.c (quit_force): Pop targets from all inferior.
6047 (gdb_init): Don't call initialize_targets.
6048 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
6049 Declare.
6050 (windows_add_thread, windows_delete_thread): Adjust.
6051 (get_windows_debug_event): Rename to ...
6052 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
6053 * tracefile-tfile.c (tfile_target_open): Pass down target.
6054 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
6055 Forward declare.
6056 (switch_to_thread): Add process_stratum_target parameter.
6057 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
6058 parameter. Use it.
6059 (mi_on_resume): Pass target down.
6060 * nat/fork-inferior.c (startup_inferior): Add
6061 process_stratum_target parameter. Pass it down.
6062 * nat/fork-inferior.h (startup_inferior): Add
6063 process_stratum_target parameter.
6064 * python/py-threadevent.c (py_get_event_thread): Pass target down.
6065
6066 2020-01-10 Pedro Alves <palves@redhat.com>
6067
6068 * remote.c (remote_target::start_remote): Don't set inferior_ptid
6069 directly. Instead find the first thread in the thread list and
6070 use switch_to_thread.
6071
6072 2020-01-10 Pedro Alves <palves@redhat.com>
6073
6074 * remote.c (remote_target::remote_add_inferior): Don't bind a
6075 process to the current inferior if the current inferior is already
6076 bound to a process.
6077
6078 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6079 Pedro Alves <palves@redhat.com>
6080
6081 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
6082 If no process is specified, return null_ptid instead of
6083 inferior_ptid.
6084 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
6085 TARGET_WAITKIND_SIGNALLED with no pid.
6086
6087 2020-01-10 Pedro Alves <palves@redhat.com>
6088
6089 * remote.c (first_remote_resumed_thread): New.
6090 (remote_target::wait_as): Use it as default event_ptid instead of
6091 inferior_ptid.
6092
6093 2020-01-10 Pedro Alves <palves@redhat.com>
6094
6095 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
6096
6097 2020-01-10 Pedro Alves <palves@redhat.com>
6098
6099 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
6100 not -1.
6101
6102 2020-01-10 Pedro Alves <palves@redhat.com>
6103
6104 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
6105 ptid to get_last_target_status.
6106 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
6107 ptid to get_last_target_status.
6108 * infcmd.c (continue_command): Don't pass a target_waitstatus to
6109 get_last_target_status.
6110 (info_program_command): Don't pass a target_waitstatus to
6111 get_last_target_status.
6112 * infrun.c (init_wait_for_inferior): Use
6113 nullify_last_target_wait_ptid.
6114 (get_last_target_status): Handle nullptr arguments.
6115 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
6116 (print_stop_event): Don't pass a ptid to get_last_target_status.
6117 (normal_stop): Don't pass a ptid to get_last_target_status.
6118 * infrun.h (get_last_target_status, set_last_target_status): Move
6119 comments here and update.
6120 (nullify_last_target_wait_ptid): Declare.
6121 * linux-fork.c (fork_load_infrun_state): Remove local extern
6122 declaration of nullify_last_target_wait_ptid.
6123 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
6124 to get_last_target_status.
6125
6126 2020-01-10 Pedro Alves <palves@redhat.com>
6127
6128 * gdbthread.h (scoped_restore_current_thread)
6129 <dont_restore, restore, m_dont_restore>: Declare.
6130 * thread.c (thread_alive): Add assertion. Return bool.
6131 (switch_to_thread_if_alive): New.
6132 (prune_threads): Switch inferior/thread.
6133 (print_thread_info_1): Switch thread before calling target methods.
6134 (scoped_restore_current_thread::restore): New, factored out from
6135 ...
6136 (scoped_restore_current_thread::~scoped_restore_current_thread):
6137 ... this.
6138 (scoped_restore_current_thread::scoped_restore_current_thread):
6139 Add assertion.
6140 (thread_apply_all_command, thread_select): Use
6141 switch_to_thread_if_alive.
6142 * infrun.c (proceed, restart_threads, handle_signal_stop)
6143 (switch_back_to_stepped_thread): Switch current thread before
6144 calling target methods.
6145
6146 2020-01-10 Pedro Alves <palves@redhat.com>
6147
6148 * inferior.c (switch_to_inferior_no_thread): New function,
6149 factored out from ...
6150 (inferior_command): ... here.
6151 * inferior.h (switch_to_inferior_no_thread): Declare.
6152 * mi/mi-main.c (run_one_inferior): Use
6153 switch_to_inferior_no_thread.
6154
6155 2020-01-10 Pedro Alves <palves@redhat.com>
6156
6157 * infcmd.c (kill_command): Remove dead code.
6158
6159 2020-01-10 Pedro Alves <palves@redhat.com>
6160
6161 * remote.c (remote_target::mourn_inferior): No longer check
6162 whether the target is running.
6163
6164 2020-01-10 Pedro Alves <palves@redhat.com>
6165
6166 * corelow.c (core_target::has_execution): Change parameter type to
6167 inferior pointer.
6168 * inferior.c (number_of_live_inferiors): Use
6169 inferior::has_execution instead of target_has_execution_1.
6170 * inferior.h (inferior::has_execution): New.
6171 * linux-thread-db.c (thread_db_target::update_thread_list): Use
6172 inferior::has_execution instead of target_has_execution_1.
6173 * process-stratum-target.c
6174 (process_stratum_target::has_execution): Change parameter type to
6175 inferior pointer. Check the inferior's PID instead of
6176 inferior_ptid.
6177 * process-stratum-target.h
6178 (process_stratum_target::has_execution): Change parameter type to
6179 inferior pointer.
6180 * record-full.c (record_full_core_target::has_execution): Change
6181 parameter type to inferior pointer.
6182 * target.c (target_has_execution_1): Change parameter type to
6183 inferior pointer.
6184 (target_has_execution_current): Adjust.
6185 * target.h (target_ops::has_execution): Change parameter type to
6186 inferior pointer.
6187 (target_has_execution_1): Change parameter type to inferior
6188 pointer. Change return type to bool.
6189 * tracefile.h (tracefile_target::has_execution): Change parameter
6190 type to inferior pointer.
6191
6192 2020-01-10 Pedro Alves <palves@redhat.com>
6193
6194 * exceptions.c (print_flush): Remove current_top_target() check.
6195
6196 2020-01-10 Pedro Alves <palves@redhat.com>
6197
6198 * remote.c (show_remote_exec_file): Show the current inferior's
6199 exec-file instead of the command variable's value.
6200
6201 2020-01-10 Pedro Alves <palves@redhat.com>
6202
6203 * record-full.c (record_full_resume_ptid): New global.
6204 (record_full_target::resume): Set it.
6205 (record_full_wait_1): Use record_full_resume_ptid instead of
6206 inferior_ptid.
6207
6208 2020-01-10 Pedro Alves <palves@redhat.com>
6209
6210 * gdbthread.h (scoped_restore_current_thread)
6211 <dont_restore, restore, m_dont_restore>: Declare.
6212 * thread.c (thread_alive): Add assertion. Return bool.
6213 (switch_to_thread_if_alive): New.
6214 (prune_threads): Switch inferior/thread.
6215 (print_thread_info_1): Switch thread before calling target methods.
6216 (scoped_restore_current_thread::restore): New, factored out from
6217 ...
6218 (scoped_restore_current_thread::~scoped_restore_current_thread):
6219 ... this.
6220 (scoped_restore_current_thread::scoped_restore_current_thread):
6221 Add assertion.
6222 (thread_apply_all_command, thread_select): Use
6223 switch_to_thread_if_alive.
6224
6225 2020-01-10 George Barrett <bob@bob131.so>
6226
6227 * stap-probe.c (stap_modify_semaphore): Don't check for null
6228 semaphores.
6229 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
6230 for null semaphores.
6231
6232 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
6233
6234 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
6235 all source windows, and maintain horizontal scroll status while
6236 doing so.
6237
6238 2020-01-09 Tom Tromey <tom@tromey.com>
6239
6240 PR tui/18932:
6241 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
6242 update_source_window, not print_source_lines.
6243
6244 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
6245
6246 * tui/tui.c (tui_enable): Register tui hooks after calling
6247 tui_display_main.
6248
6249 2020-01-09 Christian Biesinger <cbiesinger@google.com>
6250
6251 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
6252
6253 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
6254
6255 * thread.c (print_thread_info_1): Fix indentation.
6256
6257 2020-01-09 Christian Biesinger <cbiesinger@google.com>
6258
6259 * symtab.c (general_symbol_info::compute_and_set_names): Move the
6260 unique_xmalloc_ptr outside the if to always free the demangled name.
6261
6262 2020-01-08 Tom Tromey <tromey@adacore.com>
6263
6264 * xcoffread.c (enter_line_range, read_xcoff_symtab)
6265 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
6266 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
6267 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
6268 Remove.
6269 (section_offsets): New typedef.
6270 * symtab.c (fixup_section, get_msymbol_address): Update.
6271 * symmisc.c (dump_msymbols): Update.
6272 * symfile.h (relative_addr_info_to_section_offsets)
6273 (symfile_map_offsets_to_segments): Update.
6274 * symfile.c (build_section_addr_info_from_objfile)
6275 (init_objfile_sect_indices): Update.
6276 (struct place_section_arg): Change type of "offsets".
6277 (place_section): Update.
6278 (relative_addr_info_to_section_offsets): Change type of
6279 "section_offsets". Remove "num_sections" parameter.
6280 (default_symfile_offsets, syms_from_objfile_1)
6281 (set_objfile_default_section_offset): Update.
6282 (reread_symbols): No need to preserve section offsets by hand.
6283 (symfile_map_offsets_to_segments): Change type of "offsets".
6284 * stap-probe.c (relocate_address): Update.
6285 * stabsread.h (process_one_symbol): Update.
6286 * solib-target.c (struct lm_info_target) <offsets>: Change type.
6287 (solib_target_relocate_section_addresses): Update.
6288 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
6289 Update.
6290 * solib-frv.c (frv_relocate_main_executable): Update.
6291 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
6292 * solib-aix.c (solib_aix_get_section_offsets): Change return
6293 type.
6294 (solib_aix_solib_create_inferior_hook): Update.
6295 * remote.c (remote_target::get_offsets): Update.
6296 * psymtab.c (find_pc_sect_psymtab): Update.
6297 * psympriv.h (struct partial_symbol) <address, text_low,
6298 text_high>: Update.
6299 * objfiles.h (obj_section_offset): Update.
6300 (struct objfile) <section_offsets>: Change type.
6301 <num_sections>: Remove.
6302 (objfile_relocate): Update.
6303 * objfiles.c (entry_point_address_query): Update
6304 (relocate_one_symbol): Change type of "section_offsets".
6305 (objfile_relocate1, objfile_relocate1): Change type of
6306 "new_offsets".
6307 (objfile_rebase1): Update.
6308 * mipsread.c (mipscoff_symfile_read): Update.
6309 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
6310 parameter.
6311 * mdebugread.c (parse_symbol): Change type of "section_offsets".
6312 (parse_external, psymtab_to_symtab_1): Update.
6313 * machoread.c (macho_symfile_offsets): Update.
6314 * ia64-tdep.c (ia64_find_unwind_table): Update.
6315 * hppa-tdep.c (read_unwind_info): Update.
6316 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
6317 * dwarf2read.c (create_addrmap_from_index)
6318 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
6319 (process_psymtab_comp_unit_reader, add_partial_symbol)
6320 (add_partial_subprogram, process_full_comp_unit)
6321 (read_file_scope, read_func_scope, read_lexical_block_scope)
6322 (read_call_site_scope, dwarf2_rnglists_process)
6323 (dwarf2_ranges_process, dwarf2_ranges_read)
6324 (dwarf_decode_lines_1, var_decode_location, new_symbol)
6325 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
6326 Update.
6327 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
6328 Update.
6329 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
6330 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
6331 (process_one_symbol): Change type of "section_offsets".
6332 * ctfread.c (get_objfile_text_range): Update.
6333 * coffread.c (coff_symtab_read, enter_linenos)
6334 (process_coff_symbol): Update.
6335 * coff-pe-read.c (add_pe_forwarded_sym): Update.
6336 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
6337
6338 2020-01-08 Tom Tromey <tromey@adacore.com>
6339
6340 * dwarf2read.c (parse_macro_definition): Use std::string.
6341 (parse_macro_definition): Likewise.
6342
6343 2020-01-08 Tom Tromey <tromey@adacore.com>
6344
6345 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
6346 (ATTR_ALLOC_CHUNK): Remove.
6347
6348 2020-01-08 Tom Tromey <tromey@adacore.com>
6349
6350 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
6351
6352 2020-01-08 Tom Tromey <tromey@adacore.com>
6353
6354 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
6355 (dwarf2_compute_name, open_dwo_file): Likewise.
6356 (process_enumeration_scope): Use std::vector.
6357 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
6358 (partial_die_info::fixup, dwarf2_start_subfile)
6359 (guess_full_die_structure_name, dwarf2_name): Likewise.
6360 (determine_prefix): Update.
6361 (guess_full_die_structure_name): Make return type const.
6362 (partial_die_full_name): Return unique_xmalloc_ptr.
6363 (DW_FIELD_ALLOC_CHUNK): Remove.
6364
6365 2020-01-07 Tom Tromey <tromey@adacore.com>
6366
6367 PR build/24937:
6368 * stap-probe.c (class stap_static_probe_ops): Add constructor.
6369
6370 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
6371
6372 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
6373
6374 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
6375
6376 * stack.c (print_frame_info): Move disassemble_next_line code
6377 inside source_print block.
6378
6379 2020-01-06 Eli Zaretskii <eliz@gnu.org>
6380
6381 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
6382 gdb/signals.h, as we are now using native signal symbols.
6383
6384 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
6385
6386 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
6387 overflow by an early check of content vs threshold.
6388 * tui/tui-source.c (tui_source_window::line_is_displayed):
6389 Likewise.
6390
6391 2020-01-06 Eli Zaretskii <eliz@gnu.org>
6392
6393 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
6394
6395 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
6396
6397 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
6398 export table if no section contains it's RVA.
6399
6400 2020-01-06 Eli Zaretskii <eliz@gnu.org>
6401
6402 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
6403
6404 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
6405
6406 * source.c (print_source_lines_base): Set last_line_listed.
6407
6408 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
6409
6410 * tui/tui-disasm.c: Remove trailing spaces.
6411
6412 2020-01-06 Eli Zaretskii <eliz@gnu.org>
6413 Pedro Alves <palves@redhat.com>
6414
6415 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
6416 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
6417 (windows_gdb_signal_to_target): New function, uses the above
6418 enumeration to convert GDB internal signal codes to equivalent
6419 Windows codes.
6420 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
6421 * windows-nat.c: Include "gdb_wait.h".
6422 (get_windows_debug_event): Extract the fatal exception from the
6423 exit status and convert to the equivalent Posix signal number.
6424 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
6425 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
6426 * gdbsupport/gdb_wait.c: New file, implements
6427 windows_status_to_termsig.
6428 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
6429 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
6430
6431 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
6432
6433 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
6434 show_layout.
6435
6436 2020-01-05 Luis Machado <luis.machado@linaro.org>
6437
6438 * aarch64-linux-nat.c
6439 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
6440 and bfd_mach_aarch64.
6441
6442 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6443
6444 * ui-file.c (stdio_file::can_emit_style_escape)
6445 (tee_file::can_emit_style_escape): Ensure style is used also on
6446 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
6447 to gdb_stdout.
6448 * main.c (set_gdb_data_directory): Use file style to output the
6449 warning that the given pathname is not a directory.
6450 * top.c (show_history_filename, gdb_safe_append_history)
6451 (show_gdb_datadir): Use file style.
6452
6453 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
6454
6455 * solib-target.c (struct lm_info_target):
6456 Change offsets to be a unique_xmalloc_ptr.
6457 (solib_target_relocate_section_addresses): Update.
6458
6459 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
6460
6461 * windows-nat.c (windows_clear_solib): Free so_list linked list.
6462
6463 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
6464
6465 * MAINTAINERS (Write After Approval): Add myself.
6466
6467 2020-01-02 Luis Machado <luis.machado@linaro.org>
6468
6469 * proc-service.c (get_ps_regcache): Remove reference to obsolete
6470 Cell BE architecture.
6471 * target.h (struct target_ops) <thread_architecture>: Likewise.
6472
6473 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
6474
6475 * Makefile.in: Use INSTALL_PROGRAM_ENV.
6476
6477 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
6478
6479 * MAINTAINERS (Write After Approval): Add myself.
6480
6481 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6482
6483 * gdbarch.sh: Update copyright year range of generated files.
6484
6485 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6486
6487 Update copyright year range in all GDB files.
6488
6489 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6490
6491 * copyright.py: Convert to Python 3.
6492
6493 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6494
6495 * copyright.py: Adapt after move of gnulib directory from gdb
6496 directory to toplevel directory.
6497
6498 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6499
6500 * copyright.py (main): Exit if run from the wrong directory.
6501
6502 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6503
6504 * top.c (print_gdb_version): Change copyright year to 2020.
6505
6506 2020-01-01 Joel Brobecker <brobecker@adacore.com>
6507
6508 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
6509
6510 For older changes see ChangeLog-2019.
6511 \f
6512 Local Variables:
6513 mode: change-log
6514 left-margin: 8
6515 fill-column: 74
6516 version-control: never
6517 coding: utf-8
6518 End:
This page took 0.162685 seconds and 4 git commands to generate.