gdb: New maintenance command to print XML target description
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2
3 * target-descriptions.c (tdesc_architecture_name): Protect against
4 NULL pointer dereference.
5 (maint_print_xml_tdesc_cmd): New function.
6 (_initialize_target_descriptions): Register new 'maint print
7 xml-tdesc' command and give it the filename completer.
8 * NEWS: Mention new 'maint print xml-tdesc' command.
9
10 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
11
12 * target-descriptions.c (class tdesc_compatible_info): New class.
13 (struct target_desc): Change type of compatible vector.
14 (tdesc_compatible_p): Update for change in type of
15 target_desc::compatible.
16 (tdesc_compatible_info_list): New function.
17 (tdesc_compatible_info_arch_name): New function.
18 (tdesc_add_compatible): Update for change in type of
19 target_desc::compatible.
20 (print_c_tdesc::visit_pre): Likewise.
21
22 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
23
24 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
25 whitespace to underscore.
26 (maint_print_c_tdesc_cmd): Use fake filename for target
27 descriptions that came from the target.
28 (_initialize_target_descriptions): Add filename command completion
29 for 'maint print c-tdesc'.
30
31 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
32
33 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
34 lines.
35
36 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
37
38 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
39 lines.
40 (dwarf2_find_location_expression): Likewise.
41 (call_site_parameter_matches): Likewise.
42 (dwarf2_compile_expr_to_ax): Likewise.
43 (disassemble_dwarf_expression): Likewise.
44 (loclist_describe_location): Likewise.
45
46 2020-06-23 Pedro Alves <palves@redhat.com>
47
48 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
49 progspace-and-thread.h. Include scoped-mock-context.h instead.
50 (register_to_value_test): Use scoped_mock_context.
51 * regcache.c: Include "scoped-mock-context.h".
52 (cooked_read_test): Don't error out if a target is already pushed.
53 Use scoped_mock_context. Adjust.
54 * scoped-mock-context.h: New file.
55
56 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
57
58 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
59 initializer.
60 (ada_language::is_string_type_p): New member function.
61 * c-lang.c (c_language_data): Delete la_is_string_type_p
62 initializer.
63 (cplus_language_data): Likewise.
64 (asm_language_data): Likewise.
65 (minimal_language_data): Likewise.
66 * d-lang.c (d_language_data): Likewise.
67 * f-lang.c (f_is_string_type_p): Delete function, implementation
68 moved to f_language::is_string_type_p.
69 (f_language_data): Delete la_is_string_type_p initializer.
70 (f_language::is_string_type_p): New member function,
71 implementation from f_is_string_type_p.
72 * go-lang.c (go_is_string_type_p): Delete function, implementation
73 moved to go_language::is_string_type_p.
74 (go_language_data): Delete la_is_string_type_p initializer.
75 (go_language::is_string_type_p): New member function,
76 implementation from go_is_string_type_p.
77 * language.c (language_defn::is_string_type_p): Define new member
78 function.
79 (default_is_string_type_p): Make static, add comment copied from
80 header file.
81 (unknown_language_data): Delete la_is_string_type_p initializer.
82 (unknown_language::is_string_type_p): New member function.
83 (auto_language_data): Delete la_is_string_type_p initializer.
84 (auto_language::is_string_type_p): New member function.
85 * language.h (language_data): Delete la_is_string_type_p field.
86 (language_defn::is_string_type_p): Declare new function.
87 (default_is_string_type_p): Delete desclaration, move comment to
88 definition.
89 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
90 moved to m2_language::is_string_type_p.
91 (m2_language_data): Delete la_is_string_type_p initializer.
92 (m2_language::is_string_type_p): New member function,
93 implementation from m2_is_string_type_p.
94 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
95 initializer.
96 * opencl-lang.c (opencl_language_data): Likewise.
97 * p-lang.c (pascal_is_string_type_p): Delete function,
98 implementation moved to pascal_language::is_string_type_p.
99 (pascal_language_data): Delete la_is_string_type_p initializer.
100 (pascal_language::is_string_type_p): New member function,
101 implementation from pascal_is_string_type_p.
102 * rust-lang.c (rust_is_string_type_p): Delete function,
103 implementation moved to rust_language::is_string_type_p.
104 (rust_language_data): Delete la_is_string_type_p initializer.
105 (rust_language::is_string_type_p): New member function,
106 implementation from rust_is_string_type_p.
107 * valprint.c (val_print_scalar_or_string_type_p): Update call to
108 is_string_type_p.
109
110 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
111
112 * ada-lang.c (ada_language_data): Delete la_print_typedef
113 initializer.
114 (ada_language::print_typedef): New member function.
115 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
116 (cplus_language_data): Likewise.
117 (asm_language_data): Likewise.
118 (minimal_language_data): Likewise.
119 * d-lang.c (d_language_data): Likewise.
120 * f-lang.c (f_language_data): Likewise.
121 (f_language::print_typedef): New member function.
122 * go-lang.c (go_language_data): Delete la_print_typedef
123 initializer.
124 * language.c (language_defn::print_typedef): Define member
125 function.
126 (unknown_language_data): Delete la_print_typedef initializer.
127 (unknown_language::print_typedef): New member function.
128 (auto_language_data): Delete la_print_typedef initializer.
129 (auto_language::print_typedef): New member function.
130 * language.h (language_data): Delete la_print_typedef field.
131 (language_defn::print_typedef): Declare new member function.
132 (LA_PRINT_TYPEDEF): Update call to print_typedef.
133 (default_print_typedef): Delete declaration.
134 * m2-lang.c (m2_language_data): Delete la_print_typedef
135 initializer.
136 (m2_language::print_typedef): New member function.
137 * objc-lang.c (objc_language_data): Delete la_print_typedef
138 initializer.
139 * opencl-lang.c (opencl_language_data): Likewise.
140 * p-lang.c (pascal_language_data): Likewise.
141 (pascal_language::print_typedef): New member function.
142 * rust-lang.c (rust_print_typedef): Delete function,
143 implementation moved to rust_language::print_typedef.
144 (rust_language): Delete la_print_typedef initializer.
145 (rust_language::print_typedef): New member function,
146 implementation from rust_print_typedef.
147 * typeprint.c (default_print_typedef): Delete.
148
149 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
150
151 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
152 (ada_language::printstr): New member function.
153 * c-lang.c (c_language_data): Delete la_printstr initializer.
154 (cplus_language_data): Likewise.
155 (asm_language_data): Likewise.
156 (minimal_language_data): Likewise.
157 * d-lang.c (d_language_data): Likewise.
158 * f-lang.c (f_printstr): Rename to f_language::printstr.
159 (f_language_data): Delete la_printstr initializer.
160 (f_language::printstr): New member function, implementation from
161 f_printstr.
162 * go-lang.c (go_language_data): Delete la_printstr initializer.
163 * language.c (language_defn::printstr): Define new member
164 function.
165 (unk_lang_printstr): Delete.
166 (unknown_language_data): Delete la_printstr initializer.
167 (unknown_language::printstr): New member function.
168 (auto_language_data): Delete la_printstr initializer.
169 (auto_language::printstr): New member function.
170 * language.h (language_data): Delete la_printstr field.
171 (language_defn::printstr): Declare new member function.
172 (LA_PRINT_STRING): Update call to printstr.
173 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
174 (m2_language_data): Delete la_printstr initializer.
175 (m2_language::printstr): New member function, implementation from
176 m2_printstr.
177 * objc-lang.c (objc_language_data): Delete la_printstr
178 initializer.
179 * opencl-lang.c (opencl_language_data): Likewise.
180 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
181 (pascal_language_data): Delete la_printstr initializer.
182 (pascal_language::printstr): New member function, implementation
183 from pascal_printstr.
184 * p-lang.h (pascal_printstr): Delete declaration.
185 * rust-lang.c (rust_printstr): Update header comment.
186 (rust_language_data): Delete la_printstr initializer.
187 (rust_language::printstr): New member function.
188
189 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
190
191 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
192 (ada_language::printchar): New member function.
193 * c-lang.c (c_language_data): Delete la_printchar initializer.
194 (cplus_language_data): Likewise.
195 (asm_language_data): Likewise.
196 (minimal_language_data): Likewise.
197 * d-lang.c (d_language_data): Likewise.
198 * f-lang.c (f_printchar): Rename to f_language::printchar.
199 (f_language_data): Delete la_printchar initializer.
200 (f_language::printchar): New member function, implementation from
201 f_printchar.
202 * go-lang.c (go_language_data): Delete la_printchar initializer.
203 * language.c (unk_lang_printchar): Delete.
204 (language_defn::printchar): Define new member function.
205 (unknown_language_data): Delete la_printchar initializer.
206 (unknown_language::printchar): New member function.
207 (auto_language_data): Delete la_printchar initializer.
208 (auto_language::printchar): New member function.
209 * language.h (language_data): Delete la_printchar field.
210 (language_defn::printchar): Declare new member function.
211 (LA_PRINT_CHAR): Update call to printchar.
212 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
213 (m2_language::printchar): New member function.
214 * objc-lang.c (objc_language_data): Delete la_printchar
215 initializer.
216 * opencl-lang.c (opencl_language_data): Likewise.
217 * p-lang.c (pascal_language_data): Delete la_printchar
218 initializer.
219 (pascal_language::printchar): New member function.
220 * rust-lang.c (rust_printchar): Rename to
221 rust_language::printchar.
222 (rust_language_data): Delete la_printchar initializer.
223 (rust_language::printchar): New member function, implementation
224 from rust_printchar.
225
226 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
227
228 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
229 (ada_language_data): Delete la_emitchar initializer.
230 (ada_language::emitchar): New member function, implementation from
231 emit_char.
232 * c-lang.c (c_language_data): Delete la_emitchar initializer.
233 (cplus_language_data): Likewise.
234 (asm_language_data): Likewise.
235 (minimal_language_data): Likewise.
236 * d-lang.c (d_language_data): Likewise.
237 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
238 (f_language_data): Delete la_emitchar initializer.
239 (f_language::emitchar): New member function, implementation from
240 f_emit_char.
241 * go-lang.c (go_language_data): Delete la_emitchar initializer.
242 * language.c (unk_lang_emit_char): Delete.
243 (language_defn::emitchar): New member function definition.
244 (unknown_language_data): Delete la_emitchar initializer.
245 (unknown_language::emitchar): New member function.
246 (auto_language_data): Delete la_emitchar initializer.
247 (auto_language::emitchar): New member function.
248 * language.h (language_data): Delete la_emitchar field.
249 (language_defn::emitchar): New member field declaration.
250 (LA_EMIT_CHAR): Update call to emitchar.
251 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
252 (m2_language_data): Delete la_emitchar initializer.
253 (m2_language::emitchar): New member function, implementation from
254 m2_emit_char.
255 * objc-lang.c (objc_language_data): Delete la_emitchar
256 initializer.
257 * opencl-lang.c (opencl_language_data): Likewise.
258 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
259 (pascal_language_data): Delete la_emitchar initializer.
260 (pascal_language::emitchar): New member function, implementation
261 from pascal_emit_char.
262 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
263 (rust_language_data): Delete la_emitchar initializer.
264 (rust_language::emitchar): New member function, implementation
265 from rust_emitchar.
266
267 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
268
269 * ada-lang.c (resolve): Rename to ada_language::post_parser.
270 (ada_language_data): Delete la_post_parser initializer.
271 (ada_language::post_parser): New member function.
272 * c-lang.c (c_language_data): Delete la_post_parser initializer.
273 (cplus_language_data): Likewise.
274 (asm_language_data): Likewise.
275 (minimal_language_data): Likewise.
276 * d-lang.c (d_language_data): Likewise.
277 * f-lang.c (f_language_data): Likewise.
278 * go-lang.c (go_language_data): Likewise.
279 * language.c (unknown_language_data): Likewise.
280 (auto_language_data): Likewise.
281 * language.h (language_data): Delete la_post_parser field.
282 (language_defn::post_parser): New member function.
283 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
284 * objc-lang.c (objc_language_data): Likewise.
285 * opencl-lang.c (opencl_language_data): Likewise.
286 * p-lang.c (pascal_language_data): Likewise.
287 * parse.c (parse_exp_in_context): Update call to post_parser.
288 (null_post_parser): Delete definition.
289 * parser-defs.h (null_post_parser): Delete declaration.
290 * rust-lang.c (rust_language_data): Delete la_post_parser
291 initializer.
292
293 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
294
295 * ada-lang.c (parse): Rename to ada_language::parser.
296 (ada_language_data): Delete la_parser initializer.
297 (ada_language::parser): New member function, implementation from
298 parse.
299 * c-lang.c (c_language_data): Delete la_parser initializer.
300 (cplus_language_data): Likewise.
301 (asm_language_data): Likewise.
302 (minimal_language_data): Likewise.
303 * d-lang.c (d_language_data): Likewise.
304 (d_language::parser): New member function.
305 * f-lang.c (f_language_data): Delete la_parser initializer.
306 (f_language::parser): New member function.
307 * go-lang.c (go_language_data): Delete la_parser initializer.
308 (go_language::parser): New member function.
309 * language.c (unk_lang_parser): Delete.
310 (language_defn::parser): Define new member function.
311 (unknown_language_data): Delete la_parser initializer.
312 (unknown_language::parser): New member function.
313 (auto_language_data): Delete la_parser initializer.
314 (auto_language::parser): New member function.
315 * language.h (language_data): Delete la_parser field.
316 (language_defn::parser): Declare new member function.
317 * m2-lang.c (m2_language_data): Delete la_parser initializer.
318 (m2_language::parser): New member function.
319 * objc-lang.c (objc_language_data): Delete la_parser initializer.
320 * opencl-lang.c (opencl_language_data): Likewise.
321 * p-lang.c (pascal_language_data): Likewise.
322 (pascal_language::parser): New member function.
323 * parse.c (parse_exp_in_context): Update call to parser.
324 * rust-lang.c (rust_language_data): Delete la_parser initializer.
325 (rust_language::parser): New member function.
326
327 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
328
329 * top.c (print_gdb_configuration): Print --with-python-libdir
330 configuration value.
331
332 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
333
334 * NEWS: Mention change to the alias command.
335
336 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
337
338 * cli/cli-cmds.c (lookup_cmd_for_default_args)
339 (alias_command_completer)
340 (make_alias_options_def_group): New functions.
341 (alias_opts, alias_option_defs): New struct and array.
342 (alias_usage_error): Update usage.
343 (alias_command): Handles optional DEFAULT-ARGS... arguments.
344 Use option framework.
345 (_initialize_cli_cmds): Update alias command help.
346 Update aliases command help.
347 (show_user):
348 Add NULL for new default_args lookup_cmd argument.
349 (valid_command_p): Rename to validate_aliased_command.
350 Add NULL for new default_args lookup_cmd argument. Verify that the
351 aliased_command has no default args.
352 * cli/cli-decode.c (help_cmd): Show aliases definitions.
353 (lookup_cmd_1, lookup_cmd): New argument default_args.
354 (add_alias_cmd):
355 Add NULL for new default_args lookup_cmd argument.
356 (print_help_for_command): Show default args under the layout
357 alias some_alias = some_aliased_cmd some_alias_default_arg.
358 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
359 xfree default_args in destructor.
360 * cli/cli-script.c (process_next_line, do_define_command):
361 Add NULL for new default_args lookup_cmd argument.
362 * command.h: Declare new default_args argument in lookup_cmd
363 and lookup_cmd_1.
364 * completer.c (complete_line_internal_1):
365 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
366 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
367 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
368 Likewise.
369 * infcmd.c (_initialize_infcmd): Likewise.
370 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
371 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
372 * python/py-param.c (add_setshow_generic): Likewise.
373 * remote.c (_initialize_remote): Likewise.
374 * top.c (execute_command): Prepend default_args if command has some.
375 (set_verbose):
376 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
377 * tracepoint.c (validate_actionline, encode_actions_1):
378 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
379
380 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
381
382 * jit.c (jit_read_descriptor): Use bool as the return type.
383 (jit_breakpoint_re_set_internal): Use bool as the return type.
384 Invert the return value logic; return true if the jit breakpoint
385 has been successfully initialized.
386 (jit_inferior_init): Update the call to
387 jit_breakpoint_re_set_internal.
388
389 2020-06-22 Pedro Alves <palves@redhat.com>
390
391 PR gdb/25939
392 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
393 Use the current inferior instead. Don't return
394 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
395 wait again.
396 * sol-thread.c (sol_thread_target::wait): Don't reference
397 inferior_ptid.
398 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
399 (sol_update_thread_list_callback): Use the current inferior's pid
400 instead of inferior_ptid.
401
402 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
403
404 * procfs.c: Cleanup many comments.
405
406 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
407 (AFTER_WATCHFLAG): Replace by value.
408
409 (MAIN_PROC_NAME_FORMAT): Inline ...
410 (create_procinfo): ... here.
411
412 (procfs_debug_inferior): Remove SYS_exec handling.
413 (syscall_is_exec): Likewise.
414 (procfs_set_exec_trap): Likewise.
415
416 (syscall_is_lwp_exit): Inline in callers.
417 (syscall_is_exit): Likewise.
418 (syscall_is_exec): Likewise.
419 (syscall_is_lwp_create): Likewise.
420
421 (invalidate_cache): Remove #if 0 code.
422
423 (make_signal_thread_runnable): Remove.
424 (procfs_target::resume): Remove #if 0 code.
425
426 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
427
428 PR gdb/25939
429 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
430 call ...
431 (procfs_target::create_inferior): ... here.
432
433 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
434
435 * exec.c (validate_exec_file): Ensure the build-id is up to
436 date by calling reopen_exec_file (that checks file timestamp
437 to decide to re-read the file).
438
439 2020-06-18 Pedro Alves <palves@redhat.com>
440
441 PR gdb/25412
442 * gdbthread.h (delete_thread, delete_thread_silent)
443 (find_thread_ptid): Update comments.
444 * thread.c (current_thread_): New global.
445 (is_current_thread): Move higher, and reimplement.
446 (inferior_thread): Reimplement.
447 (set_thread_exited): Use bool. Add assertions.
448 (add_thread_silent): Simplify thread-reuse handling by always
449 calling delete_thread.
450 (delete_thread): Remove intro comment.
451 (find_thread_ptid): Skip exited threads.
452 (switch_to_thread_no_regs): Write to current_thread_.
453 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
454 INFERIOR_PTID. Clear current_thread_.
455
456 2020-06-18 Pedro Alves <palves@redhat.com>
457
458 * aix-thread.c (pd_update): Use switch_to_thread.
459
460 2020-06-18 Pedro Alves <palves@redhat.com>
461
462 * ravenscar-thread.c (ravenscar_thread_target): Update.
463 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
464 (ravenscar_thread_target::add_active_thread): ... this. Don't
465 set m_base_ptid here. Update to avoid referencing inferior_ptid.
466 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
467
468 2020-06-18 Pedro Alves <palves@redhat.com>
469
470 * nat/windows-nat.c (current_windows_thread): Remove.
471 * nat/windows-nat.h (current_windows_thread): Remove.
472 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
473 Adjust.
474 (display_selectors): Adjust to fetch the current
475 windows_thread_info based on inferior_ptid.
476 (fake_create_process): No longer write to current_windows_thread.
477 (windows_nat_target::get_windows_debug_event):
478 Don't set inferior_ptid or current_windows_thread.
479 (windows_nat_target::wait): Adjust to not rely on
480 current_windows_thread.
481 (do_initial_windows_stuff): Now a method of windows_nat_target.
482 Switch to the last_ptid thread.
483 (windows_nat_target::attach): Adjust.
484 (windows_nat_target::detach): Use switch_to_no_thread instead of
485 writing to inferior_ptid directly.
486 (windows_nat_target::create_inferior): Adjust.
487
488 2020-06-18 Pedro Alves <palves@redhat.com>
489
490 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
491
492 2020-06-18 Pedro Alves <palves@redhat.com>
493
494 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
495 after creating it, instead of writing to inferior_ptid. Don't
496 write to inferior_ptid.
497
498 2020-06-18 Pedro Alves <palves@redhat.com>
499
500 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
501
502 2020-06-18 Pedro Alves <palves@redhat.com>
503
504 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
505 it, instead of writing to inferior_ptid.
506
507 2020-06-18 Pedro Alves <palves@redhat.com>
508
509 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
510 to inferior_ptid.
511
512 2020-06-18 Pedro Alves <palves@redhat.com>
513
514 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
515 instead of writing to inferior_ptid directly.
516
517 2020-06-18 Pedro Alves <palves@redhat.com>
518
519 * corelow.c (core_target::close): Use switch_to_no_thread instead
520 of writing to inferior_ptid directly.
521 (add_to_thread_list, core_target_open): Use switch_to_thread
522 instead of writing to inferior_ptid directly.
523
524 2020-06-18 Pedro Alves <palves@redhat.com>
525
526 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
527 inferior_ptid.
528 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
529 inferior_ptid.
530 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
531 inferior_ptid directly.
532 (darwin_nat_target::init_thread_list): Switch to thread, instead
533 of writing to inferior_ptid.
534 (darwin_nat_target::attach): Don't write to inferior_ptid.
535 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
536
537 2020-06-18 Pedro Alves <palves@redhat.com>
538
539 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
540 thread.
541 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
542 Instead use switch_to_thread.
543 (gnu_nat_target::detach): Use switch_to_no_thread
544 instead of writing to inferior_ptid directly. Used passed-in
545 inferior instead of looking up the inferior by pid.
546
547 2020-06-18 Pedro Alves <palves@redhat.com>
548
549 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
550 inferior_ptid.
551
552 2020-06-18 Pedro Alves <palves@redhat.com>
553
554 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
555 inferior_ptid.
556 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
557 thread.
558 (nto_procfs_target::detach): Avoid referencing
559 inferior_ptid. Use switch_to_no_thread instead of writing to
560 inferior_ptid directly.
561 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
562 instead of writing to inferior_ptid directly.
563 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
564 to thread.
565
566 2020-06-18 Pedro Alves <palves@redhat.com>
567
568 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
569 after creating it, instead of writing to inferior_ptid.
570 (gdbsim_target_open): Use switch_to_no_thread instead of writing
571 to inferior_ptid directly.
572 (gdbsim_target::wait): Don't write to inferior_ptid.
573
574 2020-06-18 Pedro Alves <palves@redhat.com>
575
576 * remote.c (remote_target::remote_notice_new_inferior): Use
577 switch_to_thread instead of writing to inferior_ptid directly.
578 (remote_target::add_current_inferior_and_thread): Use
579 switch_to_no_thread instead of writing to inferior_ptid directly.
580 (extended_remote_target::attach): Use switch_to_inferior_no_thread
581 and switch_to_thread instead of using set_current_inferior or
582 writing to inferior_ptid directly.
583
584 2020-06-18 Pedro Alves <palves@redhat.com>
585
586 * tracectf.c (ctf_target_open): Switch to added thread instead of
587 writing to inferior_ptid directly.
588 (ctf_target::close): Use switch_to_no_thread instead of writing to
589 inferior_ptid directly.
590
591 2020-06-18 Pedro Alves <palves@redhat.com>
592
593 * tracefile-tfile.c (tfile_target_open): Don't write to
594 inferior_ptid directly, instead switch to added thread.
595 (tfile_target::close): Use switch_to_no_thread instead of writing
596 to inferior_ptid directly.
597
598 2020-06-18 Pedro Alves <palves@redhat.com>
599
600 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
601 (procfs_target::detach): Use switch_to_no_thread
602 instead of writing to inferior_ptid directly.
603 (do_attach): Change return type to void. Switch to the added
604 thread.
605 (procfs_target::create_inferior): Switch to the added thread.
606 (procfs_do_thread_registers): Don't write to inferior_ptid.
607
608 2020-06-18 Pedro Alves <palves@redhat.com>
609
610 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
611 of writing to inferior_ptid.
612 (scoped_restore_exited_inferior): Delete.
613 (handle_vfork_child_exec_or_exit): Simplify using
614 scoped_restore_current_pspace_and_thread. Use switch_to_thread
615 instead of writing to inferior_ptid.
616 (THREAD_STOPPED_BY): Delete.
617 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
618 (thread_stopped_by_hw_breakpoint): Delete.
619 (save_waitstatus): Use
620 scoped_restore_current_thread+switch_to_thread, and call
621 target_stopped_by_watchpoint instead of
622 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
623 instead of thread_stopped_by_sw_breakpoint, and
624 target_stopped_by_hw_breakpoint instead of
625 thread_stopped_by_hw_breakpoint.
626 (handle_inferior_event)
627 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
628 inferior_ptid directly, nor
629 set_current_inferior/set_current_program_space. Use
630 switch_to_thread / switch_to_inferior_no_thread instead.
631
632 2020-06-18 Pedro Alves <palves@redhat.com>
633
634 * target.c (generic_mourn_inferior): Use switch_to_no_thread
635 instead of writing to inferior_ptid.
636
637 2020-06-18 Pedro Alves <palves@redhat.com>
638
639 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
640 added thread.
641 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
642 to the added thread.
643 (inf_ptrace_target::detach_success): Use switch_to_no_thread
644 instead of writing to inferior_ptid.
645
646 2020-06-18 Pedro Alves <palves@redhat.com>
647
648 * gdbarch-selftests.c: Include "progspace-and-thread.h".
649 (register_to_value_test): Mock a program_space too. Heap-allocate
650 the address space. Don't write to inferior_ptid. Use
651 switch_to_thread instead.
652
653 2020-06-18 Pedro Alves <palves@redhat.com>
654
655 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
656 Delete.
657 (find_signalled_thread()): New, factored out from
658 linux_make_corefile_notes and adjusted to handle exited threads.
659 (linux_make_corefile_notes): Adjust to use the new
660 find_signalled_thread.
661
662 2020-06-18 Pedro Alves <palves@redhat.com>
663
664 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
665 of saving/restoring inferior_ptid.
666
667 2020-06-17 Tom Tromey <tom@tromey.com>
668
669 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
670 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
671 declare.
672 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
673
674 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
675
676 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
677 of partial symtabs.
678
679 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
680
681 * regformats/reg-arm.dat: Remove.
682 * regformats/reg-bfin.dat: Remove.
683 * regformats/reg-cris.dat: Remove.
684 * regformats/reg-crisv32.dat: Remove.
685 * regformats/reg-m32r.dat: Remove.
686 * regformats/reg-tilegx.dat: Remove.
687 * regformats/reg-tilegx32.dat: Remove.
688
689 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
690
691 * features/Makefile (WHICH): Remove arm files.
692 * regformats/arm/arm-with-iwmmxt.dat: Remove.
693 * regformats/arm/arm-with-neon.dat: Remove.
694 * regformats/arm/arm-with-vfpv2.dat: Remove.
695 * regformats/arm/arm-with-vfpv3.dat: Remove.
696
697 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
698
699 * features/Makefile (XMLTOC): Remove rx.xml.
700
701 2020-06-17 Pedro Alves <palves@redhat.com>
702
703 * gdbthread.h (thread_control_state) <trap_expected> Update
704 comments.
705
706 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
707
708 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
709 ada_language::lookup_symbol_nonlocal.
710 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
711 (ada_language::lookup_symbol_nonlocal): New member function,
712 implementation from ada_lookup_symbol_nonlocal.
713 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
714 initializer.
715 (cplus_language_data): Delete la_lookup_symbol_nonlocal
716 initializer.
717 (cplus_language::lookup_symbol_nonlocal): New member function.
718 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
719 (minimal_language_data) Likewise.
720 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
721 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
722 initializer.
723 (d_language::lookup_symbol_nonlocal): New member function.
724 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
725 initializer.
726 (f_language::lookup_symbol_nonlocal): New member function.
727 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
728 initializer.
729 * language.c (unknown_language_data): Likewise.
730 (auto_language_data): Likewise.
731 * language.h (language_data): Delete la_lookup_symbol_nonlocal
732 field.
733 (language_defn::lookup_symbol_nonlocal): New member function.
734 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
735 initializer.
736 * objc-lang.c (objc_language_data): Likewise.
737 * opencl-lang.c (opencl_language_data): Likewise.
738 * p-lang.c (pascal_language_data): Likewise.
739 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
740 rust_language::lookup_symbol_nonlocal.
741 (rust_language_data): Delete la_lookup_symbol_nonlocal
742 initializer.
743 (rust_language::lookup_symbol_nonlocal): New member function,
744 implementation from rust_lookup_symbol_nonlocal.
745 * symtab.c (lookup_symbol_aux): Update call to
746 lookup_symbol_nonlocal.
747 (basic_lookup_symbol_nonlocal): Rename to...
748 (language_defn::lookup_symbol_nonlocal): ...this, and update
749 header comment. Remove language_defn parameter, and replace with
750 uses of `this'.
751 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
752
753 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
754
755 * ada-lang.c (ada_language_data): Delete la_value_print_inner
756 initializer.
757 (ada_language::value_print_inner): New member function.
758 * c-lang.c (c_language_data): Delete la_value_print_inner
759 initializer.
760 (cplus_language_data): Likewise.
761 (asm_language_data): Likewise.
762 (minimal_language_data): Likewise.
763 * d-lang.c (d_language_data): Likewise.
764 (d_language::value_print_inner): New member function.
765 * f-lang.c (f_language_data): Delete la_value_print_inner
766 initializer.
767 (f_language::value_print_inner): New member function.
768 * f-lang.h (f_value_print_innner): Rename to...
769 (f_value_print_inner): ...this (note spelling of 'inner').
770 * f-valprint.c (f_value_print_innner): Rename to...
771 (f_value_print_inner): ...this (note spelling of 'inner').
772 * go-lang.c (go_language_data): Delete la_value_print_inner
773 initializer.
774 (go_language::value_print_inner): New member function.
775 * language.c (language_defn::value_print_inner): Define new member
776 function.
777 (unk_lang_value_print_inner): Delete.
778 (unknown_language_data): Delete la_value_print_inner initializer.
779 (unknown_language::value_print_inner): New member function.
780 (auto_language_data): Delete la_value_print_inner initializer.
781 (auto_language::value_print_inner): New member function.
782 * language.h (language_data): Delete la_value_print_inner field.
783 (language_defn::value_print_inner): Delcare new member function.
784 * m2-lang.c (m2_language_data): Delete la_value_print_inner
785 initializer.
786 (m2_language::value_print_inner): New member function.
787 * objc-lang.c (objc_language_data): Delete la_value_print_inner
788 initializer.
789 * opencl-lang.c (opencl_language_data): Likewise.
790 * p-lang.c (pascal_language_data): Likewise.
791 (pascal_language::value_print_inner): New member function.
792 * rust-lang.c (rust_language_data): Delete la_value_print_inner
793 initializer.
794 (rust_language::value_print_inner): New member function.
795 * valprint.c (do_val_print): Update call to value_print_inner.
796
797 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
798
799 * ada-lang.c (ada_language_data): Delete la_value_print
800 initializer.
801 (ada_language::value_print): New member function.
802 * c-lang.c (c_language_data): Delete la_value_print initializer.
803 (cplus_language_data): Likewise.
804 (asm_language_data): Likewise.
805 (minimal_language_data): Likewise.
806 * d-lang.c (d_language_data): Likewise.
807 * f-lang.c (f_language_data): Likewise.
808 * go-lang.c (go_language_data): Likewise.
809 * language.c (unk_lang_value_print): Delete.
810 (language_defn::value_print): Define new member function.
811 (unknown_language_data): Delete la_value_print initializer.
812 (unknown_language::value_print): New member function.
813 (auto_language_data): Delete la_value_print initializer.
814 (auto_language::value_print): New member function.
815 * language.h (language_data): Delete la_value_print field.
816 (language_defn::value_print): Declare new member function.
817 (LA_VALUE_PRINT): Update call to value_print.
818 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
819 * objc-lang.c (objc_language_data): Likewise.
820 * opencl-lang.c (opencl_language_data): Likewise.
821 * p-lang.c (pascal_language_data): Likewise.
822 (pascal_language::value_print): New member function.
823 * rust-lang.c (rust_language_data): Delete la_value_print
824 initializer.
825
826 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
827
828 * ada-lang.c (ada_watch_location_expression): Rename to
829 ada_language::watch_location_expression.
830 (ada_language_data): Delete la_watch_location_expression
831 initializer.
832 (ada_language::watch_location_expression): New member function,
833 implementation from ada_watch_location_expression.
834 * breakpoint.c (watch_command_1): Update call to
835 watch_location_expression.
836 * c-lang.c (c_watch_location_expression): Rename to
837 language_defn::watch_location_expression.
838 (c_language_data): Delete la_watch_location_expression
839 initializer.
840 (cplus_language_data): Likewise.
841 (asm_language_data): Likewise.
842 (minimal_language_data): Likewise.
843 * c-lang.h (c_watch_location_expression): Delete declaration.
844 * d-lang.c (d_language_data): Delete la_watch_location_expression
845 initializer.
846 * f-lang.c (f_language_data): Likewise.
847 * go-lang.c (go_language_data): Likewise.
848 * language.c (language_defn::watch_location_expression): Member
849 function implementation from c_watch_location_expression.
850 (unknown_language_data): Delete la_watch_location_expression
851 initializer.
852 (auto_language_data): Likewise.
853 * language.h (language_data): Delete la_watch_location_expression
854 field.
855 (language_defn::watch_location_expression): Declare new member
856 function.
857 * m2-lang.c (m2_language_data): Delete
858 la_watch_location_expression initializer.
859 * objc-lang.c (objc_language_data): Likewise.
860 * opencl-lang.c (opencl_language_data): Likewise.
861 * p-lang.c (pascal_language_data): Likewise.
862 * rust-lang.c (rust_watch_location_expression): Rename to
863 rust_language::watch_location_expression.
864 (rust_language_data): Delete la_watch_location_expression
865 initializer.
866 (rust_language::watch_location_expression): New member function,
867 implementation from rust_watch_location_expression.
868
869 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
870
871 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
872 ada_language::collect_symbol_completion_matches.
873 (ada_language_data): Delete la_collect_symbol_completion_matches
874 initializer.
875 (ada_language::collect_symbol_completion_matches): New member
876 function, implementation from
877 ada_collect_symbol_completion_matches.
878 * c-lang.c (c_language_data): Delete
879 la_collect_symbol_completion_matches initializer.
880 (cplus_language_data): Likewise.
881 (asm_language_data): Likewise.
882 (minimal_language_data): Likewise.
883 * d-lang.c (d_language_data): Likewise.
884 * f-lang.c (f_collect_symbol_completion_matches): Rename to
885 f_language::collect_symbol_completion_matches.
886 (f_language_data): Delete la_collect_symbol_completion_matches
887 initializer.
888 (f_language::collect_symbol_completion_matches) New member
889 function, implementation from f_collect_symbol_completion_matches.
890 * go-lang.c (go_language_data): Delete
891 la_collect_symbol_completion_matches initializer.
892 * language.c (unknown_language_data): Likewise.
893 (auto_language_data): Likewise.
894 * language.h (language_data): Delete
895 la_collect_symbol_completion_matches field.
896 (language_defn::collect_symbol_completion_matches): New member
897 function.
898 * m2-lang.c (m2_language_data): Delete
899 la_collect_symbol_completion_matches initializer.
900 * objc-lang.c (objc_language_data): Likewise.
901 * opencl-lang.c (opencl_language_data): Likewise.
902 * p-lang.c (pascal_language_data): Likewise.
903 * rust-lang.c (rust_language_data): Likewise.
904 * symtab.c (default_collect_symbol_completion_matches): Delete.
905 (collect_symbol_completion_matches): Update call to
906 collect_symbol_completion_matches.
907 (collect_symbol_completion_matches_type): Likewise.
908 * symtab.h (default_collect_symbol_completion_matches): Delete
909 declaration.
910
911 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
912
913 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
914 (ada_language_data): Delete la_word_break_characters initializer.
915 (ada_language::word_break_characters): New member function.
916 * c-lang.c (c_language_data): Delete la_word_break_characters
917 initializer.
918 (cplus_language_data): Likewise.
919 (asm_language_data): Likewise.
920 (minimal_language_data): Likewise.
921 * completer.c: Update global comment.
922 (advance_to_expression_complete_word_point): Update call to
923 word_break_characters.
924 (complete_files_symbols): Likewise.
925 (complete_line_internal_1): Likewise.
926 (default_completer_handle_brkchars): Likewise.
927 (skip_quoted_chars): Likewise.
928 * d-lang.c (d_language_data): Delete la_word_break_characters
929 initializer.
930 * f-lang.c (f_word_break_characters): Delete.
931 (f_language_data): Delete la_word_break_characters initializer.
932 (f_language::word_break_characters): New member function.
933 * go-lang.c (go_language_data): Delete la_word_break_characters
934 initializer.
935 * language.c (unknown_language_data): Likewise.
936 (auto_language_data): Likewise.
937 * language.h (default_word_break_characters): Move declaration to
938 earlier in the file.
939 (language_data): Delete la_word_break_characters field.
940 (language_defn::word_break_characters): New member function.
941 * m2-lang.c (m2_language_data): Delete la_word_break_characters
942 initializer.
943 * objc-lang.c (objc_language_data): Likewise.
944 * opencl-lang.c (opencl_language_data): Likewise.
945 * p-lang.c (pascal_language_data): Likewise.
946 * rust-lang.c (rust_language_data): Likewise.
947
948 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
949
950 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
951 (ada_language_data): Delete la_get_symbol_name_matcher
952 initializer.
953 (language_defn::get_symbol_name_matcher_inner): New member
954 function.
955 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
956 initializer.
957 (cplus_language_data): Likewise.
958 (cplus_language::get_symbol_name_matcher_inner): New member
959 function.
960 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
961 (minimal_language_data): Likewise.
962 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
963 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
964 initializer.
965 * dictionary.c (iter_match_first_hashed): Update call to
966 get_symbol_name_matcher.
967 (iter_match_next_hashed): Likewise.
968 (iter_match_next_linear): Likewise.
969 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
970 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
971 initializer.
972 (f_language::get_symbol_name_matcher_inner): New member function.
973 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
974 initializer.
975 * language.c (default_symbol_name_matcher): Update header comment,
976 make static.
977 (language_defn::get_symbol_name_matcher): New definition.
978 (language_defn::get_symbol_name_matcher_inner): Likewise.
979 (get_symbol_name_matcher): Delete.
980 (unknown_language_data): Delete la_get_symbol_name_matcher
981 initializer.
982 (auto_language_data): Likewise.
983 * language.h (language_data): Delete la_get_symbol_name_matcher
984 field.
985 (language_defn::get_symbol_name_matcher): New member function.
986 (language_defn::get_symbol_name_matcher_inner): Likewise.
987 (default_symbol_name_matcher): Delete declaration.
988 * linespec.c (find_methods): Update call to
989 get_symbol_name_matcher.
990 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
991 initializer.
992 * minsyms.c (lookup_minimal_symbol): Update call to
993 get_symbol_name_matcher.
994 (iterate_over_minimal_symbols): Likewise.
995 * objc-lang.c (objc_language_data): Delete
996 la_get_symbol_name_matcher initializer.
997 * opencl-lang.c (opencl_language_data): Likewise.
998 * p-lang.c (pascal_language_data): Likewise.
999 * psymtab.c (psymbol_name_matches): Update call to
1000 get_symbol_name_matcher.
1001 * rust-lang.c (rust_language_data): Delete
1002 la_get_symbol_name_matcher initializer.
1003 * symtab.c (symbol_matches_search_name): Update call to
1004 get_symbol_name_matcher.
1005 (compare_symbol_name): Likewise.
1006
1007 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1008
1009 * ada-lang.c (ada_language_data): Delete la_compute_program
1010 initializer.
1011 * c-lang.c (c_language_data): Likewise.
1012 (c_language::compute_program): New member function.
1013 (cplus_language_data): Delete la_compute_program initializer.
1014 (cplus_language::compute_program): New member function.
1015 (asm_language_data): Delete la_compute_program initializer.
1016 (minimal_language_data): Likewise.
1017 * c-lang.h (c_compute_program): Update comment.
1018 (cplus_compute_program): Likewise.
1019 * compile/compile-c-support.c (c_compute_program): Likewise.
1020 (cplus_compute_program): Likewise.
1021 * compile/compile.c (compile_to_object): Update call to
1022 la_compute_program.
1023 * d-lang.c (d_language_data): Delete la_compute_program
1024 initializer.
1025 * f-lang.c (f_language_data): Likewise.
1026 * go-lang.c (go_language_data): Likewise.
1027 * language.c (unknown_language_data): Likewise.
1028 (auto_language_data): Likewise.
1029 * language.h (language_data): Delete la_compute_program field.
1030 (language_defn::compute_program): New member function.
1031 * m2-lang.c (m2_language_data): Delete la_compute_program
1032 initializer.
1033 * objc-lang.c (objc_language_data): Likewise.
1034 * opencl-lang.c (opencl_language_data): Likewise.
1035 * p-lang.c (pascal_language_data): Likewise.
1036 * rust-lang.c (rust_language_data): Likewise.
1037
1038 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1039
1040 * ada-lang.c (ada_language_data) Delete
1041 la_class_name_from_physname initializer.
1042 * c-lang.c (c_language_data): Likewise.
1043 (cplus_language_data): Likewise.
1044 (cplus_language::class_name_from_physname): New member function.
1045 (asm_language_data): Delete la_class_name_from_physname
1046 initializer.
1047 (minimal_language_data): Likewise.
1048 * d-lang.c (d_language_data): Likewise.
1049 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
1050 method on language_defn class.
1051 (guess_full_die_structure_name): Likewise.
1052 * f-lang.c (f_language_data): Delete la_class_name_from_physname
1053 initializer.
1054 * go-lang.c (go_language_data): Likewise.
1055 * language.c (language_class_name_from_physname): Delete.
1056 (unk_lang_class_name): Delete.
1057 (unknown_language_data): Delete la_class_name_from_physname
1058 initializer.
1059 (auto_language_data): Likewise.
1060 * language.h (language_data): Delete la_class_name_from_physname
1061 field.
1062 (language_defn::class_name_from_physname): New function.
1063 (language_class_name_from_physname): Delete declaration.
1064 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
1065 initializer.
1066 * objc-lang.c (objc_language_data): Likewise.
1067 * opencl-lang.c (opencl_language_data): Likewise.
1068 * p-lang.c (pascal_language_data): Likewise.
1069 * rust-lang.c (rust_language_data): Likewise.
1070
1071 2020-06-16 Tom Tromey <tom@tromey.com>
1072
1073 * tui/tui-data.h (STATUS_NAME): New macro.
1074 * tui/tui-layout.c (tui_remove_some_windows)
1075 (initialize_known_windows, tui_register_window)
1076 (tui_layout_split::remove_windows, initialize_layouts)
1077 (tui_new_layout_command): Don't use hard-coded window names.
1078
1079 2020-06-16 Tom Tromey <tom@tromey.com>
1080
1081 PR tui/25348:
1082 * tui/tui.c (tui_ensure_readline_initialized): Rename from
1083 tui_initialize_readline. Only run once. Call rl_initialize.
1084 * tui/tui.h (tui_ensure_readline_initialized): Rename from
1085 tui_initialize_readline.
1086 * tui/tui-io.c (tui_setup_io): Call
1087 tui_ensure_readline_initialized.
1088 * tui/tui-interp.c (tui_interp::init): Update.
1089
1090 2020-06-16 Tom Tromey <tom@tromey.com>
1091
1092 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
1093 Also preserve the status window.
1094
1095 2020-06-16 Tom Tromey <tom@tromey.com>
1096
1097 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
1098 where m_window==nullptr.
1099
1100 2020-06-15 Tom Tromey <tromey@adacore.com>
1101
1102 * windows-nat.c (windows_nat::handle_output_debug_string):
1103 Update.
1104 (windows_nat::handle_ms_vc_exception): Update.
1105 * target.h (target_read_string): Change API.
1106 * target.c (target_read_string): Change API.
1107 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
1108 Update.
1109 * solib-frv.c (frv_current_sos): Update.
1110 * solib-dsbt.c (dsbt_current_sos): Update.
1111 * solib-darwin.c (darwin_current_sos): Update.
1112 * linux-thread-db.c (inferior_has_bug): Update.
1113 * expprint.c (print_subexp_standard): Update.
1114 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
1115 (ada_exception_message_1): Update.
1116
1117 2020-06-15 Tom Tromey <tromey@adacore.com>
1118
1119 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
1120
1121 2020-06-15 Tom Tromey <tromey@adacore.com>
1122
1123 * valprint.c (read_string): Update comment.
1124 * target.c (MIN): Remove.
1125 (target_read_string): Rewrite.
1126
1127 2020-06-15 Tom Tromey <tromey@adacore.com>
1128
1129 * corefile.c (read_memory_string): Remove.
1130 * ada-valprint.c (ada_value_print_ptr): Update.
1131 * ada-lang.h (ada_tag_name): Change return type.
1132 * ada-lang.c (type_from_tag): Update.
1133 (ada_tag_name_from_tsd): Change return type. Use
1134 target_read_string.
1135 (ada_tag_name): Likewise.
1136 * gdbcore.h (read_memory_string): Don't declare.
1137
1138 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
1139
1140 * symtab.c (rbreak_command): Ignore Windows drive colon.
1141
1142 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
1143
1144 * NEWS: Mention removed GDBserver host support.
1145
1146 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
1147
1148 * features/riscv/rebuild-csr-xml.sh: Updated.
1149
1150 2020-06-11 Tom Tromey <tom@tromey.com>
1151
1152 PR gdb/18318:
1153 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
1154
1155 2020-06-09 Jonny Grant <jg@jguk.org>
1156 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
1157
1158 * main.c (captured_main_1): Don't print new line after help.
1159 (print_gdb_help): add mailing list and IRC channel information
1160 to --help. Add new lines between items in the footer. Remove
1161 quotes around bug url.
1162
1163 2020-06-11 Keith Seitz <keiths@redhat.com>
1164
1165 PR gdb/21356
1166 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
1167 Resolve typedefs for type length calculations.
1168
1169 2020-06-10 Tom de Vries <tdevries@suse.de>
1170
1171 PR ada/24713
1172 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
1173 (write_psymbols): Enable .gdb_index for ada.
1174 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
1175 ada.
1176
1177 2020-06-10 Tom de Vries <tdevries@suse.de>
1178
1179 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
1180 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
1181 namei" instead of "const char *name" argument.
1182 (dw2_map_matching_symbols): Use "offset_type namei" variant of
1183 dw2_symtab_iter_init.
1184
1185 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1186
1187 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
1188 to use type::field and field::type instead.
1189
1190 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1191
1192 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
1193 to use field::type instead.
1194
1195 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1196
1197 * gdbtypes.h (struct field) <type, set_type>: New methods.
1198 Rename `type` field to...
1199 <m_type>: ... this. Change references throughout to use type or
1200 set_type methods.
1201 (FIELD_TYPE): Use field::type. Change call sites that modify
1202 the field's type to use field::set_type instead.
1203
1204 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1205
1206 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
1207 to use type::index_type instead.
1208
1209 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
1210
1211 * gdbtypes.h (struct type) <index_type, set_index_type>: New
1212 methods.
1213 (TYPE_INDEX_TYPE): Use type::index_type.
1214 * gdbtypes.c (create_array_type_with_stride): Likewise.
1215
1216 2020-06-07 Tom Tromey <tom@tromey.com>
1217
1218 * valprint.c (generic_val_print_float): Remove "embedded_offset"
1219 parameter.
1220 (generic_value_print): Update.
1221
1222 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
1223
1224 Revert commit 982a38f60b0.
1225 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
1226
1227 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
1228
1229 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
1230 avoid use after free.
1231
1232 2020-06-05 Tom de Vries <tdevries@suse.de>
1233
1234 * NEWS: Fix typos.
1235
1236 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
1237
1238 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
1239 the per_bfd object.
1240 (dwarf2_read_debug_names): Likewise.
1241 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
1242 object when re-using a per_bfd object with an index.
1243
1244 2020-06-03 Tom de Vries <tdevries@suse.de>
1245
1246 PR symtab/26046
1247 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
1248 children for C++.
1249 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
1250 DW_TAG_subprogram.
1251
1252 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1253
1254 * ada-lang.c (ada_language_data): Delete skip_trampoline
1255 initializer.
1256 * c-lang.c (c_language_data): Likewise.
1257 (cplus_language_data): Likewise.
1258 (cplus_language::skip_trampoline): New member function.
1259 (asm_language_data): Delete skip_trampoline initializer.
1260 (minimal_language_data): Likewise.
1261 * d-lang.c (d_language_data): Likewise.
1262 * f-lang.c (f_language_data): Likewise.
1263 * go-lang.c (go_language_data): Likewise.
1264 * language.c (unk_lang_trampoline): Delete function.
1265 (skip_language_trampoline): Update.
1266 (unknown_language_data): Delete skip_trampoline initializer.
1267 (auto_language_data): Likewise.
1268 * language.h (language_data): Delete skip_trampoline field.
1269 (language_defn::skip_trampoline): New function.
1270 * m2-lang.c (m2_language_data): Delete skip_trampoline
1271 initializer.
1272 * objc-lang.c (objc_skip_trampoline): Delete function, move
1273 implementation to objc_language::skip_trampoline.
1274 (objc_language_data): Delete skip_trampoline initializer.
1275 (objc_language::skip_trampoline): New member function with
1276 implementation from objc_skip_trampoline.
1277 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
1278 initializer.
1279 * p-lang.c (pascal_language_data): Likewise.
1280 * rust-lang.c (rust_language_data): Likewise.
1281
1282 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1283
1284 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
1285 (ada_language::demangle): New member function.
1286 * c-lang.c (c_language_data): Delete la_demangle initializer.
1287 (cplus_language_data): Delete la_demangle initializer.
1288 (cplus_language::demangle): New member function.
1289 (asm_language_data): Delete la_demangle initializer.
1290 (minimal_language_data): Delete la_demangle initializer.
1291 * d-lang.c (d_language_data): Delete la_demangle initializer.
1292 (d_language::demangle): New member function.
1293 * f-lang.c (f_language_data): Delete la_demangle initializer.
1294 (f_language::demangle): New member function.
1295 * go-lang.c (go_language_data): Delete la_demangle initializer.
1296 (go_language::demangle): New member function.
1297 * language.c (language_demangle): Update.
1298 (unk_lang_demangle): Delete.
1299 (unknown_language_data): Delete la_demangle initializer.
1300 (unknown_language::demangle): New member function.
1301 (auto_language_data): Delete la_demangle initializer.
1302 (auto_language::demangle): New member function.
1303 * language.h (language_data): Delete la_demangle field.
1304 (language_defn::demangle): New function.
1305 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
1306 * objc-lang.c (objc_language_data): Delete la_demangle
1307 initializer.
1308 (objc_language::demangle): New member function.
1309 * opencl-lang.c (opencl_language_data): Delete la_demangle
1310 initializer.
1311 * p-lang.c (pascal_language_data): Likewise.
1312 * rust-lang.c (rust_language_data): Likewise.
1313 (rust_language::demangle): New member function.
1314
1315 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1316
1317 * ada-lang.c (ada_language_data): Delete la_print_type
1318 initializer.
1319 (ada_language::print_type): New member function.
1320 * c-lang.c (c_language_data): Delete la_print_type initializer.
1321 (c_language::print_type): New member function.
1322 (cplus_language_data): Delete la_print_type initializer.
1323 (cplus_language::print_type): New member function.
1324 (asm_language_data): Delete la_print_type initializer.
1325 (asm_language::print_type): New member function.
1326 (minimal_language_data): Delete la_print_type initializer.
1327 (minimal_language::print_type): New member function.
1328 * d-lang.c (d_language_data): Delete la_print_type initializer.
1329 (d_language::print_type): New member function.
1330 * f-lang.c (f_language_data): Delete la_print_type initializer.
1331 (f_language::print_type): New member function.
1332 * go-lang.c (go_language_data): Delete la_print_type initializer.
1333 (go_language::print_type): New member function.
1334 * language.c (unk_lang_print_type): Delete.
1335 (unknown_language_data): Delete la_print_type initializer.
1336 (unknown_language::print_type): New member function.
1337 (auto_language_data): Delete la_print_type initializer.
1338 (auto_language::print_type): New member function.
1339 * language.h (language_data): Delete la_print_type field.
1340 (language_defn::print_type): New function.
1341 (LA_PRINT_TYPE): Update.
1342 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
1343 (m2_language::print_type): New member function.
1344 * objc-lang.c (objc_language_data): Delete la_print_type
1345 initializer.
1346 (objc_language::print_type): New member function.
1347 * opencl-lang.c (opencl_print_type): Delete, implementation moved
1348 to opencl_language::print_type.
1349 (opencl_language_data): Delete la_print_type initializer.
1350 (opencl_language::print_type): New member function, implementation
1351 from opencl_print_type.
1352 * p-lang.c (pascal_language_data): Delete la_print_type
1353 initializer.
1354 (pascal_language::print_type): New member function.
1355 * rust-lang.c (rust_print_type): Delete, implementation moved to
1356 rust_language::print_type.
1357 (rust_language_data): Delete la_print_type initializer.
1358 (rust_language::print_type): New member function, implementation
1359 from rust_print_type.
1360
1361 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1362
1363 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
1364 implementation moves to...
1365 (ada_language::sniff_from_mangled_name): ...here. Update return
1366 type.
1367 (ada_language_data): Delete la_sniff_from_mangled_name
1368 initializer.
1369 * c-lang.c (c_language_data): Likewise.
1370 (cplus_language_data): Likewise.
1371 (cplus_language::sniff_from_mangled_name): New member function,
1372 implementation taken from gdb_sniff_from_mangled_name.
1373 (asm_language_data): Delete la_sniff_from_mangled_name
1374 initializer.
1375 (minimal_language_data): Likewise.
1376 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
1377 implementation moves to cplus_language::sniff_from_mangled_name.
1378 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
1379 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
1380 moves to...
1381 (d_language::sniff_from_mangled_name): ...here.
1382 (d_language_data): Delete la_sniff_from_mangled_name initializer.
1383 * f-lang.c (f_language_data): Likewise.
1384 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
1385 moves to...
1386 (go_language::sniff_from_mangled_name): ...here.
1387 (go_language_data): Delete la_sniff_from_mangled_name initializer.
1388 * language.c (language_sniff_from_mangled_name): Delete.
1389 (unknown_language_data): Delete la_sniff_from_mangled_name
1390 initializer.
1391 (auto_language_data): Likewise.
1392 * language.h (language_data): Delete la_sniff_from_mangled_name
1393 field.
1394 (language_defn::sniff_from_mangled_name): New function.
1395 (language_sniff_from_mangled_name): Delete declaration.
1396 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
1397 field.
1398 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
1399 implementation moves to...
1400 (objc_language::sniff_from_mangled_name): ...here.
1401 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
1402 * opencl-lang.c (opencl_language_data): Likewise.
1403 * p-lang.c (pascal_language_data): Likewise.
1404 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
1405 implementation moves to...
1406 (rust_language::sniff_from_mangled_name): ...here.
1407 (rust_language_data): Delete la_sniff_from_mangled_name
1408 initializer.
1409 * symtab.c (symbol_find_demangled_name): Call
1410 sniff_from_mangled_name member function.
1411
1412 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1413
1414 * ada-lang.c (ada_language_data): Delete la_search_name_hash
1415 initializer.
1416 * c-lang.c (c_language_data): Likewise.
1417 (cplus_language_data): Likewise.
1418 (cplus_language::search_name_hash): New member function.
1419 (asm_language_data): Delete la_search_name_hash initializer.
1420 (minimal_language_data): Likewise.
1421 * d-lang.c (d_language_data): Likewise.
1422 * dictionary.c (default_search_name_hash): Rename to...
1423 (language_defn::search_name_hash): ...this.
1424 * f-lang.c (f_language_data): Likewise.
1425 (f_language::search_name_hash): New member function.
1426 * go-lang.c (go_language_data): Delete la_search_name_hash
1427 initializer.
1428 * language.c (unknown_language_data): Likewise.
1429 (auto_language_data): Likewise.
1430 * language.h (struct language_data): Delete la_search_name_hash
1431 field.
1432 (language_defn::search_name_hash): Declare new member function.
1433 (default_search_name_hash): Delete declaration.
1434 * m2-lang.c (m2_language_data): Delete la_search_name_hash
1435 initializer.
1436 * objc-lang.c (objc_language_data): Likewise.
1437 * opencl-lang.c (opencl_language_data): Likewise.
1438 * p-lang.c (pascal_language_data): Likewise.
1439 * rust-lang.c (rust_language_data): Likewise.
1440 * symtab.c (search_name_hash): Update call.
1441
1442 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1443
1444 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
1445 initializer.
1446 * c-lang.c (class compile_instance): Declare.
1447 (c_language_data): Delete la_get_compile_instance initializer.
1448 (c_language::get_compile_instance): New member function.
1449 (cplus_language_data): Delete la_get_compile_instance initializer.
1450 (cplus_language::get_compile_instance): New member function.
1451 (asm_language_data): Delete la_get_compile_instance initializer.
1452 (minimal_language_data): Likewise.
1453 * c-lang.h (c_get_compile_context): Update comment.
1454 (cplus_get_compile_context): Update comment.
1455 * compile/compile.c (compile_to_object): Update calls, don't rely
1456 on function pointer being NULL.
1457 * d-lang.c (d_language_data): Delete la_get_compile_instance
1458 initializer.
1459 * f-lang.c (f_language_data): Likewise.
1460 * go-lang.c (go_language_data): Likewise.
1461 * language.c (unknown_language_data): Likewise.
1462 (auto_language_data): Likewise.
1463 * language.h (language_data): Delete la_get_compile_instance field.
1464 (language_defn::get_compile_instance): New member function.
1465 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
1466 initializer.
1467 * objc-lang.c (objc_language_data): Likewise.
1468 * opencl-lang.c (opencl_language_data): Likewise.
1469 * p-lang.c (pascal_language_data): Likewise.
1470 * rust-lang.c (rust_language_data): Likewise.
1471
1472 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1473
1474 * ada-lang.c (ada_add_all_symbols): Update comment.
1475 (ada_iterate_over_symbols): Delete, move implementation to...
1476 (ada_language::iterate_over_symbols): ...here, a new member
1477 function, rewrite to use range based for loop.
1478 (ada_language_data): Delete la_iterate_over_symbols initializer.
1479 * c-lang.c (c_language_data): Likewise.
1480 (cplus_language_data): Likewise.
1481 (asm_language_data): Likewise.
1482 (minimal_language_data): Likewise.
1483 * d-lang.c (d_language_data): Likewise.
1484 * f-lang.c (f_language_data): Likewise.
1485 * go-lang.c (go_language_data): Likewise.
1486 * language.c (unknown_language_data): Likewise.
1487 (auto_language_data): Likewise.
1488 * language.h (language_data): Delete la_iterate_over_symbols field.
1489 (language_defn::iterate_over_symbols): New member function.
1490 (LA_ITERATE_OVER_SYMBOLS): Update.
1491 * linespec.c (iterate_over_all_matching_symtabs): Update.
1492 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
1493 initializer.
1494 * objc-lang.c (objc_language_data): Likewise.
1495 * opencl-lang.c (opencl_language_data): Likewise.
1496 * p-lang.c (pascal_language_data): Likewise.
1497 * rust-lang.c (rust_language_data): Likewise.
1498
1499 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1500
1501 * ada-lang.c (ada_language_data): Delete
1502 la_lookup_transparent_type initializer.
1503 * c-lang.c (c_language_data): Likewise.
1504 (cplus_language_data): Likewise.
1505 (cplus_language::lookup_transparent_type): New member function.
1506 (asm_language_data): Delete la_lookup_transparent_type
1507 initializer.
1508 (minimal_language_data): Likewise.
1509 * d-lang.c (d_language_data): Likewise.
1510 * f-lang.c (f_language_data): Likewise.
1511 * go-lang.c (go_language_data): Likewise.
1512 * language.c (unknown_language_data): Likewise.
1513 (auto_language_data): Likewise.
1514 * language.h (struct language_data): Delete
1515 la_lookup_transparent_type field.
1516 (language_defn::lookup_transparent_type): New member function.
1517 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
1518 initializer.
1519 * objc-lang.c (objc_language_data): Likewise.
1520 * opencl-lang.c (opencl_language_data): Likewise.
1521 * p-lang.c (pascal_language_data): Likewise.
1522 * rust-lang.c (rust_language_data): Likewise.
1523 * symtab.c (symbol_matches_domain): Update call.
1524
1525 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1526
1527 * ada-lang.c (ada_language_arch_info): Delete function, move
1528 implementation to...
1529 (ada_language::language_arch_info): ...here, a new member
1530 function.
1531 (ada_language_data): Delete la_language_arch_info.
1532 * c-lang.c (c_language_data): Likewise.
1533 (c_language::language_arch_info): New member function.
1534 (cplus_language_arch_info): Delete function, move
1535 implementation to...
1536 (cplus_language::language_arch_info): ...here, a new member
1537 function.
1538 (cplus_language_data): Delete la_language_arch_info.
1539 (asm_language_data): Likewise.
1540 (asm_language::language_arch_info): New member function.
1541 (minimal_language_data): Delete la_language_arch_info.
1542 (minimal_language::language_arch_info): New member function.
1543 * d-lang.c (d_language_arch_info): Delete function, move
1544 implementation to...
1545 (d_language::language_arch_info): ...here, a new member
1546 function.
1547 (d_language_data): Delete la_language_arch_info.
1548 * f-lang.c (f_language_arch_info): Delete function, move
1549 implementation to...
1550 (f_language::language_arch_info): ...here, a new member
1551 function.
1552 (f_language_data): Delete la_language_arch_info.
1553 * go-lang.c (go_language_arch_info): Delete function, move
1554 implementation to...
1555 (go_language::language_arch_info): ...here, a new member
1556 function.
1557 (go_language_data): Delete la_language_arch_info.
1558 * language.c (unknown_language_data): Likewise.
1559 (unknown_language::language_arch_info): New member function.
1560 (auto_language_data): Delete la_language_arch_info.
1561 (auto_language::language_arch_info): New member function.
1562 (language_gdbarch_post_init): Update call to
1563 la_language_arch_info.
1564 * language.h (language_data): Delete la_language_arch_info
1565 function pointer.
1566 (language_defn::language_arch_info): New function.
1567 * m2-lang.c (m2_language_arch_info): Delete function, move
1568 implementation to...
1569 (m2_language::language_arch_info): ...here, a new member
1570 function.
1571 (m2_language_data): Delete la_language_arch_info.
1572 * objc-lang.c (objc_language_arch_info): Delete function, move
1573 implementation to...
1574 (objc_language::language_arch_info): ...here, a new member
1575 function.
1576 (objc_language_data): Delete la_language_arch_info.
1577 * opencl-lang.c (opencl_language_arch_info): Delete function, move
1578 implementation to...
1579 (opencl_language::language_arch_info): ...here, a new member
1580 function.
1581 (opencl_language_data): Delete la_language_arch_info.
1582 * p-lang.c (pascal_language_arch_info): Delete function, move
1583 implementation to...
1584 (pascal_language::language_arch_info): ...here, a new member
1585 function.
1586 (pascal_language_data): Delete la_language_arch_info.
1587 * rust-lang.c (rust_language_arch_info): Delete function, move
1588 implementation to...
1589 (rust_language::language_arch_info): ...here, a new member
1590 function.
1591 (rust_language_data): Delete la_language_arch_info.
1592
1593 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1594
1595 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
1596 initializer.
1597 * c-lang.c (c_language_data): Likewise.
1598 (cplus_language_data): Likewise.
1599 (cplus_language::pass_by_reference_info): New method.
1600 (asm_language_data): Delete la_pass_by_reference initializer.
1601 (minimal_language_data): Likewise.
1602 * cp-abi.c (cp_pass_by_reference): Remove use of
1603 default_pass_by_reference.
1604 * d-lang.c (d_language_data): Likewise.
1605 * f-lang.c (f_language_data): Likewise.
1606 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
1607 default_pass_by_reference.
1608 * go-lang.c (go_language_data): Likewise.
1609 * language.c (language_pass_by_reference): Update.
1610 (default_pass_by_reference): Delete.
1611 (unknown_language_data): Delete la_pass_by_reference
1612 initializer.
1613 (auto_language_data): Likewise.
1614 * language.h (struct language_data): Delete la_pass_by_reference
1615 field.
1616 (language_defn::pass_by_reference_info): New member function.
1617 (default_pass_by_reference): Delete declaration.
1618 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
1619 initializer.
1620 * objc-lang.c (objc_language_data): Likewise.
1621 * opencl-lang.c (opencl_language_data): Likewise.
1622 * p-lang.c (pascal_language_data): Likewise.
1623 * rust-lang.c (rust_language_data): Likewise.
1624
1625 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1626
1627 * ada-lang.c (ada_read_var_value): Delete function, move
1628 implementation to...
1629 (ada_language::read_var_value): ...here.
1630 (ada_language_data): Delete la_read_var_value initializer.
1631 * c-lang.c (c_language_data): Likewise.
1632 (cplus_language_data): Likewise.
1633 (minimal_language_data): Likewise.
1634 * d-lang.c (d_language_data): Likewise.
1635 * f-lang.c (f_language_data): Likewise.
1636 * findvar.c (default_read_var_value): Rename to...
1637 (language_defn::read_var_value): ...this.
1638 * findvar.c (read_var_value): Update header comment, and change to
1639 call member function instead of function pointer.
1640 * go-lang.c (go_language_data): Likewise.
1641 * language.c (unknown_language_data): Delete la_read_var_value
1642 initializer.
1643 (auto_language_data): Likewise.
1644 * language.h (struct language_data): Delete la_read_var_value
1645 field.
1646 (language_defn::read_var_value): New member function.
1647 (default_read_var_value): Delete declaration.
1648 * m2-lang.c (m2_language_data): Delete la_read_var_value
1649 initializer.
1650 * objc-lang.c (objc_language_data): Likewise.
1651 * opencl-lang.c (opencl_language_data): Likewise.
1652 * p-lang.c (pascal_language_data): Likewise.
1653 * rust-lang.c (rust_language_data): Likewise.
1654 * value.h (default_read_var_value): Delete declaration.
1655
1656 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1657
1658 * ada-lang.c (ada_print_array_index): Delete function, move
1659 implementation to...
1660 (ada_language::print_array_index): ...here.
1661 (ada_language_data): Delete la_print_array_index initializer.
1662 * c-lang.c (c_language_data): Likewise.
1663 (cplus_language_data): Likewise.
1664 (minimal_language_data): Likewise.
1665 * d-lang.c (d_language_data): Likewise.
1666 * f-lang.c (f_language_data): Likewise.
1667 * go-lang.c (go_language_data): Likewise.
1668 * language.c (default_print_array_index): Delete function, move
1669 implementation to...
1670 (language_defn::print_array_index): ...here.
1671 (unknown_language_data): Delete la_print_array_index initializer.
1672 (auto_language_data): Likewise.
1673 * language.h (struct language_data): Delete la_print_array_index
1674 field.
1675 (language_defn::print_array_index): New member function.
1676 (LA_PRINT_ARRAY_INDEX): Update.
1677 (default_print_array_index): Delete declaration.
1678 * m2-lang.c (m2_language_data): Delete la_print_array_index
1679 initializer.
1680 * objc-lang.c (objc_language_data): Likewise.
1681 * opencl-lang.c (opencl_language_data): Likewise.
1682 * p-lang.c (pascal_language_data): Likewise.
1683 * rust-lang.c (rust_language_data): Likewise.
1684
1685 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
1686
1687 * gdb/ada-lang.c (ada_language_defn): Convert to...
1688 (ada_language_data): ...this.
1689 (class ada_language): New class.
1690 (ada_language_defn): New static global.
1691 * gdb/c-lang.c (c_language_defn): Convert to...
1692 (c_language_data): ...this.
1693 (class c_language): New class.
1694 (c_language_defn): New static global.
1695 (cplus_language_defn): Convert to...
1696 (cplus_language_data): ...this.
1697 (class cplus_language): New class.
1698 (cplus_language_defn): New static global.
1699 (asm_language_defn): Convert to...
1700 (asm_language_data): ...this.
1701 (class asm_language): New class.
1702 (asm_language_defn): New static global.
1703 (minimal_language_defn): Convert to...
1704 (minimal_language_data): ...this.
1705 (class minimal_language): New class.
1706 (minimal_language_defn): New static global.
1707 * gdb/d-lang.c (d_language_defn): Convert to...
1708 (d_language_data): ...this.
1709 (class d_language): New class.
1710 (d_language_defn): New static global.
1711 * gdb/f-lang.c (f_language_defn): Convert to...
1712 (f_language_data): ...this.
1713 (class f_language): New class.
1714 (f_language_defn): New static global.
1715 * gdb/go-lang.c (go_language_defn): Convert to...
1716 (go_language_data): ...this.
1717 (class go_language): New class.
1718 (go_language_defn): New static global.
1719 * gdb/language.c (unknown_language_defn): Remove declaration.
1720 (current_language): Initialize to nullptr, real initialization is
1721 moved to _initialize_language.
1722 (languages): Delete global.
1723 (language_defn::languages): Define.
1724 (set_language_command): Use language_defn::languages.
1725 (set_language): Likewise.
1726 (range_error): Likewise.
1727 (language_enum): Likewise.
1728 (language_def): Likewise.
1729 (add_set_language_command): Use language_def::languages for the
1730 language list, and language_def to lookup language pointers.
1731 (skip_language_trampoline): Use language_defn::languages.
1732 (unknown_language_defn): Convert to...
1733 (unknown_language_data): ...this.
1734 (class unknown_language): New class.
1735 (unknown_language_defn): New static global.
1736 (auto_language_defn): Convert to...
1737 (auto_language_data): ...this.
1738 (class auto_language): New class.
1739 (auto_language_defn): New static global.
1740 (language_gdbarch_post_init): Use language_defn::languages.
1741 (_initialize_language): Initialize current_language.
1742 * gdb/language.h (struct language_defn): Rename to...
1743 (struct language_data): ...this.
1744 (struct language_defn): New.
1745 (auto_language_defn): Delete.
1746 (unknown_language_defn): Delete.
1747 (minimal_language_defn): Delete.
1748 (ada_language_defn): Delete.
1749 (asm_language_defn): Delete.
1750 (c_language_defn): Delete.
1751 (cplus_language_defn): Delete.
1752 (d_language_defn): Delete.
1753 (f_language_defn): Delete.
1754 (go_language_defn): Delete.
1755 (m2_language_defn): Delete.
1756 (objc_language_defn): Delete.
1757 (opencl_language_defn): Delete.
1758 (pascal_language_defn): Delete.
1759 (rust_language_defn): Delete.
1760 * gdb/m2-lang.c (m2_language_defn): Convert to...
1761 (m2_language_data): ...this.
1762 (class m2_language): New class.
1763 (m2_language_defn): New static global.
1764 * gdb/objc-lang.c (objc_language_defn): Convert to...
1765 (objc_language_data): ...this.
1766 (class objc_language): New class.
1767 (objc_language_defn): New static global.
1768 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
1769 (opencl_language_data): ...this.
1770 (class opencl_language): New class.
1771 (opencl_language_defn): New static global.
1772 * gdb/p-lang.c (pascal_language_defn): Convert to...
1773 (pascal_language_data): ...this.
1774 (class pascal_language): New class.
1775 (pascal_language_defn): New static global.
1776 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
1777 language pointer, update comment format.
1778 * gdb/rust-lang.c (rust_language_defn): Convert to...
1779 (rust_language_data): ...this.
1780 (class rust_language): New class.
1781 (rust_language_defn): New static global.
1782
1783 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
1784
1785 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
1786 member variable.
1787 <m_stmt_at_address>: New member variable.
1788 (lnp_state_machine::record_line): Don't record some lines, update
1789 tracking of is_stmt at the same address.
1790 (lnp_state_machine::lnp_state_machine): Initialise new member
1791 variables.
1792
1793 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
1794
1795 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
1796 "-include gnu-nat-mig.h".
1797 * gnu-nat-mig.h: New file.
1798 * gnu-nat.c: Include "gnu-nat-mig.h".
1799 (exc_server, msg_reply_server, notify_server,
1800 process_reply_server): Remove declarations.
1801
1802 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1803
1804 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
1805 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
1806 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
1807 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
1808 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
1809 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
1810 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
1811 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
1812 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
1813 to gnu_nat_target class.
1814 * gnu-nat.c: Likewise.
1815 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
1816 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
1817 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
1818 object.
1819 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
1820 instead of `gnu_target'.
1821
1822 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1823
1824 * i386-gnu-tdep.c: Include "gdbcore.h"
1825 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
1826 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
1827 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
1828 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
1829 i386_gnu_sigcontext_addr): New functions
1830 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
1831 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
1832 tdep.
1833
1834 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1835
1836 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
1837 before fork_inferior call. Avoid calling it if target_is_pushed returns
1838 true.
1839
1840 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1841
1842 * gnu-nat.h (gnu_target): New variable declaration.
1843 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
1844 gnu_target.
1845 * gnu-nat.c (gnu_target): New variable.
1846 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
1847 add_thread_silent, and add_thread calls.
1848 (gnu_nat_target::create_inferior): Pass gnu_target to
1849 add_thread_silent, thread_change_ptid call.
1850 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
1851 call.
1852
1853 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1854
1855 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
1856 (gnu_nat_target::find_memory_regions): Remove unused
1857 `old_address' variable.
1858
1859 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1860
1861 * gnu-nat.c: Include "gdbarch.h".
1862
1863 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1864
1865 * reply_mig_hack.awk (Error return): Cast function through
1866 void *, to bypass compiler function call check.
1867
1868 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1869
1870 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
1871 $(srcdir)/reply_mig_hack.awk.
1872
1873 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
1874
1875 * gnu-nat.h (gnu_debug_flag): Set type to bool.
1876
1877 2020-05-30 Jonny Grant <jg@jguk.org>
1878
1879 * configure.ac (ACX_BUGURL): change bug URL to https.
1880
1881 2020-05-30 Pedro Alves <palves@redhat.com>
1882
1883 * cp-support.c (replace_typedefs_template): New.
1884 (replace_typedefs_qualified_name): Handle
1885 DEMANGLE_COMPONENT_TEMPLATE.
1886
1887 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
1888
1889 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
1890 dwarf2/index-cache.h, dwarf2/index-write.c,
1891 dwarf2/index-write.h, dwarf2/line-header.c,
1892 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
1893 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
1894 variables and fields from `dwarf2_per_objfile` to just
1895 `per_objfile` throughout.
1896
1897 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
1898
1899 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
1900 <push_dwarf_reg_entry_value>: Add comment.
1901
1902 2020-05-28 Kevin Buettner <kevinb@redhat.com>
1903 Keith Seitz <keiths@redhat.com>
1904
1905 * python/python.c (do_start_initialization): Call PyEval_SaveThread
1906 instead of PyEval_ReleaseLock.
1907 (class gdbpy_gil): Move to earlier in file.
1908 (finalize_python): Set gdb_python_initialized.
1909 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
1910 when not initialized.
1911
1912 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
1913
1914 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
1915 <push_dwarf_reg_entry_value>: Remove assert. Override
1916 per_objfile with caller_per_objfile.
1917
1918 2020-05-28 Tom de Vries <tdevries@suse.de>
1919
1920 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
1921 PR gold/15646 workaround to symbol kind "type".
1922
1923 2020-05-27 Tom Tromey <tromey@adacore.com>
1924
1925 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
1926
1927 2020-05-27 Tom Tromey <tromey@adacore.com>
1928
1929 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
1930 Use htab_find_with_hash.
1931 <add_abbrev>: Remove "abbrev_number" parameter.
1932 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
1933 "abbrev_number" parameter. Use htab_find_slot_with_hash.
1934 (hash_abbrev): Add comment.
1935 (abbrev_table::lookup_abbrev): Move to header file.
1936 (abbrev_table::read): Update.
1937
1938 2020-05-27 Tom Tromey <tromey@adacore.com>
1939
1940 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
1941 method.
1942 <canonical_name>: New member.
1943 <raw_name>: Rename from "name".
1944 (partial_die_info): Initialize canonical_name.
1945 (scan_partial_symbols): Check raw_name.
1946 (partial_die_parent_scope, partial_die_full_name)
1947 (add_partial_symbol, add_partial_subprogram)
1948 (add_partial_enumeration, load_partial_dies): Use "name" method.
1949 (partial_die_info::name): New method.
1950 (partial_die_info::read, guess_partial_die_structure_name)
1951 (partial_die_info::fixup): Update.
1952
1953 2020-05-27 Tom Tromey <tromey@adacore.com>
1954
1955 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
1956 <get_ref_die_offset>: Inline.
1957 <get_ref_die_offset_complaint>: New method.
1958 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
1959 (attribute::get_ref_die_offset_complaint): Rename from
1960 get_ref_die_offset. Just issue complaint.
1961
1962 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
1963
1964 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
1965
1966 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
1967
1968 * exec.c (exec_file_attach): Use errno value of first openp failure.
1969
1970 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
1971
1972 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
1973 Don't close thread handle.
1974
1975 2020-05-27 Tom Tromey <tom@tromey.com>
1976 Simon Marchi <simon.marchi@efficios.com>
1977
1978 * objfiles.h (struct objfile) <partial_symtabs>: Now a
1979 shared_ptr.
1980 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
1981 member.
1982 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
1983 dwarf2_per_bfd_objfile_data_key>: New globals.
1984 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
1985 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
1986 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
1987 shared.
1988 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
1989 short-circuit when sharing.
1990 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
1991 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
1992
1993 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
1994
1995 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
1996 to...
1997 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
1998 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
1999
2000 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2001
2002 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
2003 build_name_components, find_name_components_bounds>:
2004 Add per_objfile parameter.
2005 (struct mapped_index) <symbol_name_at>: Likewise.
2006 (struct mapped_debug_names): Remove constructor.
2007 <dwarf2_per_objfile>: Remove field.
2008 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
2009 (mapped_index_base::find_name_components_bounds,
2010 mapped_index_base::build_name_components,
2011 dw2_expand_symtabs_matching_symbol): Likewise.
2012 (class mock_mapped_index) <symbol_name_at>: Likewise.
2013 (check_match): Likewise.
2014 (check_find_bounds_finds): Likewise.
2015 (test_mapped_index_find_name_component_bounds): Update.
2016 (CHECK_MATCH): Update.
2017 (dw2_expand_symtabs_matching): Update.
2018 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
2019 per_objfile parameter.
2020 <find_vec_in_debug_names>: Likewise.
2021 <m_per_objfile>: New field.
2022 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
2023 parameter.
2024 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
2025 (dw2_debug_names_iterator::next): Update.
2026 (dw2_debug_names_lookup_symbol): Update.
2027 (dw2_debug_names_expand_symtabs_for_function): Update.
2028 (dw2_debug_names_map_matching_symbols): Update.
2029 (dw2_debug_names_expand_symtabs_matching): Update.
2030 (dwarf2_read_debug_names): Update.
2031
2032 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2033
2034 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
2035 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
2036 move to dwarf2_per_objfile.
2037 <read_in_chain>: Remove.
2038 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
2039 remove_all_cus, age_comp_units>: New methods.
2040 <m_dwarf2_cus>: New member.
2041 (struct dwarf2_per_cu_data) <cu>: Remove.
2042 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
2043 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
2044 moved to methods of dwarf2_per_objfile.
2045 (dwarf2_clear_marks): Remove.
2046 (dwarf2_queue_item::~dwarf2_queue_item): Update.
2047 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
2048 (dwarf2_per_bfd::free_cached_comp_units): Remove.
2049 (dwarf2_per_objfile::remove_all_cus): New.
2050 (class free_cached_comp_units) <~free_cached_comp_units>:
2051 Update.
2052 (load_cu): Update.
2053 (dw2_do_instantiate_symtab): Adjust.
2054 (fill_in_sig_entry_from_dwo_entry): Adjust.
2055 (cutu_reader::init_tu_and_read_dwo_dies): Update.
2056 (cutu_reader::cutu_reader): Likewise.
2057 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
2058 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
2059 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
2060 and dwarf2_per_objfile::age_comp_units.
2061 (load_partial_comp_unit): Update.
2062 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
2063 (process_queue): Likewise.
2064 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
2065 backlink.
2066 (dwarf2_read_addr_index): Likewise.
2067 (follow_die_offset): Likewise.
2068 (dwarf2_fetch_die_loc_sect_off): Likewise.
2069 (dwarf2_fetch_constant_bytes): Likewise.
2070 (dwarf2_fetch_die_type_sect_off): Likewise.
2071 (follow_die_sig_1): Likewise.
2072 (load_full_type_unit): Likewise.
2073 (read_signatured_type): Likewise.
2074 (dwarf2_cu::dwarf2_cu): Don't set cu field.
2075 (dwarf2_cu::~dwarf2_cu): Remove.
2076 (dwarf2_per_objfile::get_cu): New.
2077 (dwarf2_per_objfile::set_cu): New.
2078 (age_cached_comp_units): Rename to...
2079 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
2080 to std::unordered_map.
2081 (free_one_cached_comp_unit): Rename to...
2082 (dwarf2_per_objfile::remove_cu): ... this. Adjust
2083 to std::unordered_map.
2084 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
2085 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
2086 a dwarf2_per_objfile in data.
2087 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
2088 (dwarf2_clear_marks): Remove.
2089
2090 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2091
2092 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
2093 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
2094 (init_tu_and_read_dwo_dies): Likewise.
2095 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
2096 (cutu_reader::cutu_reader): Likewise.
2097 (load_partial_comp_unit): Likewise.
2098 (process_psymtab_comp_unit): Update.
2099 (build_type_psymtabs_1): Update.
2100 (process_skeletonless_type_unit): Update.
2101 (load_full_comp_unit): Update.
2102 (find_partial_die): Update.
2103 (dwarf2_read_addr_index): Update.
2104 (read_signatured_type): Update.
2105
2106 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2107
2108 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
2109 m_header_read_in>: New fields.
2110 <get_header>: New method.
2111 * dwarf2/read.c (per_cu_header_read_in): Remove.
2112 (dwarf2_per_cu_data::get_header): New.
2113 (dwarf2_per_cu_data::addr_size): Update.
2114 (dwarf2_per_cu_data::offset_size): Update.
2115 (dwarf2_per_cu_data::ref_addr_size): Update.
2116
2117 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2118
2119 * dwarf2/read.c (load_cu): Return dwarf2_cu.
2120 (dw2_do_instantiate_symtab): Update.
2121 (queue_and_load_all_dwo_tus): Change parameter from
2122 dwarf2_per_cu_data to dwarf2_cu.
2123 (dwarf2_fetch_die_loc_sect_off): Update.
2124 (dwarf2_fetch_constant_bytes): Update.
2125 (dwarf2_fetch_die_type_sect_off): Update.
2126
2127 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2128
2129 * dwarf2/read.c (process_full_comp_unit,
2130 process_full_type_unit): Remove per_cu, per_objfile paramters.
2131 Add dwarf2_cu parameter.
2132 (process_queue): Update.
2133
2134 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2135
2136 * dwarf2/read.c (create_cu_from_index_list): Replace
2137 dwarf2_per_objfile parameter with dwarf2_per_bfd.
2138 (create_cus_from_index_list): Likewise.
2139 (create_cus_from_index): Likewise.
2140 (create_signatured_type_table_from_index): Likewise.
2141 (create_cus_from_debug_names_list): Likewise.
2142 (create_cus_from_debug_names): Likewise.
2143 (dwarf2_read_gdb_index): Update.
2144 (dwarf2_read_debug_names): Update.
2145
2146 2020-05-27 Tom Tromey <tom@tromey.com>
2147 Simon Marchi <simon.marchi@efficios.com>
2148
2149 * dwarf2/read.h (struct dwarf2_per_objfile)
2150 <get_type_for_signatured_type, set_type_for_signatured_type>:
2151 New methods.
2152 <m_type_map>: New member.
2153 (struct signatured_type) <type>: Remove.
2154 * dwarf2/read.c
2155 (dwarf2_per_objfile::get_type_for_signatured_type,
2156 dwarf2_per_objfile::set_type_for_signatured_type): New.
2157 (get_signatured_type): Use new methods.
2158
2159 2020-05-27 Tom Tromey <tom@tromey.com>
2160 Simon Marchi <simon.marchi@efficios.com>
2161
2162 * dwarf2/read.h (struct type_unit_group_unshareable): New.
2163 (struct dwarf2_per_objfile) <type_units>: New member.
2164 <get_type_unit_group_unshareable>: New method.
2165 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
2166 num_symtabs, symtabs>: Remove; move to
2167 type_unit_group_unshareable.
2168 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
2169 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
2170 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
2171
2172 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2173
2174 * dwarf2/read.h (struct dwarf2_per_cu_data):
2175 <dwarf2_per_objfile>: Remove.
2176 * dwarf2/read.c (create_cu_from_index_list): Don't assign
2177 dwarf2_per_objfile.
2178 (create_signatured_type_table_from_index): Likewise.
2179 (create_signatured_type_table_from_debug_names): Likewise.
2180 (create_debug_type_hash_table): Likewise.
2181 (fill_in_sig_entry_from_dwo_entry): Likewise.
2182 (create_type_unit_group): Likewise.
2183 (read_comp_units_from_section): Likewise.
2184 (create_cus_hash_table): Likewise.
2185
2186 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2187
2188 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
2189 dwarf2_per_cu_data::dwarf2_per_objfile.
2190 (compute_compunit_symtab_includes): Likewise.
2191 (dwarf2_cu::start_symtab): Likewise.
2192
2193 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2194
2195 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
2196 parameter.
2197 * dwarf2/read.c (get_die_type_at_offset): Likewise.
2198 (read_namespace_alias): Update.
2199 (lookup_die_type): Update.
2200 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
2201 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
2202 Update.
2203 (disassemble_dwarf_expression): Update.
2204
2205 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2206
2207 * dwarf2/read.h (struct dwarf2_queue_item): Add
2208 dwarf2_per_objfile parameter, assign new parameter.
2209 <per_objfile>: New field.
2210 * dwarf2/read.c (free_one_cached_comp_unit): Add
2211 dwarf2_per_objfile parameter.
2212 (queue_comp_unit): Likewise.
2213 (dw2_do_instantiate_symtab): Update.
2214 (process_psymtab_comp_unit): Update.
2215 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
2216 (process_imported_unit_die): Update.
2217 (queue_and_load_dwo_tu): Update.
2218 (follow_die_offset): Update.
2219 (follow_die_sig_1): Update.
2220
2221 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2222
2223 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
2224 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
2225 (read_call_site_scope): Assign per_objfile.
2226 (dwarf2_per_cu_data::objfile): Remove.
2227 * gdbtypes.h (struct call_site) <per_objfile>: New member.
2228 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
2229 dwarf2_per_objfile parameter.
2230 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
2231 dwarf2_per_objfile parameter.
2232 (dwarf_expr_reg_to_entry_parameter): Add output
2233 dwarf2_per_objfile parameter.
2234 (locexpr_get_frame_base): Update.
2235 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
2236 <push_dwarf_reg_entry_value>: Update.
2237 <call_site_to_target_addr>: Update.
2238 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
2239 parameter.
2240 (value_of_dwarf_reg_entry): Update.
2241 (rw_pieced_value): Update.
2242 (indirect_synthetic_pointer): Update.
2243 (dwarf2_evaluate_property): Update.
2244 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
2245 parameter.
2246 (locexpr_read_variable): Update.
2247 (locexpr_get_symbol_read_needs): Update.
2248 (loclist_read_variable): Update.
2249
2250 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2251
2252 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
2253 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2254 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
2255 parameter.
2256 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
2257 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
2258 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
2259 parameter.
2260 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
2261 sect_variable_value): Add dwarf2_per_objfile parameter.
2262 (class dwarf_evaluate_loc_desc) <dwarf_call,
2263 dwarf_variable_value>: Update.
2264 (fetch_const_value_from_synthetic_pointer): Add
2265 dwarf2_per_objfile parameter.
2266 (fetch_const_value_from_synthetic_pointer): Update.
2267 (coerced_pieced_ref): Update.
2268 (class symbol_needs_eval_context) <dwarf_call,
2269 dwarf_variable_value>: Update.
2270 (dwarf2_compile_expr_to_ax): Update.
2271
2272 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2273
2274 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
2275 parameter.
2276 (dwarf2_evaluate_loc_desc_full): Update.
2277
2278 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2279
2280 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
2281 parameter.
2282 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
2283 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
2284 dwarf2_per_objfile parameter.
2285 (decode_debug_loc_dwo_addresses): Likewise.
2286 (dwarf2_find_location_expression): Update.
2287 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
2288 (locexpr_describe_location_piece): Add dwarf2_per_objfile
2289 parameter.
2290 (disassemble_dwarf_expression): Add dwarf2_per_objfile
2291 parameter.
2292 (locexpr_describe_location_1): Likewise.
2293 (locexpr_describe_location): Update.
2294
2295 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2296
2297 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
2298 Remove.
2299 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
2300 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
2301 (dwarf2_compile_property_to_c): Update.
2302 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
2303 use text offset from objfile.
2304 (locexpr_tracepoint_var_ref): Update.
2305 (locexpr_generate_c_location): Update.
2306 (loclist_describe_location): Update.
2307 (loclist_tracepoint_var_ref): Update.
2308 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
2309 dwarf2_per_objfile parameter.
2310 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
2311 use text offset from objfile.
2312 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
2313
2314 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2315
2316 * dwarf2/expr.h (struct dwarf_expr_context)
2317 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
2318 <offset>: Remove.
2319 <per_objfile>: New member.
2320 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
2321 dwarf2_per_objfile parameter. Don't set offset, set
2322 per_objfile.
2323 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
2324 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
2325 a dwarf2_per_objfile object instead of an offset.
2326 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
2327 constructor.
2328 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
2329 to dwarf2_expr_executor constructor. Don't set offset.
2330 (dwarf2_fetch_cfa_info): Update.
2331 (struct dwarf2_frame_cache) <text_offset>: Remove.
2332 <per_objfile>: New field.
2333 (dwarf2_frame_cache): Update.
2334 (dwarf2_frame_prev_register): Update.
2335 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2336 <dwarf_evaluate_loc_desc>: Add constructor.
2337 (dwarf2_evaluate_loc_desc_full): Update.
2338 (dwarf2_locexpr_baton_eval): Update.
2339 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
2340 Add constructor.
2341 (dwarf2_loc_desc_get_symbol_read_needs): Update.
2342
2343 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2344
2345 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
2346 addr_sized_int_type>: Move to dwarf2_cu.
2347 <int_type>: Move to dwarf2_per_objfile.
2348 (struct dwarf2_per_objfile) <int_type>: Move here.
2349 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
2350 addr_sized_int_type>: Move here.
2351 (read_func_scope): Update.
2352 (read_array_type): Update.
2353 (read_tag_string_type): Update.
2354 (attr_to_dynamic_prop): Update.
2355 (dwarf2_per_cu_data::int_type): Rename to...
2356 (dwarf2_per_objfile::int_type): ... this.
2357 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
2358 (dwarf2_cu::addr_sized_int_type): ... this.
2359 (read_subrange_type): Update.
2360 (dwarf2_per_cu_data::addr_type): Rename to...
2361 (dwarf2_cu::addr_type): ... this.
2362 (set_die_type): Update.
2363
2364 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2365
2366 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
2367 data through per_cu->cu.
2368
2369 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2370
2371 * dwarf2/read.c (lookup_dwo_comp_unit): Change
2372 dwarf2_per_cu_data parameter fo dwarf2_cu.
2373 (lookup_dwo_type_unit): Likewise.
2374 (read_cutu_die_from_dwo): Likewise.
2375 (lookup_dwo_unit): Likewise.
2376 (open_and_init_dwo_file): Likewise.
2377 (lookup_dwo_cutu): Likewise.
2378 (lookup_dwo_comp_unit): Likewise.
2379 (lookup_dwo_type_unit): Likewise.
2380 (cutu_reader::init_tu_and_read_dwo_dies): Update.
2381 (cutu_reader::cutu_reader): Update.
2382
2383 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2384
2385 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
2386 parameter.
2387 (process_full_type_unit): Likewise.
2388 (process_queue): Update.
2389
2390 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2391
2392 * dwarf2/read.c (recursively_compute_inclusions): Add
2393 dwarf2_per_objfile parameter.
2394 (compute_compunit_symtab_includes): Likewise.
2395 (process_cu_includes): Update.
2396
2397 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2398
2399 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
2400 parameter.
2401 (create_type_unit_group): Update.
2402 (process_psymtab_comp_unit_reader): Update.
2403 (build_type_psymtabs_reader): Update.
2404
2405 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2406
2407 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
2408 object through m_this_cu->cu.
2409
2410 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2411
2412 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
2413 the info parameter.
2414 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
2415
2416 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2417
2418 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
2419 per_objfile parameter.
2420 (load_full_type_unit): Add per_objfile parameter.
2421 (read_signatured_type): Likewise.
2422 (load_full_comp_unit): Likewise.
2423 (load_cu): Likewise.
2424 (dw2_do_instantiate_symtab): Likewise.
2425 (dw2_get_file_names): Likewise.
2426 (dw2_map_symtabs_matching_filename): Update.
2427 (dw_expand_symtabs_matching_file_matcher): Update.
2428 (dw2_map_symbol_filenames): Update.
2429 (process_psymtab_comp_unit): Add per_objfile parameter.
2430 (build_type_psymtabs_1): Update.
2431 (process_skeletonless_type_unit): Update.
2432 (dwarf2_build_psymtabs_hard): Update.
2433 (load_partial_comp_unit): Add per_objfile parameter.
2434 (scan_partial_symbols): Update.
2435 (load_full_comp_unit): Add per_objfile parameter.
2436 (process_imported_unit_die): Update.
2437 (create_cus_hash_table): Update.
2438 (find_partial_die): Update.
2439 (dwarf2_read_addr_index): Update.
2440 (follow_die_offset): Update.
2441 (dwarf2_fetch_die_loc_sect_off): Update.
2442 (dwarf2_fetch_constant_bytes): Update.
2443 (dwarf2_fetch_die_type_sect_off): Update.
2444 (follow_die_sig_1): Update.
2445 (load_full_type_unit): Add per_objfile parameter.
2446 (read_signatured_type): Likewise.
2447
2448 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2449
2450 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
2451 of objfile_name.
2452
2453 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2454
2455 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
2456 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
2457 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
2458 field.
2459 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
2460 (create_cus_from_index): Update.
2461 (dwarf2_read_gdb_index): Update.
2462 (create_cus_from_debug_names): Update.
2463 (dwarf2_read_debug_names): Update.
2464 (get_abbrev_section_for_cu): Update.
2465 (create_all_comp_units): Update.
2466 (read_attribute_value): Update.
2467 (get_debug_line_section): Update.
2468 * dwarf2/index-cache.c (index_cache::store): Update.
2469 * dwarf2/index-write.c (save_gdb_index_command): Update.
2470 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
2471
2472 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2473
2474 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
2475 member.
2476 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
2477 dwarf2_per_cu_data::per_bfd.
2478 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
2479 (create_type_unit_group): Likewise.
2480 (queue_comp_unit): Remove reference to
2481 per_cu->dwarf2_per_objfile.
2482 (maybe_queue_comp_unit): Likewise.
2483 (fill_in_sig_entry_from_dwo_entry): Assign new field.
2484 (create_cus_hash_table): Assign new field.
2485
2486 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2487
2488 * dwarf2/read.c: Replace
2489 dwarf2_cu->per_cu->dwarf2_per_objfile references with
2490 dwarf2_cu->per_objfile throughout.
2491
2492 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2493
2494 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
2495 parameter, don't use per_cu->dwarf2_per_objfile.
2496 (dw2_instantiate_symtab): Likewise.
2497 (dw2_find_last_source_symtab): Update.
2498 (dw2_map_expand_apply): Update.
2499 (dw2_lookup_symbol): Update.
2500 (dw2_expand_symtabs_for_function): Update.
2501 (dw2_expand_all_symtabs): Update.
2502 (dw2_expand_symtabs_with_fullname): Update.
2503 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
2504 don't use per_cu->dwarf2_per_objfile.
2505 (dw2_expand_marked_cus): Update.
2506 (dw2_find_pc_sect_compunit_symtab): Update.
2507 (dw2_debug_names_lookup_symbol): Update.
2508 (dw2_debug_names_expand_symtabs_for_function): Update.
2509 (dw2_debug_names_map_matching_symbols): Update.
2510 (dwarf2_psymtab::expand_psymtab): Update.
2511
2512 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2513
2514 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
2515 <per_objfile>: New member.
2516 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
2517 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
2518 call to dwarf2_cu.
2519 (cutu_reader::cutu_reader): Update.
2520 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
2521
2522 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2523
2524 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
2525 struct dwarf2_per_objfile.
2526 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
2527 dwarf2_per_bfd.
2528 * dwarf2/read.c (set_die_type): Update.
2529 (get_die_type_at_offset): Update.
2530
2531 2020-05-27 Tom Tromey <tom@tromey.com>
2532 Simon Marchi <simon.marchi@efficios.com>
2533
2534 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
2535 method.
2536 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
2537 get_symtab, set_symtab>: New methods.
2538 <m_symtabs>: New field.
2539 (struct dwarf2_psymtab): Derive from partial_symtab.
2540 <readin_p, get_compunit_symtab>: Declare methods.
2541 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
2542 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
2543 New methods.
2544 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
2545 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
2546 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
2547 (dw2_symtab_iter_next, dw2_print_stats)
2548 (dw2_expand_symtabs_with_fullname)
2549 (dw2_expand_symtabs_matching_one)
2550 (dw_expand_symtabs_matching_file_matcher)
2551 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
2552 (dw2_debug_names_iterator::next)
2553 (dw2_debug_names_map_matching_symbols)
2554 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
2555 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
2556 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
2557 New methods.
2558 (get_compunit_symtab, process_full_comp_unit)
2559 (process_full_type_unit): Update.
2560 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
2561
2562 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
2563
2564 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
2565 then introduce a new dwarf2_per_objfile type.
2566 <read_line_string>: Move to the new dwarf2_per_objfile type.
2567 <objfile>: Likewise.
2568 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
2569 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
2570 dwarf2_per_objfile->per_bfd.
2571 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
2572 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
2573 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
2574 (dwarf2_per_bfd::free_cached_comp_units): ... this.
2575 (dwarf2_has_info): Allocate dwarf2_per_bfd.
2576 (dwarf2_per_objfile::locate_sections): Rename to...
2577 (dwarf2_per_bfd::locate_sections): ... this.
2578 (dwarf2_per_objfile::get_cutu): Rename to...
2579 (dwarf2_per_bfd::get_cutu): ... this.
2580 (dwarf2_per_objfile::get_cu): Rename to...
2581 (dwarf2_per_bfd::get_cu): ... this.
2582 (dwarf2_per_objfile::get_tu): Rename to...
2583 (dwarf2_per_bfd::get_tu): ... this.
2584 (dwarf2_per_objfile::allocate_per_cu): Rename to...
2585 (dwarf2_per_bfd::allocate_per_cu): ... this.
2586 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
2587 (dwarf2_per_bfd::allocate_signatured_type): ... this.
2588 (get_gdb_index_contents_ftype): Change parameter from
2589 dwarf2_per_objfile to dwarf2_per_bfd.
2590 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
2591 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
2592
2593 2020-05-27 Tom Tromey <tom@tromey.com>
2594 Simon Marchi <simon.marchi@efficios.com>
2595
2596 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
2597 (allocate_piece_closure): Set "per_objfile" member.
2598 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
2599 (locexpr_describe_location, loclist_describe_location): Use new
2600 member.
2601 * dwarf2/read.c (read_call_site_scope)
2602 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
2603 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
2604 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
2605 handle_data_member_location): Set per_objfile member.
2606 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
2607 member.
2608 (struct dwarf2_loclist_baton) <per_objfile>: New member.
2609
2610 2020-05-27 Tom Tromey <tom@tromey.com>
2611
2612 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
2613 allocate_signatured_type>: Declare new methods.
2614 <m_num_psymtabs>: New member.
2615 (struct dwarf2_per_cu_data) <index>: New member.
2616 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
2617 (dwarf2_per_objfile::allocate_signatured_type): New methods.
2618 (create_cu_from_index_list): Use allocate_per_cu.
2619 (create_signatured_type_table_from_index)
2620 (create_signatured_type_table_from_debug_names)
2621 (create_debug_type_hash_table, add_type_unit)
2622 (read_comp_units_from_section): Use allocate_signatured_type.
2623
2624 2020-05-27 Tom Tromey <tom@tromey.com>
2625
2626 * psymtab.c (partial_map_expand_apply)
2627 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
2628 (psym_lookup_global_symbol_language)
2629 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
2630 (psym_print_stats, psym_expand_symtabs_for_function)
2631 (psym_map_symbol_filenames, psym_map_matching_symbols)
2632 (psym_expand_symtabs_matching)
2633 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
2634 (maintenance_check_psymtabs): Update.
2635 * psympriv.h (struct partial_symtab) <readin_p,
2636 get_compunit_symtab>: Add objfile parameter.
2637 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
2638 Likewise.
2639 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
2640 get_compunit_symtab>: Likewise.
2641 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
2642
2643 2020-05-27 Tom Tromey <tom@tromey.com>
2644
2645 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
2646 member.
2647 * dwarf2/read.c (delete_file_name_entry): Fix comment.
2648 (create_cu_from_index_list)
2649 (create_signatured_type_table_from_index)
2650 (create_signatured_type_table_from_debug_names)
2651 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
2652 (dwarf2_create_include_psymtab)
2653 (create_debug_type_hash_table, add_type_unit)
2654 (create_type_unit_group, read_comp_units_from_section)
2655 (dwarf2_compute_name, create_cus_hash_table)
2656 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
2657 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
2658 obstack.
2659 (dw2_get_real_path): Likewise. Change argument to
2660 dwarf2_per_objfile.
2661
2662 2020-05-27 Luis Machado <luis.machado@linaro.org>
2663
2664 PR tdep/26000
2665 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
2666 for ldrd (immediate).
2667
2668 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2669
2670 * command.h: Add comment giving the name of class_tui.
2671 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
2672 create the fake command for the help for class_tui.
2673
2674 2020-05-26 Tom Tromey <tromey@adacore.com>
2675
2676 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
2677 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
2678 (val_atr): New function.
2679 (value_val_atr): Use it.
2680 * ada-valprint.c (print_optional_low_bound): Change low bound
2681 handling for enums.
2682 (val_print_packed_array_elements): Don't call discrete_position.
2683 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
2684 discrete_position for enum types.
2685 * language.c (default_print_array_index): Change type.
2686 * language.h (struct language_defn) <la_print_array_index>: Add
2687 index_type parameter, change type of index_value.
2688 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
2689 (default_print_array_index): Update.
2690 * valprint.c (maybe_print_array_index): Don't call
2691 value_from_longest. Update.
2692 (value_print_array_elements): Don't call discrete_position.
2693
2694 2020-05-26 Tom Tromey <tromey@adacore.com>
2695
2696 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
2697 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
2698
2699 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
2700
2701 PR gdb/13519
2702 * avr-tdep.c (avr_integer_to_address): Return data or code
2703 address accordingly to the second 'type' argument of the
2704 function.
2705
2706 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
2707
2708 * infcmd.c, inferior.h: (construct_inferior_arguments):
2709 Moved function from here to gdbsupport/common-inferior.{h,cc}
2710
2711 2020-05-23 Tom Tromey <tom@tromey.com>
2712
2713 Revert commit eca1f90c:
2714 * NEWS: Remove entry for completion styling.
2715 * completer.c (_rl_completion_prefix_display_length): Move
2716 declaration later.
2717 (gdb_fnprint): Revert.
2718 (gdb_display_match_list_1): Likewise.
2719 * cli/cli-style.c (completion_prefix_style)
2720 (completion_difference_style, completion_suffix_style): Remove.
2721 (_initialize_cli_style): Revert.
2722 * cli/cli-style.h (completion_prefix_style)
2723 (completion_difference_style, completion_suffix_style): Don't
2724 declare.
2725
2726 2020-05-24 Pedro Alves <palves@redhat.com>
2727
2728 * symtab.c (completion_list_add_name): Return boolean indication
2729 of whether the symbol matched.
2730 (completion_list_add_symbol): Don't try to remove C++ aliases if
2731 the symbol didn't match in the first place.
2732 * symtab.h (completion_list_add_name): Return bool.
2733
2734 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
2735
2736 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
2737 type::field.
2738
2739 2020-05-23 Joel Brobecker <brobecker@adacore.com>
2740
2741 GDB 9.2 released.
2742
2743 2020-05-23 Tom Tromey <tom@tromey.com>
2744
2745 * NEWS: Add entry for completion styling.
2746 * completer.c (_rl_completion_prefix_display_length): Move
2747 declaration earlier.
2748 (gdb_fnprint): Use completion_style.
2749 (gdb_display_match_list_1): Likewise.
2750 * cli/cli-style.c (completion_prefix_style)
2751 (completion_difference_style, completion_suffix_style): New
2752 globals.
2753 (_initialize_cli_style): Register new globals.
2754 * cli/cli-style.h (completion_prefix_style)
2755 (completion_difference_style, completion_suffix_style): Declare.
2756
2757 2020-05-23 Pedro Alves <palves@redhat.com>
2758
2759 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
2760 (parse_escape): Use ISDIGIT instead of isdigit.
2761 (puts_debug): Use gdb_isprint instead of isprint.
2762 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
2763 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
2764 ISSPACE instead of isspace.
2765 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
2766 instead of isspace.
2767 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
2768 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
2769 instead of isxdigit and ISDIGIT instead of isdigit.
2770
2771 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
2772
2773 * gdbtypes.h (struct type) <field>: New method.
2774 (TYPE_FIELDS): Remove, replace all uses with either type::fields
2775 or type::field.
2776
2777 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
2778
2779 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
2780 (TYPE_FIELDS): Use type::fields. Change all call sites that
2781 modify the propery to use type::set_fields instead.
2782
2783 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
2784
2785 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
2786 type::num_fields instead.
2787
2788 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
2789
2790 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
2791 methods.
2792 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
2793 that modify the number of fields to use type::set_num_fields
2794 instead.
2795
2796 2020-05-22 Tom Tromey <tromey@adacore.com>
2797
2798 * compile/compile-object-load.h (munmap_list_free): Don't
2799 declare.
2800
2801 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
2802
2803 * annotate.c (annotate_source_line): Update return type, add call
2804 to update current symtab and line.
2805 * annotate.h (annotate_source_line): Update return type, and
2806 extend header comment.
2807 * source.c (info_line_command): Check annotation_level before
2808 calling annotate_source_line.
2809 * stack.c (print_frame_info): If calling annotate_source_line
2810 returns true, then don't print any other source line information.
2811
2812 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
2813
2814 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
2815
2816 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
2817
2818 * coffread.c (patch_type): Remove NULL check before xfree.
2819 * corefile.c (set_gnutarget): Likewise.
2820 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
2821 * exec.c (build_section_table): Likewise.
2822 * remote.c (remote_target::pass_signals): Likewise.
2823 * utils.c (n_spaces): Likewise.
2824 * cli/cli-script.c (document_command): Likewise.
2825 * i386-windows-tdep.c (core_process_module_section): Likewise.
2826 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
2827
2828 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
2829
2830 * symfile.c (reread_symbols): Clear objfile's section_offsets
2831 vector and section indices, re-compute them by calling
2832 sym_offsets.
2833
2834 2020-05-20 Tom Tromey <tromey@adacore.com>
2835
2836 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
2837 (desc_one_bound, desc_index_type): Compute field name.
2838
2839 2020-05-20 Tom de Vries <tdevries@suse.de>
2840
2841 PR symtab/25833
2842 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
2843
2844 2020-05-20 Alan Modra <amodra@gmail.com>
2845
2846 PR 25993
2847 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
2848 bfd_set_filename.
2849 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
2850 passed to bfd_set_filename.
2851 * symfile-mem.c (add_vsyscall_page): Likewise for string
2852 passed to symbol_file_add_from_memory.
2853 (symbol_file_add_from_memory): Make name param a const char* and
2854 don't strdup.
2855
2856 2020-05-20 Alan Modra <amodra@gmail.com>
2857
2858 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
2859 rather than accessing bfd->filename directly.
2860 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
2861 and use bfd_section_name.
2862 * dwarf2/frame.c (decode_frame_entry): Likewise.
2863 * exec.c (exec_set_section_address): Likewise.
2864 * solib-aix.c (solib_aix_bfd_open): Likewise.
2865 * stap-probe.c (get_stap_base_address): Likewise.
2866 * symfile.c (reread_symbols): Likewise.
2867
2868 2020-05-19 Tom Tromey <tromey@adacore.com>
2869
2870 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
2871
2872 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
2873
2874 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
2875
2876 2020-05-19 Pedro Alves <palves@redhat.com>
2877
2878 * NEWS (set exec-file-mismatch): Adjust entry.
2879 * exec.c: Include "build-id.h".
2880 (validate_exec_file): Try to match build IDs instead of filenames.
2881 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
2882 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
2883 and pass down 'warn_if_slow'.
2884 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
2885 gdb_bfd_open_closure to pass it down.
2886 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
2887
2888 2020-05-19 Pedro Alves <palves@redhat.com>
2889
2890 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
2891 * target.c (target_fileio_open_1): Rename to target_fileio_open
2892 and make extern. Use bool.
2893 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
2894 (target_fileio_read_alloc_1): Adjust.
2895 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
2896 (target_fileio_open_warn_if_slow): Delete declaration.
2897
2898 2020-05-19 Pedro Alves <palves@redhat.com>
2899
2900 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
2901 Adjust all callers.
2902
2903 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
2904
2905 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
2906 whether disp is negative.
2907
2908 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
2909
2910 * symfile.h (struct symfile_segment_data)
2911 <~symfile_segment_data>: Remove.
2912 <segment_info>: Change to std::vector.
2913 * symfile.c (default_symfile_segments): Update.
2914 * elfread.c (elf_symfile_segments): Update.
2915
2916 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
2917
2918 * symfile.h (struct symfile_segment_data) <struct segment>: New.
2919 <segments>: New.
2920 <segment_bases, segment_sizes>: Remove.
2921 * symfile.c (default_symfile_segments): Update.
2922 * elfread.c (elf_symfile_segments): Update.
2923 * remote.c (remote_target::get_offsets): Update.
2924 * solib-target.c (solib_target_relocate_section_addresses):
2925 Update.
2926
2927 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
2928
2929 * symfile.h (struct symfile_segment_data): Initialize fields.
2930 <~symfile_segment_data>: Add.
2931 (symfile_segment_data_up): New.
2932 (struct sym_fns) <sym_segments>: Return a
2933 symfile_segment_data_up.
2934 (default_symfile_segments): Return a symfile_segment_data_up.
2935 (free_symfile_segment_data): Remove.
2936 (get_symfile_segment_data): Return a symfile_segment_data_up.
2937 * symfile.c (default_symfile_segments): Likewise.
2938 (get_symfile_segment_data): Likewise.
2939 (free_symfile_segment_data): Remove.
2940 (symfile_find_segment_sections): Update.
2941 * elfread.c (elf_symfile_segments): Return a
2942 symfile_segment_data_up.
2943 * remote.c (remote_target::get_offsets): Update.
2944 * solib-target.c (solib_target_relocate_section_addresses):
2945 Update.
2946 * symfile-debug.c (debug_sym_segments): Return a
2947 symfile_segment_data_up.
2948
2949 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2950
2951 PR build/25981
2952 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
2953 Hardcode register numbers.
2954
2955 PR build/25981
2956 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
2957 procfs_find_LDT_entry): Remove.
2958 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
2959 procfs_find_LDT_entry): Remove.
2960 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
2961 Remove.
2962
2963 2020-05-17 Pedro Alves <palves@redhat.com>
2964 Andrew Burgess <andrew.burgess@embecosm.com>
2965 Keno Fischer <keno@juliacomputing.com>
2966
2967 PR gdb/25741
2968 * breakpoint.c (build_target_condition_list): Update comments.
2969 (build_target_command_list): Update comments and skip matching
2970 locations.
2971 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
2972 a separate function. Simplify "set breakpoint auto-hw off"
2973 handling.
2974 (insert_breakpoints): Update comment.
2975 (tracepoint_locations_match): New parameter. For breakpoints,
2976 compare location types too, if the caller wants to.
2977 (handle_automatic_hardware_breakpoints): New functions.
2978 (bp_location_is_less_than): Also sort by location type and
2979 hardware breakpoint length.
2980 (update_global_location_list): Handle "set breakpoint auto-hw on"
2981 here.
2982 (update_breakpoint_locations): Ask breakpoint_locations_match to
2983 ignore location types.
2984
2985 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
2986
2987 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
2988 type::name instead.
2989
2990 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
2991
2992 * gdbtypes.h (struct type) <name, set_name>: New methods.
2993 (TYPE_CODE): Use type::name. Change all call sites used to set
2994 the name to use type::set_name instead.
2995
2996 2020-05-16 Tom Tromey <tom@tromey.com>
2997
2998 * top.c (quit_force): Update.
2999 * infrun.c (handle_no_resumed): Update.
3000 * top.h (all_uis): New function.
3001 (ALL_UIS): Remove.
3002
3003 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3004
3005 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
3006
3007 2020-05-16 Pedro Alves <palves@redhat.com>
3008
3009 * ia64-linux-nat.c
3010 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
3011 Declare method.
3012 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
3013
3014 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
3015
3016 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
3017 (sparc64_adi_info): Likewise.
3018
3019 2020-05-15 Tom Tromey <tom@tromey.com>
3020
3021 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
3022 block_objfile.
3023 (lookup_objfile_from_block): Remove.
3024 (lookup_symbol_in_block, lookup_symbol_in_static_block)
3025 (lookup_global_symbol): Use block_objfile.
3026 * symtab.h (lookup_objfile_from_block): Don't declare.
3027 * printcmd.c (clear_dangling_display_expressions): Use
3028 block_objfile.
3029 * parse.c (operator_check_standard): Use block_objfile.
3030
3031 2020-05-15 Tom Tromey <tom@tromey.com>
3032
3033 * language.c (language_alloc_type_symbol): Set
3034 SYMBOL_SECTION.
3035 * symtab.c (initialize_objfile_symbol): Remove.
3036 (allocate_symbol): Remove.
3037 (allocate_template_symbol): Remove.
3038 * dwarf2/read.c (fixup_go_packaging): Use "new".
3039 (new_symbol): Use "new".
3040 (read_variable): Don't call initialize_objfile_symbol. Use
3041 "new".
3042 (read_func_scope): Use "new".
3043 * xcoffread.c (process_xcoff_symbol): Don't call
3044 initialize_objfile_symbol.
3045 (SYMBOL_DUP): Remove.
3046 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
3047 "new".
3048 * symtab.h (allocate_symbol, initialize_objfile_symbol)
3049 (allocate_template_symbol): Don't declare.
3050 (struct symbol): Add copy constructor. Change defaults.
3051 * jit.c (finalize_symtab): Use "new".
3052 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
3053 Use "new".
3054 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
3055 (common_block_end): Use "new".
3056 * mdebugread.c (parse_symbol): Use "new".
3057 (new_symbol): Likewise.
3058
3059 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3060
3061 * NEWS: Mention changes to help and apropos.
3062
3063 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3064
3065 * command.h (enum command_class): Improve comments, document
3066 that class_alias is for user-defined aliases, give the class
3067 name for each class, remove unused class_xdb.
3068 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
3069 * breakpoint.c (_initialize_breakpoint): Replace class_alias
3070 by a precise class.
3071 * infcmd.c (_initialize_infcmd): Likewise.
3072 * reverse.c (_initialize_reverse): Likewise.
3073 * stack.c (_initialize_stack): Likewise.
3074 * symfile.c (_initialize_symfile): Likewise.
3075 * tracepoint.c (_initialize_tracepoint): Likewise.
3076
3077 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3078
3079 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
3080 when their aliased command is traversed.
3081 (help_cmd): Add fput_command_names_styled call to
3082 output command name and aliases when command has an alias.
3083
3084 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3085
3086 * cli/cli-decode.h (help_cmd_list): Remove declaration.
3087 * cli/cli-decode.c (help_cmd_list): Declare as static,
3088 remove prefix argument, use bool for recurse arg, rework to show the aliases of
3089 a command together with the command.
3090 (fput_command_name_styled, fput_command_names_styled): New functions.
3091 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
3092 fput_command_name_styled.
3093 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
3094 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
3095
3096 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3097
3098 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
3099 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
3100 * command.h (cmd_show_list): Likewise.
3101 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
3102 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
3103
3104 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3105
3106 * unittests/command-def-selftests.c (traverse_command_structure):
3107 Verify all commands of a list have the same prefix command and
3108 that only the top cmdlist commands have a null prefix.
3109
3110 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3111
3112 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
3113 as prefix, not one of its aliases.
3114 (set_cmd_prefix): Remove.
3115 (do_add_cmd): Centralize the setting of the prefix of a command, when
3116 command is defined after its full chain of prefix commands.
3117 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
3118 (add_setshow_cmd_full): Likewise.
3119 (update_prefix_field_of_prefixed_commands): New function.
3120 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
3121 update_prefix_field_of_prefixed_commands.
3122 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
3123 addresses of remote_set_cmdlist and remote_show_cmdlist given
3124 as argument, not the address of an argument.
3125 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
3126 * gdb/remote.c (_initialize_remote): Likewise.
3127
3128 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3129
3130 * cli/cli-cmds.c (alias_command): Check for an existing alias
3131 using lookup_cmd_composition, as valid_command_p is too strict
3132 and forbids aliases that are the prefix of an existing alias
3133 or command.
3134 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
3135 command is properly recognised as a valid command.
3136
3137 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3138
3139 * unittests/help-doc-selftests.c: Rename to
3140 unittests/command-def-selftests.c
3141 * unittests/command-def-selftests.c (help_doc_tests): Update some
3142 comments.
3143 (command_structure_tests, traverse_command_structure): New namespace
3144 and function.
3145 (command_structure_invariants_tests): New function.
3146 (_initialize_command_def_selftests) Renamed from
3147 _initialize_help_doc_selftests, register command_structure_invariants
3148 selftest.
3149
3150 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3151
3152 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
3153 an alias of 'show'.
3154
3155 2020-05-15 Joel Brobecker <brobecker@adacore.com>
3156
3157 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
3158 ada_is_fixed_point_type. Update all callers.
3159 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
3160 all callers.
3161 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
3162 Update all callers.
3163 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
3164 print_fixed_point_type. Update all callers.
3165 * ada-valprint.c (ada_value_print_num): Replace call to
3166 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
3167
3168 2020-05-14 Kevin Buettner <kevinb@redhat.com>
3169
3170 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
3171 processors.
3172 (cpu_supports_bts): Add CV_AMD case.
3173
3174 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
3175 Simon Marchi <simon.marchi@efficios.com>
3176
3177 * infrun.c (stop_all_threads): Collect multiple wait events at
3178 each pass.
3179
3180 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
3181
3182 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
3183 type::code instead.
3184
3185 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
3186
3187 * gdbtypes.h (struct type) <code, set_code>: New methods.
3188 (TYPE_CODE): Use type::code. Change all call sites used to set
3189 the code to use type::set_code instead.
3190
3191 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3192 Tom de Vries <tdevries@suse.de>
3193 Pedro Alves <palves@redhat.com>
3194
3195 PR threads/25478
3196 * infrun.c (stop_all_threads): Do NOT ignore
3197 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
3198 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
3199 received.
3200 (handle_no_resumed): Remove code handling a live inferior with no
3201 threads.
3202 * remote.c (has_single_non_exited_thread): New.
3203 (remote_target::update_thread_list): Do not delete a thread if is
3204 the last thread of the process.
3205 * thread.c (thread_select): Call delete_exited_threads instead of
3206 prune_threads.
3207
3208 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3209
3210 * infrun.c (stop_all_threads): Enable/disable thread events of all
3211 targets. Move a debug message denoting the end of the function
3212 into the SCOPED_EXIT block.
3213
3214 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3215
3216 * process-stratum-target.h: Include <set>.
3217 (all_non_exited_process_targets, switch_to_target_no_thread): New
3218 function declarations.
3219 * process-stratum-target.c (all_non_exited_process_targets)
3220 (switch_to_target_no_thread): New function implementations.
3221
3222 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3223
3224 * infrun.c (handle_inferior_event): Extract out a piece of code
3225 into...
3226 (mark_non_executing_threads): ...this new function.
3227
3228 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3229
3230 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
3231 use.
3232
3233 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3234
3235 * regcache.c (regcache_read_pc_protected): New function
3236 implementation that returns 0 if the PC cannot read via
3237 'regcache_read_pc'.
3238 * infrun.c (proceed): Call 'regcache_read_pc_protected'
3239 instead of 'regcache_read_pc'.
3240 (keep_going_pass_signal): Ditto.
3241
3242 2020-05-13 Tom Tromey <tromey@adacore.com>
3243
3244 * ada-lang.c (align_value): Remove.
3245 (ada_template_to_fixed_record_type_1): Use align_up.
3246
3247 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3248
3249 * async-event.c: Update the copyright year.
3250 * async-event.h: Update the copyright year.
3251
3252 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
3253
3254 * objfiles.h (is_addr_in_objfile,
3255 shared_objfile_contains_address_p): Return bool.
3256 * objfile.c (is_addr_in_objfile,
3257 shared_objfile_contains_address_p): Return bool.
3258
3259 2020-05-11 Tom Tromey <tromey@adacore.com>
3260
3261 * cli/cli-cmds.c (info_command): Restore.
3262 (_initialize_cli_cmds): Use add_prefix_command for "info".
3263 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
3264
3265 2020-05-11 Tom Tromey <tromey@adacore.com>
3266
3267 * ada-lang.c (ada_value_primitive_field): Now public.
3268 * ada-lang.h (ada_value_primitive_field): Declare.
3269 * ada-valprint.c (print_field_values): Use
3270 ada_value_primitive_field for wrapper fields.
3271
3272 2020-05-11 Tom de Vries <tdevries@suse.de>
3273
3274 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
3275 MODULE_DOMAIN.
3276
3277 2020-05-11 Tom de Vries <tdevries@suse.de>
3278
3279 PR symtab/25941
3280 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
3281 with length 0, if not gdb-produced.
3282 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
3283
3284 2020-05-09 Tom de Vries <tdevries@suse.de>
3285
3286 PR gdb/25955
3287 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
3288 calculation.
3289
3290 2020-05-09 Tom Tromey <tom@tromey.com>
3291
3292 * top.c (server_command): Now bool.
3293 * top.h (server_command): Now bool.
3294
3295 2020-05-08 Tom Tromey <tromey@adacore.com>
3296
3297 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
3298 already being processed.
3299
3300 2020-05-08 Tom Tromey <tom@tromey.com>
3301
3302 * printcmd.c (struct display) <next>: Remove.
3303 <display>: New constructor.
3304 <exp_string>: Now a std::string.
3305 <enabled_p>: Now a bool.
3306 (display_number): Move definition earlier.
3307 (displays): Rename from display_chain. Now a std::vector.
3308 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
3309 (display_command): Update.
3310 (do_one_display, disable_display)
3311 (enable_disable_display_command, do_enable_disable_display):
3312 Update.
3313 (free_display): Remove.
3314 (clear_displays): Rewrite.
3315 (delete_display): Update.
3316 (map_display_numbers): Use function_view. Remove "data"
3317 parameter. Update.
3318 (do_delete_display): Remove.
3319 (undisplay_command): Update.
3320 (do_one_display, do_displays, disable_display)
3321 (info_display_command): Update.
3322 (do_enable_disable_display): Remove.
3323 (enable_disable_display_command)
3324 (clear_dangling_display_expressions): Update.
3325
3326 2020-05-08 Tom Tromey <tom@tromey.com>
3327
3328 * symtab.c (set_symbol_cache_size)
3329 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
3330 (maintenance_print_symbol_cache_statistics): Update.
3331 * symmisc.c (print_symbol_bcache_statistics)
3332 (print_objfile_statistics, maintenance_print_objfiles)
3333 (maintenance_info_symtabs, maintenance_check_symtabs)
3334 (maintenance_expand_symtabs, maintenance_info_line_tables):
3335 Update.
3336 * symfile-debug.c (set_debug_symfile): Update.
3337 * source.c (forget_cached_source_info): Update.
3338 * python/python.c (gdbpy_progspaces): Update.
3339 * psymtab.c (maintenance_info_psymtabs): Update.
3340 * probe.c (parse_probes): Update.
3341 * linespec.c (iterate_over_all_matching_symtabs)
3342 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
3343 * guile/scm-progspace.c (gdbscm_progspaces): Update.
3344 * exec.c (exec_target::close): Update.
3345 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
3346 * breakpoint.c (print_one_breakpoint_location)
3347 (create_longjmp_master_breakpoint)
3348 (create_std_terminate_master_breakpoint): Update.
3349 * progspace.c (program_spaces): Now a std::vector.
3350 (maybe_new_address_space): Update.
3351 (add_program_space): Remove.
3352 (program_space::program_space): Update.
3353 (remove_program_space): Update.
3354 (number_of_program_spaces): Remove.
3355 (print_program_space, update_address_spaces): Update.
3356 * progspace.h (program_spaces): Change type.
3357 (ALL_PSPACES): Remove.
3358 (number_of_program_spaces): Don't declare.
3359 (struct program_space) <next>: Remove.
3360
3361 2020-05-08 Tom Tromey <tom@tromey.com>
3362
3363 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
3364 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
3365 (enable_break): Update.
3366 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
3367 (frv_fdpic_find_canonical_descriptor): Update.
3368 (frv_fetch_objfile_link_map): Update.
3369 * progspace.c (program_space::free_all_objfiles): Update.
3370 (program_space::solibs): New method.
3371 * progspace.h (struct program_space) <solibs>: New method.
3372 * solist.h (master_so_list): Don't declare.
3373 (ALL_SO_LIBS): Remove.
3374 * solib.h (so_list_head): Remove.
3375 (update_solib_list): Update comment.
3376 * solib.c (master_so_list): Remove.
3377 (solib_used, update_solib_list, solib_add)
3378 (info_sharedlibrary_command, clear_solib)
3379 (reload_shared_libraries_1, remove_user_added_objfile): Update.
3380
3381 2020-05-08 Tom Tromey <tom@tromey.com>
3382
3383 * extension.c (extension_languages): Now a std::array.
3384 (ALL_EXTENSION_LANGUAGES): Remove.
3385 (get_ext_lang_defn, get_ext_lang_of_file)
3386 (eval_ext_lang_from_control_command): Update.
3387 (finish_ext_lang_initialization)
3388 (auto_load_ext_lang_scripts_for_objfile)
3389 (ext_lang_type_printers::ext_lang_type_printers)
3390 (apply_ext_lang_type_printers)
3391 (ext_lang_type_printers::~ext_lang_type_printers)
3392 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
3393 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
3394 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
3395 (get_matching_xmethod_workers, ext_lang_colorize)
3396 (ext_lang_before_prompt): Update.
3397 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
3398
3399 2020-05-08 Tom Tromey <tom@tromey.com>
3400
3401 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
3402 overload.
3403 <swap_string, m_string>: Remove.
3404 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
3405 Update.
3406 * stabsread.c (define_symbol, read_type): Update.
3407 * linespec.c (find_linespec_symbols): Update.
3408 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
3409 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
3410 * dbxread.c (read_dbx_symtab): Update.
3411 * cp-support.h (cp_canonicalize_string_full)
3412 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
3413 Return unique_xmalloc_ptr.
3414 * cp-support.c (inspect_type): Update.
3415 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
3416 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
3417 Likewise.
3418 * c-typeprint.c (print_name_maybe_canonical): Update.
3419 * break-catch-throw.c (check_status_exception_catchpoint):
3420 Update.
3421
3422 2020-05-08 Tom de Vries <tdevries@suse.de>
3423
3424 * infrun.c (follow_fork): Copy current_line and current_symtab to
3425 child thread.
3426
3427 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3428
3429 * async-event.c (struct async_signal_handler, struct
3430 async_event_handler): Reformat, remove typedef.
3431
3432 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3433
3434 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
3435 access thistype->main_type->dyn_prop_list directly.
3436
3437 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3438
3439 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
3440 (remove_dyn_prop): Remove. Update all users to use
3441 type::remove_dyn_prop.
3442 * gdbtypes.c (remove_dyn_prop): Rename to...
3443 (type::remove_dyn_prop): ... this.
3444
3445 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
3446
3447 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
3448 (add_dyn_prop): Remove. Update all users to use
3449 type::add_dyn_prop.
3450 * gdbtypes.c (add_dyn_prop): Rename to...
3451 (type::add_dyn_prop): ... this.
3452
3453 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
3454
3455 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
3456 (get_dyn_prop): Remove. Update all users to use
3457 type::dyn_prop.
3458 * gdbtypes.c (get_dyn_prop): Rename to...
3459 (type::dyn_prop): ... this.
3460
3461 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
3462
3463 * gdbtypes.h (struct main_type) <flag_static>: Remove.
3464
3465 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
3466
3467 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
3468 instruction, skip it if it's there.
3469
3470 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
3471
3472 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
3473
3474 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
3475
3476 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
3477 * gdbtypes.c (recursive_dump_type): Remove use of
3478 TYPE_INCOMPLETE.
3479
3480 2020-05-03 Tom Tromey <tom@tromey.com>
3481
3482 * breakpoint.c (catch_command, tcatch_command): Remove.
3483 (_initialize_breakpoint): Use add_basic_prefix_cmd,
3484 add_show_prefix_cmd.
3485 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
3486 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
3487 Remove.
3488 (add_internal_problem_command): Use add_basic_prefix_cmd,
3489 add_show_prefix_cmd.
3490 * mips-tdep.c (set_mipsfpu_command): Remove.
3491 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
3492 * dwarf2/index-cache.c (set_index_cache_command): Remove.
3493 (_initialize_index_cache): Use add_basic_prefix_cmd.
3494 * memattr.c (dummy_cmd): Remove.
3495 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
3496 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
3497 (_initialize_tui_win): Use add_basic_prefix_cmd,
3498 add_show_prefix_cmd.
3499 * cli/cli-logging.c (set_logging_command): Remove.
3500 (_initialize_cli_logging): Use add_basic_prefix_cmd,
3501 add_show_prefix_cmd.
3502 (show_logging_command): Remove.
3503 * target.c (target_command): Remove.
3504 (add_target): Use add_basic_prefix_cmd.
3505
3506 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
3507
3508 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
3509
3510 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3511
3512 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
3513 info_command.
3514
3515 2020-04-30 Kamil Rytarowski <n54@gmx.com>
3516
3517 * nbsd-nat.c (nbsd_enable_proc_events)
3518 (nbsd_nat_target::post_startup_inferior): Add.
3519 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
3520 (nbsd_nat_target::update_thread_list): Rewrite.
3521 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
3522 "PTRACE_LWP_CREATE".
3523 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
3524
3525 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3526
3527 * stack.c (_initialize_stack): Remove duplicated creation
3528 of "frame" command and "f" alias.
3529
3530 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
3531
3532 PR gdb/18706
3533 * gdbtypes.c (check_typedef): Calculate size of array of
3534 stubbed type.
3535
3536 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
3537
3538 PR gdb/15559
3539 * i386-tdep.c (i386_push_dummy_call): Call
3540 i386_thiscall_push_dummy_call.
3541 (i386_thiscall_push_dummy_call): New function.
3542 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
3543 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
3544 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
3545
3546 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3547
3548 * gdbarch.sh (do_read): Add shellcheck disable directive for
3549 warning SC2162.
3550
3551 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3552
3553 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
3554 "referenced but not assigned" warning.
3555
3556 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3557
3558 * gdbarch.sh: Remove code that sets fallbackdefault.
3559
3560 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3561
3562 * gdbarch.sh: Use shell operators && and || instead of
3563 -a and -o.
3564
3565 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3566
3567 * gdbarch.sh: Use $(...) instead of `...`.
3568
3569 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3570
3571 * gdbarch.sh: Use double quotes around variables.
3572
3573 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
3574
3575 * gdbarch.sh: Use %s with printf, instead of variables in the
3576 format string.
3577
3578 2020-04-29 Tom Tromey <tromey@adacore.com>
3579
3580 PR ada/25875:
3581 * dwarf2/read.c (update_enumeration_type_from_children): Compute
3582 type fields here.
3583 (read_enumeration_type): Call
3584 update_enumeration_type_from_children later. Update comments.
3585 (process_enumeration_scope): Don't create type fields.
3586
3587 2020-04-29 Kamil Rytarowski <n54@gmx.com>
3588
3589 * nbsd-tdep.c: Include "xml-syscall.h".
3590 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
3591
3592 2020-04-29 Kamil Rytarowski <n54@gmx.com>
3593
3594 * nbsd-nat.c: Include "sys/wait.h".
3595 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
3596 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
3597 (nbsd_nat_target::remove_exec_catchpoint)
3598 (nbsd_nat_target::set_syscall_catchpoint): Add.
3599 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
3600 (nbsd_nat_target::insert_exec_catchpoint)
3601 (nbsd_nat_target::remove_exec_catchpoint)
3602 (nbsd_nat_target::set_syscall_catchpoint): Add.
3603 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
3604 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
3605 `nbsd_get_syscall_number'.
3606
3607 2020-04-29 Tom Tromey <tom@tromey.com>
3608
3609 * stack.c (print_block_frame_labels): Remove.
3610
3611 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
3612
3613 PR gdb/17320
3614 * ada-valprint.c (val_print_packed_array_elements): Move array
3615 end bracket to new line.
3616 (ada_val_print_string): Remove extra spaces before first array
3617 element.
3618 * c-valprint.c (c_value_print_array): Likewise.
3619 * m2-valprint.c (m2_print_array_contents): Likewise.
3620 (m2_value_print_inner): Likewise.
3621 * p-valprint.c (pascal_value_print_inner): Likewise.
3622 * valprint.c (generic_val_print_array): Likewise.
3623 (value_print_array_elements): Move first array element and array
3624 end bracket to new line.
3625
3626 2020-04-29 Tom de Vries <tdevries@suse.de>
3627
3628 PR symtab/25889
3629 * linespec.c (find_method): Fix ix calculation.
3630
3631 2020-04-28 Kamil Rytarowski <n54@gmx.com>
3632
3633 * syscalls/update-netbsd.sh: New file.
3634 * syscalls/netbsd.xml: Regenerate.
3635 * data-directory/Makefile.in: Register `netbsd.xml' in
3636 `SYSCALLS_FILES'.
3637
3638 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
3639
3640 * syscalls/update-freebsd.sh: Add double quotes.
3641
3642 2020-04-28 Tom Tromey <tom@tromey.com>
3643
3644 * NEWS: Update.
3645 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
3646 (cmdpy_init): Allow class_tui.
3647
3648 2020-04-28 Mark Williams <mark@myosotissp.com>
3649
3650 PR gdb/24480
3651 * dwarf2read.c: Add missing assingments to list_in_scope when
3652 start_symtab was already called.
3653
3654 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
3655
3656 PR gdb/25881
3657 * dwarf2/read.c (offset_map_type): Use
3658 gdb:hash_enum<sect_offset> as hash function.
3659
3660 2020-04-28 Tom de Vries <tdevries@suse.de>
3661
3662 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
3663 with DW_AT_signature.
3664
3665 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
3666
3667 * configure.ac: Remove check for fs_base/gs_base in
3668 user_regs_struct.
3669 * configure: Re-generate.
3670 * config.in: Re-generate.
3671 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
3672 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
3673 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
3674
3675 2020-04-27 Luis Machado <luis.machado@linaro.org>
3676
3677 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
3678 problematic inline frame unwinding situation.
3679 * frame.c (frame_id_computed_p): New function.
3680 * frame.h (frame_id_computed_p): New prototype.
3681
3682 2020-04-26 Tom Tromey <tom@tromey.com>
3683
3684 * command.h (enum command_class) <class_pseudo>: Remove.
3685
3686 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3687
3688 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
3689 and whitespace.
3690
3691 2020-04-25 Kamil Rytarowski <n54@gmx.com>
3692
3693 * inf-ptrace.c (inf_ptrace_target::wait): Remove
3694 `PT_GET_PROCESS_STATE' block.
3695
3696 2020-04-24 Tom Tromey <tom@tromey.com>
3697
3698 * symtab.h (symbol_get_demangled_name): Don't declare.
3699 * symtab.c (symbol_get_demangled_name): Remove.
3700 (general_symbol_info::natural_name)
3701 (general_symbol_info::demangled_name): Update.
3702
3703 2020-04-24 Tom Tromey <tom@tromey.com>
3704
3705 PR rust/25025:
3706 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
3707
3708 2020-04-24 Tom Tromey <tom@tromey.com>
3709
3710 PR symtab/12707:
3711 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
3712 exists.
3713 (new_symbol): Likewise.
3714 * compile/compile-object-load.c (get_out_value_type): Use
3715 symbol_matches_search_name.
3716
3717 2020-04-24 Tom Tromey <tom@tromey.com>
3718
3719 * dwarf2/read.c (add_partial_symbol): Do not call
3720 compute_and_set_names.
3721
3722 2020-04-24 Tom Tromey <tom@tromey.com>
3723
3724 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
3725 overload.
3726
3727 2020-04-24 Tom Tromey <tom@tromey.com>
3728
3729 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
3730 (add_psymbol_to_list): New overload. Make old overload call new
3731 one.
3732 * psympriv.h (add_psymbol_to_list): New overload.
3733
3734 2020-04-24 Tom Tromey <tom@tromey.com>
3735
3736 * dwarf2/read.c (partial_die_info::read) <case
3737 DW_AT_linkage_name>: Use value_as_string.
3738 (dwarf2_string_attr): Use value_as_string.
3739 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
3740 method.
3741 * dwarf2/attribute.c (attribute::value_as_string): New method.
3742
3743 2020-04-24 Tom Tromey <tom@tromey.com>
3744
3745 * symtab.c (general_symbol_info::natural_name)
3746 (general_symbol_info::demangled_name): Check for language_rust.
3747
3748 2020-04-24 Tom Tromey <tom@tromey.com>
3749
3750 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
3751 (dwarf2_physname): ... from here.
3752 (partial_die_info::read): Add Rust "{" hack.
3753
3754 2020-04-24 Tom Tromey <tom@tromey.com>
3755
3756 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
3757 method.
3758 (symbol_set_demangled_name): Don't declare.
3759 * symtab.c (general_symbol_info::set_demangled_name): Rename from
3760 symbol_set_demangled_name.
3761 (general_symbol_info::set_language)
3762 (general_symbol_info::compute_and_set_names): Update.
3763 * minsyms.c (minimal_symbol_reader::install): Update.
3764 * dwarf2/read.c (new_symbol): Update.
3765
3766 2020-04-24 Tom Tromey <tromey@adacore.com>
3767
3768 PR python/23662:
3769 * python/py-type.c (convert_field): Handle
3770 FIELD_LOC_KIND_DWARF_BLOCK.
3771 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
3772 (typy_get_dynamic): Nw function.
3773 (type_object_getset): Add "dynamic".
3774 * NEWS: Add entry.
3775
3776 2020-04-24 Tom Tromey <tromey@adacore.com>
3777
3778 * ada-typeprint.c (print_choices, print_variant_part)
3779 (print_record_field_types_dynamic): New functions.
3780 (print_record_field_types): Use print_record_field_types_dynamic.
3781
3782 2020-04-24 Tom Tromey <tromey@adacore.com>
3783
3784 * dwarf2/read.c (handle_data_member_location): New overload.
3785 (dwarf2_add_field): Use it.
3786 (decode_locdesc): Add "computed" parameter. Update comment.
3787 * gdbtypes.c (is_dynamic_type_internal): Also look for
3788 FIELD_LOC_KIND_DWARF_BLOCK.
3789 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
3790 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
3791 virtual base classes.
3792 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
3793 FIELD_LOC_KIND_DWARF_BLOCK.
3794
3795 2020-04-24 Tom Tromey <tromey@adacore.com>
3796
3797 * dwarf2/read.c (read_structure_type): Handle dynamic length.
3798 * gdbtypes.c (is_dynamic_type_internal): Check
3799 TYPE_HAS_DYNAMIC_LENGTH.
3800 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
3801 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
3802 New macros.
3803 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
3804 constant.
3805
3806 2020-04-24 Tom Tromey <tromey@adacore.com>
3807
3808 * dwarf2/read.c (struct variant_field): Rewrite.
3809 (struct variant_part_builder): New.
3810 (struct nextfield): Remove "variant" field. Add "offset".
3811 (struct field_info): Add "current_variant_part" and
3812 "variant_parts".
3813 (alloc_discriminant_info): Remove.
3814 (alloc_rust_variant): New function.
3815 (quirk_rust_enum): Update.
3816 (dwarf2_add_field): Set "offset" member. Don't handle
3817 DW_TAG_variant_part.
3818 (offset_map_type): New typedef.
3819 (convert_variant_range, create_one_variant)
3820 (create_one_variant_part, create_variant_parts)
3821 (add_variant_property): New functions.
3822 (dwarf2_attach_fields_to_type): Call add_variant_property.
3823 (read_structure_type): Don't handle DW_TAG_variant_part.
3824 (handle_variant_part, handle_variant): New functions.
3825 (handle_struct_member_die): Use them.
3826 (process_structure_scope): Don't handle variant parts.
3827 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
3828 (struct discriminant_info): Remove.
3829 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
3830 (struct main_type) <flag_discriminated_union>: Remove.
3831 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
3832 (rust_enum_variant): Return int. Remove "contents". Rewrite.
3833 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
3834 Update.
3835 * valops.c (value_union_variant): Remove.
3836 * value.h (value_union_variant): Don't declare.
3837
3838 2020-04-24 Tom Tromey <tromey@adacore.com>
3839
3840 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
3841 (ada_value_primitive_packed_val): Update.
3842 * ada-valprint.c (ada_value_print_1): Update.
3843 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
3844 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
3845 just an address. Use evaluate_for_locexpr_baton.
3846 (dwarf2_evaluate_property): Update.
3847 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
3848 array_view.
3849 * findvar.c (default_read_var_value): Update.
3850 * gdbtypes.c (compute_variant_fields_inner)
3851 (resolve_dynamic_type_internal): Update.
3852 (resolve_dynamic_type): Change type of valaddr parameter.
3853 * gdbtypes.h (resolve_dynamic_type): Update.
3854 * valarith.c (value_subscripted_rvalue): Update.
3855 * value.c (value_from_contents_and_address): Update.
3856
3857 2020-04-24 Tom Tromey <tromey@adacore.com>
3858
3859 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
3860 "push_initial_value" parameter.
3861 (dwarf2_evaluate_property): Likewise.
3862 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
3863
3864 2020-04-24 Tom Tromey <tromey@adacore.com>
3865
3866 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
3867 (variant::matches, compute_variant_fields_recurse)
3868 (compute_variant_fields_inner, compute_variant_fields): New
3869 functions.
3870 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
3871 Use resolved_type after type is made.
3872 (operator==): Add new cases.
3873 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
3874 (struct discriminant_range, struct variant, struct variant_part):
3875 New.
3876 (union dynamic_prop_data) <variant_parts, original_type>: New
3877 members.
3878 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
3879 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
3880 constants.
3881 * value.c (unpack_bits_as_long): Now public.
3882 * value.h (unpack_bits_as_long): Declare.
3883
3884 2020-04-24 Tom Tromey <tromey@adacore.com>
3885
3886 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
3887 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
3888
3889 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
3890
3891 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
3892
3893 2020-04-24 Kamil Rytarowski <n54@gmx.com>
3894
3895 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
3896 (remove_fork_catchpoint, post_startup_inferior)
3897 (post_attach): Move...
3898 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
3899 (remove_fork_catchpoint, post_startup_inferior)
3900 (post_attach): ...here.
3901 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
3902 (remove_fork_catchpoint, post_startup_inferior)
3903 (post_attach): Move...
3904 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
3905 (remove_fork_catchpoint, post_startup_inferior)
3906 (post_attach): ...here.
3907
3908 2020-04-24 Tom Tromey <tromey@adacore.com>
3909
3910 * nat/windows-nat.h (struct windows_thread_info)
3911 <pc_adjusted>: New member.
3912 * windows-nat.c (windows_fetch_one_register): Check
3913 pc_adjusted.
3914 (windows_nat_target::get_windows_debug_event)
3915 (windows_nat_target::wait): Set pc_adjusted.
3916
3917 2020-04-24 Tom de Vries <tdevries@suse.de>
3918
3919 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
3920 Run gdb-add-index inside temp dir.
3921
3922 2020-04-23 Tom Tromey <tromey@adacore.com>
3923
3924 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
3925 in loop.
3926
3927 2020-04-23 Luis Machado <luis.machado@linaro.org>
3928
3929 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
3930 get_frame_register instead of gdbarch_unwind_pc.
3931
3932 2020-04-23 Tom de Vries <tdevries@suse.de>
3933
3934 * symtab.c (lookup_global_symbol): Prefer def over decl.
3935
3936 2020-04-23 Tom de Vries <tdevries@suse.de>
3937
3938 PR symtab/25807
3939 * block.c (best_symbol, better_symbol): Promote to external.
3940 * block.h (best_symbol, better_symbol): Declare.
3941 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
3942 decl.
3943
3944 2020-04-23 Tom Tromey <tromey@adacore.com>
3945
3946 PR ada/25837:
3947 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
3948 "const char *", not a "const std::string &".
3949 <name_and_matcher::operator==>: Update.
3950 * unittests/lookup_name_info-selftests.c: Change type of
3951 "result".
3952
3953 2020-04-23 Tom Tromey <tom@tromey.com>
3954
3955 * inferior.h (iterate_over_inferiors): Don't declare.
3956 * inferior.c (iterate_over_inferiors): Remove.
3957 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
3958 Remove.
3959 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
3960 use iterate_over_inferiors.
3961 (darwin_resume_inferior_it)
3962 (struct resume_inferior_threads_param)
3963 (darwin_resume_inferior_threads_it): Remove.
3964 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
3965
3966 2020-04-23 Tom de Vries <tdevries@suse.de>
3967
3968 * blockframe.c (find_pc_partial_function): Use
3969 find_pc_sect_compunit_symtab rather than
3970 objfile->sf->qf->find_pc_sect_compunit_symtab.
3971
3972 2020-04-22 Tom de Vries <tdevries@suse.de>
3973
3974 PR symtab/25764
3975 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
3976 in psymtabs.
3977
3978 2020-04-22 Tom de Vries <tdevries@suse.de>
3979
3980 PR symtab/25801
3981 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
3982 symtabs.
3983
3984 2020-04-22 Tom de Vries <tdevries@suse.de>
3985
3986 PR symtab/25700
3987 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
3988 CU if already created.
3989
3990 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3991
3992 * infrun.c (displaced_step_fixup): Switch to the event_thread
3993 before calling displaced_step_restore, not after.
3994
3995 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
3996
3997 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
3998 its inferior is not recorded by us.
3999 (record_btrace_target_open): Replace call to
4000 all_non_exited_threads () with call to current_inferior
4001 ()->non_exited_threads ().
4002 (record_btrace_target::stop_recording): Likewise.
4003 (record_btrace_target::close): Likewise.
4004 (record_btrace_target::wait): Likewise.
4005 (record_btrace_target::record_stop_replaying): Likewise.
4006
4007 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4008
4009 * btrace.c (btrace_enable): Throw an error on double enables and
4010 when enabling recording fails.
4011 (btrace_disable): Throw an error if the thread is not recorded.
4012
4013 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4014
4015 * record-btrace.c (record_btrace_target::fetch_registers): Forward
4016 request if we do not have a thread_info.
4017
4018 2020-04-21 Tom de Vries <tdevries@suse.de>
4019
4020 PR gdb/25471
4021 * thread.c
4022 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
4023 exception in get_frame_id.
4024
4025 2020-04-20 Tom Tromey <tromey@adacore.com>
4026
4027 * python/python.c (struct gdbpy_event): Mark move constructor as
4028 noexcept.
4029 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
4030 constructor as noexcept.
4031 * completer.h (struct completion_result): Mark move constructor as
4032 noexcept.
4033 * completer.c (completion_result::completion_result): Use
4034 initialization style. Don't call reset_match_list.
4035
4036 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
4037
4038 * MAINTAINERS (Write After Approval): Add myself.
4039
4040 2020-04-18 Tom Tromey <tom@tromey.com>
4041
4042 * windows-tdep.c (init_w32_command_list)
4043 (w32_prefix_command_valid): Restore.
4044 (_initialize_windows_tdep): Call init_w32_command_list.
4045
4046 2020-04-18 Tom Tromey <tom@tromey.com>
4047
4048 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
4049 * value.c (value_fn_field): Update.
4050 * valops.c (find_function_in_inferior)
4051 (value_allocate_space_in_inferior): Update.
4052 * tui/tui-winsource.c (tui_update_source_windows_with_line):
4053 Update.
4054 * tui/tui-source.c (tui_source_window::set_contents): Update.
4055 * symtab.c (lookup_global_or_static_symbol)
4056 (find_function_start_sal_1, skip_prologue_sal)
4057 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
4058 * symmisc.c (dump_msymbols, dump_symtab_1)
4059 (maintenance_print_one_line_table): Update.
4060 * symfile.c (init_entry_point_info, section_is_mapped)
4061 (list_overlays_command, simple_read_overlay_table)
4062 (simple_overlay_update_1): Update.
4063 * stap-probe.c (handle_stap_probe): Update.
4064 * stabsread.c (dbx_init_float_type, define_symbol)
4065 (read_one_struct_field, read_enum_type, read_range_type): Update.
4066 * source.c (info_line_command): Update.
4067 * python/python.c (gdbpy_source_objfile_script)
4068 (gdbpy_execute_objfile_script): Update.
4069 * python/py-type.c (save_objfile_types): Update.
4070 * python/py-objfile.c (py_free_objfile): Update.
4071 * python/py-inferior.c (python_new_objfile): Update.
4072 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
4073 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
4074 (maintenance_check_psymtabs): Update.
4075 * printcmd.c (info_address_command): Update.
4076 * objfiles.h (struct objfile) <arch>: New method, from
4077 get_objfile_arch.
4078 (get_objfile_arch): Don't declare.
4079 * objfiles.c (get_objfile_arch): Remove.
4080 (filter_overlapping_sections): Update.
4081 * minsyms.c (msymbol_is_function): Update.
4082 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
4083 (output_nondebug_symbol): Update.
4084 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
4085 (mdebug_expand_psymtab): Update.
4086 * machoread.c (macho_add_oso_symfile): Update.
4087 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
4088 Update.
4089 * linux-fork.c (checkpoint_command): Update.
4090 * linespec.c (convert_linespec_to_sals): Update.
4091 * jit.c (finalize_symtab): Update.
4092 * infrun.c (insert_exception_resume_from_probe): Update.
4093 * ia64-tdep.c (ia64_find_unwind_table): Update.
4094 * hppa-tdep.c (internalize_unwinds): Update.
4095 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
4096 Update.
4097 * gcore.c (call_target_sbrk): Update.
4098 * elfread.c (record_minimal_symbol, elf_symtab_read)
4099 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
4100 (elf_gnu_ifunc_resolve_by_got): Update.
4101 * dwarf2/read.c (create_addrmap_from_index)
4102 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
4103 (read_debug_names_from_section)
4104 (process_psymtab_comp_unit_reader, add_partial_symbol)
4105 (add_partial_subprogram, process_full_comp_unit)
4106 (read_file_scope, read_func_scope, read_lexical_block_scope)
4107 (read_call_site_scope, dwarf2_ranges_read)
4108 (dwarf2_record_block_ranges, dwarf2_add_field)
4109 (mark_common_block_symbol_computed, read_tag_pointer_type)
4110 (read_tag_string_type, dwarf2_init_float_type)
4111 (dwarf2_init_complex_target_type, read_base_type)
4112 (partial_die_info::read, partial_die_info::read)
4113 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
4114 (dwarf2_fetch_die_loc_sect_off): Update.
4115 * dwarf2/loc.c (dwarf2_find_location_expression)
4116 (class dwarf_evaluate_loc_desc, rw_pieced_value)
4117 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
4118 (dwarf2_loc_desc_get_symbol_read_needs)
4119 (locexpr_describe_location_piece, locexpr_describe_location_1)
4120 (loclist_describe_location): Update.
4121 * dwarf2/index-write.c (write_debug_names): Update.
4122 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
4123 * dtrace-probe.c (dtrace_process_dof): Update.
4124 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
4125 (process_one_symbol): Update.
4126 * ctfread.c (ctf_init_float_type, read_base_type): Update.
4127 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
4128 (coff_read_enum_type): Update.
4129 * cli/cli-cmds.c (edit_command, list_command): Update.
4130 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
4131 * breakpoint.c (create_overlay_event_breakpoint)
4132 (create_longjmp_master_breakpoint)
4133 (create_std_terminate_master_breakpoint)
4134 (create_exception_master_breakpoint, get_sal_arch): Update.
4135 * block.c (block_gdbarch): Update.
4136 * annotate.c (annotate_source_line): Update.
4137
4138 2020-04-17 Tom Tromey <tromey@adacore.com>
4139
4140 * auto-load.c (show_auto_load_cmd): Remove.
4141 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
4142 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
4143 (maintenance_print_arc_command): Remove.
4144 * tui/tui-win.c (tui_command): Remove.
4145 (tui_get_cmd_list): Use add_basic_prefix_cmd.
4146 * tui/tui-layout.c (tui_layout_command): Remove.
4147 (_initialize_tui_layout): Use add_basic_prefix_cmd.
4148 * python/python.c (user_set_python, user_show_python): Remove.
4149 (_initialize_python): Use add_basic_prefix_cmd,
4150 add_show_prefix_cmd.
4151 * guile/guile.c (set_guile_command, show_guile_command): Remove.
4152 (install_gdb_commands): Use add_basic_prefix_cmd,
4153 add_show_prefix_cmd.
4154 (info_guile_command): Remove.
4155 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
4156 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
4157 add_show_prefix_cmd.
4158 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
4159 Remove do_set and do_show parameters.
4160 * cli/cli-style.c (set_style, show_style): Remove.
4161 (_initialize_cli_style): Use add_basic_prefix_cmd,
4162 add_show_prefix_cmd.
4163 (cli_style_option::add_setshow_commands): Remove do_set and
4164 do_show parameters.
4165 (cli_style_option::add_setshow_commands): Use
4166 add_basic_prefix_cmd, add_show_prefix_cmd.
4167 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
4168 (set_style_name): Remove.
4169 * cli/cli-dump.c (dump_command, append_command): Remove.
4170 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4171 (tekhex_dump_command, binary_dump_command)
4172 (binary_append_command): Remove.
4173 (_initialize_cli_dump): Use add_basic_prefix_cmd.
4174 * windows-tdep.c (w32_prefix_command_valid): Remove global.
4175 (init_w32_command_list): Remove; move into ...
4176 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
4177 * valprint.c (set_print, show_print, set_print_raw)
4178 (show_print_raw): Remove.
4179 (_initialize_valprint): Use add_basic_prefix_cmd,
4180 add_show_prefix_cmd.
4181 * typeprint.c (set_print_type, show_print_type): Remove.
4182 (_initialize_typeprint): Use add_basic_prefix_cmd,
4183 add_show_prefix_cmd.
4184 * record.c (set_record_command, show_record_command): Remove.
4185 (_initialize_record): Use add_basic_prefix_cmd,
4186 add_show_prefix_cmd.
4187 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
4188 add_show_prefix_cmd.
4189 (info_command, show_command, set_debug, show_debug): Remove.
4190 * top.h (set_history, show_history): Don't declare.
4191 * top.c (set_history, show_history): Remove.
4192 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4193 (unset_tdesc_cmd): Remove.
4194 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
4195 add_show_prefix_cmd.
4196 * symtab.c (info_module_command): Remove.
4197 (_initialize_symtab): Use add_basic_prefix_cmd.
4198 * symfile.c (overlay_command): Remove.
4199 (_initialize_symfile): Use add_basic_prefix_cmd.
4200 * sparc64-tdep.c (info_adi_command): Remove.
4201 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
4202 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
4203 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
4204 add_show_prefix_cmd.
4205 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
4206 (_initialize_serial): Use add_basic_prefix_cmd,
4207 add_show_prefix_cmd.
4208 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
4209 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
4210 add_show_prefix_cmd.
4211 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
4212 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
4213 add_show_prefix_cmd.
4214 * riscv-tdep.c (show_riscv_command, set_riscv_command)
4215 (show_debug_riscv_command, set_debug_riscv_command): Remove.
4216 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
4217 add_show_prefix_cmd.
4218 * remote.c (remote_command, set_remote_cmd): Remove.
4219 (_initialize_remote): Use add_basic_prefix_cmd.
4220 * record-full.c (set_record_full_command)
4221 (show_record_full_command): Remove.
4222 (_initialize_record_full): Use add_basic_prefix_cmd,
4223 add_show_prefix_cmd.
4224 * record-btrace.c (cmd_set_record_btrace)
4225 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
4226 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
4227 (cmd_show_record_btrace_pt): Remove.
4228 (_initialize_record_btrace): Use add_basic_prefix_cmd,
4229 add_show_prefix_cmd.
4230 * ravenscar-thread.c (set_ravenscar_command)
4231 (show_ravenscar_command): Remove.
4232 (_initialize_ravenscar): Use add_basic_prefix_cmd,
4233 add_show_prefix_cmd.
4234 * mips-tdep.c (show_mips_command, set_mips_command)
4235 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
4236 add_show_prefix_cmd.
4237 * maint.c (maintenance_command, maintenance_info_command)
4238 (maintenance_check_command, maintenance_print_command)
4239 (maintenance_set_cmd, maintenance_show_cmd): Remove.
4240 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
4241 add_show_prefix_cmd.
4242 (show_per_command_cmd): Remove.
4243 * maint-test-settings.c (maintenance_set_test_settings_cmd):
4244 Remove.
4245 (maintenance_show_test_settings_cmd): Remove.
4246 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
4247 add_show_prefix_cmd.
4248 * maint-test-options.c (maintenance_test_options_command):
4249 Remove.
4250 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
4251 * macrocmd.c (macro_command): Remove
4252 (_initialize_macrocmd): Use add_basic_prefix_cmd.
4253 * language.c (set_check, show_check): Remove.
4254 (_initialize_language): Use add_basic_prefix_cmd,
4255 add_show_prefix_cmd.
4256 * infcmd.c (unset_command): Remove.
4257 (_initialize_infcmd): Use add_basic_prefix_cmd.
4258 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
4259 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
4260 add_show_prefix_cmd.
4261 * go32-nat.c (go32_info_dos_command): Remove.
4262 (_initialize_go32_nat): Use add_basic_prefix_cmd.
4263 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
4264 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
4265 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
4266 (_initialize_frame): Use add_basic_prefix_cmd,
4267 add_show_prefix_cmd.
4268 * dcache.c (set_dcache_command, show_dcache_command): Remove.
4269 (_initialize_dcache): Use add_basic_prefix_cmd,
4270 add_show_prefix_cmd.
4271 * cp-support.c (maint_cplus_command): Remove.
4272 (_initialize_cp_support): Use add_basic_prefix_cmd.
4273 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4274 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4275 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
4276 add_basic_prefix_cmd, add_show_prefix_cmd.
4277 * breakpoint.c (save_command): Remove.
4278 (_initialize_breakpoint): Use add_basic_prefix_cmd.
4279 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
4280 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
4281 add_show_prefix_cmd.
4282 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
4283 (set_ada_command, show_ada_command): Remove.
4284 (_initialize_ada_language): Use add_basic_prefix_cmd,
4285 add_show_prefix_cmd.
4286 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
4287
4288 2020-04-16 Kamil Rytarowski <n54@gmx.com>
4289
4290 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
4291 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
4292
4293 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
4294
4295 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
4296 warning messages.
4297
4298 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
4299
4300 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
4301 import table is not at beginning of .idata section.
4302
4303 2020-04-16 Pedro Alves <palves@redhat.com>
4304
4305 * inferior.c (delete_inferior): Use delete operator directly
4306 instead of delete_program_space.
4307 * progspace.c (add_program_space): New, factored out from
4308 program_space::program_space.
4309 (remove_program_space): New, factored out from
4310 delete_program_space.
4311 (program_space::program_space): Remove intro comment. Rewrite.
4312 (program_space::~program_space): Remove intro comment. Call
4313 remove_program_space.
4314 (delete_program_space): Delete.
4315 * progspace.h (program_space::program_space): Make explicit. Move
4316 intro comment here, adjusted.
4317 (program_space::~program_space): Move intro comment here,
4318 adjusted.
4319 (delete_program_space): Remove.
4320
4321 2020-04-16 Tom Tromey <tromey@adacore.com>
4322
4323 * windows-nat.c (windows_nat::handle_access_violation): New
4324 function.
4325 * nat/windows-nat.h (handle_access_violation): Declare.
4326 * nat/windows-nat.c (handle_exception): Move Cygwin code to
4327 windows-nat.c. Call handle_access_violation.
4328
4329 2020-04-16 Tom de Vries <tdevries@suse.de>
4330
4331 PR symtab/25791
4332 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
4333 CUs without psymtab.
4334
4335 2020-04-16 Kevin Buettner <kevinb@redhat.com>
4336
4337 * python/python.c (do_start_initialization): Don't call
4338 PyEval_InitThreads for Python 3.9 and beyond.
4339
4340 2020-04-15 Kamil Rytarowski <n54@gmx.com>
4341
4342 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
4343 thread functions.
4344 (obsd_nat_target::wait): Likewise.
4345
4346 2020-04-15 Tom Tromey <tromey@adacore.com>
4347
4348 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
4349 (DEBUG_EXCEPT): Use debug_printf.
4350
4351 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
4352
4353 * completer.c (class completion_tracker::completion_hash_entry)
4354 <hash_name>: New member function.
4355 (completion_tracker::discard_completions): New callback to hash a
4356 completion_hash_entry, pass this to htab_create_alloc.
4357
4358 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
4359
4360 * windows-nat.c (windows_make_so): Warn rather than stopping with
4361 an error if realpath() fails.
4362
4363 2020-04-14 Kamil Rytarowski <n54@gmx.com>
4364
4365 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
4366 (nbsd_nat_target::info_proc): Add do_status.
4367
4368 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
4369 Tom de Vries <tdevries@suse.de>
4370
4371 PR symtab/25718
4372 * psympriv.h (struct partial_symtab::read_symtab)
4373 (struct partial_symtab::expand_psymtab)
4374 (struct partial_symtab::read_dependencies): Update comments.
4375 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
4376 read_symtab for includer.
4377 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
4378 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
4379 (struct dwarf2_include_psymtab::m_readin): Remove.
4380 (struct dwarf2_include_psymtab::includer): New member function.
4381 (dwarf2_psymtab::expand_psymtab): Assert !readin.
4382
4383 2020-04-14 Tom de Vries <tdevries@suse.de>
4384
4385 PR symtab/25720
4386 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
4387 with NULL symbol_matcher and lookup_name.
4388 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
4389 and lookup_name.
4390 * dwarf2/read.c (dw2_expand_symtabs_matching)
4391 (dw2_debug_names_expand_symtabs_matching): Same.
4392 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
4393 Make lookup_name a pointer. Update comment.
4394 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
4395 lookup_name being a pointer.
4396 * symfile.c (expand_symtabs_matching): Same.
4397 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
4398 * linespec.c (iterate_over_all_matching_symtabs): Same.
4399
4400 2020-04-13 Tom Tromey <tom@tromey.com>
4401
4402 * run-on-main-thread.c: Update include.
4403 * unittests/main-thread-selftests.c: Update include.
4404 * tui/tui-win.c: Update include.
4405 * tui/tui-io.c: Update include.
4406 * tui/tui-interp.c: Update include.
4407 * tui/tui-hooks.c: Update include.
4408 * top.h: Update include.
4409 * top.c: Update include.
4410 * ser-base.c: Update include.
4411 * remote.c: Update include.
4412 * remote-notif.c: Update include.
4413 * remote-fileio.c: Update include.
4414 * record-full.c: Update include.
4415 * record-btrace.c: Update include.
4416 * python/python.c: Update include.
4417 * posix-hdep.c: Update include.
4418 * mingw-hdep.c: Update include.
4419 * mi/mi-main.c: Update include.
4420 * mi/mi-interp.c: Update include.
4421 * main.c: Update include.
4422 * linux-nat.c: Update include.
4423 * interps.c: Update include.
4424 * infrun.c: Update include.
4425 * inf-loop.c: Update include.
4426 * event-top.c: Update include.
4427 * event-loop.c: Move to ../gdbsupport/.
4428 * event-loop.h: Move to ../gdbsupport/.
4429 * async-event.h: Update include.
4430 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
4431
4432 2020-04-13 Tom Tromey <tom@tromey.com>
4433
4434 * tui/tui-win.c: Include async-event.h.
4435 * remote.c: Include async-event.h.
4436 * remote-notif.c: Include async-event.h.
4437 * record-full.c: Include async-event.h.
4438 * record-btrace.c: Include async-event.h.
4439 * infrun.c: Include async-event.h.
4440 * event-top.c: Include async-event.h.
4441 * event-loop.h: Move some declarations to async-event.h.
4442 * event-loop.c: Don't include ser-event.h or top.h. Move some
4443 code to async-event.c.
4444 * async-event.h: New file.
4445 * async-event.c: New file.
4446 * Makefile.in (COMMON_SFILES): Add async-event.c.
4447 (HFILES_NO_SRCDIR): Add async-event.h.
4448
4449 2020-04-13 Tom Tromey <tom@tromey.com>
4450
4451 * utils.c (flush_streams): New function.
4452 * event-loop.c (gdb_wait_for_event): Call flush_streams.
4453
4454 2020-04-13 Tom Tromey <tom@tromey.com>
4455
4456 * event-loop.c (handle_file_event): Use warning, not
4457 printf_unfiltered.
4458
4459 2020-04-13 Tom Tromey <tom@tromey.com>
4460
4461 * event-loop.c: Include <chrono>.
4462
4463 2020-04-13 Tom Tromey <tom@tromey.com>
4464
4465 * gdb_select.h: Move to ../gdbsupport/.
4466 * event-loop.c: Update include path.
4467 * top.c: Update include path.
4468 * ser-base.c: Update include path.
4469 * ui-file.c: Update include path.
4470 * ser-tcp.c: Update include path.
4471 * guile/scm-ports.c: Update include path.
4472 * posix-hdep.c: Update include path.
4473 * ser-unix.c: Update include path.
4474 * gdb_usleep.c: Update include path.
4475 * mingw-hdep.c: Update include path.
4476 * inflow.c: Update include path.
4477 * infrun.c: Update include path.
4478 * event-top.c: Update include path.
4479
4480 2020-04-13 Tom Tromey <tom@tromey.com>
4481
4482 * configure: Rebuild.
4483 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
4484
4485 2020-04-13 Tom Tromey <tom@tromey.com>
4486
4487 * event-loop.h (start_event_loop): Don't declare.
4488 * event-loop.c (start_event_loop): Move...
4489 * main.c (start_event_loop): ...here. Now static.
4490
4491 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
4492
4493 * MAINTAINERS: Update my email address.
4494
4495 2020-04-12 Kamil Rytarowski <n54@gmx.com>
4496
4497 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
4498 IP_ALL.
4499
4500 2020-04-12 Kamil Rytarowski <n54@gmx.com>
4501
4502 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
4503 (nbsd_nat_target::info_proc): Add do_cmdline.
4504
4505 2020-04-12 Kamil Rytarowski <n54@gmx.com>
4506
4507 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
4508 (nbsd_nat_target::info_proc): Add do_cwd.
4509
4510 2020-04-12 Kamil Rytarowski <n54@gmx.com>
4511
4512 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
4513
4514 2020-04-11 Kamil Rytarowski <n54@gmx.com>
4515
4516 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
4517 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
4518 (nbsd_nat_target::info_proc): New functions.
4519 * nbsd-nat.c (kinfo_get_vmmap): New function.
4520 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
4521 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
4522 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
4523 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
4524 functions.
4525 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
4526 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
4527 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
4528 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
4529 (KINFO_VME_FLAG_GROWS_DOWN): New.
4530
4531 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
4532
4533 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
4534 bit shift.
4535
4536 2020-04-10 Tom Tromey <tromey@adacore.com>
4537
4538 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
4539
4540 2020-04-10 Tom Tromey <tromey@adacore.com>
4541
4542 * symtab.c (get_symbol_address, get_msymbol_address): Skip
4543 separate debug files.
4544
4545 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
4546
4547 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
4548 Move to...
4549 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
4550 ... here.
4551 * windows-nat.c (windows_nat_target::get_windows_debug_event):
4552 Check for STATUS_WX86_BREAKPOINT.
4553 (windows_nat_target::wait): Same.
4554
4555 2020-04-10 Tom de Vries <tdevries@suse.de>
4556
4557 PR cli/25808
4558 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
4559
4560 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4561
4562 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
4563 (Write After Approval): Remove Tom de Vries.
4564
4565 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
4566
4567 revert partially:
4568 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
4569
4570 * buildsym.c (record_line): Fix undefined behavior and preserve
4571 lines at eof.
4572
4573 2020-04-09 Kamil Rytarowski <n54@gmx.com>
4574
4575 * auxv.h (svr4_auxv_parse): New.
4576 * auxv.c (default_auxv_parse): Split into default_auxv_parse
4577 and generic_auxv_parse.
4578 (svr4_auxv_parse): Add.
4579 * obsd-tdep.c: Include "auxv.h".
4580 (obsd_auxv_parse): Remove.
4581 (obsd_init_abi): Remove comment.
4582 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
4583 from `obsd_auxv_parse' to `svr4_auxv_parse'.
4584 * nbsd-tdep.c: Include "auxv.h".
4585 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
4586
4587 2020-04-08 Tom Tromey <tromey@adacore.com>
4588
4589 * nat/windows-nat.h (last_wait_event): Don't declare.
4590 (wait_for_debug_event): Update comment.
4591 * nat/windows-nat.c (last_wait_event): Now static.
4592
4593 2020-04-08 Tom Tromey <tromey@adacore.com>
4594
4595 * windows-nat.c (wait_for_debug_event): Move to
4596 nat/windows-nat.c.
4597 * nat/windows-nat.h (wait_for_debug_event): Declare.
4598 * nat/windows-nat.c (wait_for_debug_event): Move from
4599 windows-nat.c. No longer static.
4600
4601 2020-04-08 Tom Tromey <tromey@adacore.com>
4602
4603 * windows-nat.c (get_windows_debug_event): Use
4604 fetch_pending_stop.
4605 * nat/windows-nat.h (fetch_pending_stop): Declare.
4606 * nat/windows-nat.c (fetch_pending_stop): New function.
4607
4608 2020-04-08 Tom Tromey <tromey@adacore.com>
4609
4610 * windows-nat.c (windows_continue): Use matching_pending_stop and
4611 continue_last_debug_event.
4612 * nat/windows-nat.h (matching_pending_stop)
4613 (continue_last_debug_event): Declare.
4614 * nat/windows-nat.c (DEBUG_EVENTS): New define.
4615 (matching_pending_stop, continue_last_debug_event): New
4616 functions.
4617
4618 2020-04-08 Tom Tromey <tromey@adacore.com>
4619
4620 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
4621 (handle_exception_result): Move to nat/windows-nat.h.
4622 (DEBUG_EXCEPTION_SIMPLE): Remove.
4623 (windows_nat::handle_ms_vc_exception): New function.
4624 (handle_exception): Move to nat/windows-nat.c.
4625 (get_windows_debug_event): Update.
4626 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
4627 nat/windows-nat.c.
4628 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
4629 (handle_exception_result): Move from windows-nat.c.
4630 (handle_exception): Declare.
4631 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
4632 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
4633 windows-nat.c.
4634
4635 2020-04-08 Tom Tromey <tromey@adacore.com>
4636
4637 * windows-nat.c (exception_count, event_count): Remove.
4638 (handle_exception, get_windows_debug_event)
4639 (do_initial_windows_stuff): Update.
4640
4641 2020-04-08 Tom Tromey <tromey@adacore.com>
4642
4643 * windows-nat.c (windows_nat::handle_load_dll)
4644 (windows_nat::handle_unload_dll): Rename. No longer static.
4645 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
4646 Declare.
4647
4648 2020-04-08 Tom Tromey <tromey@adacore.com>
4649
4650 * complaints.h (stop_whining): Declare at top-level.
4651 (complaint): Don't declare stop_whining.
4652
4653 2020-04-08 Tom Tromey <tromey@adacore.com>
4654
4655 * windows-nat.c (windows_nat::handle_output_debug_string):
4656 Rename. No longer static.
4657 * nat/windows-nat.h (handle_output_debug_string): Declare.
4658
4659 2020-04-08 Tom Tromey <tromey@adacore.com>
4660
4661 * windows-nat.c (current_process_handle, current_process_id)
4662 (main_thread_id, last_sig, current_event, last_wait_event)
4663 (current_windows_thread, desired_stop_thread_id, pending_stops)
4664 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
4665 (display_selectors, fake_create_process)
4666 (get_windows_debug_event): Update.
4667 * nat/windows-nat.h (current_process_handle, current_process_id)
4668 (main_thread_id, last_sig, current_event, last_wait_event)
4669 (current_windows_thread, desired_stop_thread_id, pending_stops)
4670 (struct pending_stop, siginfo_er): Move from windows-nat.c.
4671 * nat/windows-nat.c (current_process_handle, current_process_id)
4672 (main_thread_id, last_sig, current_event, last_wait_event)
4673 (current_windows_thread, desired_stop_thread_id, pending_stops)
4674 (siginfo_er): New globals. Move from windows-nat.c.
4675
4676 2020-04-08 Tom Tromey <tromey@adacore.com>
4677
4678 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
4679 (handle_load_dll): Update.
4680 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
4681
4682 2020-04-08 Tom Tromey <tromey@adacore.com>
4683
4684 * windows-nat.c (enum thread_disposition_type): Move to
4685 nat/windows-nat.h.
4686 (windows_nat::thread_rec): Rename from thread_rec. No longer
4687 static.
4688 (windows_add_thread, windows_nat_target::fetch_registers)
4689 (windows_nat_target::store_registers, handle_exception)
4690 (windows_nat_target::resume, get_windows_debug_event)
4691 (windows_nat_target::get_tib_address)
4692 (windows_nat_target::thread_name)
4693 (windows_nat_target::thread_alive): Update.
4694 * nat/windows-nat.h (enum thread_disposition_type): Move from
4695 windows-nat.c.
4696 (thread_rec): Declare.
4697
4698 2020-04-08 Tom Tromey <tromey@adacore.com>
4699
4700 * windows-nat.c: Add "using namespace".
4701 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
4702 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
4703
4704 2020-04-08 Tom Tromey <tromey@adacore.com>
4705
4706 * nat/windows-nat.h (struct windows_thread_info): Declare
4707 destructor.
4708 * nat/windows-nat.c (~windows_thread_info): New.
4709
4710 2020-04-08 Tom Tromey <tromey@adacore.com>
4711
4712 PR gdb/22992
4713 * windows-nat.c (current_event): Update comment.
4714 (last_wait_event, desired_stop_thread_id): New globals.
4715 (struct pending_stop): New.
4716 (pending_stops): New global.
4717 (windows_nat_target) <stopped_by_sw_breakpoint>
4718 <supports_stopped_by_sw_breakpoint>: New methods.
4719 (windows_fetch_one_register): Add assertions. Adjust PC.
4720 (windows_continue): Handle pending stops. Suspend other threads
4721 when stepping. Use last_wait_event
4722 (wait_for_debug_event): New function.
4723 (get_windows_debug_event): Use wait_for_debug_event. Handle
4724 pending stops. Queue spurious stops.
4725 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
4726 (windows_nat_target::kill): Use wait_for_debug_event.
4727 * nat/windows-nat.h (struct windows_thread_info)
4728 <stopped_at_software_breakpoint>: New field.
4729 * nat/windows-nat.c (windows_thread_info::resume): Clear
4730 stopped_at_software_breakpoint.
4731
4732 2020-04-08 Tom Tromey <tromey@adacore.com>
4733
4734 * windows-nat.c (enum thread_disposition_type): New.
4735 (thread_rec): Replace "get_context" parameter with "disposition";
4736 change type.
4737 (windows_add_thread, windows_nat_target::fetch_registers)
4738 (windows_nat_target::store_registers, handle_exception)
4739 (windows_nat_target::resume, get_windows_debug_event)
4740 (windows_nat_target::get_tib_address)
4741 (windows_nat_target::thread_name)
4742 (windows_nat_target::thread_alive): Update.
4743
4744 2020-04-08 Tom Tromey <tromey@adacore.com>
4745
4746 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
4747 (windows_continue): Use windows_continue::resume.
4748 * nat/windows-nat.h (struct windows_thread_info) <suspend,
4749 resume>: Declare new methods.
4750 * nat/windows-nat.c: New file.
4751 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
4752
4753 2020-04-08 Tom Tromey <tromey@adacore.com>
4754
4755 * windows-nat.c (windows_add_thread, windows_delete_thread)
4756 (windows_nat_target::fetch_registers)
4757 (windows_nat_target::store_registers, fake_create_process)
4758 (windows_nat_target::resume, windows_nat_target::resume)
4759 (get_windows_debug_event, windows_nat_target::wait)
4760 (windows_nat_target::pid_to_str)
4761 (windows_nat_target::get_tib_address)
4762 (windows_nat_target::get_ada_task_ptid)
4763 (windows_nat_target::thread_name)
4764 (windows_nat_target::thread_alive): Use lwp, not tid.
4765
4766 2020-04-08 Tom Tromey <tromey@adacore.com>
4767
4768 * windows-nat.c (handle_exception)
4769 (windows_nat_target::thread_name): Update.
4770 * nat/windows-nat.h (windows_thread_info): Remove destructor.
4771 <name>: Now unique_xmalloc_ptr.
4772
4773 2020-04-08 Tom Tromey <tromey@adacore.com>
4774
4775 * windows-nat.c (thread_rec)
4776 (windows_nat_target::fetch_registers): Update.
4777 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
4778 Update comment.
4779 <debug_registers_changed, reload_context>: Now bool.
4780
4781 2020-04-08 Tom Tromey <tromey@adacore.com>
4782
4783 * windows-nat.c (windows_add_thread): Use new.
4784 (windows_init_thread_list, windows_delete_thread): Use delete.
4785 (get_windows_debug_event): Update.
4786 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
4787 destructor, and initializers.
4788
4789 2020-04-08 Tom Tromey <tromey@adacore.com>
4790
4791 * windows-nat.c (struct windows_thread_info): Remove.
4792 * nat/windows-nat.h: New file.
4793
4794 2020-04-08 Tom Tromey <tromey@adacore.com>
4795
4796 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
4797 (thread_rec, windows_add_thread, windows_delete_thread)
4798 (windows_continue): Update.
4799
4800 2020-04-08 Tom Tromey <tromey@adacore.com>
4801
4802 * windows-nat.c (struct windows_thread_info): Remove typedef.
4803 (thread_head): Remove.
4804 (thread_list): New global.
4805 (thread_rec, windows_add_thread, windows_init_thread_list)
4806 (windows_delete_thread, windows_continue): Update.
4807
4808 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
4809
4810 * windows-tdep.h (windows_init_abi): Add comment.
4811 (cygwin_init_abi): New declaration.
4812 * windows-tdep.c: Split signal enumeration in two, one for
4813 Windows and one for Cygwin.
4814 (windows_gdb_signal_to_target): Only deal with signal of the
4815 Windows OS ABI.
4816 (cygwin_gdb_signal_to_target): New function.
4817 (windows_init_abi): Rename to windows_init_abi_common, don't set
4818 gdb_signal_to_target gdbarch method. Add new new function with
4819 this name.
4820 (cygwin_init_abi): New function.
4821 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
4822 comment. Don't call windows_init_abi.
4823 (amd64_windows_init_abi): Add comment, call windows_init_abi.
4824 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
4825 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
4826 i386_windows_init_abi_common, don't call windows_init_abi. Add
4827 a new function of this name.
4828 (i386_cygwin_init_abi): New function.
4829 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
4830 OS ABI Cygwin.
4831
4832 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
4833
4834 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
4835 parameter.c.
4836 (dwarf2_read_gdb_index): Update.
4837
4838 2020-04-07 Kamil Rytarowski <n54@gmx.com>
4839
4840 * nbsd-tdep.c: Include "objfiles.h".
4841 (nbsd_skip_solib_resolver): New.
4842 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
4843
4844 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
4845
4846 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
4847 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
4848 with DW_LLE_base_addressx are being emitted in DWARFv5.
4849 Add the newly added kind DW_LOC_OFFSET_PAIR also.
4850 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
4851 unsigned integer.
4852
4853 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
4854
4855 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
4856 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
4857 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
4858 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
4859 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
4860 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
4861 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
4862
4863
4864 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
4865
4866 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
4867 (read_loclist_index): New function definition.
4868 (lookup_loclist_base): New function definition.
4869 (read_loclist_header): New function definition.
4870 (dwarf2_cu): Add loclist_base and loclist_header field.
4871 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
4872 (read_full_die_1): Read the value of DW_AT_loclists_base.
4873 (read_attribute_reprocess): Handle DW_FORM_loclistx.
4874 (read_attribute_value): Handle DW_FORM_loclistx.
4875 (skip_one_die): Handle DW_FORM_loclistx.
4876 (loclist_header): New structure declaration.
4877 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
4878
4879 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4880
4881 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
4882 constructor. Remove `addr` parameter from other constructor and
4883 add `per_cu` parameter.
4884 * dwarf2/read.c (create_partial_symtab): Update.
4885
4886 2020-04-07 Tom de Vries <tdevries@suse.de>
4887
4888 PR symtab/25796
4889 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
4890 (partial_die_info::fixup): Inherit has_const_value.
4891
4892 2020-04-07 Tom de Vries <tdevries@suse.de>
4893
4894 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
4895 symbols without address.
4896
4897 2020-04-06 Kamil Rytarowski <n54@gmx.com>
4898
4899 * nbsd-nat.h (struct thread_info): Add forward declaration.
4900 (nbsd_nat_target::thread_alive): Add.
4901 (nbsd_nat_target::thread_name): Likewise.
4902 (nbsd_nat_target::update_thread_list): Likewise.
4903 (update_thread_list::post_attach): Likewise.
4904 (post_attach::pid_to_str): Likewise.
4905 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
4906 (nbsd_thread_lister): Add.
4907 (nbsd_nat_target::thread_alive): Likewise.
4908 (nbsd_nat_target::thread_name): Likewise.
4909 (nbsd_add_threads): Likewise.
4910 (update_thread_list::post_attach): Likewise.
4911 (nbsd_nat_target::update_thread_list): Likewise.
4912 (post_attach::pid_to_str): Likewise.
4913
4914 2020-04-06 Tom Tromey <tromey@adacore.com>
4915
4916 * ada-valprint.c (print_variant_part): Extract the variant field.
4917 (print_field_values): Use the field as the outer value when
4918 recursing.
4919
4920 2020-04-06 Tom Tromey <tromey@adacore.com>
4921
4922 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
4923 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
4924 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
4925 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
4926 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
4927
4928 2020-04-06 Tom Tromey <tromey@adacore.com>
4929
4930 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
4931 TYPE_CODE_ERROR.
4932
4933 2020-04-06 Kamil Rytarowski <n54@gmx.com>
4934
4935 * nbsd-tdep.c: Include "gdbarch.h".
4936 Define enum with NetBSD signal numbers.
4937 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
4938 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
4939 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
4940 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
4941 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
4942 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
4943 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
4944 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
4945 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
4946 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
4947 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
4948 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
4949
4950 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
4951
4952 PR gdb/25325
4953 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
4954
4955 2020-04-03 Tom Tromey <tromey@adacore.com>
4956
4957 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
4958 Read constant block.
4959
4960 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
4961
4962 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
4963 (gdb_bfd_get_full_section_contents): New declaration.
4964 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
4965 * windows-tdep.c (is_linked_with_cygwin_dll): Use
4966 gdb_bfd_get_full_section_contents.
4967
4968 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
4969
4970 * exec.c (build_section_table): Replace internal_error with
4971 gdb_assert.
4972 (section_table_xfer_memory_partial): Likewise.
4973 * mdebugread.c (parse_partial_symbols): Likewise.
4974 * psymtab.c (lookup_partial_symbol): Likewise.
4975 * utils.c (wrap_here): Likewise.
4976
4977 2020-04-02 Tom Tromey <tromey@adacore.com>
4978
4979 * f-lang.c (build_fortran_types): Use arch_type to initialize
4980 builtin_complex_s32 in the TYPE_CODE_ERROR case.
4981
4982 2020-04-02 Tom Tromey <tromey@adacore.com>
4983
4984 * dwarf2/read.c (partial_die_info::read): Do not create a vector
4985 of attributes.
4986
4987 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
4988 Bernd Edlinger <bernd.edlinger@hotmail.de>
4989 Tom Tromey <tromey@adacore.com>
4990
4991 * buildsym.c (buildsym_compunit::record_line): Remove
4992 deduplication code.
4993
4994 2020-04-02 Tom de Vries <tdevries@suse.de>
4995
4996 PR ada/24671
4997 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
4998
4999 2020-04-02 Tom de Vries <tdevries@suse.de>
5000
5001 * dwarf2/read.c (dwarf2_gdb_index_functions,
5002 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
5003 NULL.
5004 * psymtab.c (psym_lookup_global_symbol_language): New function.
5005 (psym_functions): Init psym_lookup_global_symbol_language with
5006 psym_lookup_global_symbol_language.
5007 * symfile-debug.c (debug_sym_quick_functions): Init
5008 lookup_global_symbol_language with NULL.
5009 * symfile.c (set_initial_language): Remove fixme comment.
5010 * symfile.h (struct quick_symbol_functions): Add
5011 lookup_global_symbol_language.
5012 * symtab.c (find_quick_global_symbol_language): New function.
5013 (find_main_name): Use find_quick_global_symbol_language.
5014
5015 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5016
5017 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
5018
5019 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5020
5021 * buildsym.c (record_line): Fix undefined behavior and preserve
5022 lines at eof.
5023
5024 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5025
5026 * buildsym.c (record_line): Fix the resizing condition.
5027
5028 2020-04-01 Tom Tromey <tom@tromey.com>
5029
5030 * value.h (value_literal_complex): Add comment.
5031 * valops.c (value_literal_complex): Refer to value.h.
5032
5033 2020-04-01 Tom Tromey <tom@tromey.com>
5034
5035 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
5036 (scalar_type): New rule, from typebase.
5037 (typebase): Use scalar_type. Recognize complex types.
5038 (field_name): Handle FLOAT_KEYWORD.
5039 (ident_tokens): Add _Complex and __complex__.
5040
5041 2020-04-01 Tom Tromey <tom@tromey.com>
5042
5043 PR exp/25299:
5044 * valarith.c (promotion_type, complex_binop): New functions.
5045 (scalar_binop): Handle complex numbers. Use promotion_type.
5046 (value_pos, value_neg, value_complement): Handle complex numbers.
5047
5048 2020-04-01 Tom Tromey <tom@tromey.com>
5049
5050 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
5051 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
5052 (parse_number): Handle complex numbers.
5053
5054 2020-04-01 Tom Tromey <tom@tromey.com>
5055
5056 * c-valprint.c (c_decorations): Change complex suffix to "i".
5057
5058 2020-04-01 Tom Tromey <tom@tromey.com>
5059
5060 * valprint.c (generic_value_print_complex): Use accessors.
5061 * value.h (value_real_part, value_imaginary_part): Declare.
5062 * valops.c (value_real_part, value_imaginary_part): New
5063 functions.
5064 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
5065
5066 2020-04-01 Tom Tromey <tom@tromey.com>
5067
5068 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
5069 (read_range_type): Update.
5070 * mdebugread.c (basic_type): Update.
5071 * go-lang.c (build_go_types): Use init_complex_type.
5072 * gdbtypes.h (struct main_type) <complex_type>: New member.
5073 (init_complex_type): Update.
5074 (arch_complex_type): Don't declare.
5075 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
5076 Make name if none given. Use alloc_type_copy. Look for cached
5077 complex type.
5078 (arch_complex_type): Remove.
5079 (gdbtypes_post_init): Use init_complex_type.
5080 * f-lang.c (build_fortran_types): Use init_complex_type.
5081 * dwarf2/read.c (read_base_type): Update.
5082 * d-lang.c (build_d_types): Use init_complex_type.
5083 * ctfread.c (read_base_type): Update.
5084
5085 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5086
5087 * infrun.c (stop_all_threads): Update assertion, plus when
5088 stopping threads, take into account that we might be trying
5089 to stop an all-stop target.
5090 (stop_waiting): Call 'stop_all_threads' if there exists a
5091 non-stop target.
5092
5093 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5094
5095 * target.h (exists_non_stop_target): New function declaration.
5096 * target.c (exists_non_stop_target): New function.
5097
5098 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
5099
5100 PR gdb/24789
5101 * eval.c (is_integral_or_integral_reference): New function.
5102 (evaluate_subexp_standard): Allow integer references in
5103 pointer arithmetic.
5104
5105 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5106
5107 * remote.c (remote_target::remote_parse_stop_reply): Remove the
5108 check for no ptid in the stop reply when the target is non-stop.
5109
5110 2020-04-01 Tom Tromey <tromey@adacore.com>
5111
5112 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
5113 "name" parameter to rvalue reference. Initialize m_name_holder.
5114 <lookup_name_info>: New overloads.
5115 <name>: Return gdb::string_view.
5116 <c_str>: New method.
5117 <make_ignore_params>: Update.
5118 <search_name_hash>: Update.
5119 <language_lookup_name>: Return const char *.
5120 <m_name>: Change type.
5121 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
5122 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
5123 (lookup_name_info::match_any): Update.
5124 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
5125 Update.
5126 * minsyms.c (linkage_name_str): Update.
5127 * language.c (default_symbol_name_matcher): Update.
5128 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
5129 Update.
5130 * ada-lang.c (ada_fold_name): Change parameter to string_view.
5131 (ada_lookup_name_info::ada_lookup_name_info): Update.
5132 (literal_symbol_name_matcher): Update.
5133
5134 2020-04-01 Tom Tromey <tromey@adacore.com>
5135
5136 * psymtab.c (psymtab_search_name): Remove function.
5137 (psym_lookup_symbol): Create search name and lookup name here.
5138 (lookup_partial_symbol): Remove "name" parameter; add
5139 lookup_name.
5140 (psym_expand_symtabs_for_function): Update.
5141
5142 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
5143
5144 PR tui/25597:
5145 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
5146
5147 2020-03-31 Tom Tromey <tromey@adacore.com>
5148
5149 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
5150 memcpy.
5151
5152 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
5153
5154 * features/riscv/32bit-csr.xml: Regenerated.
5155 * features/riscv/64bit-csr.xml: Regenerated.
5156
5157 2020-03-30 Tom Tromey <tromey@adacore.com>
5158
5159 * ada-valprint.c (print_variant_part): Update.
5160 * ada-lang.h (ada_which_variant_applies): Update.
5161 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
5162 outer_valaddr parameters; replace with "outer" value parameter.
5163 (to_fixed_variant_branch_type): Update.
5164
5165 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5166
5167 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
5168 <list>. Remove inclusion of observable.h.
5169 (PPC_DEBUG_CURRENT_VERSION): Move up define.
5170 (struct arch_lwp_info): New struct.
5171 (class ppc_linux_dreg_interface): New class.
5172 (struct ppc_linux_process_info): New struct.
5173 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
5174 <low_new_clone, low_forget_process, low_prepare_to_resume>
5175 <copy_thread_dreg_state, mark_thread_stale>
5176 <mark_debug_registers_changed, register_hw_breakpoint>
5177 <clear_hw_breakpoint, register_wp, clear_wp>
5178 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
5179 <num_memory_accesses, get_trigger_type>
5180 <create_watchpoint_request, hwdebug_point_cmp>
5181 <init_arch_lwp_info, get_arch_lwp_info>
5182 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
5183 methods.
5184 <struct ptid_hash>: New inner struct.
5185 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
5186 members.
5187 (saved_dabr_value, hwdebug_info, max_slots_number)
5188 (struct hw_break_tuple, struct thread_points, ppc_threads)
5189 (have_ptrace_hwdebug_interface)
5190 (hwdebug_find_thread_points_by_tid)
5191 (hwdebug_insert_point, hwdebug_remove_point): Remove.
5192 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
5193 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
5194 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
5195 use m_dreg_interface.
5196 (hwdebug_point_cmp): Change to...
5197 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
5198 reference arguments instead of pointers.
5199 (ppc_linux_nat_target::ranged_break_num_registers): Use
5200 m_dreg_interface.
5201 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
5202 m_dreg_interface. Call register_hw_breakpoint.
5203 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
5204 m_dreg_interface. Call clear_hw_breakpoint.
5205 (get_trigger_type): Change to...
5206 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
5207 comment.
5208 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
5209 use m_dreg_interface. Call register_hw_breakpoint.
5210 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
5211 use m_dreg_interface. Call clear_hw_breakpoint.
5212 (can_use_watchpoint_cond_accel): Change to...
5213 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
5214 method. Update comment, use m_dreg_interface and
5215 m_process_info.
5216 (calculate_dvc): Change to...
5217 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
5218 m_dreg_interface.
5219 (num_memory_accesses): Change to...
5220 (ppc_linux_nat_target::num_memory_accesses): ...this method.
5221 (check_condition): Change to...
5222 (ppc_linux_nat_target::check_condition): ...this method.
5223 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
5224 comment, use m_dreg_interface.
5225 (create_watchpoint_request): Change to...
5226 (ppc_linux_nat_target::create_watchpoint_request): ...this
5227 method. Use m_dreg_interface.
5228 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
5229 m_dreg_interface. Call register_hw_breakpoint or register_wp.
5230 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
5231 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
5232 (ppc_linux_nat_target::low_forget_process)
5233 (ppc_linux_nat_target::low_new_fork)
5234 (ppc_linux_nat_target::low_new_clone)
5235 (ppc_linux_nat_target::low_delete_thread)
5236 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
5237 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
5238 only call mark_thread_stale.
5239 (ppc_linux_thread_exit): Remove.
5240 (ppc_linux_nat_target::stopped_data_address): Change to...
5241 (ppc_linux_nat_target::low_stopped_data_address): This. Add
5242 comment, use m_dreg_interface and m_thread_hw_breakpoints.
5243 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
5244 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
5245 comment. Call low_stopped_data_address.
5246 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
5247 m_dreg_interface.
5248 (ppc_linux_nat_target::masked_watch_num_registers): Use
5249 m_dreg_interface.
5250 (ppc_linux_nat_target::copy_thread_dreg_state)
5251 (ppc_linux_nat_target::mark_thread_stale)
5252 (ppc_linux_nat_target::mark_debug_registers_changed)
5253 (ppc_linux_nat_target::register_hw_breakpoint)
5254 (ppc_linux_nat_target::clear_hw_breakpoint)
5255 (ppc_linux_nat_target::register_wp)
5256 (ppc_linux_nat_target::clear_wp)
5257 (ppc_linux_nat_target::init_arch_lwp_info)
5258 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
5259 (_initialize_ppc_linux_nat): Remove observer callback.
5260
5261 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5262
5263 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
5264 (ppc_linux_nat_target::auxv_parse)
5265 (ppc_linux_nat_target::read_description)
5266 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
5267 Move up.
5268
5269 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
5270
5271 * linux-nat.h (low_new_clone): New method.
5272 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
5273
5274 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
5275
5276 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
5277 (dbx_expand_psymtab): ... this.
5278 (start_psymtab): Update.
5279 * mdebugread.c (psymtab_to_symtab_1): Rename to...
5280 (mdebug_expand_psymtab): ... this.
5281 (parse_partial_symbols): Update.
5282 (new_psymtab): Update.
5283 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
5284 (xcoff_expand_psymtab): ... this.
5285 (xcoff_start_psymtab): Update.
5286
5287 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
5288
5289 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
5290 <expand_dependencies>: ... this.
5291 * psymtab.c (partial_symtab::read_dependencies): Rename to...
5292 (partial_symtab::expand_dependencies): ... this.
5293 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
5294 Update.
5295 (dwarf2_psymtab::expand_psymtab): Update.
5296 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
5297 * mdebugread.c (psymtab_to_symtab_1): Update.
5298 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
5299
5300 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
5301
5302 * psympriv.h (discard_psymtab): Remove.
5303 * dbxread.c (dbx_end_psymtab): Update.
5304 * xcoffread.c (xcoff_end_psymtab): Update.
5305
5306 2020-03-28 Tom Tromey <tom@tromey.com>
5307
5308 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
5309 comment.
5310
5311 2020-03-28 Tom Tromey <tom@tromey.com>
5312
5313 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
5314
5315 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
5316
5317 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
5318
5319 2020-03-26 John Baldwin <jhb@FreeBSD.org>
5320
5321 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
5322
5323 2020-03-26 Tom Tromey <tom@tromey.com>
5324
5325 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
5326 (mark_common_block_symbol_computed, read_tag_string_type)
5327 (attr_to_dynamic_prop, read_subrange_type): Update.
5328 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
5329 to be methods on struct attribute.
5330 (skip_one_die, process_imported_unit_die, read_namespace_alias)
5331 (read_call_site_scope, partial_die_info::read)
5332 (partial_die_info::read, lookup_die_type, follow_die_ref):
5333 Update.
5334 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
5335 from dwarf2_get_ref_die_offset.
5336 (attribute::constant_value): New method, from
5337 dwarf2_get_attr_constant_value.
5338 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
5339 Declare method.
5340 <constant_value>: New method.
5341
5342 2020-03-26 Tom Tromey <tom@tromey.com>
5343
5344 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
5345 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
5346 (dwarf_type_encoding_name): Move to stringify.c.
5347 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
5348 * dwarf2/stringify.c: New file.
5349 * dwarf2/stringify.h: New file.
5350
5351 2020-03-26 Tom Tromey <tom@tromey.com>
5352
5353 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
5354 Rewrite.
5355
5356 2020-03-26 Tom Tromey <tom@tromey.com>
5357
5358 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
5359 methods.
5360 * dwarf2/read.c (lookup_addr_base): Move to die.h.
5361 (lookup_ranges_base): Likewise.
5362 (read_cutu_die_from_dwo, read_full_die_1): Update.
5363
5364 2020-03-26 Tom Tromey <tom@tromey.com>
5365
5366 * dwarf2/read.c (read_import_statement, read_file_scope)
5367 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
5368 (read_lexical_block_scope, read_call_site_scope)
5369 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
5370 (handle_struct_member_die, process_structure_scope)
5371 (update_enumeration_type_from_children)
5372 (process_enumeration_scope, read_array_type, read_common_block)
5373 (read_namespace, read_module, read_subroutine_type): Update.
5374 (sibling_die): Remove.
5375
5376 2020-03-26 Tom Tromey <tom@tromey.com>
5377
5378 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
5379 (build_type_psymtabs_reader, read_structure_type)
5380 (read_enumeration_type, read_full_die_1): Update.
5381 (dwarf2_attr_no_follow): Move to die.h.
5382 * dwarf2/die.h (struct die_info) <attr>: New method.
5383
5384 2020-03-26 Tom Tromey <tom@tromey.com>
5385
5386 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
5387 <base_address>: Now an optional.
5388 (dwarf2_find_base_address, dwarf2_rnglists_process)
5389 (dwarf2_ranges_process, fill_in_loclist_baton)
5390 (dwarf2_symbol_mark_computed): Update.
5391
5392 2020-03-26 Tom Tromey <tom@tromey.com>
5393
5394 * dwarf2/read.c (struct die_info): Move to die.h.
5395 * dwarf2/die.h: New file.
5396
5397 2020-03-26 Tom Tromey <tom@tromey.com>
5398
5399 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
5400 * dwarf2/read.c
5401 (dwarf2_statement_list_fits_in_line_number_section_complaint):
5402 Move to line-header.c.
5403 (read_checked_initial_length_and_offset, read_formatted_entries):
5404 Likewise.
5405 (dwarf_decode_line_header): Split into two.
5406 * dwarf2/line-header.c
5407 (dwarf2_statement_list_fits_in_line_number_section_complaint):
5408 Move from read.c.
5409 (read_checked_initial_length_and_offset, read_formatted_entries):
5410 Likewise.
5411 (dwarf_decode_line_header): New function, split from read.c.
5412
5413 2020-03-26 Tom Tromey <tom@tromey.com>
5414
5415 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
5416 Declare method.
5417 * dwarf2/read.c (read_attribute_value): Update.
5418 (dwarf2_per_objfile::read_line_string): Rename from
5419 read_indirect_line_string.
5420 (read_formatted_entries): Update.
5421
5422 2020-03-26 Tom Tromey <tom@tromey.com>
5423
5424 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
5425 variable.
5426
5427 2020-03-26 Tom Tromey <tom@tromey.com>
5428
5429 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
5430 const.
5431 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
5432 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
5433 parameter const.
5434
5435 2020-03-26 Tom Tromey <tom@tromey.com>
5436
5437 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
5438 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
5439 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
5440 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
5441
5442 2020-03-26 Tom Tromey <tom@tromey.com>
5443
5444 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
5445 file_names_size, file_full_name, file_file_name>: Use const.
5446 <file_name_at, file_names>: Add const overload.
5447 * dwarf2/line-header.c (line_header::file_file_name)
5448 (line_header::file_full_name): Update.
5449
5450 2020-03-26 Tom Tromey <tom@tromey.com>
5451
5452 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
5453 (macro_start_file, consume_improper_spaces)
5454 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
5455 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
5456 (dwarf_decode_macros): Move to macro.c.
5457 * dwarf2/macro.c: New file.
5458 * dwarf2/macro.h: New file.
5459 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
5460
5461 2020-03-26 Tom Tromey <tom@tromey.com>
5462
5463 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
5464 method.
5465 * dwarf2/section.c: New method. From
5466 read_indirect_string_at_offset_from.
5467 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
5468 (read_indirect_string_at_offset_from): Move to section.c.
5469 (read_indirect_string_at_offset): Rewrite.
5470 (read_indirect_line_string_at_offset): Remove.
5471 (read_indirect_string, read_indirect_line_string)
5472 (dwarf_decode_macro_bytes): Update.
5473
5474 2020-03-26 Tom Tromey <tom@tromey.com>
5475
5476 * dwarf2/section.h (struct dwarf2_section_info)
5477 <overload_complaint>: Declare.
5478 (dwarf2_section_buffer_overflow_complaint): Don't declare.
5479 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
5480 Rename from dwarf2_section_buffer_overflow_complaint.
5481 * dwarf2/read.c (skip_one_die, partial_die_info::read)
5482 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
5483
5484 2020-03-26 Tom Tromey <tom@tromey.com>
5485
5486 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
5487 Declare.
5488 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
5489 Move from read.c.
5490 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
5491 to section.c.
5492
5493 2020-03-26 Tom Tromey <tom@tromey.com>
5494
5495 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
5496
5497 2020-03-26 Tom Tromey <tom@tromey.com>
5498
5499 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
5500 "builder".
5501 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
5502 parameter.
5503 (dwarf_decode_macros): Update.
5504
5505 2020-03-26 Tom Tromey <tom@tromey.com>
5506
5507 * dwarf2/read.c (read_attribute_value): Update.
5508 (read_indirect_string_from_dwz): Move to dwz.c; change into
5509 method.
5510 (dwarf_decode_macro_bytes): Update.
5511 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
5512 * dwarf2/dwz.c: New file.
5513 * Makefile.in (COMMON_SFILES): Add dwz.c.
5514
5515 2020-03-26 Tom Tromey <tom@tromey.com>
5516
5517 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
5518 * dwarf2/read.c: Add include.
5519 * dwarf2/index-write.c: Add include.
5520 * dwarf2/index-cache.c: Add include.
5521 * dwarf2/dwz.h: New file.
5522
5523 2020-03-25 Tom Tromey <tom@tromey.com>
5524
5525 * compile/compile-object-load.c (get_out_value_type): Mention
5526 correct symbol name in error message.
5527
5528 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
5529
5530 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
5531
5532 2020-03-25 Tom de Vries <tdevries@suse.de>
5533
5534 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
5535 * symmisc.c (dump_symtab_1): Print user and includes fields.
5536 (maintenance_info_symtabs): Same.
5537
5538 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
5539
5540 PR gdb/25534
5541 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
5542 (riscv_regcache_cooked_write): New function.
5543 (riscv_push_dummy_call): Use new function.
5544 (riscv_return_value): Likewise.
5545
5546 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
5547
5548 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
5549 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
5550 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
5551 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
5552 * infrun.c (follow_fork): Likewise.
5553 (follow_fork_inferior): Likewise.
5554 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
5555 * linux-nat.h (class linux_nat_target): Likewise.
5556 * remote.c (class remote_target) <follow_fork>: Likewise.
5557 (remote_target::follow_fork): Likewise.
5558 * target-delegates.c: Re-generate.
5559 * target.c (default_follow_fork): Likewise.
5560 (target_follow_fork): Likewise.
5561 * target.h (struct target_ops) <follow_fork>: Likewise.
5562 (target_follow_fork): Likewise.
5563
5564 2020-03-24 Tom de Vries <tdevries@suse.de>
5565
5566 * psymtab.c (maintenance_info_psymtabs): Print user field.
5567
5568 2020-03-20 Tom Tromey <tromey@adacore.com>
5569
5570 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
5571 const.
5572 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
5573 const.
5574
5575 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
5576
5577 * ptrace.m4: Don't check for ptrace declaration.
5578 * config.in: Re-generate.
5579 * configure: Re-generate.
5580 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
5581 not defined.
5582
5583 2020-03-20 Kamil Rytarowski <n54@gmx.com>
5584
5585 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
5586 `PTRACE_TYPE_RET'.
5587 * i386-bsd-nat.c (gdb_ptrace): Likewise.
5588 * sparc-nat.c (gdb_ptrace): Likewise.
5589 * x86-bsd-nat.c (gdb_ptrace): Likewise.
5590
5591 2020-03-20 Tom Tromey <tromey@adacore.com>
5592
5593 * c-exp.y (lex_one_token): Fix assert.
5594
5595 2020-03-20 Tom Tromey <tromey@adacore.com>
5596
5597 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
5598 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
5599 strncpy call.
5600
5601 2020-03-20 Tom Tromey <tromey@adacore.com>
5602
5603 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
5604
5605 2020-03-20 Tom Tromey <tromey@adacore.com>
5606
5607 * ada-valprint.c (print_variant_part): Remove parameters; switch
5608 to value-based API.
5609 (print_field_values): Likewise.
5610 (ada_val_print_struct_union): Likewise.
5611 (ada_value_print_1): Update.
5612
5613 2020-03-20 Kamil Rytarowski <n54@gmx.com>
5614
5615 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
5616 nbsd_nat_target instead of inf_ptrace_target.
5617 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
5618 nbsd_nat_target.
5619
5620 2020-03-20 Kamil Rytarowski <n54@gmx.com>
5621
5622 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
5623 it to the ptrace call.
5624 * (store_registers): Likewise.
5625
5626 2020-03-20 Kamil Rytarowski <n54@gmx.com>
5627
5628 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
5629 it to the ptrace call.
5630 * (store_registers): Likewise.
5631
5632 2020-03-19 Luis Machado <luis.machado@linaro.org>
5633
5634 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
5635 valid, fetch vg value from ptrace.
5636
5637 2020-03-19 Kamil Rytarowski <n54@gmx.com>
5638 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
5639 * inf-ptrace.c: Likewise.
5640 * (gdb_ptrace): Add.
5641 * (inf_ptrace_target::resume): Update.
5642 * (inf_ptrace_target::xfer_partial): Likewise.
5643 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
5644 * (inf_ptrace_peek_poke): Update.
5645
5646 2020-03-19 Kamil Rytarowski <n54@gmx.com>
5647
5648 * x86-bsd-nat.c (gdb_ptrace): New.
5649 * (x86bsd_dr_set): Add new argument `ptid'.
5650 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
5651 x86bsd_dr_set_addr): Update.
5652
5653 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
5654
5655 * remote.c (remote_target::process_stop_reply): Handle events for
5656 all threads differently.
5657
5658 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
5659
5660 * completer.c (completion_tracker::remove_completion): Define new
5661 function.
5662 * completer.h (completion_tracker::remove_completion): Declare new
5663 function.
5664 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
5665 when adding a C++ function symbol.
5666
5667 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
5668
5669 * completer.c (completion_tracker::completion_hash_entry): Define
5670 new class.
5671 (advance_to_filename_complete_word_point): Call
5672 recompute_lowest_common_denominator.
5673 (completion_tracker::completion_tracker): Call discard_completions
5674 to setup the hash table.
5675 (completion_tracker::discard_completions): Allow for being called
5676 from the constructor, pass new equal function, and element deleter
5677 when constructing the hash table. Initialise new class member
5678 variables.
5679 (completion_tracker::maybe_add_completion): Remove use of
5680 m_entries_vec, and store more information into m_entries_hash.
5681 (completion_tracker::recompute_lcd_visitor): New function, most
5682 content taken from...
5683 (completion_tracker::recompute_lowest_common_denominator):
5684 ...here, this now just visits each item in the hash calling the
5685 above visitor.
5686 (completion_tracker::build_completion_result): Remove use of
5687 m_entries_vec, call recompute_lowest_common_denominator.
5688 * completer.h (completion_tracker::have_completions): Remove use
5689 of m_entries_vec.
5690 (completion_tracker::completion_hash_entry): Declare new class.
5691 (completion_tracker::recompute_lowest_common_denominator): Change
5692 function signature.
5693 (completion_tracker::recompute_lcd_visitor): Declare new function.
5694 (completion_tracker::m_entries_vec): Delete.
5695 (completion_tracker::m_entries_hash): Initialize to NULL.
5696 (completion_tracker::m_lowest_common_denominator_valid): New
5697 member variable.
5698 (completion_tracker::m_lowest_common_denominator_max_length): New
5699 member variable.
5700
5701 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5702
5703 * regformats/regdef.h: Put reg in gdb namespace.
5704
5705 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5706
5707 * i386-bsd-nat.c (gdb_ptrace): New.
5708 * (i386bsd_fetch_inferior_registers,
5709 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
5710 * (i386bsd_fetch_inferior_registers,
5711 i386bsd_store_inferior_registers) Use gdb_ptrace.
5712
5713 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5714
5715 * amd64-bsd-nat.c (gdb_ptrace): New.
5716 * (amd64bsd_fetch_inferior_registers,
5717 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
5718 * (amd64bsd_fetch_inferior_registers,
5719 amd64bsd_store_inferior_registers) Use gdb_ptrace.
5720
5721 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5722
5723 * user-regs.c (user_reg::read): Rename to...
5724 (user_reg::xread): ...this.
5725 * (append_user_reg): Rename argument `read' to `xread'.
5726 * (user_reg_add_builtin): Likewise.
5727 * (user_reg_add): Likewise.
5728 * (value_of_user_reg): Likewise.
5729
5730 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5731
5732 * sparc-nat.c (gdb_ptrace): New.
5733 * sparc-nat.c (sparc_fetch_inferior_registers)
5734 (sparc_store_inferior_registers) Remove obsolete comment.
5735 * sparc-nat.c (sparc_fetch_inferior_registers)
5736 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
5737 * sparc-nat.c (sparc_fetch_inferior_registers)
5738 (sparc_store_inferior_registers) Use gdb_ptrace.
5739
5740 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5741
5742 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
5743 it to the ptrace call.
5744 * sh-nbsd-nat.c (store_registers): Likewise.
5745
5746 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5747
5748 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
5749 nbsd_nat_target instead of inf_ptrace_target.
5750 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
5751 nbsd_nat_target.
5752
5753 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5754
5755 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
5756
5757 2020-03-17 Kamil Rytarowski <n54@gmx.com>
5758
5759 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
5760 <sys/sysctl.h>.
5761 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
5762
5763 2020-03-17 Tom de Vries <tdevries@suse.de>
5764
5765 PR gdb/23710
5766 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
5767 fields.
5768 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
5769 fields.
5770 (process_imported_unit_die): Skip import of c++ CUs.
5771
5772 2020-03-16 Tom Tromey <tom@tromey.com>
5773
5774 * p-valprint.c (pascal_object_print_value): Initialize
5775 base_value.
5776
5777 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
5778 Shahab Vahedi <shahab@synopsys.com>
5779
5780 * Makefile.in: Add arch/arc.o
5781 * configure.tgt: Likewise.
5782 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
5783 (_initialize_arc_tdep): Don't initialize old target descriptions.
5784 (arc_read_description): New function to cache target descriptions.
5785 * arc-tdep.h (arc_read_description): Add proto type.
5786 * arch/arc.c: New file.
5787 * arch/arc.h: Likewise.
5788 * features/Makefile: Replace old target descriptions with new.
5789 * features/arc-arcompact.c: Remove.
5790 * features/arc-arcompact.xml: Likewise.
5791 * features/arc-v2.c: Likewise
5792 * features/arc-v2.xml: Likewise
5793 * features/arc/aux-arcompact.xml: New file.
5794 * features/arc/aux-v2.xml: Likewise.
5795 * features/arc/core-arcompact.xml: Likewise.
5796 * features/arc/core-v2.xml: Likewise.
5797 * features/arc/aux-arcompact.c: Generate.
5798 * features/arc/aux-v2.c: Likewise.
5799 * features/arc/core-arcompact.c: Likewise.
5800 * features/arc/core-v2.c: Likewise.
5801 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
5802
5803 2020-03-16 Tom Tromey <tromey@adacore.com>
5804
5805 PR gdb/25663:
5806 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
5807 putting value into bcache.
5808
5809 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5810
5811 PR gdb/21500
5812 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
5813 to...
5814 (amd64_windows_init_abi_common): ... this. Don't set size of
5815 long type.
5816 (amd64_windows_init_abi): New function.
5817 (amd64_cygwin_init_abi): New function.
5818 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
5819 the Cygwin OS ABI.
5820 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
5821 comment.
5822
5823 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5824
5825 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
5826 * windows-tdep.c (CYGWIN_DLL_NAME): New.
5827 (pe_import_directory_entry): New struct type.
5828 (is_linked_with_cygwin_dll): New function.
5829 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
5830 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
5831 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
5832
5833 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5834
5835 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
5836 i386_cygwin_core_osabi_sniffer.
5837
5838 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5839
5840 * i386-cygwin-tdep.c: Rename to...
5841 * i386-windows-tdep.c: ... this.
5842 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
5843 i386-windows-tdep.c.
5844 * configure.tgt: Likewise.
5845
5846 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5847
5848 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
5849 * osabi.c (gdb_osabi_names): Add "Windows".
5850 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
5851 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
5852 (i386_cygwin_core_osabi_sniffer): New function, extracted from
5853 i386_cygwin_osabi_sniffer.
5854 (_initialize_i386_cygwin_tdep): Register OS ABI
5855 GDB_OSABI_WINDOWS for i386.
5856 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
5857 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
5858 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
5859 for x86-64.
5860 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
5861 when the target matches '*-*-mingw*'.
5862
5863 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5864
5865 * defs.h (enum gdb_osabi): Move to...
5866 * osabi.h (enum gdb_osabi): ... here.
5867 * gdbarch.sh: Include osabi.h in gdbarch.h.
5868 * gdbarch.h: Re-generate.
5869
5870 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
5871
5872 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
5873 function.
5874 (_initialize_amd64_windows_tdep): Register osabi sniffer.
5875
5876 2020-03-14 Tom Tromey <tom@tromey.com>
5877
5878 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
5879 for C++.
5880 (c_type_print_modifier): Likewise. Add "language" parameter.
5881 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
5882 (c_type_print_base_1): Update.
5883 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
5884 constants.
5885 * type-stack.c (type_stack::insert): Handle tp_atomic and
5886 tp_restrict.
5887 (type_stack::follow_type_instance_flags): Likewise.
5888 (type_stack::follow_types): Likewise. Merge type-following code.
5889 * c-exp.y (RESTRICT, ATOMIC): New tokens.
5890 (space_identifier, cv_with_space_id)
5891 (const_or_volatile_or_space_identifier_noopt)
5892 (const_or_volatile_or_space_identifier): Remove.
5893 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
5894 rules.
5895 (ptr_operator, typebase): Update.
5896 (enum token_flag) <FLAG_C>: New constant.
5897 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
5898 "_Atomic".
5899 (lex_one_token): Handle FLAG_C.
5900
5901 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5902
5903 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
5904 it to the ptrace call.
5905 * m68k-bsd-nat.c (store_registers): Likewise.
5906
5907 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5908
5909 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
5910 gdb_byte *.
5911 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
5912 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
5913 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
5914
5915 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5916
5917 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
5918 nbsd_nat_target instead of inf_ptrace_target.
5919 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
5920 nbsd_nat_target.
5921
5922 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5923
5924 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
5925 register_t.
5926
5927 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5928
5929 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
5930 it to the ptrace call.
5931 * alpha-bsd-nat.c (store_registers): Likewise.
5932
5933 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5934
5935 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
5936 includes.
5937 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
5938 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
5939 fill_fpregset): Likewise.
5940
5941 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5942
5943 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
5944 nbsd_nat_target instead of inf_ptrace_target.
5945 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
5946 nbsd_nat_target.
5947
5948 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5949
5950 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
5951 register_t.
5952
5953 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5954
5955 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
5956 it to the ptrace call.
5957 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
5958 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
5959 * arm-nbsd-nat.c (store_register): Likewise.
5960 * arm-nbsd-nat.c (store_regs): Likewise.
5961 * arm-nbsd-nat.c (store_fp_register): Likewise.
5962 * arm-nbsd-nat.c (store_fp_regs): Likewise.
5963
5964 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5965
5966 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
5967 nbsd_nat_target instead of inf_ptrace_target.
5968 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
5969 nbsd_nat_target.
5970
5971 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5972
5973 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
5974 it to the ptrace call.
5975 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
5976
5977 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5978
5979 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
5980 it to the ptrace call.
5981 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
5982
5983 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5984
5985 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
5986 gdb_byte *.
5987 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
5988
5989 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5990
5991 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
5992 instead of inf_ptrace_target.
5993 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
5994 nbsd_nat_target.
5995
5996 2020-03-14 Kamil Rytarowski <n54@gmx.com>
5997
5998 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
5999 register_t.
6000
6001 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6002
6003 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6004 register_t.
6005
6006 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6007
6008 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
6009 register_t.
6010
6011 2020-03-13 Tom Tromey <tom@tromey.com>
6012
6013 * value.h (val_print): Don't declare.
6014 * valprint.h (val_print_array_elements)
6015 (val_print_scalar_formatted, generic_val_print): Don't declare.
6016 * valprint.c (generic_val_print_array): Take a struct value.
6017 (generic_val_print_ptr, generic_val_print_memberptr)
6018 (generic_val_print_bool, generic_val_print_int)
6019 (generic_val_print_char, generic_val_print_complex)
6020 (generic_val_print): Remove.
6021 (generic_value_print): Update.
6022 (do_val_print): Remove unused parameters. Don't call
6023 la_val_print.
6024 (val_print): Remove.
6025 (common_val_print): Update. Don't call value_check_printable.
6026 (val_print_scalar_formatted, val_print_array_elements): Remove.
6027 * rust-lang.c (rust_val_print): Remove.
6028 (rust_language_defn): Update.
6029 * p-valprint.c (pascal_val_print): Remove.
6030 (pascal_value_print_inner): Update.
6031 (pascal_object_print_val_fields, pascal_object_print_val):
6032 Remove.
6033 (pascal_object_print_static_field): Update.
6034 * p-lang.h (pascal_val_print): Don't declare.
6035 * p-lang.c (pascal_language_defn): Update.
6036 * opencl-lang.c (opencl_language_defn): Update.
6037 * objc-lang.c (objc_language_defn): Update.
6038 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
6039 * m2-lang.h (m2_val_print): Don't declare.
6040 * m2-lang.c (m2_language_defn): Update.
6041 * language.h (struct language_defn) <la_val_print>: Remove.
6042 * language.c (unk_lang_value_print_inner): Rename. Change
6043 argument types.
6044 (unknown_language_defn, auto_language_defn): Update.
6045 * go-valprint.c (go_val_print): Remove.
6046 * go-lang.h (go_val_print): Don't declare.
6047 * go-lang.c (go_language_defn): Update.
6048 * f-valprint.c (f_val_print): Remove.
6049 * f-lang.h (f_value_print): Don't declare.
6050 * f-lang.c (f_language_defn): Update.
6051 * d-valprint.c (d_val_print): Remove.
6052 * d-lang.h (d_value_print): Don't declare.
6053 * d-lang.c (d_language_defn): Update.
6054 * cp-valprint.c (cp_print_value_fields)
6055 (cp_print_value_fields_rtti, cp_print_value): Remove.
6056 (cp_print_static_field): Update.
6057 * c-valprint.c (c_val_print_array, c_val_print_ptr)
6058 (c_val_print_struct, c_val_print_union, c_val_print_int)
6059 (c_val_print_memberptr, c_val_print): Remove.
6060 * c-lang.h (c_val_print_array, cp_print_value_fields)
6061 (cp_print_value_fields_rtti): Don't declare.
6062 * c-lang.c (c_language_defn, cplus_language_defn)
6063 (asm_language_defn, minimal_language_defn): Update.
6064 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
6065 (ada_val_print_enum): Take a struct value.
6066 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
6067 (ada_val_print): Remove.
6068 (ada_value_print_1): Update.
6069 (printable_val_type): Remove.
6070 * ada-lang.h (ada_val_print): Don't declare.
6071 * ada-lang.c (ada_language_defn): Update.
6072
6073 2020-03-13 Tom Tromey <tom@tromey.com>
6074
6075 * valprint.c (do_val_print): Update.
6076 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
6077 a struct value.
6078 (value_to_value_object_no_release): Declare.
6079 * python/py-value.c (value_to_value_object_no_release): New
6080 function.
6081 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
6082 struct value.
6083 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
6084 function.
6085 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
6086 a struct value.
6087 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
6088 Declare.
6089 (gdbscm_apply_val_pretty_printer): Take a struct value.
6090 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
6091 value.
6092 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
6093 value.
6094 * extension-priv.h (struct extension_language_ops)
6095 <apply_val_pretty_printer>: Take a struct value.
6096 * cp-valprint.c (cp_print_value): Create a struct value.
6097 (cp_print_value): Update.
6098
6099 2020-03-13 Tom Tromey <tom@tromey.com>
6100
6101 * ada-valprint.c (print_field_values): Call common_val_print.
6102
6103 2020-03-13 Tom Tromey <tom@tromey.com>
6104
6105 * ada-valprint.c (val_print_packed_array_elements): Remove
6106 bitoffset and val parameters. Call common_val_print.
6107 (ada_val_print_string): Remove offset, address, and original_value
6108 parameters.
6109 (ada_val_print_array): Update.
6110 (ada_value_print_array): New function.
6111 (ada_value_print_1): Call it.
6112
6113 2020-03-13 Tom Tromey <tom@tromey.com>
6114
6115 * ada-valprint.c (ada_value_print): Use common_val_print.
6116
6117 2020-03-13 Tom Tromey <tom@tromey.com>
6118
6119 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
6120
6121 2020-03-13 Tom Tromey <tom@tromey.com>
6122
6123 * ada-valprint.c (ada_value_print_num): New function.
6124 (ada_value_print_1): Use it.
6125
6126 2020-03-13 Tom Tromey <tom@tromey.com>
6127
6128 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
6129
6130 2020-03-13 Tom Tromey <tom@tromey.com>
6131
6132 * ada-valprint.c (ada_value_print_ptr): New function.
6133 (ada_value_print_1): Use it.
6134
6135 2020-03-13 Tom Tromey <tom@tromey.com>
6136
6137 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
6138 call common_val_print.
6139 (ada_val_print_1): Update.
6140 (ada_value_print_1): New function.
6141 (ada_value_print_inner): Rewrite.
6142
6143 2020-03-13 Tom Tromey <tom@tromey.com>
6144
6145 * cp-valprint.c (cp_print_value_fields): Update.
6146 (cp_print_value): New function.
6147
6148 2020-03-13 Tom Tromey <tom@tromey.com>
6149
6150 * m2-valprint.c (m2_value_print_inner): Use
6151 cp_print_value_fields.
6152 * cp-valprint.c (cp_print_value_fields): New function.
6153 * c-valprint.c (c_value_print_struct): New function.
6154 (c_value_print_inner): Use c_value_print_struct.
6155 * c-lang.h (cp_print_value_fields): Declare.
6156
6157 2020-03-13 Tom Tromey <tom@tromey.com>
6158
6159 * c-valprint.c (c_value_print_array): New function.
6160 (c_value_print_inner): Use it.
6161
6162 2020-03-13 Tom Tromey <tom@tromey.com>
6163
6164 * c-valprint.c (c_value_print_memberptr): New function.
6165 (c_value_print_inner): Use it.
6166
6167 2020-03-13 Tom Tromey <tom@tromey.com>
6168
6169 * c-valprint.c (c_value_print_int): New function.
6170 (c_value_print_inner): Use it.
6171
6172 2020-03-13 Tom Tromey <tom@tromey.com>
6173
6174 * c-valprint.c (c_value_print_ptr): New function.
6175 (c_value_print_inner): Use it.
6176
6177 2020-03-13 Tom Tromey <tom@tromey.com>
6178
6179 * c-valprint.c (c_value_print_inner): Rewrite.
6180
6181 2020-03-13 Tom Tromey <tom@tromey.com>
6182
6183 * valprint.c (generic_value_print_complex): New function.
6184 (generic_value_print): Use it.
6185
6186 2020-03-13 Tom Tromey <tom@tromey.com>
6187
6188 * valprint.c (generic_val_print_float): Don't call
6189 val_print_scalar_formatted.
6190 (generic_val_print, generic_value_print): Update.
6191
6192 2020-03-13 Tom Tromey <tom@tromey.com>
6193
6194 * valprint.c (generic_value_print_char): New function
6195 (generic_value_print): Use it.
6196
6197 2020-03-13 Tom Tromey <tom@tromey.com>
6198
6199 * valprint.c (generic_value_print_int): New function.
6200 (generic_value_print): Use it.
6201
6202 2020-03-13 Tom Tromey <tom@tromey.com>
6203
6204 * valprint.c (generic_value_print_bool): New function.
6205 (generic_value_print): Use it.
6206
6207 2020-03-13 Tom Tromey <tom@tromey.com>
6208
6209 * valprint.c (generic_val_print_func): Simplify.
6210 (generic_val_print, generic_value_print): Update.
6211
6212 2020-03-13 Tom Tromey <tom@tromey.com>
6213
6214 * valprint.c (generic_val_print_flags): Remove.
6215 (generic_val_print, generic_value_print): Update.
6216 (val_print_type_code_flags): Add original_value parameter.
6217
6218 2020-03-13 Tom Tromey <tom@tromey.com>
6219
6220 * valprint.c (generic_val_print): Update.
6221 (generic_value_print): Update.
6222 * valprint.c (generic_val_print_enum): Don't call
6223 val_print_scalar_formatted.
6224
6225 2020-03-13 Tom Tromey <tom@tromey.com>
6226
6227 * valprint.c (generic_value_print): Call generic_value_print_ptr.
6228 * valprint.c (generic_value_print_ptr): New function.
6229
6230 2020-03-13 Tom Tromey <tom@tromey.com>
6231
6232 * valprint.c (generic_value_print): Rewrite.
6233
6234 2020-03-13 Tom Tromey <tom@tromey.com>
6235
6236 * p-valprint.c (pascal_object_print_value_fields)
6237 (pascal_object_print_value): New functions.
6238
6239 2020-03-13 Tom Tromey <tom@tromey.com>
6240
6241 * p-valprint.c (pascal_value_print_inner): Rewrite.
6242
6243 2020-03-13 Tom Tromey <tom@tromey.com>
6244
6245 * f-valprint.c (f_value_print_innner): Rewrite.
6246
6247 2020-03-13 Tom Tromey <tom@tromey.com>
6248
6249 * m2-valprint.c (m2_print_unbounded_array): New overload.
6250 (m2_print_unbounded_array): Update.
6251 (m2_print_array_contents): Take a struct value.
6252 (m2_value_print_inner): Rewrite.
6253
6254 2020-03-13 Tom Tromey <tom@tromey.com>
6255
6256 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
6257 (d_value_print_inner): New function.
6258 * d-lang.h (d_value_print_inner): Declare.
6259 * d-lang.c (d_language_defn): Use d_value_print_inner.
6260
6261 2020-03-13 Tom Tromey <tom@tromey.com>
6262
6263 * go-valprint.c (go_value_print_inner): New function.
6264 * go-lang.h (go_value_print_inner): Declare.
6265 * go-lang.c (go_language_defn): Use go_value_print_inner.
6266
6267 2020-03-13 Tom Tromey <tom@tromey.com>
6268
6269 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
6270 API.
6271 (rust_val_print): Rewrite.
6272 (rust_value_print_inner): New function, from rust_val_print.
6273 (rust_language_defn): Use rust_value_print_inner.
6274
6275 2020-03-13 Tom Tromey <tom@tromey.com>
6276
6277 * ada-valprint.c (ada_value_print_inner): New function.
6278 * ada-lang.h (ada_value_print_inner): Declare.
6279 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
6280
6281 2020-03-13 Tom Tromey <tom@tromey.com>
6282
6283 * f-valprint.c (f_value_print_innner): New function.
6284 * f-lang.h (f_value_print_innner): Declare.
6285 * f-lang.c (f_language_defn): Use f_value_print_innner.
6286
6287 2020-03-13 Tom Tromey <tom@tromey.com>
6288
6289 * p-valprint.c (pascal_value_print_inner): New function.
6290 * p-lang.h (pascal_value_print_inner): Declare.
6291 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
6292
6293 2020-03-13 Tom Tromey <tom@tromey.com>
6294
6295 * m2-valprint.c (m2_value_print_inner): New function.
6296 * m2-lang.h (m2_value_print_inner): Declare.
6297 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
6298
6299 2020-03-13 Tom Tromey <tom@tromey.com>
6300
6301 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
6302 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
6303 * c-valprint.c (c_value_print_inner): New function.
6304 * c-lang.h (c_value_print_inner): Declare.
6305 * c-lang.c (c_language_defn, cplus_language_defn)
6306 (asm_language_defn, minimal_language_defn): Use
6307 c_value_print_inner.
6308
6309 2020-03-13 Tom Tromey <tom@tromey.com>
6310
6311 * p-valprint.c (pascal_object_print_value_fields): Now static.
6312 * p-lang.h (pascal_object_print_value_fields): Don't declare.
6313
6314 2020-03-13 Tom Tromey <tom@tromey.com>
6315
6316 * c-valprint.c (c_val_print_array): Simplify.
6317
6318 2020-03-13 Tom Tromey <tom@tromey.com>
6319
6320 * valprint.c (value_print_array_elements): New function.
6321 * valprint.h (value_print_array_elements): Declare.
6322
6323 2020-03-13 Tom Tromey <tom@tromey.com>
6324
6325 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
6326 * mips-tdep.c (mips_print_register): Use
6327 value_print_scalar_formatted.
6328
6329 2020-03-13 Tom Tromey <tom@tromey.com>
6330
6331 * valprint.h (value_print_scalar_formatted): Declare.
6332 * valprint.c (value_print_scalar_formatted): New function.
6333
6334 2020-03-13 Tom Tromey <tom@tromey.com>
6335
6336 * valprint.h (generic_value_print): Declare.
6337 * valprint.c (generic_value_print): New function.
6338
6339 2020-03-13 Tom Tromey <tom@tromey.com>
6340
6341 * valprint.c (do_val_print): Call la_value_print_inner, if
6342 available.
6343 * rust-lang.c (rust_language_defn): Update.
6344 * p-lang.c (pascal_language_defn): Update.
6345 * opencl-lang.c (opencl_language_defn): Update.
6346 * objc-lang.c (objc_language_defn): Update.
6347 * m2-lang.c (m2_language_defn): Update.
6348 * language.h (struct language_defn) <la_value_print_inner>: New
6349 member.
6350 * language.c (unknown_language_defn, auto_language_defn): Update.
6351 * go-lang.c (go_language_defn): Update.
6352 * f-lang.c (f_language_defn): Update.
6353 * d-lang.c (d_language_defn): Update.
6354 * c-lang.c (c_language_defn, cplus_language_defn)
6355 (asm_language_defn, minimal_language_defn): Update.
6356 * ada-lang.c (ada_language_defn): Update.
6357
6358 2020-03-13 Tom Tromey <tom@tromey.com>
6359
6360 * c-valprint.c (c_value_print): Use common_val_print.
6361
6362 2020-03-13 Tom Tromey <tom@tromey.com>
6363
6364 * cp-valprint.c (cp_print_static_field): Use common_val_print.
6365
6366 2020-03-13 Tom Tromey <tom@tromey.com>
6367
6368 * f-valprint.c (f77_print_array_1, f_val_print): Use
6369 common_val_print.
6370
6371 2020-03-13 Tom Tromey <tom@tromey.com>
6372
6373 * riscv-tdep.c (riscv_print_one_register_info): Use
6374 common_val_print.
6375
6376 2020-03-13 Tom Tromey <tom@tromey.com>
6377
6378 * mi/mi-main.c (output_register): Use common_val_print.
6379
6380 2020-03-13 Tom Tromey <tom@tromey.com>
6381
6382 * infcmd.c (default_print_one_register_info): Use
6383 common_val_print.
6384
6385 2020-03-13 Tom Tromey <tom@tromey.com>
6386
6387 * valprint.h (common_val_print_checked): Declare.
6388 * valprint.c (common_val_print_checked): New function.
6389 * stack.c (print_frame_arg): Use common_val_print_checked.
6390
6391 2020-03-13 Tom Tromey <tom@tromey.com>
6392
6393 * valprint.c (do_val_print): New function, from val_print.
6394 (val_print): Use do_val_print.
6395 (common_val_print): Use do_val_print.
6396
6397 2020-03-13 Tom Tromey <tom@tromey.com>
6398
6399 * valprint.c (value_print): Use scoped_value_mark.
6400
6401 2020-03-13 Tom de Vries <tdevries@suse.de>
6402
6403 PR symtab/25646
6404 * psymtab.c (partial_symtab::partial_symtab): Don't set
6405 globals_offset and statics_offset. Push element onto
6406 current_global_psymbols and current_static_psymbols stacks.
6407 (concat): New function.
6408 (end_psymtab_common): Set globals_offset and statics_offset. Pop
6409 element from current_global_psymbols and current_static_psymbols
6410 stacks. Concat popped elements to global_psymbols and
6411 static_symbols.
6412 (add_psymbol_to_list): Use current_global_psymbols and
6413 current_static_psymbols stacks.
6414 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
6415 current_static_psymbols fields.
6416
6417 2020-03-12 Christian Biesinger <cbiesinger@google.com>
6418
6419 * corelow.c (sniff_core_bfd): Remove.
6420 (class core_target) <m_core_vec>: Remove.
6421 (core_target::core_target): Update.
6422 (core_file_fns): Remove.
6423 (deprecated_add_core_fns): Remove.
6424 (default_core_sniffer): Remove.
6425 (sniff_core_bfd): Remove.
6426 (default_check_format): Remove.
6427 (gdb_check_format): Remove.
6428 (core_target_open): Update.
6429 (core_target::get_core_register_section): Update.
6430 (get_core_registers_cb): Update.
6431 (core_target::fetch_registers): Update.
6432 * gdbcore.h (struct core_fns): Remove.
6433 (deprecated_add_core_fns): Remove.
6434 (default_core_sniffer): Remove.
6435 (default_check_format): Remove.
6436
6437 2020-03-12 Tom Tromey <tom@tromey.com>
6438
6439 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
6440 CORE_ADDR.
6441 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
6442
6443 2020-03-12 Tom Tromey <tom@tromey.com>
6444
6445 * remote.c (remote_target::download_tracepoint)
6446 (remote_target::enable_tracepoint)
6447 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
6448 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
6449 sprintf_vma.
6450
6451 2020-03-12 Tom Tromey <tom@tromey.com>
6452
6453 * symfile-mem.c: Update CORE_ADDR size assert.
6454
6455 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6456
6457 * selftest.m4: Move to gdbsupport/.
6458 * acinclude.m4: Update path to selftest.m4.
6459
6460 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6461
6462 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
6463 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
6464 gdbarch-selfselftests.c and selftest-arch.c.
6465 (SUBDIR_UNITTESTS_OBS): Rename to...
6466 (SELFTESTS_OBS): ... this.
6467 (COMMON_SFILES): Remove disasm-selftests.c and
6468 gdbarch-selftests.c.
6469 * configure.ac: Don't add selftest-arch.{c,o} to
6470 CONFIG_{SRCS,OBS}.
6471 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
6472 preprocessor conditions.
6473
6474 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6475
6476 * configure.ac: Don't source bfd/development.sh.
6477 * selftest.m4: Modify comment.
6478 * configure: Re-generate.
6479
6480 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
6481
6482 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
6483 not "true" or "false".
6484 * configure: Re-generate.
6485
6486 2020-03-12 Christian Biesinger <cbiesinger@google.com>
6487
6488 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
6489 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
6490 renamed to arm_nbsd_supply_gregset.
6491 (fetch_register): Update to call arm_nbsd_supply_gregset.
6492 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
6493 (arm_netbsd_nat_target::fetch_registers): Update.
6494 (fetch_elfcore_registers): Removed.
6495 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
6496 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
6497 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
6498 not require NetBSD system headers.
6499 (arm_nbsd_regset): New struct.
6500 (arm_nbsd_iterate_over_regset_sections): New function.
6501 (arm_netbsd_init_abi_common): Updated to call
6502 set_gdbarch_iterate_over_regset_sections.
6503 * arm-nbsd-tdep.h: New file.
6504
6505 2020-03-11 Kevin Buettner <kevinb@redhat.com>
6506
6507 * symtab.c (find_pc_sect_line): Add check which prevents infinite
6508 recursion.
6509
6510 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
6511
6512 * configure: Re-generate.
6513
6514 2020-03-11 Tom Tromey <tromey@adacore.com>
6515
6516 * ada-typeprint.c (print_choices): Fix comment.
6517
6518 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
6519
6520 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
6521 previous item in the list, when the list has no items.
6522
6523 2020-03-11 Tom de Vries <tdevries@suse.de>
6524
6525 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
6526 PROP_LOCLIST handling code.
6527
6528 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
6529
6530 * buildsym-legacy.c (record_line): Pass extra parameter to
6531 record_line.
6532 * buildsym.c (buildsym_compunit::record_line): Take an extra
6533 parameter, reduce duplication in the line table, and record the
6534 is_stmt flag in the line table.
6535 * buildsym.h (buildsym_compunit::record_line): Add extra
6536 parameter.
6537 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
6538 non-statement lines.
6539 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
6540 this to the symtab builder.
6541 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
6542 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
6543 through to dwarf_record_line_1.
6544 * infrun.c (process_event_stop_test): When stepping, don't stop at
6545 a non-statement instruction, and only refresh the step info when
6546 we land in the middle of a line's range. Also add an extra
6547 comment.
6548 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
6549 field.
6550 * record-btrace.c (btrace_find_line_range): Only record lines
6551 marked as is-statement.
6552 * stack.c (frame_show_address): Show the frame address if we are
6553 in a non-statement sal.
6554 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
6555 (maintenance_print_one_line_table): Print a header for the is_stmt
6556 column, and include is_stmt information in the output.
6557 * symtab.c (find_pc_sect_line): Find lines marked as statements in
6558 preference to non-statements.
6559 (find_pcs_for_symtab_line): Prefer is-statement entries.
6560 (find_line_common): Likewise.
6561 * symtab.h (struct linetable_entry): Add is_stmt field.
6562 (struct symtab_and_line): Likewise.
6563 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
6564 arranging the line table.
6565
6566 2020-03-07 Tom de Vries <tdevries@suse.de>
6567
6568 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
6569 DIE.
6570
6571 2020-03-07 Tom Tromey <tom@tromey.com>
6572
6573 * valops.c (value_literal_complex): Remove obsolete comment.
6574 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
6575 comment.
6576
6577 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
6578
6579 * infrun.h: Forward-declare thread_info.
6580 (set_step_info): Add thread_info parameter, add doc.
6581 * infrun.c (set_step_info): Add thread_info parameter, move doc
6582 to header.
6583 * infrun.c (process_event_stop_test): Pass thread to
6584 set_step_info call.
6585 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
6586 set_step_info.
6587 (prepare_one_step): Add thread_info parameter, pass it to
6588 set_step_frame and prepare_one_step (recursive) call.
6589 (step_1): Pass thread to prepare_one_step call.
6590 (step_command_fsm::should_stop): Pass thread to
6591 prepare_one_step.
6592 (until_next_fsm): Pass thread to set_step_frame call.
6593 (finish_command): Pass thread to set_step_info call.
6594
6595 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
6596
6597 * windows-tdep.c (windows_solib_create_inferior_hook):
6598 Check if inferior is running.
6599
6600 2020-03-06 Tom de Vries <tdevries@suse.de>
6601
6602 * NEWS: Fix "the the".
6603 * ctfread.c: Same.
6604
6605 2020-03-06 Tom de Vries <tdevries@suse.de>
6606
6607 * psymtab.c (psymtab_to_symtab): Don't print "done.".
6608
6609 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
6610
6611 * .dir-locals.el: Add a comment referencing the other copies of
6612 this file.
6613
6614 2020-03-05 John Baldwin <jhb@FreeBSD.org>
6615
6616 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
6617 psargs.
6618
6619 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6620
6621 * .gitattributes: New file.
6622
6623 2020-03-04 Tom Tromey <tom@tromey.com>
6624
6625 * symmisc.c (print_symbol_bcache_statistics)
6626 (print_objfile_statistics): Update.
6627 * symfile.c (allocate_symtab): Use intern.
6628 * psymtab.c (partial_symtab::partial_symtab): Use intern.
6629 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
6630 macro_cache>: Remove.
6631 <string_cache>: New member.
6632 (struct objfile) <intern>: New methods.
6633 * elfread.c (elf_symtab_read): Use intern.
6634 * dwarf2/read.c (fixup_go_packaging): Intern package name.
6635 (dwarf2_compute_name, dwarf2_physname)
6636 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
6637 names.
6638 (guess_partial_die_structure_name): Update.
6639 (partial_die_info::fixup): Intern name.
6640 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
6641 name.
6642 (dwarf2_name): Intern name. Update.
6643 * buildsym.c (buildsym_compunit::get_macro_table): Use
6644 string_cache.
6645
6646 2020-03-04 Tom Tromey <tom@tromey.com>
6647
6648 * jit.c (bfd_open_from_target_memory): Make "target" const.
6649 * corefile.c (gnutarget): Now const.
6650 * gdbcore.h (gnutarget): Now const.
6651
6652 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
6653
6654 * NEWS: Mention support for WOW64 processes.
6655 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
6656 (amd64_windows_segment_register_p): Remove static.
6657 (_initialize_amd64_windows_nat): Update.
6658 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
6659 * i386-windows-nat.c (context_offset): Update.
6660 (i386_mappings): Rename and remove static.
6661 (i386_windows_segment_register_p): Remove static.
6662 (_initialize_i386_windows_nat): Update.
6663 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
6664 (STATUS_WX86_SINGLE_STEP): New macro.
6665 (EnumProcessModulesEx): New macro.
6666 (Wow64SuspendThread): New macro.
6667 (Wow64GetThreadContext): New macro.
6668 (Wow64SetThreadContext): New macro.
6669 (Wow64GetThreadSelectorEntry): New macro.
6670 (windows_set_context_register_offsets): Add static.
6671 (windows_set_segment_register_p): Likewise.
6672 (windows_add_thread): Adapt for WOW64 processes.
6673 (windows_fetch_one_register): Likewise.
6674 (windows_nat_target::fetch_registers): Likewise.
6675 (windows_store_one_register): Likewise.
6676 (display_selector): Likewise.
6677 (display_selectors): Likewise.
6678 (handle_exception): Likewise.
6679 (windows_continue): Likewise.
6680 (windows_nat_target::resume): Likewise.
6681 (windows_add_all_dlls): Likewise.
6682 (do_initial_windows_stuff): Likewise.
6683 (windows_nat_target::attach): Likewise.
6684 (windows_get_exec_module_filename): Likewise.
6685 (windows_nat_target::create_inferior): Likewise.
6686 (windows_xfer_siginfo): Likewise.
6687 (_initialize_loadable): Initialize Wow64SuspendThread,
6688 Wow64GetThreadContext, Wow64SetThreadContext,
6689 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
6690 * windows-nat.h (windows_set_context_register_offsets):
6691 Remove declaration.
6692 (windows_set_segment_register_p): Likewise.
6693 (i386_windows_segment_register_p): Add declaration.
6694 (amd64_windows_segment_register_p): Likewise.
6695
6696 2020-03-04 Luis Machado <luis.machado@linaro.org>
6697
6698 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
6699 in "info registers" for AArch64/ARM.
6700
6701 The change caused "info registers" to not print GPR's.
6702
6703 gdb/ChangeLog:
6704
6705 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
6706
6707 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
6708 when reg->group is empty and reggroup is not.
6709
6710 2020-03-03 Tom Tromey <tromey@adacore.com>
6711
6712 * dwarf2/frame.c (struct dwarf2_frame_cache)
6713 <checked_tailcall_bottom, entry_cfa_sp_offset,
6714 entry_cfa_sp_offset_p>: Remove members.
6715 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
6716 (dwarf2_frame_prev_register): Don't call
6717 dwarf2_tailcall_sniffer_first.
6718 (dwarf2_append_unwinders): Don't append tailcall unwinder.
6719 * frame-unwind.c (add_unwinder): New fuction.
6720 (frame_unwind_init): Use it. Add tailcall unwinder.
6721
6722 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
6723 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
6724
6725 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
6726 value should be printed as true.
6727
6728 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
6729
6730 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
6731 (windows_init_abi): Set and use windows_so_ops.
6732
6733 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
6734
6735 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
6736 when verifying if dealing with a convenience variable.
6737
6738 2020-03-03 Luis Machado <luis.machado@linaro.org>
6739
6740 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
6741
6742 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6743
6744 * infrun.c (gdbarch_supports_displaced_stepping): New.
6745 (use_displaced_stepping): Break up conditions in smaller pieces.
6746 Use gdbarch_supports_displaced_stepping.
6747 (displaced_step_prepare_throw): Use
6748 gdbarch_supports_displaced_stepping.
6749
6750 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
6751
6752 * NEWS: Mention new behaviour of the history filename.
6753 * top.c (write_history_p): Add comment.
6754 (show_write_history_p): Add header comment, give a different
6755 message when history writing is on, but the history filename is
6756 empty.
6757 (history_filename): Add comment.
6758 (history_filename_empty): New function.
6759 (show_history_filename): Add header comment, give a different
6760 message when the filename is empty.
6761 (init_history): Compare history_filename against nullptr, and only
6762 read history if the filename is not empty.
6763 (set_history_filename): Add header comment, and only make
6764 non-empty filenames absolute.
6765 (init_main): Make the filename argument to 'set history filename'
6766 optional.
6767
6768 2020-03-02 Christian Biesinger <cbiesinger@google.com>
6769
6770 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
6771 (arm_supply_vfpregset): ...this, and update to use VFP registers.
6772 (fetch_fp_register): Update.
6773 (fetch_fp_regs): Update.
6774 (store_fp_register): Update.
6775 (store_fp_regs): Update.
6776 (arm_netbsd_nat_target::read_description): New function.
6777 (fetch_elfcore_registers): Update.
6778
6779 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
6780
6781 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
6782 general_thread if the stop reply is missing a thread-id.
6783 (remote_target::process_stop_reply): Use the first non-exited
6784 thread if the target didn't pass a thread-id.
6785 * infrun.c (do_target_wait): Move call to
6786 switch_to_inferior_no_thread to ....
6787 (do_target_wait_1): ... here.
6788
6789 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
6790
6791 * debuginfod-support.c: Include defs.h first.
6792
6793 2020-02-28 Tom de Vries <tdevries@suse.de>
6794
6795 * symfile.c (set_initial_language): Use default language for lookup.
6796
6797 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
6798
6799 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
6800 reader variable, pass `this` to read_cutu_die_from_dwo.
6801
6802 2020-02-27 Aaron Merey <amerey@redhat.com>
6803
6804 * source.c (open_source_file): Check for nullptr when computing
6805 srcpath.
6806
6807 2020-02-27 Tom Tromey <tromey@adacore.com>
6808
6809 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
6810 member.
6811 (dwarf2_add_field): Don't update nfields.
6812 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
6813
6814 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
6815
6816 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
6817 abs.
6818
6819 2020-02-26 Tom Tromey <tom@tromey.com>
6820
6821 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
6822 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
6823 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
6824 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
6825 per_cu_data.
6826
6827 2020-02-26 Tom Tromey <tom@tromey.com>
6828
6829 * dwarf2/index-write.c (psym_index_map): Change type.
6830 (add_address_entry_worker, write_one_signatured_type)
6831 (recursively_count_psymbols, recursively_write_psymbols)
6832 (class debug_names, psyms_seen_size, write_gdbindex)
6833 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
6834
6835 2020-02-26 Aaron Merey <amerey@redhat.com>
6836
6837 * Makefile.in: Handle optional debuginfod support.
6838 * NEWS: Update.
6839 * README: Add --with-debuginfod summary.
6840 * config.in: Regenerate.
6841 * configure: Regenerate.
6842 * configure.ac: Handle optional debuginfod support.
6843 * debuginfod-support.c: debuginfod helper functions.
6844 * debuginfod-support.h: Ditto.
6845 * doc/gdb.texinfo: Add --with-debuginfod to configure options
6846 summary.
6847 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
6848 when a dwz file cannot be found.
6849 * elfread.c (elf_symfile_read): Query debuginfod servers when a
6850 debuginfo file cannot be found.
6851 * source.c (open_source_file): Query debuginfod servers when a
6852 source file cannot be found.
6853 * top.c (print_gdb_configuration): Include
6854 --{with,without}-debuginfod in the output.
6855
6856 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
6857
6858 * thread.c (thr_try_catch_cmd): Print thread name.
6859
6860 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
6861
6862 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
6863 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
6864 dwarf2_fetch_die_type_sect_off): Move to...
6865 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
6866 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
6867 dwarf2_fetch_die_type_sect_off): ... here.
6868 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
6869 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
6870 dwarf2_fetch_die_type_sect_off): Move doc to header file.
6871
6872 2020-02-26 Tom de Vries <tdevries@suse.de>
6873
6874 PR gdb/25603
6875 * symfile.c (set_initial_language): Exit-early if
6876 language_mode == language_mode_manual.
6877
6878 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
6879
6880 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
6881 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
6882 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
6883
6884 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
6885
6886 * gdbtypes.c (create_array_type_with_stride): Handle negative
6887 array strides.
6888 * valarith.c (value_subscripted_rvalue): Likewise.
6889
6890 2020-02-25 Luis Machado <luis.machado@linaro.org>
6891
6892 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
6893
6894 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
6895
6896 * loc.h (dwarf2_get_die_type): Move to...
6897 * read.h (dwarf2_get_die_type): ... here.
6898 * read.c (dwarf2_get_die_type): Move doc to header.
6899
6900 2020-02-25 Joel Brobecker <brobecker@adacore.com>
6901
6902 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
6903 'gnulib/Makefile.in' to the list.
6904
6905 2020-02-24 Tom Tromey <tom@tromey.com>
6906
6907 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
6908 Remove.
6909 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
6910 XOBNEWVEC.
6911
6912 2020-02-24 Tom Tromey <tom@tromey.com>
6913
6914 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
6915 New method.
6916 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
6917 (dw2_do_instantiate_symtab, dw2_get_file_names)
6918 (build_type_psymtab_dependencies, load_full_type_unit): Update.
6919
6920 2020-02-24 Tom Tromey <tom@tromey.com>
6921
6922 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
6923 make_scoped_restore.
6924 (dwarf2_psymtab::read_symtab): Don't clear
6925 reading_partial_symbols.
6926
6927 2020-02-24 Tom de Vries <tdevries@suse.de>
6928
6929 PR gdb/25592
6930 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
6931
6932 2020-02-24 Tom de Vries <tdevries@suse.de>
6933
6934 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
6935 commands layout next/prev/regs.
6936
6937 2020-02-22 Tom Tromey <tom@tromey.com>
6938
6939 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
6940 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
6941
6942 2020-02-22 Tom Tromey <tom@tromey.com>
6943
6944 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
6945
6946 2020-02-22 Tom Tromey <tom@tromey.com>
6947
6948 * tui/tui-win.c (_initialize_tui_win): Add usage text.
6949 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
6950 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
6951 * tui/tui.c (_initialize_tui): Add usage text.
6952
6953 2020-02-22 Tom Tromey <tom@tromey.com>
6954
6955 * tui/tui-win.c (tui_set_focus_command)
6956 (tui_set_win_height_command): Use error_no_arg.
6957 (_initialize_tui_win): Update help text.
6958 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
6959
6960 2020-02-22 Tom Tromey <tom@tromey.com>
6961
6962 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
6963 * tui/tui-disasm.h (struct tui_disasm_window)
6964 <display_start_addr>: Declare.
6965 * tui/tui-source.h (struct tui_source_window)
6966 <display_start_addr>: Declare.
6967 * tui/tui-winsource.h (struct tui_source_window_base)
6968 <show_source_line, display_start_addr>: New methods.
6969 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
6970 Rename and move to protected section.
6971 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
6972 (tui_source_window_base::do_erase_source_content): Update.
6973 (tui_source_window_base::show_source_line): Now a method.
6974 (tui_source_window_base::show_source_content)
6975 (tui_source_window_base::tui_source_window_base)
6976 (tui_source_window_base::rerender)
6977 (tui_source_window_base::refill)
6978 (tui_source_window_base::do_scroll_horizontal)
6979 (tui_source_window_base::set_is_exec_point_at)
6980 (tui_source_window_base::update_breakpoint_info)
6981 (tui_source_window_base::update_exec_info): Update.
6982 * tui/tui-source.c (tui_source_window::set_contents)
6983 (tui_source_window::showing_source_p)
6984 (tui_source_window::do_scroll_vertical)
6985 (tui_source_window::location_matches_p)
6986 (tui_source_window::line_is_displayed): Update.
6987 (tui_source_window::display_start_addr): New method.
6988 * tui/tui-disasm.c (tui_disasm_window::set_contents)
6989 (tui_disasm_window::do_scroll_vertical)
6990 (tui_disasm_window::location_matches_p): Update.
6991 (tui_disasm_window::display_start_addr): New method.
6992
6993 2020-02-22 Tom Tromey <tom@tromey.com>
6994
6995 * NEWS: Add entry for gdb.register_window_type.
6996 * tui/tui-layout.h (window_factory): New typedef.
6997 (tui_register_window): Declare.
6998 * tui/tui-layout.c (saved_tui_windows): New global.
6999 (tui_apply_current_layout): Use it.
7000 (tui_register_window): New function.
7001 * python/python.c (do_start_initialization): Call
7002 gdbpy_initialize_tui.
7003 (python_GdbMethods): Add "register_window_type" function.
7004 * python/python-internal.h (gdbpy_register_tui_window)
7005 (gdbpy_initialize_tui): Declare.
7006 * python/py-tui.c: New file.
7007 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
7008
7009 2020-02-22 Tom Tromey <tom@tromey.com>
7010
7011 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
7012
7013 2020-02-22 Tom Tromey <tom@tromey.com>
7014
7015 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
7016 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
7017 * tui/tui-data.c (tui_set_win_with_focus): Remove.
7018 (tui_set_win_focus_to): Move from tui-win.c.
7019
7020 2020-02-22 Tom Tromey <tom@tromey.com>
7021
7022 * tui/tui-layout.c (make_standard_window, get_locator_window): New
7023 functions.
7024 (known_window_types): New global.
7025 (tui_get_window_by_name): Reimplement.
7026 (initialize_known_windows): New function.
7027 (validate_window_name): Rewrite.
7028 (_initialize_tui_layout): Call initialize_known_windows.
7029
7030 2020-02-22 Tom Tromey <tom@tromey.com>
7031
7032 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
7033 Remove constants.
7034 * tui/tui-winsource.h (struct tui_source_window_base)
7035 <tui_source_window_base>: Remove parameter.
7036 * tui/tui-winsource.c
7037 (tui_source_window_base::tui_source_window_base): Remove
7038 parameter.
7039 (tui_source_window_base::refill): Update.
7040 * tui/tui-stack.h (struct tui_locator_window)
7041 <tui_locator_window>: Update.
7042 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
7043 Default the constructor.
7044 * tui/tui-regs.h (struct tui_data_item_window)
7045 <tui_data_item_window>: Default the constructor.
7046 (struct tui_data_window) <tui_data_window>: Likewise.
7047 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
7048 Default the constructor.
7049 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
7050 Default the constructor.
7051 <type>: Remove.
7052 (struct tui_win_info) <tui_win_info>: Default the constructor.
7053 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
7054 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
7055 Default the constructor.
7056
7057 2020-02-22 Tom Tromey <tom@tromey.com>
7058
7059 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
7060 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
7061 * tui/tui-win.c (tui_resize_all): Don't call
7062 tui_delete_invisible_windows.
7063 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
7064 done.
7065 (tui_set_layout): Update.
7066 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
7067 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
7068 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
7069
7070 2020-02-22 Tom Tromey <tom@tromey.com>
7071
7072 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
7073 correctly.
7074
7075 2020-02-22 Tom Tromey <tom@tromey.com>
7076
7077 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
7078
7079 2020-02-22 Tom Tromey <tom@tromey.com>
7080
7081 * tui/tui-winsource.h (struct tui_source_window_iterator)
7082 <inner_iterator>: New etytypedef.
7083 <tui_source_window_iterator>: Take "end" parameter.
7084 <tui_source_window_iterator>: Take iterator.
7085 <operator*, advance>: Update.
7086 <m_iter>: Change type.
7087 <m_end>: New field.
7088 (struct tui_source_windows) <begin, end>: Update.
7089 * tui/tui-layout.c (tui_windows): New global.
7090 (tui_apply_current_layout): Clear tui_windows.
7091 (tui_layout_window::apply): Update tui_windows.
7092 * tui/tui-data.h (tui_windows): Declare.
7093 (all_tui_windows): Now inline function.
7094 (class tui_window_iterator, struct all_tui_windows): Remove.
7095
7096 2020-02-22 Tom Tromey <tom@tromey.com>
7097
7098 PR tui/17850:
7099 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
7100 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
7101 "height" argument.
7102 (class tui_layout_window) <get_sizes>: Likewise.
7103 (class tui_layout_split) <tui_layout_split>: Add "vertical"
7104 argument.
7105 <get_sizes>: Add "height" argument.
7106 <m_vertical>: New field.
7107 * tui/tui-layout.c (tui_layout_split::clone): Update.
7108 (tui_layout_split::get_sizes): Add "height" argument.
7109 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
7110 (tui_new_layout_command): Parse "-horizontal".
7111 (_initialize_tui_layout): Update help string.
7112 (tui_layout_split::specification): Add "-horizontal" when needed.
7113 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
7114 argument.
7115 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
7116 New methods.
7117
7118 2020-02-22 Tom Tromey <tom@tromey.com>
7119
7120 * tui/tui-layout.h (enum tui_adjust_result): New.
7121 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
7122 (class tui_layout_window) <adjust_size>: Return
7123 tui_adjust_result. Rewrite.
7124 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
7125 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
7126
7127 2020-02-22 Tom Tromey <tom@tromey.com>
7128
7129 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
7130 parameter and return types.
7131 (class tui_layout_base) <specification>: Add "depth".
7132 (class tui_layout_window) <specification>: Add "depth".
7133 (class tui_layout_split) <specification>: Add "depth".
7134 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
7135 and return types.
7136 (tui_new_layout_command): Parse sub-layouts.
7137 (_initialize_tui_layout): Update help string.
7138 (tui_layout_window::specification): Add "depth".
7139 (add_layout_command): Update.
7140
7141 2020-02-22 Tom Tromey <tom@tromey.com>
7142
7143 * NEWS: Add "tui new-layout" item.
7144 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
7145 Add new-layout command to help text.
7146 (validate_window_name): New function.
7147 (tui_new_layout_command): New function.
7148 (_initialize_tui_layout): Register "new-layout".
7149 (tui_layout_window::specification): New method.
7150 (tui_layout_window::specification): New method.
7151 * tui/tui-layout.h (class tui_layout_base) <specification>: New
7152 method.
7153 (class tui_layout_window) <specification>: New method.
7154 (class tui_layout_split) <specification>: New method.
7155
7156 2020-02-22 Tom Tromey <tom@tromey.com>
7157
7158 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
7159 * tui/tui-win.c (window_name_completer): Update comment.
7160 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
7161 Declare method.
7162 (class tui_layout_window) <replace_window>: Likewise.
7163 (class tui_layout_split) <replace_window>: Likewise.
7164 (tui_set_layout): Don't declare.
7165 (tui_set_initial_layout): Declare function.
7166 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
7167 (asm_regs_layout): New globals.
7168 (tui_current_layout, show_layout): Remove.
7169 (tui_set_layout, tui_add_win_to_layout): Rewrite.
7170 (find_layout, tui_apply_layout): New function.
7171 (layout_completer): Remove.
7172 (tui_next_layout): Reimplement.
7173 (tui_next_layout_command): New function.
7174 (tui_set_initial_layout, tui_prev_layout_command): New functions.
7175 (tui_regs_layout): Reimplement.
7176 (tui_regs_layout_command): New function.
7177 (extract_display_start_addr): Rewrite.
7178 (next_layout, prev_layout): Remove.
7179 (tui_layout_window::replace_window): New method.
7180 (tui_layout_split::replace_window): New method.
7181 (destroy_layout): New function.
7182 (layout_list): New global.
7183 (add_layout_command): New function.
7184 (initialize_layouts): Update.
7185 (tui_layout_command): New function.
7186 (_initialize_tui_layout): Install "layout" commands.
7187 * tui/tui-data.h (enum tui_layout_type): Remove.
7188 (tui_current_layout): Don't declare.
7189
7190 2020-02-22 Tom Tromey <tom@tromey.com>
7191
7192 * tui/tui-regs.c (tui_reg_layout): Remove.
7193 (tui_reg_command): Use tui_regs_layout.
7194 * tui/tui-layout.h (tui_reg_command): Declare.
7195 * tui/tui-layout.c (tui_reg_command): New function.
7196
7197 2020-02-22 Tom Tromey <tom@tromey.com>
7198
7199 * tui/tui.c (tui_rl_delete_other_windows): Call
7200 tui_remove_some_windows.
7201 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
7202 Declare method.
7203 (class tui_layout_window) <remove_windows>: New method.
7204 (class tui_layout_split) <remove_windows>: Declare.
7205 (tui_remove_some_windows): Declare.
7206 * tui/tui-layout.c (tui_remove_some_windows): New function.
7207 (tui_layout_split::remove_windows): New method.
7208
7209 2020-02-22 Tom Tromey <tom@tromey.com>
7210
7211 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
7212 * tui/tui-layout.h (tui_next_layout): Declare.
7213 * tui/tui-layout.c (tui_next_layout): New function.
7214
7215 2020-02-22 Tom Tromey <tom@tromey.com>
7216
7217 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
7218 correct coordinates.
7219
7220 2020-02-22 Tom Tromey <tom@tromey.com>
7221
7222 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
7223 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
7224 DATA_WIN case.
7225
7226 2020-02-22 Tom Tromey <tom@tromey.com>
7227
7228 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
7229 TUI_DISASM_WIN, not tui_win_list.
7230
7231 2020-02-22 Tom Tromey <tom@tromey.com>
7232
7233 * valprint.c (generic_val_print_enum_1)
7234 (val_print_type_code_flags): Style member names.
7235 * rust-lang.c (val_print_struct, rust_print_enum)
7236 (rust_print_struct_def, rust_internal_print_type): Style member
7237 names.
7238 * p-valprint.c (pascal_object_print_value_fields): Style member
7239 names. Only call fprintf_symbol_filtered for static members.
7240 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
7241 * f-valprint.c (f_val_print): Style member names.
7242 * f-typeprint.c (f_type_print_base): Style member names.
7243 * cp-valprint.c (cp_print_value_fields): Style member names. Only
7244 call fprintf_symbol_filtered for static members.
7245 (cp_print_class_member): Style member names.
7246 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
7247 member names.
7248 * ada-valprint.c (ada_print_scalar): Style enum names.
7249 (ada_val_print_enum): Likewise.
7250 * ada-typeprint.c (print_enum_type): Style enum names.
7251
7252 2020-02-21 Tom Tromey <tom@tromey.com>
7253
7254 * psympriv.h (struct partial_symtab): Update comment.
7255
7256 2020-02-21 Tom Tromey <tromey@adacore.com>
7257
7258 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
7259 type is CORE_ADDR.
7260
7261 2020-02-21 Tom de Vries <tdevries@suse.de>
7262
7263 PR gdb/25534
7264 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
7265 if dependencies[i]->user != NULL.
7266
7267 2020-02-21 Ali Tamur <tamur@google.com>
7268
7269 * dwarf2/read.c (dwarf2_name): Add null check.
7270
7271 2020-02-20 Tom Tromey <tom@tromey.com>
7272
7273 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
7274 ">=", in binary search.
7275 (dwarf2_find_containing_comp_unit): New overload.
7276 (run_test): New self-test.
7277 (_initialize_dwarf2_read): Register new test.
7278
7279 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
7280
7281 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
7282 * riscv-tdep.h: Likewise.
7283 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
7284 rv32-only CSR.
7285 * features/riscv/64bit-csr.xml: Regenerated.
7286
7287 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
7288 Tom Tromey <tom@tromey.com>
7289
7290 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
7291 of 'fputc_unfiltered'.
7292 (putchar_unfiltered): Call 'fputc_unfiltered'.
7293 (fputc_unfiltered): Call 'fputs_unfiltered'.
7294
7295 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
7296
7297 * config.in: Regenerate.
7298 * configure: Regenerate.
7299 * configure.ac: Add --with-python-libdir option.
7300 * main.c: Use WITH_PYTHON_LIBDIR.
7301
7302 2020-02-19 Tom Tromey <tom@tromey.com>
7303
7304 * symtab.c (general_symbol_info::compute_and_set_names): Use
7305 obstack_strndup. Simplify call to symbol_set_demangled_name.
7306
7307 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
7308
7309 * dwarf2/read.c (allocate_signatured_type_table,
7310 allocate_dwo_unit_table, allocate_type_unit_groups_table,
7311 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
7312 Remove objfile parameter, update all callers.
7313
7314 2020-02-19 Doug Evans <dje@google.com>
7315
7316 PR rust/25535
7317 * rust-lang.c (rust_print_enum): Apply embedded_offset to
7318 rust_enum_variant calculation.
7319
7320 2020-02-19 Tom Tromey <tromey@adacore.com>
7321
7322 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
7323
7324 2020-02-19 Tom Tromey <tromey@adacore.com>
7325
7326 * ada-lang.c (cache_symbol): Use obstack_strdup.
7327
7328 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
7329
7330 * configure: Regenerate.
7331
7332 2020-02-19 Tom Tromey <tromey@adacore.com>
7333
7334 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
7335 NULL check.
7336
7337 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
7338
7339 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
7340
7341 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
7342
7343 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
7344 if GDBSERVER is not defined.
7345 (riscv_tdesc_cache): Likewise, also store const target_desc.
7346 (STATIC_IN_GDB): Define.
7347 (riscv_create_target_description): Update declaration with
7348 STATIC_IN_GDB.
7349 (riscv_lookup_target_description): New function, only define if
7350 GDBSERVER is not defined.
7351 * arch/riscv.h (riscv_create_target_description): Declare only
7352 when GDBSERVER is defined.
7353 (riscv_lookup_target_description): New declaration when GDBSERVER
7354 is not defined.
7355 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
7356 (riscv_linux_read_features): ...this, and return
7357 riscv_gdbarch_features instead of target_desc.
7358 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
7359 (riscv_linux_read_description): Rename to...
7360 (riscv_linux_read_features): ...this.
7361 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
7362 Update to use riscv_gdbarch_features and
7363 riscv_lookup_target_description.
7364 * riscv-tdep.c (riscv_find_default_target_description): Use
7365 riscv_lookup_target_description instead of
7366 riscv_create_target_description.
7367
7368 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7369
7370 * valprint.c (generic_val_print_enum_1): When printing a flag
7371 enum with value 0 and there is no enumerator with value 0, print
7372 just "0" instead of "(unknown: 0x0)".
7373
7374 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7375
7376 * valprint.c (generic_val_print_enum_1): Print unknown part of
7377 flag enum in hex.
7378
7379 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7380
7381 * dwarf2/read.c (update_enumeration_type_from_children): Allow
7382 flag enums to contain duplicate enumerators.
7383 * valprint.c (generic_val_print_enum_1): Update comment.
7384
7385 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7386
7387 * dwarf2/read.c: Include "count-one-bits.h".
7388 (update_enumeration_type_from_children): If an enumerator has
7389 multiple bits set, don't treat the enumeration as a "flag enum".
7390 * valprint.c (generic_val_print_enum_1): Assert that enumerators
7391 of flag enums have 0 or 1 bit set.
7392
7393 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
7394
7395 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
7396 conversion.
7397 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
7398 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
7399 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
7400 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
7401 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
7402
7403 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
7404
7405 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
7406
7407 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7408
7409 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
7410 displaced_step_closure_up.
7411 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
7412 (struct displaced_step_closure_up):
7413 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
7414 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
7415 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
7416 Likewise.
7417 * gdbarch.sh (displaced_step_copy_insn): Likewise.
7418 * gdbarch.c, gdbarch.h: Re-generate.
7419 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
7420 displaced_step_closure_up.
7421 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
7422 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
7423 * infrun.h (displaced_step_closure_up): New type alias.
7424 (struct displaced_step_inferior_state) <step_closure>: Change
7425 type to displaced_step_closure_up.
7426 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
7427 displaced_step_closure_up.
7428 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
7429
7430 2020-02-14 Tom Tromey <tom@tromey.com>
7431
7432 * minidebug.c (gnu_debug_key): New global.
7433 (find_separate_debug_file_in_section): Use it.
7434
7435 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7436
7437 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
7438 std::unique_ptr.
7439 * gdbarch.c: Re-generate.
7440 * gdbarch.h: Re-generate.
7441 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
7442 change.
7443 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
7444 type to std::unique_ptr.
7445 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
7446 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
7447 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
7448 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
7449 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
7450 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
7451 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
7452 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
7453 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
7454
7455 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7456
7457 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
7458 std::unique_ptr.
7459 (displaced_step_clear): Rename to...
7460 (displaced_step_reset): ... this. Just call displaced->reset ().
7461 (displaced_step_clear_cleanup): Rename to...
7462 (displaced_step_reset_cleanup): ... this.
7463 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
7464 (displaced_step_fixup): Likewise.
7465 (resume_1): Likewise.
7466 (handle_inferior_event): Restore child's memory before calling
7467 displaced_step_fixup on the parent.
7468 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
7469 to std::unique_ptr.
7470 <step_closure>: Change type to std::unique_ptr.
7471
7472 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
7473
7474 * arm-tdep.c: Include count-one-bits.h.
7475 (cleanup_block_store_pc): Use count_one_bits.
7476 (cleanup_block_load_pc): Use count_one_bits.
7477 (arm_copy_block_xfer): Use count_one_bits.
7478 (thumb2_copy_block_xfer): Use count_one_bits.
7479 (thumb_copy_pop_pc_16bit): Use count_one_bits.
7480 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
7481 (thumb_get_next_pcs_raw): Use count_one_bits.
7482 (arm_get_next_pcs_raw): Use count_one_bits_l.
7483 * arch/arm.c (bitcount): Remove.
7484 * arch/arm.h (bitcount): Remove.
7485
7486 2020-02-14 Tom Tromey <tromey@adacore.com>
7487
7488 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
7489 Update.
7490 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
7491 * dwarf2/loc.c (call_site_find_chain_1): Return
7492 unique_xmalloc_ptr.
7493 (call_site_find_chain): Likewise.
7494
7495 2020-02-14 Richard Biener <rguenther@suse.de>
7496
7497 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
7498 on expression with division operators.
7499
7500 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
7501
7502 * MAINTAINERS (Write After Approval): Adding myself.
7503
7504 2020-02-12 Tom Tromey <tom@tromey.com>
7505
7506 * event-loop.c (event_data, gdb_event, event_handler_func):
7507 Remove.
7508
7509 2020-02-12 Tom Tromey <tom@tromey.com>
7510
7511 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
7512 (dwarf2_frame_objfile_data): Add comment.
7513 (find_comp_unit, set_comp_unit): New functions.
7514 (dwarf2_frame_find_fde): Use find_comp_unit.
7515 (dwarf2_build_frame_info): Use set_comp_unit.
7516
7517 2020-02-12 Tom Tromey <tom@tromey.com>
7518
7519 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
7520 (comp_unit): Don't initialize objfile.
7521 (execute_cfa_program): Add text_offset parameter.
7522 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
7523 (dwarf2_frame_cache): Update.
7524 (dwarf2_build_frame_info): Don't set "objfile" member.
7525
7526 2020-02-12 Tom Tromey <tom@tromey.com>
7527
7528 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
7529 (decode_frame_entry): Likewise.
7530 (dwarf2_build_frame_info): Update.
7531
7532 2020-02-12 Tom Tromey <tom@tromey.com>
7533
7534 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
7535 (decode_frame_entry_1): Use the comp_unit obstack.
7536
7537 2020-02-12 Tom Tromey <tom@tromey.com>
7538
7539 * dwarf2/frame.c (struct comp_unit): Add initializers and
7540 constructor.
7541 (dwarf2_frame_objfile_data): Store a comp_unit.
7542 (dwarf2_frame_find_fde): Update.
7543 (dwarf2_build_frame_info): Use "new".
7544
7545 2020-02-12 Tom Tromey <tom@tromey.com>
7546
7547 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
7548 (dwarf2_fde_table): Typedef for std::vector.
7549 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
7550 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
7551 (decode_frame_entry): Update.
7552 (dwarf2_build_frame_info): Use "new".
7553
7554 2020-02-12 Christian Biesinger <cbiesinger@google.com>
7555
7556 * arm-tdep.c (arm_gdbarch_init): Update.
7557 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
7558 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
7559 have_neon, is_m>: Change to bool.
7560
7561 2020-02-12 Christian Biesinger <cbiesinger@google.com>
7562
7563 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
7564
7565 2020-02-12 Tom Tromey <tom@tromey.com>
7566
7567 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
7568
7569 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
7570
7571 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
7572 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
7573
7574 2020-02-11 Tom Tromey <tom@tromey.com>
7575
7576 * psymtab.h: Update comment.
7577
7578 2020-02-11 Tom Tromey <tom@tromey.com>
7579
7580 * gdb_obstack.h (struct auto_obstack): Use
7581 DISABLE_COPY_AND_ASSIGN.
7582
7583 2020-02-11 Tom Tromey <tom@tromey.com>
7584
7585 * dwarf2/frame.h (struct objfile): Don't forward declare.
7586
7587 2020-02-11 Christian Biesinger <cbiesinger@google.com>
7588
7589 * cris-tdep.c (cris_supply_gregset): Change signature to match
7590 what struct regset expects.
7591 (cris_regset): New struct.
7592 (fetch_core_registers): Remove.
7593 (cris_iterate_over_regset_sections): New function.
7594 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
7595 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
7596
7597 2020-02-11 Christian Biesinger <cbiesinger@google.com>
7598
7599 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
7600 registers.
7601
7602 2020-02-11 Christian Biesinger <cbiesinger@google.com>
7603
7604 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
7605
7606 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
7607
7608 * configure: Re-generate.
7609
7610 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
7611
7612 * configure: Re-generate.
7613
7614 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
7615
7616 * acinclude: Update warning.m4 path.
7617 * warning.m4: Move to gdbsupport.
7618
7619 2020-02-11 Tom Tromey <tromey@adacore.com>
7620
7621 * remote.c (remote_console_output): Update.
7622 * printcmd.c (printf_command): Update.
7623 * event-loop.c (gdb_wait_for_event): Update.
7624 * linux-nat.c (sigchld_handler): Update.
7625 * remote-sim.c (gdb_os_write_stdout): Update.
7626 (gdb_os_flush_stdout): Update.
7627 (gdb_os_flush_stderr): Update.
7628 (gdb_os_write_stderr): Update.
7629 * exceptions.c (print_exception): Update.
7630 * remote-fileio.c (remote_fileio_func_read): Update.
7631 (remote_fileio_func_write): Update.
7632 * tui/tui.c (tui_enable): Update.
7633 * tui/tui-interp.c (tui_interp::init): Update.
7634 * utils.c (init_page_info): Update.
7635 (putchar_unfiltered, fputc_unfiltered): Update.
7636 (gdb_flush): Update.
7637 (emit_style_escape): Update.
7638 (flush_wrap_buffer, fputs_maybe_filtered): Update.
7639 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
7640 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
7641 (stderr_file::write): Update.
7642 (stderr_file::puts): Update.
7643 * ui-file.h (ui_file_isatty, ui_file_write)
7644 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
7645 (ui_file_puts): Don't declare.
7646
7647 2020-02-10 Tom de Vries <tdevries@suse.de>
7648
7649 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
7650 sentinel to char *.
7651
7652 2020-02-09 Tom de Vries <tdevries@suse.de>
7653
7654 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
7655 filename if it matches "<artificial>".
7656
7657 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
7658
7659 * windows-tdep.c (struct enum_value_name): New struct.
7660 (create_enum): New function.
7661 (windows_get_siginfo_type): Create and use enum types.
7662
7663 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
7664
7665 * NEWS: Mention $_siginfo support for Windows.
7666 * windows-nat.c (handle_exception): Set siginfo_er.
7667 (windows_nat_target::mourn_inferior): Reset siginfo_er.
7668 (windows_xfer_siginfo): New function.
7669 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
7670 * windows-tdep.c (struct windows_gdbarch_data): New struct.
7671 (init_windows_gdbarch_data): New function.
7672 (get_windows_gdbarch_data): New function.
7673 (windows_get_siginfo_type): New function.
7674 (windows_init_abi): Register windows_get_siginfo_type.
7675 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
7676
7677 2020-02-08 Tom Tromey <tom@tromey.com>
7678
7679 * dwarf2/read.c (class cutu_reader) <cutu_reader,
7680 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
7681 <keep>: Declare method.
7682 <m_keep>: Remove member.
7683 <~cutu_reader>: Remove.
7684 (cutu_reader::init_tu_and_read_dwo_dies): Update.
7685 (cutu_reader::cutu_reader): Update.
7686 (cutu_reader::keep): Rename from ~cutu_reader.
7687 (process_psymtab_comp_unit, build_type_psymtabs_1)
7688 (process_skeletonless_type_unit, load_partial_comp_unit)
7689 (load_full_comp_unit, dwarf2_read_addr_index)
7690 (read_signatured_type): Update.
7691
7692 2020-02-08 Tom Tromey <tom@tromey.com>
7693
7694 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
7695 "want_partial_unit" parameter.
7696 (process_psymtab_comp_unit): Change want_partial_unit to bool.
7697 Inline check for DW_TAG_partial_unit.
7698 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
7699
7700 2020-02-08 Tom Tromey <tom@tromey.com>
7701
7702 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
7703 read.c.
7704 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
7705 read.c.
7706
7707 2020-02-08 Tom Tromey <tom@tromey.com>
7708
7709 * dwarf2/read.c (read_address): Move to comp-unit.c.
7710 (dwarf2_rnglists_process, dwarf2_ranges_process)
7711 (read_attribute_value, dwarf_decode_lines_1)
7712 (var_decode_location, decode_locdesc): Update.
7713 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
7714 read.c. Remove "cu" parameter.
7715 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
7716 method.
7717
7718 2020-02-08 Tom Tromey <tom@tromey.com>
7719
7720 * dwarf2/read.c (read_attribute_value, read_indirect_string)
7721 (read_indirect_line_string): Update.
7722 * dwarf2/comp-unit.c (read_offset): Remove.
7723 (read_comp_unit_head): Update.
7724 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
7725 method.
7726 (read_offset): Don't declare.
7727
7728 2020-02-08 Tom Tromey <tom@tromey.com>
7729
7730 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
7731 * dwarf2/read.c (struct comp_unit_head): Move to
7732 dwarf2/comp-unit.h.
7733 (enum class rcuh_kind): Move to comp-unit.h.
7734 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
7735 (read_comp_unit_head, error_check_comp_unit_head)
7736 (read_and_check_comp_unit_head): Move to comp-unit.c.
7737 (read_offset, dwarf_unit_type_name): Likewise.
7738 (create_debug_type_hash_table, read_cutu_die_from_dwo)
7739 (cutu_reader::cutu_reader, read_call_site_scope)
7740 (find_partial_die, follow_die_offset): Update.
7741 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
7742
7743 2020-02-08 Tom Tromey <tom@tromey.com>
7744
7745 * dwarf2/read.c (read_offset_1): Move to leb.c.
7746 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
7747 (dwarf_decode_macro_bytes): Update.
7748 * dwarf2/leb.c (read_offset): Rename; move from read.c.
7749 * dwarf2/leb.h (read_offset): Declare.
7750
7751 2020-02-08 Tom Tromey <tom@tromey.com>
7752
7753 * dwarf2/read.c (dwarf2_section_size): Remove.
7754 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
7755 Update.
7756 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
7757
7758 2020-02-08 Tom Tromey <tom@tromey.com>
7759
7760 * dwarf2/read.c (read_initial_length): Move to leb.c.
7761 * dwarf2/leb.h (read_initial_length): Declare.
7762 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
7763 handle_nonstd parameter.
7764 * dwarf2/frame.c (read_initial_length): Remove.
7765 (decode_frame_entry_1): Update.
7766
7767 2020-02-08 Tom Tromey <tom@tromey.com>
7768
7769 * dwarf2/loc.c (dwarf2_find_location_expression)
7770 (dwarf_evaluate_loc_desc::get_tls_address)
7771 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
7772 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
7773 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
7774 (dwarf2_compile_property_to_c)
7775 (dwarf2_loc_desc_get_symbol_read_needs)
7776 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
7777 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
7778 (loclist_describe_location, loclist_tracepoint_var_ref)
7779 (loclist_generate_c_location): Update.
7780 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
7781 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
7782 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
7783 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
7784 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
7785 (dwarf2_per_cu_data::addr_size)
7786 (dwarf2_per_cu_data::ref_addr_size)
7787 (dwarf2_per_cu_data::text_offset)
7788 (dwarf2_per_cu_data::addr_type): Now methods.
7789 (per_cu_header_read_in): Make per_cu "const".
7790 (dwarf2_version): Remove.
7791 (dwarf2_per_cu_data::int_type): Now a method.
7792 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
7793 (set_die_type, read_array_type, read_subrange_index_type)
7794 (read_tag_string_type, read_subrange_type): Update.
7795 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
7796 offset_size, ref_addr_size, text_offset, addr_type, version,
7797 objfile, int_type, addr_sized_int_type>: Declare methods.
7798
7799 2020-02-08 Tom Tromey <tom@tromey.com>
7800
7801 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
7802 Move earlier.
7803
7804 2020-02-08 Tom Tromey <tom@tromey.com>
7805
7806 * dwarf2/read.h (dwarf_line_debug): Declare.
7807 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
7808 * dwarf2/read.c: Move line_header code to new files.
7809 (dwarf_line_debug): No longer static.
7810 * dwarf2/line-header.c: New file.
7811 * dwarf2/line-header.h: New file.
7812
7813 2020-02-08 Tom Tromey <tom@tromey.com>
7814
7815 * dwarf2/read.c (struct line_header) <file_full_name,
7816 file_file_name>: Return unique_xmalloc_ptr.
7817 (line_header::file_file_name): Update.
7818 (line_header::file_full_name): Update.
7819 (dw2_get_file_names_reader): Update.
7820 (macro_start_file): Update.
7821
7822 2020-02-08 Tom Tromey <tom@tromey.com>
7823
7824 * dwarf2/read.c (struct line_header) <file_full_name,
7825 file_file_name>: Declare methods.
7826 (dw2_get_file_names_reader): Update.
7827 (file_file_name): Now a method.
7828 (file_full_name): Likewise.
7829 (macro_start_file): Update.
7830
7831 2020-02-08 Tom Tromey <tom@tromey.com>
7832
7833 * dwarf2/read.c (dwarf_always_disassemble)
7834 (show_dwarf_always_disassemble): Move to loc.c.
7835 (_initialize_dwarf2_read): Move "always-disassemble" registration
7836 to loc.c.
7837 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
7838 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
7839 static.
7840 (show_dwarf_always_disassemble): Move from read.c.
7841 (_initialize_dwarf2loc): Move always-disassemble from read.c.
7842
7843 2020-02-08 Tom Tromey <tom@tromey.com>
7844
7845 * dwarf2/read.c (~dwarf2_per_objfile): Update.
7846 (create_quick_file_names_table): Return htab_up.
7847 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
7848 Update.
7849 * dwarf2/read.h (struct dwarf2_per_objfile)
7850 <quick_file_names_table>: Now htab_up.
7851
7852 2020-02-08 Tom Tromey <tom@tromey.com>
7853
7854 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
7855
7856 2020-02-08 Tom Tromey <tom@tromey.com>
7857
7858 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
7859 Rewrite.
7860 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
7861 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
7862 (abbrev_table::abbrev_table): No longer inline.
7863 (ABBREV_HASH_SIZE): Remove.
7864 (abbrev_table::m_abbrevs): Now an htab_up.
7865
7866 2020-02-08 Tom Tromey <tom@tromey.com>
7867
7868 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
7869 (cutu_reader): Update.
7870 (build_type_psymtabs_1): Update.
7871 * dwarf2/abbrev.c (abbrev_table::read): Rename.
7872 (abbrev_table::alloc_abbrev): Update.
7873 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
7874 (abbrev_table::read): New static method, renamed from
7875 abbrev_table_read_table.
7876 (abbrev_table::alloc_abbrev)
7877 (abbrev_table::add_abbrev): Now private.
7878 (abbrev_table::abbrev_table): Now private.
7879 (abbrev_table::m_abbrev_obstack): Now private. Rename.
7880
7881 2020-02-08 Tom Tromey <tom@tromey.com>
7882
7883 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
7884 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
7885 htab_up.
7886
7887 2020-02-08 Tom Tromey <tom@tromey.com>
7888
7889 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
7890 htab_up.
7891 (lookup_dwo_unit_in_dwp): Update.
7892 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
7893 on obstack.
7894
7895 2020-02-08 Tom Tromey <tom@tromey.com>
7896
7897 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
7898 obstack.
7899
7900 2020-02-08 Tom Tromey <tom@tromey.com>
7901
7902 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
7903 line_header_hash.
7904 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
7905 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
7906 Change type to htab_up.
7907
7908 2020-02-08 Tom Tromey <tom@tromey.com>
7909
7910 * dwarf2/read.c (allocate_type_unit_groups_table): Return
7911 htab_up. Don't allocate on obstack.
7912 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
7913 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
7914 Change type to htab_up.
7915
7916 2020-02-08 Tom Tromey <tom@tromey.com>
7917
7918 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
7919 Change type to htab_up.
7920 * dwarf2/read.c (create_signatured_type_table_from_index)
7921 (create_signatured_type_table_from_debug_names)
7922 (create_all_type_units, add_type_unit)
7923 (lookup_dwo_signatured_type, lookup_signatured_type)
7924 (process_skeletonless_type_unit): Update.
7925 (create_debug_type_hash_table, create_debug_types_hash_table):
7926 Change type of types_htab.
7927 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
7928 htab_up. Don't allocate on obstack.
7929 (create_cus_hash_table): Change type of cus_htab parameter.
7930 (struct dwo_file) <cus, tus>: Now htab_up.
7931 (lookup_dwo_signatured_type, lookup_dwo_cutu)
7932 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
7933 (queue_and_load_all_dwo_tus): Update.
7934 * dwarf2/index-write.c (write_gdbindex): Update.
7935 (write_debug_names): Update.
7936
7937 2020-02-08 Tom Tromey <tom@tromey.com>
7938
7939 * dwarf2/read.h (struct dwarf2_queue_item): Move from
7940 dwarf2/read.c. Remove "next" member. Add constructor ntad
7941 destructor.
7942 (struct dwarf2_per_objfile) <queue>: New member.
7943 * dwarf2/read.c (struct dwarf2_queue_item): Move to
7944 dwarf2/read.h.
7945 (dwarf2_queue, dwarf2_queue_tail): Remove.
7946 (class dwarf2_queue_guard): Add parameter to constructor. Use
7947 DISABLE_COPY_AND_ASSIGN.
7948 <m_per_objfile>: New member.
7949 <~dwarf2_queue_guard>: Rewrite.
7950 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
7951 Update.
7952 (~dwarf2_queue_item): New.
7953
7954 2020-02-08 Tom Tromey <tom@tromey.com>
7955
7956 * dwarf2/read.c (struct die_info) <has_children>: New member.
7957 (dw2_get_file_names_reader): Remove has_children.
7958 (dw2_get_file_names): Update.
7959 (read_cutu_die_from_dwo): Remove has_children.
7960 (cutu_reader::init_tu_and_read_dwo_dies)
7961 (cutu_reader::cutu_reader): Update.
7962 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
7963 Remove has_children.
7964 (build_type_psymtabs_1, process_skeletonless_type_unit)
7965 (load_partial_comp_unit, load_full_comp_unit): Update.
7966 (create_dwo_cu_reader): Remove has_children.
7967 (create_cus_hash_table, read_die_and_children): Update.
7968 (read_full_die_1,read_full_die): Remove has_children.
7969 (read_signatured_type): Update.
7970 (class cutu_reader) <has_children>: Remove.
7971
7972 2020-02-08 Tom Tromey <tom@tromey.com>
7973
7974 * dwarf2/expr.c: Rename from dwarf2expr.c.
7975 * dwarf2/expr.h: Rename from dwarf2expr.h.
7976 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
7977 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
7978 * dwarf2/frame.c: Rename from dwarf2-frame.c.
7979 * dwarf2/frame.h: Rename from dwarf2-frame.h.
7980 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
7981 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
7982 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
7983 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
7984 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
7985 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
7986 * dwarf2/loc.c: Rename from dwarf2loc.c.
7987 * dwarf2/loc.h: Rename from dwarf2loc.h.
7988 * dwarf2/read.c: Rename from dwarf2read.c.
7989 * dwarf2/read.h: Rename from dwarf2read.h.
7990 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
7991 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
7992 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
7993 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
7994 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
7995 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
7996 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
7997 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
7998 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
7999 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
8000 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
8001 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
8002 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
8003 Update.
8004 * Makefile.in (COMMON_SFILES): Update.
8005 (HFILES_NO_SRCDIR): Update.
8006
8007 2020-02-08 Tom Tromey <tom@tromey.com>
8008
8009 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
8010 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
8011
8012 2020-02-08 Tom Tromey <tom@tromey.com>
8013
8014 * dwarf2read.h (struct die_info): Don't declare.
8015
8016 2020-02-08 Tom Tromey <tom@tromey.com>
8017
8018 * dwarf2read.h (die_info_ptr): Remove typedef.
8019
8020 2020-02-08 Tom Tromey <tom@tromey.com>
8021
8022 * dwarf2read.c (read_call_site_scope)
8023 (handle_data_member_location, dwarf2_add_member_fn)
8024 (mark_common_block_symbol_computed, read_common_block)
8025 (attr_to_dynamic_prop, partial_die_info::read)
8026 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
8027 (dwarf2_symbol_mark_computed, set_die_type): Update.
8028 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
8029 method.
8030 (attr_form_is_block): Don't declare.
8031 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
8032
8033 2020-02-08 Tom Tromey <tom@tromey.com>
8034
8035 * dwarf2read.c (dwarf2_find_base_address, )
8036 (read_call_site_scope, rust_containing_type)
8037 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
8038 (handle_data_member_location, dwarf2_add_member_fn)
8039 (get_alignment, read_structure_type, process_structure_scope)
8040 (mark_common_block_symbol_computed, read_common_block)
8041 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
8042 (partial_die_info::read, read_attribute_value, new_symbol)
8043 (lookup_die_type, dwarf2_get_ref_die_offset)
8044 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
8045 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
8046 (dwarf2_symbol_mark_computed): Update.
8047 * dwarf2/attribute.h (struct attribute) <value_as_address,
8048 form_is_section_offset, form_is_constant, form_is_ref>: Declare
8049 methods.
8050 (value_as_address, attr_form_is_section_offset)
8051 (attr_form_is_constant, attr_form_is_ref): Don't declare.
8052 * dwarf2/attribute.c (attribute::value_as_address)
8053 (attribute::form_is_section_offset, attribute::form_is_constant)
8054 (attribute::form_is_ref): Now methods.
8055
8056 2020-02-08 Tom Tromey <tom@tromey.com>
8057
8058 * dwarf2read.c (struct attribute, DW_STRING)
8059 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
8060 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
8061 (attr_form_is_block, attr_form_is_section_offset)
8062 (attr_form_is_constant, attr_form_is_ref): Move.
8063 * dwarf2/attribute.h: New file.
8064 * dwarf2/attribute.c: New file, from dwarf2read.c.
8065 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
8066
8067 2020-02-08 Tom Tromey <tom@tromey.com>
8068
8069 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
8070 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
8071 Move.
8072 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
8073 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
8074 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
8075 abbrev.c.
8076 * dwarf2/abbrev.h: New file.
8077 * dwarf2/abbrev.c: New file, from dwarf2read.c.
8078 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
8079
8080 2020-02-08 Tom Tromey <tom@tromey.com>
8081
8082 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
8083 (dwarf2_section_size, dwarf2_get_section_info)
8084 (create_signatured_type_table_from_debug_names)
8085 (create_addrmap_from_aranges, read_debug_names_from_section)
8086 (get_gdb_index_contents_from_section, read_comp_unit_head)
8087 (error_check_comp_unit_head, read_abbrev_offset)
8088 (create_debug_type_hash_table, init_cu_die_reader)
8089 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
8090 (read_comp_units_from_section, create_cus_hash_table)
8091 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
8092 (create_dwp_v2_section, dwarf2_rnglists_process)
8093 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
8094 (abbrev_table_read_table, read_indirect_string_at_offset_from)
8095 (read_indirect_string_from_dwz, read_addr_index_1)
8096 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
8097 (dwarf_decode_macro_bytes, dwarf_decode_macros)
8098 (fill_in_loclist_baton): Update.
8099 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
8100 get_containing_section, get_bfd_owner, get_bfd_section,
8101 get_file_name, get_id, get_flags, empty, read>: Declare methods.
8102 (dwarf2_read_section, get_section_name, get_section_file_name)
8103 (get_containing_section, get_section_bfd_owner)
8104 (get_section_bfd_section, get_section_name, get_section_file_name)
8105 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
8106 declare.
8107 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
8108 (dwarf2_section_info::get_bfd_owner)
8109 (dwarf2_section_info::get_bfd_section)
8110 (dwarf2_section_info::get_name)
8111 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
8112 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
8113 (dwarf2_section_info::read): Now methods.
8114 * dwarf-index-write.c (class debug_names): Update.
8115
8116 2020-02-08 Tom Tromey <tom@tromey.com>
8117
8118 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
8119 Move to dwarf2/section.h.
8120 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
8121 (get_section_bfd_section, get_section_name)
8122 (get_section_file_name, get_section_id, get_section_flags)
8123 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
8124 dwarf2/section.c.
8125 * dwarf2/section.h: New file.
8126 * dwarf2/section.c: New file, from dwarf2read.c.
8127 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
8128
8129 2020-02-08 Tom Tromey <tom@tromey.com>
8130
8131 * dwarf2read.h (read_unsigned_leb128): Don't declare.
8132 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
8133 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
8134 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
8135 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
8136 * dwarf2/leb.h: New file, from dwarf2read.c.
8137 * dwarf2/leb.c: New file, from dwarf2read.c.
8138 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
8139 Remove.
8140 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
8141 (COMMON_SFILES): Add dwarf2/leb.c.
8142
8143 2020-02-08 Joel Brobecker <brobecker@adacore.com>
8144
8145 GDB 9.1 released.
8146
8147 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
8148
8149 PR gdb/25190:
8150 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
8151 * gdb/remote.c (remote_console_output): Update.
8152 * gdb/ui-file.c (fputs_unfiltered): Rename to...
8153 (ui_file_puts): ...this.
8154 * gdb/ui-file.h (ui_file_puts): Add declaration.
8155 * gdb/utils.c (emit_style_escape): Update.
8156 (flush_wrap_buffer): Update.
8157 (fputs_maybe_filtered): Update.
8158 (fputs_unfiltered): Add function.
8159
8160 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
8161
8162 * gdb/event-loop.c (gdb_wait_for_event): Update.
8163 * gdb/printcmd.c (printf_command): Update.
8164 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
8165 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
8166 (gdb_os_flush_stderr): Update.
8167 * gdb/remote.c (remote_console_output): Update.
8168 * gdb/ui-file.c (gdb_flush): Rename to...
8169 (ui_file_flush): ...this.
8170 (stderr_file::write): Update.
8171 (stderr_file::puts): Update.
8172 * gdb/ui-file.h (gdb_flush): Rename to...
8173 (ui_file_flush): ...this.
8174 * gdb/utils.c (gdb_flush): Add function.
8175 * gdb/utils.h (gdb_flush): Add declaration.
8176
8177 2020-02-07 Tom Tromey <tromey@adacore.com>
8178
8179 PR breakpoints/24915:
8180 * source.c (find_and_open_source): Do not check basenames_may_differ.
8181
8182 2020-02-07 Tom Tromey <tom@tromey.com>
8183
8184 * README: Update gdbserver documentation.
8185 * gdbserver: Move to top level.
8186 * configure.tgt (build_gdbserver): Remove.
8187 * configure.ac: Remove --enable-gdbserver.
8188 * configure: Rebuild.
8189 * Makefile.in (distclean): Don't mention gdbserver.
8190
8191 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
8192
8193 * source-cache.c (source_cache::ensure): Surround
8194 get_plain_source_lines with a try/catch.
8195 (source_cache::get_line_charpos): Get rid of try/catch
8196 and only check for the return value of "ensure".
8197 * tui/tui-source.c (tui_source_window::set_contents):
8198 Simplify "nlines" calculation.
8199
8200 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
8201
8202 * MAINTAINERS (Write After Approval): Add myself.
8203
8204 2020-02-05 Christian Biesinger <cbiesinger@google.com>
8205
8206 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
8207 function call.
8208
8209 2020-02-05 Christian Biesinger <cbiesinger@google.com>
8210
8211 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
8212
8213 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
8214
8215 * nat/riscv-linux-tdesc.h: New file.
8216 * nat/riscv-linux-tdesc.c: New file, taking code from...
8217 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
8218 ... here.
8219 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
8220 NATDEPFILES.
8221
8222 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
8223
8224 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
8225 we don't set the fake simulator ptid to the null_ptid.
8226
8227 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
8228
8229 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
8230 * gdbthread.h (class thread_info) <resumed>: Likewise.
8231 * infrun.c (resume_1): Likewise.
8232 (proceed): Likewise.
8233 (infrun_thread_stop_requested): Likewise.
8234 (stop_all_threads): Likewise.
8235 (handle_inferior_event): Likewise.
8236 (restart_threads): Likewise.
8237 (finish_step_over): Likewise.
8238 (keep_going_stepped_thread): Likewise.
8239 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
8240 (linux_handle_extended_wait): Likewise.
8241 * record-btrace.c (get_thread_current_frame_id): Likewise.
8242 * record-full.c (record_full_wait_1): Likewise.
8243 * remote.c (remote_target::process_initial_stop_replies): Likewise.
8244 * target.c (target_resume): Likewise.
8245 * thread.c (set_running_thread): Likewise.
8246
8247 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8248
8249 * f-valprint.c (f77_print_array_1): Changed datatype of index
8250 variable to LONGEST from int to enable it to contain bound
8251 values correctly.
8252
8253 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
8254
8255 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
8256 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
8257 offsets according to FLEN determined.
8258 (riscv_linux_nat_target::read_description): Determine FLEN
8259 dynamically.
8260 (riscv_linux_nat_target::fetch_registers): Size regset buffer
8261 according to FLEN determined.
8262 (riscv_linux_nat_target::store_registers): Likewise.
8263
8264 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
8265
8266 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
8267 when reg->group is empty and reggroup is not.
8268
8269 2020-01-31 Tom Tromey <tromey@adacore.com>
8270
8271 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
8272 Call beneath target's mourn_inferior after unpushing.
8273
8274 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
8275
8276 PR tui/9765
8277 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
8278 have enough lines to fill the screen, still return the lowest
8279 address we found.
8280
8281 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
8282
8283 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
8284 '-', '<', and '>' commands.
8285
8286 2020-01-29 Pedro Alves <palves@redhat.com>
8287 Sergio Durigan Junior <sergiodj@redhat.com>
8288
8289 * infcmd.c (construct_inferior_arguments): Assert that
8290 'argc' is greater than 0.
8291
8292 2020-01-29 Luis Machado <luis.machado@linaro.org>
8293
8294 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
8295 (BRK_INSN_MASK): Define to 0xd4200000.
8296 (aarch64_program_breakpoint_here_p): New function.
8297 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
8298 * arch-utils.c (default_program_breakpoint_here_p): Moved from
8299 breakpoint.c.
8300 * arch-utils.h (default_program_breakpoint_here_p): Moved from
8301 breakpoint.h
8302 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
8303 call gdbarch_program_breakpoint_here_p.
8304 (program_breakpoint_here): Moved to arch-utils.c, renamed to
8305 default_program_breakpoint_here_p, changed return type to bool and
8306 simplified.
8307 * breakpoint.h (program_breakpoint_here): Moved prototype to
8308 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
8309 return type to bool.
8310 * gdbarch.c: Regenerate.
8311 * gdbarch.h: Regenerate.
8312 * gdbarch.sh (program_breakpoint_here_p): New method.
8313 * infrun.c (handle_signal_stop): Call
8314 gdbarch_program_breakpoint_here_p.
8315
8316 2020-01-26 Tom Tromey <tom@tromey.com>
8317
8318 * ctfread.c (struct ctf_fp_info): Reindent.
8319 (_initialize_ctfread): Remove.
8320
8321 2020-01-26 Tom Tromey <tom@tromey.com>
8322
8323 * psymtab.c (partial_map_expand_apply)
8324 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
8325 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
8326 (psym_print_stats, psym_expand_symtabs_for_function)
8327 (psym_map_symbol_filenames, psym_map_matching_symbols)
8328 (psym_expand_symtabs_matching)
8329 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
8330 (maintenance_check_psymtabs): Use new methods.
8331 * psympriv.h (struct partial_symtab) <readin_p,
8332 get_compunit_symtab>: New methods.
8333 <readin, compunit_symtab>: Remove members.
8334 (struct standard_psymtab): New.
8335 (struct legacy_psymtab): Derive from standard_psymtab.
8336 * dwarf2read.h (struct dwarf2_psymtab): Derive from
8337 standard_psymtab.
8338 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
8339
8340 2020-01-26 Tom Tromey <tom@tromey.com>
8341
8342 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
8343 read_dependencies. Add assert.
8344 * psymtab.c (partial_symtab::read_dependencies): New method.
8345 * psympriv.h (struct partial_symtab) <read_dependencies>: New
8346 method.
8347 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
8348 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
8349 read_dependencies.
8350 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
8351 Add assert.
8352
8353 2020-01-26 Tom Tromey <tom@tromey.com>
8354
8355 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
8356 Call expand_psymtab.
8357 (xcoff_read_symtab): Call expand_psymtab.
8358 (xcoff_start_psymtab, xcoff_end_psymtab): Set
8359 legacy_expand_psymtab.
8360 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
8361 method.
8362 (struct legacy_psymtab) <expand_psymtab>: Implement.
8363 <legacy_expand_psymtab>: New member.
8364 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
8365 (parse_partial_symbols): Set legacy_expand_psymtab.
8366 (psymtab_to_symtab_1): Change argument order. Call
8367 expand_psymtab.
8368 (new_psymtab): Set legacy_expand_psymtab.
8369 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
8370 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
8371 expand_psymtab.
8372 (dwarf2_psymtab::expand_psymtab): Rename from
8373 psymtab_to_symtab_1. Call expand_psymtab.
8374 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
8375 (dbx_end_psymtab): Likewise.
8376 (dbx_psymtab_to_symtab_1): Change argument order. Call
8377 expand_psymtab.
8378 (dbx_read_symtab): Call expand_psymtab.
8379 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
8380 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
8381 (ctf_psymtab::read_symtab): Call expand_psymtab.
8382
8383 2020-01-26 Tom Tromey <tom@tromey.com>
8384
8385 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
8386 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
8387 messages.
8388 * mdebugread.c (mdebug_read_symtab): Remove prints.
8389 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
8390 assert.
8391 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
8392
8393 2020-01-26 Tom Tromey <tom@tromey.com>
8394
8395 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
8396 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
8397 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
8398 legacy_symtab.
8399 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
8400 * psymtab.c (psymtab_to_symtab): Call method.
8401 (dump_psymtab): Update.
8402 * psympriv.h (struct partial_symtab): Add virtual destructor.
8403 <read_symtab>: New method.
8404 (struct legacy_symtab): New.
8405 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
8406 (struct pst_map) <pst>: Now a legacy_psymtab.
8407 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
8408 (new_psymtab): Use legacy_psymtab.
8409 * dwarf2read.h (struct dwarf2_psymtab): New.
8410 (struct dwarf2_per_cu_data) <psymtab>: Use it.
8411 * dwarf2read.c (dwarf2_create_include_psymtab)
8412 (dwarf2_build_include_psymtabs, create_type_unit_group)
8413 (create_partial_symtab, process_psymtab_comp_unit_reader)
8414 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
8415 (set_partial_user): Use dwarf2_psymtab.
8416 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
8417 (psymtab_to_symtab_1, process_full_comp_unit)
8418 (process_full_type_unit, dwarf2_ranges_read)
8419 (dwarf2_get_pc_bounds, psymtab_include_file_name)
8420 (dwarf_decode_lines): Use dwarf2_psymtab.
8421 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
8422 (add_address_entry_worker, write_one_signatured_type)
8423 (recursively_count_psymbols, recursively_write_psymbols)
8424 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
8425 (write_debug_names): Likewise.
8426 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
8427 <pst>: Now a legacy_psymtab.
8428 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
8429 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
8430 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
8431 * ctfread.c (struct ctf_psymtab): New.
8432 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
8433 ctf_psymtab.
8434 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
8435 (create_partial_symtab): Return a ctf_psymtab.
8436 (scan_partial_symbols): Update.
8437
8438 2020-01-26 Tom Tromey <tom@tromey.com>
8439
8440 * xcoffread.c (xcoff_start_psymtab): Use new.
8441 * psymtab.c (partial_symtab::partial_symtab): New constructor,
8442 renamed from start_psymtab_common.
8443 * psympriv.h (struct partial_symtab): Add new constructor.
8444 (start_psymtab_common): Don't declare.
8445 * mdebugread.c (parse_partial_symbols): Use new.
8446 * dwarf2read.c (create_partial_symtab): Use new.
8447 * dbxread.c (start_psymtab): Use new.
8448 * ctfread.c (create_partial_symtab): Use new.
8449
8450 2020-01-26 Tom Tromey <tom@tromey.com>
8451
8452 * xcoffread.c (xcoff_end_psymtab): Use new.
8453 * psymtab.c (start_psymtab_common): Use new.
8454 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
8455 Update.
8456 * psympriv.h (struct partial_symtab): Add parameters to
8457 constructor. Don't inline.
8458 (allocate_psymtab): Don't declare.
8459 * mdebugread.c (new_psymtab): Use new.
8460 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
8461 * dbxread.c (dbx_end_psymtab): Use new.
8462
8463 2020-01-26 Tom Tromey <tom@tromey.com>
8464
8465 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
8466 allocate_psymtab. Update documentation.
8467 * psymtab.c (psymtab_storage::install_psymtab): Rename from
8468 allocate_psymtab. Do not use new.
8469 (allocate_psymtab): Use new. Update.
8470
8471 2020-01-26 Tom Tromey <tom@tromey.com>
8472
8473 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
8474 * psymtab.c (psym_print_stats): Update.
8475 * psympriv.h (struct partial_symtab) <readin,
8476 psymtabs_addrmap_supported, anonymous>: Now bool.
8477 * mdebugread.c (psymtab_to_symtab_1): Update.
8478 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
8479 (build_type_psymtabs_reader, psymtab_to_symtab_1)
8480 (process_full_comp_unit, process_full_type_unit): Update.
8481 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
8482 * ctfread.c (psymtab_to_symtab): Update.
8483
8484 2020-01-26 Tom Tromey <tom@tromey.com>
8485
8486 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
8487 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
8488 * psymtab.c (psymtab_storage): Delete psymtabs.
8489 (psymtab_storage::allocate_psymtab): Use new.
8490 (psymtab_storage::discard_psymtab): Use delete.
8491 * psympriv.h (struct partial_symtab): Add constructor and
8492 initializers.
8493
8494 2020-01-26 Tom Tromey <tom@tromey.com>
8495
8496 * machoread.c: Do not include psympriv.h.
8497
8498 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8499
8500 * NEWS: Mention the new option and the set/show commands.
8501
8502 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8503
8504 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
8505 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
8506 (validate_exec_file): New variables, enums, functions.
8507 (exec_file_locate_attach, print_section_info): Style the filenames.
8508 (_initialize_exec): Install show_exec_file_mismatch_command and
8509 set_exec_file_mismatch_command.
8510 * gdbcore.h (validate_exec_file): Declare.
8511 * infcmd.c (attach_command): Call validate_exec_file.
8512 * remote.c ( remote_target::remote_add_inferior): Likewise.
8513
8514 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
8515
8516 * frame.c (find_frame_sal): Move call to get_next_frame into more
8517 inner scope.
8518 * inline-frame.c (inilne_state) <inline_state>: Update argument
8519 types.
8520 (inilne_state) <skipped_symbol>: Rename to...
8521 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
8522 (skip_inline_frames): Build vector of skipped symbols and use this
8523 to reate the inline_state.
8524 (inline_skipped_symbol): Add a comment and some assertions, fetch
8525 skipped symbol from the list.
8526
8527 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
8528
8529 * buildsym.c (lte_is_less_than): Delete.
8530 (buildsym_compunit::end_symtab_with_blockvector): Create local
8531 lambda function to sort line table entries, and use
8532 std::stable_sort instead of std::sort.
8533 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
8534 markers when looking for a previous line.
8535
8536 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
8537
8538 * dwarf2read.c (lnp_state_machine::record_line): Include
8539 end_sequence parameter in debug print out. Record the line if we
8540 are at an end_sequence marker even if it's not the start of a
8541 statement.
8542 * symmisc.c (maintenance_print_one_line_table): Print end of
8543 sequence markers with 'END' not '0'.
8544
8545 2020-01-24 Pedro Alves <palves@redhat.com>
8546
8547 PR gdb/25410
8548 * thread.c (scoped_restore_current_thread::restore): Use
8549 switch_to_inferior_no_thread.
8550 * exec.c: Include "progspace-and-thread.h".
8551 (add_target_sections, remove_target_sections):
8552 scoped_restore_current_pspace_and_thread instead of
8553 scoped_restore_current_thread.
8554 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
8555 and aspace to the inferior before calling clone_program_space.
8556 Remove stale comment.
8557
8558 2020-01-24 Christian Biesinger <cbiesinger@google.com>
8559
8560 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
8561 (arm_netbsd_nat_target::fetch_registers): ...this.
8562 (arm_nbsd_nat_target::store_registers): Rename to...
8563 (arm_netbsd_nat_target::store_registers): ...this.
8564
8565 2020-01-24 Christian Biesinger <cbiesinger@google.com>
8566
8567 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
8568 register_t.
8569
8570 2020-01-24 Christian Biesinger <cbiesinger@google.com>
8571
8572 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
8573 Update comment.
8574 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
8575 Likewise.
8576 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
8577 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
8578 the correct replacement (iterate_over_regset_sections).
8579 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
8580 Update comment.
8581
8582 2020-01-24 Graham Markall <graham.markall@embecosm.com>
8583
8584 PR gdb/23718
8585 * gdb/python/python.c (execute_gdb_command): Call
8586 async_enable_stdin in catch block.
8587
8588 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
8589
8590 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
8591 SWITCH_THRU_ALL_UIS.
8592
8593 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
8594
8595 PR tui/9765
8596 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
8597 comment, add extra parameter, and update to store previous symbol
8598 when appropriate.
8599 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
8600 add extra parameter.
8601 * tui/tui-disasm.c (tui_disassemble): Update header comment,
8602 remove unneeded parameter, add try/catch around gdb_print_insn,
8603 rewrite to add items to asm_lines vector.
8604 (tui_find_backward_disassembly_start_address): New function.
8605 (tui_find_disassembly_address): Updated throughout.
8606 (tui_disasm_window::set_contents): Update for changes to
8607 tui_disassemble.
8608 (tui_disasm_window::do_scroll_vertical): No need to adjust the
8609 number of lines to scroll.
8610
8611 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
8612
8613 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
8614 (SECT_OFF_DATA): Likewise.
8615 (SECT_OFF_RODATA): Likewise.
8616 (SECT_OFF_TEXT): Likewise.
8617 (SECT_OFF_BSS): Likewise.
8618 (struct objfile) <text_section_offset, data_section_offset>: New
8619 methods.
8620 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
8621 objfile::text_section_offset.
8622 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
8623 * coffread.c (coff_symtab_read): Likewise.
8624 (enter_linenos): Likewise.
8625 (process_coff_symbol): Likewise.
8626 * ctfread.c (get_objfile_text_range): Likewise.
8627 * dtrace-probe.c (dtrace_probe::get_relocated_address):
8628 Use objfile::data_section_offset.
8629 * dwarf2-frame.c (execute_cfa_program): Use
8630 objfile::text_section_offset.
8631 (dwarf2_frame_find_fde): Likewise.
8632 * dwarf2read.c (create_addrmap_from_index): Likewise.
8633 (create_addrmap_from_aranges): Likewise.
8634 (dw2_find_pc_sect_compunit_symtab): Likewise.
8635 (process_psymtab_comp_unit_reader): Likewise.
8636 (add_partial_symbol): Likewise.
8637 (add_partial_subprogram): Likewise.
8638 (process_full_comp_unit): Likewise.
8639 (read_file_scope): Likewise.
8640 (read_func_scope): Likewise.
8641 (read_lexical_block_scope): Likewise.
8642 (read_call_site_scope): Likewise.
8643 (dwarf2_rnglists_process): Likewise.
8644 (dwarf2_ranges_process): Likewise.
8645 (dwarf2_ranges_read): Likewise.
8646 (dwarf_decode_lines_1): Likewise.
8647 (new_symbol): Likewise.
8648 (dwarf2_fetch_die_loc_sect_off): Likewise.
8649 (dwarf2_per_cu_text_offset): Likewise.
8650 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
8651 * hppa-tdep.c (read_unwind_info): Likewise.
8652 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
8653 * psympriv.h (struct partial_symtab): Likewise.
8654 * psymtab.c (find_pc_sect_psymtab): Likewise.
8655 * solib-svr4.c (enable_break): Likewise.
8656 * stap-probe.c (relocate_address): Use
8657 objfile::data_section_offset.
8658 * xcoffread.c (enter_line_range): Use
8659 objfile::text_section_offset.
8660 (read_xcoff_symtab): Likewise.
8661
8662 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
8663
8664 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
8665 declaration to narrower scopes.
8666
8667 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
8668
8669 * darwin-nat.h (struct darwin_exception_msg, enum
8670 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
8671 Move up.
8672 (class darwin_nat_target) <wait_1, check_new_threads,
8673 decode_exception_message, decode_message, stop_inferior,
8674 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
8675 * darwin-nat.c (darwin_check_new_threads): Rename to...
8676 (darwin_nat_target::check_new_threads): ... this.
8677 (darwin_suspend_inferior_it): Remove.
8678 (darwin_decode_exception_message): Rename to...
8679 (darwin_nat_target::decode_exception_message): ... this.
8680 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
8681 (darwin_decode_message): Rename to...
8682 (darwin_nat_target::decode_message): ... this.
8683 (cancel_breakpoint): Rename to...
8684 (darwin_nat_target::cancel_breakpoint): ... this.
8685 (darwin_wait): Rename to...
8686 (darwin_nat_target::wait_1): ... this. Use range-based for loop
8687 instead of iterate_over_inferiors.
8688 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
8689 (darwin_stop_inferior): Rename to...
8690 (darwin_nat_target::stop_inferior): ... this.
8691 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
8692 (darwin_init_thread_list): Rename to...
8693 (darwin_nat_target::init_thread_list): ... this.
8694 (darwin_ptrace_him): Rename to...
8695 (darwin_nat_target::ptrace_him): ... this.
8696 (darwin_nat_target::create_inferior): Pass lambda function to
8697 fork_inferior.
8698 (darwin_nat_target::detach): Call stop_inferior instead of
8699 darwin_stop_inferior.
8700 * fork-inferior.h (fork_inferior): Change init_trace_fun
8701 parameter to gdb::function_view.
8702 * fork-inferior.c (fork_inferior): Likewise.
8703
8704 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
8705
8706 * i386-cygwin-tdep.c (core_process_module_section): Update.
8707 * windows-nat.c (struct lm_info_windows): Add text_offset.
8708 (windows_xfer_shared_libraries): Update.
8709 * windows-tdep.c (windows_xfer_shared_library):
8710 Add text_offset_cached argument.
8711 * windows-tdep.h (windows_xfer_shared_library): Update.
8712
8713 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
8714
8715 * gdbarch.sh: Add declaration for _initialize_gdbarch.
8716
8717 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
8718
8719 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
8720 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
8721 replace with range-based for.
8722 (gdbsim_interrupt_inferior): Remove.
8723 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
8724 with a range-based for. Inline code from
8725 gdbsim_interrupt_inferior.
8726
8727 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
8728
8729 * infrun.c (proceed): Fix indentation.
8730
8731 2020-01-21 Tom Tromey <tromey@adacore.com>
8732
8733 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
8734 * python/python.c (python_extension_ops): Update.
8735 (gdbpy_colorize): New function.
8736 * python/lib/gdb/__init__.py (colorize): New function.
8737 * extension.h (ext_lang_colorize): Declare.
8738 * extension.c (ext_lang_colorize): New function.
8739 * extension-priv.h (struct extension_language_ops) <colorize>: New
8740 member.
8741 * cli/cli-style.c (_initialize_cli_style): Update help text.
8742
8743 2020-01-21 Luis Machado <luis.machado@linaro.org>
8744
8745 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
8746 <cond>: Change type to bool.
8747 (aarch64_displaced_step_b_cond): Update cond to use bool type.
8748 (aarch64_displaced_step_cb): Likewise.
8749 (aarch64_displaced_step_tb): Likewise.
8750
8751 2020-01-21 Luis Machado <luis.machado@linaro.org>
8752
8753 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
8754 output.
8755
8756 2020-01-21 Luis Machado <luis.machado@linaro.org>
8757
8758 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
8759 <pc_adjust>: Adjust the documentation.
8760 (aarch64_displaced_step_fixup): Check if PC really moved before
8761 adjusting it.
8762
8763 2020-01-19 Tom Tromey <tom@tromey.com>
8764
8765 * disasm.c (~gdb_disassembler): New destructor.
8766 (gdb_buffered_insn_length): Call disassemble_free_target.
8767 * disasm.h (class gdb_disassembler): Declare destructor. Use
8768 DISABLE_COPY_AND_ASSIGN.
8769
8770 2020-01-19 Tom Tromey <tom@tromey.com>
8771
8772 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
8773 (die_reader_func_ftype): Remove.
8774 (cutu_reader): New class.
8775 (dw2_get_file_names_reader): Remove "data" parameter.
8776 (dw2_get_file_names): Use cutu_reader.
8777 (create_debug_type_hash_table): Update.
8778 (read_cutu_die_from_dwo): Update comment.
8779 (lookup_dwo_unit): Add dwo_name parameter.
8780 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
8781 die_reader_func_ftype and data parameters.
8782 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
8783 Remove die_reader_func_ftype and data parameters.
8784 (~cutu_reader): New; from init_cutu_and_read_dies.
8785 (cutu_reader::cutu_reader): Rename from
8786 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
8787 and data parameters.
8788 (init_cutu_and_read_dies_simple): Remove.
8789 (struct process_psymtab_comp_unit_data): Remove.
8790 (process_psymtab_comp_unit_reader): Remove data parameter; add
8791 want_partial_unit and pretend_language parameters.
8792 (process_psymtab_comp_unit): Use cutu_reader.
8793 (build_type_psymtabs_reader): Remove data parameter.
8794 (build_type_psymtabs_1): Use cutu_reader.
8795 (process_skeletonless_type_unit): Likewise.
8796 (load_partial_comp_unit_reader): Remove.
8797 (load_partial_comp_unit): Use cutu_reader.
8798 (load_full_comp_unit_reader): Remove.
8799 (load_full_comp_unit): Use cutu_reader.
8800 (struct create_dwo_cu_data): Remove.
8801 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
8802 dwo_unit parameters.
8803 (create_cus_hash_table): Use cutu_reader.
8804 (struct dwarf2_read_addr_index_data): Remove.
8805 (dwarf2_read_addr_index_reader): Remove.
8806 (dwarf2_read_addr_index): Use cutu_reader.
8807 (read_signatured_type_reader): Remove.
8808 (read_signatured_type): Use cutu_reader.
8809
8810 2020-01-19 Tom Tromey <tom@tromey.com>
8811
8812 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
8813 * tui/tui-wingeneral.h (class tui_suppress_output): New.
8814 (tui_wrefresh): Declare.
8815 * tui/tui-wingeneral.c (suppress_output): New global.
8816 (tui_suppress_output, ~tui_suppress_output): New constructor and
8817 destructor.
8818 (tui_wrefresh): New function.
8819 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
8820 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
8821 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
8822 method.
8823 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
8824 tui_wrefresh.
8825 (tui_data_window::no_refresh): New method.
8826 (tui_data_item_window::refresh_window): Call tui_wrefresh.
8827 (tui_reg_command): Use tui_suppress_output
8828 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
8829 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
8830 method.
8831 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
8832
8833 2020-01-19 Tom Tromey <tom@tromey.com>
8834
8835 * tui/tui-winsource.c (tui_update_source_windows_with_line):
8836 Handle case where symtab is null.
8837
8838 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
8839
8840 * linux-fork.c (one_fork_p): Simplify.
8841
8842 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
8843
8844 * top.c (struct qt_args): Remove.
8845 (kill_or_detach): Change return type to void, replace `void *`
8846 parameter with a proper one.
8847 (print_inferior_quit_action): Likewise.
8848 (quit_confirm): Use range-based for loop to iterate over inferiors.
8849 (quit_force): Likewise.
8850
8851 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
8852
8853 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
8854 `void *` parameter with proper parameters.
8855 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
8856 (print_one_inferior): Change return type to void, replace `void *`
8857 parameter with proper parameters.
8858 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
8859 inferiors.
8860 (get_other_inferior): Remove.
8861 (mi_cmd_remove_inferior): Use range-based loop to iterate over
8862 inferiors.
8863
8864 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
8865
8866 * mi/mi-interp.c (report_initial_inferior): Remove.
8867 (mi_interp::init): Use range-based for to iterate over inferiors.
8868
8869 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
8870
8871 * python/py-inferior.c (build_inferior_list): Remove.
8872 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
8873
8874 2020-01-16 Christian Biesinger <cbiesinger@google.com>
8875
8876 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
8877 (btrace_stitch_trace): Likewise.
8878 * charset.c (intermediate_encoding): Likewise (vaild).
8879 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
8880 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
8881 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
8882
8883 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
8884
8885 * windows-tdep.c (windows_get_tlb_type):
8886 Add rtl_user_process_parameters type.
8887
8888 2020-01-16 Pedro Alves <palves@redhat.com>
8889 Norbert Lange <nolange79@gmail.com>
8890
8891 PR build/24805
8892 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
8893 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
8894 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
8895 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
8896 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
8897 (ps_plog): Redeclare exported functions with default visibility.
8898
8899 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
8900
8901 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
8902 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
8903
8904 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
8905
8906 * infcmd.c (post_create_inferior): Use get_thread_regcache
8907 instead of get_current_regcache.
8908
8909 2020-01-14 Tom Tromey <tom@tromey.com>
8910
8911 PR symtab/12535:
8912 * python/python.c (gdbpy_decode_line): Treat empty string the same
8913 as no argument.
8914
8915 2020-01-14 Tom Tromey <tom@tromey.com>
8916
8917 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
8918
8919 2020-01-14 Tom Tromey <tom@tromey.com>
8920
8921 * nat/linux-btrace.c: Don't include <config.h>.
8922 * nat/linux-ptrace.c: Don't include <config.h>.
8923 * nat/x86-linux-dregs.c: Don't include <config.h>.
8924
8925 2020-01-14 Tom Tromey <tom@tromey.com>
8926
8927 * configure: Rebuild.
8928 * configure.ac: Move many checks to ../gdbsupport/common.m4.
8929
8930 2020-01-14 Tom Tromey <tom@tromey.com>
8931
8932 * nat/x86-linux-dregs.c: Include configh.h.
8933 * nat/linux-ptrace.c: Include configh.h.
8934 * nat/linux-btrace.c: Include configh.h.
8935 * defs.h: Include config.h, bfd.h.
8936 * configure.ac: Don't source common.host.
8937 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
8938 * configure: Rebuild.
8939 * acinclude.m4: Update path.
8940 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
8941 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
8942 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
8943 (CLIBS): Add LIBSUPPORT.
8944 (CDEPS): Likewise.
8945 (COMMON_SFILES): Remove gdbsupport files.
8946 (HFILES_NO_SRCDIR): Likewise.
8947 (stamp-version): Update path to create-version.sh.
8948 (ALLDEPFILES): Remove gdbsupport files.
8949
8950 2020-01-14 Tom Tromey <tom@tromey.com>
8951
8952 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
8953 USE_WIN32API when needed.
8954 * configure.ac (USE_WIN32API): Don't define.
8955 (WIN32LIBS): Use WIN32APILIBS.
8956 * configure: Rebuild.
8957
8958 2020-01-14 Tom Tromey <tom@tromey.com>
8959
8960 * configure: Rebuild.
8961 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
8962
8963 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
8964
8965 * skip.c (skip_function_command): Make skip w/o arguments use the
8966 name of the inlined function if pc is inside any inlined function.
8967
8968 2020-01-14 Luis Machado <luis.machado@linaro.org>
8969
8970 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
8971 * infrun.c (resume_1): Likewise.
8972 (handle_inferior_event): Remove stale comment.
8973 * linux-nat.c (linux_nat_target::resume): Update comments.
8974 (save_stop_reason): Likewise.
8975 (linux_nat_filter_event): Likewise.
8976 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
8977
8978 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
8979
8980 * elfread.c (record_minimal_symbol): Set section index to 0 for
8981 non-allocatable sections.
8982
8983
8984 2020-01-13 Ali Tamur <tamur@google.com>
8985
8986 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
8987 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
8988 to gdb::optional. Update comments.
8989 (dwo_file): Update comments.
8990 (read_attribute): Update API to take an additional out parameter,
8991 need_reprocess. This is used to mark attributes that need other
8992 attributes (e.g. str_offsets_base) for correct computation which may not
8993 have been read yet.
8994 (read_attribute_reprocess): New function declaration.
8995 (read_addr_index): Likewise.
8996 (read_dwo_str_index): Likewise.
8997 (read_stub_str_index): Likewise.
8998 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
8999 (lookup_addr_base): New function definition.
9000 (lookup_ranges_base): Likewise.
9001 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
9002 lookup_ranges_base.
9003 (init_cutu_and_read_dies): Update comments.
9004 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
9005 unit. This is used to inherit parent's str_offsets_base and addr_base.
9006 Update comments.
9007 (init_cutu_and_read_dies_simple): Reflect API changes.
9008 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
9009 (create_cus_hash_table): Change API to take parent compile unit.
9010 Reflect API changes.
9011 (open_and_init_dwo_file): Reflect API changes.
9012 (dwarf2_get_pc_bounds): Update comments.
9013 (dwarf2_record_block_ranges): Likewise.
9014 (read_full_die_1): Change implementation to reprocess attributes that
9015 need str_offsets_base and addr_base.
9016 (partial_die_info::read): Likewise.
9017 (read_attribute_reprocess): New function definition.
9018 (read_attribute_value): Change API to take an additional out parameter,
9019 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
9020 when a non-dwo compile unit has index based attributes.
9021 (read_attribute): Reflect API changes.
9022 (read_addr_index_1): Reflect API changes. Update comments.
9023 (dwarf2_read_addr_index_data): Reflect API changes.
9024 (dwarf2_read_addr_index): Likewise.
9025 (read_str_index): Change API and implementation. This becomes a helper
9026 to be used by the new string index related methods. Update error
9027 message and comments.
9028 (read_dwo_str_index): New function definition.
9029 (read_stub_str_index): Likewise.
9030 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
9031 * symfile.h (dwarf2_debug_sections): Likewise.
9032 * xcoffread.c (dwarf2_debug_sections): Likewise.
9033
9034 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9035
9036 * gdbcore.h (struct core_fns) <core_read_registers>: Change
9037 core_reg_sect type to gdb_byte *.
9038 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
9039 * cris-tdep.c (fetch_core_registers): Likewise.
9040 * corelow.c (core_target::get_core_register_section): Change
9041 type of `contents` to gdb::byte_vector.
9042
9043 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9044
9045 * tui/tui-wingeneral.c (box_win): Position the title in the center
9046 of the border.
9047
9048 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9049
9050 * corelow.c (core_target::get_core_register_section): Use
9051 std::vector instead of alloca.
9052
9053 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9054
9055 * warning.m4: Add -Wmissing-declarations to build_warnings.
9056 * configure: Re-generate.
9057
9058 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9059
9060 * python/python.c (init__gdb_module): Add declaration.
9061
9062 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9063
9064 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
9065 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
9066 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
9067 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
9068 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
9069 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
9070 * ada-exp.y (_initialize_ada_exp): Add declaration.
9071 * ada-lang.c (_initialize_ada_language): Add declaration.
9072 * ada-tasks.c (_initialize_tasks): Add declaration.
9073 * agent.c (_initialize_agent): Add declaration.
9074 * aix-thread.c (_initialize_aix_thread): Add declaration.
9075 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
9076 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
9077 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
9078 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
9079 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
9080 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
9081 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
9082 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
9083 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
9084 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
9085 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
9086 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
9087 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
9088 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
9089 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
9090 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
9091 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
9092 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
9093 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
9094 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
9095 * annotate.c (_initialize_annotate): Add declaration.
9096 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
9097 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
9098 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
9099 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
9100 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
9101 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
9102 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
9103 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
9104 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
9105 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
9106 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
9107 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
9108 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
9109 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
9110 * auto-load.c (_initialize_auto_load): Add declaration.
9111 * auxv.c (_initialize_auxv): Add declaration.
9112 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
9113 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
9114 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
9115 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
9116 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
9117 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
9118 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
9119 * breakpoint.c (_initialize_breakpoint): Add declaration.
9120 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
9121 * btrace.c (_initialize_btrace): Add declaration.
9122 * charset.c (_initialize_charset): Add declaration.
9123 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
9124 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
9125 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
9126 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
9127 * cli/cli-script.c (_initialize_cli_script): Add declaration.
9128 * cli/cli-style.c (_initialize_cli_style): Add declaration.
9129 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
9130 * coffread.c (_initialize_coffread): Add declaration.
9131 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
9132 * compile/compile.c (_initialize_compile): Add declaration.
9133 * complaints.c (_initialize_complaints): Add declaration.
9134 * completer.c (_initialize_completer): Add declaration.
9135 * copying.c (_initialize_copying): Add declaration.
9136 * corefile.c (_initialize_core): Add declaration.
9137 * corelow.c (_initialize_corelow): Add declaration.
9138 * cp-abi.c (_initialize_cp_abi): Add declaration.
9139 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
9140 * cp-support.c (_initialize_cp_support): Add declaration.
9141 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
9142 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
9143 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
9144 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
9145 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
9146 * ctfread.c (_initialize_ctfread): Add declaration.
9147 * d-lang.c (_initialize_d_language): Add declaration.
9148 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
9149 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
9150 * dbxread.c (_initialize_dbxread): Add declaration.
9151 * dcache.c (_initialize_dcache): Add declaration.
9152 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
9153 * disasm.c (_initialize_disasm): Add declaration.
9154 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
9155 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
9156 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
9157 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
9158 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
9159 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
9160 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
9161 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
9162 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
9163 * elfread.c (_initialize_elfread): Add declaration.
9164 * exec.c (_initialize_exec): Add declaration.
9165 * extension.c (_initialize_extension): Add declaration.
9166 * f-lang.c (_initialize_f_language): Add declaration.
9167 * f-valprint.c (_initialize_f_valprint): Add declaration.
9168 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
9169 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
9170 * filesystem.c (_initialize_filesystem): Add declaration.
9171 * findcmd.c (_initialize_mem_search): Add declaration.
9172 * findvar.c (_initialize_findvar): Add declaration.
9173 * fork-child.c (_initialize_fork_child): Add declaration.
9174 * frame-base.c (_initialize_frame_base): Add declaration.
9175 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
9176 * frame.c (_initialize_frame): Add declaration.
9177 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
9178 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
9179 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
9180 * gcore.c (_initialize_gcore): Add declaration.
9181 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
9182 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
9183 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
9184 * gdbarch.c (_initialize_gdbarch): Add declaration.
9185 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
9186 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
9187 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
9188 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
9189 * go-lang.c (_initialize_go_language): Add declaration.
9190 * go32-nat.c (_initialize_go32_nat): Add declaration.
9191 * guile/guile.c (_initialize_guile): Add declaration.
9192 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
9193 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
9194 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
9195 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
9196 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
9197 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
9198 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
9199 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
9200 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
9201 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
9202 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
9203 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
9204 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
9205 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
9206 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
9207 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
9208 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
9209 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
9210 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
9211 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
9212 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
9213 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
9214 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
9215 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
9216 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
9217 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
9218 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
9219 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
9220 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
9221 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
9222 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
9223 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
9224 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
9225 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
9226 * infcall.c (_initialize_infcall): Add declaration.
9227 * infcmd.c (_initialize_infcmd): Add declaration.
9228 * inflow.c (_initialize_inflow): Add declaration.
9229 * infrun.c (_initialize_infrun): Add declaration.
9230 * interps.c (_initialize_interpreter): Add declaration.
9231 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
9232 * jit.c (_initialize_jit): Add declaration.
9233 * language.c (_initialize_language): Add declaration.
9234 * linux-fork.c (_initialize_linux_fork): Add declaration.
9235 * linux-nat.c (_initialize_linux_nat): Add declaration.
9236 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
9237 * linux-thread-db.c (_initialize_thread_db): Add declaration.
9238 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
9239 * m2-lang.c (_initialize_m2_language): Add declaration.
9240 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
9241 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
9242 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
9243 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
9244 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
9245 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
9246 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
9247 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
9248 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
9249 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
9250 * machoread.c (_initialize_machoread): Add declaration.
9251 * macrocmd.c (_initialize_macrocmd): Add declaration.
9252 * macroscope.c (_initialize_macroscope): Add declaration.
9253 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
9254 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
9255 * maint.c (_initialize_maint_cmds): Add declaration.
9256 * mdebugread.c (_initialize_mdebugread): Add declaration.
9257 * memattr.c (_initialize_mem): Add declaration.
9258 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
9259 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
9260 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
9261 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
9262 * mi/mi-main.c (_initialize_mi_main): Add declaration.
9263 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
9264 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
9265 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
9266 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
9267 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
9268 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
9269 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
9270 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
9271 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
9272 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
9273 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
9274 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
9275 * mipsread.c (_initialize_mipsread): Add declaration.
9276 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
9277 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
9278 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
9279 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
9280 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
9281 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
9282 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
9283 * nto-procfs.c (_initialize_procfs): Add declaration.
9284 * objc-lang.c (_initialize_objc_language): Add declaration.
9285 * observable.c (_initialize_observer): Add declaration.
9286 * opencl-lang.c (_initialize_opencl_language): Add declaration.
9287 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
9288 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
9289 * osabi.c (_initialize_gdb_osabi): Add declaration.
9290 * osdata.c (_initialize_osdata): Add declaration.
9291 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
9292 * parse.c (_initialize_parse): Add declaration.
9293 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
9294 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
9295 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
9296 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
9297 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
9298 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
9299 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
9300 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
9301 * printcmd.c (_initialize_printcmd): Add declaration.
9302 * probe.c (_initialize_probe): Add declaration.
9303 * proc-api.c (_initialize_proc_api): Add declaration.
9304 * proc-events.c (_initialize_proc_events): Add declaration.
9305 * proc-service.c (_initialize_proc_service): Add declaration.
9306 * procfs.c (_initialize_procfs): Add declaration.
9307 * producer.c (_initialize_producer): Add declaration.
9308 * psymtab.c (_initialize_psymtab): Add declaration.
9309 * python/python.c (_initialize_python): Add declaration.
9310 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
9311 * record-btrace.c (_initialize_record_btrace): Add declaration.
9312 * record-full.c (_initialize_record_full): Add declaration.
9313 * record.c (_initialize_record): Add declaration.
9314 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
9315 * regcache.c (_initialize_regcache): Add declaration.
9316 * reggroups.c (_initialize_reggroup): Add declaration.
9317 * remote-notif.c (_initialize_notif): Add declaration.
9318 * remote-sim.c (_initialize_remote_sim): Add declaration.
9319 * remote.c (_initialize_remote): Add declaration.
9320 * reverse.c (_initialize_reverse): Add declaration.
9321 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
9322 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
9323 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
9324 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
9325 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
9326 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
9327 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
9328 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
9329 Add declaration.
9330 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
9331 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
9332 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
9333 * rust-exp.y (_initialize_rust_exp): Add declaration.
9334 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
9335 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
9336 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
9337 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
9338 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
9339 * score-tdep.c (_initialize_score_tdep): Add declaration.
9340 * ser-go32.c (_initialize_ser_dos): Add declaration.
9341 * ser-mingw.c (_initialize_ser_windows): Add declaration.
9342 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
9343 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
9344 * ser-uds.c (_initialize_ser_socket): Add declaration.
9345 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
9346 * serial.c (_initialize_serial): Add declaration.
9347 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
9348 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
9349 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
9350 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
9351 * skip.c (_initialize_step_skip): Add declaration.
9352 * sol-thread.c (_initialize_sol_thread): Add declaration.
9353 * solib-aix.c (_initialize_solib_aix): Add declaration.
9354 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
9355 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
9356 * solib-frv.c (_initialize_frv_solib): Add declaration.
9357 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
9358 * solib-target.c (_initialize_solib_target): Add declaration.
9359 * solib.c (_initialize_solib): Add declaration.
9360 * source-cache.c (_initialize_source_cache): Add declaration.
9361 * source.c (_initialize_source): Add declaration.
9362 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
9363 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
9364 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
9365 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
9366 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
9367 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
9368 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
9369 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
9370 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
9371 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
9372 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
9373 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
9374 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
9375 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
9376 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
9377 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
9378 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
9379 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
9380 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
9381 * stabsread.c (_initialize_stabsread): Add declaration.
9382 * stack.c (_initialize_stack): Add declaration.
9383 * stap-probe.c (_initialize_stap_probe): Add declaration.
9384 * std-regs.c (_initialize_frame_reg): Add declaration.
9385 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
9386 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
9387 * symfile.c (_initialize_symfile): Add declaration.
9388 * symmisc.c (_initialize_symmisc): Add declaration.
9389 * symtab.c (_initialize_symtab): Add declaration.
9390 * target.c (_initialize_target): Add declaration.
9391 * target-connection.c (_initialize_target_connection): Add
9392 declaration.
9393 * target-dcache.c (_initialize_target_dcache): Add declaration.
9394 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
9395 * thread.c (_initialize_thread): Add declaration.
9396 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
9397 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
9398 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
9399 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
9400 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
9401 * tracectf.c (_initialize_ctf): Add declaration.
9402 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
9403 * tracefile.c (_initialize_tracefile): Add declaration.
9404 * tracepoint.c (_initialize_tracepoint): Add declaration.
9405 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
9406 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
9407 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
9408 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
9409 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
9410 * tui/tui-win.c (_initialize_tui_win): Add declaration.
9411 * tui/tui.c (_initialize_tui): Add declaration.
9412 * typeprint.c (_initialize_typeprint): Add declaration.
9413 * ui-style.c (_initialize_ui_style): Add declaration.
9414 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
9415 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
9416 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
9417 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
9418 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
9419 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
9420 * unittests/filtered_iterator-selftests.c
9421 (_initialize_filtered_iterator_selftests): Add declaration.
9422 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
9423 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
9424 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
9425 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
9426 * unittests/main-thread-selftests.c
9427 (_initialize_main_thread_selftests): Add declaration.
9428 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
9429 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
9430 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
9431 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
9432 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
9433 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
9434 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
9435 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
9436 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
9437 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
9438 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
9439 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
9440 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
9441 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
9442 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
9443 declaration.
9444 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
9445 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
9446 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
9447 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
9448 * user-regs.c (_initialize_user_regs): Add declaration.
9449 * utils.c (_initialize_utils): Add declaration.
9450 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
9451 * valops.c (_initialize_valops): Add declaration.
9452 * valprint.c (_initialize_valprint): Add declaration.
9453 * value.c (_initialize_values): Add declaration.
9454 * varobj.c (_initialize_varobj): Add declaration.
9455 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
9456 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
9457 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
9458 * windows-nat.c (_initialize_windows_nat): Add declaration.
9459 (_initialize_check_for_gdb_ini): Add declaration.
9460 (_initialize_loadable): Add declaration.
9461 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
9462 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
9463 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
9464 * xcoffread.c (_initialize_xcoffread): Add declaration.
9465 * xml-support.c (_initialize_xml_support): Add declaration.
9466 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
9467 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
9468 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
9469 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
9470
9471 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9472
9473 * regformats/regdat.sh: Generate declaration for init function.
9474
9475 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9476
9477 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
9478 up.
9479 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
9480 close_one_inferior>: New methods.
9481 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
9482 pass down target to find_inferior_pid.
9483 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
9484 Pass down target to find_inferior_ptid.
9485 (gdbsim_target::create_inferior): Pass down target to
9486 add_thread_silent.
9487 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
9488 target down to find_inferior_ptid and switch_to_thread.
9489 (gdbsim_target::close): Update to call close_one_inferior.
9490 (struct resume_data): Remove.
9491 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
9492 directly, rather than through a void pointer.
9493 (gdbsim_target::resume): Update to call resume_one_inferior.
9494
9495 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
9496
9497 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
9498
9499 2020-01-12 Pedro Alves <palves@redhat.com>
9500
9501 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
9502 directly for the current inferior instead of
9503 discard_all_inferiors.
9504 (discard_all_inferiors): Delete.
9505
9506 2020-01-11 Tom Tromey <tom@tromey.com>
9507
9508 * tui/tui-wingeneral.c (box_win): Check cli_styling.
9509 * tui/tui-winsource.c (tui_source_window_base::refill): Use
9510 deprecated_safe_get_selected_frame.
9511
9512 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
9513
9514 * inferior.c (print_inferior): Switch inferior before printing it.
9515
9516 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
9517 Pedro Alves <palves@redhat.com>
9518
9519 * progspace-and-thread.c (switch_to_program_space_and_thread):
9520 Assert there's an inferior for PSPACE. Use
9521 switch_to_inferior_no_thread to switch the inferior too.
9522 * progspace.c (program_space::~program_space): Call
9523 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
9524 (program_space::free_all_objfiles): Don't call clear_symtab_users
9525 here.
9526 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
9527
9528 2020-01-10 Pedro Alves <palves@redhat.com>
9529
9530 * NEWS: Mention multi-target debugging, "info connections", and
9531 "add-inferior -no-connection".
9532
9533 2020-01-10 Pedro Alves <palves@redhat.com>
9534
9535 * infrun.c: Include "target-connection.h".
9536 (check_multi_target_resumption): New.
9537 (proceed): Call it.
9538 * target-connection.c (make_target_connection_string): Make
9539 extern.
9540 * target-connection.h (make_target_connection_string): Declare.
9541
9542 2020-01-10 Pedro Alves <palves@redhat.com>
9543
9544 * Makefile.in (COMMON_SFILES): Add target-connection.c.
9545 * inferior.c (uiout_field_connection): New function.
9546 (print_inferior): Add new "connection-id" column.
9547 (add_inferior_command): Show connection number/string of added
9548 inferior.
9549 * process-stratum-target.h
9550 (process_stratum_target::connection_string): New virtual method.
9551 (process_stratum_target::connection_number): New field.
9552 * remote.c (remote_target::connection_string): New override.
9553 * target-connection.c: New file.
9554 * target-connection.h: New file.
9555 * target.c (decref_target): Remove process_stratum targets from
9556 the connection list.
9557 (target_stack::push): Add process_stratum targets to the
9558 connection list.
9559
9560 2020-01-10 Pedro Alves <palves@redhat.com>
9561
9562 Revert:
9563 2016-04-12 Pedro Alves <palves@redhat.com>
9564 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
9565 Remove references to name.
9566 * serial.h (struct serial) <name>: Delete.
9567
9568 2020-01-10 Pedro Alves <palves@redhat.com>
9569
9570 * gdbarch-selftests.c (register_to_value_test): Remove "target
9571 already pushed" check.
9572
9573 2020-01-10 Pedro Alves <palves@redhat.com>
9574 John Baldwin <jhb@FreeBSD.org>
9575
9576 * aarch64-linux-nat.c
9577 (aarch64_linux_nat_target::thread_architecture): Adjust.
9578 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
9579 (task_command_1): Likewise.
9580 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
9581 (aix_thread_target::wait, aix_thread_target::fetch_registers)
9582 (aix_thread_target::store_registers)
9583 (aix_thread_target::thread_alive): Adjust.
9584 * amd64-fbsd-tdep.c: Include "inferior.h".
9585 (amd64fbsd_get_thread_local_address): Pass down target.
9586 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
9587 thread's gdbarch instead of target_gdbarch.
9588 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
9589 get_last_target_status.
9590 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
9591 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
9592 inferiors.
9593 (update_inserted_breakpoint_locations): Skip if inferiors with no
9594 execution.
9595 (update_global_location_list): When handling moribund locations,
9596 find representative inferior for location's pspace, and use thread
9597 count of its process_stratum target.
9598 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
9599 * bsd-uthread.c (bsd_uthread_target::wait): Use
9600 as_process_stratum_target and adjust thread_change_ptid and
9601 add_thread calls.
9602 (bsd_uthread_target::update_thread_list): Use
9603 as_process_stratum_target and adjust find_thread_ptid,
9604 thread_change_ptid and add_thread calls.
9605 * btrace.c (maint_btrace_packet_history_cmd): Adjust
9606 find_thread_ptid call.
9607 * corelow.c (add_to_thread_list): Adjust add_thread call.
9608 (core_target_open): Adjust add_thread_silent and thread_count
9609 calls.
9610 (core_target::pid_to_str): Adjust find_inferior_ptid call.
9611 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
9612 * event-top.c (async_disconnect): Pop targets from all inferiors.
9613 * exec.c (add_target_sections): Push exec target on all inferiors
9614 sharing the program space.
9615 (remove_target_sections): Remove the exec target from all
9616 inferiors sharing the program space.
9617 (exec_on_vfork): New.
9618 * exec.h (exec_on_vfork): Declare.
9619 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
9620 Pass it down.
9621 (fbsd_nat_target::update_thread_list): Adjust.
9622 (fbsd_nat_target::resume): Adjust.
9623 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
9624 down.
9625 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
9626 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
9627 get_thread_arch_regcache call.
9628 * fork-child.c (gdb_startup_inferior): Pass target down to
9629 startup_inferior and set_executing.
9630 * gdbthread.h (struct process_stratum_target): Forward declare.
9631 (add_thread, add_thread_silent, add_thread_with_info)
9632 (in_thread_list): Add process_stratum_target parameter.
9633 (find_thread_ptid(inferior*, ptid_t)): New overload.
9634 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
9635 parameter.
9636 (all_threads()): Delete overload.
9637 (all_threads, all_non_exited_threads): Add process_stratum_target
9638 parameter.
9639 (all_threads_safe): Use brace initialization.
9640 (thread_count): Add process_stratum_target parameter.
9641 (set_resumed, set_running, set_stop_requested, set_executing)
9642 (threads_are_executing, finish_thread_state): Add
9643 process_stratum_target parameter.
9644 (switch_to_thread): Use is_current_thread.
9645 * i386-fbsd-tdep.c: Include "inferior.h".
9646 (i386fbsd_get_thread_local_address): Pass down target.
9647 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
9648 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
9649 have_inferiors check.
9650 * inf-ptrace.c (inf_ptrace_target::create_inferior)
9651 (inf_ptrace_target::attach): Adjust.
9652 * infcall.c (run_inferior_call): Adjust.
9653 * infcmd.c (run_command_1): Pass target to
9654 scoped_finish_thread_state.
9655 (proceed_thread_callback): Skip inferiors with no execution.
9656 (continue_command): Rename 'all_threads' local to avoid hiding
9657 'all_threads' function. Adjust get_last_target_status call.
9658 (prepare_one_step): Adjust set_running call.
9659 (signal_command): Use user_visible_resume_target. Compare thread
9660 pointers instead of inferior_ptid.
9661 (info_program_command): Adjust to pass down target.
9662 (attach_command): Mark target's 'thread_executing' flag.
9663 (stop_current_target_threads_ns): New, factored out from ...
9664 (interrupt_target_1): ... this. Switch inferior before making
9665 target calls.
9666 * inferior-iter.h
9667 (struct all_inferiors_iterator, struct all_inferiors_range)
9668 (struct all_inferiors_safe_range)
9669 (struct all_non_exited_inferiors_range): Filter on
9670 process_stratum_target too. Remove explicit.
9671 * inferior.c (inferior::inferior): Push dummy target on target
9672 stack.
9673 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
9674 Add process_stratum_target parameter, and pass it down.
9675 (have_live_inferiors): Adjust.
9676 (switch_to_inferior_and_push_target): New.
9677 (add_inferior_command, clone_inferior_command): Handle
9678 "-no-connection" parameter. Use
9679 switch_to_inferior_and_push_target.
9680 (_initialize_inferior): Mention "-no-connection" option in
9681 the help of "add-inferior" and "clone-inferior" commands.
9682 * inferior.h: Include "process-stratum-target.h".
9683 (interrupt_target_1): Use bool.
9684 (struct inferior) <push_target, unpush_target, target_is_pushed,
9685 find_target_beneath, top_target, process_target, target_at,
9686 m_stack>: New.
9687 (discard_all_inferiors): Delete.
9688 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
9689 (all_inferiors, all_non_exited_inferiors): Add
9690 process_stratum_target parameter.
9691 * infrun.c: Include "gdb_select.h" and <unordered_map>.
9692 (target_last_proc_target): New global.
9693 (follow_fork_inferior): Push target on new inferior. Pass target
9694 to add_thread_silent. Call exec_on_vfork. Handle target's
9695 reference count.
9696 (follow_fork): Adjust get_last_target_status call. Also consider
9697 target.
9698 (follow_exec): Push target on new inferior.
9699 (struct execution_control_state) <target>: New field.
9700 (user_visible_resume_target): New.
9701 (do_target_resume): Call target_async.
9702 (resume_1): Set target's threads_executing flag. Consider resume
9703 target.
9704 (commit_resume_all_targets): New.
9705 (proceed): Also consider resume target. Skip threads of inferiors
9706 with no execution. Commit resumtion in all targets.
9707 (start_remote): Pass current inferior to wait_for_inferior.
9708 (infrun_thread_stop_requested): Consider target as well. Pass
9709 thread_info pointer to clear_inline_frame_state instead of ptid.
9710 (infrun_thread_thread_exit): Consider target as well.
9711 (random_pending_event_thread): New inferior parameter. Use it.
9712 (do_target_wait): Rename to ...
9713 (do_target_wait_1): ... this. Add inferior parameter, and pass it
9714 down.
9715 (threads_are_resumed_pending_p, do_target_wait): New.
9716 (prepare_for_detach): Adjust calls.
9717 (wait_for_inferior): New inferior parameter. Handle it. Use
9718 do_target_wait_1 instead of do_target_wait.
9719 (fetch_inferior_event): Adjust. Switch to representative
9720 inferior. Pass target down.
9721 (set_last_target_status): Add process_stratum_target parameter.
9722 Save target in global.
9723 (get_last_target_status): Add process_stratum_target parameter and
9724 handle it.
9725 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
9726 (context_switch): Check inferior_ptid == null_ptid before calling
9727 inferior_thread().
9728 (get_inferior_stop_soon): Pass down target.
9729 (wait_one): Rename to ...
9730 (poll_one_curr_target): ... this.
9731 (struct wait_one_event): New.
9732 (wait_one): New.
9733 (stop_all_threads): Adjust.
9734 (handle_no_resumed, handle_inferior_event): Adjust to consider the
9735 event's target.
9736 (switch_back_to_stepped_thread): Also consider target.
9737 (print_stop_event): Update.
9738 (normal_stop): Update. Also consider the resume target.
9739 * infrun.h (wait_for_inferior): Remove declaration.
9740 (user_visible_resume_target): New declaration.
9741 (get_last_target_status, set_last_target_status): New
9742 process_stratum_target parameter.
9743 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
9744 process_stratum_target parameter, and use it.
9745 (clear_inline_frame_state (thread_info*)): New.
9746 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
9747 process_stratum_target parameter.
9748 (clear_inline_frame_state (thread_info*)): Declare.
9749 * linux-fork.c (delete_checkpoint_command): Pass target down to
9750 find_thread_ptid.
9751 (checkpoint_command): Adjust.
9752 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
9753 instead of just tweaking inferior_ptid.
9754 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
9755 (exit_lwp): Pass target down to find_thread_ptid.
9756 (attach_proc_task_lwp_callback): Pass target down to
9757 add_thread/set_running/set_executing.
9758 (linux_nat_target::attach): Pass target down to
9759 thread_change_ptid.
9760 (get_detach_signal): Pass target down to find_thread_ptid.
9761 Consider last target status's target.
9762 (linux_resume_one_lwp_throw, resume_lwp)
9763 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
9764 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
9765 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
9766 (linux_nat_target::async_wait_fd): New.
9767 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
9768 target down.
9769 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
9770 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
9771 * linux-thread-db.c (struct thread_db_info::process_target): New
9772 field.
9773 (add_thread_db_info): Save target.
9774 (get_thread_db_info): New process_stratum_target parameter. Also
9775 match target.
9776 (delete_thread_db_info): New process_stratum_target parameter.
9777 Also match target.
9778 (thread_from_lwp): Adjust to pass down target.
9779 (thread_db_notice_clone): Pass down target.
9780 (check_thread_db_callback): Pass down target.
9781 (try_thread_db_load_1): Always push the thread_db target.
9782 (try_thread_db_load, record_thread): Pass target down.
9783 (thread_db_target::detach): Pass target down. Always unpush the
9784 thread_db target.
9785 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
9786 target down. Always unpush the thread_db target.
9787 (find_new_threads_callback, thread_db_find_new_threads_2)
9788 (thread_db_target::update_thread_list): Pass target down.
9789 (thread_db_target::pid_to_str): Pass current inferior down.
9790 (thread_db_target::get_thread_local_address): Pass target down.
9791 (thread_db_target::resume, maintenance_check_libthread_db): Pass
9792 target down.
9793 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
9794 * procfs.c (procfs_target::procfs_init_inferior): Declare.
9795 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
9796 (procfs_init_inferior): Rename to ...
9797 (procfs_target::procfs_init_inferior): ... this and adjust.
9798 (procfs_target::create_inferior, procfs_notice_thread)
9799 (procfs_do_thread_registers): Adjust.
9800 * ppc-fbsd-tdep.c: Include "inferior.h".
9801 (ppcfbsd_get_thread_local_address): Pass down target.
9802 * proc-service.c (ps_xfer_memory): Switch current inferior and
9803 program space as well.
9804 (get_ps_regcache): Pass target down.
9805 * process-stratum-target.c
9806 (process_stratum_target::thread_address_space)
9807 (process_stratum_target::thread_architecture): Pass target down.
9808 * process-stratum-target.h
9809 (process_stratum_target::threads_executing): New field.
9810 (as_process_stratum_target): New.
9811 * ravenscar-thread.c
9812 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
9813 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
9814 down.
9815 * record-btrace.c (record_btrace_target::info_record): Adjust.
9816 (record_btrace_target::record_method)
9817 (record_btrace_target::record_is_replaying)
9818 (record_btrace_target::fetch_registers)
9819 (get_thread_current_frame_id, record_btrace_target::resume)
9820 (record_btrace_target::wait, record_btrace_target::stop): Pass
9821 target down.
9822 * record-full.c (record_full_wait_1): Switch to event thread.
9823 Pass target down.
9824 * regcache.c (regcache::regcache)
9825 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
9826 process_stratum_target parameter and handle it.
9827 (current_thread_target): New global.
9828 (get_thread_regcache): Add process_stratum_target parameter and
9829 handle it. Switch inferior before calling target method.
9830 (get_thread_regcache): Pass target down.
9831 (get_thread_regcache_for_ptid): Pass target down.
9832 (registers_changed_ptid): Add process_stratum_target parameter and
9833 handle it.
9834 (registers_changed_thread, registers_changed): Pass target down.
9835 (test_get_thread_arch_aspace_regcache): New.
9836 (current_regcache_test): Define a couple local test_target_ops
9837 instances and use them for testing.
9838 (readwrite_regcache): Pass process_stratum_target parameter.
9839 (cooked_read_test, cooked_write_test): Pass mock_target down.
9840 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
9841 (get_thread_arch_aspace_regcache): Add process_stratum_target
9842 parameter.
9843 (regcache::target): New method.
9844 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
9845 (regcache::registers_changed_ptid): Add process_stratum_target
9846 parameter.
9847 (regcache::m_target): New field.
9848 (registers_changed_ptid): Add process_stratum_target parameter.
9849 * remote.c (remote_state::supports_vCont_probed): New field.
9850 (remote_target::async_wait_fd): New method.
9851 (remote_unpush_and_throw): Add remote_target parameter.
9852 (get_current_remote_target): Adjust.
9853 (remote_target::remote_add_inferior): Push target.
9854 (remote_target::remote_add_thread)
9855 (remote_target::remote_notice_new_inferior)
9856 (get_remote_thread_info): Pass target down.
9857 (remote_target::update_thread_list): Skip threads of inferiors
9858 bound to other targets. (remote_target::close): Don't discard
9859 inferiors. (remote_target::add_current_inferior_and_thread)
9860 (remote_target::process_initial_stop_replies)
9861 (remote_target::start_remote)
9862 (remote_target::remote_serial_quit_handler): Pass down target.
9863 (remote_target::remote_unpush_target): New remote_target
9864 parameter. Unpush the target from all inferiors.
9865 (remote_target::remote_unpush_and_throw): New remote_target
9866 parameter. Pass it down.
9867 (remote_target::open_1): Check whether the current inferior has
9868 execution instead of checking whether any inferior is live. Pass
9869 target down.
9870 (remote_target::remote_detach_1): Pass down target. Use
9871 remote_unpush_target.
9872 (extended_remote_target::attach): Pass down target.
9873 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
9874 (remote_target::append_resumption): Pass down target.
9875 (remote_target::append_pending_thread_resumptions)
9876 (remote_target::remote_resume_with_hc, remote_target::resume)
9877 (remote_target::commit_resume): Pass down target.
9878 (remote_target::remote_stop_ns): Check supports_vCont_probed.
9879 (remote_target::interrupt_query)
9880 (remote_target::remove_new_fork_children)
9881 (remote_target::check_pending_events_prevent_wildcard_vcont)
9882 (remote_target::remote_parse_stop_reply)
9883 (remote_target::process_stop_reply): Pass down target.
9884 (first_remote_resumed_thread): New remote_target parameter. Pass
9885 it down.
9886 (remote_target::wait_as): Pass down target.
9887 (unpush_and_perror): New remote_target parameter. Pass it down.
9888 (remote_target::readchar, remote_target::remote_serial_write)
9889 (remote_target::getpkt_or_notif_sane_1)
9890 (remote_target::kill_new_fork_children, remote_target::kill): Pass
9891 down target.
9892 (remote_target::mourn_inferior): Pass down target. Use
9893 remote_unpush_target.
9894 (remote_target::core_of_thread)
9895 (remote_target::remote_btrace_maybe_reopen): Pass down target.
9896 (remote_target::pid_to_exec_file)
9897 (remote_target::thread_handle_to_thread_info): Pass down target.
9898 (remote_target::async_wait_fd): New.
9899 * riscv-fbsd-tdep.c: Include "inferior.h".
9900 (riscv_fbsd_get_thread_local_address): Pass down target.
9901 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
9902 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
9903 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
9904 Adjust.
9905 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
9906 * solib-svr4.c (enable_break): Pass down target.
9907 * spu-multiarch.c (parse_spufs_run): Pass down target.
9908 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
9909 * target-delegates.c: Regenerate.
9910 * target.c (g_target_stack): Delete.
9911 (current_top_target): Return the current inferior's top target.
9912 (target_has_execution_1): Refer to the passed-in inferior's top
9913 target.
9914 (target_supports_terminal_ours): Check whether the initial
9915 inferior was already created.
9916 (decref_target): New.
9917 (target_stack::push): Incref/decref the target.
9918 (push_target, push_target, unpush_target): Adjust.
9919 (target_stack::unpush): Defref target.
9920 (target_is_pushed): Return bool. Adjust to refer to the current
9921 inferior's target stack.
9922 (dispose_inferior): Delete, and inline parts ...
9923 (target_preopen): ... here. Only dispose of the current inferior.
9924 (target_detach): Hold strong target reference while detaching.
9925 Pass target down.
9926 (target_thread_name): Add assertion.
9927 (target_resume): Pass down target.
9928 (target_ops::beneath, find_target_at): Adjust to refer to the
9929 current inferior's target stack.
9930 (get_dummy_target): New.
9931 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
9932 has a thread running.
9933 (initialize_targets): Rename to ...
9934 (_initialize_target): ... this.
9935 * target.h: Include "gdbsupport/refcounted-object.h".
9936 (struct target_ops): Inherit refcounted_object.
9937 (target_ops::shortname, target_ops::longname): Make const.
9938 (target_ops::async_wait_fd): New method.
9939 (decref_target): Declare.
9940 (struct target_ops_ref_policy): New.
9941 (target_ops_ref): New typedef.
9942 (get_dummy_target): Declare function.
9943 (target_is_pushed): Return bool.
9944 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
9945 (all_matching_threads_iterator::all_matching_threads_iterator):
9946 Handle filter target.
9947 * thread-iter.h (struct all_matching_threads_iterator, struct
9948 all_matching_threads_range, class all_non_exited_threads_range):
9949 Filter by target too. Remove explicit.
9950 * thread.c (threads_executing): Delete.
9951 (inferior_thread): Pass down current inferior.
9952 (clear_thread_inferior_resources): Pass down thread pointer
9953 instead of ptid_t.
9954 (add_thread_silent, add_thread_with_info, add_thread): Add
9955 process_stratum_target parameter. Use it for thread and inferior
9956 searches.
9957 (is_current_thread): New.
9958 (thread_info::deletable): Use it.
9959 (find_thread_ptid, thread_count, in_thread_list)
9960 (thread_change_ptid, set_resumed, set_running): New
9961 process_stratum_target parameter. Pass it down.
9962 (set_executing): New process_stratum_target parameter. Pass it
9963 down. Adjust reference to 'threads_executing'.
9964 (threads_are_executing): New process_stratum_target parameter.
9965 Adjust reference to 'threads_executing'.
9966 (set_stop_requested, finish_thread_state): New
9967 process_stratum_target parameter. Pass it down.
9968 (switch_to_thread): Also match inferior.
9969 (switch_to_thread): New process_stratum_target parameter. Pass it
9970 down.
9971 (update_threads_executing): Reimplement.
9972 * top.c (quit_force): Pop targets from all inferior.
9973 (gdb_init): Don't call initialize_targets.
9974 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
9975 Declare.
9976 (windows_add_thread, windows_delete_thread): Adjust.
9977 (get_windows_debug_event): Rename to ...
9978 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
9979 * tracefile-tfile.c (tfile_target_open): Pass down target.
9980 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
9981 Forward declare.
9982 (switch_to_thread): Add process_stratum_target parameter.
9983 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
9984 parameter. Use it.
9985 (mi_on_resume): Pass target down.
9986 * nat/fork-inferior.c (startup_inferior): Add
9987 process_stratum_target parameter. Pass it down.
9988 * nat/fork-inferior.h (startup_inferior): Add
9989 process_stratum_target parameter.
9990 * python/py-threadevent.c (py_get_event_thread): Pass target down.
9991
9992 2020-01-10 Pedro Alves <palves@redhat.com>
9993
9994 * remote.c (remote_target::start_remote): Don't set inferior_ptid
9995 directly. Instead find the first thread in the thread list and
9996 use switch_to_thread.
9997
9998 2020-01-10 Pedro Alves <palves@redhat.com>
9999
10000 * remote.c (remote_target::remote_add_inferior): Don't bind a
10001 process to the current inferior if the current inferior is already
10002 bound to a process.
10003
10004 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10005 Pedro Alves <palves@redhat.com>
10006
10007 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
10008 If no process is specified, return null_ptid instead of
10009 inferior_ptid.
10010 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
10011 TARGET_WAITKIND_SIGNALLED with no pid.
10012
10013 2020-01-10 Pedro Alves <palves@redhat.com>
10014
10015 * remote.c (first_remote_resumed_thread): New.
10016 (remote_target::wait_as): Use it as default event_ptid instead of
10017 inferior_ptid.
10018
10019 2020-01-10 Pedro Alves <palves@redhat.com>
10020
10021 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
10022
10023 2020-01-10 Pedro Alves <palves@redhat.com>
10024
10025 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
10026 not -1.
10027
10028 2020-01-10 Pedro Alves <palves@redhat.com>
10029
10030 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
10031 ptid to get_last_target_status.
10032 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
10033 ptid to get_last_target_status.
10034 * infcmd.c (continue_command): Don't pass a target_waitstatus to
10035 get_last_target_status.
10036 (info_program_command): Don't pass a target_waitstatus to
10037 get_last_target_status.
10038 * infrun.c (init_wait_for_inferior): Use
10039 nullify_last_target_wait_ptid.
10040 (get_last_target_status): Handle nullptr arguments.
10041 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
10042 (print_stop_event): Don't pass a ptid to get_last_target_status.
10043 (normal_stop): Don't pass a ptid to get_last_target_status.
10044 * infrun.h (get_last_target_status, set_last_target_status): Move
10045 comments here and update.
10046 (nullify_last_target_wait_ptid): Declare.
10047 * linux-fork.c (fork_load_infrun_state): Remove local extern
10048 declaration of nullify_last_target_wait_ptid.
10049 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
10050 to get_last_target_status.
10051
10052 2020-01-10 Pedro Alves <palves@redhat.com>
10053
10054 * gdbthread.h (scoped_restore_current_thread)
10055 <dont_restore, restore, m_dont_restore>: Declare.
10056 * thread.c (thread_alive): Add assertion. Return bool.
10057 (switch_to_thread_if_alive): New.
10058 (prune_threads): Switch inferior/thread.
10059 (print_thread_info_1): Switch thread before calling target methods.
10060 (scoped_restore_current_thread::restore): New, factored out from
10061 ...
10062 (scoped_restore_current_thread::~scoped_restore_current_thread):
10063 ... this.
10064 (scoped_restore_current_thread::scoped_restore_current_thread):
10065 Add assertion.
10066 (thread_apply_all_command, thread_select): Use
10067 switch_to_thread_if_alive.
10068 * infrun.c (proceed, restart_threads, handle_signal_stop)
10069 (switch_back_to_stepped_thread): Switch current thread before
10070 calling target methods.
10071
10072 2020-01-10 Pedro Alves <palves@redhat.com>
10073
10074 * inferior.c (switch_to_inferior_no_thread): New function,
10075 factored out from ...
10076 (inferior_command): ... here.
10077 * inferior.h (switch_to_inferior_no_thread): Declare.
10078 * mi/mi-main.c (run_one_inferior): Use
10079 switch_to_inferior_no_thread.
10080
10081 2020-01-10 Pedro Alves <palves@redhat.com>
10082
10083 * infcmd.c (kill_command): Remove dead code.
10084
10085 2020-01-10 Pedro Alves <palves@redhat.com>
10086
10087 * remote.c (remote_target::mourn_inferior): No longer check
10088 whether the target is running.
10089
10090 2020-01-10 Pedro Alves <palves@redhat.com>
10091
10092 * corelow.c (core_target::has_execution): Change parameter type to
10093 inferior pointer.
10094 * inferior.c (number_of_live_inferiors): Use
10095 inferior::has_execution instead of target_has_execution_1.
10096 * inferior.h (inferior::has_execution): New.
10097 * linux-thread-db.c (thread_db_target::update_thread_list): Use
10098 inferior::has_execution instead of target_has_execution_1.
10099 * process-stratum-target.c
10100 (process_stratum_target::has_execution): Change parameter type to
10101 inferior pointer. Check the inferior's PID instead of
10102 inferior_ptid.
10103 * process-stratum-target.h
10104 (process_stratum_target::has_execution): Change parameter type to
10105 inferior pointer.
10106 * record-full.c (record_full_core_target::has_execution): Change
10107 parameter type to inferior pointer.
10108 * target.c (target_has_execution_1): Change parameter type to
10109 inferior pointer.
10110 (target_has_execution_current): Adjust.
10111 * target.h (target_ops::has_execution): Change parameter type to
10112 inferior pointer.
10113 (target_has_execution_1): Change parameter type to inferior
10114 pointer. Change return type to bool.
10115 * tracefile.h (tracefile_target::has_execution): Change parameter
10116 type to inferior pointer.
10117
10118 2020-01-10 Pedro Alves <palves@redhat.com>
10119
10120 * exceptions.c (print_flush): Remove current_top_target() check.
10121
10122 2020-01-10 Pedro Alves <palves@redhat.com>
10123
10124 * remote.c (show_remote_exec_file): Show the current inferior's
10125 exec-file instead of the command variable's value.
10126
10127 2020-01-10 Pedro Alves <palves@redhat.com>
10128
10129 * record-full.c (record_full_resume_ptid): New global.
10130 (record_full_target::resume): Set it.
10131 (record_full_wait_1): Use record_full_resume_ptid instead of
10132 inferior_ptid.
10133
10134 2020-01-10 Pedro Alves <palves@redhat.com>
10135
10136 * gdbthread.h (scoped_restore_current_thread)
10137 <dont_restore, restore, m_dont_restore>: Declare.
10138 * thread.c (thread_alive): Add assertion. Return bool.
10139 (switch_to_thread_if_alive): New.
10140 (prune_threads): Switch inferior/thread.
10141 (print_thread_info_1): Switch thread before calling target methods.
10142 (scoped_restore_current_thread::restore): New, factored out from
10143 ...
10144 (scoped_restore_current_thread::~scoped_restore_current_thread):
10145 ... this.
10146 (scoped_restore_current_thread::scoped_restore_current_thread):
10147 Add assertion.
10148 (thread_apply_all_command, thread_select): Use
10149 switch_to_thread_if_alive.
10150
10151 2020-01-10 George Barrett <bob@bob131.so>
10152
10153 * stap-probe.c (stap_modify_semaphore): Don't check for null
10154 semaphores.
10155 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
10156 for null semaphores.
10157
10158 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
10159
10160 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
10161 all source windows, and maintain horizontal scroll status while
10162 doing so.
10163
10164 2020-01-09 Tom Tromey <tom@tromey.com>
10165
10166 PR tui/18932:
10167 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
10168 update_source_window, not print_source_lines.
10169
10170 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
10171
10172 * tui/tui.c (tui_enable): Register tui hooks after calling
10173 tui_display_main.
10174
10175 2020-01-09 Christian Biesinger <cbiesinger@google.com>
10176
10177 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
10178
10179 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
10180
10181 * thread.c (print_thread_info_1): Fix indentation.
10182
10183 2020-01-09 Christian Biesinger <cbiesinger@google.com>
10184
10185 * symtab.c (general_symbol_info::compute_and_set_names): Move the
10186 unique_xmalloc_ptr outside the if to always free the demangled name.
10187
10188 2020-01-08 Tom Tromey <tromey@adacore.com>
10189
10190 * xcoffread.c (enter_line_range, read_xcoff_symtab)
10191 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
10192 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
10193 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
10194 Remove.
10195 (section_offsets): New typedef.
10196 * symtab.c (fixup_section, get_msymbol_address): Update.
10197 * symmisc.c (dump_msymbols): Update.
10198 * symfile.h (relative_addr_info_to_section_offsets)
10199 (symfile_map_offsets_to_segments): Update.
10200 * symfile.c (build_section_addr_info_from_objfile)
10201 (init_objfile_sect_indices): Update.
10202 (struct place_section_arg): Change type of "offsets".
10203 (place_section): Update.
10204 (relative_addr_info_to_section_offsets): Change type of
10205 "section_offsets". Remove "num_sections" parameter.
10206 (default_symfile_offsets, syms_from_objfile_1)
10207 (set_objfile_default_section_offset): Update.
10208 (reread_symbols): No need to preserve section offsets by hand.
10209 (symfile_map_offsets_to_segments): Change type of "offsets".
10210 * stap-probe.c (relocate_address): Update.
10211 * stabsread.h (process_one_symbol): Update.
10212 * solib-target.c (struct lm_info_target) <offsets>: Change type.
10213 (solib_target_relocate_section_addresses): Update.
10214 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
10215 Update.
10216 * solib-frv.c (frv_relocate_main_executable): Update.
10217 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
10218 * solib-aix.c (solib_aix_get_section_offsets): Change return
10219 type.
10220 (solib_aix_solib_create_inferior_hook): Update.
10221 * remote.c (remote_target::get_offsets): Update.
10222 * psymtab.c (find_pc_sect_psymtab): Update.
10223 * psympriv.h (struct partial_symbol) <address, text_low,
10224 text_high>: Update.
10225 * objfiles.h (obj_section_offset): Update.
10226 (struct objfile) <section_offsets>: Change type.
10227 <num_sections>: Remove.
10228 (objfile_relocate): Update.
10229 * objfiles.c (entry_point_address_query): Update
10230 (relocate_one_symbol): Change type of "section_offsets".
10231 (objfile_relocate1, objfile_relocate1): Change type of
10232 "new_offsets".
10233 (objfile_rebase1): Update.
10234 * mipsread.c (mipscoff_symfile_read): Update.
10235 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
10236 parameter.
10237 * mdebugread.c (parse_symbol): Change type of "section_offsets".
10238 (parse_external, psymtab_to_symtab_1): Update.
10239 * machoread.c (macho_symfile_offsets): Update.
10240 * ia64-tdep.c (ia64_find_unwind_table): Update.
10241 * hppa-tdep.c (read_unwind_info): Update.
10242 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
10243 * dwarf2read.c (create_addrmap_from_index)
10244 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
10245 (process_psymtab_comp_unit_reader, add_partial_symbol)
10246 (add_partial_subprogram, process_full_comp_unit)
10247 (read_file_scope, read_func_scope, read_lexical_block_scope)
10248 (read_call_site_scope, dwarf2_rnglists_process)
10249 (dwarf2_ranges_process, dwarf2_ranges_read)
10250 (dwarf_decode_lines_1, var_decode_location, new_symbol)
10251 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
10252 Update.
10253 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
10254 Update.
10255 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
10256 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
10257 (process_one_symbol): Change type of "section_offsets".
10258 * ctfread.c (get_objfile_text_range): Update.
10259 * coffread.c (coff_symtab_read, enter_linenos)
10260 (process_coff_symbol): Update.
10261 * coff-pe-read.c (add_pe_forwarded_sym): Update.
10262 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
10263
10264 2020-01-08 Tom Tromey <tromey@adacore.com>
10265
10266 * dwarf2read.c (parse_macro_definition): Use std::string.
10267 (parse_macro_definition): Likewise.
10268
10269 2020-01-08 Tom Tromey <tromey@adacore.com>
10270
10271 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
10272 (ATTR_ALLOC_CHUNK): Remove.
10273
10274 2020-01-08 Tom Tromey <tromey@adacore.com>
10275
10276 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
10277
10278 2020-01-08 Tom Tromey <tromey@adacore.com>
10279
10280 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
10281 (dwarf2_compute_name, open_dwo_file): Likewise.
10282 (process_enumeration_scope): Use std::vector.
10283 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
10284 (partial_die_info::fixup, dwarf2_start_subfile)
10285 (guess_full_die_structure_name, dwarf2_name): Likewise.
10286 (determine_prefix): Update.
10287 (guess_full_die_structure_name): Make return type const.
10288 (partial_die_full_name): Return unique_xmalloc_ptr.
10289 (DW_FIELD_ALLOC_CHUNK): Remove.
10290
10291 2020-01-07 Tom Tromey <tromey@adacore.com>
10292
10293 PR build/24937:
10294 * stap-probe.c (class stap_static_probe_ops): Add constructor.
10295
10296 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
10297
10298 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
10299
10300 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
10301
10302 * stack.c (print_frame_info): Move disassemble_next_line code
10303 inside source_print block.
10304
10305 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10306
10307 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
10308 gdb/signals.h, as we are now using native signal symbols.
10309
10310 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
10311
10312 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
10313 overflow by an early check of content vs threshold.
10314 * tui/tui-source.c (tui_source_window::line_is_displayed):
10315 Likewise.
10316
10317 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10318
10319 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
10320
10321 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
10322
10323 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
10324 export table if no section contains it's RVA.
10325
10326 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10327
10328 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
10329
10330 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
10331
10332 * source.c (print_source_lines_base): Set last_line_listed.
10333
10334 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
10335
10336 * tui/tui-disasm.c: Remove trailing spaces.
10337
10338 2020-01-06 Eli Zaretskii <eliz@gnu.org>
10339 Pedro Alves <palves@redhat.com>
10340
10341 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
10342 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
10343 (windows_gdb_signal_to_target): New function, uses the above
10344 enumeration to convert GDB internal signal codes to equivalent
10345 Windows codes.
10346 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
10347 * windows-nat.c: Include "gdb_wait.h".
10348 (get_windows_debug_event): Extract the fatal exception from the
10349 exit status and convert to the equivalent Posix signal number.
10350 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
10351 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
10352 * gdbsupport/gdb_wait.c: New file, implements
10353 windows_status_to_termsig.
10354 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
10355 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
10356
10357 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
10358
10359 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
10360 show_layout.
10361
10362 2020-01-05 Luis Machado <luis.machado@linaro.org>
10363
10364 * aarch64-linux-nat.c
10365 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
10366 and bfd_mach_aarch64.
10367
10368 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10369
10370 * ui-file.c (stdio_file::can_emit_style_escape)
10371 (tee_file::can_emit_style_escape): Ensure style is used also on
10372 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
10373 to gdb_stdout.
10374 * main.c (set_gdb_data_directory): Use file style to output the
10375 warning that the given pathname is not a directory.
10376 * top.c (show_history_filename, gdb_safe_append_history)
10377 (show_gdb_datadir): Use file style.
10378
10379 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
10380
10381 * solib-target.c (struct lm_info_target):
10382 Change offsets to be a unique_xmalloc_ptr.
10383 (solib_target_relocate_section_addresses): Update.
10384
10385 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
10386
10387 * windows-nat.c (windows_clear_solib): Free so_list linked list.
10388
10389 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
10390
10391 * MAINTAINERS (Write After Approval): Add myself.
10392
10393 2020-01-02 Luis Machado <luis.machado@linaro.org>
10394
10395 * proc-service.c (get_ps_regcache): Remove reference to obsolete
10396 Cell BE architecture.
10397 * target.h (struct target_ops) <thread_architecture>: Likewise.
10398
10399 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
10400
10401 * Makefile.in: Use INSTALL_PROGRAM_ENV.
10402
10403 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
10404
10405 * MAINTAINERS (Write After Approval): Add myself.
10406
10407 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10408
10409 * gdbarch.sh: Update copyright year range of generated files.
10410
10411 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10412
10413 Update copyright year range in all GDB files.
10414
10415 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10416
10417 * copyright.py: Convert to Python 3.
10418
10419 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10420
10421 * copyright.py: Adapt after move of gnulib directory from gdb
10422 directory to toplevel directory.
10423
10424 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10425
10426 * copyright.py (main): Exit if run from the wrong directory.
10427
10428 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10429
10430 * top.c (print_gdb_version): Change copyright year to 2020.
10431
10432 2020-01-01 Joel Brobecker <brobecker@adacore.com>
10433
10434 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
10435
10436 For older changes see ChangeLog-2019.
10437 \f
10438 Local Variables:
10439 mode: change-log
10440 left-margin: 8
10441 fill-column: 74
10442 version-control: never
10443 coding: utf-8
10444 End:
This page took 0.229665 seconds and 5 git commands to generate.