]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
Support several new ELF auxiliary vector types on FreeBSD.
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2020-07-09 John Baldwin <jhb@FreeBSD.org>
2
3 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
4 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
5 AT_FREEBSD_PS_STRINGS.
6
7 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
8
9 * auto-load.c (auto_load_objfile_script_1): Convert drive part
10 of debugfile path on Windows.
11
12 2020-07-08 John Baldwin <jhb@FreeBSD.org>
13
14 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
15 argument to 'data'.
16
17 2020-07-08 Tom Tromey <tromey@adacore.com>
18
19 * ada-lang.c (ada_exception_message_1): Use read_memory.
20
21 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
22
23 PR python/22748
24 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
25 special handling for inline frames.
26 * findvar.c (value_of_register_lazy): Skip inline frames when
27 creating lazy register values.
28 * frame.c (frame_id_computed_p): Delete definition.
29 * frame.h (frame_id_computed_p): Delete declaration.
30
31 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
32
33 * NEWS: Mention additions to Python API.
34 * python/py-arch.c (archpy_register_groups): New function.
35 (arch_object_methods): Add 'register_groups' method.
36 * python/py-registers.c (reggroup_iterator_object): New struct.
37 (reggroup_object): New struct.
38 (gdbpy_new_reggroup): New function.
39 (gdbpy_reggroup_to_string): New function.
40 (gdbpy_reggroup_name): New function.
41 (gdbpy_reggroup_iter): New function.
42 (gdbpy_reggroup_iter_next): New function.
43 (gdbpy_new_reggroup_iterator): New function
44 (gdbpy_initialize_registers): Register new types.
45 (reggroup_iterator_object_type): Define new Python type.
46 (gdbpy_reggroup_getset): New static global.
47 (reggroup_object_type): Define new Python type.
48 * python/python-internal.h
49
50 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
51
52 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
53 * python/py-arch.c (archpy_registers): New function.
54 (arch_object_methods): Add 'registers' method.
55 * python/py-registers.c: New file.
56 * python/python-internal.h
57 (gdbpy_new_register_descriptor_iterator): Declare.
58 (gdbpy_initialize_registers): Declare.
59 * python/python.c (do_start_initialization): Call
60 gdbpy_initialize_registers.
61 * NEWS: Mention additions to the Python API.
62
63 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
64
65 * NEWS: Mention new Python API method.
66 * python/py-unwind.c (pending_framepy_architecture): New function.
67 (pending_frame_object_methods): Add architecture method.
68
69 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
70
71 * gdbarch.c: Regenerate.
72 * gdbarch.h: Regenerate.
73 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
74 (gdbarch_data): Use internal_error for the case where
75 deprecated_set_gdbarch_data was originally needed.
76 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
77 and use passed in obstack.
78 (libunwind_frame_set_descr): Should no longer get back NULL from
79 gdbarch_data.
80 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
81 type.
82 * user-regs.c (user_regs_init): Update parameters, and use passed
83 in obstack.
84 (user_reg_add): Should no longer get back NULL from gdbarch_data.
85 (_initialize_user_regs): Register as a pre-init gdbarch data type.
86
87 2020-07-06 Tom de Vries <tdevries@suse.de>
88
89 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
90 End-Of-Sequence in lte_is_less_than.
91 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
92 "gdb: Don't reorder line table entries too much when sorting".
93
94 2020-07-06 Tom de Vries <tdevries@suse.de>
95
96 PR tui/26205
97 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
98
99 2020-07-05 Tom de Vries <tdevries@suse.de>
100
101 PR build/26187
102 * inferior.h (struct infcall_suspend_state_deleter): If available, use
103 std::uncaught_exceptions instead of deprecated
104 std::uncaught_exception.
105
106 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
107
108 * macroexp.h (macro_stringify): Return
109 gdb::unique_xmalloc_ptr<char>.
110 * macroexp.c (macro_stringify): Likewise.
111 * macrotab.c (fixup_definition): Update.
112
113 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
114
115 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
116 (lex_one_token): Update.
117 * macroexp.c (struct macro_buffer) <release>: Return
118 gdb::unique_xmalloc_ptr<char>.
119 (macro_stringify): Update.
120 (macro_expand): Update.
121 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
122 * macroexp.h (macro_expand_next): Likewise.
123
124 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
125
126 * macroexp.h (macro_lookup_ftype): Remove.
127 (macro_expand, macro_expand_once, macro_expand_next): Remove
128 lookup function parameters, add scope parameter.
129 * macroexp.c (scan, substitute_args, expand, maybe_expand,
130 macro_expand, macro_expand_once, macro_expand_next): Likewise.
131 * macroscope.h (standard_macro_lookup): Change parameter type
132 to macro_scope.
133 * macroscope.c (standard_macro_lookup): Likewise.
134 * c-exp.y (lex_one_token): Update.
135 * macrocmd.c (macro_expand_command): Likewise.
136 (macro_expand_once_command): Likewise.
137
138 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
139
140 * inf-loop.c (inferior_event_handler): Remove client_data param.
141 * inf-loop.h (inferior_event_handler): Likewise.
142 * infcmd.c (step_1): Adjust.
143 * infrun.c (proceed): Adjust.
144 (fetch_inferior_event): Remove client_data param.
145 (infrun_async_inferior_event_handler): Adjust.
146 * infrun.h (fetch_inferior_event): Remove `void *` param.
147 * linux-nat.c (handle_target_event): Adjust.
148 * record-btrace.c (record_btrace_handle_async_inferior_event):
149 Adjust.
150 * record-full.c (record_full_async_inferior_event_handler):
151 Adjust.
152 * remote.c (remote_async_inferior_event_handler): Adjust.
153
154 2020-07-01 Tom Tromey <tom@tromey.com>
155
156 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
157 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
158
159 2020-07-01 Tom Tromey <tom@tromey.com>
160
161 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
162 tui_gen_win_info.
163 (tui_win_info::make_window): Merge with
164 tui_gen_win_info::make_window.
165 (tui_win_info::make_visible): Move from tui_gen_win_info.
166 * tui/tui-win.c (tui_win_info::max_width): Move from
167 tui_gen_win_info.
168 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
169 type.
170 <window_factory>: Likewise.
171 * tui/tui-layout.c (tui_win_info::resize): Move from
172 tui_gen_win_info.
173 (make_standard_window): Change return type.
174 (get_locator_window, tui_get_window_by_name): Likewise.
175 (tui_layout_window::apply): Remove a cast.
176 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
177 (struct tui_win_info): Merge with tui_gen_win_info.
178 (struct tui_gen_win_info): Remove.
179
180 2020-07-01 Tom Tromey <tom@tromey.com>
181
182 * tui/tui-stack.h (struct tui_locator_window): Derive from
183 tui_win_info.
184 <do_scroll_horizontal, do_scroll_vertical>: New methods.
185 <can_box>: New method.
186
187 2020-07-01 Tom Tromey <tom@tromey.com>
188
189 * tui/tui-stack.h (struct tui_locator_window): Remove body.
190
191 2020-07-01 Tom Tromey <tom@tromey.com>
192
193 * tui/tui-regs.c (tui_data_window::display_registers_from)
194 (tui_data_window::display_registers_from)
195 (tui_data_window::first_data_item_displayed)
196 (tui_data_window::delete_data_content_windows): Update.
197 (tui_data_window::refresh_window, tui_data_window::no_refresh):
198 Remove.
199 (tui_data_window::check_register_values): Update.
200 (tui_data_item_window::rerender): Add parameters. Update.
201 (tui_data_item_window::refresh_window): Remove.
202 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
203 virtual.
204 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
205 tui_gen_win_info.
206 <refresh_window, max_height, min_height>: Remove.
207 <rerender>: Add parameters.
208 <x, y, visible>: New members.
209 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
210 <m_item_width>: New member.
211
212 2020-07-01 Tom Tromey <tom@tromey.com>
213
214 * tui/tui-regs.c (tui_data_window::show_register_group)
215 (tui_data_window::check_register_values): Update.
216 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
217 from item_no.
218
219 2020-07-01 Tom Tromey <tom@tromey.com>
220
221 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
222 useless "if".
223
224 2020-07-01 Tom Tromey <tom@tromey.com>
225
226 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
227 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
228
229 2020-07-01 Tom Tromey <tom@tromey.com>
230
231 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
232 * tui/tui-winsource.h (enum tui_line_or_address_kind)
233 (struct tui_line_or_address): Move from tui-data.h.
234 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
235 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
236 (tui_cmd_window, tui_source_window_base, tui_source_window)
237 (tui_disasm_window): Don't declare.
238 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
239 to tui-winsource.h.
240 (SINGLE_KEY): Move to tui-stack.c.
241
242 2020-07-01 Tom Tromey <tom@tromey.com>
243
244 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
245 std::string.
246 * tui/tui-regs.c (class tab_expansion_file): New.
247 (tab_expansion_file::write): New method.
248 (tui_register_format): Change return type. Use
249 tab_expansion_file.
250 (tui_get_register, tui_data_window::display_registers_from)
251 (tui_data_item_window::rerender): Update.
252 * tui/tui-io.h (tui_expand_tabs): Don't declare.
253 * tui/tui-io.c (tui_expand_tabs): Remove.
254
255 2020-07-01 Tom Tromey <tom@tromey.com>
256
257 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
258
259 2020-07-01 Fangrui Song <maskray@google.com>
260
261 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
262
263 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
264
265 * dwarf2/read.c (set_die_type): Removed conditions to restrict
266 forms for DW_AT_associated and DW_AT_allocated attributes,
267 which is already checked in function attr_to_dynamic_prop.
268
269 2020-06-30 Tom Tromey <tromey@adacore.com>
270
271 * dwarf2/read.c (quirk_rust_enum): Correctly call
272 alloc_rust_variant for default-less enum.
273
274 2020-06-30 Tom Tromey <tromey@adacore.com>
275
276 PR build/26183:
277 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
278 gdb::to_string.
279
280 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
281
282 * gdbarch.sh (displaced_step_copy_insn): Update doc.
283 * gdbarch.h: Re-generate.
284
285 2020-06-28 Tom Tromey <tom@tromey.com>
286
287 * command.h (cmd_types): Remove.
288 (cmd_type): Don't declare.
289 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
290 typedef.
291 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
292 * cli/cli-decode.c (cmd_type): Remove.
293
294 2020-06-27 Pedro Alves <palves@redhat.com>
295
296 * fork-child.c (prefork_hook): Adjust.
297 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
298 Delete.
299 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
300 * inferior.c (inferior::set_tty, inferior::tty): New methods.
301 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
302 Remove declarations.
303 (struct inferior) <set_tty, tty>: New methods.
304 (struct inferior) <terminal>: Rename to ...
305 (struct inferior) <m_terminal>: ... this and make private.
306 * main.c (captured_main_1): Adjust.
307 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
308 (mi_cmd_inferior_tty_show): Adjust.
309 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
310 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
311
312 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
313
314 * configure.ac: Add --enable-libctf: handle --disable-static
315 properly.
316 * acinclude.m4: sinclude ../config/enable.m4.
317 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
318 (LIBCTF): Substitute in.
319 (CTF_DEPS): New, likewise.
320 (CLIBS): libctf needs symbols from libbfd: move earlier.
321 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
322 flags.
323 * ctfread.c: Surround in ENABLE_LIBCTF.
324 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
325 * configure: Regenerate.
326 * config.in: Likewise.
327
328 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
329
330 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
331
332 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
333
334 * inferior.h (struct inferior) <terminal>: Change type to
335 gdb::unique_xmalloc_ptr<char>.
336 * inferior.c (inferior::~inferior): Don't free inf->terminal.
337 * infcmd.c (set_inferior_io_terminal): Don't free terminal
338 field, adjust to unique pointer.
339 (get_inferior_io_terminal): Adjust to unique pointer.
340
341 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
342
343 * riscv-tdep.c (riscv_print_registers_info): Loop over all
344 registers, not just the known core set of registers.
345
346 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
347
348 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
349 fflags, frm, and fcsr registers.
350 (riscv_register_reggroup_p): Remove unknown CSRs from save and
351 restore groups.
352 (riscv_tdesc_unknown_reg): New function.
353 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
354 tdesc_use_registers.
355 * riscv-tdep.h (struct gdbarch_tdep): Add
356 unknown_csrs_first_regnum, unknown_csrs_count,
357 duplicate_fflags_regnum, duplicate_frm_regnum, and
358 duplicate_fcsr_regnum fields.
359
360 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
361
362 * target-descriptions.c (tdesc_use_registers): Add new parameter a
363 callback, use the callback (when not null) to help number unknown
364 registers.
365 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
366 (tdesc_use_registers): Add extra parameter to declaration.
367
368 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
369
370 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
371 in the file.
372 (class riscv_pending_register_alias): Likewise.
373 (riscv_register_feature::register_info): Change 'required_p' field
374 to 'required', and change its type. Add 'check' member function.
375 (riscv_register_feature::register_info::check): Define new member
376 function.
377 (riscv_xreg_feature): Change initialisation of 'required' field.
378 (riscv_freg_feature): Likewise.
379 (riscv_virtual_feature): Likewise.
380 (riscv_csr_feature): Likewise.
381 (riscv_check_tdesc_feature): Take extra parameter, the csr
382 tdesc_feature, rewrite the function to use the new
383 riscv_register_feature::register_info::check function.
384 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
385
386 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
387
388 * features/Makefile: Remove all references to the deleted files
389 below.
390 * features/riscv/32bit-csr.c: Deleted.
391 * features/riscv/32bit-csr.xml: Deleted.
392 * features/riscv/64bit-csr.c: Deleted.
393 * features/riscv/64bit-csr.xml: Deleted.
394 * features/riscv/rebuild-csr-xml.sh: Deleted.
395
396 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
397
398 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
399 whitespace error for declaration of names member variable.
400 (struct riscv_register_feature): Add new prefer_first_name member
401 variable, and fix whitespace error in declaration of registers.
402 (riscv_xreg_feature): Initialize prefer_first_name field.
403 (riscv_freg_feature): Likewise.
404 (riscv_virtual_feature): Likewise.
405 (riscv_csr_feature): Likewise.
406 (riscv_register_name): Expand on comments. Remove register name
407 modifications for CSR and virtual registers.
408
409 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
410
411 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
412 errors.
413
414 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
415
416 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
417 riscv-opc.h.
418 (class riscv_pending_register_alias): New class.
419 (riscv_check_tdesc_feature): Take vector of pending aliases and
420 populate it as appropriate.
421 (riscv_setup_register_aliases): Delete.
422 (riscv_gdbarch_init): Create vector of pending aliases and pass it
423 to riscv_check_tdesc_feature in all cases. Use the vector to
424 create the register aliases.
425
426 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
427
428 * sol2-tdep.c (sol2_static_transform_name): Remove.
429 (sol2_init_abi): Don't register it.
430 * gdbarch.sh (static_transform_name): Remove.
431 * gdbarch.c, gdbarch.h: Regenerate.
432
433 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
434 gdbarch_static_transform_name.
435 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
436 * stabsread.c (define_symbol) <'X'>: Remove.
437 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
438 handling.
439 <'V'>: Likewise.
440 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
441 <'S'>: Remove call to gdbarch_static_transform_name.
442
443 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
444
445 * procfs.c (procfs_pre_trace): New function.
446 (procfs_target::create_inferior): Pass it to fork_inferior.
447
448 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
449
450 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
451 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
452 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
453 sol2-tdep.o, sparc-sol2-tdep.o.
454 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
455 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
456 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
457 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
458
459 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
460
461 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
462 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
463 Call sol2_init_abi.
464 Remove calls to set_gdbarch_skip_solib_resolver,
465 set_gdbarch_core_pid_to_str.
466 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
467 (i386_sol2_static_transform_name): Remove.
468 (i386_sol2_init_abi): Call sol2_init_abi.
469 Remove calls to set_gdbarch_sofun_address_maybe_missing,
470 set_gdbarch_static_transform_name,
471 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
472 Use sol2_sigtramp_p.
473 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
474 (sol2_sigtramp_p): New function.
475 (sol2_static_transform_name): New function.
476 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
477 (sol2_init_abi): New function.
478 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
479 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
480 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
481 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
482 (sparc_sol2_static_transform_name): Remove.
483 (sparc32_sol2_init_abi): Call sol2_init_abi.
484 Remove calls to set_gdbarch_sofun_address_maybe_missing,
485 set_gdbarch_static_transform_name,
486 set_gdbarch_skip_solib_resolver,
487 set_gdbarch_core_pid_to_str.
488 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
489 (sparc_sol2_static_transform_name): Remove
490 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
491 call sol2_sigtramp_p.
492 (sparc64_sol2_init_abi): Call sol2_init_abi.
493 Remove calls to set_gdbarch_sofun_address_maybe_missing,
494 set_gdbarch_static_transform_name,
495 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
496
497 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
498
499 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
500 * exec.c (validate_exec_file): If from_tty, set both
501 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
502 * symfile.c (symbol_file_add_with_addrs): if always_confirm
503 and from_tty, unconditionally ask a confirmation.
504
505 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
506
507 * target-descriptions.c (tdesc_architecture_name): Protect against
508 NULL pointer dereference.
509 (maint_print_xml_tdesc_cmd): New function.
510 (_initialize_target_descriptions): Register new 'maint print
511 xml-tdesc' command and give it the filename completer.
512 * NEWS: Mention new 'maint print xml-tdesc' command.
513
514 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
515
516 * target-descriptions.c (class tdesc_compatible_info): New class.
517 (struct target_desc): Change type of compatible vector.
518 (tdesc_compatible_p): Update for change in type of
519 target_desc::compatible.
520 (tdesc_compatible_info_list): New function.
521 (tdesc_compatible_info_arch_name): New function.
522 (tdesc_add_compatible): Update for change in type of
523 target_desc::compatible.
524 (print_c_tdesc::visit_pre): Likewise.
525
526 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
527
528 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
529 whitespace to underscore.
530 (maint_print_c_tdesc_cmd): Use fake filename for target
531 descriptions that came from the target.
532 (_initialize_target_descriptions): Add filename command completion
533 for 'maint print c-tdesc'.
534
535 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
536
537 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
538 lines.
539
540 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
541
542 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
543 lines.
544 (dwarf2_find_location_expression): Likewise.
545 (call_site_parameter_matches): Likewise.
546 (dwarf2_compile_expr_to_ax): Likewise.
547 (disassemble_dwarf_expression): Likewise.
548 (loclist_describe_location): Likewise.
549
550 2020-06-23 Pedro Alves <palves@redhat.com>
551
552 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
553 progspace-and-thread.h. Include scoped-mock-context.h instead.
554 (register_to_value_test): Use scoped_mock_context.
555 * regcache.c: Include "scoped-mock-context.h".
556 (cooked_read_test): Don't error out if a target is already pushed.
557 Use scoped_mock_context. Adjust.
558 * scoped-mock-context.h: New file.
559
560 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
561
562 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
563 initializer.
564 (ada_language::is_string_type_p): New member function.
565 * c-lang.c (c_language_data): Delete la_is_string_type_p
566 initializer.
567 (cplus_language_data): Likewise.
568 (asm_language_data): Likewise.
569 (minimal_language_data): Likewise.
570 * d-lang.c (d_language_data): Likewise.
571 * f-lang.c (f_is_string_type_p): Delete function, implementation
572 moved to f_language::is_string_type_p.
573 (f_language_data): Delete la_is_string_type_p initializer.
574 (f_language::is_string_type_p): New member function,
575 implementation from f_is_string_type_p.
576 * go-lang.c (go_is_string_type_p): Delete function, implementation
577 moved to go_language::is_string_type_p.
578 (go_language_data): Delete la_is_string_type_p initializer.
579 (go_language::is_string_type_p): New member function,
580 implementation from go_is_string_type_p.
581 * language.c (language_defn::is_string_type_p): Define new member
582 function.
583 (default_is_string_type_p): Make static, add comment copied from
584 header file.
585 (unknown_language_data): Delete la_is_string_type_p initializer.
586 (unknown_language::is_string_type_p): New member function.
587 (auto_language_data): Delete la_is_string_type_p initializer.
588 (auto_language::is_string_type_p): New member function.
589 * language.h (language_data): Delete la_is_string_type_p field.
590 (language_defn::is_string_type_p): Declare new function.
591 (default_is_string_type_p): Delete desclaration, move comment to
592 definition.
593 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
594 moved to m2_language::is_string_type_p.
595 (m2_language_data): Delete la_is_string_type_p initializer.
596 (m2_language::is_string_type_p): New member function,
597 implementation from m2_is_string_type_p.
598 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
599 initializer.
600 * opencl-lang.c (opencl_language_data): Likewise.
601 * p-lang.c (pascal_is_string_type_p): Delete function,
602 implementation moved to pascal_language::is_string_type_p.
603 (pascal_language_data): Delete la_is_string_type_p initializer.
604 (pascal_language::is_string_type_p): New member function,
605 implementation from pascal_is_string_type_p.
606 * rust-lang.c (rust_is_string_type_p): Delete function,
607 implementation moved to rust_language::is_string_type_p.
608 (rust_language_data): Delete la_is_string_type_p initializer.
609 (rust_language::is_string_type_p): New member function,
610 implementation from rust_is_string_type_p.
611 * valprint.c (val_print_scalar_or_string_type_p): Update call to
612 is_string_type_p.
613
614 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
615
616 * ada-lang.c (ada_language_data): Delete la_print_typedef
617 initializer.
618 (ada_language::print_typedef): New member function.
619 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
620 (cplus_language_data): Likewise.
621 (asm_language_data): Likewise.
622 (minimal_language_data): Likewise.
623 * d-lang.c (d_language_data): Likewise.
624 * f-lang.c (f_language_data): Likewise.
625 (f_language::print_typedef): New member function.
626 * go-lang.c (go_language_data): Delete la_print_typedef
627 initializer.
628 * language.c (language_defn::print_typedef): Define member
629 function.
630 (unknown_language_data): Delete la_print_typedef initializer.
631 (unknown_language::print_typedef): New member function.
632 (auto_language_data): Delete la_print_typedef initializer.
633 (auto_language::print_typedef): New member function.
634 * language.h (language_data): Delete la_print_typedef field.
635 (language_defn::print_typedef): Declare new member function.
636 (LA_PRINT_TYPEDEF): Update call to print_typedef.
637 (default_print_typedef): Delete declaration.
638 * m2-lang.c (m2_language_data): Delete la_print_typedef
639 initializer.
640 (m2_language::print_typedef): New member function.
641 * objc-lang.c (objc_language_data): Delete la_print_typedef
642 initializer.
643 * opencl-lang.c (opencl_language_data): Likewise.
644 * p-lang.c (pascal_language_data): Likewise.
645 (pascal_language::print_typedef): New member function.
646 * rust-lang.c (rust_print_typedef): Delete function,
647 implementation moved to rust_language::print_typedef.
648 (rust_language): Delete la_print_typedef initializer.
649 (rust_language::print_typedef): New member function,
650 implementation from rust_print_typedef.
651 * typeprint.c (default_print_typedef): Delete.
652
653 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
654
655 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
656 (ada_language::printstr): New member function.
657 * c-lang.c (c_language_data): Delete la_printstr initializer.
658 (cplus_language_data): Likewise.
659 (asm_language_data): Likewise.
660 (minimal_language_data): Likewise.
661 * d-lang.c (d_language_data): Likewise.
662 * f-lang.c (f_printstr): Rename to f_language::printstr.
663 (f_language_data): Delete la_printstr initializer.
664 (f_language::printstr): New member function, implementation from
665 f_printstr.
666 * go-lang.c (go_language_data): Delete la_printstr initializer.
667 * language.c (language_defn::printstr): Define new member
668 function.
669 (unk_lang_printstr): Delete.
670 (unknown_language_data): Delete la_printstr initializer.
671 (unknown_language::printstr): New member function.
672 (auto_language_data): Delete la_printstr initializer.
673 (auto_language::printstr): New member function.
674 * language.h (language_data): Delete la_printstr field.
675 (language_defn::printstr): Declare new member function.
676 (LA_PRINT_STRING): Update call to printstr.
677 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
678 (m2_language_data): Delete la_printstr initializer.
679 (m2_language::printstr): New member function, implementation from
680 m2_printstr.
681 * objc-lang.c (objc_language_data): Delete la_printstr
682 initializer.
683 * opencl-lang.c (opencl_language_data): Likewise.
684 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
685 (pascal_language_data): Delete la_printstr initializer.
686 (pascal_language::printstr): New member function, implementation
687 from pascal_printstr.
688 * p-lang.h (pascal_printstr): Delete declaration.
689 * rust-lang.c (rust_printstr): Update header comment.
690 (rust_language_data): Delete la_printstr initializer.
691 (rust_language::printstr): New member function.
692
693 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
694
695 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
696 (ada_language::printchar): New member function.
697 * c-lang.c (c_language_data): Delete la_printchar initializer.
698 (cplus_language_data): Likewise.
699 (asm_language_data): Likewise.
700 (minimal_language_data): Likewise.
701 * d-lang.c (d_language_data): Likewise.
702 * f-lang.c (f_printchar): Rename to f_language::printchar.
703 (f_language_data): Delete la_printchar initializer.
704 (f_language::printchar): New member function, implementation from
705 f_printchar.
706 * go-lang.c (go_language_data): Delete la_printchar initializer.
707 * language.c (unk_lang_printchar): Delete.
708 (language_defn::printchar): Define new member function.
709 (unknown_language_data): Delete la_printchar initializer.
710 (unknown_language::printchar): New member function.
711 (auto_language_data): Delete la_printchar initializer.
712 (auto_language::printchar): New member function.
713 * language.h (language_data): Delete la_printchar field.
714 (language_defn::printchar): Declare new member function.
715 (LA_PRINT_CHAR): Update call to printchar.
716 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
717 (m2_language::printchar): New member function.
718 * objc-lang.c (objc_language_data): Delete la_printchar
719 initializer.
720 * opencl-lang.c (opencl_language_data): Likewise.
721 * p-lang.c (pascal_language_data): Delete la_printchar
722 initializer.
723 (pascal_language::printchar): New member function.
724 * rust-lang.c (rust_printchar): Rename to
725 rust_language::printchar.
726 (rust_language_data): Delete la_printchar initializer.
727 (rust_language::printchar): New member function, implementation
728 from rust_printchar.
729
730 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
731
732 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
733 (ada_language_data): Delete la_emitchar initializer.
734 (ada_language::emitchar): New member function, implementation from
735 emit_char.
736 * c-lang.c (c_language_data): Delete la_emitchar initializer.
737 (cplus_language_data): Likewise.
738 (asm_language_data): Likewise.
739 (minimal_language_data): Likewise.
740 * d-lang.c (d_language_data): Likewise.
741 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
742 (f_language_data): Delete la_emitchar initializer.
743 (f_language::emitchar): New member function, implementation from
744 f_emit_char.
745 * go-lang.c (go_language_data): Delete la_emitchar initializer.
746 * language.c (unk_lang_emit_char): Delete.
747 (language_defn::emitchar): New member function definition.
748 (unknown_language_data): Delete la_emitchar initializer.
749 (unknown_language::emitchar): New member function.
750 (auto_language_data): Delete la_emitchar initializer.
751 (auto_language::emitchar): New member function.
752 * language.h (language_data): Delete la_emitchar field.
753 (language_defn::emitchar): New member field declaration.
754 (LA_EMIT_CHAR): Update call to emitchar.
755 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
756 (m2_language_data): Delete la_emitchar initializer.
757 (m2_language::emitchar): New member function, implementation from
758 m2_emit_char.
759 * objc-lang.c (objc_language_data): Delete la_emitchar
760 initializer.
761 * opencl-lang.c (opencl_language_data): Likewise.
762 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
763 (pascal_language_data): Delete la_emitchar initializer.
764 (pascal_language::emitchar): New member function, implementation
765 from pascal_emit_char.
766 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
767 (rust_language_data): Delete la_emitchar initializer.
768 (rust_language::emitchar): New member function, implementation
769 from rust_emitchar.
770
771 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
772
773 * ada-lang.c (resolve): Rename to ada_language::post_parser.
774 (ada_language_data): Delete la_post_parser initializer.
775 (ada_language::post_parser): New member function.
776 * c-lang.c (c_language_data): Delete la_post_parser initializer.
777 (cplus_language_data): Likewise.
778 (asm_language_data): Likewise.
779 (minimal_language_data): Likewise.
780 * d-lang.c (d_language_data): Likewise.
781 * f-lang.c (f_language_data): Likewise.
782 * go-lang.c (go_language_data): Likewise.
783 * language.c (unknown_language_data): Likewise.
784 (auto_language_data): Likewise.
785 * language.h (language_data): Delete la_post_parser field.
786 (language_defn::post_parser): New member function.
787 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
788 * objc-lang.c (objc_language_data): Likewise.
789 * opencl-lang.c (opencl_language_data): Likewise.
790 * p-lang.c (pascal_language_data): Likewise.
791 * parse.c (parse_exp_in_context): Update call to post_parser.
792 (null_post_parser): Delete definition.
793 * parser-defs.h (null_post_parser): Delete declaration.
794 * rust-lang.c (rust_language_data): Delete la_post_parser
795 initializer.
796
797 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
798
799 * ada-lang.c (parse): Rename to ada_language::parser.
800 (ada_language_data): Delete la_parser initializer.
801 (ada_language::parser): New member function, implementation from
802 parse.
803 * c-lang.c (c_language_data): Delete la_parser initializer.
804 (cplus_language_data): Likewise.
805 (asm_language_data): Likewise.
806 (minimal_language_data): Likewise.
807 * d-lang.c (d_language_data): Likewise.
808 (d_language::parser): New member function.
809 * f-lang.c (f_language_data): Delete la_parser initializer.
810 (f_language::parser): New member function.
811 * go-lang.c (go_language_data): Delete la_parser initializer.
812 (go_language::parser): New member function.
813 * language.c (unk_lang_parser): Delete.
814 (language_defn::parser): Define new member function.
815 (unknown_language_data): Delete la_parser initializer.
816 (unknown_language::parser): New member function.
817 (auto_language_data): Delete la_parser initializer.
818 (auto_language::parser): New member function.
819 * language.h (language_data): Delete la_parser field.
820 (language_defn::parser): Declare new member function.
821 * m2-lang.c (m2_language_data): Delete la_parser initializer.
822 (m2_language::parser): New member function.
823 * objc-lang.c (objc_language_data): Delete la_parser initializer.
824 * opencl-lang.c (opencl_language_data): Likewise.
825 * p-lang.c (pascal_language_data): Likewise.
826 (pascal_language::parser): New member function.
827 * parse.c (parse_exp_in_context): Update call to parser.
828 * rust-lang.c (rust_language_data): Delete la_parser initializer.
829 (rust_language::parser): New member function.
830
831 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
832
833 * top.c (print_gdb_configuration): Print --with-python-libdir
834 configuration value.
835
836 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
837
838 * NEWS: Mention change to the alias command.
839
840 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
841
842 * cli/cli-cmds.c (lookup_cmd_for_default_args)
843 (alias_command_completer)
844 (make_alias_options_def_group): New functions.
845 (alias_opts, alias_option_defs): New struct and array.
846 (alias_usage_error): Update usage.
847 (alias_command): Handles optional DEFAULT-ARGS... arguments.
848 Use option framework.
849 (_initialize_cli_cmds): Update alias command help.
850 Update aliases command help.
851 (show_user):
852 Add NULL for new default_args lookup_cmd argument.
853 (valid_command_p): Rename to validate_aliased_command.
854 Add NULL for new default_args lookup_cmd argument. Verify that the
855 aliased_command has no default args.
856 * cli/cli-decode.c (help_cmd): Show aliases definitions.
857 (lookup_cmd_1, lookup_cmd): New argument default_args.
858 (add_alias_cmd):
859 Add NULL for new default_args lookup_cmd argument.
860 (print_help_for_command): Show default args under the layout
861 alias some_alias = some_aliased_cmd some_alias_default_arg.
862 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
863 xfree default_args in destructor.
864 * cli/cli-script.c (process_next_line, do_define_command):
865 Add NULL for new default_args lookup_cmd argument.
866 * command.h: Declare new default_args argument in lookup_cmd
867 and lookup_cmd_1.
868 * completer.c (complete_line_internal_1):
869 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
870 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
871 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
872 Likewise.
873 * infcmd.c (_initialize_infcmd): Likewise.
874 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
875 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
876 * python/py-param.c (add_setshow_generic): Likewise.
877 * remote.c (_initialize_remote): Likewise.
878 * top.c (execute_command): Prepend default_args if command has some.
879 (set_verbose):
880 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
881 * tracepoint.c (validate_actionline, encode_actions_1):
882 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
883
884 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
885
886 * jit.c (jit_read_descriptor): Use bool as the return type.
887 (jit_breakpoint_re_set_internal): Use bool as the return type.
888 Invert the return value logic; return true if the jit breakpoint
889 has been successfully initialized.
890 (jit_inferior_init): Update the call to
891 jit_breakpoint_re_set_internal.
892
893 2020-06-22 Pedro Alves <palves@redhat.com>
894
895 PR gdb/25939
896 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
897 Use the current inferior instead. Don't return
898 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
899 wait again.
900 * sol-thread.c (sol_thread_target::wait): Don't reference
901 inferior_ptid.
902 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
903 (sol_update_thread_list_callback): Use the current inferior's pid
904 instead of inferior_ptid.
905
906 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
907
908 * procfs.c: Cleanup many comments.
909
910 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
911 (AFTER_WATCHFLAG): Replace by value.
912
913 (MAIN_PROC_NAME_FORMAT): Inline ...
914 (create_procinfo): ... here.
915
916 (procfs_debug_inferior): Remove SYS_exec handling.
917 (syscall_is_exec): Likewise.
918 (procfs_set_exec_trap): Likewise.
919
920 (syscall_is_lwp_exit): Inline in callers.
921 (syscall_is_exit): Likewise.
922 (syscall_is_exec): Likewise.
923 (syscall_is_lwp_create): Likewise.
924
925 (invalidate_cache): Remove #if 0 code.
926
927 (make_signal_thread_runnable): Remove.
928 (procfs_target::resume): Remove #if 0 code.
929
930 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
931
932 PR gdb/25939
933 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
934 call ...
935 (procfs_target::create_inferior): ... here.
936
937 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
938
939 * exec.c (validate_exec_file): Ensure the build-id is up to
940 date by calling reopen_exec_file (that checks file timestamp
941 to decide to re-read the file).
942
943 2020-06-18 Pedro Alves <palves@redhat.com>
944
945 PR gdb/25412
946 * gdbthread.h (delete_thread, delete_thread_silent)
947 (find_thread_ptid): Update comments.
948 * thread.c (current_thread_): New global.
949 (is_current_thread): Move higher, and reimplement.
950 (inferior_thread): Reimplement.
951 (set_thread_exited): Use bool. Add assertions.
952 (add_thread_silent): Simplify thread-reuse handling by always
953 calling delete_thread.
954 (delete_thread): Remove intro comment.
955 (find_thread_ptid): Skip exited threads.
956 (switch_to_thread_no_regs): Write to current_thread_.
957 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
958 INFERIOR_PTID. Clear current_thread_.
959
960 2020-06-18 Pedro Alves <palves@redhat.com>
961
962 * aix-thread.c (pd_update): Use switch_to_thread.
963
964 2020-06-18 Pedro Alves <palves@redhat.com>
965
966 * ravenscar-thread.c (ravenscar_thread_target): Update.
967 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
968 (ravenscar_thread_target::add_active_thread): ... this. Don't
969 set m_base_ptid here. Update to avoid referencing inferior_ptid.
970 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
971
972 2020-06-18 Pedro Alves <palves@redhat.com>
973
974 * nat/windows-nat.c (current_windows_thread): Remove.
975 * nat/windows-nat.h (current_windows_thread): Remove.
976 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
977 Adjust.
978 (display_selectors): Adjust to fetch the current
979 windows_thread_info based on inferior_ptid.
980 (fake_create_process): No longer write to current_windows_thread.
981 (windows_nat_target::get_windows_debug_event):
982 Don't set inferior_ptid or current_windows_thread.
983 (windows_nat_target::wait): Adjust to not rely on
984 current_windows_thread.
985 (do_initial_windows_stuff): Now a method of windows_nat_target.
986 Switch to the last_ptid thread.
987 (windows_nat_target::attach): Adjust.
988 (windows_nat_target::detach): Use switch_to_no_thread instead of
989 writing to inferior_ptid directly.
990 (windows_nat_target::create_inferior): Adjust.
991
992 2020-06-18 Pedro Alves <palves@redhat.com>
993
994 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
995
996 2020-06-18 Pedro Alves <palves@redhat.com>
997
998 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
999 after creating it, instead of writing to inferior_ptid. Don't
1000 write to inferior_ptid.
1001
1002 2020-06-18 Pedro Alves <palves@redhat.com>
1003
1004 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
1005
1006 2020-06-18 Pedro Alves <palves@redhat.com>
1007
1008 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
1009 it, instead of writing to inferior_ptid.
1010
1011 2020-06-18 Pedro Alves <palves@redhat.com>
1012
1013 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
1014 to inferior_ptid.
1015
1016 2020-06-18 Pedro Alves <palves@redhat.com>
1017
1018 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
1019 instead of writing to inferior_ptid directly.
1020
1021 2020-06-18 Pedro Alves <palves@redhat.com>
1022
1023 * corelow.c (core_target::close): Use switch_to_no_thread instead
1024 of writing to inferior_ptid directly.
1025 (add_to_thread_list, core_target_open): Use switch_to_thread
1026 instead of writing to inferior_ptid directly.
1027
1028 2020-06-18 Pedro Alves <palves@redhat.com>
1029
1030 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
1031 inferior_ptid.
1032 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
1033 inferior_ptid.
1034 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
1035 inferior_ptid directly.
1036 (darwin_nat_target::init_thread_list): Switch to thread, instead
1037 of writing to inferior_ptid.
1038 (darwin_nat_target::attach): Don't write to inferior_ptid.
1039 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
1040
1041 2020-06-18 Pedro Alves <palves@redhat.com>
1042
1043 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
1044 thread.
1045 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
1046 Instead use switch_to_thread.
1047 (gnu_nat_target::detach): Use switch_to_no_thread
1048 instead of writing to inferior_ptid directly. Used passed-in
1049 inferior instead of looking up the inferior by pid.
1050
1051 2020-06-18 Pedro Alves <palves@redhat.com>
1052
1053 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
1054 inferior_ptid.
1055
1056 2020-06-18 Pedro Alves <palves@redhat.com>
1057
1058 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
1059 inferior_ptid.
1060 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
1061 thread.
1062 (nto_procfs_target::detach): Avoid referencing
1063 inferior_ptid. Use switch_to_no_thread instead of writing to
1064 inferior_ptid directly.
1065 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
1066 instead of writing to inferior_ptid directly.
1067 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
1068 to thread.
1069
1070 2020-06-18 Pedro Alves <palves@redhat.com>
1071
1072 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
1073 after creating it, instead of writing to inferior_ptid.
1074 (gdbsim_target_open): Use switch_to_no_thread instead of writing
1075 to inferior_ptid directly.
1076 (gdbsim_target::wait): Don't write to inferior_ptid.
1077
1078 2020-06-18 Pedro Alves <palves@redhat.com>
1079
1080 * remote.c (remote_target::remote_notice_new_inferior): Use
1081 switch_to_thread instead of writing to inferior_ptid directly.
1082 (remote_target::add_current_inferior_and_thread): Use
1083 switch_to_no_thread instead of writing to inferior_ptid directly.
1084 (extended_remote_target::attach): Use switch_to_inferior_no_thread
1085 and switch_to_thread instead of using set_current_inferior or
1086 writing to inferior_ptid directly.
1087
1088 2020-06-18 Pedro Alves <palves@redhat.com>
1089
1090 * tracectf.c (ctf_target_open): Switch to added thread instead of
1091 writing to inferior_ptid directly.
1092 (ctf_target::close): Use switch_to_no_thread instead of writing to
1093 inferior_ptid directly.
1094
1095 2020-06-18 Pedro Alves <palves@redhat.com>
1096
1097 * tracefile-tfile.c (tfile_target_open): Don't write to
1098 inferior_ptid directly, instead switch to added thread.
1099 (tfile_target::close): Use switch_to_no_thread instead of writing
1100 to inferior_ptid directly.
1101
1102 2020-06-18 Pedro Alves <palves@redhat.com>
1103
1104 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
1105 (procfs_target::detach): Use switch_to_no_thread
1106 instead of writing to inferior_ptid directly.
1107 (do_attach): Change return type to void. Switch to the added
1108 thread.
1109 (procfs_target::create_inferior): Switch to the added thread.
1110 (procfs_do_thread_registers): Don't write to inferior_ptid.
1111
1112 2020-06-18 Pedro Alves <palves@redhat.com>
1113
1114 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
1115 of writing to inferior_ptid.
1116 (scoped_restore_exited_inferior): Delete.
1117 (handle_vfork_child_exec_or_exit): Simplify using
1118 scoped_restore_current_pspace_and_thread. Use switch_to_thread
1119 instead of writing to inferior_ptid.
1120 (THREAD_STOPPED_BY): Delete.
1121 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
1122 (thread_stopped_by_hw_breakpoint): Delete.
1123 (save_waitstatus): Use
1124 scoped_restore_current_thread+switch_to_thread, and call
1125 target_stopped_by_watchpoint instead of
1126 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
1127 instead of thread_stopped_by_sw_breakpoint, and
1128 target_stopped_by_hw_breakpoint instead of
1129 thread_stopped_by_hw_breakpoint.
1130 (handle_inferior_event)
1131 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
1132 inferior_ptid directly, nor
1133 set_current_inferior/set_current_program_space. Use
1134 switch_to_thread / switch_to_inferior_no_thread instead.
1135
1136 2020-06-18 Pedro Alves <palves@redhat.com>
1137
1138 * target.c (generic_mourn_inferior): Use switch_to_no_thread
1139 instead of writing to inferior_ptid.
1140
1141 2020-06-18 Pedro Alves <palves@redhat.com>
1142
1143 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
1144 added thread.
1145 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
1146 to the added thread.
1147 (inf_ptrace_target::detach_success): Use switch_to_no_thread
1148 instead of writing to inferior_ptid.
1149
1150 2020-06-18 Pedro Alves <palves@redhat.com>
1151
1152 * gdbarch-selftests.c: Include "progspace-and-thread.h".
1153 (register_to_value_test): Mock a program_space too. Heap-allocate
1154 the address space. Don't write to inferior_ptid. Use
1155 switch_to_thread instead.
1156
1157 2020-06-18 Pedro Alves <palves@redhat.com>
1158
1159 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
1160 Delete.
1161 (find_signalled_thread()): New, factored out from
1162 linux_make_corefile_notes and adjusted to handle exited threads.
1163 (linux_make_corefile_notes): Adjust to use the new
1164 find_signalled_thread.
1165
1166 2020-06-18 Pedro Alves <palves@redhat.com>
1167
1168 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
1169 of saving/restoring inferior_ptid.
1170
1171 2020-06-17 Tom Tromey <tom@tromey.com>
1172
1173 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
1174 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
1175 declare.
1176 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
1177
1178 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
1179
1180 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
1181 of partial symtabs.
1182
1183 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1184
1185 * regformats/reg-arm.dat: Remove.
1186 * regformats/reg-bfin.dat: Remove.
1187 * regformats/reg-cris.dat: Remove.
1188 * regformats/reg-crisv32.dat: Remove.
1189 * regformats/reg-m32r.dat: Remove.
1190 * regformats/reg-tilegx.dat: Remove.
1191 * regformats/reg-tilegx32.dat: Remove.
1192
1193 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1194
1195 * features/Makefile (WHICH): Remove arm files.
1196 * regformats/arm/arm-with-iwmmxt.dat: Remove.
1197 * regformats/arm/arm-with-neon.dat: Remove.
1198 * regformats/arm/arm-with-vfpv2.dat: Remove.
1199 * regformats/arm/arm-with-vfpv3.dat: Remove.
1200
1201 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1202
1203 * features/Makefile (XMLTOC): Remove rx.xml.
1204
1205 2020-06-17 Pedro Alves <palves@redhat.com>
1206
1207 * gdbthread.h (thread_control_state) <trap_expected> Update
1208 comments.
1209
1210 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1211
1212 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
1213 ada_language::lookup_symbol_nonlocal.
1214 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
1215 (ada_language::lookup_symbol_nonlocal): New member function,
1216 implementation from ada_lookup_symbol_nonlocal.
1217 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
1218 initializer.
1219 (cplus_language_data): Delete la_lookup_symbol_nonlocal
1220 initializer.
1221 (cplus_language::lookup_symbol_nonlocal): New member function.
1222 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
1223 (minimal_language_data) Likewise.
1224 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
1225 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
1226 initializer.
1227 (d_language::lookup_symbol_nonlocal): New member function.
1228 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
1229 initializer.
1230 (f_language::lookup_symbol_nonlocal): New member function.
1231 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
1232 initializer.
1233 * language.c (unknown_language_data): Likewise.
1234 (auto_language_data): Likewise.
1235 * language.h (language_data): Delete la_lookup_symbol_nonlocal
1236 field.
1237 (language_defn::lookup_symbol_nonlocal): New member function.
1238 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
1239 initializer.
1240 * objc-lang.c (objc_language_data): Likewise.
1241 * opencl-lang.c (opencl_language_data): Likewise.
1242 * p-lang.c (pascal_language_data): Likewise.
1243 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
1244 rust_language::lookup_symbol_nonlocal.
1245 (rust_language_data): Delete la_lookup_symbol_nonlocal
1246 initializer.
1247 (rust_language::lookup_symbol_nonlocal): New member function,
1248 implementation from rust_lookup_symbol_nonlocal.
1249 * symtab.c (lookup_symbol_aux): Update call to
1250 lookup_symbol_nonlocal.
1251 (basic_lookup_symbol_nonlocal): Rename to...
1252 (language_defn::lookup_symbol_nonlocal): ...this, and update
1253 header comment. Remove language_defn parameter, and replace with
1254 uses of `this'.
1255 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
1256
1257 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1258
1259 * ada-lang.c (ada_language_data): Delete la_value_print_inner
1260 initializer.
1261 (ada_language::value_print_inner): New member function.
1262 * c-lang.c (c_language_data): Delete la_value_print_inner
1263 initializer.
1264 (cplus_language_data): Likewise.
1265 (asm_language_data): Likewise.
1266 (minimal_language_data): Likewise.
1267 * d-lang.c (d_language_data): Likewise.
1268 (d_language::value_print_inner): New member function.
1269 * f-lang.c (f_language_data): Delete la_value_print_inner
1270 initializer.
1271 (f_language::value_print_inner): New member function.
1272 * f-lang.h (f_value_print_innner): Rename to...
1273 (f_value_print_inner): ...this (note spelling of 'inner').
1274 * f-valprint.c (f_value_print_innner): Rename to...
1275 (f_value_print_inner): ...this (note spelling of 'inner').
1276 * go-lang.c (go_language_data): Delete la_value_print_inner
1277 initializer.
1278 (go_language::value_print_inner): New member function.
1279 * language.c (language_defn::value_print_inner): Define new member
1280 function.
1281 (unk_lang_value_print_inner): Delete.
1282 (unknown_language_data): Delete la_value_print_inner initializer.
1283 (unknown_language::value_print_inner): New member function.
1284 (auto_language_data): Delete la_value_print_inner initializer.
1285 (auto_language::value_print_inner): New member function.
1286 * language.h (language_data): Delete la_value_print_inner field.
1287 (language_defn::value_print_inner): Delcare new member function.
1288 * m2-lang.c (m2_language_data): Delete la_value_print_inner
1289 initializer.
1290 (m2_language::value_print_inner): New member function.
1291 * objc-lang.c (objc_language_data): Delete la_value_print_inner
1292 initializer.
1293 * opencl-lang.c (opencl_language_data): Likewise.
1294 * p-lang.c (pascal_language_data): Likewise.
1295 (pascal_language::value_print_inner): New member function.
1296 * rust-lang.c (rust_language_data): Delete la_value_print_inner
1297 initializer.
1298 (rust_language::value_print_inner): New member function.
1299 * valprint.c (do_val_print): Update call to value_print_inner.
1300
1301 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1302
1303 * ada-lang.c (ada_language_data): Delete la_value_print
1304 initializer.
1305 (ada_language::value_print): New member function.
1306 * c-lang.c (c_language_data): Delete la_value_print initializer.
1307 (cplus_language_data): Likewise.
1308 (asm_language_data): Likewise.
1309 (minimal_language_data): Likewise.
1310 * d-lang.c (d_language_data): Likewise.
1311 * f-lang.c (f_language_data): Likewise.
1312 * go-lang.c (go_language_data): Likewise.
1313 * language.c (unk_lang_value_print): Delete.
1314 (language_defn::value_print): Define new member function.
1315 (unknown_language_data): Delete la_value_print initializer.
1316 (unknown_language::value_print): New member function.
1317 (auto_language_data): Delete la_value_print initializer.
1318 (auto_language::value_print): New member function.
1319 * language.h (language_data): Delete la_value_print field.
1320 (language_defn::value_print): Declare new member function.
1321 (LA_VALUE_PRINT): Update call to value_print.
1322 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
1323 * objc-lang.c (objc_language_data): Likewise.
1324 * opencl-lang.c (opencl_language_data): Likewise.
1325 * p-lang.c (pascal_language_data): Likewise.
1326 (pascal_language::value_print): New member function.
1327 * rust-lang.c (rust_language_data): Delete la_value_print
1328 initializer.
1329
1330 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1331
1332 * ada-lang.c (ada_watch_location_expression): Rename to
1333 ada_language::watch_location_expression.
1334 (ada_language_data): Delete la_watch_location_expression
1335 initializer.
1336 (ada_language::watch_location_expression): New member function,
1337 implementation from ada_watch_location_expression.
1338 * breakpoint.c (watch_command_1): Update call to
1339 watch_location_expression.
1340 * c-lang.c (c_watch_location_expression): Rename to
1341 language_defn::watch_location_expression.
1342 (c_language_data): Delete la_watch_location_expression
1343 initializer.
1344 (cplus_language_data): Likewise.
1345 (asm_language_data): Likewise.
1346 (minimal_language_data): Likewise.
1347 * c-lang.h (c_watch_location_expression): Delete declaration.
1348 * d-lang.c (d_language_data): Delete la_watch_location_expression
1349 initializer.
1350 * f-lang.c (f_language_data): Likewise.
1351 * go-lang.c (go_language_data): Likewise.
1352 * language.c (language_defn::watch_location_expression): Member
1353 function implementation from c_watch_location_expression.
1354 (unknown_language_data): Delete la_watch_location_expression
1355 initializer.
1356 (auto_language_data): Likewise.
1357 * language.h (language_data): Delete la_watch_location_expression
1358 field.
1359 (language_defn::watch_location_expression): Declare new member
1360 function.
1361 * m2-lang.c (m2_language_data): Delete
1362 la_watch_location_expression initializer.
1363 * objc-lang.c (objc_language_data): Likewise.
1364 * opencl-lang.c (opencl_language_data): Likewise.
1365 * p-lang.c (pascal_language_data): Likewise.
1366 * rust-lang.c (rust_watch_location_expression): Rename to
1367 rust_language::watch_location_expression.
1368 (rust_language_data): Delete la_watch_location_expression
1369 initializer.
1370 (rust_language::watch_location_expression): New member function,
1371 implementation from rust_watch_location_expression.
1372
1373 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1374
1375 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
1376 ada_language::collect_symbol_completion_matches.
1377 (ada_language_data): Delete la_collect_symbol_completion_matches
1378 initializer.
1379 (ada_language::collect_symbol_completion_matches): New member
1380 function, implementation from
1381 ada_collect_symbol_completion_matches.
1382 * c-lang.c (c_language_data): Delete
1383 la_collect_symbol_completion_matches initializer.
1384 (cplus_language_data): Likewise.
1385 (asm_language_data): Likewise.
1386 (minimal_language_data): Likewise.
1387 * d-lang.c (d_language_data): Likewise.
1388 * f-lang.c (f_collect_symbol_completion_matches): Rename to
1389 f_language::collect_symbol_completion_matches.
1390 (f_language_data): Delete la_collect_symbol_completion_matches
1391 initializer.
1392 (f_language::collect_symbol_completion_matches) New member
1393 function, implementation from f_collect_symbol_completion_matches.
1394 * go-lang.c (go_language_data): Delete
1395 la_collect_symbol_completion_matches initializer.
1396 * language.c (unknown_language_data): Likewise.
1397 (auto_language_data): Likewise.
1398 * language.h (language_data): Delete
1399 la_collect_symbol_completion_matches field.
1400 (language_defn::collect_symbol_completion_matches): New member
1401 function.
1402 * m2-lang.c (m2_language_data): Delete
1403 la_collect_symbol_completion_matches initializer.
1404 * objc-lang.c (objc_language_data): Likewise.
1405 * opencl-lang.c (opencl_language_data): Likewise.
1406 * p-lang.c (pascal_language_data): Likewise.
1407 * rust-lang.c (rust_language_data): Likewise.
1408 * symtab.c (default_collect_symbol_completion_matches): Delete.
1409 (collect_symbol_completion_matches): Update call to
1410 collect_symbol_completion_matches.
1411 (collect_symbol_completion_matches_type): Likewise.
1412 * symtab.h (default_collect_symbol_completion_matches): Delete
1413 declaration.
1414
1415 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1416
1417 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
1418 (ada_language_data): Delete la_word_break_characters initializer.
1419 (ada_language::word_break_characters): New member function.
1420 * c-lang.c (c_language_data): Delete la_word_break_characters
1421 initializer.
1422 (cplus_language_data): Likewise.
1423 (asm_language_data): Likewise.
1424 (minimal_language_data): Likewise.
1425 * completer.c: Update global comment.
1426 (advance_to_expression_complete_word_point): Update call to
1427 word_break_characters.
1428 (complete_files_symbols): Likewise.
1429 (complete_line_internal_1): Likewise.
1430 (default_completer_handle_brkchars): Likewise.
1431 (skip_quoted_chars): Likewise.
1432 * d-lang.c (d_language_data): Delete la_word_break_characters
1433 initializer.
1434 * f-lang.c (f_word_break_characters): Delete.
1435 (f_language_data): Delete la_word_break_characters initializer.
1436 (f_language::word_break_characters): New member function.
1437 * go-lang.c (go_language_data): Delete la_word_break_characters
1438 initializer.
1439 * language.c (unknown_language_data): Likewise.
1440 (auto_language_data): Likewise.
1441 * language.h (default_word_break_characters): Move declaration to
1442 earlier in the file.
1443 (language_data): Delete la_word_break_characters field.
1444 (language_defn::word_break_characters): New member function.
1445 * m2-lang.c (m2_language_data): Delete la_word_break_characters
1446 initializer.
1447 * objc-lang.c (objc_language_data): Likewise.
1448 * opencl-lang.c (opencl_language_data): Likewise.
1449 * p-lang.c (pascal_language_data): Likewise.
1450 * rust-lang.c (rust_language_data): Likewise.
1451
1452 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1453
1454 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
1455 (ada_language_data): Delete la_get_symbol_name_matcher
1456 initializer.
1457 (language_defn::get_symbol_name_matcher_inner): New member
1458 function.
1459 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
1460 initializer.
1461 (cplus_language_data): Likewise.
1462 (cplus_language::get_symbol_name_matcher_inner): New member
1463 function.
1464 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
1465 (minimal_language_data): Likewise.
1466 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
1467 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
1468 initializer.
1469 * dictionary.c (iter_match_first_hashed): Update call to
1470 get_symbol_name_matcher.
1471 (iter_match_next_hashed): Likewise.
1472 (iter_match_next_linear): Likewise.
1473 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
1474 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
1475 initializer.
1476 (f_language::get_symbol_name_matcher_inner): New member function.
1477 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
1478 initializer.
1479 * language.c (default_symbol_name_matcher): Update header comment,
1480 make static.
1481 (language_defn::get_symbol_name_matcher): New definition.
1482 (language_defn::get_symbol_name_matcher_inner): Likewise.
1483 (get_symbol_name_matcher): Delete.
1484 (unknown_language_data): Delete la_get_symbol_name_matcher
1485 initializer.
1486 (auto_language_data): Likewise.
1487 * language.h (language_data): Delete la_get_symbol_name_matcher
1488 field.
1489 (language_defn::get_symbol_name_matcher): New member function.
1490 (language_defn::get_symbol_name_matcher_inner): Likewise.
1491 (default_symbol_name_matcher): Delete declaration.
1492 * linespec.c (find_methods): Update call to
1493 get_symbol_name_matcher.
1494 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
1495 initializer.
1496 * minsyms.c (lookup_minimal_symbol): Update call to
1497 get_symbol_name_matcher.
1498 (iterate_over_minimal_symbols): Likewise.
1499 * objc-lang.c (objc_language_data): Delete
1500 la_get_symbol_name_matcher initializer.
1501 * opencl-lang.c (opencl_language_data): Likewise.
1502 * p-lang.c (pascal_language_data): Likewise.
1503 * psymtab.c (psymbol_name_matches): Update call to
1504 get_symbol_name_matcher.
1505 * rust-lang.c (rust_language_data): Delete
1506 la_get_symbol_name_matcher initializer.
1507 * symtab.c (symbol_matches_search_name): Update call to
1508 get_symbol_name_matcher.
1509 (compare_symbol_name): Likewise.
1510
1511 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1512
1513 * ada-lang.c (ada_language_data): Delete la_compute_program
1514 initializer.
1515 * c-lang.c (c_language_data): Likewise.
1516 (c_language::compute_program): New member function.
1517 (cplus_language_data): Delete la_compute_program initializer.
1518 (cplus_language::compute_program): New member function.
1519 (asm_language_data): Delete la_compute_program initializer.
1520 (minimal_language_data): Likewise.
1521 * c-lang.h (c_compute_program): Update comment.
1522 (cplus_compute_program): Likewise.
1523 * compile/compile-c-support.c (c_compute_program): Likewise.
1524 (cplus_compute_program): Likewise.
1525 * compile/compile.c (compile_to_object): Update call to
1526 la_compute_program.
1527 * d-lang.c (d_language_data): Delete la_compute_program
1528 initializer.
1529 * f-lang.c (f_language_data): Likewise.
1530 * go-lang.c (go_language_data): Likewise.
1531 * language.c (unknown_language_data): Likewise.
1532 (auto_language_data): Likewise.
1533 * language.h (language_data): Delete la_compute_program field.
1534 (language_defn::compute_program): New member function.
1535 * m2-lang.c (m2_language_data): Delete la_compute_program
1536 initializer.
1537 * objc-lang.c (objc_language_data): Likewise.
1538 * opencl-lang.c (opencl_language_data): Likewise.
1539 * p-lang.c (pascal_language_data): Likewise.
1540 * rust-lang.c (rust_language_data): Likewise.
1541
1542 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1543
1544 * ada-lang.c (ada_language_data) Delete
1545 la_class_name_from_physname initializer.
1546 * c-lang.c (c_language_data): Likewise.
1547 (cplus_language_data): Likewise.
1548 (cplus_language::class_name_from_physname): New member function.
1549 (asm_language_data): Delete la_class_name_from_physname
1550 initializer.
1551 (minimal_language_data): Likewise.
1552 * d-lang.c (d_language_data): Likewise.
1553 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
1554 method on language_defn class.
1555 (guess_full_die_structure_name): Likewise.
1556 * f-lang.c (f_language_data): Delete la_class_name_from_physname
1557 initializer.
1558 * go-lang.c (go_language_data): Likewise.
1559 * language.c (language_class_name_from_physname): Delete.
1560 (unk_lang_class_name): Delete.
1561 (unknown_language_data): Delete la_class_name_from_physname
1562 initializer.
1563 (auto_language_data): Likewise.
1564 * language.h (language_data): Delete la_class_name_from_physname
1565 field.
1566 (language_defn::class_name_from_physname): New function.
1567 (language_class_name_from_physname): Delete declaration.
1568 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
1569 initializer.
1570 * objc-lang.c (objc_language_data): Likewise.
1571 * opencl-lang.c (opencl_language_data): Likewise.
1572 * p-lang.c (pascal_language_data): Likewise.
1573 * rust-lang.c (rust_language_data): Likewise.
1574
1575 2020-06-16 Tom Tromey <tom@tromey.com>
1576
1577 * tui/tui-data.h (STATUS_NAME): New macro.
1578 * tui/tui-layout.c (tui_remove_some_windows)
1579 (initialize_known_windows, tui_register_window)
1580 (tui_layout_split::remove_windows, initialize_layouts)
1581 (tui_new_layout_command): Don't use hard-coded window names.
1582
1583 2020-06-16 Tom Tromey <tom@tromey.com>
1584
1585 PR tui/25348:
1586 * tui/tui.c (tui_ensure_readline_initialized): Rename from
1587 tui_initialize_readline. Only run once. Call rl_initialize.
1588 * tui/tui.h (tui_ensure_readline_initialized): Rename from
1589 tui_initialize_readline.
1590 * tui/tui-io.c (tui_setup_io): Call
1591 tui_ensure_readline_initialized.
1592 * tui/tui-interp.c (tui_interp::init): Update.
1593
1594 2020-06-16 Tom Tromey <tom@tromey.com>
1595
1596 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
1597 Also preserve the status window.
1598
1599 2020-06-16 Tom Tromey <tom@tromey.com>
1600
1601 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
1602 where m_window==nullptr.
1603
1604 2020-06-15 Tom Tromey <tromey@adacore.com>
1605
1606 * windows-nat.c (windows_nat::handle_output_debug_string):
1607 Update.
1608 (windows_nat::handle_ms_vc_exception): Update.
1609 * target.h (target_read_string): Change API.
1610 * target.c (target_read_string): Change API.
1611 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
1612 Update.
1613 * solib-frv.c (frv_current_sos): Update.
1614 * solib-dsbt.c (dsbt_current_sos): Update.
1615 * solib-darwin.c (darwin_current_sos): Update.
1616 * linux-thread-db.c (inferior_has_bug): Update.
1617 * expprint.c (print_subexp_standard): Update.
1618 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
1619 (ada_exception_message_1): Update.
1620
1621 2020-06-15 Tom Tromey <tromey@adacore.com>
1622
1623 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
1624
1625 2020-06-15 Tom Tromey <tromey@adacore.com>
1626
1627 * valprint.c (read_string): Update comment.
1628 * target.c (MIN): Remove.
1629 (target_read_string): Rewrite.
1630
1631 2020-06-15 Tom Tromey <tromey@adacore.com>
1632
1633 * corefile.c (read_memory_string): Remove.
1634 * ada-valprint.c (ada_value_print_ptr): Update.
1635 * ada-lang.h (ada_tag_name): Change return type.
1636 * ada-lang.c (type_from_tag): Update.
1637 (ada_tag_name_from_tsd): Change return type. Use
1638 target_read_string.
1639 (ada_tag_name): Likewise.
1640 * gdbcore.h (read_memory_string): Don't declare.
1641
1642 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
1643
1644 * symtab.c (rbreak_command): Ignore Windows drive colon.
1645
1646 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
1647
1648 * NEWS: Mention removed GDBserver host support.
1649
1650 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
1651
1652 * features/riscv/rebuild-csr-xml.sh: Updated.
1653
1654 2020-06-11 Tom Tromey <tom@tromey.com>
1655
1656 PR gdb/18318:
1657 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
1658
1659 2020-06-09 Jonny Grant <jg@jguk.org>
1660 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
1661
1662 * main.c (captured_main_1): Don't print new line after help.
1663 (print_gdb_help): add mailing list and IRC channel information
1664 to --help. Add new lines between items in the footer. Remove
1665 quotes around bug url.
1666
1667 2020-06-11 Keith Seitz <keiths@redhat.com>
1668
1669 PR gdb/21356
1670 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
1671 Resolve typedefs for type length calculations.
1672
1673 2020-06-10 Tom de Vries <tdevries@suse.de>
1674
1675 PR ada/24713
1676 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
1677 (write_psymbols): Enable .gdb_index for ada.
1678 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
1679 ada.
1680
1681 2020-06-10 Tom de Vries <tdevries@suse.de>
1682
1683 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
1684 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
1685 namei" instead of "const char *name" argument.
1686 (dw2_map_matching_symbols): Use "offset_type namei" variant of
1687 dw2_symtab_iter_init.
1688
1689 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1690
1691 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
1692 to use type::field and field::type instead.
1693
1694 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1695
1696 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
1697 to use field::type instead.
1698
1699 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1700
1701 * gdbtypes.h (struct field) <type, set_type>: New methods.
1702 Rename `type` field to...
1703 <m_type>: ... this. Change references throughout to use type or
1704 set_type methods.
1705 (FIELD_TYPE): Use field::type. Change call sites that modify
1706 the field's type to use field::set_type instead.
1707
1708 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1709
1710 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
1711 to use type::index_type instead.
1712
1713 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1714
1715 * gdbtypes.h (struct type) <index_type, set_index_type>: New
1716 methods.
1717 (TYPE_INDEX_TYPE): Use type::index_type.
1718 * gdbtypes.c (create_array_type_with_stride): Likewise.
1719
1720 2020-06-07 Tom Tromey <tom@tromey.com>
1721
1722 * valprint.c (generic_val_print_float): Remove "embedded_offset"
1723 parameter.
1724 (generic_value_print): Update.
1725
1726 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
1727
1728 Revert commit 982a38f60b0.
1729 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
1730
1731 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
1732
1733 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
1734 avoid use after free.
1735
1736 2020-06-05 Tom de Vries <tdevries@suse.de>
1737
1738 * NEWS: Fix typos.
1739
1740 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
1741
1742 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
1743 the per_bfd object.
1744 (dwarf2_read_debug_names): Likewise.
1745 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
1746 object when re-using a per_bfd object with an index.
1747
1748 2020-06-03 Tom de Vries <tdevries@suse.de>
1749
1750 PR symtab/26046
1751 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
1752 children for C++.
1753 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
1754 DW_TAG_subprogram.
1755
1756 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1757
1758 * ada-lang.c (ada_language_data): Delete skip_trampoline
1759 initializer.
1760 * c-lang.c (c_language_data): Likewise.
1761 (cplus_language_data): Likewise.
1762 (cplus_language::skip_trampoline): New member function.
1763 (asm_language_data): Delete skip_trampoline initializer.
1764 (minimal_language_data): Likewise.
1765 * d-lang.c (d_language_data): Likewise.
1766 * f-lang.c (f_language_data): Likewise.
1767 * go-lang.c (go_language_data): Likewise.
1768 * language.c (unk_lang_trampoline): Delete function.
1769 (skip_language_trampoline): Update.
1770 (unknown_language_data): Delete skip_trampoline initializer.
1771 (auto_language_data): Likewise.
1772 * language.h (language_data): Delete skip_trampoline field.
1773 (language_defn::skip_trampoline): New function.
1774 * m2-lang.c (m2_language_data): Delete skip_trampoline
1775 initializer.
1776 * objc-lang.c (objc_skip_trampoline): Delete function, move
1777 implementation to objc_language::skip_trampoline.
1778 (objc_language_data): Delete skip_trampoline initializer.
1779 (objc_language::skip_trampoline): New member function with
1780 implementation from objc_skip_trampoline.
1781 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
1782 initializer.
1783 * p-lang.c (pascal_language_data): Likewise.
1784 * rust-lang.c (rust_language_data): Likewise.
1785
1786 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1787
1788 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
1789 (ada_language::demangle): New member function.
1790 * c-lang.c (c_language_data): Delete la_demangle initializer.
1791 (cplus_language_data): Delete la_demangle initializer.
1792 (cplus_language::demangle): New member function.
1793 (asm_language_data): Delete la_demangle initializer.
1794 (minimal_language_data): Delete la_demangle initializer.
1795 * d-lang.c (d_language_data): Delete la_demangle initializer.
1796 (d_language::demangle): New member function.
1797 * f-lang.c (f_language_data): Delete la_demangle initializer.
1798 (f_language::demangle): New member function.
1799 * go-lang.c (go_language_data): Delete la_demangle initializer.
1800 (go_language::demangle): New member function.
1801 * language.c (language_demangle): Update.
1802 (unk_lang_demangle): Delete.
1803 (unknown_language_data): Delete la_demangle initializer.
1804 (unknown_language::demangle): New member function.
1805 (auto_language_data): Delete la_demangle initializer.
1806 (auto_language::demangle): New member function.
1807 * language.h (language_data): Delete la_demangle field.
1808 (language_defn::demangle): New function.
1809 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
1810 * objc-lang.c (objc_language_data): Delete la_demangle
1811 initializer.
1812 (objc_language::demangle): New member function.
1813 * opencl-lang.c (opencl_language_data): Delete la_demangle
1814 initializer.
1815 * p-lang.c (pascal_language_data): Likewise.
1816 * rust-lang.c (rust_language_data): Likewise.
1817 (rust_language::demangle): New member function.
1818
1819 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1820
1821 * ada-lang.c (ada_language_data): Delete la_print_type
1822 initializer.
1823 (ada_language::print_type): New member function.
1824 * c-lang.c (c_language_data): Delete la_print_type initializer.
1825 (c_language::print_type): New member function.
1826 (cplus_language_data): Delete la_print_type initializer.
1827 (cplus_language::print_type): New member function.
1828 (asm_language_data): Delete la_print_type initializer.
1829 (asm_language::print_type): New member function.
1830 (minimal_language_data): Delete la_print_type initializer.
1831 (minimal_language::print_type): New member function.
1832 * d-lang.c (d_language_data): Delete la_print_type initializer.
1833 (d_language::print_type): New member function.
1834 * f-lang.c (f_language_data): Delete la_print_type initializer.
1835 (f_language::print_type): New member function.
1836 * go-lang.c (go_language_data): Delete la_print_type initializer.
1837 (go_language::print_type): New member function.
1838 * language.c (unk_lang_print_type): Delete.
1839 (unknown_language_data): Delete la_print_type initializer.
1840 (unknown_language::print_type): New member function.
1841 (auto_language_data): Delete la_print_type initializer.
1842 (auto_language::print_type): New member function.
1843 * language.h (language_data): Delete la_print_type field.
1844 (language_defn::print_type): New function.
1845 (LA_PRINT_TYPE): Update.
1846 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
1847 (m2_language::print_type): New member function.
1848 * objc-lang.c (objc_language_data): Delete la_print_type
1849 initializer.
1850 (objc_language::print_type): New member function.
1851 * opencl-lang.c (opencl_print_type): Delete, implementation moved
1852 to opencl_language::print_type.
1853 (opencl_language_data): Delete la_print_type initializer.
1854 (opencl_language::print_type): New member function, implementation
1855 from opencl_print_type.
1856 * p-lang.c (pascal_language_data): Delete la_print_type
1857 initializer.
1858 (pascal_language::print_type): New member function.
1859 * rust-lang.c (rust_print_type): Delete, implementation moved to
1860 rust_language::print_type.
1861 (rust_language_data): Delete la_print_type initializer.
1862 (rust_language::print_type): New member function, implementation
1863 from rust_print_type.
1864
1865 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1866
1867 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
1868 implementation moves to...
1869 (ada_language::sniff_from_mangled_name): ...here. Update return
1870 type.
1871 (ada_language_data): Delete la_sniff_from_mangled_name
1872 initializer.
1873 * c-lang.c (c_language_data): Likewise.
1874 (cplus_language_data): Likewise.
1875 (cplus_language::sniff_from_mangled_name): New member function,
1876 implementation taken from gdb_sniff_from_mangled_name.
1877 (asm_language_data): Delete la_sniff_from_mangled_name
1878 initializer.
1879 (minimal_language_data): Likewise.
1880 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
1881 implementation moves to cplus_language::sniff_from_mangled_name.
1882 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
1883 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
1884 moves to...
1885 (d_language::sniff_from_mangled_name): ...here.
1886 (d_language_data): Delete la_sniff_from_mangled_name initializer.
1887 * f-lang.c (f_language_data): Likewise.
1888 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
1889 moves to...
1890 (go_language::sniff_from_mangled_name): ...here.
1891 (go_language_data): Delete la_sniff_from_mangled_name initializer.
1892 * language.c (language_sniff_from_mangled_name): Delete.
1893 (unknown_language_data): Delete la_sniff_from_mangled_name
1894 initializer.
1895 (auto_language_data): Likewise.
1896 * language.h (language_data): Delete la_sniff_from_mangled_name
1897 field.
1898 (language_defn::sniff_from_mangled_name): New function.
1899 (language_sniff_from_mangled_name): Delete declaration.
1900 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
1901 field.
1902 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
1903 implementation moves to...
1904 (objc_language::sniff_from_mangled_name): ...here.
1905 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
1906 * opencl-lang.c (opencl_language_data): Likewise.
1907 * p-lang.c (pascal_language_data): Likewise.
1908 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
1909 implementation moves to...
1910 (rust_language::sniff_from_mangled_name): ...here.
1911 (rust_language_data): Delete la_sniff_from_mangled_name
1912 initializer.
1913 * symtab.c (symbol_find_demangled_name): Call
1914 sniff_from_mangled_name member function.
1915
1916 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1917
1918 * ada-lang.c (ada_language_data): Delete la_search_name_hash
1919 initializer.
1920 * c-lang.c (c_language_data): Likewise.
1921 (cplus_language_data): Likewise.
1922 (cplus_language::search_name_hash): New member function.
1923 (asm_language_data): Delete la_search_name_hash initializer.
1924 (minimal_language_data): Likewise.
1925 * d-lang.c (d_language_data): Likewise.
1926 * dictionary.c (default_search_name_hash): Rename to...
1927 (language_defn::search_name_hash): ...this.
1928 * f-lang.c (f_language_data): Likewise.
1929 (f_language::search_name_hash): New member function.
1930 * go-lang.c (go_language_data): Delete la_search_name_hash
1931 initializer.
1932 * language.c (unknown_language_data): Likewise.
1933 (auto_language_data): Likewise.
1934 * language.h (struct language_data): Delete la_search_name_hash
1935 field.
1936 (language_defn::search_name_hash): Declare new member function.
1937 (default_search_name_hash): Delete declaration.
1938 * m2-lang.c (m2_language_data): Delete la_search_name_hash
1939 initializer.
1940 * objc-lang.c (objc_language_data): Likewise.
1941 * opencl-lang.c (opencl_language_data): Likewise.
1942 * p-lang.c (pascal_language_data): Likewise.
1943 * rust-lang.c (rust_language_data): Likewise.
1944 * symtab.c (search_name_hash): Update call.
1945
1946 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1947
1948 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
1949 initializer.
1950 * c-lang.c (class compile_instance): Declare.
1951 (c_language_data): Delete la_get_compile_instance initializer.
1952 (c_language::get_compile_instance): New member function.
1953 (cplus_language_data): Delete la_get_compile_instance initializer.
1954 (cplus_language::get_compile_instance): New member function.
1955 (asm_language_data): Delete la_get_compile_instance initializer.
1956 (minimal_language_data): Likewise.
1957 * c-lang.h (c_get_compile_context): Update comment.
1958 (cplus_get_compile_context): Update comment.
1959 * compile/compile.c (compile_to_object): Update calls, don't rely
1960 on function pointer being NULL.
1961 * d-lang.c (d_language_data): Delete la_get_compile_instance
1962 initializer.
1963 * f-lang.c (f_language_data): Likewise.
1964 * go-lang.c (go_language_data): Likewise.
1965 * language.c (unknown_language_data): Likewise.
1966 (auto_language_data): Likewise.
1967 * language.h (language_data): Delete la_get_compile_instance field.
1968 (language_defn::get_compile_instance): New member function.
1969 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
1970 initializer.
1971 * objc-lang.c (objc_language_data): Likewise.
1972 * opencl-lang.c (opencl_language_data): Likewise.
1973 * p-lang.c (pascal_language_data): Likewise.
1974 * rust-lang.c (rust_language_data): Likewise.
1975
1976 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1977
1978 * ada-lang.c (ada_add_all_symbols): Update comment.
1979 (ada_iterate_over_symbols): Delete, move implementation to...
1980 (ada_language::iterate_over_symbols): ...here, a new member
1981 function, rewrite to use range based for loop.
1982 (ada_language_data): Delete la_iterate_over_symbols initializer.
1983 * c-lang.c (c_language_data): Likewise.
1984 (cplus_language_data): Likewise.
1985 (asm_language_data): Likewise.
1986 (minimal_language_data): Likewise.
1987 * d-lang.c (d_language_data): Likewise.
1988 * f-lang.c (f_language_data): Likewise.
1989 * go-lang.c (go_language_data): Likewise.
1990 * language.c (unknown_language_data): Likewise.
1991 (auto_language_data): Likewise.
1992 * language.h (language_data): Delete la_iterate_over_symbols field.
1993 (language_defn::iterate_over_symbols): New member function.
1994 (LA_ITERATE_OVER_SYMBOLS): Update.
1995 * linespec.c (iterate_over_all_matching_symtabs): Update.
1996 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
1997 initializer.
1998 * objc-lang.c (objc_language_data): Likewise.
1999 * opencl-lang.c (opencl_language_data): Likewise.
2000 * p-lang.c (pascal_language_data): Likewise.
2001 * rust-lang.c (rust_language_data): Likewise.
2002
2003 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2004
2005 * ada-lang.c (ada_language_data): Delete
2006 la_lookup_transparent_type initializer.
2007 * c-lang.c (c_language_data): Likewise.
2008 (cplus_language_data): Likewise.
2009 (cplus_language::lookup_transparent_type): New member function.
2010 (asm_language_data): Delete la_lookup_transparent_type
2011 initializer.
2012 (minimal_language_data): Likewise.
2013 * d-lang.c (d_language_data): Likewise.
2014 * f-lang.c (f_language_data): Likewise.
2015 * go-lang.c (go_language_data): Likewise.
2016 * language.c (unknown_language_data): Likewise.
2017 (auto_language_data): Likewise.
2018 * language.h (struct language_data): Delete
2019 la_lookup_transparent_type field.
2020 (language_defn::lookup_transparent_type): New member function.
2021 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
2022 initializer.
2023 * objc-lang.c (objc_language_data): Likewise.
2024 * opencl-lang.c (opencl_language_data): Likewise.
2025 * p-lang.c (pascal_language_data): Likewise.
2026 * rust-lang.c (rust_language_data): Likewise.
2027 * symtab.c (symbol_matches_domain): Update call.
2028
2029 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2030
2031 * ada-lang.c (ada_language_arch_info): Delete function, move
2032 implementation to...
2033 (ada_language::language_arch_info): ...here, a new member
2034 function.
2035 (ada_language_data): Delete la_language_arch_info.
2036 * c-lang.c (c_language_data): Likewise.
2037 (c_language::language_arch_info): New member function.
2038 (cplus_language_arch_info): Delete function, move
2039 implementation to...
2040 (cplus_language::language_arch_info): ...here, a new member
2041 function.
2042 (cplus_language_data): Delete la_language_arch_info.
2043 (asm_language_data): Likewise.
2044 (asm_language::language_arch_info): New member function.
2045 (minimal_language_data): Delete la_language_arch_info.
2046 (minimal_language::language_arch_info): New member function.
2047 * d-lang.c (d_language_arch_info): Delete function, move
2048 implementation to...
2049 (d_language::language_arch_info): ...here, a new member
2050 function.
2051 (d_language_data): Delete la_language_arch_info.
2052 * f-lang.c (f_language_arch_info): Delete function, move
2053 implementation to...
2054 (f_language::language_arch_info): ...here, a new member
2055 function.
2056 (f_language_data): Delete la_language_arch_info.
2057 * go-lang.c (go_language_arch_info): Delete function, move
2058 implementation to...
2059 (go_language::language_arch_info): ...here, a new member
2060 function.
2061 (go_language_data): Delete la_language_arch_info.
2062 * language.c (unknown_language_data): Likewise.
2063 (unknown_language::language_arch_info): New member function.
2064 (auto_language_data): Delete la_language_arch_info.
2065 (auto_language::language_arch_info): New member function.
2066 (language_gdbarch_post_init): Update call to
2067 la_language_arch_info.
2068 * language.h (language_data): Delete la_language_arch_info
2069 function pointer.
2070 (language_defn::language_arch_info): New function.
2071 * m2-lang.c (m2_language_arch_info): Delete function, move
2072 implementation to...
2073 (m2_language::language_arch_info): ...here, a new member
2074 function.
2075 (m2_language_data): Delete la_language_arch_info.
2076 * objc-lang.c (objc_language_arch_info): Delete function, move
2077 implementation to...
2078 (objc_language::language_arch_info): ...here, a new member
2079 function.
2080 (objc_language_data): Delete la_language_arch_info.
2081 * opencl-lang.c (opencl_language_arch_info): Delete function, move
2082 implementation to...
2083 (opencl_language::language_arch_info): ...here, a new member
2084 function.
2085 (opencl_language_data): Delete la_language_arch_info.
2086 * p-lang.c (pascal_language_arch_info): Delete function, move
2087 implementation to...
2088 (pascal_language::language_arch_info): ...here, a new member
2089 function.
2090 (pascal_language_data): Delete la_language_arch_info.
2091 * rust-lang.c (rust_language_arch_info): Delete function, move
2092 implementation to...
2093 (rust_language::language_arch_info): ...here, a new member
2094 function.
2095 (rust_language_data): Delete la_language_arch_info.
2096
2097 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2098
2099 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
2100 initializer.
2101 * c-lang.c (c_language_data): Likewise.
2102 (cplus_language_data): Likewise.
2103 (cplus_language::pass_by_reference_info): New method.
2104 (asm_language_data): Delete la_pass_by_reference initializer.
2105 (minimal_language_data): Likewise.
2106 * cp-abi.c (cp_pass_by_reference): Remove use of
2107 default_pass_by_reference.
2108 * d-lang.c (d_language_data): Likewise.
2109 * f-lang.c (f_language_data): Likewise.
2110 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
2111 default_pass_by_reference.
2112 * go-lang.c (go_language_data): Likewise.
2113 * language.c (language_pass_by_reference): Update.
2114 (default_pass_by_reference): Delete.
2115 (unknown_language_data): Delete la_pass_by_reference
2116 initializer.
2117 (auto_language_data): Likewise.
2118 * language.h (struct language_data): Delete la_pass_by_reference
2119 field.
2120 (language_defn::pass_by_reference_info): New member function.
2121 (default_pass_by_reference): Delete declaration.
2122 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
2123 initializer.
2124 * objc-lang.c (objc_language_data): Likewise.
2125 * opencl-lang.c (opencl_language_data): Likewise.
2126 * p-lang.c (pascal_language_data): Likewise.
2127 * rust-lang.c (rust_language_data): Likewise.
2128
2129 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2130
2131 * ada-lang.c (ada_read_var_value): Delete function, move
2132 implementation to...
2133 (ada_language::read_var_value): ...here.
2134 (ada_language_data): Delete la_read_var_value initializer.
2135 * c-lang.c (c_language_data): Likewise.
2136 (cplus_language_data): Likewise.
2137 (minimal_language_data): Likewise.
2138 * d-lang.c (d_language_data): Likewise.
2139 * f-lang.c (f_language_data): Likewise.
2140 * findvar.c (default_read_var_value): Rename to...
2141 (language_defn::read_var_value): ...this.
2142 * findvar.c (read_var_value): Update header comment, and change to
2143 call member function instead of function pointer.
2144 * go-lang.c (go_language_data): Likewise.
2145 * language.c (unknown_language_data): Delete la_read_var_value
2146 initializer.
2147 (auto_language_data): Likewise.
2148 * language.h (struct language_data): Delete la_read_var_value
2149 field.
2150 (language_defn::read_var_value): New member function.
2151 (default_read_var_value): Delete declaration.
2152 * m2-lang.c (m2_language_data): Delete la_read_var_value
2153 initializer.
2154 * objc-lang.c (objc_language_data): Likewise.
2155 * opencl-lang.c (opencl_language_data): Likewise.
2156 * p-lang.c (pascal_language_data): Likewise.
2157 * rust-lang.c (rust_language_data): Likewise.
2158 * value.h (default_read_var_value): Delete declaration.
2159
2160 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2161
2162 * ada-lang.c (ada_print_array_index): Delete function, move
2163 implementation to...
2164 (ada_language::print_array_index): ...here.
2165 (ada_language_data): Delete la_print_array_index initializer.
2166 * c-lang.c (c_language_data): Likewise.
2167 (cplus_language_data): Likewise.
2168 (minimal_language_data): Likewise.
2169 * d-lang.c (d_language_data): Likewise.
2170 * f-lang.c (f_language_data): Likewise.
2171 * go-lang.c (go_language_data): Likewise.
2172 * language.c (default_print_array_index): Delete function, move
2173 implementation to...
2174 (language_defn::print_array_index): ...here.
2175 (unknown_language_data): Delete la_print_array_index initializer.
2176 (auto_language_data): Likewise.
2177 * language.h (struct language_data): Delete la_print_array_index
2178 field.
2179 (language_defn::print_array_index): New member function.
2180 (LA_PRINT_ARRAY_INDEX): Update.
2181 (default_print_array_index): Delete declaration.
2182 * m2-lang.c (m2_language_data): Delete la_print_array_index
2183 initializer.
2184 * objc-lang.c (objc_language_data): Likewise.
2185 * opencl-lang.c (opencl_language_data): Likewise.
2186 * p-lang.c (pascal_language_data): Likewise.
2187 * rust-lang.c (rust_language_data): Likewise.
2188
2189 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2190
2191 * gdb/ada-lang.c (ada_language_defn): Convert to...
2192 (ada_language_data): ...this.
2193 (class ada_language): New class.
2194 (ada_language_defn): New static global.
2195 * gdb/c-lang.c (c_language_defn): Convert to...
2196 (c_language_data): ...this.
2197 (class c_language): New class.
2198 (c_language_defn): New static global.
2199 (cplus_language_defn): Convert to...
2200 (cplus_language_data): ...this.
2201 (class cplus_language): New class.
2202 (cplus_language_defn): New static global.
2203 (asm_language_defn): Convert to...
2204 (asm_language_data): ...this.
2205 (class asm_language): New class.
2206 (asm_language_defn): New static global.
2207 (minimal_language_defn): Convert to...
2208 (minimal_language_data): ...this.
2209 (class minimal_language): New class.
2210 (minimal_language_defn): New static global.
2211 * gdb/d-lang.c (d_language_defn): Convert to...
2212 (d_language_data): ...this.
2213 (class d_language): New class.
2214 (d_language_defn): New static global.
2215 * gdb/f-lang.c (f_language_defn): Convert to...
2216 (f_language_data): ...this.
2217 (class f_language): New class.
2218 (f_language_defn): New static global.
2219 * gdb/go-lang.c (go_language_defn): Convert to...
2220 (go_language_data): ...this.
2221 (class go_language): New class.
2222 (go_language_defn): New static global.
2223 * gdb/language.c (unknown_language_defn): Remove declaration.
2224 (current_language): Initialize to nullptr, real initialization is
2225 moved to _initialize_language.
2226 (languages): Delete global.
2227 (language_defn::languages): Define.
2228 (set_language_command): Use language_defn::languages.
2229 (set_language): Likewise.
2230 (range_error): Likewise.
2231 (language_enum): Likewise.
2232 (language_def): Likewise.
2233 (add_set_language_command): Use language_def::languages for the
2234 language list, and language_def to lookup language pointers.
2235 (skip_language_trampoline): Use language_defn::languages.
2236 (unknown_language_defn): Convert to...
2237 (unknown_language_data): ...this.
2238 (class unknown_language): New class.
2239 (unknown_language_defn): New static global.
2240 (auto_language_defn): Convert to...
2241 (auto_language_data): ...this.
2242 (class auto_language): New class.
2243 (auto_language_defn): New static global.
2244 (language_gdbarch_post_init): Use language_defn::languages.
2245 (_initialize_language): Initialize current_language.
2246 * gdb/language.h (struct language_defn): Rename to...
2247 (struct language_data): ...this.
2248 (struct language_defn): New.
2249 (auto_language_defn): Delete.
2250 (unknown_language_defn): Delete.
2251 (minimal_language_defn): Delete.
2252 (ada_language_defn): Delete.
2253 (asm_language_defn): Delete.
2254 (c_language_defn): Delete.
2255 (cplus_language_defn): Delete.
2256 (d_language_defn): Delete.
2257 (f_language_defn): Delete.
2258 (go_language_defn): Delete.
2259 (m2_language_defn): Delete.
2260 (objc_language_defn): Delete.
2261 (opencl_language_defn): Delete.
2262 (pascal_language_defn): Delete.
2263 (rust_language_defn): Delete.
2264 * gdb/m2-lang.c (m2_language_defn): Convert to...
2265 (m2_language_data): ...this.
2266 (class m2_language): New class.
2267 (m2_language_defn): New static global.
2268 * gdb/objc-lang.c (objc_language_defn): Convert to...
2269 (objc_language_data): ...this.
2270 (class objc_language): New class.
2271 (objc_language_defn): New static global.
2272 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
2273 (opencl_language_data): ...this.
2274 (class opencl_language): New class.
2275 (opencl_language_defn): New static global.
2276 * gdb/p-lang.c (pascal_language_defn): Convert to...
2277 (pascal_language_data): ...this.
2278 (class pascal_language): New class.
2279 (pascal_language_defn): New static global.
2280 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
2281 language pointer, update comment format.
2282 * gdb/rust-lang.c (rust_language_defn): Convert to...
2283 (rust_language_data): ...this.
2284 (class rust_language): New class.
2285 (rust_language_defn): New static global.
2286
2287 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
2288
2289 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
2290 member variable.
2291 <m_stmt_at_address>: New member variable.
2292 (lnp_state_machine::record_line): Don't record some lines, update
2293 tracking of is_stmt at the same address.
2294 (lnp_state_machine::lnp_state_machine): Initialise new member
2295 variables.
2296
2297 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
2298
2299 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
2300 "-include gnu-nat-mig.h".
2301 * gnu-nat-mig.h: New file.
2302 * gnu-nat.c: Include "gnu-nat-mig.h".
2303 (exc_server, msg_reply_server, notify_server,
2304 process_reply_server): Remove declarations.
2305
2306 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2307
2308 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
2309 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
2310 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
2311 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
2312 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
2313 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
2314 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
2315 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
2316 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
2317 to gnu_nat_target class.
2318 * gnu-nat.c: Likewise.
2319 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
2320 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
2321 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
2322 object.
2323 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
2324 instead of `gnu_target'.
2325
2326 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2327
2328 * i386-gnu-tdep.c: Include "gdbcore.h"
2329 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
2330 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
2331 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
2332 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
2333 i386_gnu_sigcontext_addr): New functions
2334 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
2335 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
2336 tdep.
2337
2338 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2339
2340 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
2341 before fork_inferior call. Avoid calling it if target_is_pushed returns
2342 true.
2343
2344 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2345
2346 * gnu-nat.h (gnu_target): New variable declaration.
2347 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
2348 gnu_target.
2349 * gnu-nat.c (gnu_target): New variable.
2350 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
2351 add_thread_silent, and add_thread calls.
2352 (gnu_nat_target::create_inferior): Pass gnu_target to
2353 add_thread_silent, thread_change_ptid call.
2354 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
2355 call.
2356
2357 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2358
2359 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
2360 (gnu_nat_target::find_memory_regions): Remove unused
2361 `old_address' variable.
2362
2363 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2364
2365 * gnu-nat.c: Include "gdbarch.h".
2366
2367 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2368
2369 * reply_mig_hack.awk (Error return): Cast function through
2370 void *, to bypass compiler function call check.
2371
2372 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2373
2374 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
2375 $(srcdir)/reply_mig_hack.awk.
2376
2377 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2378
2379 * gnu-nat.h (gnu_debug_flag): Set type to bool.
2380
2381 2020-05-30 Jonny Grant <jg@jguk.org>
2382
2383 * configure.ac (ACX_BUGURL): change bug URL to https.
2384
2385 2020-05-30 Pedro Alves <palves@redhat.com>
2386
2387 * cp-support.c (replace_typedefs_template): New.
2388 (replace_typedefs_qualified_name): Handle
2389 DEMANGLE_COMPONENT_TEMPLATE.
2390
2391 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
2392
2393 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
2394 dwarf2/index-cache.h, dwarf2/index-write.c,
2395 dwarf2/index-write.h, dwarf2/line-header.c,
2396 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
2397 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
2398 variables and fields from `dwarf2_per_objfile` to just
2399 `per_objfile` throughout.
2400
2401 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
2402
2403 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2404 <push_dwarf_reg_entry_value>: Add comment.
2405
2406 2020-05-28 Kevin Buettner <kevinb@redhat.com>
2407 Keith Seitz <keiths@redhat.com>
2408
2409 * python/python.c (do_start_initialization): Call PyEval_SaveThread
2410 instead of PyEval_ReleaseLock.
2411 (class gdbpy_gil): Move to earlier in file.
2412 (finalize_python): Set gdb_python_initialized.
2413 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
2414 when not initialized.
2415
2416 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
2417
2418 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2419 <push_dwarf_reg_entry_value>: Remove assert. Override
2420 per_objfile with caller_per_objfile.
2421
2422 2020-05-28 Tom de Vries <tdevries@suse.de>
2423
2424 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
2425 PR gold/15646 workaround to symbol kind "type".
2426
2427 2020-05-27 Tom Tromey <tromey@adacore.com>
2428
2429 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
2430
2431 2020-05-27 Tom Tromey <tromey@adacore.com>
2432
2433 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
2434 Use htab_find_with_hash.
2435 <add_abbrev>: Remove "abbrev_number" parameter.
2436 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
2437 "abbrev_number" parameter. Use htab_find_slot_with_hash.
2438 (hash_abbrev): Add comment.
2439 (abbrev_table::lookup_abbrev): Move to header file.
2440 (abbrev_table::read): Update.
2441
2442 2020-05-27 Tom Tromey <tromey@adacore.com>
2443
2444 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
2445 method.
2446 <canonical_name>: New member.
2447 <raw_name>: Rename from "name".
2448 (partial_die_info): Initialize canonical_name.
2449 (scan_partial_symbols): Check raw_name.
2450 (partial_die_parent_scope, partial_die_full_name)
2451 (add_partial_symbol, add_partial_subprogram)
2452 (add_partial_enumeration, load_partial_dies): Use "name" method.
2453 (partial_die_info::name): New method.
2454 (partial_die_info::read, guess_partial_die_structure_name)
2455 (partial_die_info::fixup): Update.
2456
2457 2020-05-27 Tom Tromey <tromey@adacore.com>
2458
2459 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
2460 <get_ref_die_offset>: Inline.
2461 <get_ref_die_offset_complaint>: New method.
2462 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
2463 (attribute::get_ref_die_offset_complaint): Rename from
2464 get_ref_die_offset. Just issue complaint.
2465
2466 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2467
2468 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
2469
2470 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2471
2472 * exec.c (exec_file_attach): Use errno value of first openp failure.
2473
2474 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2475
2476 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
2477 Don't close thread handle.
2478
2479 2020-05-27 Tom Tromey <tom@tromey.com>
2480 Simon Marchi <simon.marchi@efficios.com>
2481
2482 * objfiles.h (struct objfile) <partial_symtabs>: Now a
2483 shared_ptr.
2484 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
2485 member.
2486 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
2487 dwarf2_per_bfd_objfile_data_key>: New globals.
2488 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
2489 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
2490 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
2491 shared.
2492 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
2493 short-circuit when sharing.
2494 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
2495 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
2496
2497 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2498
2499 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
2500 to...
2501 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
2502 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
2503
2504 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2505
2506 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
2507 build_name_components, find_name_components_bounds>:
2508 Add per_objfile parameter.
2509 (struct mapped_index) <symbol_name_at>: Likewise.
2510 (struct mapped_debug_names): Remove constructor.
2511 <dwarf2_per_objfile>: Remove field.
2512 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
2513 (mapped_index_base::find_name_components_bounds,
2514 mapped_index_base::build_name_components,
2515 dw2_expand_symtabs_matching_symbol): Likewise.
2516 (class mock_mapped_index) <symbol_name_at>: Likewise.
2517 (check_match): Likewise.
2518 (check_find_bounds_finds): Likewise.
2519 (test_mapped_index_find_name_component_bounds): Update.
2520 (CHECK_MATCH): Update.
2521 (dw2_expand_symtabs_matching): Update.
2522 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
2523 per_objfile parameter.
2524 <find_vec_in_debug_names>: Likewise.
2525 <m_per_objfile>: New field.
2526 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
2527 parameter.
2528 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
2529 (dw2_debug_names_iterator::next): Update.
2530 (dw2_debug_names_lookup_symbol): Update.
2531 (dw2_debug_names_expand_symtabs_for_function): Update.
2532 (dw2_debug_names_map_matching_symbols): Update.
2533 (dw2_debug_names_expand_symtabs_matching): Update.
2534 (dwarf2_read_debug_names): Update.
2535
2536 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2537
2538 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
2539 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
2540 move to dwarf2_per_objfile.
2541 <read_in_chain>: Remove.
2542 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
2543 remove_all_cus, age_comp_units>: New methods.
2544 <m_dwarf2_cus>: New member.
2545 (struct dwarf2_per_cu_data) <cu>: Remove.
2546 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
2547 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
2548 moved to methods of dwarf2_per_objfile.
2549 (dwarf2_clear_marks): Remove.
2550 (dwarf2_queue_item::~dwarf2_queue_item): Update.
2551 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
2552 (dwarf2_per_bfd::free_cached_comp_units): Remove.
2553 (dwarf2_per_objfile::remove_all_cus): New.
2554 (class free_cached_comp_units) <~free_cached_comp_units>:
2555 Update.
2556 (load_cu): Update.
2557 (dw2_do_instantiate_symtab): Adjust.
2558 (fill_in_sig_entry_from_dwo_entry): Adjust.
2559 (cutu_reader::init_tu_and_read_dwo_dies): Update.
2560 (cutu_reader::cutu_reader): Likewise.
2561 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
2562 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
2563 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
2564 and dwarf2_per_objfile::age_comp_units.
2565 (load_partial_comp_unit): Update.
2566 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
2567 (process_queue): Likewise.
2568 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
2569 backlink.
2570 (dwarf2_read_addr_index): Likewise.
2571 (follow_die_offset): Likewise.
2572 (dwarf2_fetch_die_loc_sect_off): Likewise.
2573 (dwarf2_fetch_constant_bytes): Likewise.
2574 (dwarf2_fetch_die_type_sect_off): Likewise.
2575 (follow_die_sig_1): Likewise.
2576 (load_full_type_unit): Likewise.
2577 (read_signatured_type): Likewise.
2578 (dwarf2_cu::dwarf2_cu): Don't set cu field.
2579 (dwarf2_cu::~dwarf2_cu): Remove.
2580 (dwarf2_per_objfile::get_cu): New.
2581 (dwarf2_per_objfile::set_cu): New.
2582 (age_cached_comp_units): Rename to...
2583 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
2584 to std::unordered_map.
2585 (free_one_cached_comp_unit): Rename to...
2586 (dwarf2_per_objfile::remove_cu): ... this. Adjust
2587 to std::unordered_map.
2588 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
2589 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
2590 a dwarf2_per_objfile in data.
2591 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
2592 (dwarf2_clear_marks): Remove.
2593
2594 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2595
2596 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
2597 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
2598 (init_tu_and_read_dwo_dies): Likewise.
2599 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
2600 (cutu_reader::cutu_reader): Likewise.
2601 (load_partial_comp_unit): Likewise.
2602 (process_psymtab_comp_unit): Update.
2603 (build_type_psymtabs_1): Update.
2604 (process_skeletonless_type_unit): Update.
2605 (load_full_comp_unit): Update.
2606 (find_partial_die): Update.
2607 (dwarf2_read_addr_index): Update.
2608 (read_signatured_type): Update.
2609
2610 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2611
2612 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
2613 m_header_read_in>: New fields.
2614 <get_header>: New method.
2615 * dwarf2/read.c (per_cu_header_read_in): Remove.
2616 (dwarf2_per_cu_data::get_header): New.
2617 (dwarf2_per_cu_data::addr_size): Update.
2618 (dwarf2_per_cu_data::offset_size): Update.
2619 (dwarf2_per_cu_data::ref_addr_size): Update.
2620
2621 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2622
2623 * dwarf2/read.c (load_cu): Return dwarf2_cu.
2624 (dw2_do_instantiate_symtab): Update.
2625 (queue_and_load_all_dwo_tus): Change parameter from
2626 dwarf2_per_cu_data to dwarf2_cu.
2627 (dwarf2_fetch_die_loc_sect_off): Update.
2628 (dwarf2_fetch_constant_bytes): Update.
2629 (dwarf2_fetch_die_type_sect_off): Update.
2630
2631 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2632
2633 * dwarf2/read.c (process_full_comp_unit,
2634 process_full_type_unit): Remove per_cu, per_objfile paramters.
2635 Add dwarf2_cu parameter.
2636 (process_queue): Update.
2637
2638 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2639
2640 * dwarf2/read.c (create_cu_from_index_list): Replace
2641 dwarf2_per_objfile parameter with dwarf2_per_bfd.
2642 (create_cus_from_index_list): Likewise.
2643 (create_cus_from_index): Likewise.
2644 (create_signatured_type_table_from_index): Likewise.
2645 (create_cus_from_debug_names_list): Likewise.
2646 (create_cus_from_debug_names): Likewise.
2647 (dwarf2_read_gdb_index): Update.
2648 (dwarf2_read_debug_names): Update.
2649
2650 2020-05-27 Tom Tromey <tom@tromey.com>
2651 Simon Marchi <simon.marchi@efficios.com>
2652
2653 * dwarf2/read.h (struct dwarf2_per_objfile)
2654 <get_type_for_signatured_type, set_type_for_signatured_type>:
2655 New methods.
2656 <m_type_map>: New member.
2657 (struct signatured_type) <type>: Remove.
2658 * dwarf2/read.c
2659 (dwarf2_per_objfile::get_type_for_signatured_type,
2660 dwarf2_per_objfile::set_type_for_signatured_type): New.
2661 (get_signatured_type): Use new methods.
2662
2663 2020-05-27 Tom Tromey <tom@tromey.com>
2664 Simon Marchi <simon.marchi@efficios.com>
2665
2666 * dwarf2/read.h (struct type_unit_group_unshareable): New.
2667 (struct dwarf2_per_objfile) <type_units>: New member.
2668 <get_type_unit_group_unshareable>: New method.
2669 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
2670 num_symtabs, symtabs>: Remove; move to
2671 type_unit_group_unshareable.
2672 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
2673 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
2674 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
2675
2676 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2677
2678 * dwarf2/read.h (struct dwarf2_per_cu_data):
2679 <dwarf2_per_objfile>: Remove.
2680 * dwarf2/read.c (create_cu_from_index_list): Don't assign
2681 dwarf2_per_objfile.
2682 (create_signatured_type_table_from_index): Likewise.
2683 (create_signatured_type_table_from_debug_names): Likewise.
2684 (create_debug_type_hash_table): Likewise.
2685 (fill_in_sig_entry_from_dwo_entry): Likewise.
2686 (create_type_unit_group): Likewise.
2687 (read_comp_units_from_section): Likewise.
2688 (create_cus_hash_table): Likewise.
2689
2690 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2691
2692 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
2693 dwarf2_per_cu_data::dwarf2_per_objfile.
2694 (compute_compunit_symtab_includes): Likewise.
2695 (dwarf2_cu::start_symtab): Likewise.
2696
2697 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2698
2699 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
2700 parameter.
2701 * dwarf2/read.c (get_die_type_at_offset): Likewise.
2702 (read_namespace_alias): Update.
2703 (lookup_die_type): Update.
2704 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
2705 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
2706 Update.
2707 (disassemble_dwarf_expression): Update.
2708
2709 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2710
2711 * dwarf2/read.h (struct dwarf2_queue_item): Add
2712 dwarf2_per_objfile parameter, assign new parameter.
2713 <per_objfile>: New field.
2714 * dwarf2/read.c (free_one_cached_comp_unit): Add
2715 dwarf2_per_objfile parameter.
2716 (queue_comp_unit): Likewise.
2717 (dw2_do_instantiate_symtab): Update.
2718 (process_psymtab_comp_unit): Update.
2719 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
2720 (process_imported_unit_die): Update.
2721 (queue_and_load_dwo_tu): Update.
2722 (follow_die_offset): Update.
2723 (follow_die_sig_1): Update.
2724
2725 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2726
2727 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
2728 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
2729 (read_call_site_scope): Assign per_objfile.
2730 (dwarf2_per_cu_data::objfile): Remove.
2731 * gdbtypes.h (struct call_site) <per_objfile>: New member.
2732 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
2733 dwarf2_per_objfile parameter.
2734 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
2735 dwarf2_per_objfile parameter.
2736 (dwarf_expr_reg_to_entry_parameter): Add output
2737 dwarf2_per_objfile parameter.
2738 (locexpr_get_frame_base): Update.
2739 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
2740 <push_dwarf_reg_entry_value>: Update.
2741 <call_site_to_target_addr>: Update.
2742 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
2743 parameter.
2744 (value_of_dwarf_reg_entry): Update.
2745 (rw_pieced_value): Update.
2746 (indirect_synthetic_pointer): Update.
2747 (dwarf2_evaluate_property): Update.
2748 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
2749 parameter.
2750 (locexpr_read_variable): Update.
2751 (locexpr_get_symbol_read_needs): Update.
2752 (loclist_read_variable): Update.
2753
2754 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2755
2756 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
2757 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2758 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
2759 parameter.
2760 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
2761 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2762 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
2763 parameter.
2764 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
2765 sect_variable_value): Add dwarf2_per_objfile parameter.
2766 (class dwarf_evaluate_loc_desc) <dwarf_call,
2767 dwarf_variable_value>: Update.
2768 (fetch_const_value_from_synthetic_pointer): Add
2769 dwarf2_per_objfile parameter.
2770 (fetch_const_value_from_synthetic_pointer): Update.
2771 (coerced_pieced_ref): Update.
2772 (class symbol_needs_eval_context) <dwarf_call,
2773 dwarf_variable_value>: Update.
2774 (dwarf2_compile_expr_to_ax): Update.
2775
2776 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2777
2778 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
2779 parameter.
2780 (dwarf2_evaluate_loc_desc_full): Update.
2781
2782 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2783
2784 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
2785 parameter.
2786 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
2787 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
2788 dwarf2_per_objfile parameter.
2789 (decode_debug_loc_dwo_addresses): Likewise.
2790 (dwarf2_find_location_expression): Update.
2791 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
2792 (locexpr_describe_location_piece): Add dwarf2_per_objfile
2793 parameter.
2794 (disassemble_dwarf_expression): Add dwarf2_per_objfile
2795 parameter.
2796 (locexpr_describe_location_1): Likewise.
2797 (locexpr_describe_location): Update.
2798
2799 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2800
2801 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
2802 Remove.
2803 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
2804 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
2805 (dwarf2_compile_property_to_c): Update.
2806 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
2807 use text offset from objfile.
2808 (locexpr_tracepoint_var_ref): Update.
2809 (locexpr_generate_c_location): Update.
2810 (loclist_describe_location): Update.
2811 (loclist_tracepoint_var_ref): Update.
2812 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
2813 dwarf2_per_objfile parameter.
2814 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
2815 use text offset from objfile.
2816 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
2817
2818 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2819
2820 * dwarf2/expr.h (struct dwarf_expr_context)
2821 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
2822 <offset>: Remove.
2823 <per_objfile>: New member.
2824 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
2825 dwarf2_per_objfile parameter. Don't set offset, set
2826 per_objfile.
2827 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
2828 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
2829 a dwarf2_per_objfile object instead of an offset.
2830 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
2831 constructor.
2832 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
2833 to dwarf2_expr_executor constructor. Don't set offset.
2834 (dwarf2_fetch_cfa_info): Update.
2835 (struct dwarf2_frame_cache) <text_offset>: Remove.
2836 <per_objfile>: New field.
2837 (dwarf2_frame_cache): Update.
2838 (dwarf2_frame_prev_register): Update.
2839 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2840 <dwarf_evaluate_loc_desc>: Add constructor.
2841 (dwarf2_evaluate_loc_desc_full): Update.
2842 (dwarf2_locexpr_baton_eval): Update.
2843 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
2844 Add constructor.
2845 (dwarf2_loc_desc_get_symbol_read_needs): Update.
2846
2847 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2848
2849 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
2850 addr_sized_int_type>: Move to dwarf2_cu.
2851 <int_type>: Move to dwarf2_per_objfile.
2852 (struct dwarf2_per_objfile) <int_type>: Move here.
2853 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
2854 addr_sized_int_type>: Move here.
2855 (read_func_scope): Update.
2856 (read_array_type): Update.
2857 (read_tag_string_type): Update.
2858 (attr_to_dynamic_prop): Update.
2859 (dwarf2_per_cu_data::int_type): Rename to...
2860 (dwarf2_per_objfile::int_type): ... this.
2861 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
2862 (dwarf2_cu::addr_sized_int_type): ... this.
2863 (read_subrange_type): Update.
2864 (dwarf2_per_cu_data::addr_type): Rename to...
2865 (dwarf2_cu::addr_type): ... this.
2866 (set_die_type): Update.
2867
2868 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2869
2870 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
2871 data through per_cu->cu.
2872
2873 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2874
2875 * dwarf2/read.c (lookup_dwo_comp_unit): Change
2876 dwarf2_per_cu_data parameter fo dwarf2_cu.
2877 (lookup_dwo_type_unit): Likewise.
2878 (read_cutu_die_from_dwo): Likewise.
2879 (lookup_dwo_unit): Likewise.
2880 (open_and_init_dwo_file): Likewise.
2881 (lookup_dwo_cutu): Likewise.
2882 (lookup_dwo_comp_unit): Likewise.
2883 (lookup_dwo_type_unit): Likewise.
2884 (cutu_reader::init_tu_and_read_dwo_dies): Update.
2885 (cutu_reader::cutu_reader): Update.
2886
2887 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2888
2889 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
2890 parameter.
2891 (process_full_type_unit): Likewise.
2892 (process_queue): Update.
2893
2894 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2895
2896 * dwarf2/read.c (recursively_compute_inclusions): Add
2897 dwarf2_per_objfile parameter.
2898 (compute_compunit_symtab_includes): Likewise.
2899 (process_cu_includes): Update.
2900
2901 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2902
2903 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
2904 parameter.
2905 (create_type_unit_group): Update.
2906 (process_psymtab_comp_unit_reader): Update.
2907 (build_type_psymtabs_reader): Update.
2908
2909 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2910
2911 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
2912 object through m_this_cu->cu.
2913
2914 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2915
2916 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
2917 the info parameter.
2918 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
2919
2920 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2921
2922 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
2923 per_objfile parameter.
2924 (load_full_type_unit): Add per_objfile parameter.
2925 (read_signatured_type): Likewise.
2926 (load_full_comp_unit): Likewise.
2927 (load_cu): Likewise.
2928 (dw2_do_instantiate_symtab): Likewise.
2929 (dw2_get_file_names): Likewise.
2930 (dw2_map_symtabs_matching_filename): Update.
2931 (dw_expand_symtabs_matching_file_matcher): Update.
2932 (dw2_map_symbol_filenames): Update.
2933 (process_psymtab_comp_unit): Add per_objfile parameter.
2934 (build_type_psymtabs_1): Update.
2935 (process_skeletonless_type_unit): Update.
2936 (dwarf2_build_psymtabs_hard): Update.
2937 (load_partial_comp_unit): Add per_objfile parameter.
2938 (scan_partial_symbols): Update.
2939 (load_full_comp_unit): Add per_objfile parameter.
2940 (process_imported_unit_die): Update.
2941 (create_cus_hash_table): Update.
2942 (find_partial_die): Update.
2943 (dwarf2_read_addr_index): Update.
2944 (follow_die_offset): Update.
2945 (dwarf2_fetch_die_loc_sect_off): Update.
2946 (dwarf2_fetch_constant_bytes): Update.
2947 (dwarf2_fetch_die_type_sect_off): Update.
2948 (follow_die_sig_1): Update.
2949 (load_full_type_unit): Add per_objfile parameter.
2950 (read_signatured_type): Likewise.
2951
2952 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2953
2954 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
2955 of objfile_name.
2956
2957 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2958
2959 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
2960 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
2961 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
2962 field.
2963 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
2964 (create_cus_from_index): Update.
2965 (dwarf2_read_gdb_index): Update.
2966 (create_cus_from_debug_names): Update.
2967 (dwarf2_read_debug_names): Update.
2968 (get_abbrev_section_for_cu): Update.
2969 (create_all_comp_units): Update.
2970 (read_attribute_value): Update.
2971 (get_debug_line_section): Update.
2972 * dwarf2/index-cache.c (index_cache::store): Update.
2973 * dwarf2/index-write.c (save_gdb_index_command): Update.
2974 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
2975
2976 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2977
2978 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
2979 member.
2980 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
2981 dwarf2_per_cu_data::per_bfd.
2982 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
2983 (create_type_unit_group): Likewise.
2984 (queue_comp_unit): Remove reference to
2985 per_cu->dwarf2_per_objfile.
2986 (maybe_queue_comp_unit): Likewise.
2987 (fill_in_sig_entry_from_dwo_entry): Assign new field.
2988 (create_cus_hash_table): Assign new field.
2989
2990 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2991
2992 * dwarf2/read.c: Replace
2993 dwarf2_cu->per_cu->dwarf2_per_objfile references with
2994 dwarf2_cu->per_objfile throughout.
2995
2996 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2997
2998 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
2999 parameter, don't use per_cu->dwarf2_per_objfile.
3000 (dw2_instantiate_symtab): Likewise.
3001 (dw2_find_last_source_symtab): Update.
3002 (dw2_map_expand_apply): Update.
3003 (dw2_lookup_symbol): Update.
3004 (dw2_expand_symtabs_for_function): Update.
3005 (dw2_expand_all_symtabs): Update.
3006 (dw2_expand_symtabs_with_fullname): Update.
3007 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
3008 don't use per_cu->dwarf2_per_objfile.
3009 (dw2_expand_marked_cus): Update.
3010 (dw2_find_pc_sect_compunit_symtab): Update.
3011 (dw2_debug_names_lookup_symbol): Update.
3012 (dw2_debug_names_expand_symtabs_for_function): Update.
3013 (dw2_debug_names_map_matching_symbols): Update.
3014 (dwarf2_psymtab::expand_psymtab): Update.
3015
3016 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3017
3018 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
3019 <per_objfile>: New member.
3020 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
3021 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
3022 call to dwarf2_cu.
3023 (cutu_reader::cutu_reader): Update.
3024 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
3025
3026 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3027
3028 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
3029 struct dwarf2_per_objfile.
3030 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
3031 dwarf2_per_bfd.
3032 * dwarf2/read.c (set_die_type): Update.
3033 (get_die_type_at_offset): Update.
3034
3035 2020-05-27 Tom Tromey <tom@tromey.com>
3036 Simon Marchi <simon.marchi@efficios.com>
3037
3038 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
3039 method.
3040 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
3041 get_symtab, set_symtab>: New methods.
3042 <m_symtabs>: New field.
3043 (struct dwarf2_psymtab): Derive from partial_symtab.
3044 <readin_p, get_compunit_symtab>: Declare methods.
3045 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
3046 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
3047 New methods.
3048 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
3049 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
3050 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
3051 (dw2_symtab_iter_next, dw2_print_stats)
3052 (dw2_expand_symtabs_with_fullname)
3053 (dw2_expand_symtabs_matching_one)
3054 (dw_expand_symtabs_matching_file_matcher)
3055 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
3056 (dw2_debug_names_iterator::next)
3057 (dw2_debug_names_map_matching_symbols)
3058 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
3059 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
3060 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
3061 New methods.
3062 (get_compunit_symtab, process_full_comp_unit)
3063 (process_full_type_unit): Update.
3064 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
3065
3066 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3067
3068 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
3069 then introduce a new dwarf2_per_objfile type.
3070 <read_line_string>: Move to the new dwarf2_per_objfile type.
3071 <objfile>: Likewise.
3072 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
3073 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
3074 dwarf2_per_objfile->per_bfd.
3075 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
3076 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
3077 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
3078 (dwarf2_per_bfd::free_cached_comp_units): ... this.
3079 (dwarf2_has_info): Allocate dwarf2_per_bfd.
3080 (dwarf2_per_objfile::locate_sections): Rename to...
3081 (dwarf2_per_bfd::locate_sections): ... this.
3082 (dwarf2_per_objfile::get_cutu): Rename to...
3083 (dwarf2_per_bfd::get_cutu): ... this.
3084 (dwarf2_per_objfile::get_cu): Rename to...
3085 (dwarf2_per_bfd::get_cu): ... this.
3086 (dwarf2_per_objfile::get_tu): Rename to...
3087 (dwarf2_per_bfd::get_tu): ... this.
3088 (dwarf2_per_objfile::allocate_per_cu): Rename to...
3089 (dwarf2_per_bfd::allocate_per_cu): ... this.
3090 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
3091 (dwarf2_per_bfd::allocate_signatured_type): ... this.
3092 (get_gdb_index_contents_ftype): Change parameter from
3093 dwarf2_per_objfile to dwarf2_per_bfd.
3094 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
3095 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
3096
3097 2020-05-27 Tom Tromey <tom@tromey.com>
3098 Simon Marchi <simon.marchi@efficios.com>
3099
3100 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
3101 (allocate_piece_closure): Set "per_objfile" member.
3102 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
3103 (locexpr_describe_location, loclist_describe_location): Use new
3104 member.
3105 * dwarf2/read.c (read_call_site_scope)
3106 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
3107 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
3108 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
3109 handle_data_member_location): Set per_objfile member.
3110 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
3111 member.
3112 (struct dwarf2_loclist_baton) <per_objfile>: New member.
3113
3114 2020-05-27 Tom Tromey <tom@tromey.com>
3115
3116 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
3117 allocate_signatured_type>: Declare new methods.
3118 <m_num_psymtabs>: New member.
3119 (struct dwarf2_per_cu_data) <index>: New member.
3120 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
3121 (dwarf2_per_objfile::allocate_signatured_type): New methods.
3122 (create_cu_from_index_list): Use allocate_per_cu.
3123 (create_signatured_type_table_from_index)
3124 (create_signatured_type_table_from_debug_names)
3125 (create_debug_type_hash_table, add_type_unit)
3126 (read_comp_units_from_section): Use allocate_signatured_type.
3127
3128 2020-05-27 Tom Tromey <tom@tromey.com>
3129
3130 * psymtab.c (partial_map_expand_apply)
3131 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
3132 (psym_lookup_global_symbol_language)
3133 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
3134 (psym_print_stats, psym_expand_symtabs_for_function)
3135 (psym_map_symbol_filenames, psym_map_matching_symbols)
3136 (psym_expand_symtabs_matching)
3137 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
3138 (maintenance_check_psymtabs): Update.
3139 * psympriv.h (struct partial_symtab) <readin_p,
3140 get_compunit_symtab>: Add objfile parameter.
3141 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
3142 Likewise.
3143 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
3144 get_compunit_symtab>: Likewise.
3145 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
3146
3147 2020-05-27 Tom Tromey <tom@tromey.com>
3148
3149 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
3150 member.
3151 * dwarf2/read.c (delete_file_name_entry): Fix comment.
3152 (create_cu_from_index_list)
3153 (create_signatured_type_table_from_index)
3154 (create_signatured_type_table_from_debug_names)
3155 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
3156 (dwarf2_create_include_psymtab)
3157 (create_debug_type_hash_table, add_type_unit)
3158 (create_type_unit_group, read_comp_units_from_section)
3159 (dwarf2_compute_name, create_cus_hash_table)
3160 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
3161 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
3162 obstack.
3163 (dw2_get_real_path): Likewise. Change argument to
3164 dwarf2_per_objfile.
3165
3166 2020-05-27 Luis Machado <luis.machado@linaro.org>
3167
3168 PR tdep/26000
3169 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
3170 for ldrd (immediate).
3171
3172 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3173
3174 * command.h: Add comment giving the name of class_tui.
3175 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
3176 create the fake command for the help for class_tui.
3177
3178 2020-05-26 Tom Tromey <tromey@adacore.com>
3179
3180 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
3181 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
3182 (val_atr): New function.
3183 (value_val_atr): Use it.
3184 * ada-valprint.c (print_optional_low_bound): Change low bound
3185 handling for enums.
3186 (val_print_packed_array_elements): Don't call discrete_position.
3187 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
3188 discrete_position for enum types.
3189 * language.c (default_print_array_index): Change type.
3190 * language.h (struct language_defn) <la_print_array_index>: Add
3191 index_type parameter, change type of index_value.
3192 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
3193 (default_print_array_index): Update.
3194 * valprint.c (maybe_print_array_index): Don't call
3195 value_from_longest. Update.
3196 (value_print_array_elements): Don't call discrete_position.
3197
3198 2020-05-26 Tom Tromey <tromey@adacore.com>
3199
3200 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
3201 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
3202
3203 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
3204
3205 PR gdb/13519
3206 * avr-tdep.c (avr_integer_to_address): Return data or code
3207 address accordingly to the second 'type' argument of the
3208 function.
3209
3210 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
3211
3212 * infcmd.c, inferior.h: (construct_inferior_arguments):
3213 Moved function from here to gdbsupport/common-inferior.{h,cc}
3214
3215 2020-05-23 Tom Tromey <tom@tromey.com>
3216
3217 Revert commit eca1f90c:
3218 * NEWS: Remove entry for completion styling.
3219 * completer.c (_rl_completion_prefix_display_length): Move
3220 declaration later.
3221 (gdb_fnprint): Revert.
3222 (gdb_display_match_list_1): Likewise.
3223 * cli/cli-style.c (completion_prefix_style)
3224 (completion_difference_style, completion_suffix_style): Remove.
3225 (_initialize_cli_style): Revert.
3226 * cli/cli-style.h (completion_prefix_style)
3227 (completion_difference_style, completion_suffix_style): Don't
3228 declare.
3229
3230 2020-05-24 Pedro Alves <palves@redhat.com>
3231
3232 * symtab.c (completion_list_add_name): Return boolean indication
3233 of whether the symbol matched.
3234 (completion_list_add_symbol): Don't try to remove C++ aliases if
3235 the symbol didn't match in the first place.
3236 * symtab.h (completion_list_add_name): Return bool.
3237
3238 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
3239
3240 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
3241 type::field.
3242
3243 2020-05-23 Joel Brobecker <brobecker@adacore.com>
3244
3245 GDB 9.2 released.
3246
3247 2020-05-23 Tom Tromey <tom@tromey.com>
3248
3249 * NEWS: Add entry for completion styling.
3250 * completer.c (_rl_completion_prefix_display_length): Move
3251 declaration earlier.
3252 (gdb_fnprint): Use completion_style.
3253 (gdb_display_match_list_1): Likewise.
3254 * cli/cli-style.c (completion_prefix_style)
3255 (completion_difference_style, completion_suffix_style): New
3256 globals.
3257 (_initialize_cli_style): Register new globals.
3258 * cli/cli-style.h (completion_prefix_style)
3259 (completion_difference_style, completion_suffix_style): Declare.
3260
3261 2020-05-23 Pedro Alves <palves@redhat.com>
3262
3263 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
3264 (parse_escape): Use ISDIGIT instead of isdigit.
3265 (puts_debug): Use gdb_isprint instead of isprint.
3266 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
3267 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
3268 ISSPACE instead of isspace.
3269 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
3270 instead of isspace.
3271 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
3272 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
3273 instead of isxdigit and ISDIGIT instead of isdigit.
3274
3275 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3276
3277 * gdbtypes.h (struct type) <field>: New method.
3278 (TYPE_FIELDS): Remove, replace all uses with either type::fields
3279 or type::field.
3280
3281 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3282
3283 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
3284 (TYPE_FIELDS): Use type::fields. Change all call sites that
3285 modify the propery to use type::set_fields instead.
3286
3287 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3288
3289 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
3290 type::num_fields instead.
3291
3292 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3293
3294 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
3295 methods.
3296 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
3297 that modify the number of fields to use type::set_num_fields
3298 instead.
3299
3300 2020-05-22 Tom Tromey <tromey@adacore.com>
3301
3302 * compile/compile-object-load.h (munmap_list_free): Don't
3303 declare.
3304
3305 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
3306
3307 * annotate.c (annotate_source_line): Update return type, add call
3308 to update current symtab and line.
3309 * annotate.h (annotate_source_line): Update return type, and
3310 extend header comment.
3311 * source.c (info_line_command): Check annotation_level before
3312 calling annotate_source_line.
3313 * stack.c (print_frame_info): If calling annotate_source_line
3314 returns true, then don't print any other source line information.
3315
3316 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
3317
3318 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
3319
3320 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
3321
3322 * coffread.c (patch_type): Remove NULL check before xfree.
3323 * corefile.c (set_gnutarget): Likewise.
3324 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
3325 * exec.c (build_section_table): Likewise.
3326 * remote.c (remote_target::pass_signals): Likewise.
3327 * utils.c (n_spaces): Likewise.
3328 * cli/cli-script.c (document_command): Likewise.
3329 * i386-windows-tdep.c (core_process_module_section): Likewise.
3330 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
3331
3332 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
3333
3334 * symfile.c (reread_symbols): Clear objfile's section_offsets
3335 vector and section indices, re-compute them by calling
3336 sym_offsets.
3337
3338 2020-05-20 Tom Tromey <tromey@adacore.com>
3339
3340 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
3341 (desc_one_bound, desc_index_type): Compute field name.
3342
3343 2020-05-20 Tom de Vries <tdevries@suse.de>
3344
3345 PR symtab/25833
3346 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
3347
3348 2020-05-20 Alan Modra <amodra@gmail.com>
3349
3350 PR 25993
3351 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
3352 bfd_set_filename.
3353 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
3354 passed to bfd_set_filename.
3355 * symfile-mem.c (add_vsyscall_page): Likewise for string
3356 passed to symbol_file_add_from_memory.
3357 (symbol_file_add_from_memory): Make name param a const char* and
3358 don't strdup.
3359
3360 2020-05-20 Alan Modra <amodra@gmail.com>
3361
3362 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
3363 rather than accessing bfd->filename directly.
3364 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
3365 and use bfd_section_name.
3366 * dwarf2/frame.c (decode_frame_entry): Likewise.
3367 * exec.c (exec_set_section_address): Likewise.
3368 * solib-aix.c (solib_aix_bfd_open): Likewise.
3369 * stap-probe.c (get_stap_base_address): Likewise.
3370 * symfile.c (reread_symbols): Likewise.
3371
3372 2020-05-19 Tom Tromey <tromey@adacore.com>
3373
3374 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
3375
3376 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3377
3378 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
3379
3380 2020-05-19 Pedro Alves <palves@redhat.com>
3381
3382 * NEWS (set exec-file-mismatch): Adjust entry.
3383 * exec.c: Include "build-id.h".
3384 (validate_exec_file): Try to match build IDs instead of filenames.
3385 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
3386 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
3387 and pass down 'warn_if_slow'.
3388 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
3389 gdb_bfd_open_closure to pass it down.
3390 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
3391
3392 2020-05-19 Pedro Alves <palves@redhat.com>
3393
3394 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
3395 * target.c (target_fileio_open_1): Rename to target_fileio_open
3396 and make extern. Use bool.
3397 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
3398 (target_fileio_read_alloc_1): Adjust.
3399 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
3400 (target_fileio_open_warn_if_slow): Delete declaration.
3401
3402 2020-05-19 Pedro Alves <palves@redhat.com>
3403
3404 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
3405 Adjust all callers.
3406
3407 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
3408
3409 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
3410 whether disp is negative.
3411
3412 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3413
3414 * symfile.h (struct symfile_segment_data)
3415 <~symfile_segment_data>: Remove.
3416 <segment_info>: Change to std::vector.
3417 * symfile.c (default_symfile_segments): Update.
3418 * elfread.c (elf_symfile_segments): Update.
3419
3420 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3421
3422 * symfile.h (struct symfile_segment_data) <struct segment>: New.
3423 <segments>: New.
3424 <segment_bases, segment_sizes>: Remove.
3425 * symfile.c (default_symfile_segments): Update.
3426 * elfread.c (elf_symfile_segments): Update.
3427 * remote.c (remote_target::get_offsets): Update.
3428 * solib-target.c (solib_target_relocate_section_addresses):
3429 Update.
3430
3431 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3432
3433 * symfile.h (struct symfile_segment_data): Initialize fields.
3434 <~symfile_segment_data>: Add.
3435 (symfile_segment_data_up): New.
3436 (struct sym_fns) <sym_segments>: Return a
3437 symfile_segment_data_up.
3438 (default_symfile_segments): Return a symfile_segment_data_up.
3439 (free_symfile_segment_data): Remove.
3440 (get_symfile_segment_data): Return a symfile_segment_data_up.
3441 * symfile.c (default_symfile_segments): Likewise.
3442 (get_symfile_segment_data): Likewise.
3443 (free_symfile_segment_data): Remove.
3444 (symfile_find_segment_sections): Update.
3445 * elfread.c (elf_symfile_segments): Return a
3446 symfile_segment_data_up.
3447 * remote.c (remote_target::get_offsets): Update.
3448 * solib-target.c (solib_target_relocate_section_addresses):
3449 Update.
3450 * symfile-debug.c (debug_sym_segments): Return a
3451 symfile_segment_data_up.
3452
3453 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3454
3455 PR build/25981
3456 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
3457 Hardcode register numbers.
3458
3459 PR build/25981
3460 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
3461 procfs_find_LDT_entry): Remove.
3462 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
3463 procfs_find_LDT_entry): Remove.
3464 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
3465 Remove.
3466
3467 2020-05-17 Pedro Alves <palves@redhat.com>
3468 Andrew Burgess <andrew.burgess@embecosm.com>
3469 Keno Fischer <keno@juliacomputing.com>
3470
3471 PR gdb/25741
3472 * breakpoint.c (build_target_condition_list): Update comments.
3473 (build_target_command_list): Update comments and skip matching
3474 locations.
3475 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
3476 a separate function. Simplify "set breakpoint auto-hw off"
3477 handling.
3478 (insert_breakpoints): Update comment.
3479 (tracepoint_locations_match): New parameter. For breakpoints,
3480 compare location types too, if the caller wants to.
3481 (handle_automatic_hardware_breakpoints): New functions.
3482 (bp_location_is_less_than): Also sort by location type and
3483 hardware breakpoint length.
3484 (update_global_location_list): Handle "set breakpoint auto-hw on"
3485 here.
3486 (update_breakpoint_locations): Ask breakpoint_locations_match to
3487 ignore location types.
3488
3489 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3490
3491 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
3492 type::name instead.
3493
3494 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3495
3496 * gdbtypes.h (struct type) <name, set_name>: New methods.
3497 (TYPE_CODE): Use type::name. Change all call sites used to set
3498 the name to use type::set_name instead.
3499
3500 2020-05-16 Tom Tromey <tom@tromey.com>
3501
3502 * top.c (quit_force): Update.
3503 * infrun.c (handle_no_resumed): Update.
3504 * top.h (all_uis): New function.
3505 (ALL_UIS): Remove.
3506
3507 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3508
3509 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
3510
3511 2020-05-16 Pedro Alves <palves@redhat.com>
3512
3513 * ia64-linux-nat.c
3514 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
3515 Declare method.
3516 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
3517
3518 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
3519
3520 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
3521 (sparc64_adi_info): Likewise.
3522
3523 2020-05-15 Tom Tromey <tom@tromey.com>
3524
3525 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
3526 block_objfile.
3527 (lookup_objfile_from_block): Remove.
3528 (lookup_symbol_in_block, lookup_symbol_in_static_block)
3529 (lookup_global_symbol): Use block_objfile.
3530 * symtab.h (lookup_objfile_from_block): Don't declare.
3531 * printcmd.c (clear_dangling_display_expressions): Use
3532 block_objfile.
3533 * parse.c (operator_check_standard): Use block_objfile.
3534
3535 2020-05-15 Tom Tromey <tom@tromey.com>
3536
3537 * language.c (language_alloc_type_symbol): Set
3538 SYMBOL_SECTION.
3539 * symtab.c (initialize_objfile_symbol): Remove.
3540 (allocate_symbol): Remove.
3541 (allocate_template_symbol): Remove.
3542 * dwarf2/read.c (fixup_go_packaging): Use "new".
3543 (new_symbol): Use "new".
3544 (read_variable): Don't call initialize_objfile_symbol. Use
3545 "new".
3546 (read_func_scope): Use "new".
3547 * xcoffread.c (process_xcoff_symbol): Don't call
3548 initialize_objfile_symbol.
3549 (SYMBOL_DUP): Remove.
3550 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
3551 "new".
3552 * symtab.h (allocate_symbol, initialize_objfile_symbol)
3553 (allocate_template_symbol): Don't declare.
3554 (struct symbol): Add copy constructor. Change defaults.
3555 * jit.c (finalize_symtab): Use "new".
3556 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
3557 Use "new".
3558 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
3559 (common_block_end): Use "new".
3560 * mdebugread.c (parse_symbol): Use "new".
3561 (new_symbol): Likewise.
3562
3563 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3564
3565 * NEWS: Mention changes to help and apropos.
3566
3567 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3568
3569 * command.h (enum command_class): Improve comments, document
3570 that class_alias is for user-defined aliases, give the class
3571 name for each class, remove unused class_xdb.
3572 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
3573 * breakpoint.c (_initialize_breakpoint): Replace class_alias
3574 by a precise class.
3575 * infcmd.c (_initialize_infcmd): Likewise.
3576 * reverse.c (_initialize_reverse): Likewise.
3577 * stack.c (_initialize_stack): Likewise.
3578 * symfile.c (_initialize_symfile): Likewise.
3579 * tracepoint.c (_initialize_tracepoint): Likewise.
3580
3581 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3582
3583 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
3584 when their aliased command is traversed.
3585 (help_cmd): Add fput_command_names_styled call to
3586 output command name and aliases when command has an alias.
3587
3588 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3589
3590 * cli/cli-decode.h (help_cmd_list): Remove declaration.
3591 * cli/cli-decode.c (help_cmd_list): Declare as static,
3592 remove prefix argument, use bool for recurse arg, rework to show the aliases of
3593 a command together with the command.
3594 (fput_command_name_styled, fput_command_names_styled): New functions.
3595 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
3596 fput_command_name_styled.
3597 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
3598 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
3599
3600 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3601
3602 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
3603 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
3604 * command.h (cmd_show_list): Likewise.
3605 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
3606 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
3607
3608 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3609
3610 * unittests/command-def-selftests.c (traverse_command_structure):
3611 Verify all commands of a list have the same prefix command and
3612 that only the top cmdlist commands have a null prefix.
3613
3614 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3615
3616 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
3617 as prefix, not one of its aliases.
3618 (set_cmd_prefix): Remove.
3619 (do_add_cmd): Centralize the setting of the prefix of a command, when
3620 command is defined after its full chain of prefix commands.
3621 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
3622 (add_setshow_cmd_full): Likewise.
3623 (update_prefix_field_of_prefixed_commands): New function.
3624 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
3625 update_prefix_field_of_prefixed_commands.
3626 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
3627 addresses of remote_set_cmdlist and remote_show_cmdlist given
3628 as argument, not the address of an argument.
3629 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
3630 * gdb/remote.c (_initialize_remote): Likewise.
3631
3632 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3633
3634 * cli/cli-cmds.c (alias_command): Check for an existing alias
3635 using lookup_cmd_composition, as valid_command_p is too strict
3636 and forbids aliases that are the prefix of an existing alias
3637 or command.
3638 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
3639 command is properly recognised as a valid command.
3640
3641 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3642
3643 * unittests/help-doc-selftests.c: Rename to
3644 unittests/command-def-selftests.c
3645 * unittests/command-def-selftests.c (help_doc_tests): Update some
3646 comments.
3647 (command_structure_tests, traverse_command_structure): New namespace
3648 and function.
3649 (command_structure_invariants_tests): New function.
3650 (_initialize_command_def_selftests) Renamed from
3651 _initialize_help_doc_selftests, register command_structure_invariants
3652 selftest.
3653
3654 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3655
3656 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
3657 an alias of 'show'.
3658
3659 2020-05-15 Joel Brobecker <brobecker@adacore.com>
3660
3661 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
3662 ada_is_fixed_point_type. Update all callers.
3663 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
3664 all callers.
3665 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
3666 Update all callers.
3667 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
3668 print_fixed_point_type. Update all callers.
3669 * ada-valprint.c (ada_value_print_num): Replace call to
3670 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
3671
3672 2020-05-14 Kevin Buettner <kevinb@redhat.com>
3673
3674 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
3675 processors.
3676 (cpu_supports_bts): Add CV_AMD case.
3677
3678 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
3679 Simon Marchi <simon.marchi@efficios.com>
3680
3681 * infrun.c (stop_all_threads): Collect multiple wait events at
3682 each pass.
3683
3684 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
3685
3686 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
3687 type::code instead.
3688
3689 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
3690
3691 * gdbtypes.h (struct type) <code, set_code>: New methods.
3692 (TYPE_CODE): Use type::code. Change all call sites used to set
3693 the code to use type::set_code instead.
3694
3695 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3696 Tom de Vries <tdevries@suse.de>
3697 Pedro Alves <palves@redhat.com>
3698
3699 PR threads/25478
3700 * infrun.c (stop_all_threads): Do NOT ignore
3701 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
3702 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
3703 received.
3704 (handle_no_resumed): Remove code handling a live inferior with no
3705 threads.
3706 * remote.c (has_single_non_exited_thread): New.
3707 (remote_target::update_thread_list): Do not delete a thread if is
3708 the last thread of the process.
3709 * thread.c (thread_select): Call delete_exited_threads instead of
3710 prune_threads.
3711
3712 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3713
3714 * infrun.c (stop_all_threads): Enable/disable thread events of all
3715 targets. Move a debug message denoting the end of the function
3716 into the SCOPED_EXIT block.
3717
3718 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3719
3720 * process-stratum-target.h: Include <set>.
3721 (all_non_exited_process_targets, switch_to_target_no_thread): New
3722 function declarations.
3723 * process-stratum-target.c (all_non_exited_process_targets)
3724 (switch_to_target_no_thread): New function implementations.
3725
3726 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3727
3728 * infrun.c (handle_inferior_event): Extract out a piece of code
3729 into...
3730 (mark_non_executing_threads): ...this new function.
3731
3732 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3733
3734 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
3735 use.
3736
3737 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3738
3739 * regcache.c (regcache_read_pc_protected): New function
3740 implementation that returns 0 if the PC cannot read via
3741 'regcache_read_pc'.
3742 * infrun.c (proceed): Call 'regcache_read_pc_protected'
3743 instead of 'regcache_read_pc'.
3744 (keep_going_pass_signal): Ditto.
3745
3746 2020-05-13 Tom Tromey <tromey@adacore.com>
3747
3748 * ada-lang.c (align_value): Remove.
3749 (ada_template_to_fixed_record_type_1): Use align_up.
3750
3751 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3752
3753 * async-event.c: Update the copyright year.
3754 * async-event.h: Update the copyright year.
3755
3756 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
3757
3758 * objfiles.h (is_addr_in_objfile,
3759 shared_objfile_contains_address_p): Return bool.
3760 * objfile.c (is_addr_in_objfile,
3761 shared_objfile_contains_address_p): Return bool.
3762
3763 2020-05-11 Tom Tromey <tromey@adacore.com>
3764
3765 * cli/cli-cmds.c (info_command): Restore.
3766 (_initialize_cli_cmds): Use add_prefix_command for "info".
3767 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
3768
3769 2020-05-11 Tom Tromey <tromey@adacore.com>
3770
3771 * ada-lang.c (ada_value_primitive_field): Now public.
3772 * ada-lang.h (ada_value_primitive_field): Declare.
3773 * ada-valprint.c (print_field_values): Use
3774 ada_value_primitive_field for wrapper fields.
3775
3776 2020-05-11 Tom de Vries <tdevries@suse.de>
3777
3778 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
3779 MODULE_DOMAIN.
3780
3781 2020-05-11 Tom de Vries <tdevries@suse.de>
3782
3783 PR symtab/25941
3784 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
3785 with length 0, if not gdb-produced.
3786 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
3787
3788 2020-05-09 Tom de Vries <tdevries@suse.de>
3789
3790 PR gdb/25955
3791 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
3792 calculation.
3793
3794 2020-05-09 Tom Tromey <tom@tromey.com>
3795
3796 * top.c (server_command): Now bool.
3797 * top.h (server_command): Now bool.
3798
3799 2020-05-08 Tom Tromey <tromey@adacore.com>
3800
3801 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
3802 already being processed.
3803
3804 2020-05-08 Tom Tromey <tom@tromey.com>
3805
3806 * printcmd.c (struct display) <next>: Remove.
3807 <display>: New constructor.
3808 <exp_string>: Now a std::string.
3809 <enabled_p>: Now a bool.
3810 (display_number): Move definition earlier.
3811 (displays): Rename from display_chain. Now a std::vector.
3812 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
3813 (display_command): Update.
3814 (do_one_display, disable_display)
3815 (enable_disable_display_command, do_enable_disable_display):
3816 Update.
3817 (free_display): Remove.
3818 (clear_displays): Rewrite.
3819 (delete_display): Update.
3820 (map_display_numbers): Use function_view. Remove "data"
3821 parameter. Update.
3822 (do_delete_display): Remove.
3823 (undisplay_command): Update.
3824 (do_one_display, do_displays, disable_display)
3825 (info_display_command): Update.
3826 (do_enable_disable_display): Remove.
3827 (enable_disable_display_command)
3828 (clear_dangling_display_expressions): Update.
3829
3830 2020-05-08 Tom Tromey <tom@tromey.com>
3831
3832 * symtab.c (set_symbol_cache_size)
3833 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
3834 (maintenance_print_symbol_cache_statistics): Update.
3835 * symmisc.c (print_symbol_bcache_statistics)
3836 (print_objfile_statistics, maintenance_print_objfiles)
3837 (maintenance_info_symtabs, maintenance_check_symtabs)
3838 (maintenance_expand_symtabs, maintenance_info_line_tables):
3839 Update.
3840 * symfile-debug.c (set_debug_symfile): Update.
3841 * source.c (forget_cached_source_info): Update.
3842 * python/python.c (gdbpy_progspaces): Update.
3843 * psymtab.c (maintenance_info_psymtabs): Update.
3844 * probe.c (parse_probes): Update.
3845 * linespec.c (iterate_over_all_matching_symtabs)
3846 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
3847 * guile/scm-progspace.c (gdbscm_progspaces): Update.
3848 * exec.c (exec_target::close): Update.
3849 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
3850 * breakpoint.c (print_one_breakpoint_location)
3851 (create_longjmp_master_breakpoint)
3852 (create_std_terminate_master_breakpoint): Update.
3853 * progspace.c (program_spaces): Now a std::vector.
3854 (maybe_new_address_space): Update.
3855 (add_program_space): Remove.
3856 (program_space::program_space): Update.
3857 (remove_program_space): Update.
3858 (number_of_program_spaces): Remove.
3859 (print_program_space, update_address_spaces): Update.
3860 * progspace.h (program_spaces): Change type.
3861 (ALL_PSPACES): Remove.
3862 (number_of_program_spaces): Don't declare.
3863 (struct program_space) <next>: Remove.
3864
3865 2020-05-08 Tom Tromey <tom@tromey.com>
3866
3867 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
3868 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
3869 (enable_break): Update.
3870 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
3871 (frv_fdpic_find_canonical_descriptor): Update.
3872 (frv_fetch_objfile_link_map): Update.
3873 * progspace.c (program_space::free_all_objfiles): Update.
3874 (program_space::solibs): New method.
3875 * progspace.h (struct program_space) <solibs>: New method.
3876 * solist.h (master_so_list): Don't declare.
3877 (ALL_SO_LIBS): Remove.
3878 * solib.h (so_list_head): Remove.
3879 (update_solib_list): Update comment.
3880 * solib.c (master_so_list): Remove.
3881 (solib_used, update_solib_list, solib_add)
3882 (info_sharedlibrary_command, clear_solib)
3883 (reload_shared_libraries_1, remove_user_added_objfile): Update.
3884
3885 2020-05-08 Tom Tromey <tom@tromey.com>
3886
3887 * extension.c (extension_languages): Now a std::array.
3888 (ALL_EXTENSION_LANGUAGES): Remove.
3889 (get_ext_lang_defn, get_ext_lang_of_file)
3890 (eval_ext_lang_from_control_command): Update.
3891 (finish_ext_lang_initialization)
3892 (auto_load_ext_lang_scripts_for_objfile)
3893 (ext_lang_type_printers::ext_lang_type_printers)
3894 (apply_ext_lang_type_printers)
3895 (ext_lang_type_printers::~ext_lang_type_printers)
3896 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
3897 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
3898 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
3899 (get_matching_xmethod_workers, ext_lang_colorize)
3900 (ext_lang_before_prompt): Update.
3901 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
3902
3903 2020-05-08 Tom Tromey <tom@tromey.com>
3904
3905 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
3906 overload.
3907 <swap_string, m_string>: Remove.
3908 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
3909 Update.
3910 * stabsread.c (define_symbol, read_type): Update.
3911 * linespec.c (find_linespec_symbols): Update.
3912 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
3913 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
3914 * dbxread.c (read_dbx_symtab): Update.
3915 * cp-support.h (cp_canonicalize_string_full)
3916 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
3917 Return unique_xmalloc_ptr.
3918 * cp-support.c (inspect_type): Update.
3919 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
3920 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
3921 Likewise.
3922 * c-typeprint.c (print_name_maybe_canonical): Update.
3923 * break-catch-throw.c (check_status_exception_catchpoint):
3924 Update.
3925
3926 2020-05-08 Tom de Vries <tdevries@suse.de>
3927
3928 * infrun.c (follow_fork): Copy current_line and current_symtab to
3929 child thread.
3930
3931 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3932
3933 * async-event.c (struct async_signal_handler, struct
3934 async_event_handler): Reformat, remove typedef.
3935
3936 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3937
3938 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
3939 access thistype->main_type->dyn_prop_list directly.
3940
3941 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3942
3943 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
3944 (remove_dyn_prop): Remove. Update all users to use
3945 type::remove_dyn_prop.
3946 * gdbtypes.c (remove_dyn_prop): Rename to...
3947 (type::remove_dyn_prop): ... this.
3948
3949 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
3950
3951 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
3952 (add_dyn_prop): Remove. Update all users to use
3953 type::add_dyn_prop.
3954 * gdbtypes.c (add_dyn_prop): Rename to...
3955 (type::add_dyn_prop): ... this.
3956
3957 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3958
3959 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
3960 (get_dyn_prop): Remove. Update all users to use
3961 type::dyn_prop.
3962 * gdbtypes.c (get_dyn_prop): Rename to...
3963 (type::dyn_prop): ... this.
3964
3965 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
3966
3967 * gdbtypes.h (struct main_type) <flag_static>: Remove.
3968
3969 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
3970
3971 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
3972 instruction, skip it if it's there.
3973
3974 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
3975
3976 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
3977
3978 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
3979
3980 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
3981 * gdbtypes.c (recursive_dump_type): Remove use of
3982 TYPE_INCOMPLETE.
3983
3984 2020-05-03 Tom Tromey <tom@tromey.com>
3985
3986 * breakpoint.c (catch_command, tcatch_command): Remove.
3987 (_initialize_breakpoint): Use add_basic_prefix_cmd,
3988 add_show_prefix_cmd.
3989 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
3990 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
3991 Remove.
3992 (add_internal_problem_command): Use add_basic_prefix_cmd,
3993 add_show_prefix_cmd.
3994 * mips-tdep.c (set_mipsfpu_command): Remove.
3995 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
3996 * dwarf2/index-cache.c (set_index_cache_command): Remove.
3997 (_initialize_index_cache): Use add_basic_prefix_cmd.
3998 * memattr.c (dummy_cmd): Remove.
3999 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
4000 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
4001 (_initialize_tui_win): Use add_basic_prefix_cmd,
4002 add_show_prefix_cmd.
4003 * cli/cli-logging.c (set_logging_command): Remove.
4004 (_initialize_cli_logging): Use add_basic_prefix_cmd,
4005 add_show_prefix_cmd.
4006 (show_logging_command): Remove.
4007 * target.c (target_command): Remove.
4008 (add_target): Use add_basic_prefix_cmd.
4009
4010 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
4011
4012 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
4013
4014 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4015
4016 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
4017 info_command.
4018
4019 2020-04-30 Kamil Rytarowski <n54@gmx.com>
4020
4021 * nbsd-nat.c (nbsd_enable_proc_events)
4022 (nbsd_nat_target::post_startup_inferior): Add.
4023 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
4024 (nbsd_nat_target::update_thread_list): Rewrite.
4025 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
4026 "PTRACE_LWP_CREATE".
4027 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
4028
4029 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4030
4031 * stack.c (_initialize_stack): Remove duplicated creation
4032 of "frame" command and "f" alias.
4033
4034 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4035
4036 PR gdb/18706
4037 * gdbtypes.c (check_typedef): Calculate size of array of
4038 stubbed type.
4039
4040 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4041
4042 PR gdb/15559
4043 * i386-tdep.c (i386_push_dummy_call): Call
4044 i386_thiscall_push_dummy_call.
4045 (i386_thiscall_push_dummy_call): New function.
4046 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
4047 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
4048 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
4049
4050 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4051
4052 * gdbarch.sh (do_read): Add shellcheck disable directive for
4053 warning SC2162.
4054
4055 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4056
4057 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
4058 "referenced but not assigned" warning.
4059
4060 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4061
4062 * gdbarch.sh: Remove code that sets fallbackdefault.
4063
4064 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4065
4066 * gdbarch.sh: Use shell operators && and || instead of
4067 -a and -o.
4068
4069 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4070
4071 * gdbarch.sh: Use $(...) instead of `...`.
4072
4073 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4074
4075 * gdbarch.sh: Use double quotes around variables.
4076
4077 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4078
4079 * gdbarch.sh: Use %s with printf, instead of variables in the
4080 format string.
4081
4082 2020-04-29 Tom Tromey <tromey@adacore.com>
4083
4084 PR ada/25875:
4085 * dwarf2/read.c (update_enumeration_type_from_children): Compute
4086 type fields here.
4087 (read_enumeration_type): Call
4088 update_enumeration_type_from_children later. Update comments.
4089 (process_enumeration_scope): Don't create type fields.
4090
4091 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4092
4093 * nbsd-tdep.c: Include "xml-syscall.h".
4094 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
4095
4096 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4097
4098 * nbsd-nat.c: Include "sys/wait.h".
4099 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
4100 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
4101 (nbsd_nat_target::remove_exec_catchpoint)
4102 (nbsd_nat_target::set_syscall_catchpoint): Add.
4103 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
4104 (nbsd_nat_target::insert_exec_catchpoint)
4105 (nbsd_nat_target::remove_exec_catchpoint)
4106 (nbsd_nat_target::set_syscall_catchpoint): Add.
4107 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
4108 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
4109 `nbsd_get_syscall_number'.
4110
4111 2020-04-29 Tom Tromey <tom@tromey.com>
4112
4113 * stack.c (print_block_frame_labels): Remove.
4114
4115 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
4116
4117 PR gdb/17320
4118 * ada-valprint.c (val_print_packed_array_elements): Move array
4119 end bracket to new line.
4120 (ada_val_print_string): Remove extra spaces before first array
4121 element.
4122 * c-valprint.c (c_value_print_array): Likewise.
4123 * m2-valprint.c (m2_print_array_contents): Likewise.
4124 (m2_value_print_inner): Likewise.
4125 * p-valprint.c (pascal_value_print_inner): Likewise.
4126 * valprint.c (generic_val_print_array): Likewise.
4127 (value_print_array_elements): Move first array element and array
4128 end bracket to new line.
4129
4130 2020-04-29 Tom de Vries <tdevries@suse.de>
4131
4132 PR symtab/25889
4133 * linespec.c (find_method): Fix ix calculation.
4134
4135 2020-04-28 Kamil Rytarowski <n54@gmx.com>
4136
4137 * syscalls/update-netbsd.sh: New file.
4138 * syscalls/netbsd.xml: Regenerate.
4139 * data-directory/Makefile.in: Register `netbsd.xml' in
4140 `SYSCALLS_FILES'.
4141
4142 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
4143
4144 * syscalls/update-freebsd.sh: Add double quotes.
4145
4146 2020-04-28 Tom Tromey <tom@tromey.com>
4147
4148 * NEWS: Update.
4149 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
4150 (cmdpy_init): Allow class_tui.
4151
4152 2020-04-28 Mark Williams <mark@myosotissp.com>
4153
4154 PR gdb/24480
4155 * dwarf2read.c: Add missing assingments to list_in_scope when
4156 start_symtab was already called.
4157
4158 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
4159
4160 PR gdb/25881
4161 * dwarf2/read.c (offset_map_type): Use
4162 gdb:hash_enum<sect_offset> as hash function.
4163
4164 2020-04-28 Tom de Vries <tdevries@suse.de>
4165
4166 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
4167 with DW_AT_signature.
4168
4169 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
4170
4171 * configure.ac: Remove check for fs_base/gs_base in
4172 user_regs_struct.
4173 * configure: Re-generate.
4174 * config.in: Re-generate.
4175 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
4176 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
4177 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
4178
4179 2020-04-27 Luis Machado <luis.machado@linaro.org>
4180
4181 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
4182 problematic inline frame unwinding situation.
4183 * frame.c (frame_id_computed_p): New function.
4184 * frame.h (frame_id_computed_p): New prototype.
4185
4186 2020-04-26 Tom Tromey <tom@tromey.com>
4187
4188 * command.h (enum command_class) <class_pseudo>: Remove.
4189
4190 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4191
4192 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
4193 and whitespace.
4194
4195 2020-04-25 Kamil Rytarowski <n54@gmx.com>
4196
4197 * inf-ptrace.c (inf_ptrace_target::wait): Remove
4198 `PT_GET_PROCESS_STATE' block.
4199
4200 2020-04-24 Tom Tromey <tom@tromey.com>
4201
4202 * symtab.h (symbol_get_demangled_name): Don't declare.
4203 * symtab.c (symbol_get_demangled_name): Remove.
4204 (general_symbol_info::natural_name)
4205 (general_symbol_info::demangled_name): Update.
4206
4207 2020-04-24 Tom Tromey <tom@tromey.com>
4208
4209 PR rust/25025:
4210 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
4211
4212 2020-04-24 Tom Tromey <tom@tromey.com>
4213
4214 PR symtab/12707:
4215 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
4216 exists.
4217 (new_symbol): Likewise.
4218 * compile/compile-object-load.c (get_out_value_type): Use
4219 symbol_matches_search_name.
4220
4221 2020-04-24 Tom Tromey <tom@tromey.com>
4222
4223 * dwarf2/read.c (add_partial_symbol): Do not call
4224 compute_and_set_names.
4225
4226 2020-04-24 Tom Tromey <tom@tromey.com>
4227
4228 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
4229 overload.
4230
4231 2020-04-24 Tom Tromey <tom@tromey.com>
4232
4233 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
4234 (add_psymbol_to_list): New overload. Make old overload call new
4235 one.
4236 * psympriv.h (add_psymbol_to_list): New overload.
4237
4238 2020-04-24 Tom Tromey <tom@tromey.com>
4239
4240 * dwarf2/read.c (partial_die_info::read) <case
4241 DW_AT_linkage_name>: Use value_as_string.
4242 (dwarf2_string_attr): Use value_as_string.
4243 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
4244 method.
4245 * dwarf2/attribute.c (attribute::value_as_string): New method.
4246
4247 2020-04-24 Tom Tromey <tom@tromey.com>
4248
4249 * symtab.c (general_symbol_info::natural_name)
4250 (general_symbol_info::demangled_name): Check for language_rust.
4251
4252 2020-04-24 Tom Tromey <tom@tromey.com>
4253
4254 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
4255 (dwarf2_physname): ... from here.
4256 (partial_die_info::read): Add Rust "{" hack.
4257
4258 2020-04-24 Tom Tromey <tom@tromey.com>
4259
4260 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
4261 method.
4262 (symbol_set_demangled_name): Don't declare.
4263 * symtab.c (general_symbol_info::set_demangled_name): Rename from
4264 symbol_set_demangled_name.
4265 (general_symbol_info::set_language)
4266 (general_symbol_info::compute_and_set_names): Update.
4267 * minsyms.c (minimal_symbol_reader::install): Update.
4268 * dwarf2/read.c (new_symbol): Update.
4269
4270 2020-04-24 Tom Tromey <tromey@adacore.com>
4271
4272 PR python/23662:
4273 * python/py-type.c (convert_field): Handle
4274 FIELD_LOC_KIND_DWARF_BLOCK.
4275 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
4276 (typy_get_dynamic): Nw function.
4277 (type_object_getset): Add "dynamic".
4278 * NEWS: Add entry.
4279
4280 2020-04-24 Tom Tromey <tromey@adacore.com>
4281
4282 * ada-typeprint.c (print_choices, print_variant_part)
4283 (print_record_field_types_dynamic): New functions.
4284 (print_record_field_types): Use print_record_field_types_dynamic.
4285
4286 2020-04-24 Tom Tromey <tromey@adacore.com>
4287
4288 * dwarf2/read.c (handle_data_member_location): New overload.
4289 (dwarf2_add_field): Use it.
4290 (decode_locdesc): Add "computed" parameter. Update comment.
4291 * gdbtypes.c (is_dynamic_type_internal): Also look for
4292 FIELD_LOC_KIND_DWARF_BLOCK.
4293 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
4294 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
4295 virtual base classes.
4296 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
4297 FIELD_LOC_KIND_DWARF_BLOCK.
4298
4299 2020-04-24 Tom Tromey <tromey@adacore.com>
4300
4301 * dwarf2/read.c (read_structure_type): Handle dynamic length.
4302 * gdbtypes.c (is_dynamic_type_internal): Check
4303 TYPE_HAS_DYNAMIC_LENGTH.
4304 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
4305 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
4306 New macros.
4307 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
4308 constant.
4309
4310 2020-04-24 Tom Tromey <tromey@adacore.com>
4311
4312 * dwarf2/read.c (struct variant_field): Rewrite.
4313 (struct variant_part_builder): New.
4314 (struct nextfield): Remove "variant" field. Add "offset".
4315 (struct field_info): Add "current_variant_part" and
4316 "variant_parts".
4317 (alloc_discriminant_info): Remove.
4318 (alloc_rust_variant): New function.
4319 (quirk_rust_enum): Update.
4320 (dwarf2_add_field): Set "offset" member. Don't handle
4321 DW_TAG_variant_part.
4322 (offset_map_type): New typedef.
4323 (convert_variant_range, create_one_variant)
4324 (create_one_variant_part, create_variant_parts)
4325 (add_variant_property): New functions.
4326 (dwarf2_attach_fields_to_type): Call add_variant_property.
4327 (read_structure_type): Don't handle DW_TAG_variant_part.
4328 (handle_variant_part, handle_variant): New functions.
4329 (handle_struct_member_die): Use them.
4330 (process_structure_scope): Don't handle variant parts.
4331 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
4332 (struct discriminant_info): Remove.
4333 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
4334 (struct main_type) <flag_discriminated_union>: Remove.
4335 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
4336 (rust_enum_variant): Return int. Remove "contents". Rewrite.
4337 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
4338 Update.
4339 * valops.c (value_union_variant): Remove.
4340 * value.h (value_union_variant): Don't declare.
4341
4342 2020-04-24 Tom Tromey <tromey@adacore.com>
4343
4344 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
4345 (ada_value_primitive_packed_val): Update.
4346 * ada-valprint.c (ada_value_print_1): Update.
4347 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
4348 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
4349 just an address. Use evaluate_for_locexpr_baton.
4350 (dwarf2_evaluate_property): Update.
4351 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
4352 array_view.
4353 * findvar.c (default_read_var_value): Update.
4354 * gdbtypes.c (compute_variant_fields_inner)
4355 (resolve_dynamic_type_internal): Update.
4356 (resolve_dynamic_type): Change type of valaddr parameter.
4357 * gdbtypes.h (resolve_dynamic_type): Update.
4358 * valarith.c (value_subscripted_rvalue): Update.
4359 * value.c (value_from_contents_and_address): Update.
4360
4361 2020-04-24 Tom Tromey <tromey@adacore.com>
4362
4363 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
4364 "push_initial_value" parameter.
4365 (dwarf2_evaluate_property): Likewise.
4366 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
4367
4368 2020-04-24 Tom Tromey <tromey@adacore.com>
4369
4370 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
4371 (variant::matches, compute_variant_fields_recurse)
4372 (compute_variant_fields_inner, compute_variant_fields): New
4373 functions.
4374 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
4375 Use resolved_type after type is made.
4376 (operator==): Add new cases.
4377 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
4378 (struct discriminant_range, struct variant, struct variant_part):
4379 New.
4380 (union dynamic_prop_data) <variant_parts, original_type>: New
4381 members.
4382 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
4383 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
4384 constants.
4385 * value.c (unpack_bits_as_long): Now public.
4386 * value.h (unpack_bits_as_long): Declare.
4387
4388 2020-04-24 Tom Tromey <tromey@adacore.com>
4389
4390 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
4391 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
4392
4393 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
4394
4395 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
4396
4397 2020-04-24 Kamil Rytarowski <n54@gmx.com>
4398
4399 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
4400 (remove_fork_catchpoint, post_startup_inferior)
4401 (post_attach): Move...
4402 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
4403 (remove_fork_catchpoint, post_startup_inferior)
4404 (post_attach): ...here.
4405 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
4406 (remove_fork_catchpoint, post_startup_inferior)
4407 (post_attach): Move...
4408 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
4409 (remove_fork_catchpoint, post_startup_inferior)
4410 (post_attach): ...here.
4411
4412 2020-04-24 Tom Tromey <tromey@adacore.com>
4413
4414 * nat/windows-nat.h (struct windows_thread_info)
4415 <pc_adjusted>: New member.
4416 * windows-nat.c (windows_fetch_one_register): Check
4417 pc_adjusted.
4418 (windows_nat_target::get_windows_debug_event)
4419 (windows_nat_target::wait): Set pc_adjusted.
4420
4421 2020-04-24 Tom de Vries <tdevries@suse.de>
4422
4423 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
4424 Run gdb-add-index inside temp dir.
4425
4426 2020-04-23 Tom Tromey <tromey@adacore.com>
4427
4428 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
4429 in loop.
4430
4431 2020-04-23 Luis Machado <luis.machado@linaro.org>
4432
4433 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
4434 get_frame_register instead of gdbarch_unwind_pc.
4435
4436 2020-04-23 Tom de Vries <tdevries@suse.de>
4437
4438 * symtab.c (lookup_global_symbol): Prefer def over decl.
4439
4440 2020-04-23 Tom de Vries <tdevries@suse.de>
4441
4442 PR symtab/25807
4443 * block.c (best_symbol, better_symbol): Promote to external.
4444 * block.h (best_symbol, better_symbol): Declare.
4445 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
4446 decl.
4447
4448 2020-04-23 Tom Tromey <tromey@adacore.com>
4449
4450 PR ada/25837:
4451 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
4452 "const char *", not a "const std::string &".
4453 <name_and_matcher::operator==>: Update.
4454 * unittests/lookup_name_info-selftests.c: Change type of
4455 "result".
4456
4457 2020-04-23 Tom Tromey <tom@tromey.com>
4458
4459 * inferior.h (iterate_over_inferiors): Don't declare.
4460 * inferior.c (iterate_over_inferiors): Remove.
4461 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
4462 Remove.
4463 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
4464 use iterate_over_inferiors.
4465 (darwin_resume_inferior_it)
4466 (struct resume_inferior_threads_param)
4467 (darwin_resume_inferior_threads_it): Remove.
4468 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
4469
4470 2020-04-23 Tom de Vries <tdevries@suse.de>
4471
4472 * blockframe.c (find_pc_partial_function): Use
4473 find_pc_sect_compunit_symtab rather than
4474 objfile->sf->qf->find_pc_sect_compunit_symtab.
4475
4476 2020-04-22 Tom de Vries <tdevries@suse.de>
4477
4478 PR symtab/25764
4479 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
4480 in psymtabs.
4481
4482 2020-04-22 Tom de Vries <tdevries@suse.de>
4483
4484 PR symtab/25801
4485 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
4486 symtabs.
4487
4488 2020-04-22 Tom de Vries <tdevries@suse.de>
4489
4490 PR symtab/25700
4491 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
4492 CU if already created.
4493
4494 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4495
4496 * infrun.c (displaced_step_fixup): Switch to the event_thread
4497 before calling displaced_step_restore, not after.
4498
4499 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4500
4501 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
4502 its inferior is not recorded by us.
4503 (record_btrace_target_open): Replace call to
4504 all_non_exited_threads () with call to current_inferior
4505 ()->non_exited_threads ().
4506 (record_btrace_target::stop_recording): Likewise.
4507 (record_btrace_target::close): Likewise.
4508 (record_btrace_target::wait): Likewise.
4509 (record_btrace_target::record_stop_replaying): Likewise.
4510
4511 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4512
4513 * btrace.c (btrace_enable): Throw an error on double enables and
4514 when enabling recording fails.
4515 (btrace_disable): Throw an error if the thread is not recorded.
4516
4517 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4518
4519 * record-btrace.c (record_btrace_target::fetch_registers): Forward
4520 request if we do not have a thread_info.
4521
4522 2020-04-21 Tom de Vries <tdevries@suse.de>
4523
4524 PR gdb/25471
4525 * thread.c
4526 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
4527 exception in get_frame_id.
4528
4529 2020-04-20 Tom Tromey <tromey@adacore.com>
4530
4531 * python/python.c (struct gdbpy_event): Mark move constructor as
4532 noexcept.
4533 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
4534 constructor as noexcept.
4535 * completer.h (struct completion_result): Mark move constructor as
4536 noexcept.
4537 * completer.c (completion_result::completion_result): Use
4538 initialization style. Don't call reset_match_list.
4539
4540 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
4541
4542 * MAINTAINERS (Write After Approval): Add myself.
4543
4544 2020-04-18 Tom Tromey <tom@tromey.com>
4545
4546 * windows-tdep.c (init_w32_command_list)
4547 (w32_prefix_command_valid): Restore.
4548 (_initialize_windows_tdep): Call init_w32_command_list.
4549
4550 2020-04-18 Tom Tromey <tom@tromey.com>
4551
4552 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
4553 * value.c (value_fn_field): Update.
4554 * valops.c (find_function_in_inferior)
4555 (value_allocate_space_in_inferior): Update.
4556 * tui/tui-winsource.c (tui_update_source_windows_with_line):
4557 Update.
4558 * tui/tui-source.c (tui_source_window::set_contents): Update.
4559 * symtab.c (lookup_global_or_static_symbol)
4560 (find_function_start_sal_1, skip_prologue_sal)
4561 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
4562 * symmisc.c (dump_msymbols, dump_symtab_1)
4563 (maintenance_print_one_line_table): Update.
4564 * symfile.c (init_entry_point_info, section_is_mapped)
4565 (list_overlays_command, simple_read_overlay_table)
4566 (simple_overlay_update_1): Update.
4567 * stap-probe.c (handle_stap_probe): Update.
4568 * stabsread.c (dbx_init_float_type, define_symbol)
4569 (read_one_struct_field, read_enum_type, read_range_type): Update.
4570 * source.c (info_line_command): Update.
4571 * python/python.c (gdbpy_source_objfile_script)
4572 (gdbpy_execute_objfile_script): Update.
4573 * python/py-type.c (save_objfile_types): Update.
4574 * python/py-objfile.c (py_free_objfile): Update.
4575 * python/py-inferior.c (python_new_objfile): Update.
4576 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
4577 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
4578 (maintenance_check_psymtabs): Update.
4579 * printcmd.c (info_address_command): Update.
4580 * objfiles.h (struct objfile) <arch>: New method, from
4581 get_objfile_arch.
4582 (get_objfile_arch): Don't declare.
4583 * objfiles.c (get_objfile_arch): Remove.
4584 (filter_overlapping_sections): Update.
4585 * minsyms.c (msymbol_is_function): Update.
4586 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
4587 (output_nondebug_symbol): Update.
4588 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
4589 (mdebug_expand_psymtab): Update.
4590 * machoread.c (macho_add_oso_symfile): Update.
4591 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
4592 Update.
4593 * linux-fork.c (checkpoint_command): Update.
4594 * linespec.c (convert_linespec_to_sals): Update.
4595 * jit.c (finalize_symtab): Update.
4596 * infrun.c (insert_exception_resume_from_probe): Update.
4597 * ia64-tdep.c (ia64_find_unwind_table): Update.
4598 * hppa-tdep.c (internalize_unwinds): Update.
4599 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
4600 Update.
4601 * gcore.c (call_target_sbrk): Update.
4602 * elfread.c (record_minimal_symbol, elf_symtab_read)
4603 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
4604 (elf_gnu_ifunc_resolve_by_got): Update.
4605 * dwarf2/read.c (create_addrmap_from_index)
4606 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
4607 (read_debug_names_from_section)
4608 (process_psymtab_comp_unit_reader, add_partial_symbol)
4609 (add_partial_subprogram, process_full_comp_unit)
4610 (read_file_scope, read_func_scope, read_lexical_block_scope)
4611 (read_call_site_scope, dwarf2_ranges_read)
4612 (dwarf2_record_block_ranges, dwarf2_add_field)
4613 (mark_common_block_symbol_computed, read_tag_pointer_type)
4614 (read_tag_string_type, dwarf2_init_float_type)
4615 (dwarf2_init_complex_target_type, read_base_type)
4616 (partial_die_info::read, partial_die_info::read)
4617 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
4618 (dwarf2_fetch_die_loc_sect_off): Update.
4619 * dwarf2/loc.c (dwarf2_find_location_expression)
4620 (class dwarf_evaluate_loc_desc, rw_pieced_value)
4621 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
4622 (dwarf2_loc_desc_get_symbol_read_needs)
4623 (locexpr_describe_location_piece, locexpr_describe_location_1)
4624 (loclist_describe_location): Update.
4625 * dwarf2/index-write.c (write_debug_names): Update.
4626 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
4627 * dtrace-probe.c (dtrace_process_dof): Update.
4628 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
4629 (process_one_symbol): Update.
4630 * ctfread.c (ctf_init_float_type, read_base_type): Update.
4631 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
4632 (coff_read_enum_type): Update.
4633 * cli/cli-cmds.c (edit_command, list_command): Update.
4634 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
4635 * breakpoint.c (create_overlay_event_breakpoint)
4636 (create_longjmp_master_breakpoint)
4637 (create_std_terminate_master_breakpoint)
4638 (create_exception_master_breakpoint, get_sal_arch): Update.
4639 * block.c (block_gdbarch): Update.
4640 * annotate.c (annotate_source_line): Update.
4641
4642 2020-04-17 Tom Tromey <tromey@adacore.com>
4643
4644 * auto-load.c (show_auto_load_cmd): Remove.
4645 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
4646 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
4647 (maintenance_print_arc_command): Remove.
4648 * tui/tui-win.c (tui_command): Remove.
4649 (tui_get_cmd_list): Use add_basic_prefix_cmd.
4650 * tui/tui-layout.c (tui_layout_command): Remove.
4651 (_initialize_tui_layout): Use add_basic_prefix_cmd.
4652 * python/python.c (user_set_python, user_show_python): Remove.
4653 (_initialize_python): Use add_basic_prefix_cmd,
4654 add_show_prefix_cmd.
4655 * guile/guile.c (set_guile_command, show_guile_command): Remove.
4656 (install_gdb_commands): Use add_basic_prefix_cmd,
4657 add_show_prefix_cmd.
4658 (info_guile_command): Remove.
4659 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
4660 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
4661 add_show_prefix_cmd.
4662 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
4663 Remove do_set and do_show parameters.
4664 * cli/cli-style.c (set_style, show_style): Remove.
4665 (_initialize_cli_style): Use add_basic_prefix_cmd,
4666 add_show_prefix_cmd.
4667 (cli_style_option::add_setshow_commands): Remove do_set and
4668 do_show parameters.
4669 (cli_style_option::add_setshow_commands): Use
4670 add_basic_prefix_cmd, add_show_prefix_cmd.
4671 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
4672 (set_style_name): Remove.
4673 * cli/cli-dump.c (dump_command, append_command): Remove.
4674 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4675 (tekhex_dump_command, binary_dump_command)
4676 (binary_append_command): Remove.
4677 (_initialize_cli_dump): Use add_basic_prefix_cmd.
4678 * windows-tdep.c (w32_prefix_command_valid): Remove global.
4679 (init_w32_command_list): Remove; move into ...
4680 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
4681 * valprint.c (set_print, show_print, set_print_raw)
4682 (show_print_raw): Remove.
4683 (_initialize_valprint): Use add_basic_prefix_cmd,
4684 add_show_prefix_cmd.
4685 * typeprint.c (set_print_type, show_print_type): Remove.
4686 (_initialize_typeprint): Use add_basic_prefix_cmd,
4687 add_show_prefix_cmd.
4688 * record.c (set_record_command, show_record_command): Remove.
4689 (_initialize_record): Use add_basic_prefix_cmd,
4690 add_show_prefix_cmd.
4691 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
4692 add_show_prefix_cmd.
4693 (info_command, show_command, set_debug, show_debug): Remove.
4694 * top.h (set_history, show_history): Don't declare.
4695 * top.c (set_history, show_history): Remove.
4696 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4697 (unset_tdesc_cmd): Remove.
4698 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
4699 add_show_prefix_cmd.
4700 * symtab.c (info_module_command): Remove.
4701 (_initialize_symtab): Use add_basic_prefix_cmd.
4702 * symfile.c (overlay_command): Remove.
4703 (_initialize_symfile): Use add_basic_prefix_cmd.
4704 * sparc64-tdep.c (info_adi_command): Remove.
4705 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
4706 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
4707 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
4708 add_show_prefix_cmd.
4709 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
4710 (_initialize_serial): Use add_basic_prefix_cmd,
4711 add_show_prefix_cmd.
4712 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
4713 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
4714 add_show_prefix_cmd.
4715 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
4716 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
4717 add_show_prefix_cmd.
4718 * riscv-tdep.c (show_riscv_command, set_riscv_command)
4719 (show_debug_riscv_command, set_debug_riscv_command): Remove.
4720 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
4721 add_show_prefix_cmd.
4722 * remote.c (remote_command, set_remote_cmd): Remove.
4723 (_initialize_remote): Use add_basic_prefix_cmd.
4724 * record-full.c (set_record_full_command)
4725 (show_record_full_command): Remove.
4726 (_initialize_record_full): Use add_basic_prefix_cmd,
4727 add_show_prefix_cmd.
4728 * record-btrace.c (cmd_set_record_btrace)
4729 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
4730 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
4731 (cmd_show_record_btrace_pt): Remove.
4732 (_initialize_record_btrace): Use add_basic_prefix_cmd,
4733 add_show_prefix_cmd.
4734 * ravenscar-thread.c (set_ravenscar_command)
4735 (show_ravenscar_command): Remove.
4736 (_initialize_ravenscar): Use add_basic_prefix_cmd,
4737 add_show_prefix_cmd.
4738 * mips-tdep.c (show_mips_command, set_mips_command)
4739 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
4740 add_show_prefix_cmd.
4741 * maint.c (maintenance_command, maintenance_info_command)
4742 (maintenance_check_command, maintenance_print_command)
4743 (maintenance_set_cmd, maintenance_show_cmd): Remove.
4744 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
4745 add_show_prefix_cmd.
4746 (show_per_command_cmd): Remove.
4747 * maint-test-settings.c (maintenance_set_test_settings_cmd):
4748 Remove.
4749 (maintenance_show_test_settings_cmd): Remove.
4750 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
4751 add_show_prefix_cmd.
4752 * maint-test-options.c (maintenance_test_options_command):
4753 Remove.
4754 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
4755 * macrocmd.c (macro_command): Remove
4756 (_initialize_macrocmd): Use add_basic_prefix_cmd.
4757 * language.c (set_check, show_check): Remove.
4758 (_initialize_language): Use add_basic_prefix_cmd,
4759 add_show_prefix_cmd.
4760 * infcmd.c (unset_command): Remove.
4761 (_initialize_infcmd): Use add_basic_prefix_cmd.
4762 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
4763 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
4764 add_show_prefix_cmd.
4765 * go32-nat.c (go32_info_dos_command): Remove.
4766 (_initialize_go32_nat): Use add_basic_prefix_cmd.
4767 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
4768 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
4769 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
4770 (_initialize_frame): Use add_basic_prefix_cmd,
4771 add_show_prefix_cmd.
4772 * dcache.c (set_dcache_command, show_dcache_command): Remove.
4773 (_initialize_dcache): Use add_basic_prefix_cmd,
4774 add_show_prefix_cmd.
4775 * cp-support.c (maint_cplus_command): Remove.
4776 (_initialize_cp_support): Use add_basic_prefix_cmd.
4777 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4778 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4779 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
4780 add_basic_prefix_cmd, add_show_prefix_cmd.
4781 * breakpoint.c (save_command): Remove.
4782 (_initialize_breakpoint): Use add_basic_prefix_cmd.
4783 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
4784 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
4785 add_show_prefix_cmd.
4786 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
4787 (set_ada_command, show_ada_command): Remove.
4788 (_initialize_ada_language): Use add_basic_prefix_cmd,
4789 add_show_prefix_cmd.
4790 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
4791
4792 2020-04-16 Kamil Rytarowski <n54@gmx.com>
4793
4794 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
4795 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
4796
4797 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
4798
4799 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
4800 warning messages.
4801
4802 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
4803
4804 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
4805 import table is not at beginning of .idata section.
4806
4807 2020-04-16 Pedro Alves <palves@redhat.com>
4808
4809 * inferior.c (delete_inferior): Use delete operator directly
4810 instead of delete_program_space.
4811 * progspace.c (add_program_space): New, factored out from
4812 program_space::program_space.
4813 (remove_program_space): New, factored out from
4814 delete_program_space.
4815 (program_space::program_space): Remove intro comment. Rewrite.
4816 (program_space::~program_space): Remove intro comment. Call
4817 remove_program_space.
4818 (delete_program_space): Delete.
4819 * progspace.h (program_space::program_space): Make explicit. Move
4820 intro comment here, adjusted.
4821 (program_space::~program_space): Move intro comment here,
4822 adjusted.
4823 (delete_program_space): Remove.
4824
4825 2020-04-16 Tom Tromey <tromey@adacore.com>
4826
4827 * windows-nat.c (windows_nat::handle_access_violation): New
4828 function.
4829 * nat/windows-nat.h (handle_access_violation): Declare.
4830 * nat/windows-nat.c (handle_exception): Move Cygwin code to
4831 windows-nat.c. Call handle_access_violation.
4832
4833 2020-04-16 Tom de Vries <tdevries@suse.de>
4834
4835 PR symtab/25791
4836 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
4837 CUs without psymtab.
4838
4839 2020-04-16 Kevin Buettner <kevinb@redhat.com>
4840
4841 * python/python.c (do_start_initialization): Don't call
4842 PyEval_InitThreads for Python 3.9 and beyond.
4843
4844 2020-04-15 Kamil Rytarowski <n54@gmx.com>
4845
4846 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
4847 thread functions.
4848 (obsd_nat_target::wait): Likewise.
4849
4850 2020-04-15 Tom Tromey <tromey@adacore.com>
4851
4852 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
4853 (DEBUG_EXCEPT): Use debug_printf.
4854
4855 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
4856
4857 * completer.c (class completion_tracker::completion_hash_entry)
4858 <hash_name>: New member function.
4859 (completion_tracker::discard_completions): New callback to hash a
4860 completion_hash_entry, pass this to htab_create_alloc.
4861
4862 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
4863
4864 * windows-nat.c (windows_make_so): Warn rather than stopping with
4865 an error if realpath() fails.
4866
4867 2020-04-14 Kamil Rytarowski <n54@gmx.com>
4868
4869 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
4870 (nbsd_nat_target::info_proc): Add do_status.
4871
4872 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
4873 Tom de Vries <tdevries@suse.de>
4874
4875 PR symtab/25718
4876 * psympriv.h (struct partial_symtab::read_symtab)
4877 (struct partial_symtab::expand_psymtab)
4878 (struct partial_symtab::read_dependencies): Update comments.
4879 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
4880 read_symtab for includer.
4881 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
4882 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
4883 (struct dwarf2_include_psymtab::m_readin): Remove.
4884 (struct dwarf2_include_psymtab::includer): New member function.
4885 (dwarf2_psymtab::expand_psymtab): Assert !readin.
4886
4887 2020-04-14 Tom de Vries <tdevries@suse.de>
4888
4889 PR symtab/25720
4890 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
4891 with NULL symbol_matcher and lookup_name.
4892 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
4893 and lookup_name.
4894 * dwarf2/read.c (dw2_expand_symtabs_matching)
4895 (dw2_debug_names_expand_symtabs_matching): Same.
4896 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
4897 Make lookup_name a pointer. Update comment.
4898 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
4899 lookup_name being a pointer.
4900 * symfile.c (expand_symtabs_matching): Same.
4901 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
4902 * linespec.c (iterate_over_all_matching_symtabs): Same.
4903
4904 2020-04-13 Tom Tromey <tom@tromey.com>
4905
4906 * run-on-main-thread.c: Update include.
4907 * unittests/main-thread-selftests.c: Update include.
4908 * tui/tui-win.c: Update include.
4909 * tui/tui-io.c: Update include.
4910 * tui/tui-interp.c: Update include.
4911 * tui/tui-hooks.c: Update include.
4912 * top.h: Update include.
4913 * top.c: Update include.
4914 * ser-base.c: Update include.
4915 * remote.c: Update include.
4916 * remote-notif.c: Update include.
4917 * remote-fileio.c: Update include.
4918 * record-full.c: Update include.
4919 * record-btrace.c: Update include.
4920 * python/python.c: Update include.
4921 * posix-hdep.c: Update include.
4922 * mingw-hdep.c: Update include.
4923 * mi/mi-main.c: Update include.
4924 * mi/mi-interp.c: Update include.
4925 * main.c: Update include.
4926 * linux-nat.c: Update include.
4927 * interps.c: Update include.
4928 * infrun.c: Update include.
4929 * inf-loop.c: Update include.
4930 * event-top.c: Update include.
4931 * event-loop.c: Move to ../gdbsupport/.
4932 * event-loop.h: Move to ../gdbsupport/.
4933 * async-event.h: Update include.
4934 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
4935
4936 2020-04-13 Tom Tromey <tom@tromey.com>
4937
4938 * tui/tui-win.c: Include async-event.h.
4939 * remote.c: Include async-event.h.
4940 * remote-notif.c: Include async-event.h.
4941 * record-full.c: Include async-event.h.
4942 * record-btrace.c: Include async-event.h.
4943 * infrun.c: Include async-event.h.
4944 * event-top.c: Include async-event.h.
4945 * event-loop.h: Move some declarations to async-event.h.
4946 * event-loop.c: Don't include ser-event.h or top.h. Move some
4947 code to async-event.c.
4948 * async-event.h: New file.
4949 * async-event.c: New file.
4950 * Makefile.in (COMMON_SFILES): Add async-event.c.
4951 (HFILES_NO_SRCDIR): Add async-event.h.
4952
4953 2020-04-13 Tom Tromey <tom@tromey.com>
4954
4955 * utils.c (flush_streams): New function.
4956 * event-loop.c (gdb_wait_for_event): Call flush_streams.
4957
4958 2020-04-13 Tom Tromey <tom@tromey.com>
4959
4960 * event-loop.c (handle_file_event): Use warning, not
4961 printf_unfiltered.
4962
4963 2020-04-13 Tom Tromey <tom@tromey.com>
4964
4965 * event-loop.c: Include <chrono>.
4966
4967 2020-04-13 Tom Tromey <tom@tromey.com>
4968
4969 * gdb_select.h: Move to ../gdbsupport/.
4970 * event-loop.c: Update include path.
4971 * top.c: Update include path.
4972 * ser-base.c: Update include path.
4973 * ui-file.c: Update include path.
4974 * ser-tcp.c: Update include path.
4975 * guile/scm-ports.c: Update include path.
4976 * posix-hdep.c: Update include path.
4977 * ser-unix.c: Update include path.
4978 * gdb_usleep.c: Update include path.
4979 * mingw-hdep.c: Update include path.
4980 * inflow.c: Update include path.
4981 * infrun.c: Update include path.
4982 * event-top.c: Update include path.
4983
4984 2020-04-13 Tom Tromey <tom@tromey.com>
4985
4986 * configure: Rebuild.
4987 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
4988
4989 2020-04-13 Tom Tromey <tom@tromey.com>
4990
4991 * event-loop.h (start_event_loop): Don't declare.
4992 * event-loop.c (start_event_loop): Move...
4993 * main.c (start_event_loop): ...here. Now static.
4994
4995 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
4996
4997 * MAINTAINERS: Update my email address.
4998
4999 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5000
5001 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
5002 IP_ALL.
5003
5004 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5005
5006 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
5007 (nbsd_nat_target::info_proc): Add do_cmdline.
5008
5009 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5010
5011 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
5012 (nbsd_nat_target::info_proc): Add do_cwd.
5013
5014 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5015
5016 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
5017
5018 2020-04-11 Kamil Rytarowski <n54@gmx.com>
5019
5020 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
5021 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
5022 (nbsd_nat_target::info_proc): New functions.
5023 * nbsd-nat.c (kinfo_get_vmmap): New function.
5024 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
5025 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
5026 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
5027 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
5028 functions.
5029 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
5030 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
5031 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
5032 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
5033 (KINFO_VME_FLAG_GROWS_DOWN): New.
5034
5035 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
5036
5037 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
5038 bit shift.
5039
5040 2020-04-10 Tom Tromey <tromey@adacore.com>
5041
5042 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
5043
5044 2020-04-10 Tom Tromey <tromey@adacore.com>
5045
5046 * symtab.c (get_symbol_address, get_msymbol_address): Skip
5047 separate debug files.
5048
5049 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
5050
5051 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5052 Move to...
5053 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5054 ... here.
5055 * windows-nat.c (windows_nat_target::get_windows_debug_event):
5056 Check for STATUS_WX86_BREAKPOINT.
5057 (windows_nat_target::wait): Same.
5058
5059 2020-04-10 Tom de Vries <tdevries@suse.de>
5060
5061 PR cli/25808
5062 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
5063
5064 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5065
5066 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
5067 (Write After Approval): Remove Tom de Vries.
5068
5069 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
5070
5071 revert partially:
5072 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5073
5074 * buildsym.c (record_line): Fix undefined behavior and preserve
5075 lines at eof.
5076
5077 2020-04-09 Kamil Rytarowski <n54@gmx.com>
5078
5079 * auxv.h (svr4_auxv_parse): New.
5080 * auxv.c (default_auxv_parse): Split into default_auxv_parse
5081 and generic_auxv_parse.
5082 (svr4_auxv_parse): Add.
5083 * obsd-tdep.c: Include "auxv.h".
5084 (obsd_auxv_parse): Remove.
5085 (obsd_init_abi): Remove comment.
5086 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
5087 from `obsd_auxv_parse' to `svr4_auxv_parse'.
5088 * nbsd-tdep.c: Include "auxv.h".
5089 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
5090
5091 2020-04-08 Tom Tromey <tromey@adacore.com>
5092
5093 * nat/windows-nat.h (last_wait_event): Don't declare.
5094 (wait_for_debug_event): Update comment.
5095 * nat/windows-nat.c (last_wait_event): Now static.
5096
5097 2020-04-08 Tom Tromey <tromey@adacore.com>
5098
5099 * windows-nat.c (wait_for_debug_event): Move to
5100 nat/windows-nat.c.
5101 * nat/windows-nat.h (wait_for_debug_event): Declare.
5102 * nat/windows-nat.c (wait_for_debug_event): Move from
5103 windows-nat.c. No longer static.
5104
5105 2020-04-08 Tom Tromey <tromey@adacore.com>
5106
5107 * windows-nat.c (get_windows_debug_event): Use
5108 fetch_pending_stop.
5109 * nat/windows-nat.h (fetch_pending_stop): Declare.
5110 * nat/windows-nat.c (fetch_pending_stop): New function.
5111
5112 2020-04-08 Tom Tromey <tromey@adacore.com>
5113
5114 * windows-nat.c (windows_continue): Use matching_pending_stop and
5115 continue_last_debug_event.
5116 * nat/windows-nat.h (matching_pending_stop)
5117 (continue_last_debug_event): Declare.
5118 * nat/windows-nat.c (DEBUG_EVENTS): New define.
5119 (matching_pending_stop, continue_last_debug_event): New
5120 functions.
5121
5122 2020-04-08 Tom Tromey <tromey@adacore.com>
5123
5124 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
5125 (handle_exception_result): Move to nat/windows-nat.h.
5126 (DEBUG_EXCEPTION_SIMPLE): Remove.
5127 (windows_nat::handle_ms_vc_exception): New function.
5128 (handle_exception): Move to nat/windows-nat.c.
5129 (get_windows_debug_event): Update.
5130 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
5131 nat/windows-nat.c.
5132 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
5133 (handle_exception_result): Move from windows-nat.c.
5134 (handle_exception): Declare.
5135 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
5136 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
5137 windows-nat.c.
5138
5139 2020-04-08 Tom Tromey <tromey@adacore.com>
5140
5141 * windows-nat.c (exception_count, event_count): Remove.
5142 (handle_exception, get_windows_debug_event)
5143 (do_initial_windows_stuff): Update.
5144
5145 2020-04-08 Tom Tromey <tromey@adacore.com>
5146
5147 * windows-nat.c (windows_nat::handle_load_dll)
5148 (windows_nat::handle_unload_dll): Rename. No longer static.
5149 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
5150 Declare.
5151
5152 2020-04-08 Tom Tromey <tromey@adacore.com>
5153
5154 * complaints.h (stop_whining): Declare at top-level.
5155 (complaint): Don't declare stop_whining.
5156
5157 2020-04-08 Tom Tromey <tromey@adacore.com>
5158
5159 * windows-nat.c (windows_nat::handle_output_debug_string):
5160 Rename. No longer static.
5161 * nat/windows-nat.h (handle_output_debug_string): Declare.
5162
5163 2020-04-08 Tom Tromey <tromey@adacore.com>
5164
5165 * windows-nat.c (current_process_handle, current_process_id)
5166 (main_thread_id, last_sig, current_event, last_wait_event)
5167 (current_windows_thread, desired_stop_thread_id, pending_stops)
5168 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
5169 (display_selectors, fake_create_process)
5170 (get_windows_debug_event): Update.
5171 * nat/windows-nat.h (current_process_handle, current_process_id)
5172 (main_thread_id, last_sig, current_event, last_wait_event)
5173 (current_windows_thread, desired_stop_thread_id, pending_stops)
5174 (struct pending_stop, siginfo_er): Move from windows-nat.c.
5175 * nat/windows-nat.c (current_process_handle, current_process_id)
5176 (main_thread_id, last_sig, current_event, last_wait_event)
5177 (current_windows_thread, desired_stop_thread_id, pending_stops)
5178 (siginfo_er): New globals. Move from windows-nat.c.
5179
5180 2020-04-08 Tom Tromey <tromey@adacore.com>
5181
5182 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
5183 (handle_load_dll): Update.
5184 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
5185
5186 2020-04-08 Tom Tromey <tromey@adacore.com>
5187
5188 * windows-nat.c (enum thread_disposition_type): Move to
5189 nat/windows-nat.h.
5190 (windows_nat::thread_rec): Rename from thread_rec. No longer
5191 static.
5192 (windows_add_thread, windows_nat_target::fetch_registers)
5193 (windows_nat_target::store_registers, handle_exception)
5194 (windows_nat_target::resume, get_windows_debug_event)
5195 (windows_nat_target::get_tib_address)
5196 (windows_nat_target::thread_name)
5197 (windows_nat_target::thread_alive): Update.
5198 * nat/windows-nat.h (enum thread_disposition_type): Move from
5199 windows-nat.c.
5200 (thread_rec): Declare.
5201
5202 2020-04-08 Tom Tromey <tromey@adacore.com>
5203
5204 * windows-nat.c: Add "using namespace".
5205 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
5206 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
5207
5208 2020-04-08 Tom Tromey <tromey@adacore.com>
5209
5210 * nat/windows-nat.h (struct windows_thread_info): Declare
5211 destructor.
5212 * nat/windows-nat.c (~windows_thread_info): New.
5213
5214 2020-04-08 Tom Tromey <tromey@adacore.com>
5215
5216 PR gdb/22992
5217 * windows-nat.c (current_event): Update comment.
5218 (last_wait_event, desired_stop_thread_id): New globals.
5219 (struct pending_stop): New.
5220 (pending_stops): New global.
5221 (windows_nat_target) <stopped_by_sw_breakpoint>
5222 <supports_stopped_by_sw_breakpoint>: New methods.
5223 (windows_fetch_one_register): Add assertions. Adjust PC.
5224 (windows_continue): Handle pending stops. Suspend other threads
5225 when stepping. Use last_wait_event
5226 (wait_for_debug_event): New function.
5227 (get_windows_debug_event): Use wait_for_debug_event. Handle
5228 pending stops. Queue spurious stops.
5229 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
5230 (windows_nat_target::kill): Use wait_for_debug_event.
5231 * nat/windows-nat.h (struct windows_thread_info)
5232 <stopped_at_software_breakpoint>: New field.
5233 * nat/windows-nat.c (windows_thread_info::resume): Clear
5234 stopped_at_software_breakpoint.
5235
5236 2020-04-08 Tom Tromey <tromey@adacore.com>
5237
5238 * windows-nat.c (enum thread_disposition_type): New.
5239 (thread_rec): Replace "get_context" parameter with "disposition";
5240 change type.
5241 (windows_add_thread, windows_nat_target::fetch_registers)
5242 (windows_nat_target::store_registers, handle_exception)
5243 (windows_nat_target::resume, get_windows_debug_event)
5244 (windows_nat_target::get_tib_address)
5245 (windows_nat_target::thread_name)
5246 (windows_nat_target::thread_alive): Update.
5247
5248 2020-04-08 Tom Tromey <tromey@adacore.com>
5249
5250 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
5251 (windows_continue): Use windows_continue::resume.
5252 * nat/windows-nat.h (struct windows_thread_info) <suspend,
5253 resume>: Declare new methods.
5254 * nat/windows-nat.c: New file.
5255 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
5256
5257 2020-04-08 Tom Tromey <tromey@adacore.com>
5258
5259 * windows-nat.c (windows_add_thread, windows_delete_thread)
5260 (windows_nat_target::fetch_registers)
5261 (windows_nat_target::store_registers, fake_create_process)
5262 (windows_nat_target::resume, windows_nat_target::resume)
5263 (get_windows_debug_event, windows_nat_target::wait)
5264 (windows_nat_target::pid_to_str)
5265 (windows_nat_target::get_tib_address)
5266 (windows_nat_target::get_ada_task_ptid)
5267 (windows_nat_target::thread_name)
5268 (windows_nat_target::thread_alive): Use lwp, not tid.
5269
5270 2020-04-08 Tom Tromey <tromey@adacore.com>
5271
5272 * windows-nat.c (handle_exception)
5273 (windows_nat_target::thread_name): Update.
5274 * nat/windows-nat.h (windows_thread_info): Remove destructor.
5275 <name>: Now unique_xmalloc_ptr.
5276
5277 2020-04-08 Tom Tromey <tromey@adacore.com>
5278
5279 * windows-nat.c (thread_rec)
5280 (windows_nat_target::fetch_registers): Update.
5281 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
5282 Update comment.
5283 <debug_registers_changed, reload_context>: Now bool.
5284
5285 2020-04-08 Tom Tromey <tromey@adacore.com>
5286
5287 * windows-nat.c (windows_add_thread): Use new.
5288 (windows_init_thread_list, windows_delete_thread): Use delete.
5289 (get_windows_debug_event): Update.
5290 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
5291 destructor, and initializers.
5292
5293 2020-04-08 Tom Tromey <tromey@adacore.com>
5294
5295 * windows-nat.c (struct windows_thread_info): Remove.
5296 * nat/windows-nat.h: New file.
5297
5298 2020-04-08 Tom Tromey <tromey@adacore.com>
5299
5300 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
5301 (thread_rec, windows_add_thread, windows_delete_thread)
5302 (windows_continue): Update.
5303
5304 2020-04-08 Tom Tromey <tromey@adacore.com>
5305
5306 * windows-nat.c (struct windows_thread_info): Remove typedef.
5307 (thread_head): Remove.
5308 (thread_list): New global.
5309 (thread_rec, windows_add_thread, windows_init_thread_list)
5310 (windows_delete_thread, windows_continue): Update.
5311
5312 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
5313
5314 * windows-tdep.h (windows_init_abi): Add comment.
5315 (cygwin_init_abi): New declaration.
5316 * windows-tdep.c: Split signal enumeration in two, one for
5317 Windows and one for Cygwin.
5318 (windows_gdb_signal_to_target): Only deal with signal of the
5319 Windows OS ABI.
5320 (cygwin_gdb_signal_to_target): New function.
5321 (windows_init_abi): Rename to windows_init_abi_common, don't set
5322 gdb_signal_to_target gdbarch method. Add new new function with
5323 this name.
5324 (cygwin_init_abi): New function.
5325 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
5326 comment. Don't call windows_init_abi.
5327 (amd64_windows_init_abi): Add comment, call windows_init_abi.
5328 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
5329 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
5330 i386_windows_init_abi_common, don't call windows_init_abi. Add
5331 a new function of this name.
5332 (i386_cygwin_init_abi): New function.
5333 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
5334 OS ABI Cygwin.
5335
5336 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
5337
5338 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
5339 parameter.c.
5340 (dwarf2_read_gdb_index): Update.
5341
5342 2020-04-07 Kamil Rytarowski <n54@gmx.com>
5343
5344 * nbsd-tdep.c: Include "objfiles.h".
5345 (nbsd_skip_solib_resolver): New.
5346 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
5347
5348 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5349
5350 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
5351 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
5352 with DW_LLE_base_addressx are being emitted in DWARFv5.
5353 Add the newly added kind DW_LOC_OFFSET_PAIR also.
5354 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
5355 unsigned integer.
5356
5357 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5358
5359 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
5360 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
5361 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
5362 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
5363 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
5364 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
5365 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
5366
5367
5368 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5369
5370 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
5371 (read_loclist_index): New function definition.
5372 (lookup_loclist_base): New function definition.
5373 (read_loclist_header): New function definition.
5374 (dwarf2_cu): Add loclist_base and loclist_header field.
5375 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
5376 (read_full_die_1): Read the value of DW_AT_loclists_base.
5377 (read_attribute_reprocess): Handle DW_FORM_loclistx.
5378 (read_attribute_value): Handle DW_FORM_loclistx.
5379 (skip_one_die): Handle DW_FORM_loclistx.
5380 (loclist_header): New structure declaration.
5381 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
5382
5383 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5384
5385 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
5386 constructor. Remove `addr` parameter from other constructor and
5387 add `per_cu` parameter.
5388 * dwarf2/read.c (create_partial_symtab): Update.
5389
5390 2020-04-07 Tom de Vries <tdevries@suse.de>
5391
5392 PR symtab/25796
5393 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
5394 (partial_die_info::fixup): Inherit has_const_value.
5395
5396 2020-04-07 Tom de Vries <tdevries@suse.de>
5397
5398 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
5399 symbols without address.
5400
5401 2020-04-06 Kamil Rytarowski <n54@gmx.com>
5402
5403 * nbsd-nat.h (struct thread_info): Add forward declaration.
5404 (nbsd_nat_target::thread_alive): Add.
5405 (nbsd_nat_target::thread_name): Likewise.
5406 (nbsd_nat_target::update_thread_list): Likewise.
5407 (update_thread_list::post_attach): Likewise.
5408 (post_attach::pid_to_str): Likewise.
5409 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
5410 (nbsd_thread_lister): Add.
5411 (nbsd_nat_target::thread_alive): Likewise.
5412 (nbsd_nat_target::thread_name): Likewise.
5413 (nbsd_add_threads): Likewise.
5414 (update_thread_list::post_attach): Likewise.
5415 (nbsd_nat_target::update_thread_list): Likewise.
5416 (post_attach::pid_to_str): Likewise.
5417
5418 2020-04-06 Tom Tromey <tromey@adacore.com>
5419
5420 * ada-valprint.c (print_variant_part): Extract the variant field.
5421 (print_field_values): Use the field as the outer value when
5422 recursing.
5423
5424 2020-04-06 Tom Tromey <tromey@adacore.com>
5425
5426 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
5427 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
5428 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
5429 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
5430 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
5431
5432 2020-04-06 Tom Tromey <tromey@adacore.com>
5433
5434 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
5435 TYPE_CODE_ERROR.
5436
5437 2020-04-06 Kamil Rytarowski <n54@gmx.com>
5438
5439 * nbsd-tdep.c: Include "gdbarch.h".
5440 Define enum with NetBSD signal numbers.
5441 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
5442 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
5443 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5444 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
5445 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
5446 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
5447 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
5448 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
5449 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
5450 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
5451 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
5452 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
5453
5454 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
5455
5456 PR gdb/25325
5457 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
5458
5459 2020-04-03 Tom Tromey <tromey@adacore.com>
5460
5461 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
5462 Read constant block.
5463
5464 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
5465
5466 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
5467 (gdb_bfd_get_full_section_contents): New declaration.
5468 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
5469 * windows-tdep.c (is_linked_with_cygwin_dll): Use
5470 gdb_bfd_get_full_section_contents.
5471
5472 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
5473
5474 * exec.c (build_section_table): Replace internal_error with
5475 gdb_assert.
5476 (section_table_xfer_memory_partial): Likewise.
5477 * mdebugread.c (parse_partial_symbols): Likewise.
5478 * psymtab.c (lookup_partial_symbol): Likewise.
5479 * utils.c (wrap_here): Likewise.
5480
5481 2020-04-02 Tom Tromey <tromey@adacore.com>
5482
5483 * f-lang.c (build_fortran_types): Use arch_type to initialize
5484 builtin_complex_s32 in the TYPE_CODE_ERROR case.
5485
5486 2020-04-02 Tom Tromey <tromey@adacore.com>
5487
5488 * dwarf2/read.c (partial_die_info::read): Do not create a vector
5489 of attributes.
5490
5491 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
5492 Bernd Edlinger <bernd.edlinger@hotmail.de>
5493 Tom Tromey <tromey@adacore.com>
5494
5495 * buildsym.c (buildsym_compunit::record_line): Remove
5496 deduplication code.
5497
5498 2020-04-02 Tom de Vries <tdevries@suse.de>
5499
5500 PR ada/24671
5501 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
5502
5503 2020-04-02 Tom de Vries <tdevries@suse.de>
5504
5505 * dwarf2/read.c (dwarf2_gdb_index_functions,
5506 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
5507 NULL.
5508 * psymtab.c (psym_lookup_global_symbol_language): New function.
5509 (psym_functions): Init psym_lookup_global_symbol_language with
5510 psym_lookup_global_symbol_language.
5511 * symfile-debug.c (debug_sym_quick_functions): Init
5512 lookup_global_symbol_language with NULL.
5513 * symfile.c (set_initial_language): Remove fixme comment.
5514 * symfile.h (struct quick_symbol_functions): Add
5515 lookup_global_symbol_language.
5516 * symtab.c (find_quick_global_symbol_language): New function.
5517 (find_main_name): Use find_quick_global_symbol_language.
5518
5519 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5520
5521 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
5522
5523 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5524
5525 * buildsym.c (record_line): Fix undefined behavior and preserve
5526 lines at eof.
5527
5528 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5529
5530 * buildsym.c (record_line): Fix the resizing condition.
5531
5532 2020-04-01 Tom Tromey <tom@tromey.com>
5533
5534 * value.h (value_literal_complex): Add comment.
5535 * valops.c (value_literal_complex): Refer to value.h.
5536
5537 2020-04-01 Tom Tromey <tom@tromey.com>
5538
5539 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
5540 (scalar_type): New rule, from typebase.
5541 (typebase): Use scalar_type. Recognize complex types.
5542 (field_name): Handle FLOAT_KEYWORD.
5543 (ident_tokens): Add _Complex and __complex__.
5544
5545 2020-04-01 Tom Tromey <tom@tromey.com>
5546
5547 PR exp/25299:
5548 * valarith.c (promotion_type, complex_binop): New functions.
5549 (scalar_binop): Handle complex numbers. Use promotion_type.
5550 (value_pos, value_neg, value_complement): Handle complex numbers.
5551
5552 2020-04-01 Tom Tromey <tom@tromey.com>
5553
5554 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
5555 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
5556 (parse_number): Handle complex numbers.
5557
5558 2020-04-01 Tom Tromey <tom@tromey.com>
5559
5560 * c-valprint.c (c_decorations): Change complex suffix to "i".
5561
5562 2020-04-01 Tom Tromey <tom@tromey.com>
5563
5564 * valprint.c (generic_value_print_complex): Use accessors.
5565 * value.h (value_real_part, value_imaginary_part): Declare.
5566 * valops.c (value_real_part, value_imaginary_part): New
5567 functions.
5568 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
5569
5570 2020-04-01 Tom Tromey <tom@tromey.com>
5571
5572 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
5573 (read_range_type): Update.
5574 * mdebugread.c (basic_type): Update.
5575 * go-lang.c (build_go_types): Use init_complex_type.
5576 * gdbtypes.h (struct main_type) <complex_type>: New member.
5577 (init_complex_type): Update.
5578 (arch_complex_type): Don't declare.
5579 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
5580 Make name if none given. Use alloc_type_copy. Look for cached
5581 complex type.
5582 (arch_complex_type): Remove.
5583 (gdbtypes_post_init): Use init_complex_type.
5584 * f-lang.c (build_fortran_types): Use init_complex_type.
5585 * dwarf2/read.c (read_base_type): Update.
5586 * d-lang.c (build_d_types): Use init_complex_type.
5587 * ctfread.c (read_base_type): Update.
5588
5589 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5590
5591 * infrun.c (stop_all_threads): Update assertion, plus when
5592 stopping threads, take into account that we might be trying
5593 to stop an all-stop target.
5594 (stop_waiting): Call 'stop_all_threads' if there exists a
5595 non-stop target.
5596
5597 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5598
5599 * target.h (exists_non_stop_target): New function declaration.
5600 * target.c (exists_non_stop_target): New function.
5601
5602 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
5603
5604 PR gdb/24789
5605 * eval.c (is_integral_or_integral_reference): New function.
5606 (evaluate_subexp_standard): Allow integer references in
5607 pointer arithmetic.
5608
5609 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5610
5611 * remote.c (remote_target::remote_parse_stop_reply): Remove the
5612 check for no ptid in the stop reply when the target is non-stop.
5613
5614 2020-04-01 Tom Tromey <tromey@adacore.com>
5615
5616 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
5617 "name" parameter to rvalue reference. Initialize m_name_holder.
5618 <lookup_name_info>: New overloads.
5619 <name>: Return gdb::string_view.
5620 <c_str>: New method.
5621 <make_ignore_params>: Update.
5622 <search_name_hash>: Update.
5623 <language_lookup_name>: Return const char *.
5624 <m_name>: Change type.
5625 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
5626 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
5627 (lookup_name_info::match_any): Update.
5628 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
5629 Update.
5630 * minsyms.c (linkage_name_str): Update.
5631 * language.c (default_symbol_name_matcher): Update.
5632 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
5633 Update.
5634 * ada-lang.c (ada_fold_name): Change parameter to string_view.
5635 (ada_lookup_name_info::ada_lookup_name_info): Update.
5636 (literal_symbol_name_matcher): Update.
5637
5638 2020-04-01 Tom Tromey <tromey@adacore.com>
5639
5640 * psymtab.c (psymtab_search_name): Remove function.
5641 (psym_lookup_symbol): Create search name and lookup name here.
5642 (lookup_partial_symbol): Remove "name" parameter; add
5643 lookup_name.
5644 (psym_expand_symtabs_for_function): Update.
5645
5646 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
5647
5648 PR tui/25597:
5649 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
5650
5651 2020-03-31 Tom Tromey <tromey@adacore.com>
5652
5653 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
5654 memcpy.
5655
5656 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
5657
5658 * features/riscv/32bit-csr.xml: Regenerated.
5659 * features/riscv/64bit-csr.xml: Regenerated.
5660
5661 2020-03-30 Tom Tromey <tromey@adacore.com>
5662
5663 * ada-valprint.c (print_variant_part): Update.
5664 * ada-lang.h (ada_which_variant_applies): Update.
5665 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
5666 outer_valaddr parameters; replace with "outer" value parameter.
5667 (to_fixed_variant_branch_type): Update.
5668
5669 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5670
5671 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
5672 <list>. Remove inclusion of observable.h.
5673 (PPC_DEBUG_CURRENT_VERSION): Move up define.
5674 (struct arch_lwp_info): New struct.
5675 (class ppc_linux_dreg_interface): New class.
5676 (struct ppc_linux_process_info): New struct.
5677 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
5678 <low_new_clone, low_forget_process, low_prepare_to_resume>
5679 <copy_thread_dreg_state, mark_thread_stale>
5680 <mark_debug_registers_changed, register_hw_breakpoint>
5681 <clear_hw_breakpoint, register_wp, clear_wp>
5682 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
5683 <num_memory_accesses, get_trigger_type>
5684 <create_watchpoint_request, hwdebug_point_cmp>
5685 <init_arch_lwp_info, get_arch_lwp_info>
5686 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
5687 methods.
5688 <struct ptid_hash>: New inner struct.
5689 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
5690 members.
5691 (saved_dabr_value, hwdebug_info, max_slots_number)
5692 (struct hw_break_tuple, struct thread_points, ppc_threads)
5693 (have_ptrace_hwdebug_interface)
5694 (hwdebug_find_thread_points_by_tid)
5695 (hwdebug_insert_point, hwdebug_remove_point): Remove.
5696 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
5697 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
5698 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
5699 use m_dreg_interface.
5700 (hwdebug_point_cmp): Change to...
5701 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
5702 reference arguments instead of pointers.
5703 (ppc_linux_nat_target::ranged_break_num_registers): Use
5704 m_dreg_interface.
5705 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
5706 m_dreg_interface. Call register_hw_breakpoint.
5707 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
5708 m_dreg_interface. Call clear_hw_breakpoint.
5709 (get_trigger_type): Change to...
5710 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
5711 comment.
5712 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
5713 use m_dreg_interface. Call register_hw_breakpoint.
5714 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
5715 use m_dreg_interface. Call clear_hw_breakpoint.
5716 (can_use_watchpoint_cond_accel): Change to...
5717 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
5718 method. Update comment, use m_dreg_interface and
5719 m_process_info.
5720 (calculate_dvc): Change to...
5721 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
5722 m_dreg_interface.
5723 (num_memory_accesses): Change to...
5724 (ppc_linux_nat_target::num_memory_accesses): ...this method.
5725 (check_condition): Change to...
5726 (ppc_linux_nat_target::check_condition): ...this method.
5727 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
5728 comment, use m_dreg_interface.
5729 (create_watchpoint_request): Change to...
5730 (ppc_linux_nat_target::create_watchpoint_request): ...this
5731 method. Use m_dreg_interface.
5732 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
5733 m_dreg_interface. Call register_hw_breakpoint or register_wp.
5734 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
5735 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
5736 (ppc_linux_nat_target::low_forget_process)
5737 (ppc_linux_nat_target::low_new_fork)
5738 (ppc_linux_nat_target::low_new_clone)
5739 (ppc_linux_nat_target::low_delete_thread)
5740 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
5741 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
5742 only call mark_thread_stale.
5743 (ppc_linux_thread_exit): Remove.
5744 (ppc_linux_nat_target::stopped_data_address): Change to...
5745 (ppc_linux_nat_target::low_stopped_data_address): This. Add
5746 comment, use m_dreg_interface and m_thread_hw_breakpoints.
5747 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
5748 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
5749 comment. Call low_stopped_data_address.
5750 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
5751 m_dreg_interface.
5752 (ppc_linux_nat_target::masked_watch_num_registers): Use
5753 m_dreg_interface.
5754 (ppc_linux_nat_target::copy_thread_dreg_state)
5755 (ppc_linux_nat_target::mark_thread_stale)
5756 (ppc_linux_nat_target::mark_debug_registers_changed)
5757 (ppc_linux_nat_target::register_hw_breakpoint)
5758 (ppc_linux_nat_target::clear_hw_breakpoint)
5759 (ppc_linux_nat_target::register_wp)
5760 (ppc_linux_nat_target::clear_wp)
5761 (ppc_linux_nat_target::init_arch_lwp_info)
5762 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
5763 (_initialize_ppc_linux_nat): Remove observer callback.
5764
5765 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5766
5767 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
5768 (ppc_linux_nat_target::auxv_parse)
5769 (ppc_linux_nat_target::read_description)
5770 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
5771 Move up.
5772
5773 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5774
5775 * linux-nat.h (low_new_clone): New method.
5776 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
5777
5778 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
5779
5780 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
5781 (dbx_expand_psymtab): ... this.
5782 (start_psymtab): Update.
5783 * mdebugread.c (psymtab_to_symtab_1): Rename to...
5784 (mdebug_expand_psymtab): ... this.
5785 (parse_partial_symbols): Update.
5786 (new_psymtab): Update.
5787 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
5788 (xcoff_expand_psymtab): ... this.
5789 (xcoff_start_psymtab): Update.
5790
5791 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
5792
5793 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
5794 <expand_dependencies>: ... this.
5795 * psymtab.c (partial_symtab::read_dependencies): Rename to...
5796 (partial_symtab::expand_dependencies): ... this.
5797 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
5798 Update.
5799 (dwarf2_psymtab::expand_psymtab): Update.
5800 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
5801 * mdebugread.c (psymtab_to_symtab_1): Update.
5802 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
5803
5804 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
5805
5806 * psympriv.h (discard_psymtab): Remove.
5807 * dbxread.c (dbx_end_psymtab): Update.
5808 * xcoffread.c (xcoff_end_psymtab): Update.
5809
5810 2020-03-28 Tom Tromey <tom@tromey.com>
5811
5812 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
5813 comment.
5814
5815 2020-03-28 Tom Tromey <tom@tromey.com>
5816
5817 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
5818
5819 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
5820
5821 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
5822
5823 2020-03-26 John Baldwin <jhb@FreeBSD.org>
5824
5825 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
5826
5827 2020-03-26 Tom Tromey <tom@tromey.com>
5828
5829 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
5830 (mark_common_block_symbol_computed, read_tag_string_type)
5831 (attr_to_dynamic_prop, read_subrange_type): Update.
5832 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
5833 to be methods on struct attribute.
5834 (skip_one_die, process_imported_unit_die, read_namespace_alias)
5835 (read_call_site_scope, partial_die_info::read)
5836 (partial_die_info::read, lookup_die_type, follow_die_ref):
5837 Update.
5838 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
5839 from dwarf2_get_ref_die_offset.
5840 (attribute::constant_value): New method, from
5841 dwarf2_get_attr_constant_value.
5842 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
5843 Declare method.
5844 <constant_value>: New method.
5845
5846 2020-03-26 Tom Tromey <tom@tromey.com>
5847
5848 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
5849 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
5850 (dwarf_type_encoding_name): Move to stringify.c.
5851 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
5852 * dwarf2/stringify.c: New file.
5853 * dwarf2/stringify.h: New file.
5854
5855 2020-03-26 Tom Tromey <tom@tromey.com>
5856
5857 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
5858 Rewrite.
5859
5860 2020-03-26 Tom Tromey <tom@tromey.com>
5861
5862 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
5863 methods.
5864 * dwarf2/read.c (lookup_addr_base): Move to die.h.
5865 (lookup_ranges_base): Likewise.
5866 (read_cutu_die_from_dwo, read_full_die_1): Update.
5867
5868 2020-03-26 Tom Tromey <tom@tromey.com>
5869
5870 * dwarf2/read.c (read_import_statement, read_file_scope)
5871 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
5872 (read_lexical_block_scope, read_call_site_scope)
5873 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
5874 (handle_struct_member_die, process_structure_scope)
5875 (update_enumeration_type_from_children)
5876 (process_enumeration_scope, read_array_type, read_common_block)
5877 (read_namespace, read_module, read_subroutine_type): Update.
5878 (sibling_die): Remove.
5879
5880 2020-03-26 Tom Tromey <tom@tromey.com>
5881
5882 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
5883 (build_type_psymtabs_reader, read_structure_type)
5884 (read_enumeration_type, read_full_die_1): Update.
5885 (dwarf2_attr_no_follow): Move to die.h.
5886 * dwarf2/die.h (struct die_info) <attr>: New method.
5887
5888 2020-03-26 Tom Tromey <tom@tromey.com>
5889
5890 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
5891 <base_address>: Now an optional.
5892 (dwarf2_find_base_address, dwarf2_rnglists_process)
5893 (dwarf2_ranges_process, fill_in_loclist_baton)
5894 (dwarf2_symbol_mark_computed): Update.
5895
5896 2020-03-26 Tom Tromey <tom@tromey.com>
5897
5898 * dwarf2/read.c (struct die_info): Move to die.h.
5899 * dwarf2/die.h: New file.
5900
5901 2020-03-26 Tom Tromey <tom@tromey.com>
5902
5903 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
5904 * dwarf2/read.c
5905 (dwarf2_statement_list_fits_in_line_number_section_complaint):
5906 Move to line-header.c.
5907 (read_checked_initial_length_and_offset, read_formatted_entries):
5908 Likewise.
5909 (dwarf_decode_line_header): Split into two.
5910 * dwarf2/line-header.c
5911 (dwarf2_statement_list_fits_in_line_number_section_complaint):
5912 Move from read.c.
5913 (read_checked_initial_length_and_offset, read_formatted_entries):
5914 Likewise.
5915 (dwarf_decode_line_header): New function, split from read.c.
5916
5917 2020-03-26 Tom Tromey <tom@tromey.com>
5918
5919 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
5920 Declare method.
5921 * dwarf2/read.c (read_attribute_value): Update.
5922 (dwarf2_per_objfile::read_line_string): Rename from
5923 read_indirect_line_string.
5924 (read_formatted_entries): Update.
5925
5926 2020-03-26 Tom Tromey <tom@tromey.com>
5927
5928 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
5929 variable.
5930
5931 2020-03-26 Tom Tromey <tom@tromey.com>
5932
5933 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
5934 const.
5935 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
5936 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
5937 parameter const.
5938
5939 2020-03-26 Tom Tromey <tom@tromey.com>
5940
5941 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
5942 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
5943 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
5944 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
5945
5946 2020-03-26 Tom Tromey <tom@tromey.com>
5947
5948 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
5949 file_names_size, file_full_name, file_file_name>: Use const.
5950 <file_name_at, file_names>: Add const overload.
5951 * dwarf2/line-header.c (line_header::file_file_name)
5952 (line_header::file_full_name): Update.
5953
5954 2020-03-26 Tom Tromey <tom@tromey.com>
5955
5956 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
5957 (macro_start_file, consume_improper_spaces)
5958 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
5959 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
5960 (dwarf_decode_macros): Move to macro.c.
5961 * dwarf2/macro.c: New file.
5962 * dwarf2/macro.h: New file.
5963 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
5964
5965 2020-03-26 Tom Tromey <tom@tromey.com>
5966
5967 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
5968 method.
5969 * dwarf2/section.c: New method. From
5970 read_indirect_string_at_offset_from.
5971 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
5972 (read_indirect_string_at_offset_from): Move to section.c.
5973 (read_indirect_string_at_offset): Rewrite.
5974 (read_indirect_line_string_at_offset): Remove.
5975 (read_indirect_string, read_indirect_line_string)
5976 (dwarf_decode_macro_bytes): Update.
5977
5978 2020-03-26 Tom Tromey <tom@tromey.com>
5979
5980 * dwarf2/section.h (struct dwarf2_section_info)
5981 <overload_complaint>: Declare.
5982 (dwarf2_section_buffer_overflow_complaint): Don't declare.
5983 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
5984 Rename from dwarf2_section_buffer_overflow_complaint.
5985 * dwarf2/read.c (skip_one_die, partial_die_info::read)
5986 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
5987
5988 2020-03-26 Tom Tromey <tom@tromey.com>
5989
5990 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
5991 Declare.
5992 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
5993 Move from read.c.
5994 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
5995 to section.c.
5996
5997 2020-03-26 Tom Tromey <tom@tromey.com>
5998
5999 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
6000
6001 2020-03-26 Tom Tromey <tom@tromey.com>
6002
6003 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
6004 "builder".
6005 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
6006 parameter.
6007 (dwarf_decode_macros): Update.
6008
6009 2020-03-26 Tom Tromey <tom@tromey.com>
6010
6011 * dwarf2/read.c (read_attribute_value): Update.
6012 (read_indirect_string_from_dwz): Move to dwz.c; change into
6013 method.
6014 (dwarf_decode_macro_bytes): Update.
6015 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
6016 * dwarf2/dwz.c: New file.
6017 * Makefile.in (COMMON_SFILES): Add dwz.c.
6018
6019 2020-03-26 Tom Tromey <tom@tromey.com>
6020
6021 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
6022 * dwarf2/read.c: Add include.
6023 * dwarf2/index-write.c: Add include.
6024 * dwarf2/index-cache.c: Add include.
6025 * dwarf2/dwz.h: New file.
6026
6027 2020-03-25 Tom Tromey <tom@tromey.com>
6028
6029 * compile/compile-object-load.c (get_out_value_type): Mention
6030 correct symbol name in error message.
6031
6032 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
6033
6034 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6035
6036 2020-03-25 Tom de Vries <tdevries@suse.de>
6037
6038 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
6039 * symmisc.c (dump_symtab_1): Print user and includes fields.
6040 (maintenance_info_symtabs): Same.
6041
6042 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
6043
6044 PR gdb/25534
6045 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
6046 (riscv_regcache_cooked_write): New function.
6047 (riscv_push_dummy_call): Use new function.
6048 (riscv_return_value): Likewise.
6049
6050 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
6051
6052 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
6053 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
6054 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
6055 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
6056 * infrun.c (follow_fork): Likewise.
6057 (follow_fork_inferior): Likewise.
6058 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
6059 * linux-nat.h (class linux_nat_target): Likewise.
6060 * remote.c (class remote_target) <follow_fork>: Likewise.
6061 (remote_target::follow_fork): Likewise.
6062 * target-delegates.c: Re-generate.
6063 * target.c (default_follow_fork): Likewise.
6064 (target_follow_fork): Likewise.
6065 * target.h (struct target_ops) <follow_fork>: Likewise.
6066 (target_follow_fork): Likewise.
6067
6068 2020-03-24 Tom de Vries <tdevries@suse.de>
6069
6070 * psymtab.c (maintenance_info_psymtabs): Print user field.
6071
6072 2020-03-20 Tom Tromey <tromey@adacore.com>
6073
6074 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
6075 const.
6076 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
6077 const.
6078
6079 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
6080
6081 * ptrace.m4: Don't check for ptrace declaration.
6082 * config.in: Re-generate.
6083 * configure: Re-generate.
6084 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
6085 not defined.
6086
6087 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6088
6089 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
6090 `PTRACE_TYPE_RET'.
6091 * i386-bsd-nat.c (gdb_ptrace): Likewise.
6092 * sparc-nat.c (gdb_ptrace): Likewise.
6093 * x86-bsd-nat.c (gdb_ptrace): Likewise.
6094
6095 2020-03-20 Tom Tromey <tromey@adacore.com>
6096
6097 * c-exp.y (lex_one_token): Fix assert.
6098
6099 2020-03-20 Tom Tromey <tromey@adacore.com>
6100
6101 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
6102 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
6103 strncpy call.
6104
6105 2020-03-20 Tom Tromey <tromey@adacore.com>
6106
6107 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
6108
6109 2020-03-20 Tom Tromey <tromey@adacore.com>
6110
6111 * ada-valprint.c (print_variant_part): Remove parameters; switch
6112 to value-based API.
6113 (print_field_values): Likewise.
6114 (ada_val_print_struct_union): Likewise.
6115 (ada_value_print_1): Update.
6116
6117 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6118
6119 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
6120 nbsd_nat_target instead of inf_ptrace_target.
6121 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6122 nbsd_nat_target.
6123
6124 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6125
6126 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
6127 it to the ptrace call.
6128 * (store_registers): Likewise.
6129
6130 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6131
6132 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
6133 it to the ptrace call.
6134 * (store_registers): Likewise.
6135
6136 2020-03-19 Luis Machado <luis.machado@linaro.org>
6137
6138 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
6139 valid, fetch vg value from ptrace.
6140
6141 2020-03-19 Kamil Rytarowski <n54@gmx.com>
6142 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
6143 * inf-ptrace.c: Likewise.
6144 * (gdb_ptrace): Add.
6145 * (inf_ptrace_target::resume): Update.
6146 * (inf_ptrace_target::xfer_partial): Likewise.
6147 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
6148 * (inf_ptrace_peek_poke): Update.
6149
6150 2020-03-19 Kamil Rytarowski <n54@gmx.com>
6151
6152 * x86-bsd-nat.c (gdb_ptrace): New.
6153 * (x86bsd_dr_set): Add new argument `ptid'.
6154 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
6155 x86bsd_dr_set_addr): Update.
6156
6157 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6158
6159 * remote.c (remote_target::process_stop_reply): Handle events for
6160 all threads differently.
6161
6162 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6163
6164 * completer.c (completion_tracker::remove_completion): Define new
6165 function.
6166 * completer.h (completion_tracker::remove_completion): Declare new
6167 function.
6168 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
6169 when adding a C++ function symbol.
6170
6171 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6172
6173 * completer.c (completion_tracker::completion_hash_entry): Define
6174 new class.
6175 (advance_to_filename_complete_word_point): Call
6176 recompute_lowest_common_denominator.
6177 (completion_tracker::completion_tracker): Call discard_completions
6178 to setup the hash table.
6179 (completion_tracker::discard_completions): Allow for being called
6180 from the constructor, pass new equal function, and element deleter
6181 when constructing the hash table. Initialise new class member
6182 variables.
6183 (completion_tracker::maybe_add_completion): Remove use of
6184 m_entries_vec, and store more information into m_entries_hash.
6185 (completion_tracker::recompute_lcd_visitor): New function, most
6186 content taken from...
6187 (completion_tracker::recompute_lowest_common_denominator):
6188 ...here, this now just visits each item in the hash calling the
6189 above visitor.
6190 (completion_tracker::build_completion_result): Remove use of
6191 m_entries_vec, call recompute_lowest_common_denominator.
6192 * completer.h (completion_tracker::have_completions): Remove use
6193 of m_entries_vec.
6194 (completion_tracker::completion_hash_entry): Declare new class.
6195 (completion_tracker::recompute_lowest_common_denominator): Change
6196 function signature.
6197 (completion_tracker::recompute_lcd_visitor): Declare new function.
6198 (completion_tracker::m_entries_vec): Delete.
6199 (completion_tracker::m_entries_hash): Initialize to NULL.
6200 (completion_tracker::m_lowest_common_denominator_valid): New
6201 member variable.
6202 (completion_tracker::m_lowest_common_denominator_max_length): New
6203 member variable.
6204
6205 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6206
6207 * regformats/regdef.h: Put reg in gdb namespace.
6208
6209 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6210
6211 * i386-bsd-nat.c (gdb_ptrace): New.
6212 * (i386bsd_fetch_inferior_registers,
6213 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
6214 * (i386bsd_fetch_inferior_registers,
6215 i386bsd_store_inferior_registers) Use gdb_ptrace.
6216
6217 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6218
6219 * amd64-bsd-nat.c (gdb_ptrace): New.
6220 * (amd64bsd_fetch_inferior_registers,
6221 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
6222 * (amd64bsd_fetch_inferior_registers,
6223 amd64bsd_store_inferior_registers) Use gdb_ptrace.
6224
6225 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6226
6227 * user-regs.c (user_reg::read): Rename to...
6228 (user_reg::xread): ...this.
6229 * (append_user_reg): Rename argument `read' to `xread'.
6230 * (user_reg_add_builtin): Likewise.
6231 * (user_reg_add): Likewise.
6232 * (value_of_user_reg): Likewise.
6233
6234 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6235
6236 * sparc-nat.c (gdb_ptrace): New.
6237 * sparc-nat.c (sparc_fetch_inferior_registers)
6238 (sparc_store_inferior_registers) Remove obsolete comment.
6239 * sparc-nat.c (sparc_fetch_inferior_registers)
6240 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
6241 * sparc-nat.c (sparc_fetch_inferior_registers)
6242 (sparc_store_inferior_registers) Use gdb_ptrace.
6243
6244 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6245
6246 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
6247 it to the ptrace call.
6248 * sh-nbsd-nat.c (store_registers): Likewise.
6249
6250 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6251
6252 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
6253 nbsd_nat_target instead of inf_ptrace_target.
6254 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6255 nbsd_nat_target.
6256
6257 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6258
6259 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
6260
6261 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6262
6263 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
6264 <sys/sysctl.h>.
6265 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
6266
6267 2020-03-17 Tom de Vries <tdevries@suse.de>
6268
6269 PR gdb/23710
6270 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
6271 fields.
6272 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
6273 fields.
6274 (process_imported_unit_die): Skip import of c++ CUs.
6275
6276 2020-03-16 Tom Tromey <tom@tromey.com>
6277
6278 * p-valprint.c (pascal_object_print_value): Initialize
6279 base_value.
6280
6281 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
6282 Shahab Vahedi <shahab@synopsys.com>
6283
6284 * Makefile.in: Add arch/arc.o
6285 * configure.tgt: Likewise.
6286 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
6287 (_initialize_arc_tdep): Don't initialize old target descriptions.
6288 (arc_read_description): New function to cache target descriptions.
6289 * arc-tdep.h (arc_read_description): Add proto type.
6290 * arch/arc.c: New file.
6291 * arch/arc.h: Likewise.
6292 * features/Makefile: Replace old target descriptions with new.
6293 * features/arc-arcompact.c: Remove.
6294 * features/arc-arcompact.xml: Likewise.
6295 * features/arc-v2.c: Likewise
6296 * features/arc-v2.xml: Likewise
6297 * features/arc/aux-arcompact.xml: New file.
6298 * features/arc/aux-v2.xml: Likewise.
6299 * features/arc/core-arcompact.xml: Likewise.
6300 * features/arc/core-v2.xml: Likewise.
6301 * features/arc/aux-arcompact.c: Generate.
6302 * features/arc/aux-v2.c: Likewise.
6303 * features/arc/core-arcompact.c: Likewise.
6304 * features/arc/core-v2.c: Likewise.
6305 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
6306
6307 2020-03-16 Tom Tromey <tromey@adacore.com>
6308
6309 PR gdb/25663:
6310 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
6311 putting value into bcache.
6312
6313 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6314
6315 PR gdb/21500
6316 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
6317 to...
6318 (amd64_windows_init_abi_common): ... this. Don't set size of
6319 long type.
6320 (amd64_windows_init_abi): New function.
6321 (amd64_cygwin_init_abi): New function.
6322 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
6323 the Cygwin OS ABI.
6324 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
6325 comment.
6326
6327 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6328
6329 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
6330 * windows-tdep.c (CYGWIN_DLL_NAME): New.
6331 (pe_import_directory_entry): New struct type.
6332 (is_linked_with_cygwin_dll): New function.
6333 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
6334 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
6335 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
6336
6337 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6338
6339 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
6340 i386_cygwin_core_osabi_sniffer.
6341
6342 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6343
6344 * i386-cygwin-tdep.c: Rename to...
6345 * i386-windows-tdep.c: ... this.
6346 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
6347 i386-windows-tdep.c.
6348 * configure.tgt: Likewise.
6349
6350 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6351
6352 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
6353 * osabi.c (gdb_osabi_names): Add "Windows".
6354 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
6355 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
6356 (i386_cygwin_core_osabi_sniffer): New function, extracted from
6357 i386_cygwin_osabi_sniffer.
6358 (_initialize_i386_cygwin_tdep): Register OS ABI
6359 GDB_OSABI_WINDOWS for i386.
6360 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
6361 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
6362 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
6363 for x86-64.
6364 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
6365 when the target matches '*-*-mingw*'.
6366
6367 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6368
6369 * defs.h (enum gdb_osabi): Move to...
6370 * osabi.h (enum gdb_osabi): ... here.
6371 * gdbarch.sh: Include osabi.h in gdbarch.h.
6372 * gdbarch.h: Re-generate.
6373
6374 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6375
6376 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
6377 function.
6378 (_initialize_amd64_windows_tdep): Register osabi sniffer.
6379
6380 2020-03-14 Tom Tromey <tom@tromey.com>
6381
6382 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
6383 for C++.
6384 (c_type_print_modifier): Likewise. Add "language" parameter.
6385 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
6386 (c_type_print_base_1): Update.
6387 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
6388 constants.
6389 * type-stack.c (type_stack::insert): Handle tp_atomic and
6390 tp_restrict.
6391 (type_stack::follow_type_instance_flags): Likewise.
6392 (type_stack::follow_types): Likewise. Merge type-following code.
6393 * c-exp.y (RESTRICT, ATOMIC): New tokens.
6394 (space_identifier, cv_with_space_id)
6395 (const_or_volatile_or_space_identifier_noopt)
6396 (const_or_volatile_or_space_identifier): Remove.
6397 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
6398 rules.
6399 (ptr_operator, typebase): Update.
6400 (enum token_flag) <FLAG_C>: New constant.
6401 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
6402 "_Atomic".
6403 (lex_one_token): Handle FLAG_C.
6404
6405 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6406
6407 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
6408 it to the ptrace call.
6409 * m68k-bsd-nat.c (store_registers): Likewise.
6410
6411 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6412
6413 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
6414 gdb_byte *.
6415 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
6416 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
6417 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
6418
6419 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6420
6421 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
6422 nbsd_nat_target instead of inf_ptrace_target.
6423 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6424 nbsd_nat_target.
6425
6426 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6427
6428 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
6429 register_t.
6430
6431 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6432
6433 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
6434 it to the ptrace call.
6435 * alpha-bsd-nat.c (store_registers): Likewise.
6436
6437 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6438
6439 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
6440 includes.
6441 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
6442 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
6443 fill_fpregset): Likewise.
6444
6445 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6446
6447 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
6448 nbsd_nat_target instead of inf_ptrace_target.
6449 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6450 nbsd_nat_target.
6451
6452 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6453
6454 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
6455 register_t.
6456
6457 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6458
6459 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
6460 it to the ptrace call.
6461 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
6462 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
6463 * arm-nbsd-nat.c (store_register): Likewise.
6464 * arm-nbsd-nat.c (store_regs): Likewise.
6465 * arm-nbsd-nat.c (store_fp_register): Likewise.
6466 * arm-nbsd-nat.c (store_fp_regs): Likewise.
6467
6468 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6469
6470 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
6471 nbsd_nat_target instead of inf_ptrace_target.
6472 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6473 nbsd_nat_target.
6474
6475 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6476
6477 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
6478 it to the ptrace call.
6479 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
6480
6481 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6482
6483 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
6484 it to the ptrace call.
6485 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
6486
6487 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6488
6489 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
6490 gdb_byte *.
6491 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
6492
6493 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6494
6495 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
6496 instead of inf_ptrace_target.
6497 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6498 nbsd_nat_target.
6499
6500 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6501
6502 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6503 register_t.
6504
6505 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6506
6507 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6508 register_t.
6509
6510 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6511
6512 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
6513 register_t.
6514
6515 2020-03-13 Tom Tromey <tom@tromey.com>
6516
6517 * value.h (val_print): Don't declare.
6518 * valprint.h (val_print_array_elements)
6519 (val_print_scalar_formatted, generic_val_print): Don't declare.
6520 * valprint.c (generic_val_print_array): Take a struct value.
6521 (generic_val_print_ptr, generic_val_print_memberptr)
6522 (generic_val_print_bool, generic_val_print_int)
6523 (generic_val_print_char, generic_val_print_complex)
6524 (generic_val_print): Remove.
6525 (generic_value_print): Update.
6526 (do_val_print): Remove unused parameters. Don't call
6527 la_val_print.
6528 (val_print): Remove.
6529 (common_val_print): Update. Don't call value_check_printable.
6530 (val_print_scalar_formatted, val_print_array_elements): Remove.
6531 * rust-lang.c (rust_val_print): Remove.
6532 (rust_language_defn): Update.
6533 * p-valprint.c (pascal_val_print): Remove.
6534 (pascal_value_print_inner): Update.
6535 (pascal_object_print_val_fields, pascal_object_print_val):
6536 Remove.
6537 (pascal_object_print_static_field): Update.
6538 * p-lang.h (pascal_val_print): Don't declare.
6539 * p-lang.c (pascal_language_defn): Update.
6540 * opencl-lang.c (opencl_language_defn): Update.
6541 * objc-lang.c (objc_language_defn): Update.
6542 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
6543 * m2-lang.h (m2_val_print): Don't declare.
6544 * m2-lang.c (m2_language_defn): Update.
6545 * language.h (struct language_defn) <la_val_print>: Remove.
6546 * language.c (unk_lang_value_print_inner): Rename. Change
6547 argument types.
6548 (unknown_language_defn, auto_language_defn): Update.
6549 * go-valprint.c (go_val_print): Remove.
6550 * go-lang.h (go_val_print): Don't declare.
6551 * go-lang.c (go_language_defn): Update.
6552 * f-valprint.c (f_val_print): Remove.
6553 * f-lang.h (f_value_print): Don't declare.
6554 * f-lang.c (f_language_defn): Update.
6555 * d-valprint.c (d_val_print): Remove.
6556 * d-lang.h (d_value_print): Don't declare.
6557 * d-lang.c (d_language_defn): Update.
6558 * cp-valprint.c (cp_print_value_fields)
6559 (cp_print_value_fields_rtti, cp_print_value): Remove.
6560 (cp_print_static_field): Update.
6561 * c-valprint.c (c_val_print_array, c_val_print_ptr)
6562 (c_val_print_struct, c_val_print_union, c_val_print_int)
6563 (c_val_print_memberptr, c_val_print): Remove.
6564 * c-lang.h (c_val_print_array, cp_print_value_fields)
6565 (cp_print_value_fields_rtti): Don't declare.
6566 * c-lang.c (c_language_defn, cplus_language_defn)
6567 (asm_language_defn, minimal_language_defn): Update.
6568 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
6569 (ada_val_print_enum): Take a struct value.
6570 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
6571 (ada_val_print): Remove.
6572 (ada_value_print_1): Update.
6573 (printable_val_type): Remove.
6574 * ada-lang.h (ada_val_print): Don't declare.
6575 * ada-lang.c (ada_language_defn): Update.
6576
6577 2020-03-13 Tom Tromey <tom@tromey.com>
6578
6579 * valprint.c (do_val_print): Update.
6580 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
6581 a struct value.
6582 (value_to_value_object_no_release): Declare.
6583 * python/py-value.c (value_to_value_object_no_release): New
6584 function.
6585 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
6586 struct value.
6587 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
6588 function.
6589 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
6590 a struct value.
6591 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
6592 Declare.
6593 (gdbscm_apply_val_pretty_printer): Take a struct value.
6594 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
6595 value.
6596 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
6597 value.
6598 * extension-priv.h (struct extension_language_ops)
6599 <apply_val_pretty_printer>: Take a struct value.
6600 * cp-valprint.c (cp_print_value): Create a struct value.
6601 (cp_print_value): Update.
6602
6603 2020-03-13 Tom Tromey <tom@tromey.com>
6604
6605 * ada-valprint.c (print_field_values): Call common_val_print.
6606
6607 2020-03-13 Tom Tromey <tom@tromey.com>
6608
6609 * ada-valprint.c (val_print_packed_array_elements): Remove
6610 bitoffset and val parameters. Call common_val_print.
6611 (ada_val_print_string): Remove offset, address, and original_value
6612 parameters.
6613 (ada_val_print_array): Update.
6614 (ada_value_print_array): New function.
6615 (ada_value_print_1): Call it.
6616
6617 2020-03-13 Tom Tromey <tom@tromey.com>
6618
6619 * ada-valprint.c (ada_value_print): Use common_val_print.
6620
6621 2020-03-13 Tom Tromey <tom@tromey.com>
6622
6623 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
6624
6625 2020-03-13 Tom Tromey <tom@tromey.com>
6626
6627 * ada-valprint.c (ada_value_print_num): New function.
6628 (ada_value_print_1): Use it.
6629
6630 2020-03-13 Tom Tromey <tom@tromey.com>
6631
6632 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
6633
6634 2020-03-13 Tom Tromey <tom@tromey.com>
6635
6636 * ada-valprint.c (ada_value_print_ptr): New function.
6637 (ada_value_print_1): Use it.
6638
6639 2020-03-13 Tom Tromey <tom@tromey.com>
6640
6641 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
6642 call common_val_print.
6643 (ada_val_print_1): Update.
6644 (ada_value_print_1): New function.
6645 (ada_value_print_inner): Rewrite.
6646
6647 2020-03-13 Tom Tromey <tom@tromey.com>
6648
6649 * cp-valprint.c (cp_print_value_fields): Update.
6650 (cp_print_value): New function.
6651
6652 2020-03-13 Tom Tromey <tom@tromey.com>
6653
6654 * m2-valprint.c (m2_value_print_inner): Use
6655 cp_print_value_fields.
6656 * cp-valprint.c (cp_print_value_fields): New function.
6657 * c-valprint.c (c_value_print_struct): New function.
6658 (c_value_print_inner): Use c_value_print_struct.
6659 * c-lang.h (cp_print_value_fields): Declare.
6660
6661 2020-03-13 Tom Tromey <tom@tromey.com>
6662
6663 * c-valprint.c (c_value_print_array): New function.
6664 (c_value_print_inner): Use it.
6665
6666 2020-03-13 Tom Tromey <tom@tromey.com>
6667
6668 * c-valprint.c (c_value_print_memberptr): New function.
6669 (c_value_print_inner): Use it.
6670
6671 2020-03-13 Tom Tromey <tom@tromey.com>
6672
6673 * c-valprint.c (c_value_print_int): New function.
6674 (c_value_print_inner): Use it.
6675
6676 2020-03-13 Tom Tromey <tom@tromey.com>
6677
6678 * c-valprint.c (c_value_print_ptr): New function.
6679 (c_value_print_inner): Use it.
6680
6681 2020-03-13 Tom Tromey <tom@tromey.com>
6682
6683 * c-valprint.c (c_value_print_inner): Rewrite.
6684
6685 2020-03-13 Tom Tromey <tom@tromey.com>
6686
6687 * valprint.c (generic_value_print_complex): New function.
6688 (generic_value_print): Use it.
6689
6690 2020-03-13 Tom Tromey <tom@tromey.com>
6691
6692 * valprint.c (generic_val_print_float): Don't call
6693 val_print_scalar_formatted.
6694 (generic_val_print, generic_value_print): Update.
6695
6696 2020-03-13 Tom Tromey <tom@tromey.com>
6697
6698 * valprint.c (generic_value_print_char): New function
6699 (generic_value_print): Use it.
6700
6701 2020-03-13 Tom Tromey <tom@tromey.com>
6702
6703 * valprint.c (generic_value_print_int): New function.
6704 (generic_value_print): Use it.
6705
6706 2020-03-13 Tom Tromey <tom@tromey.com>
6707
6708 * valprint.c (generic_value_print_bool): New function.
6709 (generic_value_print): Use it.
6710
6711 2020-03-13 Tom Tromey <tom@tromey.com>
6712
6713 * valprint.c (generic_val_print_func): Simplify.
6714 (generic_val_print, generic_value_print): Update.
6715
6716 2020-03-13 Tom Tromey <tom@tromey.com>
6717
6718 * valprint.c (generic_val_print_flags): Remove.
6719 (generic_val_print, generic_value_print): Update.
6720 (val_print_type_code_flags): Add original_value parameter.
6721
6722 2020-03-13 Tom Tromey <tom@tromey.com>
6723
6724 * valprint.c (generic_val_print): Update.
6725 (generic_value_print): Update.
6726 * valprint.c (generic_val_print_enum): Don't call
6727 val_print_scalar_formatted.
6728
6729 2020-03-13 Tom Tromey <tom@tromey.com>
6730
6731 * valprint.c (generic_value_print): Call generic_value_print_ptr.
6732 * valprint.c (generic_value_print_ptr): New function.
6733
6734 2020-03-13 Tom Tromey <tom@tromey.com>
6735
6736 * valprint.c (generic_value_print): Rewrite.
6737
6738 2020-03-13 Tom Tromey <tom@tromey.com>
6739
6740 * p-valprint.c (pascal_object_print_value_fields)
6741 (pascal_object_print_value): New functions.
6742
6743 2020-03-13 Tom Tromey <tom@tromey.com>
6744
6745 * p-valprint.c (pascal_value_print_inner): Rewrite.
6746
6747 2020-03-13 Tom Tromey <tom@tromey.com>
6748
6749 * f-valprint.c (f_value_print_innner): Rewrite.
6750
6751 2020-03-13 Tom Tromey <tom@tromey.com>
6752
6753 * m2-valprint.c (m2_print_unbounded_array): New overload.
6754 (m2_print_unbounded_array): Update.
6755 (m2_print_array_contents): Take a struct value.
6756 (m2_value_print_inner): Rewrite.
6757
6758 2020-03-13 Tom Tromey <tom@tromey.com>
6759
6760 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
6761 (d_value_print_inner): New function.
6762 * d-lang.h (d_value_print_inner): Declare.
6763 * d-lang.c (d_language_defn): Use d_value_print_inner.
6764
6765 2020-03-13 Tom Tromey <tom@tromey.com>
6766
6767 * go-valprint.c (go_value_print_inner): New function.
6768 * go-lang.h (go_value_print_inner): Declare.
6769 * go-lang.c (go_language_defn): Use go_value_print_inner.
6770
6771 2020-03-13 Tom Tromey <tom@tromey.com>
6772
6773 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
6774 API.
6775 (rust_val_print): Rewrite.
6776 (rust_value_print_inner): New function, from rust_val_print.
6777 (rust_language_defn): Use rust_value_print_inner.
6778
6779 2020-03-13 Tom Tromey <tom@tromey.com>
6780
6781 * ada-valprint.c (ada_value_print_inner): New function.
6782 * ada-lang.h (ada_value_print_inner): Declare.
6783 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
6784
6785 2020-03-13 Tom Tromey <tom@tromey.com>
6786
6787 * f-valprint.c (f_value_print_innner): New function.
6788 * f-lang.h (f_value_print_innner): Declare.
6789 * f-lang.c (f_language_defn): Use f_value_print_innner.
6790
6791 2020-03-13 Tom Tromey <tom@tromey.com>
6792
6793 * p-valprint.c (pascal_value_print_inner): New function.
6794 * p-lang.h (pascal_value_print_inner): Declare.
6795 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
6796
6797 2020-03-13 Tom Tromey <tom@tromey.com>
6798
6799 * m2-valprint.c (m2_value_print_inner): New function.
6800 * m2-lang.h (m2_value_print_inner): Declare.
6801 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
6802
6803 2020-03-13 Tom Tromey <tom@tromey.com>
6804
6805 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
6806 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
6807 * c-valprint.c (c_value_print_inner): New function.
6808 * c-lang.h (c_value_print_inner): Declare.
6809 * c-lang.c (c_language_defn, cplus_language_defn)
6810 (asm_language_defn, minimal_language_defn): Use
6811 c_value_print_inner.
6812
6813 2020-03-13 Tom Tromey <tom@tromey.com>
6814
6815 * p-valprint.c (pascal_object_print_value_fields): Now static.
6816 * p-lang.h (pascal_object_print_value_fields): Don't declare.
6817
6818 2020-03-13 Tom Tromey <tom@tromey.com>
6819
6820 * c-valprint.c (c_val_print_array): Simplify.
6821
6822 2020-03-13 Tom Tromey <tom@tromey.com>
6823
6824 * valprint.c (value_print_array_elements): New function.
6825 * valprint.h (value_print_array_elements): Declare.
6826
6827 2020-03-13 Tom Tromey <tom@tromey.com>
6828
6829 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
6830 * mips-tdep.c (mips_print_register): Use
6831 value_print_scalar_formatted.
6832
6833 2020-03-13 Tom Tromey <tom@tromey.com>
6834
6835 * valprint.h (value_print_scalar_formatted): Declare.
6836 * valprint.c (value_print_scalar_formatted): New function.
6837
6838 2020-03-13 Tom Tromey <tom@tromey.com>
6839
6840 * valprint.h (generic_value_print): Declare.
6841 * valprint.c (generic_value_print): New function.
6842
6843 2020-03-13 Tom Tromey <tom@tromey.com>
6844
6845 * valprint.c (do_val_print): Call la_value_print_inner, if
6846 available.
6847 * rust-lang.c (rust_language_defn): Update.
6848 * p-lang.c (pascal_language_defn): Update.
6849 * opencl-lang.c (opencl_language_defn): Update.
6850 * objc-lang.c (objc_language_defn): Update.
6851 * m2-lang.c (m2_language_defn): Update.
6852 * language.h (struct language_defn) <la_value_print_inner>: New
6853 member.
6854 * language.c (unknown_language_defn, auto_language_defn): Update.
6855 * go-lang.c (go_language_defn): Update.
6856 * f-lang.c (f_language_defn): Update.
6857 * d-lang.c (d_language_defn): Update.
6858 * c-lang.c (c_language_defn, cplus_language_defn)
6859 (asm_language_defn, minimal_language_defn): Update.
6860 * ada-lang.c (ada_language_defn): Update.
6861
6862 2020-03-13 Tom Tromey <tom@tromey.com>
6863
6864 * c-valprint.c (c_value_print): Use common_val_print.
6865
6866 2020-03-13 Tom Tromey <tom@tromey.com>
6867
6868 * cp-valprint.c (cp_print_static_field): Use common_val_print.
6869
6870 2020-03-13 Tom Tromey <tom@tromey.com>
6871
6872 * f-valprint.c (f77_print_array_1, f_val_print): Use
6873 common_val_print.
6874
6875 2020-03-13 Tom Tromey <tom@tromey.com>
6876
6877 * riscv-tdep.c (riscv_print_one_register_info): Use
6878 common_val_print.
6879
6880 2020-03-13 Tom Tromey <tom@tromey.com>
6881
6882 * mi/mi-main.c (output_register): Use common_val_print.
6883
6884 2020-03-13 Tom Tromey <tom@tromey.com>
6885
6886 * infcmd.c (default_print_one_register_info): Use
6887 common_val_print.
6888
6889 2020-03-13 Tom Tromey <tom@tromey.com>
6890
6891 * valprint.h (common_val_print_checked): Declare.
6892 * valprint.c (common_val_print_checked): New function.
6893 * stack.c (print_frame_arg): Use common_val_print_checked.
6894
6895 2020-03-13 Tom Tromey <tom@tromey.com>
6896
6897 * valprint.c (do_val_print): New function, from val_print.
6898 (val_print): Use do_val_print.
6899 (common_val_print): Use do_val_print.
6900
6901 2020-03-13 Tom Tromey <tom@tromey.com>
6902
6903 * valprint.c (value_print): Use scoped_value_mark.
6904
6905 2020-03-13 Tom de Vries <tdevries@suse.de>
6906
6907 PR symtab/25646
6908 * psymtab.c (partial_symtab::partial_symtab): Don't set
6909 globals_offset and statics_offset. Push element onto
6910 current_global_psymbols and current_static_psymbols stacks.
6911 (concat): New function.
6912 (end_psymtab_common): Set globals_offset and statics_offset. Pop
6913 element from current_global_psymbols and current_static_psymbols
6914 stacks. Concat popped elements to global_psymbols and
6915 static_symbols.
6916 (add_psymbol_to_list): Use current_global_psymbols and
6917 current_static_psymbols stacks.
6918 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
6919 current_static_psymbols fields.
6920
6921 2020-03-12 Christian Biesinger <cbiesinger@google.com>
6922
6923 * corelow.c (sniff_core_bfd): Remove.
6924 (class core_target) <m_core_vec>: Remove.
6925 (core_target::core_target): Update.
6926 (core_file_fns): Remove.
6927 (deprecated_add_core_fns): Remove.
6928 (default_core_sniffer): Remove.
6929 (sniff_core_bfd): Remove.
6930 (default_check_format): Remove.
6931 (gdb_check_format): Remove.
6932 (core_target_open): Update.
6933 (core_target::get_core_register_section): Update.
6934 (get_core_registers_cb): Update.
6935 (core_target::fetch_registers): Update.
6936 * gdbcore.h (struct core_fns): Remove.
6937 (deprecated_add_core_fns): Remove.
6938 (default_core_sniffer): Remove.
6939 (default_check_format): Remove.
6940
6941 2020-03-12 Tom Tromey <tom@tromey.com>
6942
6943 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
6944 CORE_ADDR.
6945 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
6946
6947 2020-03-12 Tom Tromey <tom@tromey.com>
6948
6949 * remote.c (remote_target::download_tracepoint)
6950 (remote_target::enable_tracepoint)
6951 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
6952 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
6953 sprintf_vma.
6954
6955 2020-03-12 Tom Tromey <tom@tromey.com>
6956
6957 * symfile-mem.c: Update CORE_ADDR size assert.
6958
6959 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6960
6961 * selftest.m4: Move to gdbsupport/.
6962 * acinclude.m4: Update path to selftest.m4.
6963
6964 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6965
6966 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
6967 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
6968 gdbarch-selfselftests.c and selftest-arch.c.
6969 (SUBDIR_UNITTESTS_OBS): Rename to...
6970 (SELFTESTS_OBS): ... this.
6971 (COMMON_SFILES): Remove disasm-selftests.c and
6972 gdbarch-selftests.c.
6973 * configure.ac: Don't add selftest-arch.{c,o} to
6974 CONFIG_{SRCS,OBS}.
6975 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
6976 preprocessor conditions.
6977
6978 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6979
6980 * configure.ac: Don't source bfd/development.sh.
6981 * selftest.m4: Modify comment.
6982 * configure: Re-generate.
6983
6984 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6985
6986 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
6987 not "true" or "false".
6988 * configure: Re-generate.
6989
6990 2020-03-12 Christian Biesinger <cbiesinger@google.com>
6991
6992 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
6993 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
6994 renamed to arm_nbsd_supply_gregset.
6995 (fetch_register): Update to call arm_nbsd_supply_gregset.
6996 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
6997 (arm_netbsd_nat_target::fetch_registers): Update.
6998 (fetch_elfcore_registers): Removed.
6999 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
7000 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
7001 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
7002 not require NetBSD system headers.
7003 (arm_nbsd_regset): New struct.
7004 (arm_nbsd_iterate_over_regset_sections): New function.
7005 (arm_netbsd_init_abi_common): Updated to call
7006 set_gdbarch_iterate_over_regset_sections.
7007 * arm-nbsd-tdep.h: New file.
7008
7009 2020-03-11 Kevin Buettner <kevinb@redhat.com>
7010
7011 * symtab.c (find_pc_sect_line): Add check which prevents infinite
7012 recursion.
7013
7014 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
7015
7016 * configure: Re-generate.
7017
7018 2020-03-11 Tom Tromey <tromey@adacore.com>
7019
7020 * ada-typeprint.c (print_choices): Fix comment.
7021
7022 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
7023
7024 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
7025 previous item in the list, when the list has no items.
7026
7027 2020-03-11 Tom de Vries <tdevries@suse.de>
7028
7029 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
7030 PROP_LOCLIST handling code.
7031
7032 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
7033
7034 * buildsym-legacy.c (record_line): Pass extra parameter to
7035 record_line.
7036 * buildsym.c (buildsym_compunit::record_line): Take an extra
7037 parameter, reduce duplication in the line table, and record the
7038 is_stmt flag in the line table.
7039 * buildsym.h (buildsym_compunit::record_line): Add extra
7040 parameter.
7041 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
7042 non-statement lines.
7043 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
7044 this to the symtab builder.
7045 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
7046 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
7047 through to dwarf_record_line_1.
7048 * infrun.c (process_event_stop_test): When stepping, don't stop at
7049 a non-statement instruction, and only refresh the step info when
7050 we land in the middle of a line's range. Also add an extra
7051 comment.
7052 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
7053 field.
7054 * record-btrace.c (btrace_find_line_range): Only record lines
7055 marked as is-statement.
7056 * stack.c (frame_show_address): Show the frame address if we are
7057 in a non-statement sal.
7058 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
7059 (maintenance_print_one_line_table): Print a header for the is_stmt
7060 column, and include is_stmt information in the output.
7061 * symtab.c (find_pc_sect_line): Find lines marked as statements in
7062 preference to non-statements.
7063 (find_pcs_for_symtab_line): Prefer is-statement entries.
7064 (find_line_common): Likewise.
7065 * symtab.h (struct linetable_entry): Add is_stmt field.
7066 (struct symtab_and_line): Likewise.
7067 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
7068 arranging the line table.
7069
7070 2020-03-07 Tom de Vries <tdevries@suse.de>
7071
7072 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
7073 DIE.
7074
7075 2020-03-07 Tom Tromey <tom@tromey.com>
7076
7077 * valops.c (value_literal_complex): Remove obsolete comment.
7078 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
7079 comment.
7080
7081 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7082
7083 * infrun.h: Forward-declare thread_info.
7084 (set_step_info): Add thread_info parameter, add doc.
7085 * infrun.c (set_step_info): Add thread_info parameter, move doc
7086 to header.
7087 * infrun.c (process_event_stop_test): Pass thread to
7088 set_step_info call.
7089 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
7090 set_step_info.
7091 (prepare_one_step): Add thread_info parameter, pass it to
7092 set_step_frame and prepare_one_step (recursive) call.
7093 (step_1): Pass thread to prepare_one_step call.
7094 (step_command_fsm::should_stop): Pass thread to
7095 prepare_one_step.
7096 (until_next_fsm): Pass thread to set_step_frame call.
7097 (finish_command): Pass thread to set_step_info call.
7098
7099 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
7100
7101 * windows-tdep.c (windows_solib_create_inferior_hook):
7102 Check if inferior is running.
7103
7104 2020-03-06 Tom de Vries <tdevries@suse.de>
7105
7106 * NEWS: Fix "the the".
7107 * ctfread.c: Same.
7108
7109 2020-03-06 Tom de Vries <tdevries@suse.de>
7110
7111 * psymtab.c (psymtab_to_symtab): Don't print "done.".
7112
7113 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7114
7115 * .dir-locals.el: Add a comment referencing the other copies of
7116 this file.
7117
7118 2020-03-05 John Baldwin <jhb@FreeBSD.org>
7119
7120 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
7121 psargs.
7122
7123 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7124
7125 * .gitattributes: New file.
7126
7127 2020-03-04 Tom Tromey <tom@tromey.com>
7128
7129 * symmisc.c (print_symbol_bcache_statistics)
7130 (print_objfile_statistics): Update.
7131 * symfile.c (allocate_symtab): Use intern.
7132 * psymtab.c (partial_symtab::partial_symtab): Use intern.
7133 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
7134 macro_cache>: Remove.
7135 <string_cache>: New member.
7136 (struct objfile) <intern>: New methods.
7137 * elfread.c (elf_symtab_read): Use intern.
7138 * dwarf2/read.c (fixup_go_packaging): Intern package name.
7139 (dwarf2_compute_name, dwarf2_physname)
7140 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
7141 names.
7142 (guess_partial_die_structure_name): Update.
7143 (partial_die_info::fixup): Intern name.
7144 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
7145 name.
7146 (dwarf2_name): Intern name. Update.
7147 * buildsym.c (buildsym_compunit::get_macro_table): Use
7148 string_cache.
7149
7150 2020-03-04 Tom Tromey <tom@tromey.com>
7151
7152 * jit.c (bfd_open_from_target_memory): Make "target" const.
7153 * corefile.c (gnutarget): Now const.
7154 * gdbcore.h (gnutarget): Now const.
7155
7156 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
7157
7158 * NEWS: Mention support for WOW64 processes.
7159 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
7160 (amd64_windows_segment_register_p): Remove static.
7161 (_initialize_amd64_windows_nat): Update.
7162 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
7163 * i386-windows-nat.c (context_offset): Update.
7164 (i386_mappings): Rename and remove static.
7165 (i386_windows_segment_register_p): Remove static.
7166 (_initialize_i386_windows_nat): Update.
7167 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
7168 (STATUS_WX86_SINGLE_STEP): New macro.
7169 (EnumProcessModulesEx): New macro.
7170 (Wow64SuspendThread): New macro.
7171 (Wow64GetThreadContext): New macro.
7172 (Wow64SetThreadContext): New macro.
7173 (Wow64GetThreadSelectorEntry): New macro.
7174 (windows_set_context_register_offsets): Add static.
7175 (windows_set_segment_register_p): Likewise.
7176 (windows_add_thread): Adapt for WOW64 processes.
7177 (windows_fetch_one_register): Likewise.
7178 (windows_nat_target::fetch_registers): Likewise.
7179 (windows_store_one_register): Likewise.
7180 (display_selector): Likewise.
7181 (display_selectors): Likewise.
7182 (handle_exception): Likewise.
7183 (windows_continue): Likewise.
7184 (windows_nat_target::resume): Likewise.
7185 (windows_add_all_dlls): Likewise.
7186 (do_initial_windows_stuff): Likewise.
7187 (windows_nat_target::attach): Likewise.
7188 (windows_get_exec_module_filename): Likewise.
7189 (windows_nat_target::create_inferior): Likewise.
7190 (windows_xfer_siginfo): Likewise.
7191 (_initialize_loadable): Initialize Wow64SuspendThread,
7192 Wow64GetThreadContext, Wow64SetThreadContext,
7193 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
7194 * windows-nat.h (windows_set_context_register_offsets):
7195 Remove declaration.
7196 (windows_set_segment_register_p): Likewise.
7197 (i386_windows_segment_register_p): Add declaration.
7198 (amd64_windows_segment_register_p): Likewise.
7199
7200 2020-03-04 Luis Machado <luis.machado@linaro.org>
7201
7202 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
7203 in "info registers" for AArch64/ARM.
7204
7205 The change caused "info registers" to not print GPR's.
7206
7207 gdb/ChangeLog:
7208
7209 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
7210
7211 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
7212 when reg->group is empty and reggroup is not.
7213
7214 2020-03-03 Tom Tromey <tromey@adacore.com>
7215
7216 * dwarf2/frame.c (struct dwarf2_frame_cache)
7217 <checked_tailcall_bottom, entry_cfa_sp_offset,
7218 entry_cfa_sp_offset_p>: Remove members.
7219 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
7220 (dwarf2_frame_prev_register): Don't call
7221 dwarf2_tailcall_sniffer_first.
7222 (dwarf2_append_unwinders): Don't append tailcall unwinder.
7223 * frame-unwind.c (add_unwinder): New fuction.
7224 (frame_unwind_init): Use it. Add tailcall unwinder.
7225
7226 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
7227 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
7228
7229 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
7230 value should be printed as true.
7231
7232 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
7233
7234 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
7235 (windows_init_abi): Set and use windows_so_ops.
7236
7237 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
7238
7239 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
7240 when verifying if dealing with a convenience variable.
7241
7242 2020-03-03 Luis Machado <luis.machado@linaro.org>
7243
7244 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
7245
7246 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7247
7248 * infrun.c (gdbarch_supports_displaced_stepping): New.
7249 (use_displaced_stepping): Break up conditions in smaller pieces.
7250 Use gdbarch_supports_displaced_stepping.
7251 (displaced_step_prepare_throw): Use
7252 gdbarch_supports_displaced_stepping.
7253
7254 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
7255
7256 * NEWS: Mention new behaviour of the history filename.
7257 * top.c (write_history_p): Add comment.
7258 (show_write_history_p): Add header comment, give a different
7259 message when history writing is on, but the history filename is
7260 empty.
7261 (history_filename): Add comment.
7262 (history_filename_empty): New function.
7263 (show_history_filename): Add header comment, give a different
7264 message when the filename is empty.
7265 (init_history): Compare history_filename against nullptr, and only
7266 read history if the filename is not empty.
7267 (set_history_filename): Add header comment, and only make
7268 non-empty filenames absolute.
7269 (init_main): Make the filename argument to 'set history filename'
7270 optional.
7271
7272 2020-03-02 Christian Biesinger <cbiesinger@google.com>
7273
7274 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
7275 (arm_supply_vfpregset): ...this, and update to use VFP registers.
7276 (fetch_fp_register): Update.
7277 (fetch_fp_regs): Update.
7278 (store_fp_register): Update.
7279 (store_fp_regs): Update.
7280 (arm_netbsd_nat_target::read_description): New function.
7281 (fetch_elfcore_registers): Update.
7282
7283 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
7284
7285 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
7286 general_thread if the stop reply is missing a thread-id.
7287 (remote_target::process_stop_reply): Use the first non-exited
7288 thread if the target didn't pass a thread-id.
7289 * infrun.c (do_target_wait): Move call to
7290 switch_to_inferior_no_thread to ....
7291 (do_target_wait_1): ... here.
7292
7293 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
7294
7295 * debuginfod-support.c: Include defs.h first.
7296
7297 2020-02-28 Tom de Vries <tdevries@suse.de>
7298
7299 * symfile.c (set_initial_language): Use default language for lookup.
7300
7301 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
7302
7303 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
7304 reader variable, pass `this` to read_cutu_die_from_dwo.
7305
7306 2020-02-27 Aaron Merey <amerey@redhat.com>
7307
7308 * source.c (open_source_file): Check for nullptr when computing
7309 srcpath.
7310
7311 2020-02-27 Tom Tromey <tromey@adacore.com>
7312
7313 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
7314 member.
7315 (dwarf2_add_field): Don't update nfields.
7316 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
7317
7318 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
7319
7320 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
7321 abs.
7322
7323 2020-02-26 Tom Tromey <tom@tromey.com>
7324
7325 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
7326 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
7327 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
7328 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
7329 per_cu_data.
7330
7331 2020-02-26 Tom Tromey <tom@tromey.com>
7332
7333 * dwarf2/index-write.c (psym_index_map): Change type.
7334 (add_address_entry_worker, write_one_signatured_type)
7335 (recursively_count_psymbols, recursively_write_psymbols)
7336 (class debug_names, psyms_seen_size, write_gdbindex)
7337 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
7338
7339 2020-02-26 Aaron Merey <amerey@redhat.com>
7340
7341 * Makefile.in: Handle optional debuginfod support.
7342 * NEWS: Update.
7343 * README: Add --with-debuginfod summary.
7344 * config.in: Regenerate.
7345 * configure: Regenerate.
7346 * configure.ac: Handle optional debuginfod support.
7347 * debuginfod-support.c: debuginfod helper functions.
7348 * debuginfod-support.h: Ditto.
7349 * doc/gdb.texinfo: Add --with-debuginfod to configure options
7350 summary.
7351 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
7352 when a dwz file cannot be found.
7353 * elfread.c (elf_symfile_read): Query debuginfod servers when a
7354 debuginfo file cannot be found.
7355 * source.c (open_source_file): Query debuginfod servers when a
7356 source file cannot be found.
7357 * top.c (print_gdb_configuration): Include
7358 --{with,without}-debuginfod in the output.
7359
7360 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
7361
7362 * thread.c (thr_try_catch_cmd): Print thread name.
7363
7364 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
7365
7366 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
7367 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7368 dwarf2_fetch_die_type_sect_off): Move to...
7369 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
7370 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7371 dwarf2_fetch_die_type_sect_off): ... here.
7372 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
7373 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7374 dwarf2_fetch_die_type_sect_off): Move doc to header file.
7375
7376 2020-02-26 Tom de Vries <tdevries@suse.de>
7377
7378 PR gdb/25603
7379 * symfile.c (set_initial_language): Exit-early if
7380 language_mode == language_mode_manual.
7381
7382 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
7383
7384 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
7385 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
7386 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
7387
7388 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
7389
7390 * gdbtypes.c (create_array_type_with_stride): Handle negative
7391 array strides.
7392 * valarith.c (value_subscripted_rvalue): Likewise.
7393
7394 2020-02-25 Luis Machado <luis.machado@linaro.org>
7395
7396 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
7397
7398 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
7399
7400 * loc.h (dwarf2_get_die_type): Move to...
7401 * read.h (dwarf2_get_die_type): ... here.
7402 * read.c (dwarf2_get_die_type): Move doc to header.
7403
7404 2020-02-25 Joel Brobecker <brobecker@adacore.com>
7405
7406 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
7407 'gnulib/Makefile.in' to the list.
7408
7409 2020-02-24 Tom Tromey <tom@tromey.com>
7410
7411 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
7412 Remove.
7413 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
7414 XOBNEWVEC.
7415
7416 2020-02-24 Tom Tromey <tom@tromey.com>
7417
7418 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
7419 New method.
7420 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
7421 (dw2_do_instantiate_symtab, dw2_get_file_names)
7422 (build_type_psymtab_dependencies, load_full_type_unit): Update.
7423
7424 2020-02-24 Tom Tromey <tom@tromey.com>
7425
7426 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
7427 make_scoped_restore.
7428 (dwarf2_psymtab::read_symtab): Don't clear
7429 reading_partial_symbols.
7430
7431 2020-02-24 Tom de Vries <tdevries@suse.de>
7432
7433 PR gdb/25592
7434 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
7435
7436 2020-02-24 Tom de Vries <tdevries@suse.de>
7437
7438 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
7439 commands layout next/prev/regs.
7440
7441 2020-02-22 Tom Tromey <tom@tromey.com>
7442
7443 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
7444 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
7445
7446 2020-02-22 Tom Tromey <tom@tromey.com>
7447
7448 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
7449
7450 2020-02-22 Tom Tromey <tom@tromey.com>
7451
7452 * tui/tui-win.c (_initialize_tui_win): Add usage text.
7453 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
7454 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
7455 * tui/tui.c (_initialize_tui): Add usage text.
7456
7457 2020-02-22 Tom Tromey <tom@tromey.com>
7458
7459 * tui/tui-win.c (tui_set_focus_command)
7460 (tui_set_win_height_command): Use error_no_arg.
7461 (_initialize_tui_win): Update help text.
7462 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
7463
7464 2020-02-22 Tom Tromey <tom@tromey.com>
7465
7466 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
7467 * tui/tui-disasm.h (struct tui_disasm_window)
7468 <display_start_addr>: Declare.
7469 * tui/tui-source.h (struct tui_source_window)
7470 <display_start_addr>: Declare.
7471 * tui/tui-winsource.h (struct tui_source_window_base)
7472 <show_source_line, display_start_addr>: New methods.
7473 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
7474 Rename and move to protected section.
7475 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
7476 (tui_source_window_base::do_erase_source_content): Update.
7477 (tui_source_window_base::show_source_line): Now a method.
7478 (tui_source_window_base::show_source_content)
7479 (tui_source_window_base::tui_source_window_base)
7480 (tui_source_window_base::rerender)
7481 (tui_source_window_base::refill)
7482 (tui_source_window_base::do_scroll_horizontal)
7483 (tui_source_window_base::set_is_exec_point_at)
7484 (tui_source_window_base::update_breakpoint_info)
7485 (tui_source_window_base::update_exec_info): Update.
7486 * tui/tui-source.c (tui_source_window::set_contents)
7487 (tui_source_window::showing_source_p)
7488 (tui_source_window::do_scroll_vertical)
7489 (tui_source_window::location_matches_p)
7490 (tui_source_window::line_is_displayed): Update.
7491 (tui_source_window::display_start_addr): New method.
7492 * tui/tui-disasm.c (tui_disasm_window::set_contents)
7493 (tui_disasm_window::do_scroll_vertical)
7494 (tui_disasm_window::location_matches_p): Update.
7495 (tui_disasm_window::display_start_addr): New method.
7496
7497 2020-02-22 Tom Tromey <tom@tromey.com>
7498
7499 * NEWS: Add entry for gdb.register_window_type.
7500 * tui/tui-layout.h (window_factory): New typedef.
7501 (tui_register_window): Declare.
7502 * tui/tui-layout.c (saved_tui_windows): New global.
7503 (tui_apply_current_layout): Use it.
7504 (tui_register_window): New function.
7505 * python/python.c (do_start_initialization): Call
7506 gdbpy_initialize_tui.
7507 (python_GdbMethods): Add "register_window_type" function.
7508 * python/python-internal.h (gdbpy_register_tui_window)
7509 (gdbpy_initialize_tui): Declare.
7510 * python/py-tui.c: New file.
7511 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
7512
7513 2020-02-22 Tom Tromey <tom@tromey.com>
7514
7515 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
7516
7517 2020-02-22 Tom Tromey <tom@tromey.com>
7518
7519 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
7520 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
7521 * tui/tui-data.c (tui_set_win_with_focus): Remove.
7522 (tui_set_win_focus_to): Move from tui-win.c.
7523
7524 2020-02-22 Tom Tromey <tom@tromey.com>
7525
7526 * tui/tui-layout.c (make_standard_window, get_locator_window): New
7527 functions.
7528 (known_window_types): New global.
7529 (tui_get_window_by_name): Reimplement.
7530 (initialize_known_windows): New function.
7531 (validate_window_name): Rewrite.
7532 (_initialize_tui_layout): Call initialize_known_windows.
7533
7534 2020-02-22 Tom Tromey <tom@tromey.com>
7535
7536 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
7537 Remove constants.
7538 * tui/tui-winsource.h (struct tui_source_window_base)
7539 <tui_source_window_base>: Remove parameter.
7540 * tui/tui-winsource.c
7541 (tui_source_window_base::tui_source_window_base): Remove
7542 parameter.
7543 (tui_source_window_base::refill): Update.
7544 * tui/tui-stack.h (struct tui_locator_window)
7545 <tui_locator_window>: Update.
7546 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
7547 Default the constructor.
7548 * tui/tui-regs.h (struct tui_data_item_window)
7549 <tui_data_item_window>: Default the constructor.
7550 (struct tui_data_window) <tui_data_window>: Likewise.
7551 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
7552 Default the constructor.
7553 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
7554 Default the constructor.
7555 <type>: Remove.
7556 (struct tui_win_info) <tui_win_info>: Default the constructor.
7557 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
7558 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
7559 Default the constructor.
7560
7561 2020-02-22 Tom Tromey <tom@tromey.com>
7562
7563 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
7564 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
7565 * tui/tui-win.c (tui_resize_all): Don't call
7566 tui_delete_invisible_windows.
7567 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
7568 done.
7569 (tui_set_layout): Update.
7570 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
7571 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
7572 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
7573
7574 2020-02-22 Tom Tromey <tom@tromey.com>
7575
7576 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
7577 correctly.
7578
7579 2020-02-22 Tom Tromey <tom@tromey.com>
7580
7581 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
7582
7583 2020-02-22 Tom Tromey <tom@tromey.com>
7584
7585 * tui/tui-winsource.h (struct tui_source_window_iterator)
7586 <inner_iterator>: New etytypedef.
7587 <tui_source_window_iterator>: Take "end" parameter.
7588 <tui_source_window_iterator>: Take iterator.
7589 <operator*, advance>: Update.
7590 <m_iter>: Change type.
7591 <m_end>: New field.
7592 (struct tui_source_windows) <begin, end>: Update.
7593 * tui/tui-layout.c (tui_windows): New global.
7594 (tui_apply_current_layout): Clear tui_windows.
7595 (tui_layout_window::apply): Update tui_windows.
7596 * tui/tui-data.h (tui_windows): Declare.
7597 (all_tui_windows): Now inline function.
7598 (class tui_window_iterator, struct all_tui_windows): Remove.
7599
7600 2020-02-22 Tom Tromey <tom@tromey.com>
7601
7602 PR tui/17850:
7603 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
7604 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
7605 "height" argument.
7606 (class tui_layout_window) <get_sizes>: Likewise.
7607 (class tui_layout_split) <tui_layout_split>: Add "vertical"
7608 argument.
7609 <get_sizes>: Add "height" argument.
7610 <m_vertical>: New field.
7611 * tui/tui-layout.c (tui_layout_split::clone): Update.
7612 (tui_layout_split::get_sizes): Add "height" argument.
7613 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
7614 (tui_new_layout_command): Parse "-horizontal".
7615 (_initialize_tui_layout): Update help string.
7616 (tui_layout_split::specification): Add "-horizontal" when needed.
7617 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
7618 argument.
7619 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
7620 New methods.
7621
7622 2020-02-22 Tom Tromey <tom@tromey.com>
7623
7624 * tui/tui-layout.h (enum tui_adjust_result): New.
7625 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
7626 (class tui_layout_window) <adjust_size>: Return
7627 tui_adjust_result. Rewrite.
7628 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
7629 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
7630
7631 2020-02-22 Tom Tromey <tom@tromey.com>
7632
7633 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
7634 parameter and return types.
7635 (class tui_layout_base) <specification>: Add "depth".
7636 (class tui_layout_window) <specification>: Add "depth".
7637 (class tui_layout_split) <specification>: Add "depth".
7638 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
7639 and return types.
7640 (tui_new_layout_command): Parse sub-layouts.
7641 (_initialize_tui_layout): Update help string.
7642 (tui_layout_window::specification): Add "depth".
7643 (add_layout_command): Update.
7644
7645 2020-02-22 Tom Tromey <tom@tromey.com>
7646
7647 * NEWS: Add "tui new-layout" item.
7648 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
7649 Add new-layout command to help text.
7650 (validate_window_name): New function.
7651 (tui_new_layout_command): New function.
7652 (_initialize_tui_layout): Register "new-layout".
7653 (tui_layout_window::specification): New method.
7654 (tui_layout_window::specification): New method.
7655 * tui/tui-layout.h (class tui_layout_base) <specification>: New
7656 method.
7657 (class tui_layout_window) <specification>: New method.
7658 (class tui_layout_split) <specification>: New method.
7659
7660 2020-02-22 Tom Tromey <tom@tromey.com>
7661
7662 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
7663 * tui/tui-win.c (window_name_completer): Update comment.
7664 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
7665 Declare method.
7666 (class tui_layout_window) <replace_window>: Likewise.
7667 (class tui_layout_split) <replace_window>: Likewise.
7668 (tui_set_layout): Don't declare.
7669 (tui_set_initial_layout): Declare function.
7670 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
7671 (asm_regs_layout): New globals.
7672 (tui_current_layout, show_layout): Remove.
7673 (tui_set_layout, tui_add_win_to_layout): Rewrite.
7674 (find_layout, tui_apply_layout): New function.
7675 (layout_completer): Remove.
7676 (tui_next_layout): Reimplement.
7677 (tui_next_layout_command): New function.
7678 (tui_set_initial_layout, tui_prev_layout_command): New functions.
7679 (tui_regs_layout): Reimplement.
7680 (tui_regs_layout_command): New function.
7681 (extract_display_start_addr): Rewrite.
7682 (next_layout, prev_layout): Remove.
7683 (tui_layout_window::replace_window): New method.
7684 (tui_layout_split::replace_window): New method.
7685 (destroy_layout): New function.
7686 (layout_list): New global.
7687 (add_layout_command): New function.
7688 (initialize_layouts): Update.
7689 (tui_layout_command): New function.
7690 (_initialize_tui_layout): Install "layout" commands.
7691 * tui/tui-data.h (enum tui_layout_type): Remove.
7692 (tui_current_layout): Don't declare.
7693
7694 2020-02-22 Tom Tromey <tom@tromey.com>
7695
7696 * tui/tui-regs.c (tui_reg_layout): Remove.
7697 (tui_reg_command): Use tui_regs_layout.
7698 * tui/tui-layout.h (tui_reg_command): Declare.
7699 * tui/tui-layout.c (tui_reg_command): New function.
7700
7701 2020-02-22 Tom Tromey <tom@tromey.com>
7702
7703 * tui/tui.c (tui_rl_delete_other_windows): Call
7704 tui_remove_some_windows.
7705 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
7706 Declare method.
7707 (class tui_layout_window) <remove_windows>: New method.
7708 (class tui_layout_split) <remove_windows>: Declare.
7709 (tui_remove_some_windows): Declare.
7710 * tui/tui-layout.c (tui_remove_some_windows): New function.
7711 (tui_layout_split::remove_windows): New method.
7712
7713 2020-02-22 Tom Tromey <tom@tromey.com>
7714
7715 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
7716 * tui/tui-layout.h (tui_next_layout): Declare.
7717 * tui/tui-layout.c (tui_next_layout): New function.
7718
7719 2020-02-22 Tom Tromey <tom@tromey.com>
7720
7721 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
7722 correct coordinates.
7723
7724 2020-02-22 Tom Tromey <tom@tromey.com>
7725
7726 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
7727 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
7728 DATA_WIN case.
7729
7730 2020-02-22 Tom Tromey <tom@tromey.com>
7731
7732 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
7733 TUI_DISASM_WIN, not tui_win_list.
7734
7735 2020-02-22 Tom Tromey <tom@tromey.com>
7736
7737 * valprint.c (generic_val_print_enum_1)
7738 (val_print_type_code_flags): Style member names.
7739 * rust-lang.c (val_print_struct, rust_print_enum)
7740 (rust_print_struct_def, rust_internal_print_type): Style member
7741 names.
7742 * p-valprint.c (pascal_object_print_value_fields): Style member
7743 names. Only call fprintf_symbol_filtered for static members.
7744 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
7745 * f-valprint.c (f_val_print): Style member names.
7746 * f-typeprint.c (f_type_print_base): Style member names.
7747 * cp-valprint.c (cp_print_value_fields): Style member names. Only
7748 call fprintf_symbol_filtered for static members.
7749 (cp_print_class_member): Style member names.
7750 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
7751 member names.
7752 * ada-valprint.c (ada_print_scalar): Style enum names.
7753 (ada_val_print_enum): Likewise.
7754 * ada-typeprint.c (print_enum_type): Style enum names.
7755
7756 2020-02-21 Tom Tromey <tom@tromey.com>
7757
7758 * psympriv.h (struct partial_symtab): Update comment.
7759
7760 2020-02-21 Tom Tromey <tromey@adacore.com>
7761
7762 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
7763 type is CORE_ADDR.
7764
7765 2020-02-21 Tom de Vries <tdevries@suse.de>
7766
7767 PR gdb/25534
7768 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
7769 if dependencies[i]->user != NULL.
7770
7771 2020-02-21 Ali Tamur <tamur@google.com>
7772
7773 * dwarf2/read.c (dwarf2_name): Add null check.
7774
7775 2020-02-20 Tom Tromey <tom@tromey.com>
7776
7777 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
7778 ">=", in binary search.
7779 (dwarf2_find_containing_comp_unit): New overload.
7780 (run_test): New self-test.
7781 (_initialize_dwarf2_read): Register new test.
7782
7783 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
7784
7785 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
7786 * riscv-tdep.h: Likewise.
7787 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
7788 rv32-only CSR.
7789 * features/riscv/64bit-csr.xml: Regenerated.
7790
7791 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
7792 Tom Tromey <tom@tromey.com>
7793
7794 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
7795 of 'fputc_unfiltered'.
7796 (putchar_unfiltered): Call 'fputc_unfiltered'.
7797 (fputc_unfiltered): Call 'fputs_unfiltered'.
7798
7799 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
7800
7801 * config.in: Regenerate.
7802 * configure: Regenerate.
7803 * configure.ac: Add --with-python-libdir option.
7804 * main.c: Use WITH_PYTHON_LIBDIR.
7805
7806 2020-02-19 Tom Tromey <tom@tromey.com>
7807
7808 * symtab.c (general_symbol_info::compute_and_set_names): Use
7809 obstack_strndup. Simplify call to symbol_set_demangled_name.
7810
7811 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
7812
7813 * dwarf2/read.c (allocate_signatured_type_table,
7814 allocate_dwo_unit_table, allocate_type_unit_groups_table,
7815 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
7816 Remove objfile parameter, update all callers.
7817
7818 2020-02-19 Doug Evans <dje@google.com>
7819
7820 PR rust/25535
7821 * rust-lang.c (rust_print_enum): Apply embedded_offset to
7822 rust_enum_variant calculation.
7823
7824 2020-02-19 Tom Tromey <tromey@adacore.com>
7825
7826 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
7827
7828 2020-02-19 Tom Tromey <tromey@adacore.com>
7829
7830 * ada-lang.c (cache_symbol): Use obstack_strdup.
7831
7832 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
7833
7834 * configure: Regenerate.
7835
7836 2020-02-19 Tom Tromey <tromey@adacore.com>
7837
7838 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
7839 NULL check.
7840
7841 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
7842
7843 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
7844
7845 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
7846
7847 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
7848 if GDBSERVER is not defined.
7849 (riscv_tdesc_cache): Likewise, also store const target_desc.
7850 (STATIC_IN_GDB): Define.
7851 (riscv_create_target_description): Update declaration with
7852 STATIC_IN_GDB.
7853 (riscv_lookup_target_description): New function, only define if
7854 GDBSERVER is not defined.
7855 * arch/riscv.h (riscv_create_target_description): Declare only
7856 when GDBSERVER is defined.
7857 (riscv_lookup_target_description): New declaration when GDBSERVER
7858 is not defined.
7859 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
7860 (riscv_linux_read_features): ...this, and return
7861 riscv_gdbarch_features instead of target_desc.
7862 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
7863 (riscv_linux_read_description): Rename to...
7864 (riscv_linux_read_features): ...this.
7865 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
7866 Update to use riscv_gdbarch_features and
7867 riscv_lookup_target_description.
7868 * riscv-tdep.c (riscv_find_default_target_description): Use
7869 riscv_lookup_target_description instead of
7870 riscv_create_target_description.
7871
7872 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7873
7874 * valprint.c (generic_val_print_enum_1): When printing a flag
7875 enum with value 0 and there is no enumerator with value 0, print
7876 just "0" instead of "(unknown: 0x0)".
7877
7878 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7879
7880 * valprint.c (generic_val_print_enum_1): Print unknown part of
7881 flag enum in hex.
7882
7883 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7884
7885 * dwarf2/read.c (update_enumeration_type_from_children): Allow
7886 flag enums to contain duplicate enumerators.
7887 * valprint.c (generic_val_print_enum_1): Update comment.
7888
7889 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7890
7891 * dwarf2/read.c: Include "count-one-bits.h".
7892 (update_enumeration_type_from_children): If an enumerator has
7893 multiple bits set, don't treat the enumeration as a "flag enum".
7894 * valprint.c (generic_val_print_enum_1): Assert that enumerators
7895 of flag enums have 0 or 1 bit set.
7896
7897 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
7898
7899 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
7900 conversion.
7901 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
7902 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
7903 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
7904 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
7905 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
7906
7907 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7908
7909 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
7910
7911 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7912
7913 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
7914 displaced_step_closure_up.
7915 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
7916 (struct displaced_step_closure_up):
7917 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
7918 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
7919 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
7920 Likewise.
7921 * gdbarch.sh (displaced_step_copy_insn): Likewise.
7922 * gdbarch.c, gdbarch.h: Re-generate.
7923 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
7924 displaced_step_closure_up.
7925 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
7926 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
7927 * infrun.h (displaced_step_closure_up): New type alias.
7928 (struct displaced_step_inferior_state) <step_closure>: Change
7929 type to displaced_step_closure_up.
7930 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
7931 displaced_step_closure_up.
7932 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
7933
7934 2020-02-14 Tom Tromey <tom@tromey.com>
7935
7936 * minidebug.c (gnu_debug_key): New global.
7937 (find_separate_debug_file_in_section): Use it.
7938
7939 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7940
7941 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
7942 std::unique_ptr.
7943 * gdbarch.c: Re-generate.
7944 * gdbarch.h: Re-generate.
7945 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
7946 change.
7947 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
7948 type to std::unique_ptr.
7949 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
7950 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
7951 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
7952 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
7953 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
7954 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
7955 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
7956 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
7957 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
7958
7959 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7960
7961 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
7962 std::unique_ptr.
7963 (displaced_step_clear): Rename to...
7964 (displaced_step_reset): ... this. Just call displaced->reset ().
7965 (displaced_step_clear_cleanup): Rename to...
7966 (displaced_step_reset_cleanup): ... this.
7967 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
7968 (displaced_step_fixup): Likewise.
7969 (resume_1): Likewise.
7970 (handle_inferior_event): Restore child's memory before calling
7971 displaced_step_fixup on the parent.
7972 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
7973 to std::unique_ptr.
7974 <step_closure>: Change type to std::unique_ptr.
7975
7976 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7977
7978 * arm-tdep.c: Include count-one-bits.h.
7979 (cleanup_block_store_pc): Use count_one_bits.
7980 (cleanup_block_load_pc): Use count_one_bits.
7981 (arm_copy_block_xfer): Use count_one_bits.
7982 (thumb2_copy_block_xfer): Use count_one_bits.
7983 (thumb_copy_pop_pc_16bit): Use count_one_bits.
7984 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
7985 (thumb_get_next_pcs_raw): Use count_one_bits.
7986 (arm_get_next_pcs_raw): Use count_one_bits_l.
7987 * arch/arm.c (bitcount): Remove.
7988 * arch/arm.h (bitcount): Remove.
7989
7990 2020-02-14 Tom Tromey <tromey@adacore.com>
7991
7992 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
7993 Update.
7994 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
7995 * dwarf2/loc.c (call_site_find_chain_1): Return
7996 unique_xmalloc_ptr.
7997 (call_site_find_chain): Likewise.
7998
7999 2020-02-14 Richard Biener <rguenther@suse.de>
8000
8001 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
8002 on expression with division operators.
8003
8004 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8005
8006 * MAINTAINERS (Write After Approval): Adding myself.
8007
8008 2020-02-12 Tom Tromey <tom@tromey.com>
8009
8010 * event-loop.c (event_data, gdb_event, event_handler_func):
8011 Remove.
8012
8013 2020-02-12 Tom Tromey <tom@tromey.com>
8014
8015 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
8016 (dwarf2_frame_objfile_data): Add comment.
8017 (find_comp_unit, set_comp_unit): New functions.
8018 (dwarf2_frame_find_fde): Use find_comp_unit.
8019 (dwarf2_build_frame_info): Use set_comp_unit.
8020
8021 2020-02-12 Tom Tromey <tom@tromey.com>
8022
8023 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
8024 (comp_unit): Don't initialize objfile.
8025 (execute_cfa_program): Add text_offset parameter.
8026 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
8027 (dwarf2_frame_cache): Update.
8028 (dwarf2_build_frame_info): Don't set "objfile" member.
8029
8030 2020-02-12 Tom Tromey <tom@tromey.com>
8031
8032 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
8033 (decode_frame_entry): Likewise.
8034 (dwarf2_build_frame_info): Update.
8035
8036 2020-02-12 Tom Tromey <tom@tromey.com>
8037
8038 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
8039 (decode_frame_entry_1): Use the comp_unit obstack.
8040
8041 2020-02-12 Tom Tromey <tom@tromey.com>
8042
8043 * dwarf2/frame.c (struct comp_unit): Add initializers and
8044 constructor.
8045 (dwarf2_frame_objfile_data): Store a comp_unit.
8046 (dwarf2_frame_find_fde): Update.
8047 (dwarf2_build_frame_info): Use "new".
8048
8049 2020-02-12 Tom Tromey <tom@tromey.com>
8050
8051 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
8052 (dwarf2_fde_table): Typedef for std::vector.
8053 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
8054 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
8055 (decode_frame_entry): Update.
8056 (dwarf2_build_frame_info): Use "new".
8057
8058 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8059
8060 * arm-tdep.c (arm_gdbarch_init): Update.
8061 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
8062 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
8063 have_neon, is_m>: Change to bool.
8064
8065 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8066
8067 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
8068
8069 2020-02-12 Tom Tromey <tom@tromey.com>
8070
8071 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
8072
8073 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
8074
8075 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
8076 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
8077
8078 2020-02-11 Tom Tromey <tom@tromey.com>
8079
8080 * psymtab.h: Update comment.
8081
8082 2020-02-11 Tom Tromey <tom@tromey.com>
8083
8084 * gdb_obstack.h (struct auto_obstack): Use
8085 DISABLE_COPY_AND_ASSIGN.
8086
8087 2020-02-11 Tom Tromey <tom@tromey.com>
8088
8089 * dwarf2/frame.h (struct objfile): Don't forward declare.
8090
8091 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8092
8093 * cris-tdep.c (cris_supply_gregset): Change signature to match
8094 what struct regset expects.
8095 (cris_regset): New struct.
8096 (fetch_core_registers): Remove.
8097 (cris_iterate_over_regset_sections): New function.
8098 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
8099 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
8100
8101 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8102
8103 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
8104 registers.
8105
8106 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8107
8108 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
8109
8110 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8111
8112 * configure: Re-generate.
8113
8114 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8115
8116 * configure: Re-generate.
8117
8118 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8119
8120 * acinclude: Update warning.m4 path.
8121 * warning.m4: Move to gdbsupport.
8122
8123 2020-02-11 Tom Tromey <tromey@adacore.com>
8124
8125 * remote.c (remote_console_output): Update.
8126 * printcmd.c (printf_command): Update.
8127 * event-loop.c (gdb_wait_for_event): Update.
8128 * linux-nat.c (sigchld_handler): Update.
8129 * remote-sim.c (gdb_os_write_stdout): Update.
8130 (gdb_os_flush_stdout): Update.
8131 (gdb_os_flush_stderr): Update.
8132 (gdb_os_write_stderr): Update.
8133 * exceptions.c (print_exception): Update.
8134 * remote-fileio.c (remote_fileio_func_read): Update.
8135 (remote_fileio_func_write): Update.
8136 * tui/tui.c (tui_enable): Update.
8137 * tui/tui-interp.c (tui_interp::init): Update.
8138 * utils.c (init_page_info): Update.
8139 (putchar_unfiltered, fputc_unfiltered): Update.
8140 (gdb_flush): Update.
8141 (emit_style_escape): Update.
8142 (flush_wrap_buffer, fputs_maybe_filtered): Update.
8143 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
8144 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
8145 (stderr_file::write): Update.
8146 (stderr_file::puts): Update.
8147 * ui-file.h (ui_file_isatty, ui_file_write)
8148 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
8149 (ui_file_puts): Don't declare.
8150
8151 2020-02-10 Tom de Vries <tdevries@suse.de>
8152
8153 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
8154 sentinel to char *.
8155
8156 2020-02-09 Tom de Vries <tdevries@suse.de>
8157
8158 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
8159 filename if it matches "<artificial>".
8160
8161 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
8162
8163 * windows-tdep.c (struct enum_value_name): New struct.
8164 (create_enum): New function.
8165 (windows_get_siginfo_type): Create and use enum types.
8166
8167 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
8168
8169 * NEWS: Mention $_siginfo support for Windows.
8170 * windows-nat.c (handle_exception): Set siginfo_er.
8171 (windows_nat_target::mourn_inferior): Reset siginfo_er.
8172 (windows_xfer_siginfo): New function.
8173 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
8174 * windows-tdep.c (struct windows_gdbarch_data): New struct.
8175 (init_windows_gdbarch_data): New function.
8176 (get_windows_gdbarch_data): New function.
8177 (windows_get_siginfo_type): New function.
8178 (windows_init_abi): Register windows_get_siginfo_type.
8179 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
8180
8181 2020-02-08 Tom Tromey <tom@tromey.com>
8182
8183 * dwarf2/read.c (class cutu_reader) <cutu_reader,
8184 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
8185 <keep>: Declare method.
8186 <m_keep>: Remove member.
8187 <~cutu_reader>: Remove.
8188 (cutu_reader::init_tu_and_read_dwo_dies): Update.
8189 (cutu_reader::cutu_reader): Update.
8190 (cutu_reader::keep): Rename from ~cutu_reader.
8191 (process_psymtab_comp_unit, build_type_psymtabs_1)
8192 (process_skeletonless_type_unit, load_partial_comp_unit)
8193 (load_full_comp_unit, dwarf2_read_addr_index)
8194 (read_signatured_type): Update.
8195
8196 2020-02-08 Tom Tromey <tom@tromey.com>
8197
8198 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
8199 "want_partial_unit" parameter.
8200 (process_psymtab_comp_unit): Change want_partial_unit to bool.
8201 Inline check for DW_TAG_partial_unit.
8202 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
8203
8204 2020-02-08 Tom Tromey <tom@tromey.com>
8205
8206 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
8207 read.c.
8208 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
8209 read.c.
8210
8211 2020-02-08 Tom Tromey <tom@tromey.com>
8212
8213 * dwarf2/read.c (read_address): Move to comp-unit.c.
8214 (dwarf2_rnglists_process, dwarf2_ranges_process)
8215 (read_attribute_value, dwarf_decode_lines_1)
8216 (var_decode_location, decode_locdesc): Update.
8217 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
8218 read.c. Remove "cu" parameter.
8219 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
8220 method.
8221
8222 2020-02-08 Tom Tromey <tom@tromey.com>
8223
8224 * dwarf2/read.c (read_attribute_value, read_indirect_string)
8225 (read_indirect_line_string): Update.
8226 * dwarf2/comp-unit.c (read_offset): Remove.
8227 (read_comp_unit_head): Update.
8228 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
8229 method.
8230 (read_offset): Don't declare.
8231
8232 2020-02-08 Tom Tromey <tom@tromey.com>
8233
8234 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
8235 * dwarf2/read.c (struct comp_unit_head): Move to
8236 dwarf2/comp-unit.h.
8237 (enum class rcuh_kind): Move to comp-unit.h.
8238 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
8239 (read_comp_unit_head, error_check_comp_unit_head)
8240 (read_and_check_comp_unit_head): Move to comp-unit.c.
8241 (read_offset, dwarf_unit_type_name): Likewise.
8242 (create_debug_type_hash_table, read_cutu_die_from_dwo)
8243 (cutu_reader::cutu_reader, read_call_site_scope)
8244 (find_partial_die, follow_die_offset): Update.
8245 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
8246
8247 2020-02-08 Tom Tromey <tom@tromey.com>
8248
8249 * dwarf2/read.c (read_offset_1): Move to leb.c.
8250 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
8251 (dwarf_decode_macro_bytes): Update.
8252 * dwarf2/leb.c (read_offset): Rename; move from read.c.
8253 * dwarf2/leb.h (read_offset): Declare.
8254
8255 2020-02-08 Tom Tromey <tom@tromey.com>
8256
8257 * dwarf2/read.c (dwarf2_section_size): Remove.
8258 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
8259 Update.
8260 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
8261
8262 2020-02-08 Tom Tromey <tom@tromey.com>
8263
8264 * dwarf2/read.c (read_initial_length): Move to leb.c.
8265 * dwarf2/leb.h (read_initial_length): Declare.
8266 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
8267 handle_nonstd parameter.
8268 * dwarf2/frame.c (read_initial_length): Remove.
8269 (decode_frame_entry_1): Update.
8270
8271 2020-02-08 Tom Tromey <tom@tromey.com>
8272
8273 * dwarf2/loc.c (dwarf2_find_location_expression)
8274 (dwarf_evaluate_loc_desc::get_tls_address)
8275 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
8276 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
8277 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
8278 (dwarf2_compile_property_to_c)
8279 (dwarf2_loc_desc_get_symbol_read_needs)
8280 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
8281 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
8282 (loclist_describe_location, loclist_tracepoint_var_ref)
8283 (loclist_generate_c_location): Update.
8284 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
8285 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
8286 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
8287 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
8288 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
8289 (dwarf2_per_cu_data::addr_size)
8290 (dwarf2_per_cu_data::ref_addr_size)
8291 (dwarf2_per_cu_data::text_offset)
8292 (dwarf2_per_cu_data::addr_type): Now methods.
8293 (per_cu_header_read_in): Make per_cu "const".
8294 (dwarf2_version): Remove.
8295 (dwarf2_per_cu_data::int_type): Now a method.
8296 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
8297 (set_die_type, read_array_type, read_subrange_index_type)
8298 (read_tag_string_type, read_subrange_type): Update.
8299 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
8300 offset_size, ref_addr_size, text_offset, addr_type, version,
8301 objfile, int_type, addr_sized_int_type>: Declare methods.
8302
8303 2020-02-08 Tom Tromey <tom@tromey.com>
8304
8305 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
8306 Move earlier.
8307
8308 2020-02-08 Tom Tromey <tom@tromey.com>
8309
8310 * dwarf2/read.h (dwarf_line_debug): Declare.
8311 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
8312 * dwarf2/read.c: Move line_header code to new files.
8313 (dwarf_line_debug): No longer static.
8314 * dwarf2/line-header.c: New file.
8315 * dwarf2/line-header.h: New file.
8316
8317 2020-02-08 Tom Tromey <tom@tromey.com>
8318
8319 * dwarf2/read.c (struct line_header) <file_full_name,
8320 file_file_name>: Return unique_xmalloc_ptr.
8321 (line_header::file_file_name): Update.
8322 (line_header::file_full_name): Update.
8323 (dw2_get_file_names_reader): Update.
8324 (macro_start_file): Update.
8325
8326 2020-02-08 Tom Tromey <tom@tromey.com>
8327
8328 * dwarf2/read.c (struct line_header) <file_full_name,
8329 file_file_name>: Declare methods.
8330 (dw2_get_file_names_reader): Update.
8331 (file_file_name): Now a method.
8332 (file_full_name): Likewise.
8333 (macro_start_file): Update.
8334
8335 2020-02-08 Tom Tromey <tom@tromey.com>
8336
8337 * dwarf2/read.c (dwarf_always_disassemble)
8338 (show_dwarf_always_disassemble): Move to loc.c.
8339 (_initialize_dwarf2_read): Move "always-disassemble" registration
8340 to loc.c.
8341 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
8342 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
8343 static.
8344 (show_dwarf_always_disassemble): Move from read.c.
8345 (_initialize_dwarf2loc): Move always-disassemble from read.c.
8346
8347 2020-02-08 Tom Tromey <tom@tromey.com>
8348
8349 * dwarf2/read.c (~dwarf2_per_objfile): Update.
8350 (create_quick_file_names_table): Return htab_up.
8351 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
8352 Update.
8353 * dwarf2/read.h (struct dwarf2_per_objfile)
8354 <quick_file_names_table>: Now htab_up.
8355
8356 2020-02-08 Tom Tromey <tom@tromey.com>
8357
8358 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
8359
8360 2020-02-08 Tom Tromey <tom@tromey.com>
8361
8362 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
8363 Rewrite.
8364 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
8365 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
8366 (abbrev_table::abbrev_table): No longer inline.
8367 (ABBREV_HASH_SIZE): Remove.
8368 (abbrev_table::m_abbrevs): Now an htab_up.
8369
8370 2020-02-08 Tom Tromey <tom@tromey.com>
8371
8372 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
8373 (cutu_reader): Update.
8374 (build_type_psymtabs_1): Update.
8375 * dwarf2/abbrev.c (abbrev_table::read): Rename.
8376 (abbrev_table::alloc_abbrev): Update.
8377 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
8378 (abbrev_table::read): New static method, renamed from
8379 abbrev_table_read_table.
8380 (abbrev_table::alloc_abbrev)
8381 (abbrev_table::add_abbrev): Now private.
8382 (abbrev_table::abbrev_table): Now private.
8383 (abbrev_table::m_abbrev_obstack): Now private. Rename.
8384
8385 2020-02-08 Tom Tromey <tom@tromey.com>
8386
8387 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
8388 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
8389 htab_up.
8390
8391 2020-02-08 Tom Tromey <tom@tromey.com>
8392
8393 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
8394 htab_up.
8395 (lookup_dwo_unit_in_dwp): Update.
8396 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
8397 on obstack.
8398
8399 2020-02-08 Tom Tromey <tom@tromey.com>
8400
8401 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
8402 obstack.
8403
8404 2020-02-08 Tom Tromey <tom@tromey.com>
8405
8406 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
8407 line_header_hash.
8408 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
8409 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
8410 Change type to htab_up.
8411
8412 2020-02-08 Tom Tromey <tom@tromey.com>
8413
8414 * dwarf2/read.c (allocate_type_unit_groups_table): Return
8415 htab_up. Don't allocate on obstack.
8416 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
8417 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
8418 Change type to htab_up.
8419
8420 2020-02-08 Tom Tromey <tom@tromey.com>
8421
8422 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
8423 Change type to htab_up.
8424 * dwarf2/read.c (create_signatured_type_table_from_index)
8425 (create_signatured_type_table_from_debug_names)
8426 (create_all_type_units, add_type_unit)
8427 (lookup_dwo_signatured_type, lookup_signatured_type)
8428 (process_skeletonless_type_unit): Update.
8429 (create_debug_type_hash_table, create_debug_types_hash_table):
8430 Change type of types_htab.
8431 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
8432 htab_up. Don't allocate on obstack.
8433 (create_cus_hash_table): Change type of cus_htab parameter.
8434 (struct dwo_file) <cus, tus>: Now htab_up.
8435 (lookup_dwo_signatured_type, lookup_dwo_cutu)
8436 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
8437 (queue_and_load_all_dwo_tus): Update.
8438 * dwarf2/index-write.c (write_gdbindex): Update.
8439 (write_debug_names): Update.
8440
8441 2020-02-08 Tom Tromey <tom@tromey.com>
8442
8443 * dwarf2/read.h (struct dwarf2_queue_item): Move from
8444 dwarf2/read.c. Remove "next" member. Add constructor ntad
8445 destructor.
8446 (struct dwarf2_per_objfile) <queue>: New member.
8447 * dwarf2/read.c (struct dwarf2_queue_item): Move to
8448 dwarf2/read.h.
8449 (dwarf2_queue, dwarf2_queue_tail): Remove.
8450 (class dwarf2_queue_guard): Add parameter to constructor. Use
8451 DISABLE_COPY_AND_ASSIGN.
8452 <m_per_objfile>: New member.
8453 <~dwarf2_queue_guard>: Rewrite.
8454 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
8455 Update.
8456 (~dwarf2_queue_item): New.
8457
8458 2020-02-08 Tom Tromey <tom@tromey.com>
8459
8460 * dwarf2/read.c (struct die_info) <has_children>: New member.
8461 (dw2_get_file_names_reader): Remove has_children.
8462 (dw2_get_file_names): Update.
8463 (read_cutu_die_from_dwo): Remove has_children.
8464 (cutu_reader::init_tu_and_read_dwo_dies)
8465 (cutu_reader::cutu_reader): Update.
8466 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
8467 Remove has_children.
8468 (build_type_psymtabs_1, process_skeletonless_type_unit)
8469 (load_partial_comp_unit, load_full_comp_unit): Update.
8470 (create_dwo_cu_reader): Remove has_children.
8471 (create_cus_hash_table, read_die_and_children): Update.
8472 (read_full_die_1,read_full_die): Remove has_children.
8473 (read_signatured_type): Update.
8474 (class cutu_reader) <has_children>: Remove.
8475
8476 2020-02-08 Tom Tromey <tom@tromey.com>
8477
8478 * dwarf2/expr.c: Rename from dwarf2expr.c.
8479 * dwarf2/expr.h: Rename from dwarf2expr.h.
8480 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
8481 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
8482 * dwarf2/frame.c: Rename from dwarf2-frame.c.
8483 * dwarf2/frame.h: Rename from dwarf2-frame.h.
8484 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
8485 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
8486 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
8487 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
8488 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
8489 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
8490 * dwarf2/loc.c: Rename from dwarf2loc.c.
8491 * dwarf2/loc.h: Rename from dwarf2loc.h.
8492 * dwarf2/read.c: Rename from dwarf2read.c.
8493 * dwarf2/read.h: Rename from dwarf2read.h.
8494 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
8495 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
8496 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
8497 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
8498 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
8499 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
8500 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
8501 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
8502 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
8503 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
8504 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
8505 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
8506 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
8507 Update.
8508 * Makefile.in (COMMON_SFILES): Update.
8509 (HFILES_NO_SRCDIR): Update.
8510
8511 2020-02-08 Tom Tromey <tom@tromey.com>
8512
8513 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
8514 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
8515
8516 2020-02-08 Tom Tromey <tom@tromey.com>
8517
8518 * dwarf2read.h (struct die_info): Don't declare.
8519
8520 2020-02-08 Tom Tromey <tom@tromey.com>
8521
8522 * dwarf2read.h (die_info_ptr): Remove typedef.
8523
8524 2020-02-08 Tom Tromey <tom@tromey.com>
8525
8526 * dwarf2read.c (read_call_site_scope)
8527 (handle_data_member_location, dwarf2_add_member_fn)
8528 (mark_common_block_symbol_computed, read_common_block)
8529 (attr_to_dynamic_prop, partial_die_info::read)
8530 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
8531 (dwarf2_symbol_mark_computed, set_die_type): Update.
8532 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
8533 method.
8534 (attr_form_is_block): Don't declare.
8535 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
8536
8537 2020-02-08 Tom Tromey <tom@tromey.com>
8538
8539 * dwarf2read.c (dwarf2_find_base_address, )
8540 (read_call_site_scope, rust_containing_type)
8541 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
8542 (handle_data_member_location, dwarf2_add_member_fn)
8543 (get_alignment, read_structure_type, process_structure_scope)
8544 (mark_common_block_symbol_computed, read_common_block)
8545 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
8546 (partial_die_info::read, read_attribute_value, new_symbol)
8547 (lookup_die_type, dwarf2_get_ref_die_offset)
8548 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
8549 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
8550 (dwarf2_symbol_mark_computed): Update.
8551 * dwarf2/attribute.h (struct attribute) <value_as_address,
8552 form_is_section_offset, form_is_constant, form_is_ref>: Declare
8553 methods.
8554 (value_as_address, attr_form_is_section_offset)
8555 (attr_form_is_constant, attr_form_is_ref): Don't declare.
8556 * dwarf2/attribute.c (attribute::value_as_address)
8557 (attribute::form_is_section_offset, attribute::form_is_constant)
8558 (attribute::form_is_ref): Now methods.
8559
8560 2020-02-08 Tom Tromey <tom@tromey.com>
8561
8562 * dwarf2read.c (struct attribute, DW_STRING)
8563 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
8564 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
8565 (attr_form_is_block, attr_form_is_section_offset)
8566 (attr_form_is_constant, attr_form_is_ref): Move.
8567 * dwarf2/attribute.h: New file.
8568 * dwarf2/attribute.c: New file, from dwarf2read.c.
8569 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
8570
8571 2020-02-08 Tom Tromey <tom@tromey.com>
8572
8573 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
8574 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
8575 Move.
8576 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
8577 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
8578 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
8579 abbrev.c.
8580 * dwarf2/abbrev.h: New file.
8581 * dwarf2/abbrev.c: New file, from dwarf2read.c.
8582 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
8583
8584 2020-02-08 Tom Tromey <tom@tromey.com>
8585
8586 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
8587 (dwarf2_section_size, dwarf2_get_section_info)
8588 (create_signatured_type_table_from_debug_names)
8589 (create_addrmap_from_aranges, read_debug_names_from_section)
8590 (get_gdb_index_contents_from_section, read_comp_unit_head)
8591 (error_check_comp_unit_head, read_abbrev_offset)
8592 (create_debug_type_hash_table, init_cu_die_reader)
8593 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
8594 (read_comp_units_from_section, create_cus_hash_table)
8595 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
8596 (create_dwp_v2_section, dwarf2_rnglists_process)
8597 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
8598 (abbrev_table_read_table, read_indirect_string_at_offset_from)
8599 (read_indirect_string_from_dwz, read_addr_index_1)
8600 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
8601 (dwarf_decode_macro_bytes, dwarf_decode_macros)
8602 (fill_in_loclist_baton): Update.
8603 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
8604 get_containing_section, get_bfd_owner, get_bfd_section,
8605 get_file_name, get_id, get_flags, empty, read>: Declare methods.
8606 (dwarf2_read_section, get_section_name, get_section_file_name)
8607 (get_containing_section, get_section_bfd_owner)
8608 (get_section_bfd_section, get_section_name, get_section_file_name)
8609 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
8610 declare.
8611 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
8612 (dwarf2_section_info::get_bfd_owner)
8613 (dwarf2_section_info::get_bfd_section)
8614 (dwarf2_section_info::get_name)
8615 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
8616 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
8617 (dwarf2_section_info::read): Now methods.
8618 * dwarf-index-write.c (class debug_names): Update.
8619
8620 2020-02-08 Tom Tromey <tom@tromey.com>
8621
8622 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
8623 Move to dwarf2/section.h.
8624 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
8625 (get_section_bfd_section, get_section_name)
8626 (get_section_file_name, get_section_id, get_section_flags)
8627 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
8628 dwarf2/section.c.
8629 * dwarf2/section.h: New file.
8630 * dwarf2/section.c: New file, from dwarf2read.c.
8631 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
8632
8633 2020-02-08 Tom Tromey <tom@tromey.com>
8634
8635 * dwarf2read.h (read_unsigned_leb128): Don't declare.
8636 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
8637 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
8638 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
8639 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
8640 * dwarf2/leb.h: New file, from dwarf2read.c.
8641 * dwarf2/leb.c: New file, from dwarf2read.c.
8642 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
8643 Remove.
8644 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
8645 (COMMON_SFILES): Add dwarf2/leb.c.
8646
8647 2020-02-08 Joel Brobecker <brobecker@adacore.com>
8648
8649 GDB 9.1 released.
8650
8651 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
8652
8653 PR gdb/25190:
8654 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
8655 * gdb/remote.c (remote_console_output): Update.
8656 * gdb/ui-file.c (fputs_unfiltered): Rename to...
8657 (ui_file_puts): ...this.
8658 * gdb/ui-file.h (ui_file_puts): Add declaration.
8659 * gdb/utils.c (emit_style_escape): Update.
8660 (flush_wrap_buffer): Update.
8661 (fputs_maybe_filtered): Update.
8662 (fputs_unfiltered): Add function.
8663
8664 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
8665
8666 * gdb/event-loop.c (gdb_wait_for_event): Update.
8667 * gdb/printcmd.c (printf_command): Update.
8668 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
8669 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
8670 (gdb_os_flush_stderr): Update.
8671 * gdb/remote.c (remote_console_output): Update.
8672 * gdb/ui-file.c (gdb_flush): Rename to...
8673 (ui_file_flush): ...this.
8674 (stderr_file::write): Update.
8675 (stderr_file::puts): Update.
8676 * gdb/ui-file.h (gdb_flush): Rename to...
8677 (ui_file_flush): ...this.
8678 * gdb/utils.c (gdb_flush): Add function.
8679 * gdb/utils.h (gdb_flush): Add declaration.
8680
8681 2020-02-07 Tom Tromey <tromey@adacore.com>
8682
8683 PR breakpoints/24915:
8684 * source.c (find_and_open_source): Do not check basenames_may_differ.
8685
8686 2020-02-07 Tom Tromey <tom@tromey.com>
8687
8688 * README: Update gdbserver documentation.
8689 * gdbserver: Move to top level.
8690 * configure.tgt (build_gdbserver): Remove.
8691 * configure.ac: Remove --enable-gdbserver.
8692 * configure: Rebuild.
8693 * Makefile.in (distclean): Don't mention gdbserver.
8694
8695 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
8696
8697 * source-cache.c (source_cache::ensure): Surround
8698 get_plain_source_lines with a try/catch.
8699 (source_cache::get_line_charpos): Get rid of try/catch
8700 and only check for the return value of "ensure".
8701 * tui/tui-source.c (tui_source_window::set_contents):
8702 Simplify "nlines" calculation.
8703
8704 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
8705
8706 * MAINTAINERS (Write After Approval): Add myself.
8707
8708 2020-02-05 Christian Biesinger <cbiesinger@google.com>
8709
8710 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
8711 function call.
8712
8713 2020-02-05 Christian Biesinger <cbiesinger@google.com>
8714
8715 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
8716
8717 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
8718
8719 * nat/riscv-linux-tdesc.h: New file.
8720 * nat/riscv-linux-tdesc.c: New file, taking code from...
8721 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
8722 ... here.
8723 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
8724 NATDEPFILES.
8725
8726 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
8727
8728 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
8729 we don't set the fake simulator ptid to the null_ptid.
8730
8731 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
8732
8733 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
8734 * gdbthread.h (class thread_info) <resumed>: Likewise.
8735 * infrun.c (resume_1): Likewise.
8736 (proceed): Likewise.
8737 (infrun_thread_stop_requested): Likewise.
8738 (stop_all_threads): Likewise.
8739 (handle_inferior_event): Likewise.
8740 (restart_threads): Likewise.
8741 (finish_step_over): Likewise.
8742 (keep_going_stepped_thread): Likewise.
8743 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
8744 (linux_handle_extended_wait): Likewise.
8745 * record-btrace.c (get_thread_current_frame_id): Likewise.
8746 * record-full.c (record_full_wait_1): Likewise.
8747 * remote.c (remote_target::process_initial_stop_replies): Likewise.
8748 * target.c (target_resume): Likewise.
8749 * thread.c (set_running_thread): Likewise.
8750
8751 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8752
8753 * f-valprint.c (f77_print_array_1): Changed datatype of index
8754 variable to LONGEST from int to enable it to contain bound
8755 values correctly.
8756
8757 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
8758
8759 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
8760 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
8761 offsets according to FLEN determined.
8762 (riscv_linux_nat_target::read_description): Determine FLEN
8763 dynamically.
8764 (riscv_linux_nat_target::fetch_registers): Size regset buffer
8765 according to FLEN determined.
8766 (riscv_linux_nat_target::store_registers): Likewise.
8767
8768 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
8769
8770 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
8771 when reg->group is empty and reggroup is not.
8772
8773 2020-01-31 Tom Tromey <tromey@adacore.com>
8774
8775 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
8776 Call beneath target's mourn_inferior after unpushing.
8777
8778 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
8779
8780 PR tui/9765
8781 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
8782 have enough lines to fill the screen, still return the lowest
8783 address we found.
8784
8785 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
8786
8787 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
8788 '-', '<', and '>' commands.
8789
8790 2020-01-29 Pedro Alves <palves@redhat.com>
8791 Sergio Durigan Junior <sergiodj@redhat.com>
8792
8793 * infcmd.c (construct_inferior_arguments): Assert that
8794 'argc' is greater than 0.
8795
8796 2020-01-29 Luis Machado <luis.machado@linaro.org>
8797
8798 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
8799 (BRK_INSN_MASK): Define to 0xd4200000.
8800 (aarch64_program_breakpoint_here_p): New function.
8801 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
8802 * arch-utils.c (default_program_breakpoint_here_p): Moved from
8803 breakpoint.c.
8804 * arch-utils.h (default_program_breakpoint_here_p): Moved from
8805 breakpoint.h
8806 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
8807 call gdbarch_program_breakpoint_here_p.
8808 (program_breakpoint_here): Moved to arch-utils.c, renamed to
8809 default_program_breakpoint_here_p, changed return type to bool and
8810 simplified.
8811 * breakpoint.h (program_breakpoint_here): Moved prototype to
8812 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
8813 return type to bool.
8814 * gdbarch.c: Regenerate.
8815 * gdbarch.h: Regenerate.
8816 * gdbarch.sh (program_breakpoint_here_p): New method.
8817 * infrun.c (handle_signal_stop): Call
8818 gdbarch_program_breakpoint_here_p.
8819
8820 2020-01-26 Tom Tromey <tom@tromey.com>
8821
8822 * ctfread.c (struct ctf_fp_info): Reindent.
8823 (_initialize_ctfread): Remove.
8824
8825 2020-01-26 Tom Tromey <tom@tromey.com>
8826
8827 * psymtab.c (partial_map_expand_apply)
8828 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
8829 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
8830 (psym_print_stats, psym_expand_symtabs_for_function)
8831 (psym_map_symbol_filenames, psym_map_matching_symbols)
8832 (psym_expand_symtabs_matching)
8833 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
8834 (maintenance_check_psymtabs): Use new methods.
8835 * psympriv.h (struct partial_symtab) <readin_p,
8836 get_compunit_symtab>: New methods.
8837 <readin, compunit_symtab>: Remove members.
8838 (struct standard_psymtab): New.
8839 (struct legacy_psymtab): Derive from standard_psymtab.
8840 * dwarf2read.h (struct dwarf2_psymtab): Derive from
8841 standard_psymtab.
8842 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
8843
8844 2020-01-26 Tom Tromey <tom@tromey.com>
8845
8846 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
8847 read_dependencies. Add assert.
8848 * psymtab.c (partial_symtab::read_dependencies): New method.
8849 * psympriv.h (struct partial_symtab) <read_dependencies>: New
8850 method.
8851 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
8852 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
8853 read_dependencies.
8854 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
8855 Add assert.
8856
8857 2020-01-26 Tom Tromey <tom@tromey.com>
8858
8859 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
8860 Call expand_psymtab.
8861 (xcoff_read_symtab): Call expand_psymtab.
8862 (xcoff_start_psymtab, xcoff_end_psymtab): Set
8863 legacy_expand_psymtab.
8864 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
8865 method.
8866 (struct legacy_psymtab) <expand_psymtab>: Implement.
8867 <legacy_expand_psymtab>: New member.
8868 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
8869 (parse_partial_symbols): Set legacy_expand_psymtab.
8870 (psymtab_to_symtab_1): Change argument order. Call
8871 expand_psymtab.
8872 (new_psymtab): Set legacy_expand_psymtab.
8873 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
8874 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
8875 expand_psymtab.
8876 (dwarf2_psymtab::expand_psymtab): Rename from
8877 psymtab_to_symtab_1. Call expand_psymtab.
8878 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
8879 (dbx_end_psymtab): Likewise.
8880 (dbx_psymtab_to_symtab_1): Change argument order. Call
8881 expand_psymtab.
8882 (dbx_read_symtab): Call expand_psymtab.
8883 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
8884 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
8885 (ctf_psymtab::read_symtab): Call expand_psymtab.
8886
8887 2020-01-26 Tom Tromey <tom@tromey.com>
8888
8889 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
8890 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
8891 messages.
8892 * mdebugread.c (mdebug_read_symtab): Remove prints.
8893 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
8894 assert.
8895 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
8896
8897 2020-01-26 Tom Tromey <tom@tromey.com>
8898
8899 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
8900 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
8901 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
8902 legacy_symtab.
8903 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
8904 * psymtab.c (psymtab_to_symtab): Call method.
8905 (dump_psymtab): Update.
8906 * psympriv.h (struct partial_symtab): Add virtual destructor.
8907 <read_symtab>: New method.
8908 (struct legacy_symtab): New.
8909 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
8910 (struct pst_map) <pst>: Now a legacy_psymtab.
8911 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
8912 (new_psymtab): Use legacy_psymtab.
8913 * dwarf2read.h (struct dwarf2_psymtab): New.
8914 (struct dwarf2_per_cu_data) <psymtab>: Use it.
8915 * dwarf2read.c (dwarf2_create_include_psymtab)
8916 (dwarf2_build_include_psymtabs, create_type_unit_group)
8917 (create_partial_symtab, process_psymtab_comp_unit_reader)
8918 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
8919 (set_partial_user): Use dwarf2_psymtab.
8920 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
8921 (psymtab_to_symtab_1, process_full_comp_unit)
8922 (process_full_type_unit, dwarf2_ranges_read)
8923 (dwarf2_get_pc_bounds, psymtab_include_file_name)
8924 (dwarf_decode_lines): Use dwarf2_psymtab.
8925 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
8926 (add_address_entry_worker, write_one_signatured_type)
8927 (recursively_count_psymbols, recursively_write_psymbols)
8928 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
8929 (write_debug_names): Likewise.
8930 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
8931 <pst>: Now a legacy_psymtab.
8932 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
8933 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
8934 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
8935 * ctfread.c (struct ctf_psymtab): New.
8936 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
8937 ctf_psymtab.
8938 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
8939 (create_partial_symtab): Return a ctf_psymtab.
8940 (scan_partial_symbols): Update.
8941
8942 2020-01-26 Tom Tromey <tom@tromey.com>
8943
8944 * xcoffread.c (xcoff_start_psymtab): Use new.
8945 * psymtab.c (partial_symtab::partial_symtab): New constructor,
8946 renamed from start_psymtab_common.
8947 * psympriv.h (struct partial_symtab): Add new constructor.
8948 (start_psymtab_common): Don't declare.
8949 * mdebugread.c (parse_partial_symbols): Use new.
8950 * dwarf2read.c (create_partial_symtab): Use new.
8951 * dbxread.c (start_psymtab): Use new.
8952 * ctfread.c (create_partial_symtab): Use new.
8953
8954 2020-01-26 Tom Tromey <tom@tromey.com>
8955
8956 * xcoffread.c (xcoff_end_psymtab): Use new.
8957 * psymtab.c (start_psymtab_common): Use new.
8958 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
8959 Update.
8960 * psympriv.h (struct partial_symtab): Add parameters to
8961 constructor. Don't inline.
8962 (allocate_psymtab): Don't declare.
8963 * mdebugread.c (new_psymtab): Use new.
8964 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
8965 * dbxread.c (dbx_end_psymtab): Use new.
8966
8967 2020-01-26 Tom Tromey <tom@tromey.com>
8968
8969 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
8970 allocate_psymtab. Update documentation.
8971 * psymtab.c (psymtab_storage::install_psymtab): Rename from
8972 allocate_psymtab. Do not use new.
8973 (allocate_psymtab): Use new. Update.
8974
8975 2020-01-26 Tom Tromey <tom@tromey.com>
8976
8977 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
8978 * psymtab.c (psym_print_stats): Update.
8979 * psympriv.h (struct partial_symtab) <readin,
8980 psymtabs_addrmap_supported, anonymous>: Now bool.
8981 * mdebugread.c (psymtab_to_symtab_1): Update.
8982 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
8983 (build_type_psymtabs_reader, psymtab_to_symtab_1)
8984 (process_full_comp_unit, process_full_type_unit): Update.
8985 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
8986 * ctfread.c (psymtab_to_symtab): Update.
8987
8988 2020-01-26 Tom Tromey <tom@tromey.com>
8989
8990 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
8991 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
8992 * psymtab.c (psymtab_storage): Delete psymtabs.
8993 (psymtab_storage::allocate_psymtab): Use new.
8994 (psymtab_storage::discard_psymtab): Use delete.
8995 * psympriv.h (struct partial_symtab): Add constructor and
8996 initializers.
8997
8998 2020-01-26 Tom Tromey <tom@tromey.com>
8999
9000 * machoread.c: Do not include psympriv.h.
9001
9002 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9003
9004 * NEWS: Mention the new option and the set/show commands.
9005
9006 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9007
9008 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
9009 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
9010 (validate_exec_file): New variables, enums, functions.
9011 (exec_file_locate_attach, print_section_info): Style the filenames.
9012 (_initialize_exec): Install show_exec_file_mismatch_command and
9013 set_exec_file_mismatch_command.
9014 * gdbcore.h (validate_exec_file): Declare.
9015 * infcmd.c (attach_command): Call validate_exec_file.
9016 * remote.c ( remote_target::remote_add_inferior): Likewise.
9017
9018 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9019
9020 * frame.c (find_frame_sal): Move call to get_next_frame into more
9021 inner scope.
9022 * inline-frame.c (inilne_state) <inline_state>: Update argument
9023 types.
9024 (inilne_state) <skipped_symbol>: Rename to...
9025 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
9026 (skip_inline_frames): Build vector of skipped symbols and use this
9027 to reate the inline_state.
9028 (inline_skipped_symbol): Add a comment and some assertions, fetch
9029 skipped symbol from the list.
9030
9031 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9032
9033 * buildsym.c (lte_is_less_than): Delete.
9034 (buildsym_compunit::end_symtab_with_blockvector): Create local
9035 lambda function to sort line table entries, and use
9036 std::stable_sort instead of std::sort.
9037 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
9038 markers when looking for a previous line.
9039
9040 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9041
9042 * dwarf2read.c (lnp_state_machine::record_line): Include
9043 end_sequence parameter in debug print out. Record the line if we
9044 are at an end_sequence marker even if it's not the start of a
9045 statement.
9046 * symmisc.c (maintenance_print_one_line_table): Print end of
9047 sequence markers with 'END' not '0'.
9048
9049 2020-01-24 Pedro Alves <palves@redhat.com>
9050
9051 PR gdb/25410
9052 * thread.c (scoped_restore_current_thread::restore): Use
9053 switch_to_inferior_no_thread.
9054 * exec.c: Include "progspace-and-thread.h".
9055 (add_target_sections, remove_target_sections):
9056 scoped_restore_current_pspace_and_thread instead of
9057 scoped_restore_current_thread.
9058 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
9059 and aspace to the inferior before calling clone_program_space.
9060 Remove stale comment.
9061
9062 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9063
9064 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
9065 (arm_netbsd_nat_target::fetch_registers): ...this.
9066 (arm_nbsd_nat_target::store_registers): Rename to...
9067 (arm_netbsd_nat_target::store_registers): ...this.
9068
9069 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9070
9071 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
9072 register_t.
9073
9074 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9075
9076 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
9077 Update comment.
9078 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
9079 Likewise.
9080 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
9081 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
9082 the correct replacement (iterate_over_regset_sections).
9083 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
9084 Update comment.
9085
9086 2020-01-24 Graham Markall <graham.markall@embecosm.com>
9087
9088 PR gdb/23718
9089 * gdb/python/python.c (execute_gdb_command): Call
9090 async_enable_stdin in catch block.
9091
9092 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9093
9094 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
9095 SWITCH_THRU_ALL_UIS.
9096
9097 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9098
9099 PR tui/9765
9100 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
9101 comment, add extra parameter, and update to store previous symbol
9102 when appropriate.
9103 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
9104 add extra parameter.
9105 * tui/tui-disasm.c (tui_disassemble): Update header comment,
9106 remove unneeded parameter, add try/catch around gdb_print_insn,
9107 rewrite to add items to asm_lines vector.
9108 (tui_find_backward_disassembly_start_address): New function.
9109 (tui_find_disassembly_address): Updated throughout.
9110 (tui_disasm_window::set_contents): Update for changes to
9111 tui_disassemble.
9112 (tui_disasm_window::do_scroll_vertical): No need to adjust the
9113 number of lines to scroll.
9114
9115 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
9116
9117 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
9118 (SECT_OFF_DATA): Likewise.
9119 (SECT_OFF_RODATA): Likewise.
9120 (SECT_OFF_TEXT): Likewise.
9121 (SECT_OFF_BSS): Likewise.
9122 (struct objfile) <text_section_offset, data_section_offset>: New
9123 methods.
9124 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
9125 objfile::text_section_offset.
9126 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
9127 * coffread.c (coff_symtab_read): Likewise.
9128 (enter_linenos): Likewise.
9129 (process_coff_symbol): Likewise.
9130 * ctfread.c (get_objfile_text_range): Likewise.
9131 * dtrace-probe.c (dtrace_probe::get_relocated_address):
9132 Use objfile::data_section_offset.
9133 * dwarf2-frame.c (execute_cfa_program): Use
9134 objfile::text_section_offset.
9135 (dwarf2_frame_find_fde): Likewise.
9136 * dwarf2read.c (create_addrmap_from_index): Likewise.
9137 (create_addrmap_from_aranges): Likewise.
9138 (dw2_find_pc_sect_compunit_symtab): Likewise.
9139 (process_psymtab_comp_unit_reader): Likewise.
9140 (add_partial_symbol): Likewise.
9141 (add_partial_subprogram): Likewise.
9142 (process_full_comp_unit): Likewise.
9143 (read_file_scope): Likewise.
9144 (read_func_scope): Likewise.
9145 (read_lexical_block_scope): Likewise.
9146 (read_call_site_scope): Likewise.
9147 (dwarf2_rnglists_process): Likewise.
9148 (dwarf2_ranges_process): Likewise.
9149 (dwarf2_ranges_read): Likewise.
9150 (dwarf_decode_lines_1): Likewise.
9151 (new_symbol): Likewise.
9152 (dwarf2_fetch_die_loc_sect_off): Likewise.
9153 (dwarf2_per_cu_text_offset): Likewise.
9154 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
9155 * hppa-tdep.c (read_unwind_info): Likewise.
9156 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
9157 * psympriv.h (struct partial_symtab): Likewise.
9158 * psymtab.c (find_pc_sect_psymtab): Likewise.
9159 * solib-svr4.c (enable_break): Likewise.
9160 * stap-probe.c (relocate_address): Use
9161 objfile::data_section_offset.
9162 * xcoffread.c (enter_line_range): Use
9163 objfile::text_section_offset.
9164 (read_xcoff_symtab): Likewise.
9165
9166 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
9167
9168 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
9169 declaration to narrower scopes.
9170
9171 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
9172
9173 * darwin-nat.h (struct darwin_exception_msg, enum
9174 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
9175 Move up.
9176 (class darwin_nat_target) <wait_1, check_new_threads,
9177 decode_exception_message, decode_message, stop_inferior,
9178 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
9179 * darwin-nat.c (darwin_check_new_threads): Rename to...
9180 (darwin_nat_target::check_new_threads): ... this.
9181 (darwin_suspend_inferior_it): Remove.
9182 (darwin_decode_exception_message): Rename to...
9183 (darwin_nat_target::decode_exception_message): ... this.
9184 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
9185 (darwin_decode_message): Rename to...
9186 (darwin_nat_target::decode_message): ... this.
9187 (cancel_breakpoint): Rename to...
9188 (darwin_nat_target::cancel_breakpoint): ... this.
9189 (darwin_wait): Rename to...
9190 (darwin_nat_target::wait_1): ... this. Use range-based for loop
9191 instead of iterate_over_inferiors.
9192 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
9193 (darwin_stop_inferior): Rename to...
9194 (darwin_nat_target::stop_inferior): ... this.
9195 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
9196 (darwin_init_thread_list): Rename to...
9197 (darwin_nat_target::init_thread_list): ... this.
9198 (darwin_ptrace_him): Rename to...
9199 (darwin_nat_target::ptrace_him): ... this.
9200 (darwin_nat_target::create_inferior): Pass lambda function to
9201 fork_inferior.
9202 (darwin_nat_target::detach): Call stop_inferior instead of
9203 darwin_stop_inferior.
9204 * fork-inferior.h (fork_inferior): Change init_trace_fun
9205 parameter to gdb::function_view.
9206 * fork-inferior.c (fork_inferior): Likewise.
9207
9208 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
9209
9210 * i386-cygwin-tdep.c (core_process_module_section): Update.
9211 * windows-nat.c (struct lm_info_windows): Add text_offset.
9212 (windows_xfer_shared_libraries): Update.
9213 * windows-tdep.c (windows_xfer_shared_library):
9214 Add text_offset_cached argument.
9215 * windows-tdep.h (windows_xfer_shared_library): Update.
9216
9217 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9218
9219 * gdbarch.sh: Add declaration for _initialize_gdbarch.
9220
9221 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9222
9223 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
9224 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
9225 replace with range-based for.
9226 (gdbsim_interrupt_inferior): Remove.
9227 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
9228 with a range-based for. Inline code from
9229 gdbsim_interrupt_inferior.
9230
9231 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9232
9233 * infrun.c (proceed): Fix indentation.
9234
9235 2020-01-21 Tom Tromey <tromey@adacore.com>
9236
9237 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
9238 * python/python.c (python_extension_ops): Update.
9239 (gdbpy_colorize): New function.
9240 * python/lib/gdb/__init__.py (colorize): New function.
9241 * extension.h (ext_lang_colorize): Declare.
9242 * extension.c (ext_lang_colorize): New function.
9243 * extension-priv.h (struct extension_language_ops) <colorize>: New
9244 member.
9245 * cli/cli-style.c (_initialize_cli_style): Update help text.
9246
9247 2020-01-21 Luis Machado <luis.machado@linaro.org>
9248
9249 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
9250 <cond>: Change type to bool.
9251 (aarch64_displaced_step_b_cond): Update cond to use bool type.
9252 (aarch64_displaced_step_cb): Likewise.
9253 (aarch64_displaced_step_tb): Likewise.
9254
9255 2020-01-21 Luis Machado <luis.machado@linaro.org>
9256
9257 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
9258 output.
9259
9260 2020-01-21 Luis Machado <luis.machado@linaro.org>
9261
9262 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
9263 <pc_adjust>: Adjust the documentation.
9264 (aarch64_displaced_step_fixup): Check if PC really moved before
9265 adjusting it.
9266
9267 2020-01-19 Tom Tromey <tom@tromey.com>
9268
9269 * disasm.c (~gdb_disassembler): New destructor.
9270 (gdb_buffered_insn_length): Call disassemble_free_target.
9271 * disasm.h (class gdb_disassembler): Declare destructor. Use
9272 DISABLE_COPY_AND_ASSIGN.
9273
9274 2020-01-19 Tom Tromey <tom@tromey.com>
9275
9276 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
9277 (die_reader_func_ftype): Remove.
9278 (cutu_reader): New class.
9279 (dw2_get_file_names_reader): Remove "data" parameter.
9280 (dw2_get_file_names): Use cutu_reader.
9281 (create_debug_type_hash_table): Update.
9282 (read_cutu_die_from_dwo): Update comment.
9283 (lookup_dwo_unit): Add dwo_name parameter.
9284 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
9285 die_reader_func_ftype and data parameters.
9286 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
9287 Remove die_reader_func_ftype and data parameters.
9288 (~cutu_reader): New; from init_cutu_and_read_dies.
9289 (cutu_reader::cutu_reader): Rename from
9290 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
9291 and data parameters.
9292 (init_cutu_and_read_dies_simple): Remove.
9293 (struct process_psymtab_comp_unit_data): Remove.
9294 (process_psymtab_comp_unit_reader): Remove data parameter; add
9295 want_partial_unit and pretend_language parameters.
9296 (process_psymtab_comp_unit): Use cutu_reader.
9297 (build_type_psymtabs_reader): Remove data parameter.
9298 (build_type_psymtabs_1): Use cutu_reader.
9299 (process_skeletonless_type_unit): Likewise.
9300 (load_partial_comp_unit_reader): Remove.
9301 (load_partial_comp_unit): Use cutu_reader.
9302 (load_full_comp_unit_reader): Remove.
9303 (load_full_comp_unit): Use cutu_reader.
9304 (struct create_dwo_cu_data): Remove.
9305 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
9306 dwo_unit parameters.
9307 (create_cus_hash_table): Use cutu_reader.
9308 (struct dwarf2_read_addr_index_data): Remove.
9309 (dwarf2_read_addr_index_reader): Remove.
9310 (dwarf2_read_addr_index): Use cutu_reader.
9311 (read_signatured_type_reader): Remove.
9312 (read_signatured_type): Use cutu_reader.
9313
9314 2020-01-19 Tom Tromey <tom@tromey.com>
9315
9316 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
9317 * tui/tui-wingeneral.h (class tui_suppress_output): New.
9318 (tui_wrefresh): Declare.
9319 * tui/tui-wingeneral.c (suppress_output): New global.
9320 (tui_suppress_output, ~tui_suppress_output): New constructor and
9321 destructor.
9322 (tui_wrefresh): New function.
9323 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
9324 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
9325 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
9326 method.
9327 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
9328 tui_wrefresh.
9329 (tui_data_window::no_refresh): New method.
9330 (tui_data_item_window::refresh_window): Call tui_wrefresh.
9331 (tui_reg_command): Use tui_suppress_output
9332 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
9333 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
9334 method.
9335 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
9336
9337 2020-01-19 Tom Tromey <tom@tromey.com>
9338
9339 * tui/tui-winsource.c (tui_update_source_windows_with_line):
9340 Handle case where symtab is null.
9341
9342 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
9343
9344 * linux-fork.c (one_fork_p): Simplify.
9345
9346 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9347
9348 * top.c (struct qt_args): Remove.
9349 (kill_or_detach): Change return type to void, replace `void *`
9350 parameter with a proper one.
9351 (print_inferior_quit_action): Likewise.
9352 (quit_confirm): Use range-based for loop to iterate over inferiors.
9353 (quit_force): Likewise.
9354
9355 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9356
9357 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
9358 `void *` parameter with proper parameters.
9359 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
9360 (print_one_inferior): Change return type to void, replace `void *`
9361 parameter with proper parameters.
9362 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
9363 inferiors.
9364 (get_other_inferior): Remove.
9365 (mi_cmd_remove_inferior): Use range-based loop to iterate over
9366 inferiors.
9367
9368 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9369
9370 * mi/mi-interp.c (report_initial_inferior): Remove.
9371 (mi_interp::init): Use range-based for to iterate over inferiors.
9372
9373 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9374
9375 * python/py-inferior.c (build_inferior_list): Remove.
9376 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
9377
9378 2020-01-16 Christian Biesinger <cbiesinger@google.com>
9379
9380 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
9381 (btrace_stitch_trace): Likewise.
9382 * charset.c (intermediate_encoding): Likewise (vaild).
9383 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
9384 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
9385 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
9386
9387 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
9388
9389 * windows-tdep.c (windows_get_tlb_type):
9390 Add rtl_user_process_parameters type.
9391
9392 2020-01-16 Pedro Alves <palves@redhat.com>
9393 Norbert Lange <nolange79@gmail.com>
9394
9395 PR build/24805
9396 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
9397 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
9398 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
9399 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
9400 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
9401 (ps_plog): Redeclare exported functions with default visibility.
9402
9403 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
9404
9405 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
9406 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
9407
9408 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
9409
9410 * infcmd.c (post_create_inferior): Use get_thread_regcache
9411 instead of get_current_regcache.
9412
9413 2020-01-14 Tom Tromey <tom@tromey.com>
9414
9415 PR symtab/12535:
9416 * python/python.c (gdbpy_decode_line): Treat empty string the same
9417 as no argument.
9418
9419 2020-01-14 Tom Tromey <tom@tromey.com>
9420
9421 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
9422
9423 2020-01-14 Tom Tromey <tom@tromey.com>
9424
9425 * nat/linux-btrace.c: Don't include <config.h>.
9426 * nat/linux-ptrace.c: Don't include <config.h>.
9427 * nat/x86-linux-dregs.c: Don't include <config.h>.
9428
9429 2020-01-14 Tom Tromey <tom@tromey.com>
9430
9431 * configure: Rebuild.
9432 * configure.ac: Move many checks to ../gdbsupport/common.m4.
9433
9434 2020-01-14 Tom Tromey <tom@tromey.com>
9435
9436 * nat/x86-linux-dregs.c: Include configh.h.
9437 * nat/linux-ptrace.c: Include configh.h.
9438 * nat/linux-btrace.c: Include configh.h.
9439 * defs.h: Include config.h, bfd.h.
9440 * configure.ac: Don't source common.host.
9441 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
9442 * configure: Rebuild.
9443 * acinclude.m4: Update path.
9444 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
9445 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
9446 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
9447 (CLIBS): Add LIBSUPPORT.
9448 (CDEPS): Likewise.
9449 (COMMON_SFILES): Remove gdbsupport files.
9450 (HFILES_NO_SRCDIR): Likewise.
9451 (stamp-version): Update path to create-version.sh.
9452 (ALLDEPFILES): Remove gdbsupport files.
9453
9454 2020-01-14 Tom Tromey <tom@tromey.com>
9455
9456 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
9457 USE_WIN32API when needed.
9458 * configure.ac (USE_WIN32API): Don't define.
9459 (WIN32LIBS): Use WIN32APILIBS.
9460 * configure: Rebuild.
9461
9462 2020-01-14 Tom Tromey <tom@tromey.com>
9463
9464 * configure: Rebuild.
9465 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
9466
9467 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
9468
9469 * skip.c (skip_function_command): Make skip w/o arguments use the
9470 name of the inlined function if pc is inside any inlined function.
9471
9472 2020-01-14 Luis Machado <luis.machado@linaro.org>
9473
9474 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
9475 * infrun.c (resume_1): Likewise.
9476 (handle_inferior_event): Remove stale comment.
9477 * linux-nat.c (linux_nat_target::resume): Update comments.
9478 (save_stop_reason): Likewise.
9479 (linux_nat_filter_event): Likewise.
9480 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
9481
9482 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9483
9484 * elfread.c (record_minimal_symbol): Set section index to 0 for
9485 non-allocatable sections.
9486
9487
9488 2020-01-13 Ali Tamur <tamur@google.com>
9489
9490 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
9491 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
9492 to gdb::optional. Update comments.
9493 (dwo_file): Update comments.
9494 (read_attribute): Update API to take an additional out parameter,
9495 need_reprocess. This is used to mark attributes that need other
9496 attributes (e.g. str_offsets_base) for correct computation which may not
9497 have been read yet.
9498 (read_attribute_reprocess): New function declaration.
9499 (read_addr_index): Likewise.
9500 (read_dwo_str_index): Likewise.
9501 (read_stub_str_index): Likewise.
9502 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
9503 (lookup_addr_base): New function definition.
9504 (lookup_ranges_base): Likewise.
9505 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
9506 lookup_ranges_base.
9507 (init_cutu_and_read_dies): Update comments.
9508 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
9509 unit. This is used to inherit parent's str_offsets_base and addr_base.
9510 Update comments.
9511 (init_cutu_and_read_dies_simple): Reflect API changes.
9512 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
9513 (create_cus_hash_table): Change API to take parent compile unit.
9514 Reflect API changes.
9515 (open_and_init_dwo_file): Reflect API changes.
9516 (dwarf2_get_pc_bounds): Update comments.
9517 (dwarf2_record_block_ranges): Likewise.
9518 (read_full_die_1): Change implementation to reprocess attributes that
9519 need str_offsets_base and addr_base.
9520 (partial_die_info::read): Likewise.
9521 (read_attribute_reprocess): New function definition.
9522 (read_attribute_value): Change API to take an additional out parameter,
9523 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
9524 when a non-dwo compile unit has index based attributes.
9525 (read_attribute): Reflect API changes.
9526 (read_addr_index_1): Reflect API changes. Update comments.
9527 (dwarf2_read_addr_index_data): Reflect API changes.
9528 (dwarf2_read_addr_index): Likewise.
9529 (read_str_index): Change API and implementation. This becomes a helper
9530 to be used by the new string index related methods. Update error
9531 message and comments.
9532 (read_dwo_str_index): New function definition.
9533 (read_stub_str_index): Likewise.
9534 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
9535 * symfile.h (dwarf2_debug_sections): Likewise.
9536 * xcoffread.c (dwarf2_debug_sections): Likewise.
9537
9538 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9539
9540 * gdbcore.h (struct core_fns) <core_read_registers>: Change
9541 core_reg_sect type to gdb_byte *.
9542 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
9543 * cris-tdep.c (fetch_core_registers): Likewise.
9544 * corelow.c (core_target::get_core_register_section): Change
9545 type of `contents` to gdb::byte_vector.
9546
9547 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9548
9549 * tui/tui-wingeneral.c (box_win): Position the title in the center
9550 of the border.
9551
9552 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9553
9554 * corelow.c (core_target::get_core_register_section): Use
9555 std::vector instead of alloca.
9556
9557 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9558
9559 * warning.m4: Add -Wmissing-declarations to build_warnings.
9560 * configure: Re-generate.
9561
9562 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9563
9564 * python/python.c (init__gdb_module): Add declaration.
9565
9566 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9567
9568 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
9569 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
9570 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
9571 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
9572 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
9573 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
9574 * ada-exp.y (_initialize_ada_exp): Add declaration.
9575 * ada-lang.c (_initialize_ada_language): Add declaration.
9576 * ada-tasks.c (_initialize_tasks): Add declaration.
9577 * agent.c (_initialize_agent): Add declaration.
9578 * aix-thread.c (_initialize_aix_thread): Add declaration.
9579 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
9580 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
9581 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
9582 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
9583 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
9584 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
9585 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
9586 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
9587 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
9588 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
9589 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
9590 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
9591 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
9592 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
9593 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
9594 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
9595 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
9596 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
9597 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
9598 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
9599 * annotate.c (_initialize_annotate): Add declaration.
9600 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
9601 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
9602 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
9603 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
9604 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
9605 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
9606 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
9607 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
9608 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
9609 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
9610 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
9611 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
9612 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
9613 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
9614 * auto-load.c (_initialize_auto_load): Add declaration.
9615 * auxv.c (_initialize_auxv): Add declaration.
9616 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
9617 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
9618 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
9619 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
9620 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
9621 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
9622 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
9623 * breakpoint.c (_initialize_breakpoint): Add declaration.
9624 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
9625 * btrace.c (_initialize_btrace): Add declaration.
9626 * charset.c (_initialize_charset): Add declaration.
9627 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
9628 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
9629 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
9630 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
9631 * cli/cli-script.c (_initialize_cli_script): Add declaration.
9632 * cli/cli-style.c (_initialize_cli_style): Add declaration.
9633 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
9634 * coffread.c (_initialize_coffread): Add declaration.
9635 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
9636 * compile/compile.c (_initialize_compile): Add declaration.
9637 * complaints.c (_initialize_complaints): Add declaration.
9638 * completer.c (_initialize_completer): Add declaration.
9639 * copying.c (_initialize_copying): Add declaration.
9640 * corefile.c (_initialize_core): Add declaration.
9641 * corelow.c (_initialize_corelow): Add declaration.
9642 * cp-abi.c (_initialize_cp_abi): Add declaration.
9643 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
9644 * cp-support.c (_initialize_cp_support): Add declaration.
9645 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
9646 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
9647 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
9648 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
9649 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
9650 * ctfread.c (_initialize_ctfread): Add declaration.
9651 * d-lang.c (_initialize_d_language): Add declaration.
9652 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
9653 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
9654 * dbxread.c (_initialize_dbxread): Add declaration.
9655 * dcache.c (_initialize_dcache): Add declaration.
9656 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
9657 * disasm.c (_initialize_disasm): Add declaration.
9658 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
9659 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
9660 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
9661 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
9662 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
9663 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
9664 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
9665 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
9666 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
9667 * elfread.c (_initialize_elfread): Add declaration.
9668 * exec.c (_initialize_exec): Add declaration.
9669 * extension.c (_initialize_extension): Add declaration.
9670 * f-lang.c (_initialize_f_language): Add declaration.
9671 * f-valprint.c (_initialize_f_valprint): Add declaration.
9672 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
9673 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
9674 * filesystem.c (_initialize_filesystem): Add declaration.
9675 * findcmd.c (_initialize_mem_search): Add declaration.
9676 * findvar.c (_initialize_findvar): Add declaration.
9677 * fork-child.c (_initialize_fork_child): Add declaration.
9678 * frame-base.c (_initialize_frame_base): Add declaration.
9679 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
9680 * frame.c (_initialize_frame): Add declaration.
9681 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
9682 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
9683 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
9684 * gcore.c (_initialize_gcore): Add declaration.
9685 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
9686 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
9687 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
9688 * gdbarch.c (_initialize_gdbarch): Add declaration.
9689 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
9690 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
9691 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
9692 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
9693 * go-lang.c (_initialize_go_language): Add declaration.
9694 * go32-nat.c (_initialize_go32_nat): Add declaration.
9695 * guile/guile.c (_initialize_guile): Add declaration.
9696 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
9697 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
9698 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
9699 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
9700 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
9701 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
9702 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
9703 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
9704 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
9705 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
9706 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
9707 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
9708 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
9709 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
9710 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
9711 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
9712 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
9713 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
9714 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
9715 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
9716 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
9717 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
9718 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
9719 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
9720 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
9721 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
9722 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
9723 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
9724 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
9725 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
9726 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
9727 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
9728 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
9729 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
9730 * infcall.c (_initialize_infcall): Add declaration.
9731 * infcmd.c (_initialize_infcmd): Add declaration.
9732 * inflow.c (_initialize_inflow): Add declaration.
9733 * infrun.c (_initialize_infrun): Add declaration.
9734 * interps.c (_initialize_interpreter): Add declaration.
9735 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
9736 * jit.c (_initialize_jit): Add declaration.
9737 * language.c (_initialize_language): Add declaration.
9738 * linux-fork.c (_initialize_linux_fork): Add declaration.
9739 * linux-nat.c (_initialize_linux_nat): Add declaration.
9740 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
9741 * linux-thread-db.c (_initialize_thread_db): Add declaration.
9742 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
9743 * m2-lang.c (_initialize_m2_language): Add declaration.
9744 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
9745 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
9746 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
9747 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
9748 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
9749 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
9750 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
9751 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
9752 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
9753 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
9754 * machoread.c (_initialize_machoread): Add declaration.
9755 * macrocmd.c (_initialize_macrocmd): Add declaration.
9756 * macroscope.c (_initialize_macroscope): Add declaration.
9757 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
9758 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
9759 * maint.c (_initialize_maint_cmds): Add declaration.
9760 * mdebugread.c (_initialize_mdebugread): Add declaration.
9761 * memattr.c (_initialize_mem): Add declaration.
9762 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
9763 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
9764 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
9765 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
9766 * mi/mi-main.c (_initialize_mi_main): Add declaration.
9767 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
9768 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
9769 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
9770 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
9771 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
9772 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
9773 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
9774 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
9775 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
9776 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
9777 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
9778 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
9779 * mipsread.c (_initialize_mipsread): Add declaration.
9780 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
9781 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
9782 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
9783 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
9784 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
9785 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
9786 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
9787 * nto-procfs.c (_initialize_procfs): Add declaration.
9788 * objc-lang.c (_initialize_objc_language): Add declaration.
9789 * observable.c (_initialize_observer): Add declaration.
9790 * opencl-lang.c (_initialize_opencl_language): Add declaration.
9791 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
9792 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
9793 * osabi.c (_initialize_gdb_osabi): Add declaration.
9794 * osdata.c (_initialize_osdata): Add declaration.
9795 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
9796 * parse.c (_initialize_parse): Add declaration.
9797 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
9798 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
9799 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
9800 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
9801 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
9802 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
9803 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
9804 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
9805 * printcmd.c (_initialize_printcmd): Add declaration.
9806 * probe.c (_initialize_probe): Add declaration.
9807 * proc-api.c (_initialize_proc_api): Add declaration.
9808 * proc-events.c (_initialize_proc_events): Add declaration.
9809 * proc-service.c (_initialize_proc_service): Add declaration.
9810 * procfs.c (_initialize_procfs): Add declaration.
9811 * producer.c (_initialize_producer): Add declaration.
9812 * psymtab.c (_initialize_psymtab): Add declaration.
9813 * python/python.c (_initialize_python): Add declaration.
9814 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
9815 * record-btrace.c (_initialize_record_btrace): Add declaration.
9816 * record-full.c (_initialize_record_full): Add declaration.
9817 * record.c (_initialize_record): Add declaration.
9818 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
9819 * regcache.c (_initialize_regcache): Add declaration.
9820 * reggroups.c (_initialize_reggroup): Add declaration.
9821 * remote-notif.c (_initialize_notif): Add declaration.
9822 * remote-sim.c (_initialize_remote_sim): Add declaration.
9823 * remote.c (_initialize_remote): Add declaration.
9824 * reverse.c (_initialize_reverse): Add declaration.
9825 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
9826 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
9827 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
9828 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
9829 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
9830 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
9831 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
9832 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
9833 Add declaration.
9834 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
9835 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
9836 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
9837 * rust-exp.y (_initialize_rust_exp): Add declaration.
9838 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
9839 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
9840 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
9841 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
9842 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
9843 * score-tdep.c (_initialize_score_tdep): Add declaration.
9844 * ser-go32.c (_initialize_ser_dos): Add declaration.
9845 * ser-mingw.c (_initialize_ser_windows): Add declaration.
9846 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
9847 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
9848 * ser-uds.c (_initialize_ser_socket): Add declaration.
9849 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
9850 * serial.c (_initialize_serial): Add declaration.
9851 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
9852 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
9853 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
9854 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
9855 * skip.c (_initialize_step_skip): Add declaration.
9856 * sol-thread.c (_initialize_sol_thread): Add declaration.
9857 * solib-aix.c (_initialize_solib_aix): Add declaration.
9858 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
9859 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
9860 * solib-frv.c (_initialize_frv_solib): Add declaration.
9861 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
9862 * solib-target.c (_initialize_solib_target): Add declaration.
9863 * solib.c (_initialize_solib): Add declaration.
9864 * source-cache.c (_initialize_source_cache): Add declaration.
9865 * source.c (_initialize_source): Add declaration.
9866 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
9867 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
9868 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
9869 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
9870 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
9871 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
9872 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
9873 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
9874 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
9875 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
9876 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
9877 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
9878 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
9879 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
9880 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
9881 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
9882 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
9883 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
9884 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
9885 * stabsread.c (_initialize_stabsread): Add declaration.
9886 * stack.c (_initialize_stack): Add declaration.
9887 * stap-probe.c (_initialize_stap_probe): Add declaration.
9888 * std-regs.c (_initialize_frame_reg): Add declaration.
9889 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
9890 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
9891 * symfile.c (_initialize_symfile): Add declaration.
9892 * symmisc.c (_initialize_symmisc): Add declaration.
9893 * symtab.c (_initialize_symtab): Add declaration.
9894 * target.c (_initialize_target): Add declaration.
9895 * target-connection.c (_initialize_target_connection): Add
9896 declaration.
9897 * target-dcache.c (_initialize_target_dcache): Add declaration.
9898 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
9899 * thread.c (_initialize_thread): Add declaration.
9900 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
9901 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
9902 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
9903 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
9904 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
9905 * tracectf.c (_initialize_ctf): Add declaration.
9906 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
9907 * tracefile.c (_initialize_tracefile): Add declaration.
9908 * tracepoint.c (_initialize_tracepoint): Add declaration.
9909 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
9910 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
9911 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
9912 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
9913 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
9914 * tui/tui-win.c (_initialize_tui_win): Add declaration.
9915 * tui/tui.c (_initialize_tui): Add declaration.
9916 * typeprint.c (_initialize_typeprint): Add declaration.
9917 * ui-style.c (_initialize_ui_style): Add declaration.
9918 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
9919 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
9920 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
9921 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
9922 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
9923 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
9924 * unittests/filtered_iterator-selftests.c
9925 (_initialize_filtered_iterator_selftests): Add declaration.
9926 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
9927 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
9928 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
9929 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
9930 * unittests/main-thread-selftests.c
9931 (_initialize_main_thread_selftests): Add declaration.
9932 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
9933 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
9934 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
9935 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
9936 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
9937 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
9938 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
9939 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
9940 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
9941 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
9942 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
9943 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
9944 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
9945 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
9946 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
9947 declaration.
9948 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
9949 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
9950 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
9951 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
9952 * user-regs.c (_initialize_user_regs): Add declaration.
9953 * utils.c (_initialize_utils): Add declaration.
9954 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
9955 * valops.c (_initialize_valops): Add declaration.
9956 * valprint.c (_initialize_valprint): Add declaration.
9957 * value.c (_initialize_values): Add declaration.
9958 * varobj.c (_initialize_varobj): Add declaration.
9959 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
9960 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
9961 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
9962 * windows-nat.c (_initialize_windows_nat): Add declaration.
9963 (_initialize_check_for_gdb_ini): Add declaration.
9964 (_initialize_loadable): Add declaration.
9965 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
9966 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
9967 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
9968 * xcoffread.c (_initialize_xcoffread): Add declaration.
9969 * xml-support.c (_initialize_xml_support): Add declaration.
9970 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
9971 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
9972 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
9973 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
9974
9975 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9976
9977 * regformats/regdat.sh: Generate declaration for init function.
9978
9979 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9980
9981 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
9982 up.
9983 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
9984 close_one_inferior>: New methods.
9985 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
9986 pass down target to find_inferior_pid.
9987 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
9988 Pass down target to find_inferior_ptid.
9989 (gdbsim_target::create_inferior): Pass down target to
9990 add_thread_silent.
9991 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
9992 target down to find_inferior_ptid and switch_to_thread.
9993 (gdbsim_target::close): Update to call close_one_inferior.
9994 (struct resume_data): Remove.
9995 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
9996 directly, rather than through a void pointer.
9997 (gdbsim_target::resume): Update to call resume_one_inferior.
9998
9999 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
10000
10001 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
10002
10003 2020-01-12 Pedro Alves <palves@redhat.com>
10004
10005 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
10006 directly for the current inferior instead of
10007 discard_all_inferiors.
10008 (discard_all_inferiors): Delete.
10009
10010 2020-01-11 Tom Tromey <tom@tromey.com>
10011
10012 * tui/tui-wingeneral.c (box_win): Check cli_styling.
10013 * tui/tui-winsource.c (tui_source_window_base::refill): Use
10014 deprecated_safe_get_selected_frame.
10015
10016 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10017
10018 * inferior.c (print_inferior): Switch inferior before printing it.
10019
10020 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
10021 Pedro Alves <palves@redhat.com>
10022
10023 * progspace-and-thread.c (switch_to_program_space_and_thread):
10024 Assert there's an inferior for PSPACE. Use
10025 switch_to_inferior_no_thread to switch the inferior too.
10026 * progspace.c (program_space::~program_space): Call
10027 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
10028 (program_space::free_all_objfiles): Don't call clear_symtab_users
10029 here.
10030 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
10031
10032 2020-01-10 Pedro Alves <palves@redhat.com>
10033
10034 * NEWS: Mention multi-target debugging, "info connections", and
10035 "add-inferior -no-connection".
10036
10037 2020-01-10 Pedro Alves <palves@redhat.com>
10038
10039 * infrun.c: Include "target-connection.h".
10040 (check_multi_target_resumption): New.
10041 (proceed): Call it.
10042 * target-connection.c (make_target_connection_string): Make
10043 extern.
10044 * target-connection.h (make_target_connection_string): Declare.
10045
10046 2020-01-10 Pedro Alves <palves@redhat.com>
10047
10048 * Makefile.in (COMMON_SFILES): Add target-connection.c.
10049 * inferior.c (uiout_field_connection): New function.
10050 (print_inferior): Add new "connection-id" column.
10051 (add_inferior_command): Show connection number/string of added
10052 inferior.
10053 * process-stratum-target.h
10054 (process_stratum_target::connection_string): New virtual method.
10055 (process_stratum_target::connection_number): New field.
10056 * remote.c (remote_target::connection_string): New override.
10057 * target-connection.c: New file.
10058 * target-connection.h: New file.
10059 * target.c (decref_target): Remove process_stratum targets from
10060 the connection list.
10061 (target_stack::push): Add process_stratum targets to the
10062 connection list.
10063
10064 2020-01-10 Pedro Alves <palves@redhat.com>
10065
10066 Revert:
10067 2016-04-12 Pedro Alves <palves@redhat.com>
10068 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
10069 Remove references to name.
10070 * serial.h (struct serial) <name>: Delete.
10071
10072 2020-01-10 Pedro Alves <palves@redhat.com>
10073
10074 * gdbarch-selftests.c (register_to_value_test): Remove "target
10075 already pushed" check.
10076
10077 2020-01-10 Pedro Alves <palves@redhat.com>
10078 John Baldwin <jhb@FreeBSD.org>
10079
10080 * aarch64-linux-nat.c
10081 (aarch64_linux_nat_target::thread_architecture): Adjust.
10082 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
10083 (task_command_1): Likewise.
10084 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
10085 (aix_thread_target::wait, aix_thread_target::fetch_registers)
10086 (aix_thread_target::store_registers)
10087 (aix_thread_target::thread_alive): Adjust.
10088 * amd64-fbsd-tdep.c: Include "inferior.h".
10089 (amd64fbsd_get_thread_local_address): Pass down target.
10090 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
10091 thread's gdbarch instead of target_gdbarch.
10092 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
10093 get_last_target_status.
10094 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
10095 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
10096 inferiors.
10097 (update_inserted_breakpoint_locations): Skip if inferiors with no
10098 execution.
10099 (update_global_location_list): When handling moribund locations,
10100 find representative inferior for location's pspace, and use thread
10101 count of its process_stratum target.
10102 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
10103 * bsd-uthread.c (bsd_uthread_target::wait): Use
10104 as_process_stratum_target and adjust thread_change_ptid and
10105 add_thread calls.
10106 (bsd_uthread_target::update_thread_list): Use
10107 as_process_stratum_target and adjust find_thread_ptid,
10108 thread_change_ptid and add_thread calls.
10109 * btrace.c (maint_btrace_packet_history_cmd): Adjust
10110 find_thread_ptid call.
10111 * corelow.c (add_to_thread_list): Adjust add_thread call.
10112 (core_target_open): Adjust add_thread_silent and thread_count
10113 calls.
10114 (core_target::pid_to_str): Adjust find_inferior_ptid call.
10115 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
10116 * event-top.c (async_disconnect): Pop targets from all inferiors.
10117 * exec.c (add_target_sections): Push exec target on all inferiors
10118 sharing the program space.
10119 (remove_target_sections): Remove the exec target from all
10120 inferiors sharing the program space.
10121 (exec_on_vfork): New.
10122 * exec.h (exec_on_vfork): Declare.
10123 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
10124 Pass it down.
10125 (fbsd_nat_target::update_thread_list): Adjust.
10126 (fbsd_nat_target::resume): Adjust.
10127 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
10128 down.
10129 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
10130 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
10131 get_thread_arch_regcache call.
10132 * fork-child.c (gdb_startup_inferior): Pass target down to
10133 startup_inferior and set_executing.
10134 * gdbthread.h (struct process_stratum_target): Forward declare.
10135 (add_thread, add_thread_silent, add_thread_with_info)
10136 (in_thread_list): Add process_stratum_target parameter.
10137 (find_thread_ptid(inferior*, ptid_t)): New overload.
10138 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
10139 parameter.
10140 (all_threads()): Delete overload.
10141 (all_threads, all_non_exited_threads): Add process_stratum_target
10142 parameter.
10143 (all_threads_safe): Use brace initialization.
10144 (thread_count): Add process_stratum_target parameter.
10145 (set_resumed, set_running, set_stop_requested, set_executing)
10146 (threads_are_executing, finish_thread_state): Add
10147 process_stratum_target parameter.
10148 (switch_to_thread): Use is_current_thread.
10149 * i386-fbsd-tdep.c: Include "inferior.h".
10150 (i386fbsd_get_thread_local_address): Pass down target.
10151 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
10152 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
10153 have_inferiors check.
10154 * inf-ptrace.c (inf_ptrace_target::create_inferior)
10155 (inf_ptrace_target::attach): Adjust.
10156 * infcall.c (run_inferior_call): Adjust.
10157 * infcmd.c (run_command_1): Pass target to
10158 scoped_finish_thread_state.
10159 (proceed_thread_callback): Skip inferiors with no execution.
10160 (continue_command): Rename 'all_threads' local to avoid hiding
10161 'all_threads' function. Adjust get_last_target_status call.
10162 (prepare_one_step): Adjust set_running call.
10163 (signal_command): Use user_visible_resume_target. Compare thread
10164 pointers instead of inferior_ptid.
10165 (info_program_command): Adjust to pass down target.
10166 (attach_command): Mark target's 'thread_executing' flag.
10167 (stop_current_target_threads_ns): New, factored out from ...
10168 (interrupt_target_1): ... this. Switch inferior before making
10169 target calls.
10170 * inferior-iter.h
10171 (struct all_inferiors_iterator, struct all_inferiors_range)
10172 (struct all_inferiors_safe_range)
10173 (struct all_non_exited_inferiors_range): Filter on
10174 process_stratum_target too. Remove explicit.
10175 * inferior.c (inferior::inferior): Push dummy target on target
10176 stack.
10177 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
10178 Add process_stratum_target parameter, and pass it down.
10179 (have_live_inferiors): Adjust.
10180 (switch_to_inferior_and_push_target): New.
10181 (add_inferior_command, clone_inferior_command): Handle
10182 "-no-connection" parameter. Use
10183 switch_to_inferior_and_push_target.
10184 (_initialize_inferior): Mention "-no-connection" option in
10185 the help of "add-inferior" and "clone-inferior" commands.
10186 * inferior.h: Include "process-stratum-target.h".
10187 (interrupt_target_1): Use bool.
10188 (struct inferior) <push_target, unpush_target, target_is_pushed,
10189 find_target_beneath, top_target, process_target, target_at,
10190 m_stack>: New.
10191 (discard_all_inferiors): Delete.
10192 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
10193 (all_inferiors, all_non_exited_inferiors): Add
10194 process_stratum_target parameter.
10195 * infrun.c: Include "gdb_select.h" and <unordered_map>.
10196 (target_last_proc_target): New global.
10197 (follow_fork_inferior): Push target on new inferior. Pass target
10198 to add_thread_silent. Call exec_on_vfork. Handle target's
10199 reference count.
10200 (follow_fork): Adjust get_last_target_status call. Also consider
10201 target.
10202 (follow_exec): Push target on new inferior.
10203 (struct execution_control_state) <target>: New field.
10204 (user_visible_resume_target): New.
10205 (do_target_resume): Call target_async.
10206 (resume_1): Set target's threads_executing flag. Consider resume
10207 target.
10208 (commit_resume_all_targets): New.
10209 (proceed): Also consider resume target. Skip threads of inferiors
10210 with no execution. Commit resumtion in all targets.
10211 (start_remote): Pass current inferior to wait_for_inferior.
10212 (infrun_thread_stop_requested): Consider target as well. Pass
10213 thread_info pointer to clear_inline_frame_state instead of ptid.
10214 (infrun_thread_thread_exit): Consider target as well.
10215 (random_pending_event_thread): New inferior parameter. Use it.
10216 (do_target_wait): Rename to ...
10217 (do_target_wait_1): ... this. Add inferior parameter, and pass it
10218 down.
10219 (threads_are_resumed_pending_p, do_target_wait): New.
10220 (prepare_for_detach): Adjust calls.
10221 (wait_for_inferior): New inferior parameter. Handle it. Use
10222 do_target_wait_1 instead of do_target_wait.
10223 (fetch_inferior_event): Adjust. Switch to representative
10224 inferior. Pass target down.
10225 (set_last_target_status): Add process_stratum_target parameter.
10226 Save target in global.
10227 (get_last_target_status): Add process_stratum_target parameter and
10228 handle it.
10229 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
10230 (context_switch): Check inferior_ptid == null_ptid before calling
10231 inferior_thread().
10232 (get_inferior_stop_soon): Pass down target.
10233 (wait_one): Rename to ...
10234 (poll_one_curr_target): ... this.
10235 (struct wait_one_event): New.
10236 (wait_one): New.
10237 (stop_all_threads): Adjust.
10238 (handle_no_resumed, handle_inferior_event): Adjust to consider the
10239 event's target.
10240 (switch_back_to_stepped_thread): Also consider target.
10241 (print_stop_event): Update.
10242 (normal_stop): Update. Also consider the resume target.
10243 * infrun.h (wait_for_inferior): Remove declaration.
10244 (user_visible_resume_target): New declaration.
10245 (get_last_target_status, set_last_target_status): New
10246 process_stratum_target parameter.
10247 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
10248 process_stratum_target parameter, and use it.
10249 (clear_inline_frame_state (thread_info*)): New.
10250 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
10251 process_stratum_target parameter.
10252 (clear_inline_frame_state (thread_info*)): Declare.
10253 * linux-fork.c (delete_checkpoint_command): Pass target down to
10254 find_thread_ptid.
10255 (checkpoint_command): Adjust.
10256 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
10257 instead of just tweaking inferior_ptid.
10258 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
10259 (exit_lwp): Pass target down to find_thread_ptid.
10260 (attach_proc_task_lwp_callback): Pass target down to
10261 add_thread/set_running/set_executing.
10262 (linux_nat_target::attach): Pass target down to
10263 thread_change_ptid.
10264 (get_detach_signal): Pass target down to find_thread_ptid.
10265 Consider last target status's target.
10266 (linux_resume_one_lwp_throw, resume_lwp)
10267 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
10268 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
10269 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
10270 (linux_nat_target::async_wait_fd): New.
10271 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
10272 target down.
10273 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
10274 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
10275 * linux-thread-db.c (struct thread_db_info::process_target): New
10276 field.
10277 (add_thread_db_info): Save target.
10278 (get_thread_db_info): New process_stratum_target parameter. Also
10279 match target.
10280 (delete_thread_db_info): New process_stratum_target parameter.
10281 Also match target.
10282 (thread_from_lwp): Adjust to pass down target.
10283 (thread_db_notice_clone): Pass down target.
10284 (check_thread_db_callback): Pass down target.
10285 (try_thread_db_load_1): Always push the thread_db target.
10286 (try_thread_db_load, record_thread): Pass target down.
10287 (thread_db_target::detach): Pass target down. Always unpush the
10288 thread_db target.
10289 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
10290 target down. Always unpush the thread_db target.
10291 (find_new_threads_callback, thread_db_find_new_threads_2)
10292 (thread_db_target::update_thread_list): Pass target down.
10293 (thread_db_target::pid_to_str): Pass current inferior down.
10294 (thread_db_target::get_thread_local_address): Pass target down.
10295 (thread_db_target::resume, maintenance_check_libthread_db): Pass
10296 target down.
10297 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
10298 * procfs.c (procfs_target::procfs_init_inferior): Declare.
10299 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
10300 (procfs_init_inferior): Rename to ...
10301 (procfs_target::procfs_init_inferior): ... this and adjust.
10302 (procfs_target::create_inferior, procfs_notice_thread)
10303 (procfs_do_thread_registers): Adjust.
10304 * ppc-fbsd-tdep.c: Include "inferior.h".
10305 (ppcfbsd_get_thread_local_address): Pass down target.
10306 * proc-service.c (ps_xfer_memory): Switch current inferior and
10307 program space as well.
10308 (get_ps_regcache): Pass target down.
10309 * process-stratum-target.c
10310 (process_stratum_target::thread_address_space)
10311 (process_stratum_target::thread_architecture): Pass target down.
10312 * process-stratum-target.h
10313 (process_stratum_target::threads_executing): New field.
10314 (as_process_stratum_target): New.
10315 * ravenscar-thread.c
10316 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
10317 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
10318 down.
10319 * record-btrace.c (record_btrace_target::info_record): Adjust.
10320 (record_btrace_target::record_method)
10321 (record_btrace_target::record_is_replaying)
10322 (record_btrace_target::fetch_registers)
10323 (get_thread_current_frame_id, record_btrace_target::resume)
10324 (record_btrace_target::wait, record_btrace_target::stop): Pass
10325 target down.
10326 * record-full.c (record_full_wait_1): Switch to event thread.
10327 Pass target down.
10328 * regcache.c (regcache::regcache)
10329 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
10330 process_stratum_target parameter and handle it.
10331 (current_thread_target): New global.
10332 (get_thread_regcache): Add process_stratum_target parameter and
10333 handle it. Switch inferior before calling target method.
10334 (get_thread_regcache): Pass target down.
10335 (get_thread_regcache_for_ptid): Pass target down.
10336 (registers_changed_ptid): Add process_stratum_target parameter and
10337 handle it.
10338 (registers_changed_thread, registers_changed): Pass target down.
10339 (test_get_thread_arch_aspace_regcache): New.
10340 (current_regcache_test): Define a couple local test_target_ops
10341 instances and use them for testing.
10342 (readwrite_regcache): Pass process_stratum_target parameter.
10343 (cooked_read_test, cooked_write_test): Pass mock_target down.
10344 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
10345 (get_thread_arch_aspace_regcache): Add process_stratum_target
10346 parameter.
10347 (regcache::target): New method.
10348 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
10349 (regcache::registers_changed_ptid): Add process_stratum_target
10350 parameter.
10351 (regcache::m_target): New field.
10352 (registers_changed_ptid): Add process_stratum_target parameter.
10353 * remote.c (remote_state::supports_vCont_probed): New field.
10354 (remote_target::async_wait_fd): New method.
10355 (remote_unpush_and_throw): Add remote_target parameter.
10356 (get_current_remote_target): Adjust.
10357 (remote_target::remote_add_inferior): Push target.
10358 (remote_target::remote_add_thread)
10359 (remote_target::remote_notice_new_inferior)
10360 (get_remote_thread_info): Pass target down.
10361 (remote_target::update_thread_list): Skip threads of inferiors
10362 bound to other targets. (remote_target::close): Don't discard
10363 inferiors. (remote_target::add_current_inferior_and_thread)
10364 (remote_target::process_initial_stop_replies)
10365 (remote_target::start_remote)
10366 (remote_target::remote_serial_quit_handler): Pass down target.
10367 (remote_target::remote_unpush_target): New remote_target
10368 parameter. Unpush the target from all inferiors.
10369 (remote_target::remote_unpush_and_throw): New remote_target
10370 parameter. Pass it down.
10371 (remote_target::open_1): Check whether the current inferior has
10372 execution instead of checking whether any inferior is live. Pass
10373 target down.
10374 (remote_target::remote_detach_1): Pass down target. Use
10375 remote_unpush_target.
10376 (extended_remote_target::attach): Pass down target.
10377 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
10378 (remote_target::append_resumption): Pass down target.
10379 (remote_target::append_pending_thread_resumptions)
10380 (remote_target::remote_resume_with_hc, remote_target::resume)
10381 (remote_target::commit_resume): Pass down target.
10382 (remote_target::remote_stop_ns): Check supports_vCont_probed.
10383 (remote_target::interrupt_query)
10384 (remote_target::remove_new_fork_children)
10385 (remote_target::check_pending_events_prevent_wildcard_vcont)
10386 (remote_target::remote_parse_stop_reply)
10387 (remote_target::process_stop_reply): Pass down target.
10388 (first_remote_resumed_thread): New remote_target parameter. Pass
10389 it down.
10390 (remote_target::wait_as): Pass down target.
10391 (unpush_and_perror): New remote_target parameter. Pass it down.
10392 (remote_target::readchar, remote_target::remote_serial_write)
10393 (remote_target::getpkt_or_notif_sane_1)
10394 (remote_target::kill_new_fork_children, remote_target::kill): Pass
10395 down target.
10396 (remote_target::mourn_inferior): Pass down target. Use
10397 remote_unpush_target.
10398 (remote_target::core_of_thread)
10399 (remote_target::remote_btrace_maybe_reopen): Pass down target.
10400 (remote_target::pid_to_exec_file)
10401 (remote_target::thread_handle_to_thread_info): Pass down target.
10402 (remote_target::async_wait_fd): New.
10403 * riscv-fbsd-tdep.c: Include "inferior.h".
10404 (riscv_fbsd_get_thread_local_address): Pass down target.
10405 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
10406 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
10407 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
10408 Adjust.
10409 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
10410 * solib-svr4.c (enable_break): Pass down target.
10411 * spu-multiarch.c (parse_spufs_run): Pass down target.
10412 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
10413 * target-delegates.c: Regenerate.
10414 * target.c (g_target_stack): Delete.
10415 (current_top_target): Return the current inferior's top target.
10416 (target_has_execution_1): Refer to the passed-in inferior's top
10417 target.
10418 (target_supports_terminal_ours): Check whether the initial
10419 inferior was already created.
10420 (decref_target): New.
10421 (target_stack::push): Incref/decref the target.
10422 (push_target, push_target, unpush_target): Adjust.
10423 (target_stack::unpush): Defref target.
10424 (target_is_pushed): Return bool. Adjust to refer to the current
10425 inferior's target stack.
10426 (dispose_inferior): Delete, and inline parts ...
10427 (target_preopen): ... here. Only dispose of the current inferior.
10428 (target_detach): Hold strong target reference while detaching.
10429 Pass target down.
10430 (target_thread_name): Add assertion.
10431 (target_resume): Pass down target.
10432 (target_ops::beneath, find_target_at): Adjust to refer to the
10433 current inferior's target stack.
10434 (get_dummy_target): New.
10435 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
10436 has a thread running.
10437 (initialize_targets): Rename to ...
10438 (_initialize_target): ... this.
10439 * target.h: Include "gdbsupport/refcounted-object.h".
10440 (struct target_ops): Inherit refcounted_object.
10441 (target_ops::shortname, target_ops::longname): Make const.
10442 (target_ops::async_wait_fd): New method.
10443 (decref_target): Declare.
10444 (struct target_ops_ref_policy): New.
10445 (target_ops_ref): New typedef.
10446 (get_dummy_target): Declare function.
10447 (target_is_pushed): Return bool.
10448 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
10449 (all_matching_threads_iterator::all_matching_threads_iterator):
10450 Handle filter target.
10451 * thread-iter.h (struct all_matching_threads_iterator, struct
10452 all_matching_threads_range, class all_non_exited_threads_range):
10453 Filter by target too. Remove explicit.
10454 * thread.c (threads_executing): Delete.
10455 (inferior_thread): Pass down current inferior.
10456 (clear_thread_inferior_resources): Pass down thread pointer
10457 instead of ptid_t.
10458 (add_thread_silent, add_thread_with_info, add_thread): Add
10459 process_stratum_target parameter. Use it for thread and inferior
10460 searches.
10461 (is_current_thread): New.
10462 (thread_info::deletable): Use it.
10463 (find_thread_ptid, thread_count, in_thread_list)
10464 (thread_change_ptid, set_resumed, set_running): New
10465 process_stratum_target parameter. Pass it down.
10466 (set_executing): New process_stratum_target parameter. Pass it
10467 down. Adjust reference to 'threads_executing'.
10468 (threads_are_executing): New process_stratum_target parameter.
10469 Adjust reference to 'threads_executing'.
10470 (set_stop_requested, finish_thread_state): New
10471 process_stratum_target parameter. Pass it down.
10472 (switch_to_thread): Also match inferior.
10473 (switch_to_thread): New process_stratum_target parameter. Pass it
10474 down.
10475 (update_threads_executing): Reimplement.
10476 * top.c (quit_force): Pop targets from all inferior.
10477 (gdb_init): Don't call initialize_targets.
10478 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
10479 Declare.
10480 (windows_add_thread, windows_delete_thread): Adjust.
10481 (get_windows_debug_event): Rename to ...
10482 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
10483 * tracefile-tfile.c (tfile_target_open): Pass down target.
10484 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
10485 Forward declare.
10486 (switch_to_thread): Add process_stratum_target parameter.
10487 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
10488 parameter. Use it.
10489 (mi_on_resume): Pass target down.
10490 * nat/fork-inferior.c (startup_inferior): Add
10491 process_stratum_target parameter. Pass it down.
10492 * nat/fork-inferior.h (startup_inferior): Add
10493 process_stratum_target parameter.
10494 * python/py-threadevent.c (py_get_event_thread): Pass target down.
10495
10496 2020-01-10 Pedro Alves <palves@redhat.com>
10497
10498 * remote.c (remote_target::start_remote): Don't set inferior_ptid
10499 directly. Instead find the first thread in the thread list and
10500 use switch_to_thread.
10501
10502 2020-01-10 Pedro Alves <palves@redhat.com>
10503
10504 * remote.c (remote_target::remote_add_inferior): Don't bind a
10505 process to the current inferior if the current inferior is already
10506 bound to a process.
10507
10508 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10509 Pedro Alves <palves@redhat.com>
10510
10511 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
10512 If no process is specified, return null_ptid instead of
10513 inferior_ptid.
10514 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
10515 TARGET_WAITKIND_SIGNALLED with no pid.
10516
10517 2020-01-10 Pedro Alves <palves@redhat.com>
10518
10519 * remote.c (first_remote_resumed_thread): New.
10520 (remote_target::wait_as): Use it as default event_ptid instead of
10521 inferior_ptid.
10522
10523 2020-01-10 Pedro Alves <palves@redhat.com>
10524
10525 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
10526
10527 2020-01-10 Pedro Alves <palves@redhat.com>
10528
10529 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
10530 not -1.
10531
10532 2020-01-10 Pedro Alves <palves@redhat.com>
10533
10534 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
10535 ptid to get_last_target_status.
10536 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
10537 ptid to get_last_target_status.
10538 * infcmd.c (continue_command): Don't pass a target_waitstatus to
10539 get_last_target_status.
10540 (info_program_command): Don't pass a target_waitstatus to
10541 get_last_target_status.
10542 * infrun.c (init_wait_for_inferior): Use
10543 nullify_last_target_wait_ptid.
10544 (get_last_target_status): Handle nullptr arguments.
10545 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
10546 (print_stop_event): Don't pass a ptid to get_last_target_status.
10547 (normal_stop): Don't pass a ptid to get_last_target_status.
10548 * infrun.h (get_last_target_status, set_last_target_status): Move
10549 comments here and update.
10550 (nullify_last_target_wait_ptid): Declare.
10551 * linux-fork.c (fork_load_infrun_state): Remove local extern
10552 declaration of nullify_last_target_wait_ptid.
10553 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
10554 to get_last_target_status.
10555
10556 2020-01-10 Pedro Alves <palves@redhat.com>
10557
10558 * gdbthread.h (scoped_restore_current_thread)
10559 <dont_restore, restore, m_dont_restore>: Declare.
10560 * thread.c (thread_alive): Add assertion. Return bool.
10561 (switch_to_thread_if_alive): New.
10562 (prune_threads): Switch inferior/thread.
10563 (print_thread_info_1): Switch thread before calling target methods.
10564 (scoped_restore_current_thread::restore): New, factored out from
10565 ...
10566 (scoped_restore_current_thread::~scoped_restore_current_thread):
10567 ... this.
10568 (scoped_restore_current_thread::scoped_restore_current_thread):
10569 Add assertion.
10570 (thread_apply_all_command, thread_select): Use
10571 switch_to_thread_if_alive.
10572 * infrun.c (proceed, restart_threads, handle_signal_stop)
10573 (switch_back_to_stepped_thread): Switch current thread before
10574 calling target methods.
10575
10576 2020-01-10 Pedro Alves <palves@redhat.com>
10577
10578 * inferior.c (switch_to_inferior_no_thread): New function,
10579 factored out from ...
10580 (inferior_command): ... here.
10581 * inferior.h (switch_to_inferior_no_thread): Declare.
10582 * mi/mi-main.c (run_one_inferior): Use
10583 switch_to_inferior_no_thread.
10584
10585 2020-01-10 Pedro Alves <palves@redhat.com>
10586
10587 * infcmd.c (kill_command): Remove dead code.
10588
10589 2020-01-10 Pedro Alves <palves@redhat.com>
10590
10591 * remote.c (remote_target::mourn_inferior): No longer check
10592 whether the target is running.
10593
10594 2020-01-10 Pedro Alves <palves@redhat.com>
10595
10596 * corelow.c (core_target::has_execution): Change parameter type to
10597 inferior pointer.
10598 * inferior.c (number_of_live_inferiors): Use
10599 inferior::has_execution instead of target_has_execution_1.
10600 * inferior.h (inferior::has_execution): New.
10601 * linux-thread-db.c (thread_db_target::update_thread_list): Use
10602 inferior::has_execution instead of target_has_execution_1.
10603 * process-stratum-target.c
10604 (process_stratum_target::has_execution): Change parameter type to
10605 inferior pointer. Check the inferior's PID instead of
10606 inferior_ptid.
10607 * process-stratum-target.h
10608 (process_stratum_target::has_execution): Change parameter type to
10609 inferior pointer.
10610 * record-full.c (record_full_core_target::has_execution): Change
10611 parameter type to inferior pointer.
10612 * target.c (target_has_execution_1): Change parameter type to
10613 inferior pointer.
10614 (target_has_execution_current): Adjust.
10615 * target.h (target_ops::has_execution): Change parameter type to
10616 inferior pointer.
10617 (target_has_execution_1): Change parameter type to inferior
10618 pointer. Change return type to bool.
10619 * tracefile.h (tracefile_target::has_execution): Change parameter
10620 type to inferior pointer.
10621
10622 2020-01-10 Pedro Alves <palves@redhat.com>
10623
10624 * exceptions.c (print_flush): Remove current_top_target() check.
10625
10626 2020-01-10 Pedro Alves <palves@redhat.com>
10627
10628 * remote.c (show_remote_exec_file): Show the current inferior's
10629 exec-file instead of the command variable's value.
10630
10631 2020-01-10 Pedro Alves <palves@redhat.com>
10632
10633 * record-full.c (record_full_resume_ptid): New global.
10634 (record_full_target::resume): Set it.
10635 (record_full_wait_1): Use record_full_resume_ptid instead of
10636 inferior_ptid.
10637
10638 2020-01-10 Pedro Alves <palves@redhat.com>
10639
10640 * gdbthread.h (scoped_restore_current_thread)
10641 <dont_restore, restore, m_dont_restore>: Declare.
10642 * thread.c (thread_alive): Add assertion. Return bool.
10643 (switch_to_thread_if_alive): New.
10644 (prune_threads): Switch inferior/thread.
10645 (print_thread_info_1): Switch thread before calling target methods.
10646 (scoped_restore_current_thread::restore): New, factored out from
10647 ...
10648 (scoped_restore_current_thread::~scoped_restore_current_thread):
10649 ... this.
10650 (scoped_restore_current_thread::scoped_restore_current_thread):
10651 Add assertion.
10652 (thread_apply_all_command, thread_select): Use
10653 switch_to_thread_if_alive.
10654
10655 2020-01-10 George Barrett <bob@bob131.so>
10656
10657 * stap-probe.c (stap_modify_semaphore): Don't check for null
10658 semaphores.
10659 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
10660 for null semaphores.
10661
10662 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
10663
10664 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
10665 all source windows, and maintain horizontal scroll status while
10666 doing so.
10667
10668 2020-01-09 Tom Tromey <tom@tromey.com>
10669
10670 PR tui/18932:
10671 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
10672 update_source_window, not print_source_lines.
10673
10674 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
10675
10676 * tui/tui.c (tui_enable): Register tui hooks after calling
10677 tui_display_main.
10678
10679 2020-01-09 Christian Biesinger <cbiesinger@google.com>
10680
10681 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
10682
10683 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
10684
10685 * thread.c (print_thread_info_1): Fix indentation.
10686
10687 2020-01-09 Christian Biesinger <cbiesinger@google.com>
10688
10689 * symtab.c (general_symbol_info::compute_and_set_names): Move the
10690 unique_xmalloc_ptr outside the if to always free the demangled name.
10691
10692 2020-01-08 Tom Tromey <tromey@adacore.com>
10693
10694 * xcoffread.c (enter_line_range, read_xcoff_symtab)
10695 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
10696 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
10697 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
10698 Remove.
10699 (section_offsets): New typedef.
10700 * symtab.c (fixup_section, get_msymbol_address): Update.
10701 * symmisc.c (dump_msymbols): Update.
10702 * symfile.h (relative_addr_info_to_section_offsets)
10703 (symfile_map_offsets_to_segments): Update.
10704 * symfile.c (build_section_addr_info_from_objfile)
10705 (init_objfile_sect_indices): Update.
10706 (struct place_section_arg): Change type of "offsets".
10707 (place_section): Update.
10708 (relative_addr_info_to_section_offsets): Change type of
10709 "section_offsets". Remove "num_sections" parameter.
10710 (default_symfile_offsets, syms_from_objfile_1)
10711 (set_objfile_default_section_offset): Update.
10712 (reread_symbols): No need to preserve section offsets by hand.
10713 (symfile_map_offsets_to_segments): Change type of "offsets".
10714 * stap-probe.c (relocate_address): Update.
10715 * stabsread.h (process_one_symbol): Update.
10716 * solib-target.c (struct lm_info_target) <offsets>: Change type.
10717 (solib_target_relocate_section_addresses): Update.
10718 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
10719 Update.
10720 * solib-frv.c (frv_relocate_main_executable): Update.
10721 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
10722 * solib-aix.c (solib_aix_get_section_offsets): Change return
10723 type.
10724 (solib_aix_solib_create_inferior_hook): Update.
10725 * remote.c (remote_target::get_offsets): Update.
10726 * psymtab.c (find_pc_sect_psymtab): Update.
10727 * psympriv.h (struct partial_symbol) <address, text_low,
10728 text_high>: Update.
10729 * objfiles.h (obj_section_offset): Update.
10730 (struct objfile) <section_offsets>: Change type.
10731 <num_sections>: Remove.
10732 (objfile_relocate): Update.
10733 * objfiles.c (entry_point_address_query): Update
10734 (relocate_one_symbol): Change type of "section_offsets".
10735 (objfile_relocate1, objfile_relocate1): Change type of
10736 "new_offsets".
10737 (objfile_rebase1): Update.
10738 * mipsread.c (mipscoff_symfile_read): Update.
10739 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
10740 parameter.
10741 * mdebugread.c (parse_symbol): Change type of "section_offsets".
10742 (parse_external, psymtab_to_symtab_1): Update.
10743 * machoread.c (macho_symfile_offsets): Update.
10744 * ia64-tdep.c (ia64_find_unwind_table): Update.
10745 * hppa-tdep.c (read_unwind_info): Update.
10746 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
10747 * dwarf2read.c (create_addrmap_from_index)
10748 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
10749 (process_psymtab_comp_unit_reader, add_partial_symbol)
10750 (add_partial_subprogram, process_full_comp_unit)
10751 (read_file_scope, read_func_scope, read_lexical_block_scope)
10752 (read_call_site_scope, dwarf2_rnglists_process)
10753 (dwarf2_ranges_process, dwarf2_ranges_read)
10754 (dwarf_decode_lines_1, var_decode_location, new_symbol)
10755 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
10756 Update.
10757 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
10758 Update.
10759 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
10760 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
10761 (process_one_symbol): Change type of "section_offsets".
10762 * ctfread.c (get_objfile_text_range): Update.
10763 * coffread.c (coff_symtab_read, enter_linenos)
10764 (process_coff_symbol): Update.
10765 * coff-pe-read.c (add_pe_forwarded_sym): Update.
10766 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
10767
10768 2020-01-08 Tom Tromey <tromey@adacore.com>
10769
10770 * dwarf2read.c (parse_macro_definition): Use std::string.
10771 (parse_macro_definition): Likewise.
10772
10773 2020-01-08 Tom Tromey <tromey@adacore.com>
10774
10775 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
10776 (ATTR_ALLOC_CHUNK): Remove.
10777
10778 2020-01-08 Tom Tromey <tromey@adacore.com>
10779
10780 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
10781
10782 2020-01-08 Tom Tromey <tromey@adacore.com>
10783
10784 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
10785 (dwarf2_compute_name, open_dwo_file): Likewise.
10786 (process_enumeration_scope): Use std::vector.
10787 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
10788 (partial_die_info::fixup, dwarf2_start_subfile)
10789 (guess_full_die_structure_name, dwarf2_name): Likewise.
10790 (determine_prefix): Update.
10791 (guess_full_die_structure_name): Make return type const.
10792 (partial_die_full_name): Return unique_xmalloc_ptr.
10793 (DW_FIELD_ALLOC_CHUNK): Remove.
10794
10795 2020-01-07 Tom Tromey <tromey@adacore.com>
10796
10797 PR build/24937:
10798 * stap-probe.c (class stap_static_probe_ops): Add constructor.
10799
10800 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
10801
10802 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
10803
10804 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
10805
10806 * stack.c (print_frame_info): Move disassemble_next_line code
10807 inside source_print block.
10808
10809 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10810
10811 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
10812 gdb/signals.h, as we are now using native signal symbols.
10813
10814 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
10815
10816 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
10817 overflow by an early check of content vs threshold.
10818 * tui/tui-source.c (tui_source_window::line_is_displayed):
10819 Likewise.
10820
10821 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10822
10823 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
10824
10825 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
10826
10827 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
10828 export table if no section contains it's RVA.
10829
10830 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10831
10832 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
10833
10834 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
10835
10836 * source.c (print_source_lines_base): Set last_line_listed.
10837
10838 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
10839
10840 * tui/tui-disasm.c: Remove trailing spaces.
10841
10842 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10843 Pedro Alves <palves@redhat.com>
10844
10845 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
10846 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
10847 (windows_gdb_signal_to_target): New function, uses the above
10848 enumeration to convert GDB internal signal codes to equivalent
10849 Windows codes.
10850 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
10851 * windows-nat.c: Include "gdb_wait.h".
10852 (get_windows_debug_event): Extract the fatal exception from the
10853 exit status and convert to the equivalent Posix signal number.
10854 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
10855 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
10856 * gdbsupport/gdb_wait.c: New file, implements
10857 windows_status_to_termsig.
10858 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
10859 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
10860
10861 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
10862
10863 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
10864 show_layout.
10865
10866 2020-01-05 Luis Machado <luis.machado@linaro.org>
10867
10868 * aarch64-linux-nat.c
10869 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
10870 and bfd_mach_aarch64.
10871
10872 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10873
10874 * ui-file.c (stdio_file::can_emit_style_escape)
10875 (tee_file::can_emit_style_escape): Ensure style is used also on
10876 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
10877 to gdb_stdout.
10878 * main.c (set_gdb_data_directory): Use file style to output the
10879 warning that the given pathname is not a directory.
10880 * top.c (show_history_filename, gdb_safe_append_history)
10881 (show_gdb_datadir): Use file style.
10882
10883 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
10884
10885 * solib-target.c (struct lm_info_target):
10886 Change offsets to be a unique_xmalloc_ptr.
10887 (solib_target_relocate_section_addresses): Update.
10888
10889 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
10890
10891 * windows-nat.c (windows_clear_solib): Free so_list linked list.
10892
10893 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
10894
10895 * MAINTAINERS (Write After Approval): Add myself.
10896
10897 2020-01-02 Luis Machado <luis.machado@linaro.org>
10898
10899 * proc-service.c (get_ps_regcache): Remove reference to obsolete
10900 Cell BE architecture.
10901 * target.h (struct target_ops) <thread_architecture>: Likewise.
10902
10903 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
10904
10905 * Makefile.in: Use INSTALL_PROGRAM_ENV.
10906
10907 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
10908
10909 * MAINTAINERS (Write After Approval): Add myself.
10910
10911 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10912
10913 * gdbarch.sh: Update copyright year range of generated files.
10914
10915 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10916
10917 Update copyright year range in all GDB files.
10918
10919 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10920
10921 * copyright.py: Convert to Python 3.
10922
10923 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10924
10925 * copyright.py: Adapt after move of gnulib directory from gdb
10926 directory to toplevel directory.
10927
10928 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10929
10930 * copyright.py (main): Exit if run from the wrong directory.
10931
10932 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10933
10934 * top.c (print_gdb_version): Change copyright year to 2020.
10935
10936 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10937
10938 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
10939
10940 For older changes see ChangeLog-2019.
10941 \f
10942 Local Variables:
10943 mode: change-log
10944 left-margin: 8
10945 fill-column: 74
10946 version-control: never
10947 coding: utf-8
10948 End: