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