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