gdb.python/py-frame-inline.exp and C++
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-09-17 Tom Tromey <tromey@adacore.com>
2
3 * tic6x-tdep.c (tic6x_gdbarch_init): Update.
4 * target-descriptions.h (struct tdesc_arch_data_deleter): New.
5 (tdesc_arch_data_up): New typedef.
6 (tdesc_use_registers, tdesc_data_alloc): Update.
7 (tdesc_data_cleanup): Don't declare.
8 * target-descriptions.c (tdesc_data_alloc): Return a
9 tdesc_arch_data_up.
10 (tdesc_arch_data_deleter::operator()): Rename from
11 tdesc_data_cleanup. Change argument type.
12 (tdesc_use_registers): Change early_data to an rvalue reference.
13 (tdesc_use_registers): Don't use delete.
14 * sparc-tdep.c (sparc32_gdbarch_init): Update.
15 * s390-tdep.c (s390_gdbarch_init): Update.
16 * rx-tdep.c (rx_gdbarch_init): Update.
17 * rs6000-tdep.c (rs6000_gdbarch_init): Update.
18 * riscv-tdep.c (riscv_gdbarch_init): Update.
19 * or1k-tdep.c (or1k_gdbarch_init): Update.
20 * nios2-tdep.c (nios2_gdbarch_init): Update.
21 * nds32-tdep.c (nds32_gdbarch_init): Update.
22 * mips-tdep.c (mips_gdbarch_init): Update.
23 * microblaze-tdep.c (microblaze_gdbarch_init): Update.
24 * m68k-tdep.c (m68k_gdbarch_init): Update.
25 * i386-tdep.c (i386_gdbarch_init): Update.
26 * arm-tdep.c (arm_gdbarch_init): Update.
27 * arc-tdep.c (arc_tdesc_init): Update.
28 (arc_gdbarch_init): Update.
29 * aarch64-tdep.c (aarch64_gdbarch_init): Update.
30
31 2020-09-17 Hannes Domani <ssbssa@yahoo.de>
32
33 * windows-nat.c (ctrl_c_handler): Use 32bit DbgUiRemoteBreakin
34 for WOW64 processes.
35
36 2020-09-17 Tom Tromey <tom@tromey.com>
37
38 * dwarf2/read.c (compute_compunit_symtab_includes): Use htab_up.
39
40 2020-09-17 Tom Tromey <tom@tromey.com>
41
42 * value.c (preserve_values): Update.
43 * python/py-type.c (save_objfile_types): Update.
44 * guile/scm-type.c (save_objfile_types): Update.
45 * gdbtypes.h (create_copied_types_hash): Return htab_up.
46 * gdbtypes.c (create_copied_types_hash): Return htab_up.
47 * compile/compile-object-run.c (compile_object_run): Update.
48
49 2020-09-17 Tom Tromey <tom@tromey.com>
50
51 * typeprint.h (class typedef_hash_table) <~typedef_hash_table>:
52 Remove.
53 <m_table>: Now htab_up.
54 * typeprint.c (typedef_hash_table::recursively_update)
55 (typedef_hash_table::add_template_parameters)
56 (typedef_hash_table::typedef_hash_table): Update.
57 (typedef_hash_table::~typedef_hash_table): Remove.
58 (typedef_hash_table::typedef_hash_table)
59 (typedef_hash_table::find_global_typedef)
60 (typedef_hash_table::find_typedef): Update.
61
62 2020-09-17 Tom Tromey <tom@tromey.com>
63
64 * target-descriptions.c (tdesc_use_registers): Use htab_up.
65
66 2020-09-17 Tom Tromey <tom@tromey.com>
67
68 * linespec.c (class decode_compound_collector)
69 <~decode_compound_collector>: Remove.
70 <m_unique_syms>: Now htab_up.
71 (decode_compound_collector::operator ()): Update.
72 (class symtab_collector) <~symtab_collector>: Remove.
73 <m_symtab_table>: Now htab_up.
74 (symtab_collector::operator ()): Update.
75
76 2020-09-17 Tom Tromey <tom@tromey.com>
77
78 * filename-seen-cache.c (filename_seen_cache::filename_seen_cache)
79 (filename_seen_cache::clear): Update.
80 (~filename_seen_cache): Remove.
81 (filename_seen_cache::seen): Update.
82 * filename-seen-cache.h (class filename_seen_cache) <m_tab>: Now
83 htab_up.
84 <~filename_seen_cache>: Remove.
85 <traverse>: Update.
86
87 2020-09-17 Tom Tromey <tom@tromey.com>
88
89 * completer.c (completion_tracker::discard_completions)
90 (completion_tracker::~completion_tracker)
91 (completion_tracker::maybe_add_completion)
92 (completion_tracker::remove_completion)
93 (completion_tracker::recompute_lowest_common_denominator)
94 (completion_tracker::build_completion_result): Update.
95 * completer.h (class completion_tracker) <have_completions>:
96 Update.
97 <m_entries_hash>: Now htab_up.
98
99 2020-09-17 Tom Tromey <tom@tromey.com>
100
101 * breakpoint.c (ambiguous_names_p): Use htab_up.
102
103 2020-09-17 Tom Tromey <tom@tromey.com>
104
105 * auto-load.c (struct auto_load_pspace_info)
106 <~auto_load_pspace_info, auto_load_pspace_info>: Remove.
107 <loaded_script_files, loaded_script_texts>: Change type to
108 htab_up.
109 (~auto_load_pspace_info) Remove.
110 (init_loaded_scripts_info, maybe_add_script_file)
111 (maybe_add_script_text, auto_load_info_scripts): Update.
112
113 2020-09-17 Tom Tromey <tromey@adacore.com>
114
115 * c-exp.y (name_obstack): Now static.
116
117 2020-09-17 Chungyi Chi <demonic@csie.io>
118
119 * riscv-tdep.c (riscv-insn::decode): Fix recorded insn type.
120
121 2020-09-16 Simon Marchi <simon.marchi@efficios.com>
122
123 * breakpoint.h (init_catchpoint): Change int parameter to bool.
124 (add_solib_catchpoint): Likewise.
125 * breakpoint.c (struct solib_catchpoint) <is_load>: Change type
126 to bool.
127 (add_solib_catchpoint): Change int parameter/variable to bool.
128 (catch_load_or_unload): Likewise.
129 (init_catchpoint): Likewise.
130 (create_fork_vfork_event_catchpoint): Likewise.
131 (catch_fork_command_1): Likewise.
132 (catch_exec_command_1): Likewise.
133
134 2020-09-16 Simon Marchi <simon.marchi@efficios.com>
135
136 * gdb-gdb.py.in (class StructTypePrettyPrinter) <to_string>:
137 Change instance_flags to m_instance_flags.
138
139 2020-09-16 Tom Tromey <tromey@adacore.com>
140
141 PR gdb/26598:
142 * infrun.c (fill_in_stop_func): Use find_pc_partial_function_sym.
143
144 2020-09-16 John Baldwin <jhb@FreeBSD.org>
145
146 * fbsd-nat.c (fbsd_nat_target::wait): Always check for
147 PL_FLAG_EXEC.
148 (fbsd_nat_target::insert_exec_catchpoint)
149 (fbsd_nat_target::remove_exec_catchpoint): Always define.
150 * fbsd-nat.h (fbsd_nat_target::insert_exec_catchpoint)
151 (fbsd_nat_target::remove_exec_catchpoint): Always declare.
152
153 2020-09-16 John Baldwin <jhb@FreeBSD.org>
154
155 * configure.ac: Remove check for kinfo_getvmmap().
156 * configure, config.in: Regenerate.
157 * fbsd-nat.c (fbsd_read_mapping): Remove
158 (fbsd_nat_target::find_memory_regions): Remove the procfs version.
159 (fbsd_nat_target::info_proc): Assume kinfo_getfile() and
160 kinfo_get_vmmap() are always present.
161
162 2020-09-16 John Baldwin <jhb@FreeBSD.org>
163
164 * fbsd-nat.c: Always include support for
165 TARGET_OBJECT_SIGNAL_INFO.
166
167 2020-09-16 John Baldwin <jhb@FreeBSD.org>
168
169 * fbsd-nat.c (fbsd_nat_target::pid_to_exec_file): Always use
170 sysctl and remove procfs fallback.
171
172 2020-09-16 John Baldwin <jhb@FreeBSD.org>
173
174 * fbsd-nat.c: Assume PT_LWPINFO is always defined.
175 * fbsd-nat.h: Likewise.
176
177 2020-09-16 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
178
179 * breakpoint.c (commands_command_1): Make a copy of the 'arg'
180 argument.
181
182 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
183
184 * ada-lang.c (ada_language_data): Delete.
185 (ada_language): Remove references to ada_language_data.
186 * c-lang.c (c_language_data): Delete.
187 (c_language): Remove references to c_language_data.
188 (cplus_language_data): Delete.
189 (cplus_language): Remove references to cplus_language_data.
190 (asm_language_data): Delete.
191 (asm_language): Remove references to asm_language_data.
192 (minimal_language_data): Delete.
193 (minimal_language): Remove references to minimal_language_data.
194 * d-lang.c (d_language_data): Delete.
195 (d_language): Remove references to d_language_data.
196 * f-lang.c (f_language_data): Delete.
197 (f_language): Remove references to f_language_data.
198 * go-lang.c (go_language_data): Delete.
199 (go_language): Remove references to go_language_data.
200 * language.c (unknown_language_data): Delete.
201 (unknown_language): Remove references to unknown_language_data.
202 (auto_language_data): Delete.
203 (auto_language): Remove references to auto_language_data.
204 * language.h (language_data): Delete struct.
205 (language_defn): No longer inherit from language_data.
206 * m2-lang.c (m2_language_data): Delete.
207 (m2_language): Remove references to m2_language_data.
208 * objc-lang.c (objc_language_data): Delete.
209 (objc_language): Remove references to objc_language_data.
210 * opencl-lang.c (opencl_language_data): Delete.
211 (opencl_language): Remove references to opencl_language_data.
212 * p-lang.c (pascal_language_data): Delete.
213 (pascal_language): Remove references to pascal_language_data.
214 * rust-lang.c (rust_language_data): Delete.
215 (rust_language): Remove references to rust_language_data.
216
217 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
218
219 * ada-lang.c (ada_language_data): Remove la_op_print_tab
220 initializer.
221 (ada_language::opcode_print_table): New member function.
222 * c-lang.c (c_language_data): Remove la_op_print_tab initializer.
223 (c_language::opcode_print_table): New member function.
224 (cplus_language_data): Remove la_op_print_tab initializer.
225 (cplus_language::opcode_print_table): New member function.
226 (asm_language_data): Remove la_op_print_tab initializer.
227 (asm_language::opcode_print_table): New member function.
228 (minimal_language_data): Remove la_op_print_tab initializer.
229 (minimal_language::opcode_print_table): New member function.
230 * d-lang.c (d_language_data): Remove la_op_print_tab initializer.
231 (d_language::opcode_print_table): New member function.
232 * expprint.c (print_subexp_standard): Update call to
233 opcode_print_table.
234 (op_string): Likewise.
235 * f-lang.c (f_language_data): Remove la_op_print_tab initializer.
236 (f_language::opcode_print_table): New member function.
237 * go-lang.c (go_language_data): Remove la_op_print_tab
238 initializer.
239 (go_language::opcode_print_table): New member function.
240 * language.c (unknown_language_data): Remove la_op_print_tab
241 initializer.
242 (unknown_language::opcode_print_table): New member function.
243 (auto_language_data): Remove la_op_print_tab initializer.
244 (auto_language::opcode_print_table): New member function.
245 * language.h (language_data): Remove la_op_print_tab field.
246 (language_defn::opcode_print_table): Declare new member function.
247 * m2-lang.c (m2_language_data): Remove la_op_print_tab
248 initializer.
249 (m2_language::opcode_print_table): New member function.
250 * objc-lang.c (objc_language_data): Remove la_op_print_tab
251 initializer.
252 (objc_language::opcode_print_table): New member function.
253 * opencl-lang.c (opencl_language_data): Remove la_op_print_tab
254 initializer.
255 (opencl_language::opcode_print_table): New member function.
256 * p-lang.c (pascal_language_data): Remove la_op_print_tab
257 initializer.
258 (pascal_language::opcode_print_table): New member function.
259 * rust-lang.c (rust_language_data): Remove la_op_print_tab
260 initializer.
261 (rust_language::opcode_print_table): New member function.
262
263 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
264
265 * ada-lang.c (ada_language_data): Remove la_exp_desc initializer.
266 (ada_language::expression_ops): New member function.
267 * c-lang.c (c_language_data): Remove la_exp_desc initializer.
268 (c_language::expression_ops): New member function.
269 (cplus_language_data): Remove la_exp_desc initializer.
270 (cplus_language::expression_ops): New member function.
271 (asm_language_data): Remove la_exp_desc initializer.
272 (asm_language::expression_ops): New member function.
273 (minimal_language_data): Remove la_exp_desc initializer.
274 (minimal_language::expression_ops): New member function.
275 * d-lang.c (d_language_data): Remove la_exp_desc initializer.
276 (d_language::expression_ops): New member function.
277 * eval.c (evaluate_subexp): Update call to expression_ops.
278 * expprint.c (print_subexp): Likewise.
279 (op_name): Likewise.
280 (dump_subexp_body): Likewise.
281 * f-lang.c (f_language_data): Remove la_exp_desc initializer.
282 (f_language::expression_ops): New member function.
283 * go-lang.c (go_language_data): Remove la_exp_desc initializer.
284 (go_language::expression_ops): New member function.
285 * language.c (language_defn::expression_ops): New function.
286 (unknown_language_data): Remove la_exp_desc initializer.
287 (auto_language_data): Likewise.
288 * language.h (language_data): Remove la_exp_desc field.
289 (language_defn::expression_ops): Declare new member function.
290 * m2-lang.c (m2_language_data): Remove la_exp_desc initializer.
291 (m2_language::expression_ops): New member function.
292 * objc-lang.c (objc_language_data): Remove la_exp_desc
293 initializer.
294 * opencl-lang.c (opencl_language_data): Remove la_exp_desc
295 initializer.
296 (opencl_language::expression_ops): New member function.
297 * p-lang.c (pascal_language_data): Remove la_exp_desc initializer.
298 * parse.c (operator_length): Update call to expression_ops.
299 (exp_iterate): Likewise.
300 * rust-lang.c (rust_language_data): Remove la_exp_desc
301 initializer.
302 (ruse_language::expression_ops): New member function.
303
304 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
305
306 * ada-lang.c (ada_language_data): Remove la_varobj_ops
307 initializer.
308 (ada_language::varobj_ops): New member function.
309 * c-lang.c (c_language_data): Remove la_varobj_ops
310 initializer.
311 (cplus_language_data): Likewise.
312 (cplus_language::varobj_ops): New member function.
313 (asm_language_data): Remove la_varobj_ops initializer.
314 (minimal_language_data): Likewise.
315 * d-lang.c (d_language_data): Likewise.
316 * f-lang.c (f_language_data): Likewise.
317 * go-lang.c (go_language_data): Likewise.
318 * language.c (language_defn::varobj_ops): New function.
319 (unknown_language_data): Remove la_varobj_ops
320 initializer.
321 (auto_language_data): Likewise.
322 * language.h (language_data): Remove la_varobj_ops field.
323 (language_defn::varobj_ops): Declare new member function.
324 * m2-lang.c (m2_language_data): Remove la_varobj_ops initializer.
325 * objc-lang.c (objc_language_data): Likewise.
326 * opencl-lang.c (opencl_language_data): Likewise.
327 * p-lang.c (pascal_language_data): Likewise.
328 * rust-lang.c (rust_language_data): Likewise.
329 * varobj.c (varobj_create): Update call to varobj_ops.
330 * varobj.h (default_varobj_ops): Delete define.
331
332 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
333
334 * ada-lang.c (ada_language_data): Remove la_macro_expansion
335 initializer.
336 * c-lang.c (c_language_data): Likewise.
337 (c_language::macro_expansion): New member function.
338 (cplus_language_data): Likewise.
339 (cplus_language::macro_expansion): New member function.
340 (asm_language_data): Likewise.
341 (asm_language::macro_expansion): New member function.
342 (minimal_language_data): Likewise.
343 (minimal_language::macro_expansion): New member function.
344 * d-lang.c (d_language_data): Remove la_macro_expansion
345 initializer.
346 * f-lang.c (f_language_data): Likewise.
347 * go-lang.c (go_language_data): Likewise.
348 * language.c (unknown_language_data): Likewise.
349 (auto_language_data): Likewise.
350 * language.h (language_data): Remove la_macro_expansion field.
351 (language_defn::macro_expansion): New member function.
352 * m2-lang.c (m2_language_data): Remove la_macro_expansion
353 initializer.
354 * objc-lang.c (objc_language_data): Likewise.
355 (objc_language::macro_expansion): New member function.
356 * opencl-lang.c (opencl_language_data): Likewise.
357 (opencl_language::macro_expansion): New member function.
358 * p-lang.c (pascal_language_data): Remove la_macro_expansion
359 initializer.
360 * rust-lang.c (rust_language_data): Likewise.
361 * symtab.c (default_collect_symbol_completion_matches_break_on):
362 Update call to macro_expansion.
363
364 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
365
366 * ada-lang.c (ada_language_data): Remove la_array_ordering
367 initializer.
368 * c-lang.c (c_language_data): Likewise.
369 (cplus_language_data): Likewise.
370 (asm_language_data): Likewise.
371 (minimal_language_data): Likewise.
372 * d-lang.c (d_language_data): Likewise.
373 * dwarf2/read.c (read_array_order): Update for call to
374 array_ordering.
375 * f-lang.c (f_language_data): Remove la_array_ordering
376 initializer.
377 (f_language::array_ordering): New member function.
378 * go-lang.c (go_language_data): Remove la_array_ordering
379 initializer.
380 * language.c (unknown_language_data): Likewise.
381 (auto_language_data): Likewise.
382 * language.h (language_data): Delete la_array_ordering field.
383 (language_defn::array_ordering): New member function.
384 * m2-lang.c (m2_language_data): Remove la_array_ordering
385 initializer.
386 * objc-lang.c (objc_language_data): Likewise.
387 * opencl-lang.c (opencl_language_data): Likewise.
388 * p-lang.c (pascal_language_data): Likewise.
389 * rust-lang.c (rust_language_data): Likewise.
390
391 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
392
393 * ada-lang.c (ada_language_data): Remove la_case_sensitivity
394 initializer.
395 * c-lang.c (c_language_data): Likewise.
396 (cplus_language_data): Likewise.
397 (asm_language_data): Likewise.
398 (minimal_language_data): Likewise.
399 * d-lang.c (d_language_data): Likewise.
400 * f-lang.c (f_language_data): Likewise.
401 (f_language::case_sensitivity): New member function.
402 * go-lang.c (go_language_data): Remove la_case_sensitivity
403 initializer.
404 * language.c (enum case_mode): Moved here from language.h.
405 (case_mode): Make static.
406 (show_case_command): Update for case_sensitivity being a method.
407 (set_case_command): Likewise.
408 (set_range_case): Likewise.
409 (unknown_language_data): Remove la_case_sensitivity initializer.
410 (auto_language_data): Likewise.
411 * language.h (case_mode): Delete, move enum declaration to
412 language.c.
413 (language_data): Delete la_case_sensitivity field.
414 (language_defn::case_sensitivity): New member function.
415 * m2-lang.c (m2_language_data): Remove la_case_sensitivity
416 initializer.
417 * objc-lang.c (objc_language_data): Likewise.
418 * opencl-lang.c (opencl_language_data): Likewise.
419 * p-lang.c (pascal_language_data): Likewise.
420 * rust-lang.c (rust_language_data): Likewise.
421
422 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
423
424 * ada-lang.c (ada_language_data): Remove la_range_check
425 initializer.
426 * c-lang.c (c_language_data): Likewise.
427 (cplus_language_data): Likewise.
428 (asm_language_data): Likewise.
429 (minimal_language_data): Likewise.
430 * d-lang.c (d_language_data): Likewise.
431 * f-lang.c (f_language_data): Likewise.
432 (f_language::range_checking_on_by_default): New member function.
433 * go-lang.c (go_language_data): Remove la_range_check initializer.
434 * language.c (enum range_mode): Moved here from language.h.
435 (range_mode): Made static.
436 (show_range_command): Update to use
437 range_checking_on_by_default.
438 (set_range_command): Likewise.
439 (set_range_case): Likewise.
440 (unknown_language_data): Remove la_range_check initializer.
441 (auto_language_data): Likewise.
442 * language.h (range_mode): Delete. Enum definition moved to
443 language.c.
444 (language_data): Remove la_range_check field.
445 (language_defn::range_checking_on_by_default): New member
446 function.
447 * m2-lang.c (m2_language_data): Remove la_range_check initializer.
448 (m2_language::range_checking_on_by_default): New member function.
449 * objc-lang.c (objc_language_data): Remove la_range_check
450 initializer.
451 * opencl-lang.c (opencl_language_data): Likewise.
452 * p-lang.c (pascal_language_data): Likewise.
453 (pascal_language::range_checking_on_by_default): New member
454 function.
455 * rust-lang.c (rust_language_data): Remove la_range_check
456 initializer.
457 (rust_language::range_checking_on_by_default): New member
458 function.
459
460 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
461
462 * dwarf2/read.c (dwarf2_physname): Remove special case for
463 language_go.
464 * go-lang.c (go_language::store_sym_names_in_linkage_form_p): New
465 member function.
466
467 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
468
469 * ada-lang.c (ada_language_data): Remove
470 la_store_sym_names_in_linkage_form_p initializer.
471 (ada_language::store_sym_names_in_linkage_form_p): New member
472 function.
473 * c-lang.c (c_language_data): Remove
474 la_store_sym_names_in_linkage_form_p initializer.
475 (c_language::store_sym_names_in_linkage_form_p): New member
476 function.
477 (cplus_language_data): Remove la_store_sym_names_in_linkage_form_p
478 initializer.
479 (asm_language_data): Likewise.
480 (asm_language::store_sym_names_in_linkage_form_p): New member
481 function.
482 (minimal_language_data): Remove
483 la_store_sym_names_in_linkage_form_p initializer.
484 (minimal_language::store_sym_names_in_linkage_form_p): New member
485 function.
486 * d-lang.c (d_language_data): Remove
487 la_store_sym_names_in_linkage_form_p initializer.
488 * dwarf2/read.c (dwarf2_physname): Update call to
489 store_sym_names_in_linkage_form_p.
490 * f-lang.c (f_language_data): Remove
491 la_store_sym_names_in_linkage_form_p initializer.
492 * go-lang.c (go_language_data): Remove
493 la_store_sym_names_in_linkage_form_p initializer.
494 * language.c (unknown_language_data): Remove
495 la_store_sym_names_in_linkage_form_p initializer.
496 (unknown_language::store_sym_names_in_linkage_form_p): New member
497 function.
498 (auto_language_data): Remove la_store_sym_names_in_linkage_form_p
499 initializer.
500 (auto_language::store_sym_names_in_linkage_form_p): New member
501 function.
502 * language.h (language_data): Remove
503 la_store_sym_names_in_linkage_form_p member variable.
504 (language_defn::store_sym_names_in_linkage_form_p): New member
505 function.
506 * m2-lang.c (m2_language_data): Remove
507 la_store_sym_names_in_linkage_form_p initializer.
508 * objc-lang.c (objc_language_data): Likewise.
509 * opencl-lang.c (opencl_language_data): Likewise.
510 * p-lang.c (pascal_language_data): Likewise.
511 * rust-lang.c (rust_language_data): Likewise.
512
513 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
514
515 * ada-lang.c (ada_language_data): Remove string_lower_bound
516 initializer.
517 * c-lang.c (c_language_data): Likewise.
518 (cplus_language_data): Likewise.
519 (asm_language_data): Likewise.
520 (minimal_language_data): Likewise.
521 * d-lang.c (d_language_data): Likewise.
522 * f-lang.c (f_language_data): Likewise.
523 * go-lang.c (go_language_data): Likewise.
524 * language.c (unknown_language_data): Likewise.
525 (auto_language_data): Likewise.
526 * language.h (language_data): Remove string_lower_bound field.
527 (language_defn::string_lower_bound): New member function.
528 * m2-lang.c (m2_language_data): Remove string_lower_bound
529 initializer.
530 (m2_language::string_lower_bound): New member function.
531 * objc-lang.c (objc_language_data): Remove string_lower_bound
532 initializer.
533 * opencl-lang.c (opencl_language_data): Likewise.
534 * p-lang.c (pascal_language_data): Likewise.
535 * rust-lang.c (rust_language_data): Likewise.
536 * valops.c (value_cstring): Update call to string_lower_bound.
537 (value_string): Likewise.
538 * value.c (allocate_repeated_value): Likewise.
539
540 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
541
542 * valops.c (value_repeat): Fix incorrect argument name in comment.
543
544 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
545
546 * ada-lang.c (ada_language_data): Remove c_style_arrays
547 initializer.
548 (ada_language::c_style_arrays_p): New member fuction.
549 * c-lang.c (c_language_data): Remove c_style_arrays
550 initializer.
551 (cplus_language_data): Likewise.
552 (asm_language_data): Likewise.
553 (minimal_language_data): Likewise.
554 * d-lang.c (d_language_data): Likewise.
555 * eval.c (ptrmath_type_p): Update call to c_style_arrays_p.
556 * f-lang.c (f_language_data): Remove c_style_arrays initializer.
557 (f_language::c_style_arrays_p): New member function.
558 * go-lang.c (go_language_data): Remove c_style_arrays initializer.
559 * infcall.c (value_arg_coerce): Update call to c_style_arrays_p.
560 * language.c (unknown_language_data): Remove c_style_arrays
561 initializer.
562 (auto_language_data): Likewise.
563 * language.h (language_data): Remove c_style_arrays field.
564 (language_defn::c_style_arrays_p): New member function.
565 * m2-lang.c (m2_language_data): Remove c_style_arrays initializer.
566 (m2_language::c_style_arrays_p): New member function.
567 * objc-lang.c (objc_language_data): Remove c_style_arrays
568 initializer.
569 * opencl-lang.c (opencl_language_data): Likewise.
570 * p-lang.c (pascal_language_data): Likewise.
571 * rust-lang.c (rust_language_data): Likewise.
572 * valarith.c (value_subscript): Update call to c_style_arrays_p,
573 and update local variable to a bool.
574 * valops.c (value_cast): Update call to c_style_arrays_p.
575 (value_array): Likewise.
576 * value.c (coerce_array): Likewise.
577
578 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
579
580 * ada-lang.c (ada_language_data): Remove la_language initializer.
581 * c-lang.c (c_language_data): Likewise.
582 (cplus_language_data): Likewise.
583 (asm_language_data): Likewise.
584 (minimal_language_data): Likewise.
585 * d-lang.c (d_language_data): Likewise.
586 * f-lang.c (f_language_data): Likewise.
587 * go-lang.c (go_language_data): Likewise.
588 * language.c (unknown_language_data): Likewise.
589 (auto_language_data): Likewise.
590 * language.h (language_data): Remove la_language field.
591 (language_defn::language_defn): Initialise la_language field.
592 (language_defn::la_language): New member variable.
593 * m2-lang.c (m2_language_data): Remove la_language field.
594 * objc-lang.c (objc_language_data): Likewise.
595 * opencl-lang.c (opencl_language_data): Likewise.
596 * p-lang.c (pascal_language_data): Likewise.
597 * rust-lang.c (rust_language_data): Likewise.
598
599 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
600
601 * ada-lang.c (ada_extensions): Delete, moved into
602 ada_language::filename_extensions.
603 (ada_language_data): Remove la_filename_extensions initializer.
604 (ada_language::filename_extensions): New member function.
605 * c-lang.c (c_extensions): Delete, moved into
606 c_language::filename_extensions.
607 (c_language_data): Remove la_filename_extensions initializer.
608 (c_language::filename_extensions): New member function.
609 (cplus_extensions): Delete, moved into
610 cplus_language::filename_extensions.
611 (cplus_language_data): Remove la_filename_extensions initializer.
612 (cplus_language::filename_extensions): New member function.
613 (asm_extensions): Delete, moved into
614 asm_language::filename_extensions.
615 (asm_language_data): Remove la_filename_extensions initializer.
616 (asm_language::filename_extensions): New member function.
617 (minimal_language_data): Remove la_filename_extensions
618 initializer.
619 * d-lang.c (d_extensions): Delete, moved into
620 d_language::filename_extensions.
621 (d_language_data): Remove la_filename_extensions initializer.
622 (d_language::filename_extensions): New member function.
623 * f-lang.c (f_extensions): Delete, moved into
624 f_language::filename_extensions.
625 (f_language_data): Remove la_filename_extensions initializer.
626 (f_language::filename_extensions): New member function.
627 * go-lang.c (go_language_data): Remove la_filename_extensions
628 initializer.
629 * language.c (add_set_language_command): Update now that
630 filename_extensions returns a vector.
631 (unknown_language_data): Remove la_filename_extensions
632 initializer.
633 (auto_language_data): Likewise.
634 * language.h (language_data): Remove la_filename_extensions field.
635 (language_defn::filename_extensions): New member function.
636 * m2-lang.c (m2_language_data): Remove la_filename_extensions
637 initializer.
638 * objc-lang.c (objc_extensions): Delete, moved into
639 objc_language::filename_extensions.
640 (objc_language_data): Remove la_filename_extensions initializer.
641 (objc_language::filename_extensions): New member function.
642 * opencl-lang.c (opencl_language_data): Remove
643 la_filename_extensions initializer.
644 * p-lang.c (pascal_extensions): Delete, moved into
645 pascal_language::filename_extensions.
646 (pascal_language_data): Remove la_filename_extensions initializer.
647 (pascal_language::filename_extensions): New member function.
648 * rust-lang.c (rust_extensions): Delete, moved into
649 rust_language::filename_extensions.
650 (rust_language_data): Remove la_filename_extensions initializer.
651 (rust_language::filename_extensions): New member function.
652 * symfile.c (add_filename_language): Add new assert.
653
654 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
655
656 * ada-lang.c (ada_language_data): Remove la_name and
657 la_natural_name initializers.
658 (ada_language::name): New member function.
659 (ada_language::natural_name): New member function.
660 * c-lang.c (c_language_data): Remove la_name and
661 la_natural_name initializers.
662 (c_language::name): New member function.
663 (c_language::natural_name): New member function.
664 (cplus_language_data): Remove la_name and
665 la_natural_name initializers.
666 (cplus_language::name): New member function.
667 (cplus_language::natural_name): New member function.
668 (asm_language_data): Remove la_name and
669 la_natural_name initializers.
670 (asm_language::name): New member function.
671 (asm_language::natural_name): New member function.
672 (minimal_language_data): Remove la_name and
673 la_natural_name initializers.
674 (minimal_language::name): New member function.
675 (minimal_language::natural_name): New member function.
676 * compile/compile.c (compile_to_object): Update call to
677 lanugage_defn::name.
678 * d-lang.c (d_language_data): Remove la_name and
679 la_natural_name initializers.
680 (d_language::name): New member function.
681 (d_language::natural_name): New member function.
682 * expprint.c (print_subexp_standard): Update call to
683 language_defn::name.
684 (dump_raw_expression): Likewise
685 (dump_prefix_expression): Likewise.
686 * f-lang.c (f_language_data): Remove la_name and
687 la_natural_name initializers.
688 (f_language::name): New member function.
689 (f_language::natural_name): New member function.
690 * go-lang.c (go_language_data): Remove la_name and
691 la_natural_name initializers.
692 (go_language::name): New member function.
693 (go_language::natural_name): New member function.
694 * language.c (show_language_command): Update call to
695 language_defn::name.
696 (set_language_command): Likewise.
697 (language_enum): Likewise.
698 (language_str): Likewise.
699 (add_set_language_command): Likewise, use
700 language_defn::natural_name in the doc string.
701 (unknown_language_data): Remove la_name and
702 la_natural_name initializers.
703 (unknown_language::name): New member function.
704 (unknown_language::natural_name): New member function.
705 (auto_language_data): Remove la_name and
706 la_natural_name initializers.
707 (auto_language::name): New member function.
708 (auto_language::natural_name): New member function.
709 (language_lookup_primitive_type_as_symbol): Update call to
710 language_defn::name.
711 * language.h (language_data): Remove la_name and la_natural_name
712 member variables.
713 (language_defn::name): New member function.
714 (language_defn::natural_name): New member function.
715 * m2-lang.c (m2_language_data): Remove la_name and
716 la_natural_name initializers.
717 (m2_language::name): New member function.
718 (m2_language::natural_name): New member function.
719 * mi/mi-cmd-var.c (mi_cmd_var_info_expression): Update call to
720 language_defn::natural_name.
721 * objc-lang.c (objc_language_data): Remove la_name and
722 la_natural_name initializers.
723 (objc_language::name): New member function.
724 (objc_language::natural_name): New member function.
725 * opencl-lang.c (opencl_language_data): Remove la_name and
726 la_natural_name initializers.
727 (opencl_language::name): New member function.
728 (opencl_language::natural_name): New member function.
729 * p-lang.c (pascal_language_data): Remove la_name and
730 la_natural_name initializers.
731 (pascal_language::name): New member function.
732 (pascal_language::natural_name): New member function.
733 * rust-lang.c (rust_language_data): Remove la_name and
734 la_natural_name initializers.
735 (rust_language::name): New member function.
736 (rust_language::natural_name): New member function.
737 * symtab.c (lookup_language_this): Update call to
738 language_defn::name.
739
740 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
741
742 * ada-lang.c (ada_language_data): Remove la_name_of_this
743 initializer.
744 * ax-gdb.c (gen_expr): Update call to name_of_this.
745 * c-exp.y (classify_name): Likewise.
746 * c-lang.c (c_language_data): Remove la_name_of_this initializer.
747 (cplus_language_data): Likewise.
748 (cplus_language::name_of_this): New member function.
749 (asm_language_data): Remove la_name_of_this initializer.
750 (minimal_language_data): Likewise.
751 * d-lang.c (d_language_data): Likewise.
752 (d_language::name_of_this): New member function.
753 * expprint.c (print_subexp_standard): Update call to name_of_this.
754 * f-lang.c (f_language_data): Remove la_name_of_this initializer.
755 * go-lang.c (go_language_data): Likewise.
756 * language.c (unknown_language_data): Likewise.
757 (unknown_language::name_of_this): New member function.
758 (auto_language_data): Remove la_name_of_this initializer.
759 (auto_language::name_of_this): New member function.
760 * language.h (language_data): Delete la_name_of_this member
761 variable.
762 (language_defn::name_of_this): New member function.
763 * m2-lang.c (m2_language_data): Remove la_name_of_this
764 initializer.
765 * objc-lang.c (objc_language_data): Likewise.
766 (objc_language::name_of_this): New member function.
767 * opencl-lang.c (opencl_language_data): Remove la_name_of_this
768 initializer.
769 * p-lang.c (pascal_language_data): Likewise.
770 (pascal_language::name_of_this): New member function.
771 * rust-lang.c (rust_language_data): Remove la_name_of_this
772 initializer.
773 * symtab.c (lookup_language_this): Update call to name_of_this.
774 (lookup_symbol_aux): Likewise.
775 * valops.c (value_of_this): Likewise.
776
777 2020-09-16 Andrew Burgess <andrew.burgess@embecosm.com>
778
779 * ada-lang.c (ada_language_data): Remove
780 la_struct_too_deep_ellipsis initializer.
781 (ada_language::struct_too_deep_ellipsis): New member function.
782 * c-lang.c (c_language_data): Remove la_struct_too_deep_ellipsis
783 initializer.
784 (cplus_language_data): Likewise.
785 (asm_language_data): Likewise.
786 (minimal_language_data): Likewise.
787 * cp-valprint.c (cp_print_value): Update call to
788 struct_too_deep_ellipsis.
789 * d-lang.c (d_language_data): Remove la_struct_too_deep_ellipsis
790 initializer.
791 * f-lang.c (f_language_data): Likewise.
792 (f_language::struct_too_deep_ellipsis): New member function.
793 * go-lang.c (go_language_data): Remove la_struct_too_deep_ellipsis
794 initializer.
795 * language.c (unknown_language_data): Likewise.
796 (auto_language_data): Likewise.
797 * language.h (language_data): Delete la_struct_too_deep_ellipsis
798 member variable.
799 (language_defn::struct_too_deep_ellipsis): New member function.
800 * m2-lang.c (m2_language_data): Remove la_struct_too_deep_ellipsis
801 initializer.Q
802 * objc-lang.c (objc_language_data): Likewise.
803 * opencl-lang.c (opencl_language_data): Likewise.
804 * p-lang.c (pascal_language_data): Likewise.
805 * rust-lang.c (rust_language_data): Likewise.
806 * valprint.c (val_print_check_max_depth): Update call to
807 struct_too_deep_ellipsis.
808
809 2020-09-16 Felix Willgerodt <felix.willgerodt@intel.com>
810
811 * MAINTAINERS (Write After Approval): Add myself.
812
813 2020-09-15 Tom Tromey <tom@tromey.com>
814
815 * f-valprint.c (f_value_print_inner) <case TYPE_CODE_INT>:
816 Remove.
817
818 2020-09-15 Tom Tromey <tom@tromey.com>
819
820 * rust-lang.c (rust_value_print_inner): Remove TYPE_CODE_MEMBERPTR
821 and TYPE_CODE_METHODPTR cases.
822 * c-valprint.c (c_value_print_memberptr): Move to valprint.c.
823 (c_value_print_inner): Update.
824 * valprint.c (generic_value_print_memberptr): New function, from
825 c_value_print_memberptr.
826 (generic_value_print): Use it. Call cplus_print_method_ptr.
827
828 2020-09-15 Tom Tromey <tromey@adacore.com>
829
830 * python/python-internal.h (PyInt_FromLong): Remove define.
831 * python/py-value.c (convert_value_from_python): Use
832 gdb_py_object_from_longest.
833 * python/py-type.c (typy_get_code): Use
834 gdb_py_object_from_longest.
835 * python/py-symtab.c (salpy_get_line): Use
836 gdb_py_object_from_longest.
837 * python/py-symbol.c (sympy_get_addr_class, sympy_line): Use
838 gdb_py_object_from_longest.
839 * python/py-record.c (recpy_gap_reason_code): Use
840 gdb_py_object_from_longest.
841 * python/py-record-btrace.c (recpy_bt_insn_size)
842 (recpy_bt_func_level, btpy_list_count): Use
843 gdb_py_object_from_longest.
844 * python/py-infthread.c (gdbpy_create_ptid_object): Use
845 gdb_py_object_from_longest. Fix error handling.
846 * python/py-framefilter.c (bootstrap_python_frame_filters): Use
847 gdb_py_object_from_longest.
848 * python/py-frame.c (frapy_type, frapy_unwind_stop_reason): Use
849 gdb_py_object_from_longest.
850 * python/py-breakpoint.c (bppy_get_type, bppy_get_number)
851 (bppy_get_thread, bppy_get_task, bppy_get_hit_count)
852 (bppy_get_ignore_count): Use gdb_py_object_from_longest.
853
854 2020-09-15 Tom Tromey <tromey@adacore.com>
855
856 * python/python.c (gdbpy_parameter_value): Use
857 gdb_py_object_from_ulongest.
858
859 2020-09-15 Tom Tromey <tromey@adacore.com>
860
861 * python/py-infevents.c (create_register_changed_event_object):
862 Use gdb_py_object_from_longest.
863 * python/py-exitedevent.c (create_exited_event_object): Use
864 gdb_py_object_from_longest.
865
866 2020-09-15 Tom Tromey <tromey@adacore.com>
867
868 * python/python.c (gdbpy_parameter_value): Use
869 gdb_py_object_from_longest.
870 * python/py-type.c (convert_field, typy_range): Use
871 gdb_py_object_from_longest.
872 * python/py-tui.c (gdbpy_tui_width, gdbpy_tui_height): Use
873 gdb_py_object_from_longest.
874 * python/py-lazy-string.c (stpy_get_length): Use
875 gdb_py_object_from_longest.
876 * python/py-infthread.c (thpy_get_num, thpy_get_global_num): Use
877 gdb_py_object_from_longest.
878 * python/py-infevents.c (create_memory_changed_event_object): Use
879 gdb_py_object_from_longest.
880 * python/py-inferior.c (infpy_get_num): Use
881 gdb_py_object_from_longest.
882 (infpy_get_pid): Likewise.
883
884 2020-09-15 Tom Tromey <tromey@adacore.com>
885
886 * python/python-internal.h (gdb_py_long_from_ulongest): Remove
887 defines.
888 * python/py-value.c (valpy_long): Use
889 gdb_py_object_from_ulongest.
890 * python/py-symtab.c (salpy_get_pc): Use
891 gdb_py_object_from_ulongest.
892 (salpy_get_last): Likewise.
893 * python/py-record-btrace.c (recpy_bt_insn_pc): Use
894 gdb_py_object_from_ulongest.
895 * python/py-lazy-string.c (stpy_get_address): Use
896 gdb_py_object_from_ulongest.
897 * python/py-frame.c (frapy_pc): Use gdb_py_object_from_ulongest.
898 * python/py-arch.c (archpy_disassemble): Use
899 gdb_py_object_from_ulongest and gdb_py_object_from_longest. Fix
900 error handling.
901
902 2020-09-15 Tom Tromey <tromey@adacore.com>
903
904 * python/python-internal.h (gdb_py_long_from_longest): Remove
905 defines.
906 * python/py-value.c (valpy_long): Use gdb_py_object_from_longest.
907 * python/py-type.c (convert_field, typy_get_sizeof): Use
908 gdb_py_object_from_longest.
909 * python/py-record-btrace.c (btpy_list_index): Use
910 gdb_py_object_from_longest.
911
912 2020-09-15 Tom Tromey <tromey@adacore.com>
913
914 * python/python-internal.h (PyInt_FromSsize_t): Remove define.
915 * python/py-record.c (recpy_element_number): Use
916 gdb_py_object_from_longest.
917 (recpy_gap_number): Likewise.
918
919 2020-09-15 Tom Tromey <tromey@adacore.com>
920
921 * top.c (ui::ui): Update.
922 (highest_ui_num): Remove.
923 * top.h (struct ui) <num>: Remove.
924
925 2020-09-15 Tom Tromey <tromey@adacore.com>
926
927 * unittests/memory-map-selftests.c (valid_mem_map): Now array.
928 * ui-style.c (ansi_regex_text): Now array.
929 * rust-exp.y (number_regex_text): Now array.
930 * linespec.c (linespec_quote_characters): Now array.
931 * jit.c (jit_break_name, jit_descriptor_name, reader_init_fn_sym):
932 Now arrays.
933
934 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
935
936 * debuginfod-support.c (debuginfod_client_deleter): New.
937 (debuginfod_client_up): New.
938 (debuginfod_init): Return debuginfod_client_up.
939 (debuginfod_source_query): Adjust.
940 (debuginfod_debuginfo_query): Adjust.
941
942 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
943
944 * debuginfod-support.c (debuginfod_source_query): Use
945 make_unique_xstrdup.
946
947 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
948
949 * gdbtypes.h (TYPE_INSTANCE_FLAGS): Remove, replace all uses
950 with `type::instance_flags`.
951
952 2020-09-14 Michael Mullin <masmullin@gmail.com>
953
954 * xml-tdesc.c [!defined(HAVE_LIBEXPAT)] (tdesc_parse_xml):
955 Remove baton parameter.
956
957 2020-09-14 Pedro Alves <pedro@palves.net>
958
959 * Makefile.in (SELFTESTS_SRCS): Add
960 unittests/enum-flags-selftests.c.
961 * btrace.c (ftrace_update_caller, ftrace_fixup_calle): Use
962 btrace_function_flags instead of enum btrace_function_flag.
963 * compile/compile-c-types.c (convert_qualified): Use
964 enum_flags::raw.
965 * compile/compile-cplus-symbols.c (convert_one_symbol)
966 (convert_symbol_bmsym):
967 * compile/compile-cplus-types.c (compile_cplus_convert_method)
968 (compile_cplus_convert_struct_or_union_methods)
969 (compile_cplus_instance::convert_qualified_base):
970 * go-exp.y (parse_string_or_char): Add cast to int.
971 * unittests/enum-flags-selftests.c: New file.
972 * record-btrace.c (btrace_thread_flag_to_str): Change parameter's
973 type to btrace_thread_flags from btrace_thread_flag.
974 (record_btrace_cancel_resume, record_btrace_step_thread): Change
975 local's type to btrace_thread_flags from btrace_thread_flag. Add
976 cast in DEBUG call.
977
978 2020-09-14 Pedro Alves <pedro@palves.net>
979
980 * c-typeprint.c (c_type_print_modifier): Adjust to rename.
981 * gdbtypes.c (address_space_name_to_int): Rename to ...
982 (address_space_name_to_type_instance_flags): ... this.
983 (address_space_int_to_name): Rename to ...
984 (address_space_type_instance_flags_to_name): ... this.
985 * gdbtypes.h (address_space_name_to_int): Rename to ...
986 (address_space_name_to_type_instance_flags): ... this.
987 (address_space_int_to_name): Rename to ...
988 (address_space_type_instance_flags_to_name): ... this.
989 * type-stack.c (type_stack::insert): Adjust to rename.
990 * type-stack.h (type_stack::insert): Likewise.
991
992 2020-09-14 Pedro Alves <pedro@palves.net>
993 Andrew Burgess <andrew.burgess@embecosm.com>
994
995 * avr-tdep.c (avr_address_class_type_flags): Return
996 type_instance_flags.
997 (avr_address_class_type_flags_to_name): Take a
998 type_instance_flags.
999 (avr_address_class_name_to_type_flags): Return bool and take a
1000 type_instance_flags.
1001 * d-lang.c (build_d_types): Use type::set_instance_flags.
1002 * ft32-tdep.c (ft32_address_class_type_flags): Return
1003 type_instance_flags.
1004 (ft32_address_class_type_flags_to_name): Take a
1005 type_instance_flags.
1006 (ft32_address_class_name_to_type_flags): Return bool and take a
1007 type_instance_flags.
1008 (ft32_gdbarch_init): Use type::set_instance_flags.
1009 * eval.c (fake_method::fake_method): Use type::set_instance_flags.
1010 * gdbarch.h, gdbarch.c: Regenerate.
1011 * gdbarch.sh (address_class_type_flags): Use type_instance_flags.
1012 (address_class_name_to_type_flags): Use type_instance_flags and
1013 bool.
1014 * gdbtypes.c (address_space_name_to_int)
1015 (address_space_int_to_name, make_qualified_type): Use
1016 type_instance_flags.
1017 (make_qualified_type): Use type_instance_flags and
1018 type::set_instance_flags.
1019 (make_type_with_address_space, make_cv_type, make_vector_type)
1020 (check_typedef): Use type_instance_flags.
1021 (recursive_dump_type): Cast type_instance_flags to unsigned for
1022 printing.
1023 (copy_type_recursive): Use type::set_instance_flags.
1024 (gdbtypes_post_init): Use type::set_instance_flags.
1025 * gdbtypes.h (struct type) <instance_flags>: Rename to ...
1026 <m_instance_flags>: ... this.
1027 <instance_flags, set_instance_flags>: New methods.
1028 (TYPE_INSTANCE_FLAGS): Use the instance_flags method.
1029 (SET_TYPE_INSTANCE_FLAGS): New.
1030 (address_space_name_to_int, address_space_int_to_name)
1031 (make_type_with_address_space): Pass flags using
1032 type_instance_flags instead of int.
1033 * stabsread.c (cleanup_undefined_types_noname): Use
1034 type::set_instance_flags.
1035 * s390-tdep.c (s390_address_class_type_flags): Return
1036 type_instance_flags.
1037 (s390_address_class_type_flags_to_name): Take a
1038 type_instance_flags.
1039 (s390_address_class_name_to_type_flags): Return bool and take a
1040 type_instance_flags.
1041 * type-stack.c (type_stack::follow_types): Use
1042 type_instance_flags.
1043 * dwarf2/read.c (read_tag_pointer_type): Use type_instance_flags.
1044
1045 2020-09-14 Tom Tromey <tromey@adacore.com>
1046
1047 * x86-tdep.h (x86_in_indirect_branch_thunk): Update.
1048 * x86-tdep.c (x86_is_thunk_register_name)
1049 (x86_in_indirect_branch_thunk): Update.
1050 * sparc64-tdep.c (sparc64_fpu_register_names)
1051 (sparc64_cp0_register_names, sparc64_register_names)
1052 (sparc64_pseudo_register_names): Now const.
1053 * sparc-tdep.h (struct gdbarch_tdep) <fpu_register_names,
1054 cp0_registers_num>: Now const.
1055 * sparc-tdep.c (sparc_core_register_names)
1056 (sparc32_fpu_register_names, sparc32_cp0_register_names)
1057 (sparc32_pseudo_register_names): Now const.
1058 (validate_tdesc_registers): Update.
1059 * rust-lang.c (rust_extensions): Now const.
1060 * p-lang.c (p_extensions): Now const.
1061 * objc-lang.c (objc_extensions): Now const.
1062 * nto-tdep.c (nto_thread_state_str): Now const.
1063 * moxie-tdep.c (moxie_register_names): Now const.
1064 * mips-tdep.h (struct gdbarch_tdep) <mips_processor_reg_names>:
1065 Now const.
1066 * mips-tdep.c (mips_generic_reg_names, mips_tx39_reg_names)
1067 (mips_linux_reg_names): Now const.
1068 (mips_gdbarch_init): Update.
1069 * microblaze-tdep.c (microblaze_register_names): Now const.
1070 * m68k-tdep.c (m68k_register_names): Now const.
1071 * m32r-tdep.c (m32r_register_names): Now const.
1072 * ia64-tdep.c (ia64_register_names): Now const.
1073 * i386-tdep.h (struct gdbarch_tdep) <register_names,
1074 ymmh_register_names, ymm16h_regnum, mpx_register_names,
1075 k_register_names, zmmh_register_names, xmm_avx512_register_names,
1076 ymm_avx512_register_names, pkeys_register_names>: Now const.
1077 * i386-tdep.c (i386_register_names, i386_zmm_names)
1078 (i386_zmmh_names, i386_k_names, i386_ymm_names, i386_ymmh_names)
1079 (i386_mpx_names, i386_pkeys_names, i386_bnd_names)
1080 (i386_mmx_names, i386_byte_names, i386_word_names): Now const.
1081 * f-lang.c (f_extensions): Now const.
1082 * d-lang.c (d_extensions): Now const.
1083 * csky-tdep.c (csky_register_names): Now const.
1084 * charset.c (default_charset_names, charset_enum): Now const.
1085 (_initialize_charset): Update.
1086 * c-lang.c (c_extensions, cplus_extensions, asm_extensions): Now
1087 const.
1088 * bsd-uthread.c (bsd_uthread_solib_names): Now const.
1089 (bsd_uthread_solib_loaded): Update.
1090 (bsd_uthread_state): Now const.
1091 * amd64-tdep.c (amd64_register_names, amd64_ymm_names)
1092 (amd64_ymm_avx512_names, amd64_ymmh_names)
1093 (amd64_ymmh_avx512_names, amd64_mpx_names, amd64_k_names)
1094 (amd64_zmmh_names, amd64_zmm_names, amd64_xmm_avx512_names)
1095 (amd64_pkeys_names, amd64_byte_names, amd64_word_names)
1096 (amd64_dword_names): Now const.
1097 * agent.c (can_use_agent_enum): Now const.
1098 * ada-tasks.c (task_states, long_task_states): Now const.
1099 * ada-lang.c (known_runtime_file_name_patterns)
1100 (known_auxiliary_function_name_patterns, attribute_names)
1101 (standard_exc, ada_extensions): Now const.
1102
1103 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
1104
1105 * bcache.h (struct bcache) <bcache>: Remove constructor.
1106 <m_hash_function, m_compare_function>: Remove.
1107 <~bcache>: Make virtual.
1108 <compare>: Remove static method, introduce virtual method.
1109 <default_hash>: Remove.
1110 <hash>: New virtual method.
1111 * bcache.c (bcache::expand_hash_table): Update.
1112 (bcache::insert): Update.
1113 (bcache::hash): New.
1114 (bcache::compare): Update comment and parameter names.
1115 * gdbtypes.c (types_deeply_equal): Update.
1116 * psymtab.h (struct psymbol_bcache): New struct.
1117 (class psymtab_storage) <psymtab_storage>: Make default.
1118 <psymbol_cache>: Change type to psymbol_bcache.
1119 * psymtab.c (psymtab_storage::psymtab_storage): Remove.
1120 (psymbol_hash): Change to...
1121 (psymbol_bcache::hash): ... this.
1122 (psymbol_compare): Change to...
1123 (psymbol_bcache::compare): ... this.
1124
1125 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
1126
1127 * linux-nat.c (linux_nat_wait_1): Don't use inferior_ptid when
1128 checking for initial lwp.
1129
1130 2020-09-14 Tom Tromey <tromey@adacore.com>
1131
1132 * m68k-tdep.c (m68k_extract_return_value): Use
1133 pointer_result_regnum.
1134 (m68k_store_return_value): Likewise.
1135 (m68k_reg_struct_return_p): Handle vectors and arrays.
1136 (m68k_return_value): Handle arrays.
1137 (m68k_svr4_return_value): Fix single-element aggregate handling.
1138 Handle long double. Adjust for embedded ABI.
1139 (m68k_svr4_init_abi): Set pointer_result_regnum.
1140 (m68k_embedded_init_abi): New function.
1141 (m68k_gdbarch_init): Handle Tag_GNU_M68K_ABI_FP.
1142 (m68k_osabi_sniffer): New function.
1143 (_initialize_m68k_tdep): Register osabi sniffer.
1144 * m68k-tdep.h (struct gdbarch_tdep) <pointer_result_regnum>: New
1145 member.
1146
1147 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
1148
1149 * xml-support.c (xml_fetch_content_from_file): Replace xfree
1150 with gdb::unique_xmalloc_ptr<char>.
1151
1152 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
1153
1154 * xml-support.h (xml_fetch_another): Change type to be a
1155 function_view.
1156 (xml_process_xincludes): Remove baton parameter.
1157 (xml_fetch_content_from_file): Change baton parameter to
1158 dirname.
1159 * xml-support.c (struct xinclude_parsing_data)
1160 <xinclude_parsing_data>: Remove baton parameter.
1161 <fetcher_baton>: Remove.
1162 (xinclude_start_include): Adjust.
1163 (xml_process_xincludes): Adjust.
1164 (xml_fetch_content_from_file): Replace baton parameter with
1165 dirname.
1166 * xml-syscall.c (syscall_parse_xml): Remove baton parameter.
1167 (xml_init_syscalls_info): Use a lambda.
1168 * xml-tdesc.c (tdesc_parse_xml): Remove baton parameter.
1169 (file_read_description_xml): Use a lambda.
1170 (fetch_available_features_from_target): Change baton parameter
1171 to target_ops.
1172 (target_read_description_xml): Use a lambda.
1173 (target_fetch_description_xml): Use a lambda.
1174 (string_read_description_xml): Update.
1175
1176 2020-09-14 Simon Marchi <simon.marchi@polymtl.ca>
1177
1178 * gdbtypes.h (TYPE_ENDIANITY_NOT_DEFAULT): Remove, replace all
1179 uses with type::endianity_is_not_default.
1180
1181 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1182
1183 * gdbtypes.h (struct type) <endianity_is_not_default,
1184 set_endianity_is_not_default>: New methods.
1185 (TYPE_ENDIANITY_NOT_DEFAULT): Use
1186 type::endianity_is_not_default, change all write call sites to
1187 use type::set_endianity_is_not_default.
1188
1189 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1190
1191 * gdbtypes.h (TYPE_FIXED_INSTANCE): Remove, replace all
1192 uses with type::is_fixed_instance.
1193
1194 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1195
1196 * gdbtypes.h (struct type) <is_fixed_instance,
1197 set_is_fixed_instance>: New methods.
1198 (TYPE_FIXED_INSTANCE): Use type::is_fixed_instance, change all
1199 write call sites to use type::set_is_fixed_instance.
1200
1201 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1202
1203 * gdbtypes.h (TYPE_GNU_IFUNC): Remove, replace all
1204 uses with type::is_gnu_ifunc.
1205
1206 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1207
1208 * gdbtypes.h (struct type) <is_gnu_ifunc, set_is_gnu_ifunc>: New methods.
1209 (TYPE_GNU_IFUNC): Use type::is_gnu_ifunc, change all write call sites to
1210 use type::set_is_gnu_ifunc.
1211
1212 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1213
1214 * gdbtypes.h (TYPE_STUB_SUPPORTED): Remove, replace all
1215 uses with type::stub_is_supported.
1216
1217 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1218
1219 * gdbtypes.h (struct type) <stub_is_supported, set_stub_is_supported>: New methods.
1220 (TYPE_STUB_SUPPORTED): Use type::stub_is_supported, change all write call sites to
1221 use type::set_stub_is_supported.
1222
1223 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1224
1225 * gdbtypes.h (TYPE_VECTOR): Remove, replace all
1226 uses with type::is_vector.
1227
1228 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1229
1230 * gdbtypes.h (struct type) <is_vector, set_is_vector>: New methods.
1231 (TYPE_VECTOR): Use type::is_vector, change all write call sites to
1232 use type::set_is_vector.
1233
1234 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1235
1236 * gdbtypes.h (TYPE_VARARGS): Remove, replace all
1237 uses with type::has_varargs.
1238
1239 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1240
1241 * gdbtypes.h (struct type) <has_varargs, set_has_varargs>: New methods.
1242 (TYPE_VARARGS): Use type::has_varargs, change all write call sites to
1243 use type::set_has_varargs.
1244
1245 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1246
1247 * gdbtypes.h (TYPE_PROTOTYPED): Remove, replace all
1248 uses with type::is_prototyped.
1249
1250 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1251
1252 * gdbtypes.h (struct type) <is_prototyped, set_is_prototyped>:
1253 New methods.
1254 (TYPE_PROTOTYPED): Use type::is_prototyped, change all write
1255 call sites to use type::set_is_prototyped.
1256
1257 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1258
1259 * gdbtypes.h (TYPE_TARGET_STUB): Remove, replace all
1260 uses with type::target_is_stub.
1261
1262 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1263
1264 * gdbtypes.h (struct type) <target_is_stub, set_target_is_stub>:
1265 New methods.
1266 (TYPE_TARGET_STUB): Use type::is_stub, change all write call
1267 sites to use type::set_target_is_stub.
1268
1269 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1270
1271 * gdbtypes.h (TYPE_STUB): Remove, replace all
1272 uses with type::is_stub.
1273
1274 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1275
1276 * gdbtypes.h (struct type) <is_stub, set_is_stub>: New methods.
1277 (TYPE_STUB): Use type::is_stub, change all write call sites to
1278 use type::set_is_stub.
1279
1280 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1281
1282 * gdbtypes.h (TYPE_NOSIGN): Remove, replace all uses with
1283 type::has_no_signedness.
1284
1285 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1286
1287 * gdbtypes.h (struct type) <has_no_signedness,
1288 set_has_no_signedness>: New methods.
1289 (TYPE_NOSIGN): Use type::has_no_signedness, change all write
1290 call sites to use type::set_has_no_signedness.
1291
1292 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1293
1294 * gdbtypes.h (TYPE_UNSIGNED): Remove, replace all uses with
1295 type::is_unsigned.
1296
1297 2020-09-14 Simon Marchi <simon.marchi@efficios.com>
1298
1299 * gdbtypes.h (struct type) <is_unsigned, set_is_unsigned>: New
1300 methods.
1301 (TYPE_UNSIGNED): Use type::is_unsigned. Change all write call
1302 sites to use type::set_is_unsigned.
1303
1304 2020-09-14 Fredrik Hederstierna <fredrik.hederstierna@verisure.com>
1305 Adam Renquinha <arenquinha@cimeq.qc.ca>
1306
1307 * arm-tdep.c (arm_m_exception_cache): Try use correct stack
1308 pointer and stack frame offset when unwinding.
1309
1310 2020-09-13 Pedro Alves <pedro@palves.net>
1311
1312 * NEWS: Document "-break-insert --qualified".
1313 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Handle "--qualified".
1314
1315 2020-09-13 Pedro Alves <pedro@palves.net>
1316
1317 * linespec.c (classify_mtype, compare_msyms): Delete.
1318 (search_minsyms_for_name): Remove classification logic. Instead
1319 filter out trampoline symbols if we also found an external
1320 function of the same name.
1321
1322 2020-09-13 Joel Brobecker <brobecker@adacore.com>
1323
1324 * NEWS: Create a new section for the next release branch.
1325 Rename the section of the current branch, now that it has
1326 been cut.
1327
1328 2020-09-13 Joel Brobecker <brobecker@adacore.com>
1329
1330 GDB 10 branch created (8087c3fa8b5d695e3e29e69d70d0b35ec902ac59):
1331 * version.in: Bump version to 11.0.50.DATE-git.
1332
1333 2020-09-12 Joel Brobecker <brobecker@adacore.com>
1334
1335 * infrun.c (namespace selftests): Only define #if GDB_SELF_TEST.
1336
1337 2020-09-11 Moritz Riesterer <moritz.riesterer@intel.com>
1338 Felix Willgerodt <Felix.Willgerodt@intel.com>
1339
1340 * gdbarch.sh: Added bfloat16 type.
1341 * gdbarch.c: Regenerated.
1342 * gdbarch.h: Regenerated.
1343 * gdbtypes.c (floatformats_bfloat16): New struct.
1344 (gdbtypes_post_init): Add builtin_bfloat16.
1345 * gdbtypes.h (struct builtin_type) <builtin_bfloat16>: New member.
1346 (floatformats_bfloat16): New struct.
1347 * i386-tdep.c (i386_zmm_type): Add field "v32_bfloat16"
1348 (i386_ymm_type): Add field "v16_bfloat16"
1349 (i386_gdbarch_init): Add set_gdbarch_bfloat16_format.
1350 * target-descriptions.c (make_gdb_type): Add case TDESC_TYPE_BFLOAT16.
1351 * gdbsupport/tdesc.cc (tdesc_predefined_types): New member bfloat16.
1352 * gdbsupport/tdesc.h (tdesc_type_kind): New member TDESC_TYPE_BFLOAT16.
1353 * features/i386/64bit-avx512.xml: Add bfloat16 type.
1354 * features/i386/64bit-avx512.c: Regenerated.
1355 * features/i386/64bit-sse.xml: Add bfloat16 type.
1356 * features/i386/64bit-sse.c: Regenerated.
1357
1358 2020-09-11 Felix Willgerodt <felix.willgerodt@intel.com>
1359
1360 * i386-tdep.c (i386_zmm_type): Fix field names.
1361 (i386_ymm_type): Fix field names.
1362
1363 2020-09-11 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1364
1365 * breakpoint.c: Fix typo in the help message of the
1366 "set breakpoint condition-evaluation" command.
1367
1368 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1369
1370 * nbsd-nat.c: Include "nat/netbsd-nat.h".
1371 * (nbsd_nat_target::pid_to_exec_file)
1372 (nbsd_nat_target::thread_alive, nbsd_nat_target::thread_name)
1373 (nbsd_nat_target::post_startup_inferior)
1374 (nbsd_nat_target::post_attach, nbsd_nat_target::xfer_partial)
1375 (nbsd_add_threads): Switch local code to common gdb/nat functions.
1376 * (nbsd_pid_to_cmdline): Call sysctl from the global namespace.
1377 * (nbsd_thread_lister): Remove.
1378
1379 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1380
1381 * fork-inferior.c (startup_inferior): Avoid double free.
1382
1383 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1384
1385 * netbsd-nat.h (netbsd_nat::qxfer_siginfo): Add.
1386 * netbsd-nat.c (netbsd_nat::qxfer_siginfo): Likewise.
1387
1388 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1389
1390 * netbsd-nat.h (netbsd_nat::enable_proc_events): Add.
1391 * netbsd-nat.c: Include <sys/ptrace.h>.
1392 * (netbsd_nat::enable_proc_events): Add.
1393
1394 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1395
1396 * netbsd-nat.h: Include "gdbsupport/function-view.h".
1397 * (netbsd_nat::thread_alive, netbsd_nat::thread_name)
1398 (netbsd_nat::for_each_thread): Add.
1399 * netbsd-nat.c: Include "gdbsupport/common-defs.h" and
1400 "gdbsupport/common-debug.h".
1401 * (netbsd_nat::netbsd_thread_lister)
1402 (netbsd_nat::thread_alive, netbsd_nat::thread_name)
1403 (netbsd_nat::for_each_thread): Add.
1404
1405 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1406
1407 * netbsd-nat.h: Include <unistd.h>.
1408 * (netbsd_nat::pid_to_exec_file): Add.
1409 * netbsd-nat.c: Include <sys/types.h> and <sys/sysctl.h>.
1410 * (netbsd_nat::pid_to_exec_file) Add.
1411
1412 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1413
1414 * configure.nat (NATDEPFILES): Add nat/netbsd-nat.o when needed.
1415
1416 2020-09-10 Kamil Rytarowski <n54@gmx.com>
1417
1418 * netbsd-nat.h: New file.
1419 * netbsd-nat.c: Likewise.
1420
1421 2020-09-09 Tom Tromey <tromey@adacore.com>
1422
1423 * ada-lang.c (remove_extra_symbols): Do not increment when
1424 removing an element
1425
1426 2020-09-08 Tom Tromey <tromey@adacore.com>
1427
1428 * gdb_bfd.c (gdb_bfd_open): Call bfd_fopen when fstat fails.
1429
1430 2020-09-08 Tom Tromey <tromey@adacore.com>
1431
1432 PR win32/25302:
1433 * gdb_bfd.c (gdb_bfd_data): Add "st" parameter.
1434 (gdb_bfd_init_data): New function.
1435 (gdb_bfd_open, gdb_bfd_ref): Use gdb_bfd_init_data.
1436
1437 2020-09-07 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1438
1439 * infrun.c (fetch_inferior_event): Use
1440 `switch_to_target_no_thread` to switch the target.
1441
1442 2020-09-06 Tom Tromey <tom@tromey.com>
1443
1444 * symfile.h (dwarf2_free_objfile): Don't declare.
1445
1446 2020-09-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1447
1448 * gdb/i386-tdep.c (i386_floatformat_for_type): Added conditions
1449 to match 16 byte real/complex type generated by Flang compiler.
1450
1451 2020-09-03 Tom de Vries <tdevries@suse.de>
1452
1453 PR breakpoint/26546
1454 * dwarf2/read.c (new_symbol): Tag label symbol without DW_AT_low_pc as
1455 LOC_OPTIMIZED_OUT instead of LOC_LABEL.
1456
1457 2020-09-02 Simon Marchi <simon.marchi@polymtl.ca>
1458
1459 * maint.c (index_digits): New function.
1460 (struct maint_print_section_data): Remove.
1461 (print_bfd_section_info): Remove print_data parameter, add arg
1462 and index_digits.
1463 (print_objfile_section_info): Likewise.
1464 (print_bfd_section_info_maybe_relocated): Likewise (plus
1465 objfile).
1466 (maintenance_info_sections): Adjust calls.
1467
1468 2020-09-02 Tom Tromey <tromey@adacore.com>
1469
1470 * ada-varobj.c (ada_varobj_get_ptr_number_of_children): Return 0
1471 for null pointers.
1472 (ada_varobj_adjust_for_child_access): Special-case null pointers.
1473
1474 2020-09-01 Simon Marchi <simon.marchi@polymtl.ca>
1475
1476 * bcache.h (struct bcache) <insert>: Change type of `added` to
1477 pointer to bool.
1478 * bcache.c (bcache::insert): Likewise.
1479 * gdbtypes.c (check_types_worklist): Adjust.
1480 * psymtab.c (add_psymbol_to_bcache): Adjust.
1481
1482 2020-08-31 Kevin Buettner <kevinb@redhat.com>
1483
1484 * corelow.c (unordered_set): Include.
1485 (class core_target): Add field 'm_core_unavailable_mappings'.
1486 (core_target::build_file_mappings): Print only one warning
1487 per inaccessible file. Add unavailable/broken mappings
1488 to m_core_unavailable_mappings.
1489 (core_target::xfer_partial): Call...
1490 (core_target::xfer_memory_via_mappings): New method.
1491
1492 2020-08-31 Simon Marchi <simon.marchi@polymtl.ca>
1493
1494 * dwarf2/read.c (struct field_info) <non_public_fields>: Change
1495 type to bool.
1496
1497 2020-08-31 Simon Marchi <simon.marchi@polymtl.ca>
1498
1499 * dwarf2/read.c (struct field_info): Fix indentation.
1500
1501 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
1502
1503 * frame-unwind.h (frame_prev_register_ftype): Fix adjective
1504 ordering in comment.
1505 * frame.c (frame_id_eq): Fix indentation.
1506
1507 2020-08-31 Scott Linder <scott@scottlinder.com>
1508 Simon Marchi <simon.marchi@efficios.com>
1509
1510 * inline-frame.c (inline_frame_this_id): Remove assert that prevents
1511 inline frame ids in outer frame.
1512
1513 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
1514
1515 * frame.h (enum frame_id_stack_status) <FID_STACK_OUTER>: New.
1516 * frame.c (fprint_frame_id): Handle FID_STACK_OUTER.
1517 (outer_frame_id): Use FID_STACK_OUTER instead of
1518 FID_STACK_INVALID.
1519 (frame_id_p): Don't check for outer_frame_id.
1520
1521 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
1522
1523 * frame-unwind.c (frame_unwind_got_optimized): Don't set
1524 regnum/frame in value. Call allocate_value_lazy.
1525 * frame.c (frame_unwind_register_value): Use
1526 val_print_not_saved.
1527
1528 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
1529
1530 * gdbtypes.h (NULL_TYPE): Remove, change all uses to nullptr.
1531
1532 2020-08-29 Pedro Alves <pedro@palves.net>
1533
1534 * progspace.c (print_program_space): Use all_inferiors. Switch to
1535 the inferior before calling target_pid_to_str.
1536
1537 2020-08-28 Tom Tromey <tom@tromey.com>
1538
1539 * xcoffread.c (xcoff_end_psymtab): Update comment.
1540 * dbxread.c (dbx_end_psymtab): Update comment.
1541
1542 2020-08-28 Tom de Vries <tdevries@suse.de>
1543
1544 PR breakpoint/26544
1545 * breakpoint.c (parse_breakpoint_sals): Remove const from struct
1546 event_location.
1547 (create_breakpoint): Same.
1548 (base_breakpoint_decode_location): Same.
1549 (bkpt_create_sals_from_location): Same.
1550 (bkpt_decode_location): Same.
1551 (bkpt_probe_create_sals_from_location): Same.
1552 (bkpt_probe_decode_location): Same.
1553 (tracepoint_create_sals_from_location): Same.
1554 (tracepoint_decode_location): Same.
1555 (tracepoint_probe_decode_location): Same.
1556 (strace_marker_create_sals_from_location): Same.
1557 (strace_marker_decode_location): Same.
1558 (create_sals_from_location_default): Same.
1559 (decode_location_default): Same.
1560 * breakpoint.h (struct breakpoint_ops): Same.
1561 (create_breakpoint): Same.
1562 * linespec.h (decode_line_full): Same.
1563 * linespec.c (decode_line_full): Same. Throw error if
1564 result.size () == 0.
1565
1566 2020-08-27 Pedro Alves <pedro@palves.net>
1567
1568 PR gdb/26524
1569 * breakpoint.c (until_break_fsm) <location_breakpoint,
1570 caller_breakpoint>: Delete fields.
1571 <breakpoints>: New field.
1572 <until_break_fsm>: Adjust to save a breakpoint vector instead of
1573 two individual breakpoints.
1574 (until_break_fsm::should_stop): Loop over breakpoints in the
1575 breakpoint vector.
1576 (until_break_fsm::clean_up): Adjust to clear the breakpoints
1577 vector.
1578 (until_break_command): Handle location expanding into multiple
1579 sals.
1580
1581 2020-08-27 Pedro Alves <pedro@palves.net>
1582
1583 PR gdb/26523
1584 * inline-frame.c (stopped_by_user_bp_inline_frame): Also consider
1585 bp_until breakpoints user-specified locations. Update intro
1586 comment.
1587
1588 2020-08-27 Simon Marchi <simon.marchi@polymtl.ca>
1589
1590 * gdb_bfd.h (gdb_bfd_section_iterator, gdb_bfd_section_range,
1591 gdb_bfd_sections): New.
1592 * maint.c (print_bfd_section_info): Change param type to
1593 maint_print_section_data.
1594 (print_objfile_section_info): Likewise.
1595 (print_bfd_section_info_maybe_relocated): Likewise.
1596 (maintenance_info_sections): Use gdb_bfd_sections.
1597
1598 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
1599
1600 * MAINTAINERS: Add ARC target and maintainer.
1601
1602 2020-08-25 Anton Kolesov <anton.kolesov@synopsys.com>
1603
1604 * configure.tgt: ARC support for GNU/Linux.
1605 * Makefile.in (ALL_TARGET_OBJS): Likewise.
1606 * arc-linux-tdep.c: New file.
1607 * arc-tdep.h (ARC_STATUS32_L_MASK, ARC_STATUS32_DE_MASK): Declare.
1608 * arc-tdep.c (arc_write_pc): Use it.
1609
1610 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
1611
1612 * arc-tdep.c (arc_check_for_hardware_loop): New.
1613 * arc-tdep.h (gdbarch_tdep): New field has_hw_loops.
1614
1615 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
1616
1617 * arc-tdep.h: Include "gdbarch.h".
1618
1619 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
1620
1621 * arch/arc.h
1622 (arc_gdbarch_features): New class to stir the selection of target XML.
1623 (arc_create_target_description): Use FEATURES to choose XML target.
1624 (arc_lookup_target_description): Use arc_create_target_description
1625 to create _new_ target descriptions or return the already created
1626 ones if the FEATURES is the same.
1627 * arch/arc.c: Implementation of prototypes described above.
1628 * gdb/arc-tdep.h (arc_regnum enum): Add more registers.
1629 (arc_gdbarch_features_init): Initialize the FEATURES struct.
1630 * arc-tdep.c (*_feature_name): Make feature names consistent.
1631 (arc_register_feature): A new struct to hold information about
1632 registers of a particular target/feature.
1633 (arc_check_tdesc_feature): Check if XML provides registers in
1634 compliance with ARC_REGISTER_FEATURE structs.
1635 (arc_update_acc_reg_names): Add aliases for r58 and r59.
1636 (determine_*_reg_feature_set): Which feature name to look for.
1637 (arc_gdbarch_features_init): Given MACH and ABFD, initialize FEATURES.
1638 (mach_type_to_arc_isa): Convert from a set of binutils machine types
1639 to expected ISA enums to be used in arc_gdbarch_features structs.
1640 * features/Makefile (FEATURE_XMLFILES): Add new files.
1641 * gdb/features/arc/v1-aux.c: New file.
1642 * gdb/features/arc/v1-aux.xml: Likewise.
1643 * gdb/features/arc/v1-core.c: Likewise.
1644 * gdb/features/arc/v1-core.xml: Likewise.
1645 * gdb/features/arc/v2-aux.c: Likewise.
1646 * gdb/features/arc/v2-aux.xml: Likewise.
1647 * gdb/features/arc/v2-core.c: Likewise.
1648 * gdb/features/arc/v2-core.xml: Likewise.
1649 * NEWS (Changes since GDB 9): Announce obsolence of old feature names.
1650
1651 2020-08-25 Gaius Mulley <gaiusmod2@gmail.com>
1652 Andrew Burgess <andrew.burgess@embecosm.com>
1653
1654 PR m2/26372
1655 * m2-exp.y (exp): Improve comment for non_empty_arglist case, add
1656 an assert. Remove single element array indexing pattern as the
1657 MULTI_SUBSCRIPT support will handle this case too.
1658
1659 2020-08-24 Simon Marchi <simon.marchi@polymtl.ca>
1660
1661 * value.h (valprint_check_validity): Move declaration from
1662 here...
1663 * valprint.h (valprint_check_validity): ... to here.
1664
1665 2020-08-24 Simon Marchi <simon.marchi@efficios.com>
1666
1667 * debug.h: New file.
1668 * debug.c (debug_prefixed_vprintf): New function.
1669 * infrun.c (infrun_debug_printf_1): Use debug_prefixed_vprintf.
1670 * linux-nat.c (linux_nat_debug_printf_1): Likewise.
1671
1672 2020-08-24 Simon Marchi <simon.marchi@efficios.com>
1673
1674 * infrun.h (infrun_debug_printf_1): New function declaration.
1675 (infrun_debug_printf): New macro.
1676 * infrun.c (infrun_debug_printf_1): Use infrun_debug_printf
1677 throughout.
1678 (infrun_debug_printf): New function.
1679 * breakpoint.c (should_be_inserted): Use infrun_debug_printf.
1680 (handle_jit_event): Likewise.
1681
1682 2020-08-21 Mark Wielaard <mark@klomp.org>
1683
1684 * ada-lex.l: Extend register warnings diagnostics comment for g++.
1685
1686 2020-08-22 Simon Marchi <simon.marchi@efficios.com>
1687
1688 * frame.c (enum class frame_id_status): New.
1689 (struct frame_info) <this_id::p>: Change type to frame_id_status.
1690 (fprintf_frame): Update.
1691 (compute_frame_id): Set frame id status to "computing" on entry.
1692 Set it back to "not_computed" on failure and to "computed" on
1693 success.
1694 (get_frame_id): Assert the frame id is not being computed.
1695 (create_sentinel_frame): Use frame_id_status::COMPUTED.
1696 (create_new_frame): Likewise.
1697 (frame_cleanup_after_sniffer): Update assert.
1698
1699 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
1700
1701 * regcache.c (pid_ptid_regcache_map): New type.
1702 (target_ptid_regcache_map): Remove.
1703 (target_pid_ptid_regcache_map): New type.
1704 (regcaches): Change type to target_pid_ptid_regcache_map.
1705 (get_thread_arch_aspace_regcache): Update.
1706 (regcache_thread_ptid_changed): Update, handle pid-like ptid
1707 case.
1708 (regcaches_size): Update.
1709 (regcache_count): Update.
1710 (registers_changed_ptid_target_pid_test): New.
1711 (_initialize_regcache): Register new test.
1712
1713 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
1714
1715 * regcache.c (regcache_count): New.
1716 (struct regcache_test_data): New.
1717 (regcache_test_data_up): New.
1718 (populate_regcaches_for_test): New.
1719 (regcaches_test): Remove.
1720 (get_thread_arch_aspace_regcache_test): New.
1721 (registers_changed_ptid_all_test): New.
1722 (registers_changed_ptid_target_test): New.
1723 (registers_changed_ptid_target_ptid_test): New.
1724 (regcache_thread_ptid_changed): Remove regcache_count lambda.
1725 (_initialize_regcache): Register new tests.
1726
1727 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
1728
1729 * regcache.c (test_get_thread_arch_aspace_regcache): Rename to...
1730 (get_thread_arch_aspace_regcache_and_check): ... this. Remove
1731 gdbarch and aspace parameter. Use current inferior's aspace.
1732 Validate regcache's arch value.
1733 (regcaches_test): Update.
1734
1735 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
1736
1737 * regcache.c (regcaches_test): Call registers_changed.
1738
1739 2020-08-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1740
1741 * infrun.c (process_event_stop_test): Fix typo "breapoint".
1742
1743 2020-08-19 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1744
1745 * amd64-tdep.c (amd64_skip_prologue): Using symbol table
1746 to find the end of prologue for flang compiled binaries.
1747 * arm-tdep.c (arm_skip_prologue): Likewise.
1748 * i386-tdep.c (i386_skip_prologue): Likewise.
1749 * producer.c (producer_is_llvm): New function.
1750 (producer_parsing_tests): Added new tests for clang/flang.
1751 * producer.h (producer_is_llvm): New declaration.
1752
1753 2020-08-18 Simon Marchi <simon.marchi@efficios.com>
1754
1755 * linux-nat.c (linux_nat_debug_printf): New function.
1756 (linux_nat_debug_printf_1): New macro. Use throughout the file.
1757
1758 2020-08-18 Aaron Merey <amerey@redhat.com>
1759
1760 * Makefile.in (DEBUGINFOD_CFLAGS, DEBUGINFOD_LIBS): New variables.
1761 (INTERNAL_CFLAGS_BASE): Add DEBUGINFOD_CFLAGS.
1762 (CLIBS): Add DEBUGINFOD_LIBS.
1763
1764 2020-08-17 Sergei Trofimovich <siarheit@google.com>
1765
1766 * ia64-linux-nat.c: Include "gdbarch.h" to declare used
1767 'gdbarch_num_regs'.
1768
1769 2020-08-17 Tom Tromey <tromey@adacore.com>
1770
1771 * ada-varobj.c (ada_varobj_decode_var): Handle case where
1772 ada_get_decoded_value returns NULL.
1773
1774 2020-08-17 Tom Tromey <tromey@adacore.com>
1775
1776 * python/py-inferior.c (infpy_search_memory): Use
1777 gdb_py_object_from_ulongest.
1778 * python/py-infevents.c (create_inferior_call_event_object)
1779 (create_memory_changed_event_object): Use
1780 gdb_py_object_from_ulongest.
1781 * python/py-linetable.c (ltpy_entry_get_pc): Use
1782 gdb_py_object_from_ulongest.
1783
1784 2020-08-17 Simon Marchi <simon.marchi@polymtl.ca>
1785
1786 * loc.c (class symbol_needs_eval_context): Fix indentation.
1787
1788 2020-08-17 Simon Marchi <simon.marchi@polymtl.ca>
1789
1790 * dwarf2/loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
1791 bool.
1792
1793 2020-08-17 Tom de Vries <tdevries@suse.de>
1794
1795 PR gdb/26393
1796 * gdbtypes.c (dump_dynamic_prop): New function.
1797 (recursive_dump_type): Use dump_dynamic_prop for TYPE_CODE_RANGE.
1798
1799 2020-08-15 Tom de Vries <tdevries@suse.de>
1800
1801 PR backtrace/26390
1802 * stack.c (print_frame_args): Temporarily set the selected
1803 frame to FRAME while printing the frame's arguments.
1804
1805 2020-08-14 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1806
1807 PR breakpoints/26385
1808 * ppc-linux-nat.c (ppc_linux_nat_target::low_prepare_to_resume):
1809 Always clear watchpoint with PTRACE_SET_DEBUGREG.
1810
1811 2020-08-14 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1812
1813 * ppc-linux-nat.c (ppc_linux_dreg_interface::detect)
1814 (ppc_linux_nat_target::low_prepare_to_resume): Use ptrace () < 0
1815 and >= to check return value instead of == -1 and != -1.
1816
1817 2020-08-14 Simon Marchi <simon.marchi@polymtl.ca>
1818
1819 * utils.h (class gdb_argv) <as_array_view>: New method.
1820 * utils.c (gdb_argv_as_array_view_test): New.
1821 (_initialize_utils): Register selftest.
1822 * maint.c (maintenance_selftest): Use the new method.
1823
1824 2020-08-13 Kamil Rytarowski <n54@gmx.com>
1825
1826 * target.h (supports_dumpcore, dumpcore): New
1827 function declarations.
1828 * target.c (supports_dumpcore, dumpcore): New
1829 functions.
1830 * target-delegates.c: Rebuild.
1831 * gcore.c (gcore_command): Use target_supports_dumpcore ()
1832 and target_dumpcore ().
1833
1834 2020-08-13 Aaron Merey <amerey@redhat.com>
1835
1836 * debuginfod-support.c: Replace global variables with user_data.
1837
1838 2020-08-13 Simon Marchi <simon.marchi@polymtl.ca>
1839
1840 * maint.c (maintenance_selftest): Split args and pass array_view
1841 to run_tests.
1842
1843 2020-08-12 Luis Machado <luis.machado@linaro.org>
1844
1845 * value.c (check_type_length_before_alloc): Use ULONGEST to store a
1846 type's length.
1847 Use %s and pulongest to print the length.
1848
1849 2020-08-12 Pedro Alves <palves@redhat.com>
1850
1851 * NEWS: Move "Multi-target debugging support" item to the
1852 "Changes since GDB 9" section.
1853
1854 2020-08-12 Pedro Alves <palves@redhat.com>
1855
1856 PR gdb/26336
1857 * progspace.c (program_space::remove_objfile): Invalidate the
1858 frame cache.
1859
1860 2020-08-11 Tom de Vries <tdevries@suse.de>
1861
1862 * MAINTAINERS: Mark ms1 as deleted.
1863
1864 2020-08-10 Luis Machado <luis.machado@linaro.org>
1865
1866 PR gdb/26310
1867
1868 * aarch64-tdep.c (aarch64_analyze_prologue): Track use of SP/FP and
1869 act accordingly.
1870 (aarch64_analyze_prologue_test): Add more unit tests to exercise
1871 movz/str/stur/stp skipping behavior.
1872
1873 2020-08-10 Luis Machado <luis.machado@linaro.org>
1874
1875 * nat/aarch64-sve-linux-sigcontext.h (SVE_PT_REGS_OFFSET): Use
1876 struct user_sve_header instead of struct sve_context.
1877
1878 2020-08-09 Simon Marchi <simon.marchi@polymtl.ca>
1879
1880 * read.h (dwarf2_fetch_die_loc_sect_off,
1881 dwarf2_fetch_die_loc_cu_off): Replace function pointer +
1882 `void *` parameter with function_view.
1883 * read.c (dwarf2_fetch_die_loc_sect_off,
1884 dwarf2_fetch_die_loc_cu_off): Likewise.
1885 * loc.c (get_frame_pc_for_per_cu_dwarf_call): Remove.
1886 (per_cu_dwarf_call): Adjust.
1887 (get_frame_address_in_block_wrapper): Remove.
1888 (indirect_synthetic_pointer): Adjust.
1889 (get_ax_pc): Remove.
1890 (dwarf2_compile_expr_to_ax): Adjust.
1891
1892 2020-08-08 Tom de Vries <tdevries@suse.de>
1893
1894 PR build/26344
1895 * arch/riscv.c (riscv_lookup_target_description): Use an explicit
1896 constructor.
1897 * regcache.c (get_thread_arch_aspace_regcache): Same.
1898
1899 2020-08-07 Tom Tromey <tromey@adacore.com>
1900
1901 * ravenscar-thread.c
1902 (ravenscar_thread_target::set_base_thread_from_ravenscar_task):
1903 New method.
1904 (ravenscar_thread_target::wait): Check
1905 runtime_initialized.
1906 (ravenscar_thread_target::prepare_to_store)
1907 (ravenscar_thread_target::stopped_by_sw_breakpoint)
1908 (ravenscar_thread_target::stopped_by_hw_breakpoint)
1909 (ravenscar_thread_target::stopped_by_watchpoint)
1910 (ravenscar_thread_target::stopped_data_address)
1911 (ravenscar_thread_target::core_of_thread): Use
1912 scoped_restore_current_thread and
1913 set_base_thread_from_ravenscar_task.
1914
1915 2020-08-07 Tom Tromey <tromey@adacore.com>
1916
1917 * ravenscar-thread.c (update_thread_list): Set inferior_ptid.
1918
1919 2020-08-07 Tom Tromey <tromey@adacore.com>
1920
1921 * ravenscar-thread.c (ravenscar_thread_target::wait): Call
1922 update_inferior_ptid before update_thread_list.
1923 (temporarily_change_regcache_ptid): New class.
1924 (ravenscar_thread_target::fetch_registers)
1925 (ravenscar_thread_target::store_registers)
1926 (ravenscar_thread_target::prepare_to_store): Use base thread when
1927 forwarding operation.
1928
1929 2020-08-07 Tom Tromey <tromey@adacore.com>
1930
1931 * ravenscar-thread.c (ravenscar_thread_target::resume): Handle
1932 "is_pid" case.
1933
1934 2020-08-07 Tom Tromey <tromey@adacore.com>
1935
1936 * ravenscar-thread.c (xfer_partial, enable_btrace, add_thread):
1937 New methods.
1938 (ravenscar_thread_target::get_thread_base_cpu): Check m_cpu_map
1939 first.
1940 (ravenscar_thread_target::add_thread): Rename from
1941 ravenscar_add_thread.
1942 (ravenscar_thread_target::update_thread_list): Use a lambda.
1943 (ravenscar_thread_target::xfer_partial): New method.
1944
1945 2020-08-07 Tom Tromey <tromey@adacore.com>
1946
1947 * ada-lang.h (ada_task_list_iterator_ftype): Now a
1948 gdb::function_view.
1949 (iterate_over_live_ada_tasks): Change type of argument.
1950 * ada-tasks.c (iterate_over_live_ada_tasks): Change type
1951 of argument.
1952
1953 2020-08-07 Tom Tromey <tromey@adacore.com>
1954
1955 * ravenscar-thread.c (ravenscar_thread_target) <extra_thread_info>:
1956 Remove.
1957 (ravenscar_thread_target::extra_thread_info): Remove.
1958 (ravenscar_thread_target::pid_to_str): Mention Ravenscar in result;
1959 defer to target beneath for non-Ravenscar threads.
1960
1961 2020-08-07 Tom Tromey <tromey@adacore.com>
1962
1963 * ravenscar-thread.c (ravenscar_thread_target) <get_base_cpu,
1964 get_base_thread_from_ravenscar_task>: Now methods.
1965 <m_cpu_map>: New member.
1966 (ravenscar_thread_target::get_thread_base_cpu): Rename from
1967 ravenscar_get_thread_base_cpu. Check m_cpu_map.
1968 (ravenscar_thread_target::task_is_currently_active): Update.
1969 (ravenscar_thread_target::get_base_thread_from_ravenscar_task):
1970 Now a method.
1971 (ravenscar_thread_target::add_active_thread): Put initial thread
1972 into the m_cpu_map.
1973
1974 2020-08-07 Tom Tromey <tromey@adacore.com>
1975
1976 * ravenscar-thread.c (ravenscar_thread_target::wait): Return
1977 event_ptid.
1978
1979 2020-08-07 Tom Tromey <tromey@adacore.com>
1980
1981 * ravenscar-thread.c (ravenscar_thread_target::wait): Check
1982 runtime_initialized.
1983
1984 2020-08-07 Tom Tromey <tromey@adacore.com>
1985
1986 * ravenscar-thread.c (ravenscar_thread_target): Don't call
1987 add_active_thread.
1988 (ravenscar_thread_target::add_active_thread): Now public.
1989 (ravenscar_inferior_created): Call add_active_thread after pushing
1990 the target.
1991
1992 2020-08-07 Simon Marchi <simon.marchi@polymtl.ca>
1993
1994 * regcache.c (ptid_regcache_map): New type.
1995 (target_ptid_regcache_map): New type.
1996 (regcaches): Change type to target_ptid_regcache_map.
1997 (get_thread_arch_aspace_regcache): Update to regcaches' new
1998 type.
1999 (regcache_thread_ptid_changed): Likewise.
2000 (registers_changed_ptid): Likewise.
2001 (regcaches_size): Likewise.
2002 (regcaches_test): Update.
2003 (regcache_thread_ptid_changed): Update.
2004 * regcache.h (regcache_up): New type.
2005 * gdbsupport/ptid.h (hash_ptid): New struct.
2006
2007 2020-08-07 Simon Marchi <simon.marchi@efficios.com>
2008
2009 * observable.h (thread_ptid_changed): Add parameter
2010 `process_stratum_target *`.
2011 * infrun.c (infrun_thread_ptid_changed): Add parameter
2012 `process_stratum_target *` and use it.
2013 (selftests): New namespace.
2014 (infrun_thread_ptid_changed): New function.
2015 (_initialize_infrun): Register selftest.
2016 * regcache.c (regcache_thread_ptid_changed): Add parameter
2017 `process_stratum_target *` and use it.
2018 (regcache_thread_ptid_changed): New function.
2019 (_initialize_regcache): Register selftest.
2020 * thread.c (thread_change_ptid): Pass target to
2021 thread_ptid_changed observable.
2022
2023 2020-08-06 Caroline Tice <cmtice@google.com>
2024
2025 * dwarf2/read.c (struct dwo_file): Update comment on 'sections' field.
2026 (struct dwp_sections): Update field comments. Add loclists and
2027 rnglists fields.
2028 (struct virtual_v2_dwo_sections): Rename struct to
2029 'virtual_v2_or_v5_dwo_sections'; update comments at top of struct; add
2030 size & offset fields for loclists and rnglists.
2031 (struct dwp_hash_table): Add a 'v5' struct field to the union section.
2032 (create_debug_type_hash_table): Add 'DW_UT_split_type' to the check for
2033 skipping dummy type units.
2034 (create_dwp_hash_table): Update the large comment above the function to
2035 discuss Version 5 DWP files as well, with references. Update all the
2036 version checks in the function to check for version 5 as well. Add new
2037 section at the end to create dwp hash table for version 5.
2038 (create_dwp_v2_section): Rename function to
2039 'create_dwp_v2_or_v5_section'. Update function comment appropriately.
2040 Add V5 to error message text.
2041 (create_dwo_unit_in_dwp_v2): Change calls to create_dwp_v2_section
2042 into calls to create_dwp_v2_or_v5_section.
2043 (create_dwo_unit_in_dwp_v5): New function.
2044 (lookup_dwo_unit_in_dwp): Update conditional statement to explicitly
2045 check for version2; add else clause to handle version 5.
2046 (open_and_init_dwo_file): Add code to check dwarf version & only call
2047 create_debug_types_hash_table (with sections.types) if version is not 5;
2048 else call create_debug_type_hash_table, with sections.info.
2049 (dwarf2_locate_v2_dwp_sections): Update function comment to mention
2050 version 5.
2051 (dwarf2_locate_v5_dwp_sections): New function.
2052 (open_and_init_dwp_file): Add else-if clause for version 5 to call
2053 bfd_map_over_sections with dwarf2_locate_v5_dwp_sections.
2054
2055 2020-08-06 Simon Marchi <simon.marchi@efficios.com>
2056
2057 * regcache.h (class regcache): Remove friend
2058 registers_changed_ptid.
2059 <regcache_thread_ptid_changed>: Remove.
2060 <regcaches>: Remove.
2061 * regcache.c (regcache::regcaches): Rename to...
2062 (regcaches): ... this. Make static.
2063 (get_thread_arch_aspace_regcache): Update.
2064 (regcache::regcache_thread_ptid_changed): Rename to...
2065 (regcache_thread_ptid_changed): ... this. Update.
2066 (class regcache_access): Remove.
2067 (regcaches_test): Update.
2068 (_initialize_regcache): Update.
2069 * sparc64-tdep.c, dwarf2/index-write.c, record-btrace.c: Include
2070 <forward_list>.
2071
2072 2020-08-06 Simon Marchi <simon.marchi@efficios.com>
2073
2074 * regcache.h (class regcache) <current_regcache>: Rename to...
2075 <regcaches>: ... this. Move doc here.
2076 * regcache.c (regcache::current_regcache) Rename to...
2077 (regcache::regcaches): ... this. Move doc to header.
2078 (get_thread_arch_aspace_regcache): Update.
2079 (regcache::regcache_thread_ptid_changed): Update.
2080 (registers_changed_ptid): Update.
2081 (class regcache_access) <current_regcache_size>: Rename to...
2082 <regcaches_size>: ... this.
2083 (current_regcache_test): Rename to...
2084 (regcaches_test): ... this.
2085 (_initialize_regcache): Update.
2086
2087 2020-08-06 Victor Collod <vcollod@nvidia.com>
2088
2089 * amd64-tdep.c (amd64_analyze_prologue): Fix incorrect comment.
2090
2091 2020-08-05 Kevin Buettner <kevinb@redhat.com>
2092
2093 * corelow.c (core_target::build_file_mappings): Don't output
2094 null pathname in warning.
2095
2096 2020-08-05 Simon Marchi <simon.marchi@polymtl.ca>
2097
2098 * gdb.dwarf2/clztest.exp, gdb.dwarf2/dw2-common-block.exp,
2099 gdb.dwarf2/dw2-dup-frame.exp, gdb.dwarf2/dw2-reg-undefined.exp,
2100 gdb.dwarf2/dw2-single-line-discriminators.exp,
2101 dw2-undefined-ret-addr.exp: Pass nopie to compilation options.
2102
2103 2020-08-05 Tom Tromey <tromey@adacore.com>
2104
2105 PR rust/26197:
2106 * dwarf2/read.c (alloc_rust_variant): Handle univariant case.
2107 (quirk_rust_enum): Call alloc_rust_variant for univariant case.
2108 Fix off-by-one and type size errors in ordinary case.
2109
2110 2020-08-05 Tom de Vries <tdevries@suse.de>
2111
2112 * gdbtypes.c (type_not_allocated, type_not_associated): Use
2113 "prop->const_val () == 0" instead of "prop->const_val () != 0".
2114
2115 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
2116
2117 * frame.h (frame_id_p): Return bool.
2118 (frame_id_artificial_p): Return bool.
2119 (frame_id_eq): Return bool.
2120 (has_stack_frames): Return bool.
2121 (get_selected_frame): Fix typo in comment.
2122 (get_frame_pc_if_available): Return bool.
2123 (get_frame_address_in_block_if_available): Return bool.
2124 (get_frame_func_if_available): Return bool.
2125 (read_frame_register_unsigned): Return bool.
2126 (get_frame_register_bytes): Return bool.
2127 (safe_frame_unwind_memory): Return bool.
2128 (deprecated_frame_register_read): Return bool.
2129 (frame_unwinder_is): Return bool.
2130 * frame.c (struct frame_info) <prev_arch::p>: Change type to
2131 bool.
2132 <this_id::p>: Likewise.
2133 <prev_p>: Likewise.
2134 (frame_stash_add): Return bool.
2135 (get_frame_id): Use bool.
2136 (frame_id_build_special) Use bool.
2137 (frame_id_build_unavailable_stack): Use bool.
2138 (frame_id_build): Use bool.
2139 (frame_id_p): Return bool, use true/false instead of 1/0.
2140 (frame_id_artificial_p): Likewise.
2141 (frame_id_eq): Likewise.
2142 (frame_id_inner): Likewise.
2143 (get_frame_func_if_available): Likewise.
2144 (read_frame_register_unsigned): Likewise.
2145 (deprecated_frame_register_read): Likewise.
2146 (get_frame_register_bytes): Likewise.
2147 (has_stack_frames): Likewise.
2148 (inside_main_func): Likewise.
2149 (inside_entry_func): Likewise.
2150 (get_frame_pc_if_available): Likewise.
2151 (get_frame_address_in_block_if_available): Likewise.
2152 (frame_unwinder_is): Likewise.
2153 (safe_frame_unwind_memory): Likewise.
2154 (frame_unwind_arch): Likewise.
2155
2156 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
2157
2158 * frame.c (frame_info) <prev_func> <p>: Rename to status, change
2159 type to cached_copy_status.
2160 (fprintf_frame): Adjust.
2161 (get_frame_func_if_available): Adjust.
2162 (frame_cleanup_after_sniffer): Adjust.
2163
2164 2020-08-04 Mark Wielaard <mark@klomp.org>
2165
2166 * MAINTAINERS (Write After Approval): Update email address.
2167
2168 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
2169
2170 * gdbtypes.h (TYPE_DYN_PROP_ADDR): Remove, replace uses with
2171 dynamic_prop::const_val.
2172
2173 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
2174
2175 * gdbtypes.h (TYPE_DYN_PROP_KIND): Remove, replace uses with
2176 dynamic_prop::kind.
2177
2178 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
2179
2180 * gdbtypes.h (TYPE_DYN_PROP_BATON): Remove.
2181
2182 2020-08-04 Jose E. Marchesi <jose.marchesi@oracle.com>
2183
2184 * configure.tgt: Set gdb_sim for bpf-*-* targets.
2185
2186 2020-08-04 Weimin Pan <weimin.pan@oracle.com>
2187 Jose E. Marchesi <jose.marchesi@oracle.com>
2188
2189 * configure.tgt: Add entry for bpf-*-*.
2190 * Makefile.in (ALL_TARGET_OBS): Add bpf-tdep.o
2191 (ALLDEPFILES): Add bpf-tdep.c.
2192 * bpf-tdep.c: New file.
2193 * MAINTAINERS: Add bpf target and maintainer.
2194 * NEWS: Mention the support for the new target.
2195
2196 2020-08-04 Tom de Vries <tdevries@suse.de>
2197
2198 PR symtab/23270
2199 * dwarf2/read.c (find_partial_die): Change internal error into Dwarf
2200 Error.
2201
2202 2020-08-03 John Baldwin <jhb@FreeBSD.org>
2203
2204 * syscalls/freebsd.xml: Regenerate.
2205
2206 2020-08-03 John Baldwin <jhb@FreeBSD.org>
2207
2208 * syscalls/update-freebsd.sh: Fix usage and year range.
2209
2210 2020-08-03 Tom de Vries <tdevries@suse.de>
2211
2212 PR symtab/26333
2213 * dwarf2/read.c (dwarf_decode_lines_1): Ignore
2214 DW_LNE_lo_user/DW_LNE_hi_user range.
2215
2216 2020-07-30 Simon Marchi <simon.marchi@polymtl.ca>
2217
2218 PR ada/26318
2219 * ada-lang.c (ada_modulus): Return 0 if property is not of const
2220 kind.
2221
2222 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2223
2224 * breakpoint.c (set_breakpoint_condition): Do minor refactoring.
2225
2226 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2227
2228 * breakpoint.c (set_breakpoint_condition): Update the condition
2229 expressions after checking that the input condition string parses
2230 successfully and does not contain junk at the end.
2231
2232 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2233
2234 * breakpoint.c (set_breakpoint_condition): Update the
2235 condition string after parsing the new condition successfully.
2236
2237 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2238
2239 * proc-api.c (_STRUCTURED_PROC): Don't define.
2240 * proc-events.c: Likewise.
2241 * proc-flags.c: Likewise.
2242 * proc-why.c: Likewise.
2243 * procfs.c: Likewise.
2244
2245 * Makefile.in (INTERNAL_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
2246 * configure, config.in: Regenerate.
2247
2248 2020-07-30 Tom de Vries <tdevries@suse.de>
2249
2250 PR build/26320
2251 * ui-style.h (struct ui_file_style::color): Wrap m_value and
2252 m_red/m_green/m_blue in a union.
2253
2254 2020-07-29 Tom de Vries <tdevries@suse.de>
2255
2256 PR tdep/26280
2257 * s390-tdep.c (s390_displaced_step_fixup): Fix Wmaybe-uninitialized.
2258
2259 2020-07-28 Tom Tromey <tromey@adacore.com>
2260
2261 PR symtab/26270:
2262 * symtab.h (find_pc_partial_function_sym): Declare.
2263 * cli/cli-cmds.c (disassemble_command): Use
2264 find_pc_partial_function_sym. Check asm_demangle.
2265 * blockframe.c (cache_pc_function_sym): New global.
2266 (cache_pc_function_name): Remove.
2267 (clear_pc_function_cache): Update.
2268 (find_pc_partial_function_sym): New function, from
2269 find_pc_partial_function.
2270 (find_pc_partial_function): Rewrite using
2271 find_pc_partial_function_sym.
2272
2273 2020-07-28 Tom Tromey <tromey@adacore.com>
2274
2275 * cli/cli-cmds.c (_initialize_cli_cmds): Rearrange "disassemble"
2276 help. Add usage.
2277
2278 2020-07-28 Tom Tromey <tromey@adacore.com>
2279
2280 * dwarf2/expr.c (dwarf_expr_context::execute_stack_op)
2281 <DW_OP_GNU_variable_value>: Cast to address type.
2282
2283 2020-07-28 Kamil Rytarowski <n54@gmx.com>
2284
2285 * nbsd-nat.h (nbsd_nat_target::xfer_partial): New declaration.
2286 * nbsd-nat.c (nbsd_nat_target::xfer_partial): New function.
2287 * nbsd-tdep.c (nbsd_gdbarch_data_handle, struct nbsd_gdbarch_data)
2288 (init_nbsd_gdbarch_data, get_nbsd_gdbarch_data)
2289 (nbsd_get_siginfo_type): New.
2290 (nbsd_init_abi): Install gdbarch "get_siginfo_type" method.
2291 (_initialize_nbsd_tdep): New.
2292
2293 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
2294
2295 PR binutils/26301
2296 * configure: Regenerated.
2297
2298 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
2299
2300 PR binutils/26301
2301 * configure: Regenerated.
2302
2303 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
2304
2305 * python/py-frame.c: Remove 'user-regs.h' include.
2306 (frapy_read_register): Rewrite to make use of
2307 gdbpy_parse_register_id.
2308 * python/py-registers.c (gdbpy_parse_register_id): New function,
2309 moved here from python/py-unwind.c. Updated the return type, and
2310 also accepts register descriptor objects.
2311 * python/py-unwind.c: Remove 'user-regs.h' include.
2312 (pyuw_parse_register_id): Moved to python/py-registers.c.
2313 (unwind_infopy_add_saved_register): Update to use
2314 gdbpy_parse_register_id.
2315 (pending_framepy_read_register): Likewise.
2316 * python/python-internal.h (gdbpy_parse_register_id): Declare.
2317
2318 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
2319
2320 * python/py-registers.c: Add 'user-regs.h' include.
2321 (register_descriptor_iter_find): New function.
2322 (register_descriptor_iterator_object_methods): New static global
2323 methods array.
2324 (register_descriptor_iterator_object_type): Add pointer to methods
2325 array.
2326
2327 2020-07-27 John Baldwin <jhb@FreeBSD.org>
2328
2329 * fbsd-nat.h: Include <osreldate.h>. Define USE_SIGTRAP_SIGINFO
2330 for all architectures on FreeBSD 11.3 and later.
2331
2332 2020-07-27 Tom Tromey <tromey@adacore.com>
2333
2334 * gcore.h (load_corefile): Don't declare.
2335
2336 2020-07-27 Tom de Vries <tdevries@suse.de>
2337
2338 * configure.ac: Fix sys/sockets.h -> sys/socket.h typo.
2339 * config.in: Regenerate.
2340 * configure: Regenerate.
2341
2342 2020-07-26 Eli Zaretskii <eliz@gnu.org>
2343
2344 * configure.ac (AC_CHECK_HEADERS): Check for sys/socket.h and
2345 ws2tcpip.h. When checking whether socklen_t type is defined, use
2346 ws2tcpip.h if it is available and sys/socket.h isn't.
2347 * configure: Regenerate.
2348 * config.in: Regenerate.
2349
2350 2020-07-25 Andrew Burgess <andrew.burgess@embecosm.com>
2351
2352 PR fortran/23051
2353 PR fortran/26139
2354 * valops.c (value_ind): Pass address to
2355 readjust_indirect_value_type.
2356 * value.c (readjust_indirect_value_type): Make parameter
2357 non-const, and add extra address parameter. Resolve original type
2358 before using it.
2359 * value.h (readjust_indirect_value_type): Update function
2360 signature and comment.
2361
2362 2020-07-25 Tom de Vries <tdevries@suse.de>
2363
2364 PR symtab/26243
2365 * dwarf2/read.c (lnp_state_machine::record_line): Ignore zero line
2366 entries.
2367
2368 2020-07-24 Aaron Merey <amerey@redhat.com>
2369
2370 * Makefile.in: Replace LIBDEBUGINFOD with DEBUGINFOD_LIBS.
2371 * configure: Rebuild.
2372
2373 2020-07-23 Kevin Buettner <kevinb@redhat.com>
2374
2375 PR corefiles/26294
2376 * corelow.c (_initialize_corelow): Add period to help text
2377 for "maintenance print core-file-backed-mappings".
2378
2379 2020-07-23 Pedro Alves <pedro@palves.net>
2380
2381 * frame-unwind.c (frame_unwind_try_unwinder): On exception, don't
2382 touch THIS_CACHE/THIS_FRAME if the frame cache was cleared
2383 meanwhile.
2384 * frame.c (frame_cache_generation, get_frame_cache_generation):
2385 New.
2386 (reinit_frame_cache): Increment FRAME_CACHE_GENERATION.
2387 (get_prev_frame_if_no_cycle): On exception, don't touch
2388 PREV_FRAME/THIS_FRAME if the frame cache was cleared meanwhile.
2389 * frame.h (get_frame_cache_generation): Declare.
2390
2391 2020-07-23 Tom de Vries <tdevries@suse.de>
2392
2393 PR tui/26282
2394 * tui/tui-winsource.h (struct tui_source_windows::tui_source_windows):
2395 New default constructor.
2396
2397 2020-07-23 Andrew Burgess <andrew.burgess@embecosm.com>
2398
2399 * disasm.c (do_mixed_source_and_assembly_deprecated): Don't
2400 exclude non-statement entries.
2401
2402 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2403
2404 * NEWS (New commands): Mention new command
2405 "maintenance print core-file-backed-mappings".
2406
2407 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2408
2409 * corelow.c (gdbcmd.h): Include.
2410 (core_target::info_proc_mappings): New method.
2411 (get_current_core_target): New function.
2412 (maintenance_print_core_file_backed_mappings): New function.
2413 (_initialize_corelow): Add core-file-backed-mappings to
2414 "maint print" commands.
2415
2416 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2417
2418 * linux-tdep.c (dump_note_entry_p): New function.
2419 (linux_dump_mapping_p_ftype): New typedef.
2420 (linux_find_memory_regions_full): Add new parameter,
2421 should_dump_mapping_p.
2422 (linux_find_memory_regions): Adjust call to
2423 linux_find_memory_regions_full.
2424 (linux_make_mappings_core_file_notes): Use dump_note_entry_p in
2425 call to linux_find_memory_regions_full.
2426
2427 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2428
2429 * corelow.c (solist.h, unordered_map): Include.
2430 (class core_target): Add field m_core_file_mappings and
2431 method build_file_mappings.
2432 (core_target::core_target): Call build_file_mappings.
2433 (core_target::~core_target): Free memory associated with
2434 m_core_file_mappings.
2435 (core_target::build_file_mappings): New method.
2436 (core_target::xfer_partial): Use m_core_file_mappings
2437 for memory transfers.
2438 * linux-tdep.c (linux_read_core_file_mappings): New
2439 function.
2440 (linux_core_info_proc_mappings): Rewrite to use
2441 linux_read_core_file_mappings.
2442 (linux_init_abi): Register linux_read_core_file_mappings.
2443
2444 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2445
2446 * arch-utils.c (default_read_core_file_mappings): New function.
2447 * arch-utils.c (default_read_core_file_mappings): Declare.
2448 * gdbarch.sh (read_core_file_mappings): New gdbarch method.
2449 * gdbarch.h, gdbarch.c: Regenerate.
2450
2451 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2452
2453 PR corefiles/25631
2454 * corelow.c (core_target:xfer_partial): Revise
2455 TARGET_OBJECT_MEMORY case to consider non-SEC_HAS_CONTENTS
2456 case after first checking the stratum beneath the core
2457 target.
2458 (has_all_memory): Return true.
2459 * target.c (raw_memory_xfer_partial): Revise comment
2460 regarding use of has_all_memory.
2461
2462 2020-07-22 Kevin Buettner <kevinb@redhat.com>
2463
2464 * exec.h (section_table_xfer_memory): Revise declaration,
2465 replacing section name parameter with an optional callback
2466 predicate.
2467 * exec.c (section_table_xfer_memory): Likewise.
2468 * bfd-target.c, exec.c, target.c, corelow.c: Adjust all callers
2469 of section_table_xfer_memory.
2470
2471 2020-07-22 Tom Tromey <tromey@adacore.com>
2472
2473 * mi/mi-cmd-stack.c (list_args_or_locals): Use
2474 lookup_symbol_search_name.
2475
2476 2020-07-22 Andrew Burgess <andrew.burgess@embecosm.com>
2477
2478 * python/py-registers.c (gdbpy_register_object_data_init): Remove
2479 redundant local variable.
2480 (gdbpy_get_register_descriptor): Extract descriptor vector as a
2481 reference, not pointer, update code accordingly.
2482
2483 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2484 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2485
2486 * objfiles.h (struct objfile) <skip_jit_symbol_lookup>: New field.
2487 * jit.c (jit_breakpoint_re_set_internal): Use the
2488 `skip_jit_symbol_lookup` field.
2489
2490 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2491 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2492
2493 * jit.c (jit_read_descriptor): Define the descriptor address once,
2494 use twice.
2495 (jit_breakpoint_deleted): Move the declaration of the loop variable
2496 `iter` into the loop header.
2497 (jit_breakpoint_re_set_internal): Move the declaration of the local
2498 variable `objf_data` to the first point of definition.
2499 (jit_event_handler): Move the declaration of local variables
2500 `code_entry`, `entry_addr`, and `objf` to their first point of use.
2501 Rename `objf` to `jited`.
2502
2503 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2504
2505 * jit.h (struct jiter_objfile_data) <jiter_objfile_data, objfile>:
2506 Remove.
2507 * jit.c (get_jiter_objfile_data): Update.
2508
2509 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2510 Simon Marchi <simon.marchi@polymtl.ca>
2511
2512 * jit.c (struct jit_program_space_data): Remove.
2513 (jit_program_space_key): Remove.
2514 (jiter_objfile_data::~jiter_objfile_data): Remove program space
2515 stuff.
2516 (get_jit_program_space_data): Remove.
2517 (jit_breakpoint_deleted): Iterate on all of the program space's
2518 objfiles.
2519 (jit_inferior_init): Likewise.
2520 (jit_breakpoint_re_set_internal): Likewise. Also change return
2521 type to void.
2522 (jit_breakpoint_re_set): Pass current_program_space to
2523 jit_breakpoint_re_set_internal.
2524
2525 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2526
2527 * jit.h (struct jiter_objfile_data) <cached_code_address,
2528 jit_breakpoint>: Move to here from ...
2529 * jit.c (jit_program_space_data): ... here.
2530 (jiter_objfile_data::~jiter_objfile_data): Update.
2531 (jit_breakpoint_deleted): Update.
2532 (jit_breakpoint_re_set_internal): Update.
2533
2534 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2535
2536 * jit.c (jiter_objfile_data::~jiter_objfile_data): Remove some
2537 checks.
2538 (jit_read_descriptor): Remove NULL check.
2539 (jit_event_handler): Add an assertion.
2540
2541 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2542
2543 * jit.h (struct jit_objfile_data): Split into...
2544 (struct jiter_objfile_data): ... this ...
2545 (struct jited_objfile_data): ... and this.
2546 * objfiles.h (struct objfile) <jit_data>: Remove.
2547 <jiter_data, jited_data>: New fields.
2548 * jit.c (jit_objfile_data::~jit_objfile_data): Rename to ...
2549 (jiter_objfile_data::~jiter_objfile_data): ... this.
2550 (get_jit_objfile_data): Rename to ...
2551 (get_jiter_objfile_data): ... this.
2552 (add_objfile_entry): Update.
2553 (jit_read_descriptor): Use get_jiter_objfile_data.
2554 (jit_find_objf_with_entry_addr): Use objfile's jited_data field.
2555 (jit_breakpoint_re_set_internal): Use get_jiter_objfile_data.
2556 (jit_inferior_exit_hook): Use objfile's jited_data field.
2557
2558 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
2559
2560 * jit.h: Forward-declare `struct minimal_symbol`.
2561 (struct jit_objfile_data): Migrate to here from jit.c; also add a
2562 constructor, destructor, and an objfile* field.
2563 * jit.c (jit_objfile_data): Remove.
2564 (struct jit_objfile_data): Migrate from here to jit.h.
2565 (jit_objfile_data::~jit_objfile_data): New destructor
2566 implementation with code moved from free_objfile_data.
2567 (free_objfile_data): Delete.
2568 (get_jit_objfile_data): Update to use the jit_data field of objfile.
2569 (jit_find_objf_with_entry_addr): Ditto.
2570 (jit_inferior_exit_hook): Ditto.
2571 (_initialize_jit): Remove the call to
2572 register_objfile_data_with_cleanup.
2573 * objfiles.h (struct objfile) <jit_data>: New field.
2574
2575 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2576
2577 * jit.h: Forward-declare `struct objfile`.
2578 (jit_event_handler): Add a second parameter, the JITer objfile.
2579 * jit.c (jit_read_descriptor): Change the signature to take the
2580 JITer objfile as an argument instead of the jit_program_space_data.
2581 (jit_inferior_init): Update the call to jit_read_descriptor.
2582 (jit_event_handler): Use the new JITer objfile argument when calling
2583 jit_read_descriptor.
2584 * breakpoint.c (handle_jit_event): Update the call to
2585 jit_event_handler to pass the JITer objfile.
2586
2587 2020-07-21 John Baldwin <jhb@FreeBSD.org>
2588
2589 * gdbarch.c: Regenerate.
2590 * gdbarch.h: Regenerate.
2591 * gdbarch.sh (handle_segmentation_fault): Remove method.
2592 * infrun.c (handle_segmentation_fault): Remove.
2593 (print_signal_received_reason): Remove call to
2594 handle_segmentation_fault.
2595
2596 2020-07-21 John Baldwin <jhb@FreeBSD.org>
2597
2598 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
2599 Rename to sparc64_linux_report_signal_info and add siggnal
2600 argument.
2601 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
2602 instead of sparc64_linux_handle_segmentation_fault.
2603
2604 2020-07-21 John Baldwin <jhb@FreeBSD.org>
2605
2606 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
2607 i386_linux_report_signal_info instead of
2608 i386_linux_handle_segmentation_fault.
2609 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
2610 to i386_linux_report_signal_info and add siggnal argument.
2611 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
2612 of i386_linux_handle_segmentation_fault.
2613 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
2614 to i386_linux_report_signal_info and add siggnal argument.
2615
2616 2020-07-21 John Baldwin <jhb@FreeBSD.org>
2617
2618 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
2619 hook if present.
2620
2621 2020-07-21 John Baldwin <jhb@FreeBSD.org>
2622
2623 * gdbarch.c: Regenerate.
2624 * gdbarch.h: Regenerate.
2625 * gdbarch.sh (report_signal_info): New method.
2626 * infrun.c (print_signal_received_reason): Invoke gdbarch
2627 report_signal_info hook if present.
2628
2629 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
2630
2631 * python/py-registers.c : Add 'unordered_map' include.
2632 (gdbpy_new_reggroup): Renamed to...
2633 (gdbpy_get_reggroup): ...this. Update to only create register
2634 group descriptors when needed.
2635 (gdbpy_reggroup_iter_next): Update.
2636
2637 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
2638
2639 * python/py-registers.c (gdbpy_register_object_data): New static
2640 global.
2641 (gdbpy_register_object_data_init): New function.
2642 (gdbpy_new_register_descriptor): Renamed to...
2643 (gdbpy_get_register_descriptor): ...this, and update to reuse
2644 existing register descriptors where possible.
2645 (gdbpy_register_descriptor_iter_next): Update.
2646 (gdbpy_initialize_registers): Register new gdbarch data.
2647
2648 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
2649
2650 * linux-nat.c (stopped_pids): Make static.
2651
2652 2020-07-21 Simon Marchi <simon.marchi@polymtl.ca>
2653
2654 PR ada/26235
2655 * gdbtypes.c (ada_discrete_type_low_bound,
2656 ada_discrete_type_high_bound): Handle undefined bounds.
2657
2658 2020-07-21 Kamil Rytarowski <n54@gmx.com>
2659
2660 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
2661 declaration.
2662 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
2663 function.
2664
2665 2020-07-20 John Baldwin <jhb@FreeBSD.org>
2666
2667 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
2668 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
2669 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
2670 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
2671 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
2672 method.
2673
2674 2020-07-20 Ludovic Courtès <ludo@gnu.org>
2675
2676 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
2677 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
2678 which are deprecated in Guile 3.0.
2679 * configure.ac (try_guile_versions): Add "guile-3.0".
2680 * configure (try_guile_versions): Regenerate.
2681 * NEWS: Update entry.
2682
2683 2020-07-20 Ludovic Courtès <ludo@gnu.org>
2684 Doug Evans <dje@google.com>
2685
2686 PR gdb/21104
2687 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
2688 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
2689 USING_GUILE_BEFORE_2_2.
2690 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
2691 Change type to 'scm_t_port_type *'.
2692 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
2693 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
2694 parameter and honor it. Update callers.
2695 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
2696 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
2697 functions.
2698 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
2699 USING_GUILE_BEFORE_2_2.
2700 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
2701 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
2702 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
2703 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
2704 and 'SCM_PORT_TYPE'.
2705 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
2706 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
2707 (gdbscm_memory_port_read, gdbscm_memory_port_write)
2708 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
2709 [!USING_GUILE_BEFORE_2_2]: New functions.
2710 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
2711 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
2712 'gdbscm_memory_port_read'.
2713 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
2714 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
2715 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
2716 function.
2717 (ioscm_init_memory_port): Remove.
2718 (ioscm_init_memory_port_stream): New function
2719 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
2720 function.
2721 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
2722 Return scm_from_uint (0).
2723 (gdbscm_set_memory_port_read_buffer_size_x)
2724 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
2725 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
2726 Return scm_from_uint (0).
2727 (gdbscm_set_memory_port_write_buffer_size_x)
2728 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
2729 * configure.ac (try_guile_versions): Add "guile-2.2".
2730 * configure: Regenerate.
2731 * NEWS: Add entry.
2732
2733 2020-07-18 Tom Tromey <tom@tromey.com>
2734
2735 * linux-nat.c (linux_multi_process): Remove.
2736 (linux_nat_target::supports_multi_process): Return true.
2737
2738 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
2739
2740 * arch/riscv.c (riscv_tdesc_cache): Change map type.
2741 (riscv_lookup_target_description): Return pointer out of
2742 unique_ptr.
2743 * target-descriptions.c (allocate_target_description): Add
2744 comment.
2745 (target_desc_deleter::operator()): Likewise.
2746 * target-descriptions.h (struct target_desc_deleter): Moved to
2747 gdbsupport/tdesc.h.
2748 (target_desc_up): Likewise.
2749
2750 2020-07-17 Tom Tromey <tromey@adacore.com>
2751
2752 * linux-nat.c (linux_nat_target::supports_non_stop)
2753 (linux_nat_target::always_non_stop_p): Use "true".
2754 (linux_nat_target::supports_disable_randomization): Use "true" and
2755 "false".
2756
2757 2020-07-16 Caroline Tice <cmtice@google.com>
2758
2759 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
2760 (RNGLIST_HEADER_SIZE64): New constant definition.
2761 (struct dwop_section_names): Add rnglists_dwo.
2762 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
2763 (struct loclist_header): Rename to 'loclists_rnglists_header'.
2764 (struct dwo_sections): Add rnglists field.
2765 (read_attribut_reprocess): Add tag parameter.
2766 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
2767 (cu_debug_rnglists_section): New function (decl & definition).
2768 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
2769 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
2770 die whose range is being checked; get rnglist section from
2771 cu_debug_rnglists_section, to get from either objfile or dwo file as
2772 appropriate. Add cases for DW_RLE_base_addressx,
2773 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
2774 the base address to DW_RLE_offset_pairs (not to all ranges), moving
2775 test inside if-condition and updating complaint message.
2776 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
2777 dwarf2_rnglists_process.
2778 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
2779 dwarf2_ranges_process.
2780 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
2781 need_ranges_base and update comment appropriately. Also pass die tag
2782 to dwarf2_ranges_read.
2783 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
2784 need_ranges_base and update comment appropriately. Also pass die tag
2785 to dwarf2_ranges_process.
2786 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
2787 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
2788 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
2789 need_ranges_base and update comment appropriately. Also pass die tag
2790 to read_attribute_reprocess and dwarf2_ranges_read.
2791 (read_loclist_header): Rename function to read_loclists_rnglists_header,
2792 and update function comment appropriately.
2793 (read_loclist_index): Call read_loclists_rnglists_header instead of
2794 read_loclist_header.
2795 (read_rnglist_index): New function.
2796 (read_attribute_reprocess): Add tag parameter. Add code for
2797 DW_FORM_rnglistx, passing tag to read_rnglist_index.
2798 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
2799
2800 2020-07-15 Andrew Burgess <andrew.burgess@embecosm.com>
2801
2802 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
2803 being resolved.
2804
2805 2020-07-14 Andrew Burgess <andrew.burgess@embecosm.com>
2806
2807 * arch-utils.c (show_architecture): Update formatting of messages.
2808
2809 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2810
2811 * gdbtypes.h (struct type) <bounds>: Handle array and string
2812 types.
2813 * ada-lang.c (assign_aggregate): Use type::bounds on
2814 array/string type.
2815 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
2816 * c-varobj.c (c_number_of_children): Likewise.
2817 (c_describe_child): Likewise.
2818 * eval.c (evaluate_subexp_for_sizeof): Likewise.
2819 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
2820 (f_type_print_base): Likewise.
2821 * f-valprint.c (f77_array_offset_tbl): Likewise.
2822 (f77_get_upperbound): Likewise.
2823 (f77_print_array_1): Likewise.
2824 * guile/scm-type.c (gdbscm_type_range): Likewise.
2825 * m2-typeprint.c (m2_array): Likewise.
2826 (m2_is_long_set_of_type): Likewise.
2827 * m2-valprint.c (get_long_set_bounds): Likewise.
2828 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
2829 * python/py-type.c (typy_range): Likewise.
2830 * rust-lang.c (rust_internal_print_type): Likewise.
2831 * type-stack.c (type_stack::follow_types): Likewise.
2832 * valarith.c (value_subscripted_rvalue): Likewise.
2833 * valops.c (value_cast): Likewise.
2834
2835 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2836
2837 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
2838 callers to use the equivalent accessor methods.
2839
2840 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2841
2842 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
2843 (struct type) <bit_stride>: New method.
2844 (TYPE_BIT_STRIDE): Remove.
2845 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
2846
2847 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2848
2849 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
2850 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
2851 callers to use the equivalent accessor methods instead.
2852
2853 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2854
2855 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
2856 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
2857 callers to use the equivalent accessor methods instead.
2858
2859 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2860
2861 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
2862 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
2863 to use dynamic_prop::kind.
2864
2865 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2866
2867 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
2868 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
2869 to get the bound property's kind and check against
2870 PROP_UNDEFINED.
2871
2872 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2873
2874 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
2875 all callers to use type::range_bounds followed by
2876 dynamic_prop::{low,high}.
2877
2878 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
2879
2880 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
2881 const_val, set_const_val, baton, set_locexpr, set_loclist,
2882 set_addr_offset, variant_parts, set_variant_parts,
2883 original_type, set_original_type>: New methods.
2884 <kind>: Rename to...
2885 <m_kind>: ... this. Update all users to use the new methods
2886 instead.
2887 <data>: Rename to...
2888 <m_data>: ... this. Update all users to use the new methods
2889 instead.
2890
2891 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2892
2893 * gdbtypes.c (get_discrete_bounds): Return failure if
2894 the range type's bounds are not both defined and constant
2895 values.
2896 (get_array_bounds): Update comment. Remove undefined bound check.
2897
2898 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
2899
2900 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
2901 the type::bounds method directly.
2902
2903 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
2904
2905 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
2906 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
2907 are used to set the range type's bounds to use set_bounds.
2908
2909 2020-07-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2910
2911 * exec.c (_initialize_exec): Update exec-file-mismatch help.
2912
2913 2020-07-10 Pedro Alves <pedro@palves.net>
2914
2915 * gdbthread.h (inferior_ref): Define.
2916 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
2917 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
2918 * thread.c
2919 (scoped_restore_current_thread::restore):
2920 Adjust to gdb::ref_ptr.
2921 (scoped_restore_current_thread::~scoped_restore_current_thread):
2922 Remove manual decref handling.
2923 (scoped_restore_current_thread::scoped_restore_current_thread):
2924 Adjust to use
2925 inferior_ref::new_reference/thread_info_ref::new_reference.
2926 Incref the thread before calling get_frame_id instead of after.
2927 Let TARGET_CLOSE_ERROR propagate.
2928
2929 2020-07-10 Pedro Alves <pedro@palves.net>
2930
2931 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
2932 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
2933 NOT_AVAILABLE_ERROR.
2934 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
2935 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
2936
2937 2020-07-10 Simon Marchi <simon.marchi@polymtl.ca>
2938 Pedro Alves <pedro@palves.net>
2939
2940 PR gdb/26199
2941 * infrun.c (threads_are_resumed_pending_p): Delete.
2942 (do_target_wait): Remove threads_are_executing and
2943 threads_are_resumed_pending_p checks from the inferior_matches
2944 lambda. Update comments.
2945
2946 2020-07-10 Pedro Alves <pedro@palves.net>
2947
2948 PR gdb/26199
2949 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
2950 executing threads.
2951
2952 2020-07-10 Pedro Alves <pedro@palves.net>
2953
2954 PR gdb/26199
2955 * infrun.c (handle_no_resumed): Handle multiple targets.
2956
2957 2020-07-10 Pedro Alves <pedro@palves.net>
2958
2959 PR gdb/26199
2960 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
2961 target_is_async_p.
2962
2963 2020-07-10 Pedro Alves <pedro@palves.net>
2964
2965 PR gdb/26199
2966 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
2967 threads, not all threads.
2968
2969 2020-07-10 Pedro Alves <pedro@palves.net>
2970
2971 PR gdb/26199
2972 * remote.c (remote_target::open_1): Pass remote target pointer as
2973 data to create_async_event_handler.
2974 (remote_async_inferior_event_handler): Mark async event handler
2975 before returning if the remote target still has either pending
2976 events or unacknowledged notifications.
2977
2978 2020-07-10 John Baldwin <jhb@FreeBSD.org>
2979
2980 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
2981 declaration.
2982 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
2983 function.
2984
2985 2020-07-09 John Baldwin <jhb@FreeBSD.org>
2986
2987 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
2988 inferior_ptid.
2989
2990 2020-07-09 John Baldwin <jhb@FreeBSD.org>
2991
2992 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
2993 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
2994 AT_FREEBSD_PS_STRINGS.
2995
2996 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
2997
2998 * auto-load.c (auto_load_objfile_script_1): Convert drive part
2999 of debugfile path on Windows.
3000
3001 2020-07-08 John Baldwin <jhb@FreeBSD.org>
3002
3003 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
3004 argument to 'data'.
3005
3006 2020-07-08 Tom Tromey <tromey@adacore.com>
3007
3008 * ada-lang.c (ada_exception_message_1): Use read_memory.
3009
3010 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
3011
3012 PR python/22748
3013 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
3014 special handling for inline frames.
3015 * findvar.c (value_of_register_lazy): Skip inline frames when
3016 creating lazy register values.
3017 * frame.c (frame_id_computed_p): Delete definition.
3018 * frame.h (frame_id_computed_p): Delete declaration.
3019
3020 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
3021
3022 * NEWS: Mention additions to Python API.
3023 * python/py-arch.c (archpy_register_groups): New function.
3024 (arch_object_methods): Add 'register_groups' method.
3025 * python/py-registers.c (reggroup_iterator_object): New struct.
3026 (reggroup_object): New struct.
3027 (gdbpy_new_reggroup): New function.
3028 (gdbpy_reggroup_to_string): New function.
3029 (gdbpy_reggroup_name): New function.
3030 (gdbpy_reggroup_iter): New function.
3031 (gdbpy_reggroup_iter_next): New function.
3032 (gdbpy_new_reggroup_iterator): New function
3033 (gdbpy_initialize_registers): Register new types.
3034 (reggroup_iterator_object_type): Define new Python type.
3035 (gdbpy_reggroup_getset): New static global.
3036 (reggroup_object_type): Define new Python type.
3037 * python/python-internal.h
3038
3039 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
3040
3041 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
3042 * python/py-arch.c (archpy_registers): New function.
3043 (arch_object_methods): Add 'registers' method.
3044 * python/py-registers.c: New file.
3045 * python/python-internal.h
3046 (gdbpy_new_register_descriptor_iterator): Declare.
3047 (gdbpy_initialize_registers): Declare.
3048 * python/python.c (do_start_initialization): Call
3049 gdbpy_initialize_registers.
3050 * NEWS: Mention additions to the Python API.
3051
3052 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
3053
3054 * NEWS: Mention new Python API method.
3055 * python/py-unwind.c (pending_framepy_architecture): New function.
3056 (pending_frame_object_methods): Add architecture method.
3057
3058 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
3059
3060 * gdbarch.c: Regenerate.
3061 * gdbarch.h: Regenerate.
3062 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
3063 (gdbarch_data): Use internal_error for the case where
3064 deprecated_set_gdbarch_data was originally needed.
3065 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
3066 and use passed in obstack.
3067 (libunwind_frame_set_descr): Should no longer get back NULL from
3068 gdbarch_data.
3069 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
3070 type.
3071 * user-regs.c (user_regs_init): Update parameters, and use passed
3072 in obstack.
3073 (user_reg_add): Should no longer get back NULL from gdbarch_data.
3074 (_initialize_user_regs): Register as a pre-init gdbarch data type.
3075
3076 2020-07-06 Tom de Vries <tdevries@suse.de>
3077
3078 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
3079 End-Of-Sequence in lte_is_less_than.
3080 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
3081 "gdb: Don't reorder line table entries too much when sorting".
3082
3083 2020-07-06 Tom de Vries <tdevries@suse.de>
3084
3085 PR tui/26205
3086 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
3087
3088 2020-07-05 Tom de Vries <tdevries@suse.de>
3089
3090 PR build/26187
3091 * inferior.h (struct infcall_suspend_state_deleter): If available, use
3092 std::uncaught_exceptions instead of deprecated
3093 std::uncaught_exception.
3094
3095 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
3096
3097 * macroexp.h (macro_stringify): Return
3098 gdb::unique_xmalloc_ptr<char>.
3099 * macroexp.c (macro_stringify): Likewise.
3100 * macrotab.c (fixup_definition): Update.
3101
3102 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
3103
3104 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
3105 (lex_one_token): Update.
3106 * macroexp.c (struct macro_buffer) <release>: Return
3107 gdb::unique_xmalloc_ptr<char>.
3108 (macro_stringify): Update.
3109 (macro_expand): Update.
3110 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
3111 * macroexp.h (macro_expand_next): Likewise.
3112
3113 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
3114
3115 * macroexp.h (macro_lookup_ftype): Remove.
3116 (macro_expand, macro_expand_once, macro_expand_next): Remove
3117 lookup function parameters, add scope parameter.
3118 * macroexp.c (scan, substitute_args, expand, maybe_expand,
3119 macro_expand, macro_expand_once, macro_expand_next): Likewise.
3120 * macroscope.h (standard_macro_lookup): Change parameter type
3121 to macro_scope.
3122 * macroscope.c (standard_macro_lookup): Likewise.
3123 * c-exp.y (lex_one_token): Update.
3124 * macrocmd.c (macro_expand_command): Likewise.
3125 (macro_expand_once_command): Likewise.
3126
3127 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
3128
3129 * inf-loop.c (inferior_event_handler): Remove client_data param.
3130 * inf-loop.h (inferior_event_handler): Likewise.
3131 * infcmd.c (step_1): Adjust.
3132 * infrun.c (proceed): Adjust.
3133 (fetch_inferior_event): Remove client_data param.
3134 (infrun_async_inferior_event_handler): Adjust.
3135 * infrun.h (fetch_inferior_event): Remove `void *` param.
3136 * linux-nat.c (handle_target_event): Adjust.
3137 * record-btrace.c (record_btrace_handle_async_inferior_event):
3138 Adjust.
3139 * record-full.c (record_full_async_inferior_event_handler):
3140 Adjust.
3141 * remote.c (remote_async_inferior_event_handler): Adjust.
3142
3143 2020-07-01 Tom Tromey <tom@tromey.com>
3144
3145 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
3146 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
3147
3148 2020-07-01 Tom Tromey <tom@tromey.com>
3149
3150 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
3151 tui_gen_win_info.
3152 (tui_win_info::make_window): Merge with
3153 tui_gen_win_info::make_window.
3154 (tui_win_info::make_visible): Move from tui_gen_win_info.
3155 * tui/tui-win.c (tui_win_info::max_width): Move from
3156 tui_gen_win_info.
3157 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
3158 type.
3159 <window_factory>: Likewise.
3160 * tui/tui-layout.c (tui_win_info::resize): Move from
3161 tui_gen_win_info.
3162 (make_standard_window): Change return type.
3163 (get_locator_window, tui_get_window_by_name): Likewise.
3164 (tui_layout_window::apply): Remove a cast.
3165 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
3166 (struct tui_win_info): Merge with tui_gen_win_info.
3167 (struct tui_gen_win_info): Remove.
3168
3169 2020-07-01 Tom Tromey <tom@tromey.com>
3170
3171 * tui/tui-stack.h (struct tui_locator_window): Derive from
3172 tui_win_info.
3173 <do_scroll_horizontal, do_scroll_vertical>: New methods.
3174 <can_box>: New method.
3175
3176 2020-07-01 Tom Tromey <tom@tromey.com>
3177
3178 * tui/tui-stack.h (struct tui_locator_window): Remove body.
3179
3180 2020-07-01 Tom Tromey <tom@tromey.com>
3181
3182 * tui/tui-regs.c (tui_data_window::display_registers_from)
3183 (tui_data_window::display_registers_from)
3184 (tui_data_window::first_data_item_displayed)
3185 (tui_data_window::delete_data_content_windows): Update.
3186 (tui_data_window::refresh_window, tui_data_window::no_refresh):
3187 Remove.
3188 (tui_data_window::check_register_values): Update.
3189 (tui_data_item_window::rerender): Add parameters. Update.
3190 (tui_data_item_window::refresh_window): Remove.
3191 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
3192 virtual.
3193 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
3194 tui_gen_win_info.
3195 <refresh_window, max_height, min_height>: Remove.
3196 <rerender>: Add parameters.
3197 <x, y, visible>: New members.
3198 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
3199 <m_item_width>: New member.
3200
3201 2020-07-01 Tom Tromey <tom@tromey.com>
3202
3203 * tui/tui-regs.c (tui_data_window::show_register_group)
3204 (tui_data_window::check_register_values): Update.
3205 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
3206 from item_no.
3207
3208 2020-07-01 Tom Tromey <tom@tromey.com>
3209
3210 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
3211 useless "if".
3212
3213 2020-07-01 Tom Tromey <tom@tromey.com>
3214
3215 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
3216 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
3217
3218 2020-07-01 Tom Tromey <tom@tromey.com>
3219
3220 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
3221 * tui/tui-winsource.h (enum tui_line_or_address_kind)
3222 (struct tui_line_or_address): Move from tui-data.h.
3223 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
3224 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
3225 (tui_cmd_window, tui_source_window_base, tui_source_window)
3226 (tui_disasm_window): Don't declare.
3227 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
3228 to tui-winsource.h.
3229 (SINGLE_KEY): Move to tui-stack.c.
3230
3231 2020-07-01 Tom Tromey <tom@tromey.com>
3232
3233 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
3234 std::string.
3235 * tui/tui-regs.c (class tab_expansion_file): New.
3236 (tab_expansion_file::write): New method.
3237 (tui_register_format): Change return type. Use
3238 tab_expansion_file.
3239 (tui_get_register, tui_data_window::display_registers_from)
3240 (tui_data_item_window::rerender): Update.
3241 * tui/tui-io.h (tui_expand_tabs): Don't declare.
3242 * tui/tui-io.c (tui_expand_tabs): Remove.
3243
3244 2020-07-01 Tom Tromey <tom@tromey.com>
3245
3246 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
3247
3248 2020-07-01 Fangrui Song <maskray@google.com>
3249
3250 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
3251
3252 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
3253
3254 * dwarf2/read.c (set_die_type): Removed conditions to restrict
3255 forms for DW_AT_associated and DW_AT_allocated attributes,
3256 which is already checked in function attr_to_dynamic_prop.
3257
3258 2020-06-30 Tom Tromey <tromey@adacore.com>
3259
3260 * dwarf2/read.c (quirk_rust_enum): Correctly call
3261 alloc_rust_variant for default-less enum.
3262
3263 2020-06-30 Tom Tromey <tromey@adacore.com>
3264
3265 PR build/26183:
3266 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
3267 gdb::to_string.
3268
3269 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
3270
3271 * gdbarch.sh (displaced_step_copy_insn): Update doc.
3272 * gdbarch.h: Re-generate.
3273
3274 2020-06-28 Tom Tromey <tom@tromey.com>
3275
3276 * command.h (cmd_types): Remove.
3277 (cmd_type): Don't declare.
3278 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
3279 typedef.
3280 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
3281 * cli/cli-decode.c (cmd_type): Remove.
3282
3283 2020-06-27 Pedro Alves <palves@redhat.com>
3284
3285 * fork-child.c (prefork_hook): Adjust.
3286 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
3287 Delete.
3288 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
3289 * inferior.c (inferior::set_tty, inferior::tty): New methods.
3290 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
3291 Remove declarations.
3292 (struct inferior) <set_tty, tty>: New methods.
3293 (struct inferior) <terminal>: Rename to ...
3294 (struct inferior) <m_terminal>: ... this and make private.
3295 * main.c (captured_main_1): Adjust.
3296 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
3297 (mi_cmd_inferior_tty_show): Adjust.
3298 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
3299 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
3300
3301 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
3302
3303 * configure.ac: Add --enable-libctf: handle --disable-static
3304 properly.
3305 * acinclude.m4: sinclude ../config/enable.m4.
3306 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
3307 (LIBCTF): Substitute in.
3308 (CTF_DEPS): New, likewise.
3309 (CLIBS): libctf needs symbols from libbfd: move earlier.
3310 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
3311 flags.
3312 * ctfread.c: Surround in ENABLE_LIBCTF.
3313 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
3314 * configure: Regenerate.
3315 * config.in: Likewise.
3316
3317 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
3318
3319 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
3320
3321 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
3322
3323 * inferior.h (struct inferior) <terminal>: Change type to
3324 gdb::unique_xmalloc_ptr<char>.
3325 * inferior.c (inferior::~inferior): Don't free inf->terminal.
3326 * infcmd.c (set_inferior_io_terminal): Don't free terminal
3327 field, adjust to unique pointer.
3328 (get_inferior_io_terminal): Adjust to unique pointer.
3329
3330 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3331
3332 * riscv-tdep.c (riscv_print_registers_info): Loop over all
3333 registers, not just the known core set of registers.
3334
3335 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3336
3337 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
3338 fflags, frm, and fcsr registers.
3339 (riscv_register_reggroup_p): Remove unknown CSRs from save and
3340 restore groups.
3341 (riscv_tdesc_unknown_reg): New function.
3342 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
3343 tdesc_use_registers.
3344 * riscv-tdep.h (struct gdbarch_tdep): Add
3345 unknown_csrs_first_regnum, unknown_csrs_count,
3346 duplicate_fflags_regnum, duplicate_frm_regnum, and
3347 duplicate_fcsr_regnum fields.
3348
3349 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3350
3351 * target-descriptions.c (tdesc_use_registers): Add new parameter a
3352 callback, use the callback (when not null) to help number unknown
3353 registers.
3354 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
3355 (tdesc_use_registers): Add extra parameter to declaration.
3356
3357 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3358
3359 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
3360 in the file.
3361 (class riscv_pending_register_alias): Likewise.
3362 (riscv_register_feature::register_info): Change 'required_p' field
3363 to 'required', and change its type. Add 'check' member function.
3364 (riscv_register_feature::register_info::check): Define new member
3365 function.
3366 (riscv_xreg_feature): Change initialisation of 'required' field.
3367 (riscv_freg_feature): Likewise.
3368 (riscv_virtual_feature): Likewise.
3369 (riscv_csr_feature): Likewise.
3370 (riscv_check_tdesc_feature): Take extra parameter, the csr
3371 tdesc_feature, rewrite the function to use the new
3372 riscv_register_feature::register_info::check function.
3373 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
3374
3375 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3376
3377 * features/Makefile: Remove all references to the deleted files
3378 below.
3379 * features/riscv/32bit-csr.c: Deleted.
3380 * features/riscv/32bit-csr.xml: Deleted.
3381 * features/riscv/64bit-csr.c: Deleted.
3382 * features/riscv/64bit-csr.xml: Deleted.
3383 * features/riscv/rebuild-csr-xml.sh: Deleted.
3384
3385 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3386
3387 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
3388 whitespace error for declaration of names member variable.
3389 (struct riscv_register_feature): Add new prefer_first_name member
3390 variable, and fix whitespace error in declaration of registers.
3391 (riscv_xreg_feature): Initialize prefer_first_name field.
3392 (riscv_freg_feature): Likewise.
3393 (riscv_virtual_feature): Likewise.
3394 (riscv_csr_feature): Likewise.
3395 (riscv_register_name): Expand on comments. Remove register name
3396 modifications for CSR and virtual registers.
3397
3398 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3399
3400 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
3401 errors.
3402
3403 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
3404
3405 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
3406 riscv-opc.h.
3407 (class riscv_pending_register_alias): New class.
3408 (riscv_check_tdesc_feature): Take vector of pending aliases and
3409 populate it as appropriate.
3410 (riscv_setup_register_aliases): Delete.
3411 (riscv_gdbarch_init): Create vector of pending aliases and pass it
3412 to riscv_check_tdesc_feature in all cases. Use the vector to
3413 create the register aliases.
3414
3415 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3416
3417 * sol2-tdep.c (sol2_static_transform_name): Remove.
3418 (sol2_init_abi): Don't register it.
3419 * gdbarch.sh (static_transform_name): Remove.
3420 * gdbarch.c, gdbarch.h: Regenerate.
3421
3422 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
3423 gdbarch_static_transform_name.
3424 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
3425 * stabsread.c (define_symbol) <'X'>: Remove.
3426 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
3427 handling.
3428 <'V'>: Likewise.
3429 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
3430 <'S'>: Remove call to gdbarch_static_transform_name.
3431
3432 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3433
3434 * procfs.c (procfs_pre_trace): New function.
3435 (procfs_target::create_inferior): Pass it to fork_inferior.
3436
3437 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3438
3439 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
3440 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
3441 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
3442 sol2-tdep.o, sparc-sol2-tdep.o.
3443 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
3444 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
3445 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
3446 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
3447
3448 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3449
3450 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
3451 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
3452 Call sol2_init_abi.
3453 Remove calls to set_gdbarch_skip_solib_resolver,
3454 set_gdbarch_core_pid_to_str.
3455 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
3456 (i386_sol2_static_transform_name): Remove.
3457 (i386_sol2_init_abi): Call sol2_init_abi.
3458 Remove calls to set_gdbarch_sofun_address_maybe_missing,
3459 set_gdbarch_static_transform_name,
3460 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
3461 Use sol2_sigtramp_p.
3462 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
3463 (sol2_sigtramp_p): New function.
3464 (sol2_static_transform_name): New function.
3465 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
3466 (sol2_init_abi): New function.
3467 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
3468 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
3469 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
3470 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
3471 (sparc_sol2_static_transform_name): Remove.
3472 (sparc32_sol2_init_abi): Call sol2_init_abi.
3473 Remove calls to set_gdbarch_sofun_address_maybe_missing,
3474 set_gdbarch_static_transform_name,
3475 set_gdbarch_skip_solib_resolver,
3476 set_gdbarch_core_pid_to_str.
3477 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
3478 (sparc_sol2_static_transform_name): Remove
3479 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
3480 call sol2_sigtramp_p.
3481 (sparc64_sol2_init_abi): Call sol2_init_abi.
3482 Remove calls to set_gdbarch_sofun_address_maybe_missing,
3483 set_gdbarch_static_transform_name,
3484 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
3485
3486 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3487
3488 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
3489 * exec.c (validate_exec_file): If from_tty, set both
3490 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
3491 * symfile.c (symbol_file_add_with_addrs): if always_confirm
3492 and from_tty, unconditionally ask a confirmation.
3493
3494 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3495
3496 * target-descriptions.c (tdesc_architecture_name): Protect against
3497 NULL pointer dereference.
3498 (maint_print_xml_tdesc_cmd): New function.
3499 (_initialize_target_descriptions): Register new 'maint print
3500 xml-tdesc' command and give it the filename completer.
3501 * NEWS: Mention new 'maint print xml-tdesc' command.
3502
3503 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3504
3505 * target-descriptions.c (class tdesc_compatible_info): New class.
3506 (struct target_desc): Change type of compatible vector.
3507 (tdesc_compatible_p): Update for change in type of
3508 target_desc::compatible.
3509 (tdesc_compatible_info_list): New function.
3510 (tdesc_compatible_info_arch_name): New function.
3511 (tdesc_add_compatible): Update for change in type of
3512 target_desc::compatible.
3513 (print_c_tdesc::visit_pre): Likewise.
3514
3515 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3516
3517 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
3518 whitespace to underscore.
3519 (maint_print_c_tdesc_cmd): Use fake filename for target
3520 descriptions that came from the target.
3521 (_initialize_target_descriptions): Add filename command completion
3522 for 'maint print c-tdesc'.
3523
3524 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
3525
3526 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
3527 lines.
3528
3529 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
3530
3531 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
3532 lines.
3533 (dwarf2_find_location_expression): Likewise.
3534 (call_site_parameter_matches): Likewise.
3535 (dwarf2_compile_expr_to_ax): Likewise.
3536 (disassemble_dwarf_expression): Likewise.
3537 (loclist_describe_location): Likewise.
3538
3539 2020-06-23 Pedro Alves <palves@redhat.com>
3540
3541 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
3542 progspace-and-thread.h. Include scoped-mock-context.h instead.
3543 (register_to_value_test): Use scoped_mock_context.
3544 * regcache.c: Include "scoped-mock-context.h".
3545 (cooked_read_test): Don't error out if a target is already pushed.
3546 Use scoped_mock_context. Adjust.
3547 * scoped-mock-context.h: New file.
3548
3549 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3550
3551 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
3552 initializer.
3553 (ada_language::is_string_type_p): New member function.
3554 * c-lang.c (c_language_data): Delete la_is_string_type_p
3555 initializer.
3556 (cplus_language_data): Likewise.
3557 (asm_language_data): Likewise.
3558 (minimal_language_data): Likewise.
3559 * d-lang.c (d_language_data): Likewise.
3560 * f-lang.c (f_is_string_type_p): Delete function, implementation
3561 moved to f_language::is_string_type_p.
3562 (f_language_data): Delete la_is_string_type_p initializer.
3563 (f_language::is_string_type_p): New member function,
3564 implementation from f_is_string_type_p.
3565 * go-lang.c (go_is_string_type_p): Delete function, implementation
3566 moved to go_language::is_string_type_p.
3567 (go_language_data): Delete la_is_string_type_p initializer.
3568 (go_language::is_string_type_p): New member function,
3569 implementation from go_is_string_type_p.
3570 * language.c (language_defn::is_string_type_p): Define new member
3571 function.
3572 (default_is_string_type_p): Make static, add comment copied from
3573 header file.
3574 (unknown_language_data): Delete la_is_string_type_p initializer.
3575 (unknown_language::is_string_type_p): New member function.
3576 (auto_language_data): Delete la_is_string_type_p initializer.
3577 (auto_language::is_string_type_p): New member function.
3578 * language.h (language_data): Delete la_is_string_type_p field.
3579 (language_defn::is_string_type_p): Declare new function.
3580 (default_is_string_type_p): Delete desclaration, move comment to
3581 definition.
3582 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
3583 moved to m2_language::is_string_type_p.
3584 (m2_language_data): Delete la_is_string_type_p initializer.
3585 (m2_language::is_string_type_p): New member function,
3586 implementation from m2_is_string_type_p.
3587 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
3588 initializer.
3589 * opencl-lang.c (opencl_language_data): Likewise.
3590 * p-lang.c (pascal_is_string_type_p): Delete function,
3591 implementation moved to pascal_language::is_string_type_p.
3592 (pascal_language_data): Delete la_is_string_type_p initializer.
3593 (pascal_language::is_string_type_p): New member function,
3594 implementation from pascal_is_string_type_p.
3595 * rust-lang.c (rust_is_string_type_p): Delete function,
3596 implementation moved to rust_language::is_string_type_p.
3597 (rust_language_data): Delete la_is_string_type_p initializer.
3598 (rust_language::is_string_type_p): New member function,
3599 implementation from rust_is_string_type_p.
3600 * valprint.c (val_print_scalar_or_string_type_p): Update call to
3601 is_string_type_p.
3602
3603 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3604
3605 * ada-lang.c (ada_language_data): Delete la_print_typedef
3606 initializer.
3607 (ada_language::print_typedef): New member function.
3608 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
3609 (cplus_language_data): Likewise.
3610 (asm_language_data): Likewise.
3611 (minimal_language_data): Likewise.
3612 * d-lang.c (d_language_data): Likewise.
3613 * f-lang.c (f_language_data): Likewise.
3614 (f_language::print_typedef): New member function.
3615 * go-lang.c (go_language_data): Delete la_print_typedef
3616 initializer.
3617 * language.c (language_defn::print_typedef): Define member
3618 function.
3619 (unknown_language_data): Delete la_print_typedef initializer.
3620 (unknown_language::print_typedef): New member function.
3621 (auto_language_data): Delete la_print_typedef initializer.
3622 (auto_language::print_typedef): New member function.
3623 * language.h (language_data): Delete la_print_typedef field.
3624 (language_defn::print_typedef): Declare new member function.
3625 (LA_PRINT_TYPEDEF): Update call to print_typedef.
3626 (default_print_typedef): Delete declaration.
3627 * m2-lang.c (m2_language_data): Delete la_print_typedef
3628 initializer.
3629 (m2_language::print_typedef): New member function.
3630 * objc-lang.c (objc_language_data): Delete la_print_typedef
3631 initializer.
3632 * opencl-lang.c (opencl_language_data): Likewise.
3633 * p-lang.c (pascal_language_data): Likewise.
3634 (pascal_language::print_typedef): New member function.
3635 * rust-lang.c (rust_print_typedef): Delete function,
3636 implementation moved to rust_language::print_typedef.
3637 (rust_language): Delete la_print_typedef initializer.
3638 (rust_language::print_typedef): New member function,
3639 implementation from rust_print_typedef.
3640 * typeprint.c (default_print_typedef): Delete.
3641
3642 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3643
3644 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
3645 (ada_language::printstr): New member function.
3646 * c-lang.c (c_language_data): Delete la_printstr initializer.
3647 (cplus_language_data): Likewise.
3648 (asm_language_data): Likewise.
3649 (minimal_language_data): Likewise.
3650 * d-lang.c (d_language_data): Likewise.
3651 * f-lang.c (f_printstr): Rename to f_language::printstr.
3652 (f_language_data): Delete la_printstr initializer.
3653 (f_language::printstr): New member function, implementation from
3654 f_printstr.
3655 * go-lang.c (go_language_data): Delete la_printstr initializer.
3656 * language.c (language_defn::printstr): Define new member
3657 function.
3658 (unk_lang_printstr): Delete.
3659 (unknown_language_data): Delete la_printstr initializer.
3660 (unknown_language::printstr): New member function.
3661 (auto_language_data): Delete la_printstr initializer.
3662 (auto_language::printstr): New member function.
3663 * language.h (language_data): Delete la_printstr field.
3664 (language_defn::printstr): Declare new member function.
3665 (LA_PRINT_STRING): Update call to printstr.
3666 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
3667 (m2_language_data): Delete la_printstr initializer.
3668 (m2_language::printstr): New member function, implementation from
3669 m2_printstr.
3670 * objc-lang.c (objc_language_data): Delete la_printstr
3671 initializer.
3672 * opencl-lang.c (opencl_language_data): Likewise.
3673 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
3674 (pascal_language_data): Delete la_printstr initializer.
3675 (pascal_language::printstr): New member function, implementation
3676 from pascal_printstr.
3677 * p-lang.h (pascal_printstr): Delete declaration.
3678 * rust-lang.c (rust_printstr): Update header comment.
3679 (rust_language_data): Delete la_printstr initializer.
3680 (rust_language::printstr): New member function.
3681
3682 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3683
3684 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
3685 (ada_language::printchar): New member function.
3686 * c-lang.c (c_language_data): Delete la_printchar initializer.
3687 (cplus_language_data): Likewise.
3688 (asm_language_data): Likewise.
3689 (minimal_language_data): Likewise.
3690 * d-lang.c (d_language_data): Likewise.
3691 * f-lang.c (f_printchar): Rename to f_language::printchar.
3692 (f_language_data): Delete la_printchar initializer.
3693 (f_language::printchar): New member function, implementation from
3694 f_printchar.
3695 * go-lang.c (go_language_data): Delete la_printchar initializer.
3696 * language.c (unk_lang_printchar): Delete.
3697 (language_defn::printchar): Define new member function.
3698 (unknown_language_data): Delete la_printchar initializer.
3699 (unknown_language::printchar): New member function.
3700 (auto_language_data): Delete la_printchar initializer.
3701 (auto_language::printchar): New member function.
3702 * language.h (language_data): Delete la_printchar field.
3703 (language_defn::printchar): Declare new member function.
3704 (LA_PRINT_CHAR): Update call to printchar.
3705 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
3706 (m2_language::printchar): New member function.
3707 * objc-lang.c (objc_language_data): Delete la_printchar
3708 initializer.
3709 * opencl-lang.c (opencl_language_data): Likewise.
3710 * p-lang.c (pascal_language_data): Delete la_printchar
3711 initializer.
3712 (pascal_language::printchar): New member function.
3713 * rust-lang.c (rust_printchar): Rename to
3714 rust_language::printchar.
3715 (rust_language_data): Delete la_printchar initializer.
3716 (rust_language::printchar): New member function, implementation
3717 from rust_printchar.
3718
3719 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3720
3721 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
3722 (ada_language_data): Delete la_emitchar initializer.
3723 (ada_language::emitchar): New member function, implementation from
3724 emit_char.
3725 * c-lang.c (c_language_data): Delete la_emitchar initializer.
3726 (cplus_language_data): Likewise.
3727 (asm_language_data): Likewise.
3728 (minimal_language_data): Likewise.
3729 * d-lang.c (d_language_data): Likewise.
3730 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
3731 (f_language_data): Delete la_emitchar initializer.
3732 (f_language::emitchar): New member function, implementation from
3733 f_emit_char.
3734 * go-lang.c (go_language_data): Delete la_emitchar initializer.
3735 * language.c (unk_lang_emit_char): Delete.
3736 (language_defn::emitchar): New member function definition.
3737 (unknown_language_data): Delete la_emitchar initializer.
3738 (unknown_language::emitchar): New member function.
3739 (auto_language_data): Delete la_emitchar initializer.
3740 (auto_language::emitchar): New member function.
3741 * language.h (language_data): Delete la_emitchar field.
3742 (language_defn::emitchar): New member field declaration.
3743 (LA_EMIT_CHAR): Update call to emitchar.
3744 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
3745 (m2_language_data): Delete la_emitchar initializer.
3746 (m2_language::emitchar): New member function, implementation from
3747 m2_emit_char.
3748 * objc-lang.c (objc_language_data): Delete la_emitchar
3749 initializer.
3750 * opencl-lang.c (opencl_language_data): Likewise.
3751 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
3752 (pascal_language_data): Delete la_emitchar initializer.
3753 (pascal_language::emitchar): New member function, implementation
3754 from pascal_emit_char.
3755 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
3756 (rust_language_data): Delete la_emitchar initializer.
3757 (rust_language::emitchar): New member function, implementation
3758 from rust_emitchar.
3759
3760 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3761
3762 * ada-lang.c (resolve): Rename to ada_language::post_parser.
3763 (ada_language_data): Delete la_post_parser initializer.
3764 (ada_language::post_parser): New member function.
3765 * c-lang.c (c_language_data): Delete la_post_parser initializer.
3766 (cplus_language_data): Likewise.
3767 (asm_language_data): Likewise.
3768 (minimal_language_data): Likewise.
3769 * d-lang.c (d_language_data): Likewise.
3770 * f-lang.c (f_language_data): Likewise.
3771 * go-lang.c (go_language_data): Likewise.
3772 * language.c (unknown_language_data): Likewise.
3773 (auto_language_data): Likewise.
3774 * language.h (language_data): Delete la_post_parser field.
3775 (language_defn::post_parser): New member function.
3776 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
3777 * objc-lang.c (objc_language_data): Likewise.
3778 * opencl-lang.c (opencl_language_data): Likewise.
3779 * p-lang.c (pascal_language_data): Likewise.
3780 * parse.c (parse_exp_in_context): Update call to post_parser.
3781 (null_post_parser): Delete definition.
3782 * parser-defs.h (null_post_parser): Delete declaration.
3783 * rust-lang.c (rust_language_data): Delete la_post_parser
3784 initializer.
3785
3786 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3787
3788 * ada-lang.c (parse): Rename to ada_language::parser.
3789 (ada_language_data): Delete la_parser initializer.
3790 (ada_language::parser): New member function, implementation from
3791 parse.
3792 * c-lang.c (c_language_data): Delete la_parser initializer.
3793 (cplus_language_data): Likewise.
3794 (asm_language_data): Likewise.
3795 (minimal_language_data): Likewise.
3796 * d-lang.c (d_language_data): Likewise.
3797 (d_language::parser): New member function.
3798 * f-lang.c (f_language_data): Delete la_parser initializer.
3799 (f_language::parser): New member function.
3800 * go-lang.c (go_language_data): Delete la_parser initializer.
3801 (go_language::parser): New member function.
3802 * language.c (unk_lang_parser): Delete.
3803 (language_defn::parser): Define new member function.
3804 (unknown_language_data): Delete la_parser initializer.
3805 (unknown_language::parser): New member function.
3806 (auto_language_data): Delete la_parser initializer.
3807 (auto_language::parser): New member function.
3808 * language.h (language_data): Delete la_parser field.
3809 (language_defn::parser): Declare new member function.
3810 * m2-lang.c (m2_language_data): Delete la_parser initializer.
3811 (m2_language::parser): New member function.
3812 * objc-lang.c (objc_language_data): Delete la_parser initializer.
3813 * opencl-lang.c (opencl_language_data): Likewise.
3814 * p-lang.c (pascal_language_data): Likewise.
3815 (pascal_language::parser): New member function.
3816 * parse.c (parse_exp_in_context): Update call to parser.
3817 * rust-lang.c (rust_language_data): Delete la_parser initializer.
3818 (rust_language::parser): New member function.
3819
3820 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
3821
3822 * top.c (print_gdb_configuration): Print --with-python-libdir
3823 configuration value.
3824
3825 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3826
3827 * NEWS: Mention change to the alias command.
3828
3829 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3830
3831 * cli/cli-cmds.c (lookup_cmd_for_default_args)
3832 (alias_command_completer)
3833 (make_alias_options_def_group): New functions.
3834 (alias_opts, alias_option_defs): New struct and array.
3835 (alias_usage_error): Update usage.
3836 (alias_command): Handles optional DEFAULT-ARGS... arguments.
3837 Use option framework.
3838 (_initialize_cli_cmds): Update alias command help.
3839 Update aliases command help.
3840 (show_user):
3841 Add NULL for new default_args lookup_cmd argument.
3842 (valid_command_p): Rename to validate_aliased_command.
3843 Add NULL for new default_args lookup_cmd argument. Verify that the
3844 aliased_command has no default args.
3845 * cli/cli-decode.c (help_cmd): Show aliases definitions.
3846 (lookup_cmd_1, lookup_cmd): New argument default_args.
3847 (add_alias_cmd):
3848 Add NULL for new default_args lookup_cmd argument.
3849 (print_help_for_command): Show default args under the layout
3850 alias some_alias = some_aliased_cmd some_alias_default_arg.
3851 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
3852 xfree default_args in destructor.
3853 * cli/cli-script.c (process_next_line, do_define_command):
3854 Add NULL for new default_args lookup_cmd argument.
3855 * command.h: Declare new default_args argument in lookup_cmd
3856 and lookup_cmd_1.
3857 * completer.c (complete_line_internal_1):
3858 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
3859 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
3860 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
3861 Likewise.
3862 * infcmd.c (_initialize_infcmd): Likewise.
3863 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
3864 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
3865 * python/py-param.c (add_setshow_generic): Likewise.
3866 * remote.c (_initialize_remote): Likewise.
3867 * top.c (execute_command): Prepend default_args if command has some.
3868 (set_verbose):
3869 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
3870 * tracepoint.c (validate_actionline, encode_actions_1):
3871 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
3872
3873 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3874
3875 * jit.c (jit_read_descriptor): Use bool as the return type.
3876 (jit_breakpoint_re_set_internal): Use bool as the return type.
3877 Invert the return value logic; return true if the jit breakpoint
3878 has been successfully initialized.
3879 (jit_inferior_init): Update the call to
3880 jit_breakpoint_re_set_internal.
3881
3882 2020-06-22 Pedro Alves <palves@redhat.com>
3883
3884 PR gdb/25939
3885 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
3886 Use the current inferior instead. Don't return
3887 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
3888 wait again.
3889 * sol-thread.c (sol_thread_target::wait): Don't reference
3890 inferior_ptid.
3891 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
3892 (sol_update_thread_list_callback): Use the current inferior's pid
3893 instead of inferior_ptid.
3894
3895 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3896
3897 * procfs.c: Cleanup many comments.
3898
3899 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
3900 (AFTER_WATCHFLAG): Replace by value.
3901
3902 (MAIN_PROC_NAME_FORMAT): Inline ...
3903 (create_procinfo): ... here.
3904
3905 (procfs_debug_inferior): Remove SYS_exec handling.
3906 (syscall_is_exec): Likewise.
3907 (procfs_set_exec_trap): Likewise.
3908
3909 (syscall_is_lwp_exit): Inline in callers.
3910 (syscall_is_exit): Likewise.
3911 (syscall_is_exec): Likewise.
3912 (syscall_is_lwp_create): Likewise.
3913
3914 (invalidate_cache): Remove #if 0 code.
3915
3916 (make_signal_thread_runnable): Remove.
3917 (procfs_target::resume): Remove #if 0 code.
3918
3919 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3920
3921 PR gdb/25939
3922 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
3923 call ...
3924 (procfs_target::create_inferior): ... here.
3925
3926 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3927
3928 * exec.c (validate_exec_file): Ensure the build-id is up to
3929 date by calling reopen_exec_file (that checks file timestamp
3930 to decide to re-read the file).
3931
3932 2020-06-18 Pedro Alves <palves@redhat.com>
3933
3934 PR gdb/25412
3935 * gdbthread.h (delete_thread, delete_thread_silent)
3936 (find_thread_ptid): Update comments.
3937 * thread.c (current_thread_): New global.
3938 (is_current_thread): Move higher, and reimplement.
3939 (inferior_thread): Reimplement.
3940 (set_thread_exited): Use bool. Add assertions.
3941 (add_thread_silent): Simplify thread-reuse handling by always
3942 calling delete_thread.
3943 (delete_thread): Remove intro comment.
3944 (find_thread_ptid): Skip exited threads.
3945 (switch_to_thread_no_regs): Write to current_thread_.
3946 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
3947 INFERIOR_PTID. Clear current_thread_.
3948
3949 2020-06-18 Pedro Alves <palves@redhat.com>
3950
3951 * aix-thread.c (pd_update): Use switch_to_thread.
3952
3953 2020-06-18 Pedro Alves <palves@redhat.com>
3954
3955 * ravenscar-thread.c (ravenscar_thread_target): Update.
3956 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
3957 (ravenscar_thread_target::add_active_thread): ... this. Don't
3958 set m_base_ptid here. Update to avoid referencing inferior_ptid.
3959 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
3960
3961 2020-06-18 Pedro Alves <palves@redhat.com>
3962
3963 * nat/windows-nat.c (current_windows_thread): Remove.
3964 * nat/windows-nat.h (current_windows_thread): Remove.
3965 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
3966 Adjust.
3967 (display_selectors): Adjust to fetch the current
3968 windows_thread_info based on inferior_ptid.
3969 (fake_create_process): No longer write to current_windows_thread.
3970 (windows_nat_target::get_windows_debug_event):
3971 Don't set inferior_ptid or current_windows_thread.
3972 (windows_nat_target::wait): Adjust to not rely on
3973 current_windows_thread.
3974 (do_initial_windows_stuff): Now a method of windows_nat_target.
3975 Switch to the last_ptid thread.
3976 (windows_nat_target::attach): Adjust.
3977 (windows_nat_target::detach): Use switch_to_no_thread instead of
3978 writing to inferior_ptid directly.
3979 (windows_nat_target::create_inferior): Adjust.
3980
3981 2020-06-18 Pedro Alves <palves@redhat.com>
3982
3983 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
3984
3985 2020-06-18 Pedro Alves <palves@redhat.com>
3986
3987 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
3988 after creating it, instead of writing to inferior_ptid. Don't
3989 write to inferior_ptid.
3990
3991 2020-06-18 Pedro Alves <palves@redhat.com>
3992
3993 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
3994
3995 2020-06-18 Pedro Alves <palves@redhat.com>
3996
3997 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
3998 it, instead of writing to inferior_ptid.
3999
4000 2020-06-18 Pedro Alves <palves@redhat.com>
4001
4002 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
4003 to inferior_ptid.
4004
4005 2020-06-18 Pedro Alves <palves@redhat.com>
4006
4007 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
4008 instead of writing to inferior_ptid directly.
4009
4010 2020-06-18 Pedro Alves <palves@redhat.com>
4011
4012 * corelow.c (core_target::close): Use switch_to_no_thread instead
4013 of writing to inferior_ptid directly.
4014 (add_to_thread_list, core_target_open): Use switch_to_thread
4015 instead of writing to inferior_ptid directly.
4016
4017 2020-06-18 Pedro Alves <palves@redhat.com>
4018
4019 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
4020 inferior_ptid.
4021 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
4022 inferior_ptid.
4023 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
4024 inferior_ptid directly.
4025 (darwin_nat_target::init_thread_list): Switch to thread, instead
4026 of writing to inferior_ptid.
4027 (darwin_nat_target::attach): Don't write to inferior_ptid.
4028 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
4029
4030 2020-06-18 Pedro Alves <palves@redhat.com>
4031
4032 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
4033 thread.
4034 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
4035 Instead use switch_to_thread.
4036 (gnu_nat_target::detach): Use switch_to_no_thread
4037 instead of writing to inferior_ptid directly. Used passed-in
4038 inferior instead of looking up the inferior by pid.
4039
4040 2020-06-18 Pedro Alves <palves@redhat.com>
4041
4042 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
4043 inferior_ptid.
4044
4045 2020-06-18 Pedro Alves <palves@redhat.com>
4046
4047 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
4048 inferior_ptid.
4049 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
4050 thread.
4051 (nto_procfs_target::detach): Avoid referencing
4052 inferior_ptid. Use switch_to_no_thread instead of writing to
4053 inferior_ptid directly.
4054 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
4055 instead of writing to inferior_ptid directly.
4056 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
4057 to thread.
4058
4059 2020-06-18 Pedro Alves <palves@redhat.com>
4060
4061 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
4062 after creating it, instead of writing to inferior_ptid.
4063 (gdbsim_target_open): Use switch_to_no_thread instead of writing
4064 to inferior_ptid directly.
4065 (gdbsim_target::wait): Don't write to inferior_ptid.
4066
4067 2020-06-18 Pedro Alves <palves@redhat.com>
4068
4069 * remote.c (remote_target::remote_notice_new_inferior): Use
4070 switch_to_thread instead of writing to inferior_ptid directly.
4071 (remote_target::add_current_inferior_and_thread): Use
4072 switch_to_no_thread instead of writing to inferior_ptid directly.
4073 (extended_remote_target::attach): Use switch_to_inferior_no_thread
4074 and switch_to_thread instead of using set_current_inferior or
4075 writing to inferior_ptid directly.
4076
4077 2020-06-18 Pedro Alves <palves@redhat.com>
4078
4079 * tracectf.c (ctf_target_open): Switch to added thread instead of
4080 writing to inferior_ptid directly.
4081 (ctf_target::close): Use switch_to_no_thread instead of writing to
4082 inferior_ptid directly.
4083
4084 2020-06-18 Pedro Alves <palves@redhat.com>
4085
4086 * tracefile-tfile.c (tfile_target_open): Don't write to
4087 inferior_ptid directly, instead switch to added thread.
4088 (tfile_target::close): Use switch_to_no_thread instead of writing
4089 to inferior_ptid directly.
4090
4091 2020-06-18 Pedro Alves <palves@redhat.com>
4092
4093 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
4094 (procfs_target::detach): Use switch_to_no_thread
4095 instead of writing to inferior_ptid directly.
4096 (do_attach): Change return type to void. Switch to the added
4097 thread.
4098 (procfs_target::create_inferior): Switch to the added thread.
4099 (procfs_do_thread_registers): Don't write to inferior_ptid.
4100
4101 2020-06-18 Pedro Alves <palves@redhat.com>
4102
4103 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
4104 of writing to inferior_ptid.
4105 (scoped_restore_exited_inferior): Delete.
4106 (handle_vfork_child_exec_or_exit): Simplify using
4107 scoped_restore_current_pspace_and_thread. Use switch_to_thread
4108 instead of writing to inferior_ptid.
4109 (THREAD_STOPPED_BY): Delete.
4110 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
4111 (thread_stopped_by_hw_breakpoint): Delete.
4112 (save_waitstatus): Use
4113 scoped_restore_current_thread+switch_to_thread, and call
4114 target_stopped_by_watchpoint instead of
4115 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
4116 instead of thread_stopped_by_sw_breakpoint, and
4117 target_stopped_by_hw_breakpoint instead of
4118 thread_stopped_by_hw_breakpoint.
4119 (handle_inferior_event)
4120 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
4121 inferior_ptid directly, nor
4122 set_current_inferior/set_current_program_space. Use
4123 switch_to_thread / switch_to_inferior_no_thread instead.
4124
4125 2020-06-18 Pedro Alves <palves@redhat.com>
4126
4127 * target.c (generic_mourn_inferior): Use switch_to_no_thread
4128 instead of writing to inferior_ptid.
4129
4130 2020-06-18 Pedro Alves <palves@redhat.com>
4131
4132 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
4133 added thread.
4134 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
4135 to the added thread.
4136 (inf_ptrace_target::detach_success): Use switch_to_no_thread
4137 instead of writing to inferior_ptid.
4138
4139 2020-06-18 Pedro Alves <palves@redhat.com>
4140
4141 * gdbarch-selftests.c: Include "progspace-and-thread.h".
4142 (register_to_value_test): Mock a program_space too. Heap-allocate
4143 the address space. Don't write to inferior_ptid. Use
4144 switch_to_thread instead.
4145
4146 2020-06-18 Pedro Alves <palves@redhat.com>
4147
4148 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
4149 Delete.
4150 (find_signalled_thread()): New, factored out from
4151 linux_make_corefile_notes and adjusted to handle exited threads.
4152 (linux_make_corefile_notes): Adjust to use the new
4153 find_signalled_thread.
4154
4155 2020-06-18 Pedro Alves <palves@redhat.com>
4156
4157 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
4158 of saving/restoring inferior_ptid.
4159
4160 2020-06-17 Tom Tromey <tom@tromey.com>
4161
4162 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
4163 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
4164 declare.
4165 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
4166
4167 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
4168
4169 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
4170 of partial symtabs.
4171
4172 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
4173
4174 * regformats/reg-arm.dat: Remove.
4175 * regformats/reg-bfin.dat: Remove.
4176 * regformats/reg-cris.dat: Remove.
4177 * regformats/reg-crisv32.dat: Remove.
4178 * regformats/reg-m32r.dat: Remove.
4179 * regformats/reg-tilegx.dat: Remove.
4180 * regformats/reg-tilegx32.dat: Remove.
4181
4182 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
4183
4184 * features/Makefile (WHICH): Remove arm files.
4185 * regformats/arm/arm-with-iwmmxt.dat: Remove.
4186 * regformats/arm/arm-with-neon.dat: Remove.
4187 * regformats/arm/arm-with-vfpv2.dat: Remove.
4188 * regformats/arm/arm-with-vfpv3.dat: Remove.
4189
4190 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
4191
4192 * features/Makefile (XMLTOC): Remove rx.xml.
4193
4194 2020-06-17 Pedro Alves <palves@redhat.com>
4195
4196 * gdbthread.h (thread_control_state) <trap_expected> Update
4197 comments.
4198
4199 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4200
4201 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
4202 ada_language::lookup_symbol_nonlocal.
4203 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
4204 (ada_language::lookup_symbol_nonlocal): New member function,
4205 implementation from ada_lookup_symbol_nonlocal.
4206 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
4207 initializer.
4208 (cplus_language_data): Delete la_lookup_symbol_nonlocal
4209 initializer.
4210 (cplus_language::lookup_symbol_nonlocal): New member function.
4211 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
4212 (minimal_language_data) Likewise.
4213 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
4214 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
4215 initializer.
4216 (d_language::lookup_symbol_nonlocal): New member function.
4217 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
4218 initializer.
4219 (f_language::lookup_symbol_nonlocal): New member function.
4220 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
4221 initializer.
4222 * language.c (unknown_language_data): Likewise.
4223 (auto_language_data): Likewise.
4224 * language.h (language_data): Delete la_lookup_symbol_nonlocal
4225 field.
4226 (language_defn::lookup_symbol_nonlocal): New member function.
4227 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
4228 initializer.
4229 * objc-lang.c (objc_language_data): Likewise.
4230 * opencl-lang.c (opencl_language_data): Likewise.
4231 * p-lang.c (pascal_language_data): Likewise.
4232 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
4233 rust_language::lookup_symbol_nonlocal.
4234 (rust_language_data): Delete la_lookup_symbol_nonlocal
4235 initializer.
4236 (rust_language::lookup_symbol_nonlocal): New member function,
4237 implementation from rust_lookup_symbol_nonlocal.
4238 * symtab.c (lookup_symbol_aux): Update call to
4239 lookup_symbol_nonlocal.
4240 (basic_lookup_symbol_nonlocal): Rename to...
4241 (language_defn::lookup_symbol_nonlocal): ...this, and update
4242 header comment. Remove language_defn parameter, and replace with
4243 uses of `this'.
4244 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
4245
4246 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4247
4248 * ada-lang.c (ada_language_data): Delete la_value_print_inner
4249 initializer.
4250 (ada_language::value_print_inner): New member function.
4251 * c-lang.c (c_language_data): Delete la_value_print_inner
4252 initializer.
4253 (cplus_language_data): Likewise.
4254 (asm_language_data): Likewise.
4255 (minimal_language_data): Likewise.
4256 * d-lang.c (d_language_data): Likewise.
4257 (d_language::value_print_inner): New member function.
4258 * f-lang.c (f_language_data): Delete la_value_print_inner
4259 initializer.
4260 (f_language::value_print_inner): New member function.
4261 * f-lang.h (f_value_print_innner): Rename to...
4262 (f_value_print_inner): ...this (note spelling of 'inner').
4263 * f-valprint.c (f_value_print_innner): Rename to...
4264 (f_value_print_inner): ...this (note spelling of 'inner').
4265 * go-lang.c (go_language_data): Delete la_value_print_inner
4266 initializer.
4267 (go_language::value_print_inner): New member function.
4268 * language.c (language_defn::value_print_inner): Define new member
4269 function.
4270 (unk_lang_value_print_inner): Delete.
4271 (unknown_language_data): Delete la_value_print_inner initializer.
4272 (unknown_language::value_print_inner): New member function.
4273 (auto_language_data): Delete la_value_print_inner initializer.
4274 (auto_language::value_print_inner): New member function.
4275 * language.h (language_data): Delete la_value_print_inner field.
4276 (language_defn::value_print_inner): Delcare new member function.
4277 * m2-lang.c (m2_language_data): Delete la_value_print_inner
4278 initializer.
4279 (m2_language::value_print_inner): New member function.
4280 * objc-lang.c (objc_language_data): Delete la_value_print_inner
4281 initializer.
4282 * opencl-lang.c (opencl_language_data): Likewise.
4283 * p-lang.c (pascal_language_data): Likewise.
4284 (pascal_language::value_print_inner): New member function.
4285 * rust-lang.c (rust_language_data): Delete la_value_print_inner
4286 initializer.
4287 (rust_language::value_print_inner): New member function.
4288 * valprint.c (do_val_print): Update call to value_print_inner.
4289
4290 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4291
4292 * ada-lang.c (ada_language_data): Delete la_value_print
4293 initializer.
4294 (ada_language::value_print): New member function.
4295 * c-lang.c (c_language_data): Delete la_value_print initializer.
4296 (cplus_language_data): Likewise.
4297 (asm_language_data): Likewise.
4298 (minimal_language_data): Likewise.
4299 * d-lang.c (d_language_data): Likewise.
4300 * f-lang.c (f_language_data): Likewise.
4301 * go-lang.c (go_language_data): Likewise.
4302 * language.c (unk_lang_value_print): Delete.
4303 (language_defn::value_print): Define new member function.
4304 (unknown_language_data): Delete la_value_print initializer.
4305 (unknown_language::value_print): New member function.
4306 (auto_language_data): Delete la_value_print initializer.
4307 (auto_language::value_print): New member function.
4308 * language.h (language_data): Delete la_value_print field.
4309 (language_defn::value_print): Declare new member function.
4310 (LA_VALUE_PRINT): Update call to value_print.
4311 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
4312 * objc-lang.c (objc_language_data): Likewise.
4313 * opencl-lang.c (opencl_language_data): Likewise.
4314 * p-lang.c (pascal_language_data): Likewise.
4315 (pascal_language::value_print): New member function.
4316 * rust-lang.c (rust_language_data): Delete la_value_print
4317 initializer.
4318
4319 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4320
4321 * ada-lang.c (ada_watch_location_expression): Rename to
4322 ada_language::watch_location_expression.
4323 (ada_language_data): Delete la_watch_location_expression
4324 initializer.
4325 (ada_language::watch_location_expression): New member function,
4326 implementation from ada_watch_location_expression.
4327 * breakpoint.c (watch_command_1): Update call to
4328 watch_location_expression.
4329 * c-lang.c (c_watch_location_expression): Rename to
4330 language_defn::watch_location_expression.
4331 (c_language_data): Delete la_watch_location_expression
4332 initializer.
4333 (cplus_language_data): Likewise.
4334 (asm_language_data): Likewise.
4335 (minimal_language_data): Likewise.
4336 * c-lang.h (c_watch_location_expression): Delete declaration.
4337 * d-lang.c (d_language_data): Delete la_watch_location_expression
4338 initializer.
4339 * f-lang.c (f_language_data): Likewise.
4340 * go-lang.c (go_language_data): Likewise.
4341 * language.c (language_defn::watch_location_expression): Member
4342 function implementation from c_watch_location_expression.
4343 (unknown_language_data): Delete la_watch_location_expression
4344 initializer.
4345 (auto_language_data): Likewise.
4346 * language.h (language_data): Delete la_watch_location_expression
4347 field.
4348 (language_defn::watch_location_expression): Declare new member
4349 function.
4350 * m2-lang.c (m2_language_data): Delete
4351 la_watch_location_expression initializer.
4352 * objc-lang.c (objc_language_data): Likewise.
4353 * opencl-lang.c (opencl_language_data): Likewise.
4354 * p-lang.c (pascal_language_data): Likewise.
4355 * rust-lang.c (rust_watch_location_expression): Rename to
4356 rust_language::watch_location_expression.
4357 (rust_language_data): Delete la_watch_location_expression
4358 initializer.
4359 (rust_language::watch_location_expression): New member function,
4360 implementation from rust_watch_location_expression.
4361
4362 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4363
4364 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
4365 ada_language::collect_symbol_completion_matches.
4366 (ada_language_data): Delete la_collect_symbol_completion_matches
4367 initializer.
4368 (ada_language::collect_symbol_completion_matches): New member
4369 function, implementation from
4370 ada_collect_symbol_completion_matches.
4371 * c-lang.c (c_language_data): Delete
4372 la_collect_symbol_completion_matches initializer.
4373 (cplus_language_data): Likewise.
4374 (asm_language_data): Likewise.
4375 (minimal_language_data): Likewise.
4376 * d-lang.c (d_language_data): Likewise.
4377 * f-lang.c (f_collect_symbol_completion_matches): Rename to
4378 f_language::collect_symbol_completion_matches.
4379 (f_language_data): Delete la_collect_symbol_completion_matches
4380 initializer.
4381 (f_language::collect_symbol_completion_matches) New member
4382 function, implementation from f_collect_symbol_completion_matches.
4383 * go-lang.c (go_language_data): Delete
4384 la_collect_symbol_completion_matches initializer.
4385 * language.c (unknown_language_data): Likewise.
4386 (auto_language_data): Likewise.
4387 * language.h (language_data): Delete
4388 la_collect_symbol_completion_matches field.
4389 (language_defn::collect_symbol_completion_matches): New member
4390 function.
4391 * m2-lang.c (m2_language_data): Delete
4392 la_collect_symbol_completion_matches initializer.
4393 * objc-lang.c (objc_language_data): Likewise.
4394 * opencl-lang.c (opencl_language_data): Likewise.
4395 * p-lang.c (pascal_language_data): Likewise.
4396 * rust-lang.c (rust_language_data): Likewise.
4397 * symtab.c (default_collect_symbol_completion_matches): Delete.
4398 (collect_symbol_completion_matches): Update call to
4399 collect_symbol_completion_matches.
4400 (collect_symbol_completion_matches_type): Likewise.
4401 * symtab.h (default_collect_symbol_completion_matches): Delete
4402 declaration.
4403
4404 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4405
4406 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
4407 (ada_language_data): Delete la_word_break_characters initializer.
4408 (ada_language::word_break_characters): New member function.
4409 * c-lang.c (c_language_data): Delete la_word_break_characters
4410 initializer.
4411 (cplus_language_data): Likewise.
4412 (asm_language_data): Likewise.
4413 (minimal_language_data): Likewise.
4414 * completer.c: Update global comment.
4415 (advance_to_expression_complete_word_point): Update call to
4416 word_break_characters.
4417 (complete_files_symbols): Likewise.
4418 (complete_line_internal_1): Likewise.
4419 (default_completer_handle_brkchars): Likewise.
4420 (skip_quoted_chars): Likewise.
4421 * d-lang.c (d_language_data): Delete la_word_break_characters
4422 initializer.
4423 * f-lang.c (f_word_break_characters): Delete.
4424 (f_language_data): Delete la_word_break_characters initializer.
4425 (f_language::word_break_characters): New member function.
4426 * go-lang.c (go_language_data): Delete la_word_break_characters
4427 initializer.
4428 * language.c (unknown_language_data): Likewise.
4429 (auto_language_data): Likewise.
4430 * language.h (default_word_break_characters): Move declaration to
4431 earlier in the file.
4432 (language_data): Delete la_word_break_characters field.
4433 (language_defn::word_break_characters): New member function.
4434 * m2-lang.c (m2_language_data): Delete la_word_break_characters
4435 initializer.
4436 * objc-lang.c (objc_language_data): Likewise.
4437 * opencl-lang.c (opencl_language_data): Likewise.
4438 * p-lang.c (pascal_language_data): Likewise.
4439 * rust-lang.c (rust_language_data): Likewise.
4440
4441 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4442
4443 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
4444 (ada_language_data): Delete la_get_symbol_name_matcher
4445 initializer.
4446 (language_defn::get_symbol_name_matcher_inner): New member
4447 function.
4448 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
4449 initializer.
4450 (cplus_language_data): Likewise.
4451 (cplus_language::get_symbol_name_matcher_inner): New member
4452 function.
4453 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
4454 (minimal_language_data): Likewise.
4455 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
4456 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
4457 initializer.
4458 * dictionary.c (iter_match_first_hashed): Update call to
4459 get_symbol_name_matcher.
4460 (iter_match_next_hashed): Likewise.
4461 (iter_match_next_linear): Likewise.
4462 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
4463 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
4464 initializer.
4465 (f_language::get_symbol_name_matcher_inner): New member function.
4466 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
4467 initializer.
4468 * language.c (default_symbol_name_matcher): Update header comment,
4469 make static.
4470 (language_defn::get_symbol_name_matcher): New definition.
4471 (language_defn::get_symbol_name_matcher_inner): Likewise.
4472 (get_symbol_name_matcher): Delete.
4473 (unknown_language_data): Delete la_get_symbol_name_matcher
4474 initializer.
4475 (auto_language_data): Likewise.
4476 * language.h (language_data): Delete la_get_symbol_name_matcher
4477 field.
4478 (language_defn::get_symbol_name_matcher): New member function.
4479 (language_defn::get_symbol_name_matcher_inner): Likewise.
4480 (default_symbol_name_matcher): Delete declaration.
4481 * linespec.c (find_methods): Update call to
4482 get_symbol_name_matcher.
4483 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
4484 initializer.
4485 * minsyms.c (lookup_minimal_symbol): Update call to
4486 get_symbol_name_matcher.
4487 (iterate_over_minimal_symbols): Likewise.
4488 * objc-lang.c (objc_language_data): Delete
4489 la_get_symbol_name_matcher initializer.
4490 * opencl-lang.c (opencl_language_data): Likewise.
4491 * p-lang.c (pascal_language_data): Likewise.
4492 * psymtab.c (psymbol_name_matches): Update call to
4493 get_symbol_name_matcher.
4494 * rust-lang.c (rust_language_data): Delete
4495 la_get_symbol_name_matcher initializer.
4496 * symtab.c (symbol_matches_search_name): Update call to
4497 get_symbol_name_matcher.
4498 (compare_symbol_name): Likewise.
4499
4500 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4501
4502 * ada-lang.c (ada_language_data): Delete la_compute_program
4503 initializer.
4504 * c-lang.c (c_language_data): Likewise.
4505 (c_language::compute_program): New member function.
4506 (cplus_language_data): Delete la_compute_program initializer.
4507 (cplus_language::compute_program): New member function.
4508 (asm_language_data): Delete la_compute_program initializer.
4509 (minimal_language_data): Likewise.
4510 * c-lang.h (c_compute_program): Update comment.
4511 (cplus_compute_program): Likewise.
4512 * compile/compile-c-support.c (c_compute_program): Likewise.
4513 (cplus_compute_program): Likewise.
4514 * compile/compile.c (compile_to_object): Update call to
4515 la_compute_program.
4516 * d-lang.c (d_language_data): Delete la_compute_program
4517 initializer.
4518 * f-lang.c (f_language_data): Likewise.
4519 * go-lang.c (go_language_data): Likewise.
4520 * language.c (unknown_language_data): Likewise.
4521 (auto_language_data): Likewise.
4522 * language.h (language_data): Delete la_compute_program field.
4523 (language_defn::compute_program): New member function.
4524 * m2-lang.c (m2_language_data): Delete la_compute_program
4525 initializer.
4526 * objc-lang.c (objc_language_data): Likewise.
4527 * opencl-lang.c (opencl_language_data): Likewise.
4528 * p-lang.c (pascal_language_data): Likewise.
4529 * rust-lang.c (rust_language_data): Likewise.
4530
4531 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
4532
4533 * ada-lang.c (ada_language_data) Delete
4534 la_class_name_from_physname initializer.
4535 * c-lang.c (c_language_data): Likewise.
4536 (cplus_language_data): Likewise.
4537 (cplus_language::class_name_from_physname): New member function.
4538 (asm_language_data): Delete la_class_name_from_physname
4539 initializer.
4540 (minimal_language_data): Likewise.
4541 * d-lang.c (d_language_data): Likewise.
4542 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
4543 method on language_defn class.
4544 (guess_full_die_structure_name): Likewise.
4545 * f-lang.c (f_language_data): Delete la_class_name_from_physname
4546 initializer.
4547 * go-lang.c (go_language_data): Likewise.
4548 * language.c (language_class_name_from_physname): Delete.
4549 (unk_lang_class_name): Delete.
4550 (unknown_language_data): Delete la_class_name_from_physname
4551 initializer.
4552 (auto_language_data): Likewise.
4553 * language.h (language_data): Delete la_class_name_from_physname
4554 field.
4555 (language_defn::class_name_from_physname): New function.
4556 (language_class_name_from_physname): Delete declaration.
4557 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
4558 initializer.
4559 * objc-lang.c (objc_language_data): Likewise.
4560 * opencl-lang.c (opencl_language_data): Likewise.
4561 * p-lang.c (pascal_language_data): Likewise.
4562 * rust-lang.c (rust_language_data): Likewise.
4563
4564 2020-06-16 Tom Tromey <tom@tromey.com>
4565
4566 * tui/tui-data.h (STATUS_NAME): New macro.
4567 * tui/tui-layout.c (tui_remove_some_windows)
4568 (initialize_known_windows, tui_register_window)
4569 (tui_layout_split::remove_windows, initialize_layouts)
4570 (tui_new_layout_command): Don't use hard-coded window names.
4571
4572 2020-06-16 Tom Tromey <tom@tromey.com>
4573
4574 PR tui/25348:
4575 * tui/tui.c (tui_ensure_readline_initialized): Rename from
4576 tui_initialize_readline. Only run once. Call rl_initialize.
4577 * tui/tui.h (tui_ensure_readline_initialized): Rename from
4578 tui_initialize_readline.
4579 * tui/tui-io.c (tui_setup_io): Call
4580 tui_ensure_readline_initialized.
4581 * tui/tui-interp.c (tui_interp::init): Update.
4582
4583 2020-06-16 Tom Tromey <tom@tromey.com>
4584
4585 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
4586 Also preserve the status window.
4587
4588 2020-06-16 Tom Tromey <tom@tromey.com>
4589
4590 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
4591 where m_window==nullptr.
4592
4593 2020-06-15 Tom Tromey <tromey@adacore.com>
4594
4595 * windows-nat.c (windows_nat::handle_output_debug_string):
4596 Update.
4597 (windows_nat::handle_ms_vc_exception): Update.
4598 * target.h (target_read_string): Change API.
4599 * target.c (target_read_string): Change API.
4600 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
4601 Update.
4602 * solib-frv.c (frv_current_sos): Update.
4603 * solib-dsbt.c (dsbt_current_sos): Update.
4604 * solib-darwin.c (darwin_current_sos): Update.
4605 * linux-thread-db.c (inferior_has_bug): Update.
4606 * expprint.c (print_subexp_standard): Update.
4607 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
4608 (ada_exception_message_1): Update.
4609
4610 2020-06-15 Tom Tromey <tromey@adacore.com>
4611
4612 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
4613
4614 2020-06-15 Tom Tromey <tromey@adacore.com>
4615
4616 * valprint.c (read_string): Update comment.
4617 * target.c (MIN): Remove.
4618 (target_read_string): Rewrite.
4619
4620 2020-06-15 Tom Tromey <tromey@adacore.com>
4621
4622 * corefile.c (read_memory_string): Remove.
4623 * ada-valprint.c (ada_value_print_ptr): Update.
4624 * ada-lang.h (ada_tag_name): Change return type.
4625 * ada-lang.c (type_from_tag): Update.
4626 (ada_tag_name_from_tsd): Change return type. Use
4627 target_read_string.
4628 (ada_tag_name): Likewise.
4629 * gdbcore.h (read_memory_string): Don't declare.
4630
4631 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
4632
4633 * symtab.c (rbreak_command): Ignore Windows drive colon.
4634
4635 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
4636
4637 * NEWS: Mention removed GDBserver host support.
4638
4639 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
4640
4641 * features/riscv/rebuild-csr-xml.sh: Updated.
4642
4643 2020-06-11 Tom Tromey <tom@tromey.com>
4644
4645 PR gdb/18318:
4646 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
4647
4648 2020-06-09 Jonny Grant <jg@jguk.org>
4649 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
4650
4651 * main.c (captured_main_1): Don't print new line after help.
4652 (print_gdb_help): add mailing list and IRC channel information
4653 to --help. Add new lines between items in the footer. Remove
4654 quotes around bug url.
4655
4656 2020-06-11 Keith Seitz <keiths@redhat.com>
4657
4658 PR gdb/21356
4659 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
4660 Resolve typedefs for type length calculations.
4661
4662 2020-06-10 Tom de Vries <tdevries@suse.de>
4663
4664 PR ada/24713
4665 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
4666 (write_psymbols): Enable .gdb_index for ada.
4667 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
4668 ada.
4669
4670 2020-06-10 Tom de Vries <tdevries@suse.de>
4671
4672 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
4673 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
4674 namei" instead of "const char *name" argument.
4675 (dw2_map_matching_symbols): Use "offset_type namei" variant of
4676 dw2_symtab_iter_init.
4677
4678 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
4679
4680 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
4681 to use type::field and field::type instead.
4682
4683 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
4684
4685 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
4686 to use field::type instead.
4687
4688 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
4689
4690 * gdbtypes.h (struct field) <type, set_type>: New methods.
4691 Rename `type` field to...
4692 <m_type>: ... this. Change references throughout to use type or
4693 set_type methods.
4694 (FIELD_TYPE): Use field::type. Change call sites that modify
4695 the field's type to use field::set_type instead.
4696
4697 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
4698
4699 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
4700 to use type::index_type instead.
4701
4702 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
4703
4704 * gdbtypes.h (struct type) <index_type, set_index_type>: New
4705 methods.
4706 (TYPE_INDEX_TYPE): Use type::index_type.
4707 * gdbtypes.c (create_array_type_with_stride): Likewise.
4708
4709 2020-06-07 Tom Tromey <tom@tromey.com>
4710
4711 * valprint.c (generic_val_print_float): Remove "embedded_offset"
4712 parameter.
4713 (generic_value_print): Update.
4714
4715 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
4716
4717 Revert commit 982a38f60b0.
4718 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
4719
4720 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
4721
4722 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
4723 avoid use after free.
4724
4725 2020-06-05 Tom de Vries <tdevries@suse.de>
4726
4727 * NEWS: Fix typos.
4728
4729 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
4730
4731 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
4732 the per_bfd object.
4733 (dwarf2_read_debug_names): Likewise.
4734 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
4735 object when re-using a per_bfd object with an index.
4736
4737 2020-06-03 Tom de Vries <tdevries@suse.de>
4738
4739 PR symtab/26046
4740 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
4741 children for C++.
4742 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
4743 DW_TAG_subprogram.
4744
4745 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4746
4747 * ada-lang.c (ada_language_data): Delete skip_trampoline
4748 initializer.
4749 * c-lang.c (c_language_data): Likewise.
4750 (cplus_language_data): Likewise.
4751 (cplus_language::skip_trampoline): New member function.
4752 (asm_language_data): Delete skip_trampoline initializer.
4753 (minimal_language_data): Likewise.
4754 * d-lang.c (d_language_data): Likewise.
4755 * f-lang.c (f_language_data): Likewise.
4756 * go-lang.c (go_language_data): Likewise.
4757 * language.c (unk_lang_trampoline): Delete function.
4758 (skip_language_trampoline): Update.
4759 (unknown_language_data): Delete skip_trampoline initializer.
4760 (auto_language_data): Likewise.
4761 * language.h (language_data): Delete skip_trampoline field.
4762 (language_defn::skip_trampoline): New function.
4763 * m2-lang.c (m2_language_data): Delete skip_trampoline
4764 initializer.
4765 * objc-lang.c (objc_skip_trampoline): Delete function, move
4766 implementation to objc_language::skip_trampoline.
4767 (objc_language_data): Delete skip_trampoline initializer.
4768 (objc_language::skip_trampoline): New member function with
4769 implementation from objc_skip_trampoline.
4770 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
4771 initializer.
4772 * p-lang.c (pascal_language_data): Likewise.
4773 * rust-lang.c (rust_language_data): Likewise.
4774
4775 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4776
4777 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
4778 (ada_language::demangle): New member function.
4779 * c-lang.c (c_language_data): Delete la_demangle initializer.
4780 (cplus_language_data): Delete la_demangle initializer.
4781 (cplus_language::demangle): New member function.
4782 (asm_language_data): Delete la_demangle initializer.
4783 (minimal_language_data): Delete la_demangle initializer.
4784 * d-lang.c (d_language_data): Delete la_demangle initializer.
4785 (d_language::demangle): New member function.
4786 * f-lang.c (f_language_data): Delete la_demangle initializer.
4787 (f_language::demangle): New member function.
4788 * go-lang.c (go_language_data): Delete la_demangle initializer.
4789 (go_language::demangle): New member function.
4790 * language.c (language_demangle): Update.
4791 (unk_lang_demangle): Delete.
4792 (unknown_language_data): Delete la_demangle initializer.
4793 (unknown_language::demangle): New member function.
4794 (auto_language_data): Delete la_demangle initializer.
4795 (auto_language::demangle): New member function.
4796 * language.h (language_data): Delete la_demangle field.
4797 (language_defn::demangle): New function.
4798 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
4799 * objc-lang.c (objc_language_data): Delete la_demangle
4800 initializer.
4801 (objc_language::demangle): New member function.
4802 * opencl-lang.c (opencl_language_data): Delete la_demangle
4803 initializer.
4804 * p-lang.c (pascal_language_data): Likewise.
4805 * rust-lang.c (rust_language_data): Likewise.
4806 (rust_language::demangle): New member function.
4807
4808 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4809
4810 * ada-lang.c (ada_language_data): Delete la_print_type
4811 initializer.
4812 (ada_language::print_type): New member function.
4813 * c-lang.c (c_language_data): Delete la_print_type initializer.
4814 (c_language::print_type): New member function.
4815 (cplus_language_data): Delete la_print_type initializer.
4816 (cplus_language::print_type): New member function.
4817 (asm_language_data): Delete la_print_type initializer.
4818 (asm_language::print_type): New member function.
4819 (minimal_language_data): Delete la_print_type initializer.
4820 (minimal_language::print_type): New member function.
4821 * d-lang.c (d_language_data): Delete la_print_type initializer.
4822 (d_language::print_type): New member function.
4823 * f-lang.c (f_language_data): Delete la_print_type initializer.
4824 (f_language::print_type): New member function.
4825 * go-lang.c (go_language_data): Delete la_print_type initializer.
4826 (go_language::print_type): New member function.
4827 * language.c (unk_lang_print_type): Delete.
4828 (unknown_language_data): Delete la_print_type initializer.
4829 (unknown_language::print_type): New member function.
4830 (auto_language_data): Delete la_print_type initializer.
4831 (auto_language::print_type): New member function.
4832 * language.h (language_data): Delete la_print_type field.
4833 (language_defn::print_type): New function.
4834 (LA_PRINT_TYPE): Update.
4835 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
4836 (m2_language::print_type): New member function.
4837 * objc-lang.c (objc_language_data): Delete la_print_type
4838 initializer.
4839 (objc_language::print_type): New member function.
4840 * opencl-lang.c (opencl_print_type): Delete, implementation moved
4841 to opencl_language::print_type.
4842 (opencl_language_data): Delete la_print_type initializer.
4843 (opencl_language::print_type): New member function, implementation
4844 from opencl_print_type.
4845 * p-lang.c (pascal_language_data): Delete la_print_type
4846 initializer.
4847 (pascal_language::print_type): New member function.
4848 * rust-lang.c (rust_print_type): Delete, implementation moved to
4849 rust_language::print_type.
4850 (rust_language_data): Delete la_print_type initializer.
4851 (rust_language::print_type): New member function, implementation
4852 from rust_print_type.
4853
4854 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4855
4856 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
4857 implementation moves to...
4858 (ada_language::sniff_from_mangled_name): ...here. Update return
4859 type.
4860 (ada_language_data): Delete la_sniff_from_mangled_name
4861 initializer.
4862 * c-lang.c (c_language_data): Likewise.
4863 (cplus_language_data): Likewise.
4864 (cplus_language::sniff_from_mangled_name): New member function,
4865 implementation taken from gdb_sniff_from_mangled_name.
4866 (asm_language_data): Delete la_sniff_from_mangled_name
4867 initializer.
4868 (minimal_language_data): Likewise.
4869 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
4870 implementation moves to cplus_language::sniff_from_mangled_name.
4871 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
4872 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
4873 moves to...
4874 (d_language::sniff_from_mangled_name): ...here.
4875 (d_language_data): Delete la_sniff_from_mangled_name initializer.
4876 * f-lang.c (f_language_data): Likewise.
4877 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
4878 moves to...
4879 (go_language::sniff_from_mangled_name): ...here.
4880 (go_language_data): Delete la_sniff_from_mangled_name initializer.
4881 * language.c (language_sniff_from_mangled_name): Delete.
4882 (unknown_language_data): Delete la_sniff_from_mangled_name
4883 initializer.
4884 (auto_language_data): Likewise.
4885 * language.h (language_data): Delete la_sniff_from_mangled_name
4886 field.
4887 (language_defn::sniff_from_mangled_name): New function.
4888 (language_sniff_from_mangled_name): Delete declaration.
4889 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
4890 field.
4891 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
4892 implementation moves to...
4893 (objc_language::sniff_from_mangled_name): ...here.
4894 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
4895 * opencl-lang.c (opencl_language_data): Likewise.
4896 * p-lang.c (pascal_language_data): Likewise.
4897 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
4898 implementation moves to...
4899 (rust_language::sniff_from_mangled_name): ...here.
4900 (rust_language_data): Delete la_sniff_from_mangled_name
4901 initializer.
4902 * symtab.c (symbol_find_demangled_name): Call
4903 sniff_from_mangled_name member function.
4904
4905 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4906
4907 * ada-lang.c (ada_language_data): Delete la_search_name_hash
4908 initializer.
4909 * c-lang.c (c_language_data): Likewise.
4910 (cplus_language_data): Likewise.
4911 (cplus_language::search_name_hash): New member function.
4912 (asm_language_data): Delete la_search_name_hash initializer.
4913 (minimal_language_data): Likewise.
4914 * d-lang.c (d_language_data): Likewise.
4915 * dictionary.c (default_search_name_hash): Rename to...
4916 (language_defn::search_name_hash): ...this.
4917 * f-lang.c (f_language_data): Likewise.
4918 (f_language::search_name_hash): New member function.
4919 * go-lang.c (go_language_data): Delete la_search_name_hash
4920 initializer.
4921 * language.c (unknown_language_data): Likewise.
4922 (auto_language_data): Likewise.
4923 * language.h (struct language_data): Delete la_search_name_hash
4924 field.
4925 (language_defn::search_name_hash): Declare new member function.
4926 (default_search_name_hash): Delete declaration.
4927 * m2-lang.c (m2_language_data): Delete la_search_name_hash
4928 initializer.
4929 * objc-lang.c (objc_language_data): Likewise.
4930 * opencl-lang.c (opencl_language_data): Likewise.
4931 * p-lang.c (pascal_language_data): Likewise.
4932 * rust-lang.c (rust_language_data): Likewise.
4933 * symtab.c (search_name_hash): Update call.
4934
4935 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4936
4937 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
4938 initializer.
4939 * c-lang.c (class compile_instance): Declare.
4940 (c_language_data): Delete la_get_compile_instance initializer.
4941 (c_language::get_compile_instance): New member function.
4942 (cplus_language_data): Delete la_get_compile_instance initializer.
4943 (cplus_language::get_compile_instance): New member function.
4944 (asm_language_data): Delete la_get_compile_instance initializer.
4945 (minimal_language_data): Likewise.
4946 * c-lang.h (c_get_compile_context): Update comment.
4947 (cplus_get_compile_context): Update comment.
4948 * compile/compile.c (compile_to_object): Update calls, don't rely
4949 on function pointer being NULL.
4950 * d-lang.c (d_language_data): Delete la_get_compile_instance
4951 initializer.
4952 * f-lang.c (f_language_data): Likewise.
4953 * go-lang.c (go_language_data): Likewise.
4954 * language.c (unknown_language_data): Likewise.
4955 (auto_language_data): Likewise.
4956 * language.h (language_data): Delete la_get_compile_instance field.
4957 (language_defn::get_compile_instance): New member function.
4958 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
4959 initializer.
4960 * objc-lang.c (objc_language_data): Likewise.
4961 * opencl-lang.c (opencl_language_data): Likewise.
4962 * p-lang.c (pascal_language_data): Likewise.
4963 * rust-lang.c (rust_language_data): Likewise.
4964
4965 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4966
4967 * ada-lang.c (ada_add_all_symbols): Update comment.
4968 (ada_iterate_over_symbols): Delete, move implementation to...
4969 (ada_language::iterate_over_symbols): ...here, a new member
4970 function, rewrite to use range based for loop.
4971 (ada_language_data): Delete la_iterate_over_symbols initializer.
4972 * c-lang.c (c_language_data): Likewise.
4973 (cplus_language_data): Likewise.
4974 (asm_language_data): Likewise.
4975 (minimal_language_data): Likewise.
4976 * d-lang.c (d_language_data): Likewise.
4977 * f-lang.c (f_language_data): Likewise.
4978 * go-lang.c (go_language_data): Likewise.
4979 * language.c (unknown_language_data): Likewise.
4980 (auto_language_data): Likewise.
4981 * language.h (language_data): Delete la_iterate_over_symbols field.
4982 (language_defn::iterate_over_symbols): New member function.
4983 (LA_ITERATE_OVER_SYMBOLS): Update.
4984 * linespec.c (iterate_over_all_matching_symtabs): Update.
4985 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
4986 initializer.
4987 * objc-lang.c (objc_language_data): Likewise.
4988 * opencl-lang.c (opencl_language_data): Likewise.
4989 * p-lang.c (pascal_language_data): Likewise.
4990 * rust-lang.c (rust_language_data): Likewise.
4991
4992 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
4993
4994 * ada-lang.c (ada_language_data): Delete
4995 la_lookup_transparent_type initializer.
4996 * c-lang.c (c_language_data): Likewise.
4997 (cplus_language_data): Likewise.
4998 (cplus_language::lookup_transparent_type): New member function.
4999 (asm_language_data): Delete la_lookup_transparent_type
5000 initializer.
5001 (minimal_language_data): Likewise.
5002 * d-lang.c (d_language_data): Likewise.
5003 * f-lang.c (f_language_data): Likewise.
5004 * go-lang.c (go_language_data): Likewise.
5005 * language.c (unknown_language_data): Likewise.
5006 (auto_language_data): Likewise.
5007 * language.h (struct language_data): Delete
5008 la_lookup_transparent_type field.
5009 (language_defn::lookup_transparent_type): New member function.
5010 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
5011 initializer.
5012 * objc-lang.c (objc_language_data): Likewise.
5013 * opencl-lang.c (opencl_language_data): Likewise.
5014 * p-lang.c (pascal_language_data): Likewise.
5015 * rust-lang.c (rust_language_data): Likewise.
5016 * symtab.c (symbol_matches_domain): Update call.
5017
5018 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
5019
5020 * ada-lang.c (ada_language_arch_info): Delete function, move
5021 implementation to...
5022 (ada_language::language_arch_info): ...here, a new member
5023 function.
5024 (ada_language_data): Delete la_language_arch_info.
5025 * c-lang.c (c_language_data): Likewise.
5026 (c_language::language_arch_info): New member function.
5027 (cplus_language_arch_info): Delete function, move
5028 implementation to...
5029 (cplus_language::language_arch_info): ...here, a new member
5030 function.
5031 (cplus_language_data): Delete la_language_arch_info.
5032 (asm_language_data): Likewise.
5033 (asm_language::language_arch_info): New member function.
5034 (minimal_language_data): Delete la_language_arch_info.
5035 (minimal_language::language_arch_info): New member function.
5036 * d-lang.c (d_language_arch_info): Delete function, move
5037 implementation to...
5038 (d_language::language_arch_info): ...here, a new member
5039 function.
5040 (d_language_data): Delete la_language_arch_info.
5041 * f-lang.c (f_language_arch_info): Delete function, move
5042 implementation to...
5043 (f_language::language_arch_info): ...here, a new member
5044 function.
5045 (f_language_data): Delete la_language_arch_info.
5046 * go-lang.c (go_language_arch_info): Delete function, move
5047 implementation to...
5048 (go_language::language_arch_info): ...here, a new member
5049 function.
5050 (go_language_data): Delete la_language_arch_info.
5051 * language.c (unknown_language_data): Likewise.
5052 (unknown_language::language_arch_info): New member function.
5053 (auto_language_data): Delete la_language_arch_info.
5054 (auto_language::language_arch_info): New member function.
5055 (language_gdbarch_post_init): Update call to
5056 la_language_arch_info.
5057 * language.h (language_data): Delete la_language_arch_info
5058 function pointer.
5059 (language_defn::language_arch_info): New function.
5060 * m2-lang.c (m2_language_arch_info): Delete function, move
5061 implementation to...
5062 (m2_language::language_arch_info): ...here, a new member
5063 function.
5064 (m2_language_data): Delete la_language_arch_info.
5065 * objc-lang.c (objc_language_arch_info): Delete function, move
5066 implementation to...
5067 (objc_language::language_arch_info): ...here, a new member
5068 function.
5069 (objc_language_data): Delete la_language_arch_info.
5070 * opencl-lang.c (opencl_language_arch_info): Delete function, move
5071 implementation to...
5072 (opencl_language::language_arch_info): ...here, a new member
5073 function.
5074 (opencl_language_data): Delete la_language_arch_info.
5075 * p-lang.c (pascal_language_arch_info): Delete function, move
5076 implementation to...
5077 (pascal_language::language_arch_info): ...here, a new member
5078 function.
5079 (pascal_language_data): Delete la_language_arch_info.
5080 * rust-lang.c (rust_language_arch_info): Delete function, move
5081 implementation to...
5082 (rust_language::language_arch_info): ...here, a new member
5083 function.
5084 (rust_language_data): Delete la_language_arch_info.
5085
5086 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
5087
5088 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
5089 initializer.
5090 * c-lang.c (c_language_data): Likewise.
5091 (cplus_language_data): Likewise.
5092 (cplus_language::pass_by_reference_info): New method.
5093 (asm_language_data): Delete la_pass_by_reference initializer.
5094 (minimal_language_data): Likewise.
5095 * cp-abi.c (cp_pass_by_reference): Remove use of
5096 default_pass_by_reference.
5097 * d-lang.c (d_language_data): Likewise.
5098 * f-lang.c (f_language_data): Likewise.
5099 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
5100 default_pass_by_reference.
5101 * go-lang.c (go_language_data): Likewise.
5102 * language.c (language_pass_by_reference): Update.
5103 (default_pass_by_reference): Delete.
5104 (unknown_language_data): Delete la_pass_by_reference
5105 initializer.
5106 (auto_language_data): Likewise.
5107 * language.h (struct language_data): Delete la_pass_by_reference
5108 field.
5109 (language_defn::pass_by_reference_info): New member function.
5110 (default_pass_by_reference): Delete declaration.
5111 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
5112 initializer.
5113 * objc-lang.c (objc_language_data): Likewise.
5114 * opencl-lang.c (opencl_language_data): Likewise.
5115 * p-lang.c (pascal_language_data): Likewise.
5116 * rust-lang.c (rust_language_data): Likewise.
5117
5118 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
5119
5120 * ada-lang.c (ada_read_var_value): Delete function, move
5121 implementation to...
5122 (ada_language::read_var_value): ...here.
5123 (ada_language_data): Delete la_read_var_value initializer.
5124 * c-lang.c (c_language_data): Likewise.
5125 (cplus_language_data): Likewise.
5126 (minimal_language_data): Likewise.
5127 * d-lang.c (d_language_data): Likewise.
5128 * f-lang.c (f_language_data): Likewise.
5129 * findvar.c (default_read_var_value): Rename to...
5130 (language_defn::read_var_value): ...this.
5131 * findvar.c (read_var_value): Update header comment, and change to
5132 call member function instead of function pointer.
5133 * go-lang.c (go_language_data): Likewise.
5134 * language.c (unknown_language_data): Delete la_read_var_value
5135 initializer.
5136 (auto_language_data): Likewise.
5137 * language.h (struct language_data): Delete la_read_var_value
5138 field.
5139 (language_defn::read_var_value): New member function.
5140 (default_read_var_value): Delete declaration.
5141 * m2-lang.c (m2_language_data): Delete la_read_var_value
5142 initializer.
5143 * objc-lang.c (objc_language_data): Likewise.
5144 * opencl-lang.c (opencl_language_data): Likewise.
5145 * p-lang.c (pascal_language_data): Likewise.
5146 * rust-lang.c (rust_language_data): Likewise.
5147 * value.h (default_read_var_value): Delete declaration.
5148
5149 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
5150
5151 * ada-lang.c (ada_print_array_index): Delete function, move
5152 implementation to...
5153 (ada_language::print_array_index): ...here.
5154 (ada_language_data): Delete la_print_array_index initializer.
5155 * c-lang.c (c_language_data): Likewise.
5156 (cplus_language_data): Likewise.
5157 (minimal_language_data): Likewise.
5158 * d-lang.c (d_language_data): Likewise.
5159 * f-lang.c (f_language_data): Likewise.
5160 * go-lang.c (go_language_data): Likewise.
5161 * language.c (default_print_array_index): Delete function, move
5162 implementation to...
5163 (language_defn::print_array_index): ...here.
5164 (unknown_language_data): Delete la_print_array_index initializer.
5165 (auto_language_data): Likewise.
5166 * language.h (struct language_data): Delete la_print_array_index
5167 field.
5168 (language_defn::print_array_index): New member function.
5169 (LA_PRINT_ARRAY_INDEX): Update.
5170 (default_print_array_index): Delete declaration.
5171 * m2-lang.c (m2_language_data): Delete la_print_array_index
5172 initializer.
5173 * objc-lang.c (objc_language_data): Likewise.
5174 * opencl-lang.c (opencl_language_data): Likewise.
5175 * p-lang.c (pascal_language_data): Likewise.
5176 * rust-lang.c (rust_language_data): Likewise.
5177
5178 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
5179
5180 * gdb/ada-lang.c (ada_language_defn): Convert to...
5181 (ada_language_data): ...this.
5182 (class ada_language): New class.
5183 (ada_language_defn): New static global.
5184 * gdb/c-lang.c (c_language_defn): Convert to...
5185 (c_language_data): ...this.
5186 (class c_language): New class.
5187 (c_language_defn): New static global.
5188 (cplus_language_defn): Convert to...
5189 (cplus_language_data): ...this.
5190 (class cplus_language): New class.
5191 (cplus_language_defn): New static global.
5192 (asm_language_defn): Convert to...
5193 (asm_language_data): ...this.
5194 (class asm_language): New class.
5195 (asm_language_defn): New static global.
5196 (minimal_language_defn): Convert to...
5197 (minimal_language_data): ...this.
5198 (class minimal_language): New class.
5199 (minimal_language_defn): New static global.
5200 * gdb/d-lang.c (d_language_defn): Convert to...
5201 (d_language_data): ...this.
5202 (class d_language): New class.
5203 (d_language_defn): New static global.
5204 * gdb/f-lang.c (f_language_defn): Convert to...
5205 (f_language_data): ...this.
5206 (class f_language): New class.
5207 (f_language_defn): New static global.
5208 * gdb/go-lang.c (go_language_defn): Convert to...
5209 (go_language_data): ...this.
5210 (class go_language): New class.
5211 (go_language_defn): New static global.
5212 * gdb/language.c (unknown_language_defn): Remove declaration.
5213 (current_language): Initialize to nullptr, real initialization is
5214 moved to _initialize_language.
5215 (languages): Delete global.
5216 (language_defn::languages): Define.
5217 (set_language_command): Use language_defn::languages.
5218 (set_language): Likewise.
5219 (range_error): Likewise.
5220 (language_enum): Likewise.
5221 (language_def): Likewise.
5222 (add_set_language_command): Use language_def::languages for the
5223 language list, and language_def to lookup language pointers.
5224 (skip_language_trampoline): Use language_defn::languages.
5225 (unknown_language_defn): Convert to...
5226 (unknown_language_data): ...this.
5227 (class unknown_language): New class.
5228 (unknown_language_defn): New static global.
5229 (auto_language_defn): Convert to...
5230 (auto_language_data): ...this.
5231 (class auto_language): New class.
5232 (auto_language_defn): New static global.
5233 (language_gdbarch_post_init): Use language_defn::languages.
5234 (_initialize_language): Initialize current_language.
5235 * gdb/language.h (struct language_defn): Rename to...
5236 (struct language_data): ...this.
5237 (struct language_defn): New.
5238 (auto_language_defn): Delete.
5239 (unknown_language_defn): Delete.
5240 (minimal_language_defn): Delete.
5241 (ada_language_defn): Delete.
5242 (asm_language_defn): Delete.
5243 (c_language_defn): Delete.
5244 (cplus_language_defn): Delete.
5245 (d_language_defn): Delete.
5246 (f_language_defn): Delete.
5247 (go_language_defn): Delete.
5248 (m2_language_defn): Delete.
5249 (objc_language_defn): Delete.
5250 (opencl_language_defn): Delete.
5251 (pascal_language_defn): Delete.
5252 (rust_language_defn): Delete.
5253 * gdb/m2-lang.c (m2_language_defn): Convert to...
5254 (m2_language_data): ...this.
5255 (class m2_language): New class.
5256 (m2_language_defn): New static global.
5257 * gdb/objc-lang.c (objc_language_defn): Convert to...
5258 (objc_language_data): ...this.
5259 (class objc_language): New class.
5260 (objc_language_defn): New static global.
5261 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
5262 (opencl_language_data): ...this.
5263 (class opencl_language): New class.
5264 (opencl_language_defn): New static global.
5265 * gdb/p-lang.c (pascal_language_defn): Convert to...
5266 (pascal_language_data): ...this.
5267 (class pascal_language): New class.
5268 (pascal_language_defn): New static global.
5269 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
5270 language pointer, update comment format.
5271 * gdb/rust-lang.c (rust_language_defn): Convert to...
5272 (rust_language_data): ...this.
5273 (class rust_language): New class.
5274 (rust_language_defn): New static global.
5275
5276 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
5277
5278 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
5279 member variable.
5280 <m_stmt_at_address>: New member variable.
5281 (lnp_state_machine::record_line): Don't record some lines, update
5282 tracking of is_stmt at the same address.
5283 (lnp_state_machine::lnp_state_machine): Initialise new member
5284 variables.
5285
5286 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
5287
5288 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
5289 "-include gnu-nat-mig.h".
5290 * gnu-nat-mig.h: New file.
5291 * gnu-nat.c: Include "gnu-nat-mig.h".
5292 (exc_server, msg_reply_server, notify_server,
5293 process_reply_server): Remove declarations.
5294
5295 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5296
5297 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
5298 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
5299 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
5300 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
5301 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
5302 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
5303 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
5304 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
5305 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
5306 to gnu_nat_target class.
5307 * gnu-nat.c: Likewise.
5308 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
5309 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
5310 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
5311 object.
5312 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
5313 instead of `gnu_target'.
5314
5315 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5316
5317 * i386-gnu-tdep.c: Include "gdbcore.h"
5318 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
5319 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
5320 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
5321 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
5322 i386_gnu_sigcontext_addr): New functions
5323 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
5324 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
5325 tdep.
5326
5327 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5328
5329 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
5330 before fork_inferior call. Avoid calling it if target_is_pushed returns
5331 true.
5332
5333 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5334
5335 * gnu-nat.h (gnu_target): New variable declaration.
5336 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
5337 gnu_target.
5338 * gnu-nat.c (gnu_target): New variable.
5339 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
5340 add_thread_silent, and add_thread calls.
5341 (gnu_nat_target::create_inferior): Pass gnu_target to
5342 add_thread_silent, thread_change_ptid call.
5343 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
5344 call.
5345
5346 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5347
5348 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
5349 (gnu_nat_target::find_memory_regions): Remove unused
5350 `old_address' variable.
5351
5352 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5353
5354 * gnu-nat.c: Include "gdbarch.h".
5355
5356 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5357
5358 * reply_mig_hack.awk (Error return): Cast function through
5359 void *, to bypass compiler function call check.
5360
5361 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5362
5363 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
5364 $(srcdir)/reply_mig_hack.awk.
5365
5366 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
5367
5368 * gnu-nat.h (gnu_debug_flag): Set type to bool.
5369
5370 2020-05-30 Jonny Grant <jg@jguk.org>
5371
5372 * configure.ac (ACX_BUGURL): change bug URL to https.
5373
5374 2020-05-30 Pedro Alves <palves@redhat.com>
5375
5376 * cp-support.c (replace_typedefs_template): New.
5377 (replace_typedefs_qualified_name): Handle
5378 DEMANGLE_COMPONENT_TEMPLATE.
5379
5380 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
5381
5382 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
5383 dwarf2/index-cache.h, dwarf2/index-write.c,
5384 dwarf2/index-write.h, dwarf2/line-header.c,
5385 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
5386 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
5387 variables and fields from `dwarf2_per_objfile` to just
5388 `per_objfile` throughout.
5389
5390 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
5391
5392 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
5393 <push_dwarf_reg_entry_value>: Add comment.
5394
5395 2020-05-28 Kevin Buettner <kevinb@redhat.com>
5396 Keith Seitz <keiths@redhat.com>
5397
5398 * python/python.c (do_start_initialization): Call PyEval_SaveThread
5399 instead of PyEval_ReleaseLock.
5400 (class gdbpy_gil): Move to earlier in file.
5401 (finalize_python): Set gdb_python_initialized.
5402 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
5403 when not initialized.
5404
5405 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
5406
5407 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
5408 <push_dwarf_reg_entry_value>: Remove assert. Override
5409 per_objfile with caller_per_objfile.
5410
5411 2020-05-28 Tom de Vries <tdevries@suse.de>
5412
5413 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
5414 PR gold/15646 workaround to symbol kind "type".
5415
5416 2020-05-27 Tom Tromey <tromey@adacore.com>
5417
5418 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
5419
5420 2020-05-27 Tom Tromey <tromey@adacore.com>
5421
5422 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
5423 Use htab_find_with_hash.
5424 <add_abbrev>: Remove "abbrev_number" parameter.
5425 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
5426 "abbrev_number" parameter. Use htab_find_slot_with_hash.
5427 (hash_abbrev): Add comment.
5428 (abbrev_table::lookup_abbrev): Move to header file.
5429 (abbrev_table::read): Update.
5430
5431 2020-05-27 Tom Tromey <tromey@adacore.com>
5432
5433 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
5434 method.
5435 <canonical_name>: New member.
5436 <raw_name>: Rename from "name".
5437 (partial_die_info): Initialize canonical_name.
5438 (scan_partial_symbols): Check raw_name.
5439 (partial_die_parent_scope, partial_die_full_name)
5440 (add_partial_symbol, add_partial_subprogram)
5441 (add_partial_enumeration, load_partial_dies): Use "name" method.
5442 (partial_die_info::name): New method.
5443 (partial_die_info::read, guess_partial_die_structure_name)
5444 (partial_die_info::fixup): Update.
5445
5446 2020-05-27 Tom Tromey <tromey@adacore.com>
5447
5448 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
5449 <get_ref_die_offset>: Inline.
5450 <get_ref_die_offset_complaint>: New method.
5451 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
5452 (attribute::get_ref_die_offset_complaint): Rename from
5453 get_ref_die_offset. Just issue complaint.
5454
5455 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
5456
5457 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
5458
5459 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
5460
5461 * exec.c (exec_file_attach): Use errno value of first openp failure.
5462
5463 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
5464
5465 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
5466 Don't close thread handle.
5467
5468 2020-05-27 Tom Tromey <tom@tromey.com>
5469 Simon Marchi <simon.marchi@efficios.com>
5470
5471 * objfiles.h (struct objfile) <partial_symtabs>: Now a
5472 shared_ptr.
5473 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
5474 member.
5475 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
5476 dwarf2_per_bfd_objfile_data_key>: New globals.
5477 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
5478 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
5479 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
5480 shared.
5481 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
5482 short-circuit when sharing.
5483 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
5484 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
5485
5486 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5487
5488 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
5489 to...
5490 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
5491 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
5492
5493 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5494
5495 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
5496 build_name_components, find_name_components_bounds>:
5497 Add per_objfile parameter.
5498 (struct mapped_index) <symbol_name_at>: Likewise.
5499 (struct mapped_debug_names): Remove constructor.
5500 <dwarf2_per_objfile>: Remove field.
5501 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
5502 (mapped_index_base::find_name_components_bounds,
5503 mapped_index_base::build_name_components,
5504 dw2_expand_symtabs_matching_symbol): Likewise.
5505 (class mock_mapped_index) <symbol_name_at>: Likewise.
5506 (check_match): Likewise.
5507 (check_find_bounds_finds): Likewise.
5508 (test_mapped_index_find_name_component_bounds): Update.
5509 (CHECK_MATCH): Update.
5510 (dw2_expand_symtabs_matching): Update.
5511 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
5512 per_objfile parameter.
5513 <find_vec_in_debug_names>: Likewise.
5514 <m_per_objfile>: New field.
5515 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
5516 parameter.
5517 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
5518 (dw2_debug_names_iterator::next): Update.
5519 (dw2_debug_names_lookup_symbol): Update.
5520 (dw2_debug_names_expand_symtabs_for_function): Update.
5521 (dw2_debug_names_map_matching_symbols): Update.
5522 (dw2_debug_names_expand_symtabs_matching): Update.
5523 (dwarf2_read_debug_names): Update.
5524
5525 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5526
5527 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
5528 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
5529 move to dwarf2_per_objfile.
5530 <read_in_chain>: Remove.
5531 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
5532 remove_all_cus, age_comp_units>: New methods.
5533 <m_dwarf2_cus>: New member.
5534 (struct dwarf2_per_cu_data) <cu>: Remove.
5535 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
5536 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
5537 moved to methods of dwarf2_per_objfile.
5538 (dwarf2_clear_marks): Remove.
5539 (dwarf2_queue_item::~dwarf2_queue_item): Update.
5540 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
5541 (dwarf2_per_bfd::free_cached_comp_units): Remove.
5542 (dwarf2_per_objfile::remove_all_cus): New.
5543 (class free_cached_comp_units) <~free_cached_comp_units>:
5544 Update.
5545 (load_cu): Update.
5546 (dw2_do_instantiate_symtab): Adjust.
5547 (fill_in_sig_entry_from_dwo_entry): Adjust.
5548 (cutu_reader::init_tu_and_read_dwo_dies): Update.
5549 (cutu_reader::cutu_reader): Likewise.
5550 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
5551 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
5552 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
5553 and dwarf2_per_objfile::age_comp_units.
5554 (load_partial_comp_unit): Update.
5555 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
5556 (process_queue): Likewise.
5557 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
5558 backlink.
5559 (dwarf2_read_addr_index): Likewise.
5560 (follow_die_offset): Likewise.
5561 (dwarf2_fetch_die_loc_sect_off): Likewise.
5562 (dwarf2_fetch_constant_bytes): Likewise.
5563 (dwarf2_fetch_die_type_sect_off): Likewise.
5564 (follow_die_sig_1): Likewise.
5565 (load_full_type_unit): Likewise.
5566 (read_signatured_type): Likewise.
5567 (dwarf2_cu::dwarf2_cu): Don't set cu field.
5568 (dwarf2_cu::~dwarf2_cu): Remove.
5569 (dwarf2_per_objfile::get_cu): New.
5570 (dwarf2_per_objfile::set_cu): New.
5571 (age_cached_comp_units): Rename to...
5572 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
5573 to std::unordered_map.
5574 (free_one_cached_comp_unit): Rename to...
5575 (dwarf2_per_objfile::remove_cu): ... this. Adjust
5576 to std::unordered_map.
5577 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
5578 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
5579 a dwarf2_per_objfile in data.
5580 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
5581 (dwarf2_clear_marks): Remove.
5582
5583 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5584
5585 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
5586 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
5587 (init_tu_and_read_dwo_dies): Likewise.
5588 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
5589 (cutu_reader::cutu_reader): Likewise.
5590 (load_partial_comp_unit): Likewise.
5591 (process_psymtab_comp_unit): Update.
5592 (build_type_psymtabs_1): Update.
5593 (process_skeletonless_type_unit): Update.
5594 (load_full_comp_unit): Update.
5595 (find_partial_die): Update.
5596 (dwarf2_read_addr_index): Update.
5597 (read_signatured_type): Update.
5598
5599 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5600
5601 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
5602 m_header_read_in>: New fields.
5603 <get_header>: New method.
5604 * dwarf2/read.c (per_cu_header_read_in): Remove.
5605 (dwarf2_per_cu_data::get_header): New.
5606 (dwarf2_per_cu_data::addr_size): Update.
5607 (dwarf2_per_cu_data::offset_size): Update.
5608 (dwarf2_per_cu_data::ref_addr_size): Update.
5609
5610 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5611
5612 * dwarf2/read.c (load_cu): Return dwarf2_cu.
5613 (dw2_do_instantiate_symtab): Update.
5614 (queue_and_load_all_dwo_tus): Change parameter from
5615 dwarf2_per_cu_data to dwarf2_cu.
5616 (dwarf2_fetch_die_loc_sect_off): Update.
5617 (dwarf2_fetch_constant_bytes): Update.
5618 (dwarf2_fetch_die_type_sect_off): Update.
5619
5620 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5621
5622 * dwarf2/read.c (process_full_comp_unit,
5623 process_full_type_unit): Remove per_cu, per_objfile paramters.
5624 Add dwarf2_cu parameter.
5625 (process_queue): Update.
5626
5627 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5628
5629 * dwarf2/read.c (create_cu_from_index_list): Replace
5630 dwarf2_per_objfile parameter with dwarf2_per_bfd.
5631 (create_cus_from_index_list): Likewise.
5632 (create_cus_from_index): Likewise.
5633 (create_signatured_type_table_from_index): Likewise.
5634 (create_cus_from_debug_names_list): Likewise.
5635 (create_cus_from_debug_names): Likewise.
5636 (dwarf2_read_gdb_index): Update.
5637 (dwarf2_read_debug_names): Update.
5638
5639 2020-05-27 Tom Tromey <tom@tromey.com>
5640 Simon Marchi <simon.marchi@efficios.com>
5641
5642 * dwarf2/read.h (struct dwarf2_per_objfile)
5643 <get_type_for_signatured_type, set_type_for_signatured_type>:
5644 New methods.
5645 <m_type_map>: New member.
5646 (struct signatured_type) <type>: Remove.
5647 * dwarf2/read.c
5648 (dwarf2_per_objfile::get_type_for_signatured_type,
5649 dwarf2_per_objfile::set_type_for_signatured_type): New.
5650 (get_signatured_type): Use new methods.
5651
5652 2020-05-27 Tom Tromey <tom@tromey.com>
5653 Simon Marchi <simon.marchi@efficios.com>
5654
5655 * dwarf2/read.h (struct type_unit_group_unshareable): New.
5656 (struct dwarf2_per_objfile) <type_units>: New member.
5657 <get_type_unit_group_unshareable>: New method.
5658 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
5659 num_symtabs, symtabs>: Remove; move to
5660 type_unit_group_unshareable.
5661 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
5662 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
5663 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
5664
5665 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5666
5667 * dwarf2/read.h (struct dwarf2_per_cu_data):
5668 <dwarf2_per_objfile>: Remove.
5669 * dwarf2/read.c (create_cu_from_index_list): Don't assign
5670 dwarf2_per_objfile.
5671 (create_signatured_type_table_from_index): Likewise.
5672 (create_signatured_type_table_from_debug_names): Likewise.
5673 (create_debug_type_hash_table): Likewise.
5674 (fill_in_sig_entry_from_dwo_entry): Likewise.
5675 (create_type_unit_group): Likewise.
5676 (read_comp_units_from_section): Likewise.
5677 (create_cus_hash_table): Likewise.
5678
5679 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5680
5681 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
5682 dwarf2_per_cu_data::dwarf2_per_objfile.
5683 (compute_compunit_symtab_includes): Likewise.
5684 (dwarf2_cu::start_symtab): Likewise.
5685
5686 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5687
5688 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
5689 parameter.
5690 * dwarf2/read.c (get_die_type_at_offset): Likewise.
5691 (read_namespace_alias): Update.
5692 (lookup_die_type): Update.
5693 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
5694 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
5695 Update.
5696 (disassemble_dwarf_expression): Update.
5697
5698 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5699
5700 * dwarf2/read.h (struct dwarf2_queue_item): Add
5701 dwarf2_per_objfile parameter, assign new parameter.
5702 <per_objfile>: New field.
5703 * dwarf2/read.c (free_one_cached_comp_unit): Add
5704 dwarf2_per_objfile parameter.
5705 (queue_comp_unit): Likewise.
5706 (dw2_do_instantiate_symtab): Update.
5707 (process_psymtab_comp_unit): Update.
5708 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
5709 (process_imported_unit_die): Update.
5710 (queue_and_load_dwo_tu): Update.
5711 (follow_die_offset): Update.
5712 (follow_die_sig_1): Update.
5713
5714 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5715
5716 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
5717 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
5718 (read_call_site_scope): Assign per_objfile.
5719 (dwarf2_per_cu_data::objfile): Remove.
5720 * gdbtypes.h (struct call_site) <per_objfile>: New member.
5721 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
5722 dwarf2_per_objfile parameter.
5723 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
5724 dwarf2_per_objfile parameter.
5725 (dwarf_expr_reg_to_entry_parameter): Add output
5726 dwarf2_per_objfile parameter.
5727 (locexpr_get_frame_base): Update.
5728 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
5729 <push_dwarf_reg_entry_value>: Update.
5730 <call_site_to_target_addr>: Update.
5731 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
5732 parameter.
5733 (value_of_dwarf_reg_entry): Update.
5734 (rw_pieced_value): Update.
5735 (indirect_synthetic_pointer): Update.
5736 (dwarf2_evaluate_property): Update.
5737 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
5738 parameter.
5739 (locexpr_read_variable): Update.
5740 (locexpr_get_symbol_read_needs): Update.
5741 (loclist_read_variable): Update.
5742
5743 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5744
5745 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
5746 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
5747 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
5748 parameter.
5749 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
5750 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
5751 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
5752 parameter.
5753 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
5754 sect_variable_value): Add dwarf2_per_objfile parameter.
5755 (class dwarf_evaluate_loc_desc) <dwarf_call,
5756 dwarf_variable_value>: Update.
5757 (fetch_const_value_from_synthetic_pointer): Add
5758 dwarf2_per_objfile parameter.
5759 (fetch_const_value_from_synthetic_pointer): Update.
5760 (coerced_pieced_ref): Update.
5761 (class symbol_needs_eval_context) <dwarf_call,
5762 dwarf_variable_value>: Update.
5763 (dwarf2_compile_expr_to_ax): Update.
5764
5765 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5766
5767 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
5768 parameter.
5769 (dwarf2_evaluate_loc_desc_full): Update.
5770
5771 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5772
5773 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
5774 parameter.
5775 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
5776 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
5777 dwarf2_per_objfile parameter.
5778 (decode_debug_loc_dwo_addresses): Likewise.
5779 (dwarf2_find_location_expression): Update.
5780 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
5781 (locexpr_describe_location_piece): Add dwarf2_per_objfile
5782 parameter.
5783 (disassemble_dwarf_expression): Add dwarf2_per_objfile
5784 parameter.
5785 (locexpr_describe_location_1): Likewise.
5786 (locexpr_describe_location): Update.
5787
5788 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5789
5790 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
5791 Remove.
5792 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
5793 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
5794 (dwarf2_compile_property_to_c): Update.
5795 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
5796 use text offset from objfile.
5797 (locexpr_tracepoint_var_ref): Update.
5798 (locexpr_generate_c_location): Update.
5799 (loclist_describe_location): Update.
5800 (loclist_tracepoint_var_ref): Update.
5801 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
5802 dwarf2_per_objfile parameter.
5803 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
5804 use text offset from objfile.
5805 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
5806
5807 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5808
5809 * dwarf2/expr.h (struct dwarf_expr_context)
5810 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
5811 <offset>: Remove.
5812 <per_objfile>: New member.
5813 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
5814 dwarf2_per_objfile parameter. Don't set offset, set
5815 per_objfile.
5816 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
5817 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
5818 a dwarf2_per_objfile object instead of an offset.
5819 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
5820 constructor.
5821 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
5822 to dwarf2_expr_executor constructor. Don't set offset.
5823 (dwarf2_fetch_cfa_info): Update.
5824 (struct dwarf2_frame_cache) <text_offset>: Remove.
5825 <per_objfile>: New field.
5826 (dwarf2_frame_cache): Update.
5827 (dwarf2_frame_prev_register): Update.
5828 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
5829 <dwarf_evaluate_loc_desc>: Add constructor.
5830 (dwarf2_evaluate_loc_desc_full): Update.
5831 (dwarf2_locexpr_baton_eval): Update.
5832 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
5833 Add constructor.
5834 (dwarf2_loc_desc_get_symbol_read_needs): Update.
5835
5836 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5837
5838 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
5839 addr_sized_int_type>: Move to dwarf2_cu.
5840 <int_type>: Move to dwarf2_per_objfile.
5841 (struct dwarf2_per_objfile) <int_type>: Move here.
5842 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
5843 addr_sized_int_type>: Move here.
5844 (read_func_scope): Update.
5845 (read_array_type): Update.
5846 (read_tag_string_type): Update.
5847 (attr_to_dynamic_prop): Update.
5848 (dwarf2_per_cu_data::int_type): Rename to...
5849 (dwarf2_per_objfile::int_type): ... this.
5850 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
5851 (dwarf2_cu::addr_sized_int_type): ... this.
5852 (read_subrange_type): Update.
5853 (dwarf2_per_cu_data::addr_type): Rename to...
5854 (dwarf2_cu::addr_type): ... this.
5855 (set_die_type): Update.
5856
5857 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5858
5859 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
5860 data through per_cu->cu.
5861
5862 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5863
5864 * dwarf2/read.c (lookup_dwo_comp_unit): Change
5865 dwarf2_per_cu_data parameter fo dwarf2_cu.
5866 (lookup_dwo_type_unit): Likewise.
5867 (read_cutu_die_from_dwo): Likewise.
5868 (lookup_dwo_unit): Likewise.
5869 (open_and_init_dwo_file): Likewise.
5870 (lookup_dwo_cutu): Likewise.
5871 (lookup_dwo_comp_unit): Likewise.
5872 (lookup_dwo_type_unit): Likewise.
5873 (cutu_reader::init_tu_and_read_dwo_dies): Update.
5874 (cutu_reader::cutu_reader): Update.
5875
5876 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5877
5878 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
5879 parameter.
5880 (process_full_type_unit): Likewise.
5881 (process_queue): Update.
5882
5883 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5884
5885 * dwarf2/read.c (recursively_compute_inclusions): Add
5886 dwarf2_per_objfile parameter.
5887 (compute_compunit_symtab_includes): Likewise.
5888 (process_cu_includes): Update.
5889
5890 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5891
5892 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
5893 parameter.
5894 (create_type_unit_group): Update.
5895 (process_psymtab_comp_unit_reader): Update.
5896 (build_type_psymtabs_reader): Update.
5897
5898 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5899
5900 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
5901 object through m_this_cu->cu.
5902
5903 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5904
5905 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
5906 the info parameter.
5907 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
5908
5909 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5910
5911 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
5912 per_objfile parameter.
5913 (load_full_type_unit): Add per_objfile parameter.
5914 (read_signatured_type): Likewise.
5915 (load_full_comp_unit): Likewise.
5916 (load_cu): Likewise.
5917 (dw2_do_instantiate_symtab): Likewise.
5918 (dw2_get_file_names): Likewise.
5919 (dw2_map_symtabs_matching_filename): Update.
5920 (dw_expand_symtabs_matching_file_matcher): Update.
5921 (dw2_map_symbol_filenames): Update.
5922 (process_psymtab_comp_unit): Add per_objfile parameter.
5923 (build_type_psymtabs_1): Update.
5924 (process_skeletonless_type_unit): Update.
5925 (dwarf2_build_psymtabs_hard): Update.
5926 (load_partial_comp_unit): Add per_objfile parameter.
5927 (scan_partial_symbols): Update.
5928 (load_full_comp_unit): Add per_objfile parameter.
5929 (process_imported_unit_die): Update.
5930 (create_cus_hash_table): Update.
5931 (find_partial_die): Update.
5932 (dwarf2_read_addr_index): Update.
5933 (follow_die_offset): Update.
5934 (dwarf2_fetch_die_loc_sect_off): Update.
5935 (dwarf2_fetch_constant_bytes): Update.
5936 (dwarf2_fetch_die_type_sect_off): Update.
5937 (follow_die_sig_1): Update.
5938 (load_full_type_unit): Add per_objfile parameter.
5939 (read_signatured_type): Likewise.
5940
5941 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5942
5943 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
5944 of objfile_name.
5945
5946 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5947
5948 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
5949 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
5950 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
5951 field.
5952 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
5953 (create_cus_from_index): Update.
5954 (dwarf2_read_gdb_index): Update.
5955 (create_cus_from_debug_names): Update.
5956 (dwarf2_read_debug_names): Update.
5957 (get_abbrev_section_for_cu): Update.
5958 (create_all_comp_units): Update.
5959 (read_attribute_value): Update.
5960 (get_debug_line_section): Update.
5961 * dwarf2/index-cache.c (index_cache::store): Update.
5962 * dwarf2/index-write.c (save_gdb_index_command): Update.
5963 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
5964
5965 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
5966
5967 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
5968 member.
5969 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
5970 dwarf2_per_cu_data::per_bfd.
5971 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
5972 (create_type_unit_group): Likewise.
5973 (queue_comp_unit): Remove reference to
5974 per_cu->dwarf2_per_objfile.
5975 (maybe_queue_comp_unit): Likewise.
5976 (fill_in_sig_entry_from_dwo_entry): Assign new field.
5977 (create_cus_hash_table): Assign new field.
5978
5979 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5980
5981 * dwarf2/read.c: Replace
5982 dwarf2_cu->per_cu->dwarf2_per_objfile references with
5983 dwarf2_cu->per_objfile throughout.
5984
5985 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
5986
5987 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
5988 parameter, don't use per_cu->dwarf2_per_objfile.
5989 (dw2_instantiate_symtab): Likewise.
5990 (dw2_find_last_source_symtab): Update.
5991 (dw2_map_expand_apply): Update.
5992 (dw2_lookup_symbol): Update.
5993 (dw2_expand_symtabs_for_function): Update.
5994 (dw2_expand_all_symtabs): Update.
5995 (dw2_expand_symtabs_with_fullname): Update.
5996 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
5997 don't use per_cu->dwarf2_per_objfile.
5998 (dw2_expand_marked_cus): Update.
5999 (dw2_find_pc_sect_compunit_symtab): Update.
6000 (dw2_debug_names_lookup_symbol): Update.
6001 (dw2_debug_names_expand_symtabs_for_function): Update.
6002 (dw2_debug_names_map_matching_symbols): Update.
6003 (dwarf2_psymtab::expand_psymtab): Update.
6004
6005 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
6006
6007 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
6008 <per_objfile>: New member.
6009 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
6010 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
6011 call to dwarf2_cu.
6012 (cutu_reader::cutu_reader): Update.
6013 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
6014
6015 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
6016
6017 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
6018 struct dwarf2_per_objfile.
6019 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
6020 dwarf2_per_bfd.
6021 * dwarf2/read.c (set_die_type): Update.
6022 (get_die_type_at_offset): Update.
6023
6024 2020-05-27 Tom Tromey <tom@tromey.com>
6025 Simon Marchi <simon.marchi@efficios.com>
6026
6027 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
6028 method.
6029 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
6030 get_symtab, set_symtab>: New methods.
6031 <m_symtabs>: New field.
6032 (struct dwarf2_psymtab): Derive from partial_symtab.
6033 <readin_p, get_compunit_symtab>: Declare methods.
6034 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
6035 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
6036 New methods.
6037 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
6038 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
6039 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
6040 (dw2_symtab_iter_next, dw2_print_stats)
6041 (dw2_expand_symtabs_with_fullname)
6042 (dw2_expand_symtabs_matching_one)
6043 (dw_expand_symtabs_matching_file_matcher)
6044 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
6045 (dw2_debug_names_iterator::next)
6046 (dw2_debug_names_map_matching_symbols)
6047 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
6048 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
6049 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
6050 New methods.
6051 (get_compunit_symtab, process_full_comp_unit)
6052 (process_full_type_unit): Update.
6053 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
6054
6055 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
6056
6057 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
6058 then introduce a new dwarf2_per_objfile type.
6059 <read_line_string>: Move to the new dwarf2_per_objfile type.
6060 <objfile>: Likewise.
6061 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
6062 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
6063 dwarf2_per_objfile->per_bfd.
6064 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
6065 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
6066 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
6067 (dwarf2_per_bfd::free_cached_comp_units): ... this.
6068 (dwarf2_has_info): Allocate dwarf2_per_bfd.
6069 (dwarf2_per_objfile::locate_sections): Rename to...
6070 (dwarf2_per_bfd::locate_sections): ... this.
6071 (dwarf2_per_objfile::get_cutu): Rename to...
6072 (dwarf2_per_bfd::get_cutu): ... this.
6073 (dwarf2_per_objfile::get_cu): Rename to...
6074 (dwarf2_per_bfd::get_cu): ... this.
6075 (dwarf2_per_objfile::get_tu): Rename to...
6076 (dwarf2_per_bfd::get_tu): ... this.
6077 (dwarf2_per_objfile::allocate_per_cu): Rename to...
6078 (dwarf2_per_bfd::allocate_per_cu): ... this.
6079 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
6080 (dwarf2_per_bfd::allocate_signatured_type): ... this.
6081 (get_gdb_index_contents_ftype): Change parameter from
6082 dwarf2_per_objfile to dwarf2_per_bfd.
6083 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
6084 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
6085
6086 2020-05-27 Tom Tromey <tom@tromey.com>
6087 Simon Marchi <simon.marchi@efficios.com>
6088
6089 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
6090 (allocate_piece_closure): Set "per_objfile" member.
6091 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
6092 (locexpr_describe_location, loclist_describe_location): Use new
6093 member.
6094 * dwarf2/read.c (read_call_site_scope)
6095 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
6096 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
6097 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
6098 handle_data_member_location): Set per_objfile member.
6099 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
6100 member.
6101 (struct dwarf2_loclist_baton) <per_objfile>: New member.
6102
6103 2020-05-27 Tom Tromey <tom@tromey.com>
6104
6105 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
6106 allocate_signatured_type>: Declare new methods.
6107 <m_num_psymtabs>: New member.
6108 (struct dwarf2_per_cu_data) <index>: New member.
6109 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
6110 (dwarf2_per_objfile::allocate_signatured_type): New methods.
6111 (create_cu_from_index_list): Use allocate_per_cu.
6112 (create_signatured_type_table_from_index)
6113 (create_signatured_type_table_from_debug_names)
6114 (create_debug_type_hash_table, add_type_unit)
6115 (read_comp_units_from_section): Use allocate_signatured_type.
6116
6117 2020-05-27 Tom Tromey <tom@tromey.com>
6118
6119 * psymtab.c (partial_map_expand_apply)
6120 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
6121 (psym_lookup_global_symbol_language)
6122 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
6123 (psym_print_stats, psym_expand_symtabs_for_function)
6124 (psym_map_symbol_filenames, psym_map_matching_symbols)
6125 (psym_expand_symtabs_matching)
6126 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
6127 (maintenance_check_psymtabs): Update.
6128 * psympriv.h (struct partial_symtab) <readin_p,
6129 get_compunit_symtab>: Add objfile parameter.
6130 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
6131 Likewise.
6132 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
6133 get_compunit_symtab>: Likewise.
6134 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
6135
6136 2020-05-27 Tom Tromey <tom@tromey.com>
6137
6138 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
6139 member.
6140 * dwarf2/read.c (delete_file_name_entry): Fix comment.
6141 (create_cu_from_index_list)
6142 (create_signatured_type_table_from_index)
6143 (create_signatured_type_table_from_debug_names)
6144 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
6145 (dwarf2_create_include_psymtab)
6146 (create_debug_type_hash_table, add_type_unit)
6147 (create_type_unit_group, read_comp_units_from_section)
6148 (dwarf2_compute_name, create_cus_hash_table)
6149 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
6150 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
6151 obstack.
6152 (dw2_get_real_path): Likewise. Change argument to
6153 dwarf2_per_objfile.
6154
6155 2020-05-27 Luis Machado <luis.machado@linaro.org>
6156
6157 PR tdep/26000
6158 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
6159 for ldrd (immediate).
6160
6161 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6162
6163 * command.h: Add comment giving the name of class_tui.
6164 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
6165 create the fake command for the help for class_tui.
6166
6167 2020-05-26 Tom Tromey <tromey@adacore.com>
6168
6169 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
6170 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
6171 (val_atr): New function.
6172 (value_val_atr): Use it.
6173 * ada-valprint.c (print_optional_low_bound): Change low bound
6174 handling for enums.
6175 (val_print_packed_array_elements): Don't call discrete_position.
6176 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
6177 discrete_position for enum types.
6178 * language.c (default_print_array_index): Change type.
6179 * language.h (struct language_defn) <la_print_array_index>: Add
6180 index_type parameter, change type of index_value.
6181 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
6182 (default_print_array_index): Update.
6183 * valprint.c (maybe_print_array_index): Don't call
6184 value_from_longest. Update.
6185 (value_print_array_elements): Don't call discrete_position.
6186
6187 2020-05-26 Tom Tromey <tromey@adacore.com>
6188
6189 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
6190 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
6191
6192 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
6193
6194 PR gdb/13519
6195 * avr-tdep.c (avr_integer_to_address): Return data or code
6196 address accordingly to the second 'type' argument of the
6197 function.
6198
6199 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
6200
6201 * infcmd.c, inferior.h: (construct_inferior_arguments):
6202 Moved function from here to gdbsupport/common-inferior.{h,cc}
6203
6204 2020-05-23 Tom Tromey <tom@tromey.com>
6205
6206 Revert commit eca1f90c:
6207 * NEWS: Remove entry for completion styling.
6208 * completer.c (_rl_completion_prefix_display_length): Move
6209 declaration later.
6210 (gdb_fnprint): Revert.
6211 (gdb_display_match_list_1): Likewise.
6212 * cli/cli-style.c (completion_prefix_style)
6213 (completion_difference_style, completion_suffix_style): Remove.
6214 (_initialize_cli_style): Revert.
6215 * cli/cli-style.h (completion_prefix_style)
6216 (completion_difference_style, completion_suffix_style): Don't
6217 declare.
6218
6219 2020-05-24 Pedro Alves <palves@redhat.com>
6220
6221 * symtab.c (completion_list_add_name): Return boolean indication
6222 of whether the symbol matched.
6223 (completion_list_add_symbol): Don't try to remove C++ aliases if
6224 the symbol didn't match in the first place.
6225 * symtab.h (completion_list_add_name): Return bool.
6226
6227 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
6228
6229 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
6230 type::field.
6231
6232 2020-05-23 Joel Brobecker <brobecker@adacore.com>
6233
6234 GDB 9.2 released.
6235
6236 2020-05-23 Tom Tromey <tom@tromey.com>
6237
6238 * NEWS: Add entry for completion styling.
6239 * completer.c (_rl_completion_prefix_display_length): Move
6240 declaration earlier.
6241 (gdb_fnprint): Use completion_style.
6242 (gdb_display_match_list_1): Likewise.
6243 * cli/cli-style.c (completion_prefix_style)
6244 (completion_difference_style, completion_suffix_style): New
6245 globals.
6246 (_initialize_cli_style): Register new globals.
6247 * cli/cli-style.h (completion_prefix_style)
6248 (completion_difference_style, completion_suffix_style): Declare.
6249
6250 2020-05-23 Pedro Alves <palves@redhat.com>
6251
6252 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
6253 (parse_escape): Use ISDIGIT instead of isdigit.
6254 (puts_debug): Use gdb_isprint instead of isprint.
6255 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
6256 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
6257 ISSPACE instead of isspace.
6258 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
6259 instead of isspace.
6260 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
6261 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
6262 instead of isxdigit and ISDIGIT instead of isdigit.
6263
6264 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
6265
6266 * gdbtypes.h (struct type) <field>: New method.
6267 (TYPE_FIELDS): Remove, replace all uses with either type::fields
6268 or type::field.
6269
6270 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
6271
6272 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
6273 (TYPE_FIELDS): Use type::fields. Change all call sites that
6274 modify the propery to use type::set_fields instead.
6275
6276 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
6277
6278 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
6279 type::num_fields instead.
6280
6281 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
6282
6283 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
6284 methods.
6285 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
6286 that modify the number of fields to use type::set_num_fields
6287 instead.
6288
6289 2020-05-22 Tom Tromey <tromey@adacore.com>
6290
6291 * compile/compile-object-load.h (munmap_list_free): Don't
6292 declare.
6293
6294 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
6295
6296 * annotate.c (annotate_source_line): Update return type, add call
6297 to update current symtab and line.
6298 * annotate.h (annotate_source_line): Update return type, and
6299 extend header comment.
6300 * source.c (info_line_command): Check annotation_level before
6301 calling annotate_source_line.
6302 * stack.c (print_frame_info): If calling annotate_source_line
6303 returns true, then don't print any other source line information.
6304
6305 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
6306
6307 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
6308
6309 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
6310
6311 * coffread.c (patch_type): Remove NULL check before xfree.
6312 * corefile.c (set_gnutarget): Likewise.
6313 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
6314 * exec.c (build_section_table): Likewise.
6315 * remote.c (remote_target::pass_signals): Likewise.
6316 * utils.c (n_spaces): Likewise.
6317 * cli/cli-script.c (document_command): Likewise.
6318 * i386-windows-tdep.c (core_process_module_section): Likewise.
6319 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
6320
6321 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
6322
6323 * symfile.c (reread_symbols): Clear objfile's section_offsets
6324 vector and section indices, re-compute them by calling
6325 sym_offsets.
6326
6327 2020-05-20 Tom Tromey <tromey@adacore.com>
6328
6329 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
6330 (desc_one_bound, desc_index_type): Compute field name.
6331
6332 2020-05-20 Tom de Vries <tdevries@suse.de>
6333
6334 PR symtab/25833
6335 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
6336
6337 2020-05-20 Alan Modra <amodra@gmail.com>
6338
6339 PR 25993
6340 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
6341 bfd_set_filename.
6342 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
6343 passed to bfd_set_filename.
6344 * symfile-mem.c (add_vsyscall_page): Likewise for string
6345 passed to symbol_file_add_from_memory.
6346 (symbol_file_add_from_memory): Make name param a const char* and
6347 don't strdup.
6348
6349 2020-05-20 Alan Modra <amodra@gmail.com>
6350
6351 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
6352 rather than accessing bfd->filename directly.
6353 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
6354 and use bfd_section_name.
6355 * dwarf2/frame.c (decode_frame_entry): Likewise.
6356 * exec.c (exec_set_section_address): Likewise.
6357 * solib-aix.c (solib_aix_bfd_open): Likewise.
6358 * stap-probe.c (get_stap_base_address): Likewise.
6359 * symfile.c (reread_symbols): Likewise.
6360
6361 2020-05-19 Tom Tromey <tromey@adacore.com>
6362
6363 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
6364
6365 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
6366
6367 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
6368
6369 2020-05-19 Pedro Alves <palves@redhat.com>
6370
6371 * NEWS (set exec-file-mismatch): Adjust entry.
6372 * exec.c: Include "build-id.h".
6373 (validate_exec_file): Try to match build IDs instead of filenames.
6374 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
6375 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
6376 and pass down 'warn_if_slow'.
6377 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
6378 gdb_bfd_open_closure to pass it down.
6379 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
6380
6381 2020-05-19 Pedro Alves <palves@redhat.com>
6382
6383 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
6384 * target.c (target_fileio_open_1): Rename to target_fileio_open
6385 and make extern. Use bool.
6386 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
6387 (target_fileio_read_alloc_1): Adjust.
6388 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
6389 (target_fileio_open_warn_if_slow): Delete declaration.
6390
6391 2020-05-19 Pedro Alves <palves@redhat.com>
6392
6393 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
6394 Adjust all callers.
6395
6396 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
6397
6398 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
6399 whether disp is negative.
6400
6401 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
6402
6403 * symfile.h (struct symfile_segment_data)
6404 <~symfile_segment_data>: Remove.
6405 <segment_info>: Change to std::vector.
6406 * symfile.c (default_symfile_segments): Update.
6407 * elfread.c (elf_symfile_segments): Update.
6408
6409 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
6410
6411 * symfile.h (struct symfile_segment_data) <struct segment>: New.
6412 <segments>: New.
6413 <segment_bases, segment_sizes>: Remove.
6414 * symfile.c (default_symfile_segments): Update.
6415 * elfread.c (elf_symfile_segments): Update.
6416 * remote.c (remote_target::get_offsets): Update.
6417 * solib-target.c (solib_target_relocate_section_addresses):
6418 Update.
6419
6420 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
6421
6422 * symfile.h (struct symfile_segment_data): Initialize fields.
6423 <~symfile_segment_data>: Add.
6424 (symfile_segment_data_up): New.
6425 (struct sym_fns) <sym_segments>: Return a
6426 symfile_segment_data_up.
6427 (default_symfile_segments): Return a symfile_segment_data_up.
6428 (free_symfile_segment_data): Remove.
6429 (get_symfile_segment_data): Return a symfile_segment_data_up.
6430 * symfile.c (default_symfile_segments): Likewise.
6431 (get_symfile_segment_data): Likewise.
6432 (free_symfile_segment_data): Remove.
6433 (symfile_find_segment_sections): Update.
6434 * elfread.c (elf_symfile_segments): Return a
6435 symfile_segment_data_up.
6436 * remote.c (remote_target::get_offsets): Update.
6437 * solib-target.c (solib_target_relocate_section_addresses):
6438 Update.
6439 * symfile-debug.c (debug_sym_segments): Return a
6440 symfile_segment_data_up.
6441
6442 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6443
6444 PR build/25981
6445 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
6446 Hardcode register numbers.
6447
6448 PR build/25981
6449 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
6450 procfs_find_LDT_entry): Remove.
6451 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
6452 procfs_find_LDT_entry): Remove.
6453 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
6454 Remove.
6455
6456 2020-05-17 Pedro Alves <palves@redhat.com>
6457 Andrew Burgess <andrew.burgess@embecosm.com>
6458 Keno Fischer <keno@juliacomputing.com>
6459
6460 PR gdb/25741
6461 * breakpoint.c (build_target_condition_list): Update comments.
6462 (build_target_command_list): Update comments and skip matching
6463 locations.
6464 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
6465 a separate function. Simplify "set breakpoint auto-hw off"
6466 handling.
6467 (insert_breakpoints): Update comment.
6468 (tracepoint_locations_match): New parameter. For breakpoints,
6469 compare location types too, if the caller wants to.
6470 (handle_automatic_hardware_breakpoints): New functions.
6471 (bp_location_is_less_than): Also sort by location type and
6472 hardware breakpoint length.
6473 (update_global_location_list): Handle "set breakpoint auto-hw on"
6474 here.
6475 (update_breakpoint_locations): Ask breakpoint_locations_match to
6476 ignore location types.
6477
6478 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
6479
6480 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
6481 type::name instead.
6482
6483 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
6484
6485 * gdbtypes.h (struct type) <name, set_name>: New methods.
6486 (TYPE_CODE): Use type::name. Change all call sites used to set
6487 the name to use type::set_name instead.
6488
6489 2020-05-16 Tom Tromey <tom@tromey.com>
6490
6491 * top.c (quit_force): Update.
6492 * infrun.c (handle_no_resumed): Update.
6493 * top.h (all_uis): New function.
6494 (ALL_UIS): Remove.
6495
6496 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
6497
6498 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
6499
6500 2020-05-16 Pedro Alves <palves@redhat.com>
6501
6502 * ia64-linux-nat.c
6503 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
6504 Declare method.
6505 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
6506
6507 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
6508
6509 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
6510 (sparc64_adi_info): Likewise.
6511
6512 2020-05-15 Tom Tromey <tom@tromey.com>
6513
6514 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
6515 block_objfile.
6516 (lookup_objfile_from_block): Remove.
6517 (lookup_symbol_in_block, lookup_symbol_in_static_block)
6518 (lookup_global_symbol): Use block_objfile.
6519 * symtab.h (lookup_objfile_from_block): Don't declare.
6520 * printcmd.c (clear_dangling_display_expressions): Use
6521 block_objfile.
6522 * parse.c (operator_check_standard): Use block_objfile.
6523
6524 2020-05-15 Tom Tromey <tom@tromey.com>
6525
6526 * language.c (language_alloc_type_symbol): Set
6527 SYMBOL_SECTION.
6528 * symtab.c (initialize_objfile_symbol): Remove.
6529 (allocate_symbol): Remove.
6530 (allocate_template_symbol): Remove.
6531 * dwarf2/read.c (fixup_go_packaging): Use "new".
6532 (new_symbol): Use "new".
6533 (read_variable): Don't call initialize_objfile_symbol. Use
6534 "new".
6535 (read_func_scope): Use "new".
6536 * xcoffread.c (process_xcoff_symbol): Don't call
6537 initialize_objfile_symbol.
6538 (SYMBOL_DUP): Remove.
6539 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
6540 "new".
6541 * symtab.h (allocate_symbol, initialize_objfile_symbol)
6542 (allocate_template_symbol): Don't declare.
6543 (struct symbol): Add copy constructor. Change defaults.
6544 * jit.c (finalize_symtab): Use "new".
6545 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
6546 Use "new".
6547 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
6548 (common_block_end): Use "new".
6549 * mdebugread.c (parse_symbol): Use "new".
6550 (new_symbol): Likewise.
6551
6552 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6553
6554 * NEWS: Mention changes to help and apropos.
6555
6556 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6557
6558 * command.h (enum command_class): Improve comments, document
6559 that class_alias is for user-defined aliases, give the class
6560 name for each class, remove unused class_xdb.
6561 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
6562 * breakpoint.c (_initialize_breakpoint): Replace class_alias
6563 by a precise class.
6564 * infcmd.c (_initialize_infcmd): Likewise.
6565 * reverse.c (_initialize_reverse): Likewise.
6566 * stack.c (_initialize_stack): Likewise.
6567 * symfile.c (_initialize_symfile): Likewise.
6568 * tracepoint.c (_initialize_tracepoint): Likewise.
6569
6570 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6571
6572 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
6573 when their aliased command is traversed.
6574 (help_cmd): Add fput_command_names_styled call to
6575 output command name and aliases when command has an alias.
6576
6577 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6578
6579 * cli/cli-decode.h (help_cmd_list): Remove declaration.
6580 * cli/cli-decode.c (help_cmd_list): Declare as static,
6581 remove prefix argument, use bool for recurse arg, rework to show the aliases of
6582 a command together with the command.
6583 (fput_command_name_styled, fput_command_names_styled): New functions.
6584 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
6585 fput_command_name_styled.
6586 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
6587 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
6588
6589 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6590
6591 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
6592 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
6593 * command.h (cmd_show_list): Likewise.
6594 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
6595 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
6596
6597 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6598
6599 * unittests/command-def-selftests.c (traverse_command_structure):
6600 Verify all commands of a list have the same prefix command and
6601 that only the top cmdlist commands have a null prefix.
6602
6603 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6604
6605 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
6606 as prefix, not one of its aliases.
6607 (set_cmd_prefix): Remove.
6608 (do_add_cmd): Centralize the setting of the prefix of a command, when
6609 command is defined after its full chain of prefix commands.
6610 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
6611 (add_setshow_cmd_full): Likewise.
6612 (update_prefix_field_of_prefixed_commands): New function.
6613 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
6614 update_prefix_field_of_prefixed_commands.
6615 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
6616 addresses of remote_set_cmdlist and remote_show_cmdlist given
6617 as argument, not the address of an argument.
6618 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
6619 * gdb/remote.c (_initialize_remote): Likewise.
6620
6621 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6622
6623 * cli/cli-cmds.c (alias_command): Check for an existing alias
6624 using lookup_cmd_composition, as valid_command_p is too strict
6625 and forbids aliases that are the prefix of an existing alias
6626 or command.
6627 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
6628 command is properly recognised as a valid command.
6629
6630 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6631
6632 * unittests/help-doc-selftests.c: Rename to
6633 unittests/command-def-selftests.c
6634 * unittests/command-def-selftests.c (help_doc_tests): Update some
6635 comments.
6636 (command_structure_tests, traverse_command_structure): New namespace
6637 and function.
6638 (command_structure_invariants_tests): New function.
6639 (_initialize_command_def_selftests) Renamed from
6640 _initialize_help_doc_selftests, register command_structure_invariants
6641 selftest.
6642
6643 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6644
6645 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
6646 an alias of 'show'.
6647
6648 2020-05-15 Joel Brobecker <brobecker@adacore.com>
6649
6650 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
6651 ada_is_fixed_point_type. Update all callers.
6652 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
6653 all callers.
6654 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
6655 Update all callers.
6656 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
6657 print_fixed_point_type. Update all callers.
6658 * ada-valprint.c (ada_value_print_num): Replace call to
6659 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
6660
6661 2020-05-14 Kevin Buettner <kevinb@redhat.com>
6662
6663 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
6664 processors.
6665 (cpu_supports_bts): Add CV_AMD case.
6666
6667 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
6668 Simon Marchi <simon.marchi@efficios.com>
6669
6670 * infrun.c (stop_all_threads): Collect multiple wait events at
6671 each pass.
6672
6673 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
6674
6675 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
6676 type::code instead.
6677
6678 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
6679
6680 * gdbtypes.h (struct type) <code, set_code>: New methods.
6681 (TYPE_CODE): Use type::code. Change all call sites used to set
6682 the code to use type::set_code instead.
6683
6684 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6685 Tom de Vries <tdevries@suse.de>
6686 Pedro Alves <palves@redhat.com>
6687
6688 PR threads/25478
6689 * infrun.c (stop_all_threads): Do NOT ignore
6690 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
6691 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
6692 received.
6693 (handle_no_resumed): Remove code handling a live inferior with no
6694 threads.
6695 * remote.c (has_single_non_exited_thread): New.
6696 (remote_target::update_thread_list): Do not delete a thread if is
6697 the last thread of the process.
6698 * thread.c (thread_select): Call delete_exited_threads instead of
6699 prune_threads.
6700
6701 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6702
6703 * infrun.c (stop_all_threads): Enable/disable thread events of all
6704 targets. Move a debug message denoting the end of the function
6705 into the SCOPED_EXIT block.
6706
6707 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6708
6709 * process-stratum-target.h: Include <set>.
6710 (all_non_exited_process_targets, switch_to_target_no_thread): New
6711 function declarations.
6712 * process-stratum-target.c (all_non_exited_process_targets)
6713 (switch_to_target_no_thread): New function implementations.
6714
6715 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6716
6717 * infrun.c (handle_inferior_event): Extract out a piece of code
6718 into...
6719 (mark_non_executing_threads): ...this new function.
6720
6721 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6722
6723 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
6724 use.
6725
6726 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6727
6728 * regcache.c (regcache_read_pc_protected): New function
6729 implementation that returns 0 if the PC cannot read via
6730 'regcache_read_pc'.
6731 * infrun.c (proceed): Call 'regcache_read_pc_protected'
6732 instead of 'regcache_read_pc'.
6733 (keep_going_pass_signal): Ditto.
6734
6735 2020-05-13 Tom Tromey <tromey@adacore.com>
6736
6737 * ada-lang.c (align_value): Remove.
6738 (ada_template_to_fixed_record_type_1): Use align_up.
6739
6740 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6741
6742 * async-event.c: Update the copyright year.
6743 * async-event.h: Update the copyright year.
6744
6745 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
6746
6747 * objfiles.h (is_addr_in_objfile,
6748 shared_objfile_contains_address_p): Return bool.
6749 * objfile.c (is_addr_in_objfile,
6750 shared_objfile_contains_address_p): Return bool.
6751
6752 2020-05-11 Tom Tromey <tromey@adacore.com>
6753
6754 * cli/cli-cmds.c (info_command): Restore.
6755 (_initialize_cli_cmds): Use add_prefix_command for "info".
6756 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
6757
6758 2020-05-11 Tom Tromey <tromey@adacore.com>
6759
6760 * ada-lang.c (ada_value_primitive_field): Now public.
6761 * ada-lang.h (ada_value_primitive_field): Declare.
6762 * ada-valprint.c (print_field_values): Use
6763 ada_value_primitive_field for wrapper fields.
6764
6765 2020-05-11 Tom de Vries <tdevries@suse.de>
6766
6767 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
6768 MODULE_DOMAIN.
6769
6770 2020-05-11 Tom de Vries <tdevries@suse.de>
6771
6772 PR symtab/25941
6773 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
6774 with length 0, if not gdb-produced.
6775 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
6776
6777 2020-05-09 Tom de Vries <tdevries@suse.de>
6778
6779 PR gdb/25955
6780 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
6781 calculation.
6782
6783 2020-05-09 Tom Tromey <tom@tromey.com>
6784
6785 * top.c (server_command): Now bool.
6786 * top.h (server_command): Now bool.
6787
6788 2020-05-08 Tom Tromey <tromey@adacore.com>
6789
6790 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
6791 already being processed.
6792
6793 2020-05-08 Tom Tromey <tom@tromey.com>
6794
6795 * printcmd.c (struct display) <next>: Remove.
6796 <display>: New constructor.
6797 <exp_string>: Now a std::string.
6798 <enabled_p>: Now a bool.
6799 (display_number): Move definition earlier.
6800 (displays): Rename from display_chain. Now a std::vector.
6801 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
6802 (display_command): Update.
6803 (do_one_display, disable_display)
6804 (enable_disable_display_command, do_enable_disable_display):
6805 Update.
6806 (free_display): Remove.
6807 (clear_displays): Rewrite.
6808 (delete_display): Update.
6809 (map_display_numbers): Use function_view. Remove "data"
6810 parameter. Update.
6811 (do_delete_display): Remove.
6812 (undisplay_command): Update.
6813 (do_one_display, do_displays, disable_display)
6814 (info_display_command): Update.
6815 (do_enable_disable_display): Remove.
6816 (enable_disable_display_command)
6817 (clear_dangling_display_expressions): Update.
6818
6819 2020-05-08 Tom Tromey <tom@tromey.com>
6820
6821 * symtab.c (set_symbol_cache_size)
6822 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
6823 (maintenance_print_symbol_cache_statistics): Update.
6824 * symmisc.c (print_symbol_bcache_statistics)
6825 (print_objfile_statistics, maintenance_print_objfiles)
6826 (maintenance_info_symtabs, maintenance_check_symtabs)
6827 (maintenance_expand_symtabs, maintenance_info_line_tables):
6828 Update.
6829 * symfile-debug.c (set_debug_symfile): Update.
6830 * source.c (forget_cached_source_info): Update.
6831 * python/python.c (gdbpy_progspaces): Update.
6832 * psymtab.c (maintenance_info_psymtabs): Update.
6833 * probe.c (parse_probes): Update.
6834 * linespec.c (iterate_over_all_matching_symtabs)
6835 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
6836 * guile/scm-progspace.c (gdbscm_progspaces): Update.
6837 * exec.c (exec_target::close): Update.
6838 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
6839 * breakpoint.c (print_one_breakpoint_location)
6840 (create_longjmp_master_breakpoint)
6841 (create_std_terminate_master_breakpoint): Update.
6842 * progspace.c (program_spaces): Now a std::vector.
6843 (maybe_new_address_space): Update.
6844 (add_program_space): Remove.
6845 (program_space::program_space): Update.
6846 (remove_program_space): Update.
6847 (number_of_program_spaces): Remove.
6848 (print_program_space, update_address_spaces): Update.
6849 * progspace.h (program_spaces): Change type.
6850 (ALL_PSPACES): Remove.
6851 (number_of_program_spaces): Don't declare.
6852 (struct program_space) <next>: Remove.
6853
6854 2020-05-08 Tom Tromey <tom@tromey.com>
6855
6856 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
6857 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
6858 (enable_break): Update.
6859 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
6860 (frv_fdpic_find_canonical_descriptor): Update.
6861 (frv_fetch_objfile_link_map): Update.
6862 * progspace.c (program_space::free_all_objfiles): Update.
6863 (program_space::solibs): New method.
6864 * progspace.h (struct program_space) <solibs>: New method.
6865 * solist.h (master_so_list): Don't declare.
6866 (ALL_SO_LIBS): Remove.
6867 * solib.h (so_list_head): Remove.
6868 (update_solib_list): Update comment.
6869 * solib.c (master_so_list): Remove.
6870 (solib_used, update_solib_list, solib_add)
6871 (info_sharedlibrary_command, clear_solib)
6872 (reload_shared_libraries_1, remove_user_added_objfile): Update.
6873
6874 2020-05-08 Tom Tromey <tom@tromey.com>
6875
6876 * extension.c (extension_languages): Now a std::array.
6877 (ALL_EXTENSION_LANGUAGES): Remove.
6878 (get_ext_lang_defn, get_ext_lang_of_file)
6879 (eval_ext_lang_from_control_command): Update.
6880 (finish_ext_lang_initialization)
6881 (auto_load_ext_lang_scripts_for_objfile)
6882 (ext_lang_type_printers::ext_lang_type_printers)
6883 (apply_ext_lang_type_printers)
6884 (ext_lang_type_printers::~ext_lang_type_printers)
6885 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
6886 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
6887 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
6888 (get_matching_xmethod_workers, ext_lang_colorize)
6889 (ext_lang_before_prompt): Update.
6890 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
6891
6892 2020-05-08 Tom Tromey <tom@tromey.com>
6893
6894 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
6895 overload.
6896 <swap_string, m_string>: Remove.
6897 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
6898 Update.
6899 * stabsread.c (define_symbol, read_type): Update.
6900 * linespec.c (find_linespec_symbols): Update.
6901 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
6902 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
6903 * dbxread.c (read_dbx_symtab): Update.
6904 * cp-support.h (cp_canonicalize_string_full)
6905 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
6906 Return unique_xmalloc_ptr.
6907 * cp-support.c (inspect_type): Update.
6908 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
6909 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
6910 Likewise.
6911 * c-typeprint.c (print_name_maybe_canonical): Update.
6912 * break-catch-throw.c (check_status_exception_catchpoint):
6913 Update.
6914
6915 2020-05-08 Tom de Vries <tdevries@suse.de>
6916
6917 * infrun.c (follow_fork): Copy current_line and current_symtab to
6918 child thread.
6919
6920 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
6921
6922 * async-event.c (struct async_signal_handler, struct
6923 async_event_handler): Reformat, remove typedef.
6924
6925 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
6926
6927 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
6928 access thistype->main_type->dyn_prop_list directly.
6929
6930 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
6931
6932 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
6933 (remove_dyn_prop): Remove. Update all users to use
6934 type::remove_dyn_prop.
6935 * gdbtypes.c (remove_dyn_prop): Rename to...
6936 (type::remove_dyn_prop): ... this.
6937
6938 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
6939
6940 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
6941 (add_dyn_prop): Remove. Update all users to use
6942 type::add_dyn_prop.
6943 * gdbtypes.c (add_dyn_prop): Rename to...
6944 (type::add_dyn_prop): ... this.
6945
6946 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
6947
6948 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
6949 (get_dyn_prop): Remove. Update all users to use
6950 type::dyn_prop.
6951 * gdbtypes.c (get_dyn_prop): Rename to...
6952 (type::dyn_prop): ... this.
6953
6954 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
6955
6956 * gdbtypes.h (struct main_type) <flag_static>: Remove.
6957
6958 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
6959
6960 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
6961 instruction, skip it if it's there.
6962
6963 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
6964
6965 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
6966
6967 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
6968
6969 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
6970 * gdbtypes.c (recursive_dump_type): Remove use of
6971 TYPE_INCOMPLETE.
6972
6973 2020-05-03 Tom Tromey <tom@tromey.com>
6974
6975 * breakpoint.c (catch_command, tcatch_command): Remove.
6976 (_initialize_breakpoint): Use add_basic_prefix_cmd,
6977 add_show_prefix_cmd.
6978 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
6979 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
6980 Remove.
6981 (add_internal_problem_command): Use add_basic_prefix_cmd,
6982 add_show_prefix_cmd.
6983 * mips-tdep.c (set_mipsfpu_command): Remove.
6984 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
6985 * dwarf2/index-cache.c (set_index_cache_command): Remove.
6986 (_initialize_index_cache): Use add_basic_prefix_cmd.
6987 * memattr.c (dummy_cmd): Remove.
6988 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
6989 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
6990 (_initialize_tui_win): Use add_basic_prefix_cmd,
6991 add_show_prefix_cmd.
6992 * cli/cli-logging.c (set_logging_command): Remove.
6993 (_initialize_cli_logging): Use add_basic_prefix_cmd,
6994 add_show_prefix_cmd.
6995 (show_logging_command): Remove.
6996 * target.c (target_command): Remove.
6997 (add_target): Use add_basic_prefix_cmd.
6998
6999 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
7000
7001 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
7002
7003 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7004
7005 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
7006 info_command.
7007
7008 2020-04-30 Kamil Rytarowski <n54@gmx.com>
7009
7010 * nbsd-nat.c (nbsd_enable_proc_events)
7011 (nbsd_nat_target::post_startup_inferior): Add.
7012 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
7013 (nbsd_nat_target::update_thread_list): Rewrite.
7014 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
7015 "PTRACE_LWP_CREATE".
7016 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
7017
7018 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7019
7020 * stack.c (_initialize_stack): Remove duplicated creation
7021 of "frame" command and "f" alias.
7022
7023 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
7024
7025 PR gdb/18706
7026 * gdbtypes.c (check_typedef): Calculate size of array of
7027 stubbed type.
7028
7029 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
7030
7031 PR gdb/15559
7032 * i386-tdep.c (i386_push_dummy_call): Call
7033 i386_thiscall_push_dummy_call.
7034 (i386_thiscall_push_dummy_call): New function.
7035 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
7036 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
7037 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
7038
7039 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7040
7041 * gdbarch.sh (do_read): Add shellcheck disable directive for
7042 warning SC2162.
7043
7044 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7045
7046 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
7047 "referenced but not assigned" warning.
7048
7049 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7050
7051 * gdbarch.sh: Remove code that sets fallbackdefault.
7052
7053 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7054
7055 * gdbarch.sh: Use shell operators && and || instead of
7056 -a and -o.
7057
7058 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7059
7060 * gdbarch.sh: Use $(...) instead of `...`.
7061
7062 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7063
7064 * gdbarch.sh: Use double quotes around variables.
7065
7066 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
7067
7068 * gdbarch.sh: Use %s with printf, instead of variables in the
7069 format string.
7070
7071 2020-04-29 Tom Tromey <tromey@adacore.com>
7072
7073 PR ada/25875:
7074 * dwarf2/read.c (update_enumeration_type_from_children): Compute
7075 type fields here.
7076 (read_enumeration_type): Call
7077 update_enumeration_type_from_children later. Update comments.
7078 (process_enumeration_scope): Don't create type fields.
7079
7080 2020-04-29 Kamil Rytarowski <n54@gmx.com>
7081
7082 * nbsd-tdep.c: Include "xml-syscall.h".
7083 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
7084
7085 2020-04-29 Kamil Rytarowski <n54@gmx.com>
7086
7087 * nbsd-nat.c: Include "sys/wait.h".
7088 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
7089 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
7090 (nbsd_nat_target::remove_exec_catchpoint)
7091 (nbsd_nat_target::set_syscall_catchpoint): Add.
7092 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
7093 (nbsd_nat_target::insert_exec_catchpoint)
7094 (nbsd_nat_target::remove_exec_catchpoint)
7095 (nbsd_nat_target::set_syscall_catchpoint): Add.
7096 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
7097 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
7098 `nbsd_get_syscall_number'.
7099
7100 2020-04-29 Tom Tromey <tom@tromey.com>
7101
7102 * stack.c (print_block_frame_labels): Remove.
7103
7104 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
7105
7106 PR gdb/17320
7107 * ada-valprint.c (val_print_packed_array_elements): Move array
7108 end bracket to new line.
7109 (ada_val_print_string): Remove extra spaces before first array
7110 element.
7111 * c-valprint.c (c_value_print_array): Likewise.
7112 * m2-valprint.c (m2_print_array_contents): Likewise.
7113 (m2_value_print_inner): Likewise.
7114 * p-valprint.c (pascal_value_print_inner): Likewise.
7115 * valprint.c (generic_val_print_array): Likewise.
7116 (value_print_array_elements): Move first array element and array
7117 end bracket to new line.
7118
7119 2020-04-29 Tom de Vries <tdevries@suse.de>
7120
7121 PR symtab/25889
7122 * linespec.c (find_method): Fix ix calculation.
7123
7124 2020-04-28 Kamil Rytarowski <n54@gmx.com>
7125
7126 * syscalls/update-netbsd.sh: New file.
7127 * syscalls/netbsd.xml: Regenerate.
7128 * data-directory/Makefile.in: Register `netbsd.xml' in
7129 `SYSCALLS_FILES'.
7130
7131 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
7132
7133 * syscalls/update-freebsd.sh: Add double quotes.
7134
7135 2020-04-28 Tom Tromey <tom@tromey.com>
7136
7137 * NEWS: Update.
7138 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
7139 (cmdpy_init): Allow class_tui.
7140
7141 2020-04-28 Mark Williams <mark@myosotissp.com>
7142
7143 PR gdb/24480
7144 * dwarf2read.c: Add missing assingments to list_in_scope when
7145 start_symtab was already called.
7146
7147 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
7148
7149 PR gdb/25881
7150 * dwarf2/read.c (offset_map_type): Use
7151 gdb:hash_enum<sect_offset> as hash function.
7152
7153 2020-04-28 Tom de Vries <tdevries@suse.de>
7154
7155 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
7156 with DW_AT_signature.
7157
7158 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
7159
7160 * configure.ac: Remove check for fs_base/gs_base in
7161 user_regs_struct.
7162 * configure: Re-generate.
7163 * config.in: Re-generate.
7164 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
7165 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
7166 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
7167
7168 2020-04-27 Luis Machado <luis.machado@linaro.org>
7169
7170 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
7171 problematic inline frame unwinding situation.
7172 * frame.c (frame_id_computed_p): New function.
7173 * frame.h (frame_id_computed_p): New prototype.
7174
7175 2020-04-26 Tom Tromey <tom@tromey.com>
7176
7177 * command.h (enum command_class) <class_pseudo>: Remove.
7178
7179 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7180
7181 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
7182 and whitespace.
7183
7184 2020-04-25 Kamil Rytarowski <n54@gmx.com>
7185
7186 * inf-ptrace.c (inf_ptrace_target::wait): Remove
7187 `PT_GET_PROCESS_STATE' block.
7188
7189 2020-04-24 Tom Tromey <tom@tromey.com>
7190
7191 * symtab.h (symbol_get_demangled_name): Don't declare.
7192 * symtab.c (symbol_get_demangled_name): Remove.
7193 (general_symbol_info::natural_name)
7194 (general_symbol_info::demangled_name): Update.
7195
7196 2020-04-24 Tom Tromey <tom@tromey.com>
7197
7198 PR rust/25025:
7199 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
7200
7201 2020-04-24 Tom Tromey <tom@tromey.com>
7202
7203 PR symtab/12707:
7204 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
7205 exists.
7206 (new_symbol): Likewise.
7207 * compile/compile-object-load.c (get_out_value_type): Use
7208 symbol_matches_search_name.
7209
7210 2020-04-24 Tom Tromey <tom@tromey.com>
7211
7212 * dwarf2/read.c (add_partial_symbol): Do not call
7213 compute_and_set_names.
7214
7215 2020-04-24 Tom Tromey <tom@tromey.com>
7216
7217 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
7218 overload.
7219
7220 2020-04-24 Tom Tromey <tom@tromey.com>
7221
7222 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
7223 (add_psymbol_to_list): New overload. Make old overload call new
7224 one.
7225 * psympriv.h (add_psymbol_to_list): New overload.
7226
7227 2020-04-24 Tom Tromey <tom@tromey.com>
7228
7229 * dwarf2/read.c (partial_die_info::read) <case
7230 DW_AT_linkage_name>: Use value_as_string.
7231 (dwarf2_string_attr): Use value_as_string.
7232 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
7233 method.
7234 * dwarf2/attribute.c (attribute::value_as_string): New method.
7235
7236 2020-04-24 Tom Tromey <tom@tromey.com>
7237
7238 * symtab.c (general_symbol_info::natural_name)
7239 (general_symbol_info::demangled_name): Check for language_rust.
7240
7241 2020-04-24 Tom Tromey <tom@tromey.com>
7242
7243 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
7244 (dwarf2_physname): ... from here.
7245 (partial_die_info::read): Add Rust "{" hack.
7246
7247 2020-04-24 Tom Tromey <tom@tromey.com>
7248
7249 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
7250 method.
7251 (symbol_set_demangled_name): Don't declare.
7252 * symtab.c (general_symbol_info::set_demangled_name): Rename from
7253 symbol_set_demangled_name.
7254 (general_symbol_info::set_language)
7255 (general_symbol_info::compute_and_set_names): Update.
7256 * minsyms.c (minimal_symbol_reader::install): Update.
7257 * dwarf2/read.c (new_symbol): Update.
7258
7259 2020-04-24 Tom Tromey <tromey@adacore.com>
7260
7261 PR python/23662:
7262 * python/py-type.c (convert_field): Handle
7263 FIELD_LOC_KIND_DWARF_BLOCK.
7264 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
7265 (typy_get_dynamic): Nw function.
7266 (type_object_getset): Add "dynamic".
7267 * NEWS: Add entry.
7268
7269 2020-04-24 Tom Tromey <tromey@adacore.com>
7270
7271 * ada-typeprint.c (print_choices, print_variant_part)
7272 (print_record_field_types_dynamic): New functions.
7273 (print_record_field_types): Use print_record_field_types_dynamic.
7274
7275 2020-04-24 Tom Tromey <tromey@adacore.com>
7276
7277 * dwarf2/read.c (handle_data_member_location): New overload.
7278 (dwarf2_add_field): Use it.
7279 (decode_locdesc): Add "computed" parameter. Update comment.
7280 * gdbtypes.c (is_dynamic_type_internal): Also look for
7281 FIELD_LOC_KIND_DWARF_BLOCK.
7282 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
7283 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
7284 virtual base classes.
7285 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
7286 FIELD_LOC_KIND_DWARF_BLOCK.
7287
7288 2020-04-24 Tom Tromey <tromey@adacore.com>
7289
7290 * dwarf2/read.c (read_structure_type): Handle dynamic length.
7291 * gdbtypes.c (is_dynamic_type_internal): Check
7292 TYPE_HAS_DYNAMIC_LENGTH.
7293 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
7294 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
7295 New macros.
7296 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
7297 constant.
7298
7299 2020-04-24 Tom Tromey <tromey@adacore.com>
7300
7301 * dwarf2/read.c (struct variant_field): Rewrite.
7302 (struct variant_part_builder): New.
7303 (struct nextfield): Remove "variant" field. Add "offset".
7304 (struct field_info): Add "current_variant_part" and
7305 "variant_parts".
7306 (alloc_discriminant_info): Remove.
7307 (alloc_rust_variant): New function.
7308 (quirk_rust_enum): Update.
7309 (dwarf2_add_field): Set "offset" member. Don't handle
7310 DW_TAG_variant_part.
7311 (offset_map_type): New typedef.
7312 (convert_variant_range, create_one_variant)
7313 (create_one_variant_part, create_variant_parts)
7314 (add_variant_property): New functions.
7315 (dwarf2_attach_fields_to_type): Call add_variant_property.
7316 (read_structure_type): Don't handle DW_TAG_variant_part.
7317 (handle_variant_part, handle_variant): New functions.
7318 (handle_struct_member_die): Use them.
7319 (process_structure_scope): Don't handle variant parts.
7320 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
7321 (struct discriminant_info): Remove.
7322 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
7323 (struct main_type) <flag_discriminated_union>: Remove.
7324 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
7325 (rust_enum_variant): Return int. Remove "contents". Rewrite.
7326 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
7327 Update.
7328 * valops.c (value_union_variant): Remove.
7329 * value.h (value_union_variant): Don't declare.
7330
7331 2020-04-24 Tom Tromey <tromey@adacore.com>
7332
7333 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
7334 (ada_value_primitive_packed_val): Update.
7335 * ada-valprint.c (ada_value_print_1): Update.
7336 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
7337 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
7338 just an address. Use evaluate_for_locexpr_baton.
7339 (dwarf2_evaluate_property): Update.
7340 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
7341 array_view.
7342 * findvar.c (default_read_var_value): Update.
7343 * gdbtypes.c (compute_variant_fields_inner)
7344 (resolve_dynamic_type_internal): Update.
7345 (resolve_dynamic_type): Change type of valaddr parameter.
7346 * gdbtypes.h (resolve_dynamic_type): Update.
7347 * valarith.c (value_subscripted_rvalue): Update.
7348 * value.c (value_from_contents_and_address): Update.
7349
7350 2020-04-24 Tom Tromey <tromey@adacore.com>
7351
7352 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
7353 "push_initial_value" parameter.
7354 (dwarf2_evaluate_property): Likewise.
7355 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
7356
7357 2020-04-24 Tom Tromey <tromey@adacore.com>
7358
7359 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
7360 (variant::matches, compute_variant_fields_recurse)
7361 (compute_variant_fields_inner, compute_variant_fields): New
7362 functions.
7363 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
7364 Use resolved_type after type is made.
7365 (operator==): Add new cases.
7366 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
7367 (struct discriminant_range, struct variant, struct variant_part):
7368 New.
7369 (union dynamic_prop_data) <variant_parts, original_type>: New
7370 members.
7371 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
7372 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
7373 constants.
7374 * value.c (unpack_bits_as_long): Now public.
7375 * value.h (unpack_bits_as_long): Declare.
7376
7377 2020-04-24 Tom Tromey <tromey@adacore.com>
7378
7379 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
7380 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
7381
7382 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
7383
7384 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
7385
7386 2020-04-24 Kamil Rytarowski <n54@gmx.com>
7387
7388 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
7389 (remove_fork_catchpoint, post_startup_inferior)
7390 (post_attach): Move...
7391 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
7392 (remove_fork_catchpoint, post_startup_inferior)
7393 (post_attach): ...here.
7394 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
7395 (remove_fork_catchpoint, post_startup_inferior)
7396 (post_attach): Move...
7397 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
7398 (remove_fork_catchpoint, post_startup_inferior)
7399 (post_attach): ...here.
7400
7401 2020-04-24 Tom Tromey <tromey@adacore.com>
7402
7403 * nat/windows-nat.h (struct windows_thread_info)
7404 <pc_adjusted>: New member.
7405 * windows-nat.c (windows_fetch_one_register): Check
7406 pc_adjusted.
7407 (windows_nat_target::get_windows_debug_event)
7408 (windows_nat_target::wait): Set pc_adjusted.
7409
7410 2020-04-24 Tom de Vries <tdevries@suse.de>
7411
7412 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
7413 Run gdb-add-index inside temp dir.
7414
7415 2020-04-23 Tom Tromey <tromey@adacore.com>
7416
7417 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
7418 in loop.
7419
7420 2020-04-23 Luis Machado <luis.machado@linaro.org>
7421
7422 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
7423 get_frame_register instead of gdbarch_unwind_pc.
7424
7425 2020-04-23 Tom de Vries <tdevries@suse.de>
7426
7427 * symtab.c (lookup_global_symbol): Prefer def over decl.
7428
7429 2020-04-23 Tom de Vries <tdevries@suse.de>
7430
7431 PR symtab/25807
7432 * block.c (best_symbol, better_symbol): Promote to external.
7433 * block.h (best_symbol, better_symbol): Declare.
7434 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
7435 decl.
7436
7437 2020-04-23 Tom Tromey <tromey@adacore.com>
7438
7439 PR ada/25837:
7440 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
7441 "const char *", not a "const std::string &".
7442 <name_and_matcher::operator==>: Update.
7443 * unittests/lookup_name_info-selftests.c: Change type of
7444 "result".
7445
7446 2020-04-23 Tom Tromey <tom@tromey.com>
7447
7448 * inferior.h (iterate_over_inferiors): Don't declare.
7449 * inferior.c (iterate_over_inferiors): Remove.
7450 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
7451 Remove.
7452 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
7453 use iterate_over_inferiors.
7454 (darwin_resume_inferior_it)
7455 (struct resume_inferior_threads_param)
7456 (darwin_resume_inferior_threads_it): Remove.
7457 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
7458
7459 2020-04-23 Tom de Vries <tdevries@suse.de>
7460
7461 * blockframe.c (find_pc_partial_function): Use
7462 find_pc_sect_compunit_symtab rather than
7463 objfile->sf->qf->find_pc_sect_compunit_symtab.
7464
7465 2020-04-22 Tom de Vries <tdevries@suse.de>
7466
7467 PR symtab/25764
7468 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
7469 in psymtabs.
7470
7471 2020-04-22 Tom de Vries <tdevries@suse.de>
7472
7473 PR symtab/25801
7474 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
7475 symtabs.
7476
7477 2020-04-22 Tom de Vries <tdevries@suse.de>
7478
7479 PR symtab/25700
7480 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
7481 CU if already created.
7482
7483 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7484
7485 * infrun.c (displaced_step_fixup): Switch to the event_thread
7486 before calling displaced_step_restore, not after.
7487
7488 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
7489
7490 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
7491 its inferior is not recorded by us.
7492 (record_btrace_target_open): Replace call to
7493 all_non_exited_threads () with call to current_inferior
7494 ()->non_exited_threads ().
7495 (record_btrace_target::stop_recording): Likewise.
7496 (record_btrace_target::close): Likewise.
7497 (record_btrace_target::wait): Likewise.
7498 (record_btrace_target::record_stop_replaying): Likewise.
7499
7500 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
7501
7502 * btrace.c (btrace_enable): Throw an error on double enables and
7503 when enabling recording fails.
7504 (btrace_disable): Throw an error if the thread is not recorded.
7505
7506 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
7507
7508 * record-btrace.c (record_btrace_target::fetch_registers): Forward
7509 request if we do not have a thread_info.
7510
7511 2020-04-21 Tom de Vries <tdevries@suse.de>
7512
7513 PR gdb/25471
7514 * thread.c
7515 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
7516 exception in get_frame_id.
7517
7518 2020-04-20 Tom Tromey <tromey@adacore.com>
7519
7520 * python/python.c (struct gdbpy_event): Mark move constructor as
7521 noexcept.
7522 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
7523 constructor as noexcept.
7524 * completer.h (struct completion_result): Mark move constructor as
7525 noexcept.
7526 * completer.c (completion_result::completion_result): Use
7527 initialization style. Don't call reset_match_list.
7528
7529 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
7530
7531 * MAINTAINERS (Write After Approval): Add myself.
7532
7533 2020-04-18 Tom Tromey <tom@tromey.com>
7534
7535 * windows-tdep.c (init_w32_command_list)
7536 (w32_prefix_command_valid): Restore.
7537 (_initialize_windows_tdep): Call init_w32_command_list.
7538
7539 2020-04-18 Tom Tromey <tom@tromey.com>
7540
7541 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
7542 * value.c (value_fn_field): Update.
7543 * valops.c (find_function_in_inferior)
7544 (value_allocate_space_in_inferior): Update.
7545 * tui/tui-winsource.c (tui_update_source_windows_with_line):
7546 Update.
7547 * tui/tui-source.c (tui_source_window::set_contents): Update.
7548 * symtab.c (lookup_global_or_static_symbol)
7549 (find_function_start_sal_1, skip_prologue_sal)
7550 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
7551 * symmisc.c (dump_msymbols, dump_symtab_1)
7552 (maintenance_print_one_line_table): Update.
7553 * symfile.c (init_entry_point_info, section_is_mapped)
7554 (list_overlays_command, simple_read_overlay_table)
7555 (simple_overlay_update_1): Update.
7556 * stap-probe.c (handle_stap_probe): Update.
7557 * stabsread.c (dbx_init_float_type, define_symbol)
7558 (read_one_struct_field, read_enum_type, read_range_type): Update.
7559 * source.c (info_line_command): Update.
7560 * python/python.c (gdbpy_source_objfile_script)
7561 (gdbpy_execute_objfile_script): Update.
7562 * python/py-type.c (save_objfile_types): Update.
7563 * python/py-objfile.c (py_free_objfile): Update.
7564 * python/py-inferior.c (python_new_objfile): Update.
7565 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
7566 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
7567 (maintenance_check_psymtabs): Update.
7568 * printcmd.c (info_address_command): Update.
7569 * objfiles.h (struct objfile) <arch>: New method, from
7570 get_objfile_arch.
7571 (get_objfile_arch): Don't declare.
7572 * objfiles.c (get_objfile_arch): Remove.
7573 (filter_overlapping_sections): Update.
7574 * minsyms.c (msymbol_is_function): Update.
7575 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
7576 (output_nondebug_symbol): Update.
7577 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
7578 (mdebug_expand_psymtab): Update.
7579 * machoread.c (macho_add_oso_symfile): Update.
7580 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
7581 Update.
7582 * linux-fork.c (checkpoint_command): Update.
7583 * linespec.c (convert_linespec_to_sals): Update.
7584 * jit.c (finalize_symtab): Update.
7585 * infrun.c (insert_exception_resume_from_probe): Update.
7586 * ia64-tdep.c (ia64_find_unwind_table): Update.
7587 * hppa-tdep.c (internalize_unwinds): Update.
7588 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
7589 Update.
7590 * gcore.c (call_target_sbrk): Update.
7591 * elfread.c (record_minimal_symbol, elf_symtab_read)
7592 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
7593 (elf_gnu_ifunc_resolve_by_got): Update.
7594 * dwarf2/read.c (create_addrmap_from_index)
7595 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
7596 (read_debug_names_from_section)
7597 (process_psymtab_comp_unit_reader, add_partial_symbol)
7598 (add_partial_subprogram, process_full_comp_unit)
7599 (read_file_scope, read_func_scope, read_lexical_block_scope)
7600 (read_call_site_scope, dwarf2_ranges_read)
7601 (dwarf2_record_block_ranges, dwarf2_add_field)
7602 (mark_common_block_symbol_computed, read_tag_pointer_type)
7603 (read_tag_string_type, dwarf2_init_float_type)
7604 (dwarf2_init_complex_target_type, read_base_type)
7605 (partial_die_info::read, partial_die_info::read)
7606 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
7607 (dwarf2_fetch_die_loc_sect_off): Update.
7608 * dwarf2/loc.c (dwarf2_find_location_expression)
7609 (class dwarf_evaluate_loc_desc, rw_pieced_value)
7610 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
7611 (dwarf2_loc_desc_get_symbol_read_needs)
7612 (locexpr_describe_location_piece, locexpr_describe_location_1)
7613 (loclist_describe_location): Update.
7614 * dwarf2/index-write.c (write_debug_names): Update.
7615 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
7616 * dtrace-probe.c (dtrace_process_dof): Update.
7617 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
7618 (process_one_symbol): Update.
7619 * ctfread.c (ctf_init_float_type, read_base_type): Update.
7620 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
7621 (coff_read_enum_type): Update.
7622 * cli/cli-cmds.c (edit_command, list_command): Update.
7623 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
7624 * breakpoint.c (create_overlay_event_breakpoint)
7625 (create_longjmp_master_breakpoint)
7626 (create_std_terminate_master_breakpoint)
7627 (create_exception_master_breakpoint, get_sal_arch): Update.
7628 * block.c (block_gdbarch): Update.
7629 * annotate.c (annotate_source_line): Update.
7630
7631 2020-04-17 Tom Tromey <tromey@adacore.com>
7632
7633 * auto-load.c (show_auto_load_cmd): Remove.
7634 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
7635 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
7636 (maintenance_print_arc_command): Remove.
7637 * tui/tui-win.c (tui_command): Remove.
7638 (tui_get_cmd_list): Use add_basic_prefix_cmd.
7639 * tui/tui-layout.c (tui_layout_command): Remove.
7640 (_initialize_tui_layout): Use add_basic_prefix_cmd.
7641 * python/python.c (user_set_python, user_show_python): Remove.
7642 (_initialize_python): Use add_basic_prefix_cmd,
7643 add_show_prefix_cmd.
7644 * guile/guile.c (set_guile_command, show_guile_command): Remove.
7645 (install_gdb_commands): Use add_basic_prefix_cmd,
7646 add_show_prefix_cmd.
7647 (info_guile_command): Remove.
7648 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
7649 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
7650 add_show_prefix_cmd.
7651 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
7652 Remove do_set and do_show parameters.
7653 * cli/cli-style.c (set_style, show_style): Remove.
7654 (_initialize_cli_style): Use add_basic_prefix_cmd,
7655 add_show_prefix_cmd.
7656 (cli_style_option::add_setshow_commands): Remove do_set and
7657 do_show parameters.
7658 (cli_style_option::add_setshow_commands): Use
7659 add_basic_prefix_cmd, add_show_prefix_cmd.
7660 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
7661 (set_style_name): Remove.
7662 * cli/cli-dump.c (dump_command, append_command): Remove.
7663 (srec_dump_command, ihex_dump_command, verilog_dump_command)
7664 (tekhex_dump_command, binary_dump_command)
7665 (binary_append_command): Remove.
7666 (_initialize_cli_dump): Use add_basic_prefix_cmd.
7667 * windows-tdep.c (w32_prefix_command_valid): Remove global.
7668 (init_w32_command_list): Remove; move into ...
7669 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
7670 * valprint.c (set_print, show_print, set_print_raw)
7671 (show_print_raw): Remove.
7672 (_initialize_valprint): Use add_basic_prefix_cmd,
7673 add_show_prefix_cmd.
7674 * typeprint.c (set_print_type, show_print_type): Remove.
7675 (_initialize_typeprint): Use add_basic_prefix_cmd,
7676 add_show_prefix_cmd.
7677 * record.c (set_record_command, show_record_command): Remove.
7678 (_initialize_record): Use add_basic_prefix_cmd,
7679 add_show_prefix_cmd.
7680 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
7681 add_show_prefix_cmd.
7682 (info_command, show_command, set_debug, show_debug): Remove.
7683 * top.h (set_history, show_history): Don't declare.
7684 * top.c (set_history, show_history): Remove.
7685 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
7686 (unset_tdesc_cmd): Remove.
7687 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
7688 add_show_prefix_cmd.
7689 * symtab.c (info_module_command): Remove.
7690 (_initialize_symtab): Use add_basic_prefix_cmd.
7691 * symfile.c (overlay_command): Remove.
7692 (_initialize_symfile): Use add_basic_prefix_cmd.
7693 * sparc64-tdep.c (info_adi_command): Remove.
7694 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
7695 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
7696 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
7697 add_show_prefix_cmd.
7698 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
7699 (_initialize_serial): Use add_basic_prefix_cmd,
7700 add_show_prefix_cmd.
7701 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
7702 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
7703 add_show_prefix_cmd.
7704 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
7705 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
7706 add_show_prefix_cmd.
7707 * riscv-tdep.c (show_riscv_command, set_riscv_command)
7708 (show_debug_riscv_command, set_debug_riscv_command): Remove.
7709 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
7710 add_show_prefix_cmd.
7711 * remote.c (remote_command, set_remote_cmd): Remove.
7712 (_initialize_remote): Use add_basic_prefix_cmd.
7713 * record-full.c (set_record_full_command)
7714 (show_record_full_command): Remove.
7715 (_initialize_record_full): Use add_basic_prefix_cmd,
7716 add_show_prefix_cmd.
7717 * record-btrace.c (cmd_set_record_btrace)
7718 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
7719 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
7720 (cmd_show_record_btrace_pt): Remove.
7721 (_initialize_record_btrace): Use add_basic_prefix_cmd,
7722 add_show_prefix_cmd.
7723 * ravenscar-thread.c (set_ravenscar_command)
7724 (show_ravenscar_command): Remove.
7725 (_initialize_ravenscar): Use add_basic_prefix_cmd,
7726 add_show_prefix_cmd.
7727 * mips-tdep.c (show_mips_command, set_mips_command)
7728 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
7729 add_show_prefix_cmd.
7730 * maint.c (maintenance_command, maintenance_info_command)
7731 (maintenance_check_command, maintenance_print_command)
7732 (maintenance_set_cmd, maintenance_show_cmd): Remove.
7733 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
7734 add_show_prefix_cmd.
7735 (show_per_command_cmd): Remove.
7736 * maint-test-settings.c (maintenance_set_test_settings_cmd):
7737 Remove.
7738 (maintenance_show_test_settings_cmd): Remove.
7739 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
7740 add_show_prefix_cmd.
7741 * maint-test-options.c (maintenance_test_options_command):
7742 Remove.
7743 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
7744 * macrocmd.c (macro_command): Remove
7745 (_initialize_macrocmd): Use add_basic_prefix_cmd.
7746 * language.c (set_check, show_check): Remove.
7747 (_initialize_language): Use add_basic_prefix_cmd,
7748 add_show_prefix_cmd.
7749 * infcmd.c (unset_command): Remove.
7750 (_initialize_infcmd): Use add_basic_prefix_cmd.
7751 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
7752 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
7753 add_show_prefix_cmd.
7754 * go32-nat.c (go32_info_dos_command): Remove.
7755 (_initialize_go32_nat): Use add_basic_prefix_cmd.
7756 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
7757 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
7758 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
7759 (_initialize_frame): Use add_basic_prefix_cmd,
7760 add_show_prefix_cmd.
7761 * dcache.c (set_dcache_command, show_dcache_command): Remove.
7762 (_initialize_dcache): Use add_basic_prefix_cmd,
7763 add_show_prefix_cmd.
7764 * cp-support.c (maint_cplus_command): Remove.
7765 (_initialize_cp_support): Use add_basic_prefix_cmd.
7766 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
7767 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
7768 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
7769 add_basic_prefix_cmd, add_show_prefix_cmd.
7770 * breakpoint.c (save_command): Remove.
7771 (_initialize_breakpoint): Use add_basic_prefix_cmd.
7772 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
7773 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
7774 add_show_prefix_cmd.
7775 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
7776 (set_ada_command, show_ada_command): Remove.
7777 (_initialize_ada_language): Use add_basic_prefix_cmd,
7778 add_show_prefix_cmd.
7779 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
7780
7781 2020-04-16 Kamil Rytarowski <n54@gmx.com>
7782
7783 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
7784 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
7785
7786 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
7787
7788 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
7789 warning messages.
7790
7791 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
7792
7793 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
7794 import table is not at beginning of .idata section.
7795
7796 2020-04-16 Pedro Alves <palves@redhat.com>
7797
7798 * inferior.c (delete_inferior): Use delete operator directly
7799 instead of delete_program_space.
7800 * progspace.c (add_program_space): New, factored out from
7801 program_space::program_space.
7802 (remove_program_space): New, factored out from
7803 delete_program_space.
7804 (program_space::program_space): Remove intro comment. Rewrite.
7805 (program_space::~program_space): Remove intro comment. Call
7806 remove_program_space.
7807 (delete_program_space): Delete.
7808 * progspace.h (program_space::program_space): Make explicit. Move
7809 intro comment here, adjusted.
7810 (program_space::~program_space): Move intro comment here,
7811 adjusted.
7812 (delete_program_space): Remove.
7813
7814 2020-04-16 Tom Tromey <tromey@adacore.com>
7815
7816 * windows-nat.c (windows_nat::handle_access_violation): New
7817 function.
7818 * nat/windows-nat.h (handle_access_violation): Declare.
7819 * nat/windows-nat.c (handle_exception): Move Cygwin code to
7820 windows-nat.c. Call handle_access_violation.
7821
7822 2020-04-16 Tom de Vries <tdevries@suse.de>
7823
7824 PR symtab/25791
7825 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
7826 CUs without psymtab.
7827
7828 2020-04-16 Kevin Buettner <kevinb@redhat.com>
7829
7830 * python/python.c (do_start_initialization): Don't call
7831 PyEval_InitThreads for Python 3.9 and beyond.
7832
7833 2020-04-15 Kamil Rytarowski <n54@gmx.com>
7834
7835 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
7836 thread functions.
7837 (obsd_nat_target::wait): Likewise.
7838
7839 2020-04-15 Tom Tromey <tromey@adacore.com>
7840
7841 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
7842 (DEBUG_EXCEPT): Use debug_printf.
7843
7844 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
7845
7846 * completer.c (class completion_tracker::completion_hash_entry)
7847 <hash_name>: New member function.
7848 (completion_tracker::discard_completions): New callback to hash a
7849 completion_hash_entry, pass this to htab_create_alloc.
7850
7851 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
7852
7853 * windows-nat.c (windows_make_so): Warn rather than stopping with
7854 an error if realpath() fails.
7855
7856 2020-04-14 Kamil Rytarowski <n54@gmx.com>
7857
7858 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
7859 (nbsd_nat_target::info_proc): Add do_status.
7860
7861 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
7862 Tom de Vries <tdevries@suse.de>
7863
7864 PR symtab/25718
7865 * psympriv.h (struct partial_symtab::read_symtab)
7866 (struct partial_symtab::expand_psymtab)
7867 (struct partial_symtab::read_dependencies): Update comments.
7868 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
7869 read_symtab for includer.
7870 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
7871 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
7872 (struct dwarf2_include_psymtab::m_readin): Remove.
7873 (struct dwarf2_include_psymtab::includer): New member function.
7874 (dwarf2_psymtab::expand_psymtab): Assert !readin.
7875
7876 2020-04-14 Tom de Vries <tdevries@suse.de>
7877
7878 PR symtab/25720
7879 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
7880 with NULL symbol_matcher and lookup_name.
7881 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
7882 and lookup_name.
7883 * dwarf2/read.c (dw2_expand_symtabs_matching)
7884 (dw2_debug_names_expand_symtabs_matching): Same.
7885 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
7886 Make lookup_name a pointer. Update comment.
7887 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
7888 lookup_name being a pointer.
7889 * symfile.c (expand_symtabs_matching): Same.
7890 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
7891 * linespec.c (iterate_over_all_matching_symtabs): Same.
7892
7893 2020-04-13 Tom Tromey <tom@tromey.com>
7894
7895 * run-on-main-thread.c: Update include.
7896 * unittests/main-thread-selftests.c: Update include.
7897 * tui/tui-win.c: Update include.
7898 * tui/tui-io.c: Update include.
7899 * tui/tui-interp.c: Update include.
7900 * tui/tui-hooks.c: Update include.
7901 * top.h: Update include.
7902 * top.c: Update include.
7903 * ser-base.c: Update include.
7904 * remote.c: Update include.
7905 * remote-notif.c: Update include.
7906 * remote-fileio.c: Update include.
7907 * record-full.c: Update include.
7908 * record-btrace.c: Update include.
7909 * python/python.c: Update include.
7910 * posix-hdep.c: Update include.
7911 * mingw-hdep.c: Update include.
7912 * mi/mi-main.c: Update include.
7913 * mi/mi-interp.c: Update include.
7914 * main.c: Update include.
7915 * linux-nat.c: Update include.
7916 * interps.c: Update include.
7917 * infrun.c: Update include.
7918 * inf-loop.c: Update include.
7919 * event-top.c: Update include.
7920 * event-loop.c: Move to ../gdbsupport/.
7921 * event-loop.h: Move to ../gdbsupport/.
7922 * async-event.h: Update include.
7923 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
7924
7925 2020-04-13 Tom Tromey <tom@tromey.com>
7926
7927 * tui/tui-win.c: Include async-event.h.
7928 * remote.c: Include async-event.h.
7929 * remote-notif.c: Include async-event.h.
7930 * record-full.c: Include async-event.h.
7931 * record-btrace.c: Include async-event.h.
7932 * infrun.c: Include async-event.h.
7933 * event-top.c: Include async-event.h.
7934 * event-loop.h: Move some declarations to async-event.h.
7935 * event-loop.c: Don't include ser-event.h or top.h. Move some
7936 code to async-event.c.
7937 * async-event.h: New file.
7938 * async-event.c: New file.
7939 * Makefile.in (COMMON_SFILES): Add async-event.c.
7940 (HFILES_NO_SRCDIR): Add async-event.h.
7941
7942 2020-04-13 Tom Tromey <tom@tromey.com>
7943
7944 * utils.c (flush_streams): New function.
7945 * event-loop.c (gdb_wait_for_event): Call flush_streams.
7946
7947 2020-04-13 Tom Tromey <tom@tromey.com>
7948
7949 * event-loop.c (handle_file_event): Use warning, not
7950 printf_unfiltered.
7951
7952 2020-04-13 Tom Tromey <tom@tromey.com>
7953
7954 * event-loop.c: Include <chrono>.
7955
7956 2020-04-13 Tom Tromey <tom@tromey.com>
7957
7958 * gdb_select.h: Move to ../gdbsupport/.
7959 * event-loop.c: Update include path.
7960 * top.c: Update include path.
7961 * ser-base.c: Update include path.
7962 * ui-file.c: Update include path.
7963 * ser-tcp.c: Update include path.
7964 * guile/scm-ports.c: Update include path.
7965 * posix-hdep.c: Update include path.
7966 * ser-unix.c: Update include path.
7967 * gdb_usleep.c: Update include path.
7968 * mingw-hdep.c: Update include path.
7969 * inflow.c: Update include path.
7970 * infrun.c: Update include path.
7971 * event-top.c: Update include path.
7972
7973 2020-04-13 Tom Tromey <tom@tromey.com>
7974
7975 * configure: Rebuild.
7976 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
7977
7978 2020-04-13 Tom Tromey <tom@tromey.com>
7979
7980 * event-loop.h (start_event_loop): Don't declare.
7981 * event-loop.c (start_event_loop): Move...
7982 * main.c (start_event_loop): ...here. Now static.
7983
7984 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
7985
7986 * MAINTAINERS: Update my email address.
7987
7988 2020-04-12 Kamil Rytarowski <n54@gmx.com>
7989
7990 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
7991 IP_ALL.
7992
7993 2020-04-12 Kamil Rytarowski <n54@gmx.com>
7994
7995 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
7996 (nbsd_nat_target::info_proc): Add do_cmdline.
7997
7998 2020-04-12 Kamil Rytarowski <n54@gmx.com>
7999
8000 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
8001 (nbsd_nat_target::info_proc): Add do_cwd.
8002
8003 2020-04-12 Kamil Rytarowski <n54@gmx.com>
8004
8005 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
8006
8007 2020-04-11 Kamil Rytarowski <n54@gmx.com>
8008
8009 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
8010 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
8011 (nbsd_nat_target::info_proc): New functions.
8012 * nbsd-nat.c (kinfo_get_vmmap): New function.
8013 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
8014 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
8015 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
8016 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
8017 functions.
8018 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
8019 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
8020 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
8021 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
8022 (KINFO_VME_FLAG_GROWS_DOWN): New.
8023
8024 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
8025
8026 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
8027 bit shift.
8028
8029 2020-04-10 Tom Tromey <tromey@adacore.com>
8030
8031 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
8032
8033 2020-04-10 Tom Tromey <tromey@adacore.com>
8034
8035 * symtab.c (get_symbol_address, get_msymbol_address): Skip
8036 separate debug files.
8037
8038 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
8039
8040 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
8041 Move to...
8042 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
8043 ... here.
8044 * windows-nat.c (windows_nat_target::get_windows_debug_event):
8045 Check for STATUS_WX86_BREAKPOINT.
8046 (windows_nat_target::wait): Same.
8047
8048 2020-04-10 Tom de Vries <tdevries@suse.de>
8049
8050 PR cli/25808
8051 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
8052
8053 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8054
8055 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
8056 (Write After Approval): Remove Tom de Vries.
8057
8058 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
8059
8060 revert partially:
8061 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
8062
8063 * buildsym.c (record_line): Fix undefined behavior and preserve
8064 lines at eof.
8065
8066 2020-04-09 Kamil Rytarowski <n54@gmx.com>
8067
8068 * auxv.h (svr4_auxv_parse): New.
8069 * auxv.c (default_auxv_parse): Split into default_auxv_parse
8070 and generic_auxv_parse.
8071 (svr4_auxv_parse): Add.
8072 * obsd-tdep.c: Include "auxv.h".
8073 (obsd_auxv_parse): Remove.
8074 (obsd_init_abi): Remove comment.
8075 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
8076 from `obsd_auxv_parse' to `svr4_auxv_parse'.
8077 * nbsd-tdep.c: Include "auxv.h".
8078 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
8079
8080 2020-04-08 Tom Tromey <tromey@adacore.com>
8081
8082 * nat/windows-nat.h (last_wait_event): Don't declare.
8083 (wait_for_debug_event): Update comment.
8084 * nat/windows-nat.c (last_wait_event): Now static.
8085
8086 2020-04-08 Tom Tromey <tromey@adacore.com>
8087
8088 * windows-nat.c (wait_for_debug_event): Move to
8089 nat/windows-nat.c.
8090 * nat/windows-nat.h (wait_for_debug_event): Declare.
8091 * nat/windows-nat.c (wait_for_debug_event): Move from
8092 windows-nat.c. No longer static.
8093
8094 2020-04-08 Tom Tromey <tromey@adacore.com>
8095
8096 * windows-nat.c (get_windows_debug_event): Use
8097 fetch_pending_stop.
8098 * nat/windows-nat.h (fetch_pending_stop): Declare.
8099 * nat/windows-nat.c (fetch_pending_stop): New function.
8100
8101 2020-04-08 Tom Tromey <tromey@adacore.com>
8102
8103 * windows-nat.c (windows_continue): Use matching_pending_stop and
8104 continue_last_debug_event.
8105 * nat/windows-nat.h (matching_pending_stop)
8106 (continue_last_debug_event): Declare.
8107 * nat/windows-nat.c (DEBUG_EVENTS): New define.
8108 (matching_pending_stop, continue_last_debug_event): New
8109 functions.
8110
8111 2020-04-08 Tom Tromey <tromey@adacore.com>
8112
8113 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
8114 (handle_exception_result): Move to nat/windows-nat.h.
8115 (DEBUG_EXCEPTION_SIMPLE): Remove.
8116 (windows_nat::handle_ms_vc_exception): New function.
8117 (handle_exception): Move to nat/windows-nat.c.
8118 (get_windows_debug_event): Update.
8119 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
8120 nat/windows-nat.c.
8121 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
8122 (handle_exception_result): Move from windows-nat.c.
8123 (handle_exception): Declare.
8124 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
8125 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
8126 windows-nat.c.
8127
8128 2020-04-08 Tom Tromey <tromey@adacore.com>
8129
8130 * windows-nat.c (exception_count, event_count): Remove.
8131 (handle_exception, get_windows_debug_event)
8132 (do_initial_windows_stuff): Update.
8133
8134 2020-04-08 Tom Tromey <tromey@adacore.com>
8135
8136 * windows-nat.c (windows_nat::handle_load_dll)
8137 (windows_nat::handle_unload_dll): Rename. No longer static.
8138 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
8139 Declare.
8140
8141 2020-04-08 Tom Tromey <tromey@adacore.com>
8142
8143 * complaints.h (stop_whining): Declare at top-level.
8144 (complaint): Don't declare stop_whining.
8145
8146 2020-04-08 Tom Tromey <tromey@adacore.com>
8147
8148 * windows-nat.c (windows_nat::handle_output_debug_string):
8149 Rename. No longer static.
8150 * nat/windows-nat.h (handle_output_debug_string): Declare.
8151
8152 2020-04-08 Tom Tromey <tromey@adacore.com>
8153
8154 * windows-nat.c (current_process_handle, current_process_id)
8155 (main_thread_id, last_sig, current_event, last_wait_event)
8156 (current_windows_thread, desired_stop_thread_id, pending_stops)
8157 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
8158 (display_selectors, fake_create_process)
8159 (get_windows_debug_event): Update.
8160 * nat/windows-nat.h (current_process_handle, current_process_id)
8161 (main_thread_id, last_sig, current_event, last_wait_event)
8162 (current_windows_thread, desired_stop_thread_id, pending_stops)
8163 (struct pending_stop, siginfo_er): Move from windows-nat.c.
8164 * nat/windows-nat.c (current_process_handle, current_process_id)
8165 (main_thread_id, last_sig, current_event, last_wait_event)
8166 (current_windows_thread, desired_stop_thread_id, pending_stops)
8167 (siginfo_er): New globals. Move from windows-nat.c.
8168
8169 2020-04-08 Tom Tromey <tromey@adacore.com>
8170
8171 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
8172 (handle_load_dll): Update.
8173 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
8174
8175 2020-04-08 Tom Tromey <tromey@adacore.com>
8176
8177 * windows-nat.c (enum thread_disposition_type): Move to
8178 nat/windows-nat.h.
8179 (windows_nat::thread_rec): Rename from thread_rec. No longer
8180 static.
8181 (windows_add_thread, windows_nat_target::fetch_registers)
8182 (windows_nat_target::store_registers, handle_exception)
8183 (windows_nat_target::resume, get_windows_debug_event)
8184 (windows_nat_target::get_tib_address)
8185 (windows_nat_target::thread_name)
8186 (windows_nat_target::thread_alive): Update.
8187 * nat/windows-nat.h (enum thread_disposition_type): Move from
8188 windows-nat.c.
8189 (thread_rec): Declare.
8190
8191 2020-04-08 Tom Tromey <tromey@adacore.com>
8192
8193 * windows-nat.c: Add "using namespace".
8194 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
8195 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
8196
8197 2020-04-08 Tom Tromey <tromey@adacore.com>
8198
8199 * nat/windows-nat.h (struct windows_thread_info): Declare
8200 destructor.
8201 * nat/windows-nat.c (~windows_thread_info): New.
8202
8203 2020-04-08 Tom Tromey <tromey@adacore.com>
8204
8205 PR gdb/22992
8206 * windows-nat.c (current_event): Update comment.
8207 (last_wait_event, desired_stop_thread_id): New globals.
8208 (struct pending_stop): New.
8209 (pending_stops): New global.
8210 (windows_nat_target) <stopped_by_sw_breakpoint>
8211 <supports_stopped_by_sw_breakpoint>: New methods.
8212 (windows_fetch_one_register): Add assertions. Adjust PC.
8213 (windows_continue): Handle pending stops. Suspend other threads
8214 when stepping. Use last_wait_event
8215 (wait_for_debug_event): New function.
8216 (get_windows_debug_event): Use wait_for_debug_event. Handle
8217 pending stops. Queue spurious stops.
8218 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
8219 (windows_nat_target::kill): Use wait_for_debug_event.
8220 * nat/windows-nat.h (struct windows_thread_info)
8221 <stopped_at_software_breakpoint>: New field.
8222 * nat/windows-nat.c (windows_thread_info::resume): Clear
8223 stopped_at_software_breakpoint.
8224
8225 2020-04-08 Tom Tromey <tromey@adacore.com>
8226
8227 * windows-nat.c (enum thread_disposition_type): New.
8228 (thread_rec): Replace "get_context" parameter with "disposition";
8229 change type.
8230 (windows_add_thread, windows_nat_target::fetch_registers)
8231 (windows_nat_target::store_registers, handle_exception)
8232 (windows_nat_target::resume, get_windows_debug_event)
8233 (windows_nat_target::get_tib_address)
8234 (windows_nat_target::thread_name)
8235 (windows_nat_target::thread_alive): Update.
8236
8237 2020-04-08 Tom Tromey <tromey@adacore.com>
8238
8239 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
8240 (windows_continue): Use windows_continue::resume.
8241 * nat/windows-nat.h (struct windows_thread_info) <suspend,
8242 resume>: Declare new methods.
8243 * nat/windows-nat.c: New file.
8244 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
8245
8246 2020-04-08 Tom Tromey <tromey@adacore.com>
8247
8248 * windows-nat.c (windows_add_thread, windows_delete_thread)
8249 (windows_nat_target::fetch_registers)
8250 (windows_nat_target::store_registers, fake_create_process)
8251 (windows_nat_target::resume, windows_nat_target::resume)
8252 (get_windows_debug_event, windows_nat_target::wait)
8253 (windows_nat_target::pid_to_str)
8254 (windows_nat_target::get_tib_address)
8255 (windows_nat_target::get_ada_task_ptid)
8256 (windows_nat_target::thread_name)
8257 (windows_nat_target::thread_alive): Use lwp, not tid.
8258
8259 2020-04-08 Tom Tromey <tromey@adacore.com>
8260
8261 * windows-nat.c (handle_exception)
8262 (windows_nat_target::thread_name): Update.
8263 * nat/windows-nat.h (windows_thread_info): Remove destructor.
8264 <name>: Now unique_xmalloc_ptr.
8265
8266 2020-04-08 Tom Tromey <tromey@adacore.com>
8267
8268 * windows-nat.c (thread_rec)
8269 (windows_nat_target::fetch_registers): Update.
8270 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
8271 Update comment.
8272 <debug_registers_changed, reload_context>: Now bool.
8273
8274 2020-04-08 Tom Tromey <tromey@adacore.com>
8275
8276 * windows-nat.c (windows_add_thread): Use new.
8277 (windows_init_thread_list, windows_delete_thread): Use delete.
8278 (get_windows_debug_event): Update.
8279 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
8280 destructor, and initializers.
8281
8282 2020-04-08 Tom Tromey <tromey@adacore.com>
8283
8284 * windows-nat.c (struct windows_thread_info): Remove.
8285 * nat/windows-nat.h: New file.
8286
8287 2020-04-08 Tom Tromey <tromey@adacore.com>
8288
8289 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
8290 (thread_rec, windows_add_thread, windows_delete_thread)
8291 (windows_continue): Update.
8292
8293 2020-04-08 Tom Tromey <tromey@adacore.com>
8294
8295 * windows-nat.c (struct windows_thread_info): Remove typedef.
8296 (thread_head): Remove.
8297 (thread_list): New global.
8298 (thread_rec, windows_add_thread, windows_init_thread_list)
8299 (windows_delete_thread, windows_continue): Update.
8300
8301 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
8302
8303 * windows-tdep.h (windows_init_abi): Add comment.
8304 (cygwin_init_abi): New declaration.
8305 * windows-tdep.c: Split signal enumeration in two, one for
8306 Windows and one for Cygwin.
8307 (windows_gdb_signal_to_target): Only deal with signal of the
8308 Windows OS ABI.
8309 (cygwin_gdb_signal_to_target): New function.
8310 (windows_init_abi): Rename to windows_init_abi_common, don't set
8311 gdb_signal_to_target gdbarch method. Add new new function with
8312 this name.
8313 (cygwin_init_abi): New function.
8314 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
8315 comment. Don't call windows_init_abi.
8316 (amd64_windows_init_abi): Add comment, call windows_init_abi.
8317 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
8318 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
8319 i386_windows_init_abi_common, don't call windows_init_abi. Add
8320 a new function of this name.
8321 (i386_cygwin_init_abi): New function.
8322 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
8323 OS ABI Cygwin.
8324
8325 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
8326
8327 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
8328 parameter.c.
8329 (dwarf2_read_gdb_index): Update.
8330
8331 2020-04-07 Kamil Rytarowski <n54@gmx.com>
8332
8333 * nbsd-tdep.c: Include "objfiles.h".
8334 (nbsd_skip_solib_resolver): New.
8335 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
8336
8337 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
8338
8339 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
8340 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
8341 with DW_LLE_base_addressx are being emitted in DWARFv5.
8342 Add the newly added kind DW_LOC_OFFSET_PAIR also.
8343 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
8344 unsigned integer.
8345
8346 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
8347
8348 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
8349 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
8350 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
8351 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
8352 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
8353 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
8354 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
8355
8356
8357 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
8358
8359 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
8360 (read_loclist_index): New function definition.
8361 (lookup_loclist_base): New function definition.
8362 (read_loclist_header): New function definition.
8363 (dwarf2_cu): Add loclist_base and loclist_header field.
8364 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
8365 (read_full_die_1): Read the value of DW_AT_loclists_base.
8366 (read_attribute_reprocess): Handle DW_FORM_loclistx.
8367 (read_attribute_value): Handle DW_FORM_loclistx.
8368 (skip_one_die): Handle DW_FORM_loclistx.
8369 (loclist_header): New structure declaration.
8370 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
8371
8372 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
8373
8374 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
8375 constructor. Remove `addr` parameter from other constructor and
8376 add `per_cu` parameter.
8377 * dwarf2/read.c (create_partial_symtab): Update.
8378
8379 2020-04-07 Tom de Vries <tdevries@suse.de>
8380
8381 PR symtab/25796
8382 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
8383 (partial_die_info::fixup): Inherit has_const_value.
8384
8385 2020-04-07 Tom de Vries <tdevries@suse.de>
8386
8387 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
8388 symbols without address.
8389
8390 2020-04-06 Kamil Rytarowski <n54@gmx.com>
8391
8392 * nbsd-nat.h (struct thread_info): Add forward declaration.
8393 (nbsd_nat_target::thread_alive): Add.
8394 (nbsd_nat_target::thread_name): Likewise.
8395 (nbsd_nat_target::update_thread_list): Likewise.
8396 (update_thread_list::post_attach): Likewise.
8397 (post_attach::pid_to_str): Likewise.
8398 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
8399 (nbsd_thread_lister): Add.
8400 (nbsd_nat_target::thread_alive): Likewise.
8401 (nbsd_nat_target::thread_name): Likewise.
8402 (nbsd_add_threads): Likewise.
8403 (update_thread_list::post_attach): Likewise.
8404 (nbsd_nat_target::update_thread_list): Likewise.
8405 (post_attach::pid_to_str): Likewise.
8406
8407 2020-04-06 Tom Tromey <tromey@adacore.com>
8408
8409 * ada-valprint.c (print_variant_part): Extract the variant field.
8410 (print_field_values): Use the field as the outer value when
8411 recursing.
8412
8413 2020-04-06 Tom Tromey <tromey@adacore.com>
8414
8415 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
8416 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
8417 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
8418 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
8419 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
8420
8421 2020-04-06 Tom Tromey <tromey@adacore.com>
8422
8423 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
8424 TYPE_CODE_ERROR.
8425
8426 2020-04-06 Kamil Rytarowski <n54@gmx.com>
8427
8428 * nbsd-tdep.c: Include "gdbarch.h".
8429 Define enum with NetBSD signal numbers.
8430 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
8431 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
8432 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
8433 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
8434 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
8435 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
8436 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
8437 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
8438 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
8439 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
8440 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
8441 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
8442
8443 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
8444
8445 PR gdb/25325
8446 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
8447
8448 2020-04-03 Tom Tromey <tromey@adacore.com>
8449
8450 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
8451 Read constant block.
8452
8453 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
8454
8455 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
8456 (gdb_bfd_get_full_section_contents): New declaration.
8457 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
8458 * windows-tdep.c (is_linked_with_cygwin_dll): Use
8459 gdb_bfd_get_full_section_contents.
8460
8461 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
8462
8463 * exec.c (build_section_table): Replace internal_error with
8464 gdb_assert.
8465 (section_table_xfer_memory_partial): Likewise.
8466 * mdebugread.c (parse_partial_symbols): Likewise.
8467 * psymtab.c (lookup_partial_symbol): Likewise.
8468 * utils.c (wrap_here): Likewise.
8469
8470 2020-04-02 Tom Tromey <tromey@adacore.com>
8471
8472 * f-lang.c (build_fortran_types): Use arch_type to initialize
8473 builtin_complex_s32 in the TYPE_CODE_ERROR case.
8474
8475 2020-04-02 Tom Tromey <tromey@adacore.com>
8476
8477 * dwarf2/read.c (partial_die_info::read): Do not create a vector
8478 of attributes.
8479
8480 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
8481 Bernd Edlinger <bernd.edlinger@hotmail.de>
8482 Tom Tromey <tromey@adacore.com>
8483
8484 * buildsym.c (buildsym_compunit::record_line): Remove
8485 deduplication code.
8486
8487 2020-04-02 Tom de Vries <tdevries@suse.de>
8488
8489 PR ada/24671
8490 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
8491
8492 2020-04-02 Tom de Vries <tdevries@suse.de>
8493
8494 * dwarf2/read.c (dwarf2_gdb_index_functions,
8495 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
8496 NULL.
8497 * psymtab.c (psym_lookup_global_symbol_language): New function.
8498 (psym_functions): Init psym_lookup_global_symbol_language with
8499 psym_lookup_global_symbol_language.
8500 * symfile-debug.c (debug_sym_quick_functions): Init
8501 lookup_global_symbol_language with NULL.
8502 * symfile.c (set_initial_language): Remove fixme comment.
8503 * symfile.h (struct quick_symbol_functions): Add
8504 lookup_global_symbol_language.
8505 * symtab.c (find_quick_global_symbol_language): New function.
8506 (find_main_name): Use find_quick_global_symbol_language.
8507
8508 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
8509
8510 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
8511
8512 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
8513
8514 * buildsym.c (record_line): Fix undefined behavior and preserve
8515 lines at eof.
8516
8517 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
8518
8519 * buildsym.c (record_line): Fix the resizing condition.
8520
8521 2020-04-01 Tom Tromey <tom@tromey.com>
8522
8523 * value.h (value_literal_complex): Add comment.
8524 * valops.c (value_literal_complex): Refer to value.h.
8525
8526 2020-04-01 Tom Tromey <tom@tromey.com>
8527
8528 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
8529 (scalar_type): New rule, from typebase.
8530 (typebase): Use scalar_type. Recognize complex types.
8531 (field_name): Handle FLOAT_KEYWORD.
8532 (ident_tokens): Add _Complex and __complex__.
8533
8534 2020-04-01 Tom Tromey <tom@tromey.com>
8535
8536 PR exp/25299:
8537 * valarith.c (promotion_type, complex_binop): New functions.
8538 (scalar_binop): Handle complex numbers. Use promotion_type.
8539 (value_pos, value_neg, value_complement): Handle complex numbers.
8540
8541 2020-04-01 Tom Tromey <tom@tromey.com>
8542
8543 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
8544 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
8545 (parse_number): Handle complex numbers.
8546
8547 2020-04-01 Tom Tromey <tom@tromey.com>
8548
8549 * c-valprint.c (c_decorations): Change complex suffix to "i".
8550
8551 2020-04-01 Tom Tromey <tom@tromey.com>
8552
8553 * valprint.c (generic_value_print_complex): Use accessors.
8554 * value.h (value_real_part, value_imaginary_part): Declare.
8555 * valops.c (value_real_part, value_imaginary_part): New
8556 functions.
8557 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
8558
8559 2020-04-01 Tom Tromey <tom@tromey.com>
8560
8561 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
8562 (read_range_type): Update.
8563 * mdebugread.c (basic_type): Update.
8564 * go-lang.c (build_go_types): Use init_complex_type.
8565 * gdbtypes.h (struct main_type) <complex_type>: New member.
8566 (init_complex_type): Update.
8567 (arch_complex_type): Don't declare.
8568 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
8569 Make name if none given. Use alloc_type_copy. Look for cached
8570 complex type.
8571 (arch_complex_type): Remove.
8572 (gdbtypes_post_init): Use init_complex_type.
8573 * f-lang.c (build_fortran_types): Use init_complex_type.
8574 * dwarf2/read.c (read_base_type): Update.
8575 * d-lang.c (build_d_types): Use init_complex_type.
8576 * ctfread.c (read_base_type): Update.
8577
8578 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8579
8580 * infrun.c (stop_all_threads): Update assertion, plus when
8581 stopping threads, take into account that we might be trying
8582 to stop an all-stop target.
8583 (stop_waiting): Call 'stop_all_threads' if there exists a
8584 non-stop target.
8585
8586 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8587
8588 * target.h (exists_non_stop_target): New function declaration.
8589 * target.c (exists_non_stop_target): New function.
8590
8591 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
8592
8593 PR gdb/24789
8594 * eval.c (is_integral_or_integral_reference): New function.
8595 (evaluate_subexp_standard): Allow integer references in
8596 pointer arithmetic.
8597
8598 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8599
8600 * remote.c (remote_target::remote_parse_stop_reply): Remove the
8601 check for no ptid in the stop reply when the target is non-stop.
8602
8603 2020-04-01 Tom Tromey <tromey@adacore.com>
8604
8605 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
8606 "name" parameter to rvalue reference. Initialize m_name_holder.
8607 <lookup_name_info>: New overloads.
8608 <name>: Return gdb::string_view.
8609 <c_str>: New method.
8610 <make_ignore_params>: Update.
8611 <search_name_hash>: Update.
8612 <language_lookup_name>: Return const char *.
8613 <m_name>: Change type.
8614 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
8615 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
8616 (lookup_name_info::match_any): Update.
8617 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
8618 Update.
8619 * minsyms.c (linkage_name_str): Update.
8620 * language.c (default_symbol_name_matcher): Update.
8621 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
8622 Update.
8623 * ada-lang.c (ada_fold_name): Change parameter to string_view.
8624 (ada_lookup_name_info::ada_lookup_name_info): Update.
8625 (literal_symbol_name_matcher): Update.
8626
8627 2020-04-01 Tom Tromey <tromey@adacore.com>
8628
8629 * psymtab.c (psymtab_search_name): Remove function.
8630 (psym_lookup_symbol): Create search name and lookup name here.
8631 (lookup_partial_symbol): Remove "name" parameter; add
8632 lookup_name.
8633 (psym_expand_symtabs_for_function): Update.
8634
8635 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
8636
8637 PR tui/25597:
8638 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
8639
8640 2020-03-31 Tom Tromey <tromey@adacore.com>
8641
8642 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
8643 memcpy.
8644
8645 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
8646
8647 * features/riscv/32bit-csr.xml: Regenerated.
8648 * features/riscv/64bit-csr.xml: Regenerated.
8649
8650 2020-03-30 Tom Tromey <tromey@adacore.com>
8651
8652 * ada-valprint.c (print_variant_part): Update.
8653 * ada-lang.h (ada_which_variant_applies): Update.
8654 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
8655 outer_valaddr parameters; replace with "outer" value parameter.
8656 (to_fixed_variant_branch_type): Update.
8657
8658 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
8659
8660 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
8661 <list>. Remove inclusion of observable.h.
8662 (PPC_DEBUG_CURRENT_VERSION): Move up define.
8663 (struct arch_lwp_info): New struct.
8664 (class ppc_linux_dreg_interface): New class.
8665 (struct ppc_linux_process_info): New struct.
8666 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
8667 <low_new_clone, low_forget_process, low_prepare_to_resume>
8668 <copy_thread_dreg_state, mark_thread_stale>
8669 <mark_debug_registers_changed, register_hw_breakpoint>
8670 <clear_hw_breakpoint, register_wp, clear_wp>
8671 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
8672 <num_memory_accesses, get_trigger_type>
8673 <create_watchpoint_request, hwdebug_point_cmp>
8674 <init_arch_lwp_info, get_arch_lwp_info>
8675 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
8676 methods.
8677 <struct ptid_hash>: New inner struct.
8678 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
8679 members.
8680 (saved_dabr_value, hwdebug_info, max_slots_number)
8681 (struct hw_break_tuple, struct thread_points, ppc_threads)
8682 (have_ptrace_hwdebug_interface)
8683 (hwdebug_find_thread_points_by_tid)
8684 (hwdebug_insert_point, hwdebug_remove_point): Remove.
8685 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
8686 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
8687 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
8688 use m_dreg_interface.
8689 (hwdebug_point_cmp): Change to...
8690 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
8691 reference arguments instead of pointers.
8692 (ppc_linux_nat_target::ranged_break_num_registers): Use
8693 m_dreg_interface.
8694 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
8695 m_dreg_interface. Call register_hw_breakpoint.
8696 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
8697 m_dreg_interface. Call clear_hw_breakpoint.
8698 (get_trigger_type): Change to...
8699 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
8700 comment.
8701 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
8702 use m_dreg_interface. Call register_hw_breakpoint.
8703 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
8704 use m_dreg_interface. Call clear_hw_breakpoint.
8705 (can_use_watchpoint_cond_accel): Change to...
8706 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
8707 method. Update comment, use m_dreg_interface and
8708 m_process_info.
8709 (calculate_dvc): Change to...
8710 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
8711 m_dreg_interface.
8712 (num_memory_accesses): Change to...
8713 (ppc_linux_nat_target::num_memory_accesses): ...this method.
8714 (check_condition): Change to...
8715 (ppc_linux_nat_target::check_condition): ...this method.
8716 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
8717 comment, use m_dreg_interface.
8718 (create_watchpoint_request): Change to...
8719 (ppc_linux_nat_target::create_watchpoint_request): ...this
8720 method. Use m_dreg_interface.
8721 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
8722 m_dreg_interface. Call register_hw_breakpoint or register_wp.
8723 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
8724 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
8725 (ppc_linux_nat_target::low_forget_process)
8726 (ppc_linux_nat_target::low_new_fork)
8727 (ppc_linux_nat_target::low_new_clone)
8728 (ppc_linux_nat_target::low_delete_thread)
8729 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
8730 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
8731 only call mark_thread_stale.
8732 (ppc_linux_thread_exit): Remove.
8733 (ppc_linux_nat_target::stopped_data_address): Change to...
8734 (ppc_linux_nat_target::low_stopped_data_address): This. Add
8735 comment, use m_dreg_interface and m_thread_hw_breakpoints.
8736 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
8737 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
8738 comment. Call low_stopped_data_address.
8739 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
8740 m_dreg_interface.
8741 (ppc_linux_nat_target::masked_watch_num_registers): Use
8742 m_dreg_interface.
8743 (ppc_linux_nat_target::copy_thread_dreg_state)
8744 (ppc_linux_nat_target::mark_thread_stale)
8745 (ppc_linux_nat_target::mark_debug_registers_changed)
8746 (ppc_linux_nat_target::register_hw_breakpoint)
8747 (ppc_linux_nat_target::clear_hw_breakpoint)
8748 (ppc_linux_nat_target::register_wp)
8749 (ppc_linux_nat_target::clear_wp)
8750 (ppc_linux_nat_target::init_arch_lwp_info)
8751 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
8752 (_initialize_ppc_linux_nat): Remove observer callback.
8753
8754 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
8755
8756 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
8757 (ppc_linux_nat_target::auxv_parse)
8758 (ppc_linux_nat_target::read_description)
8759 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
8760 Move up.
8761
8762 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
8763
8764 * linux-nat.h (low_new_clone): New method.
8765 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
8766
8767 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
8768
8769 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
8770 (dbx_expand_psymtab): ... this.
8771 (start_psymtab): Update.
8772 * mdebugread.c (psymtab_to_symtab_1): Rename to...
8773 (mdebug_expand_psymtab): ... this.
8774 (parse_partial_symbols): Update.
8775 (new_psymtab): Update.
8776 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
8777 (xcoff_expand_psymtab): ... this.
8778 (xcoff_start_psymtab): Update.
8779
8780 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
8781
8782 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
8783 <expand_dependencies>: ... this.
8784 * psymtab.c (partial_symtab::read_dependencies): Rename to...
8785 (partial_symtab::expand_dependencies): ... this.
8786 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
8787 Update.
8788 (dwarf2_psymtab::expand_psymtab): Update.
8789 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
8790 * mdebugread.c (psymtab_to_symtab_1): Update.
8791 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
8792
8793 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
8794
8795 * psympriv.h (discard_psymtab): Remove.
8796 * dbxread.c (dbx_end_psymtab): Update.
8797 * xcoffread.c (xcoff_end_psymtab): Update.
8798
8799 2020-03-28 Tom Tromey <tom@tromey.com>
8800
8801 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
8802 comment.
8803
8804 2020-03-28 Tom Tromey <tom@tromey.com>
8805
8806 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
8807
8808 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
8809
8810 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
8811
8812 2020-03-26 John Baldwin <jhb@FreeBSD.org>
8813
8814 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
8815
8816 2020-03-26 Tom Tromey <tom@tromey.com>
8817
8818 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
8819 (mark_common_block_symbol_computed, read_tag_string_type)
8820 (attr_to_dynamic_prop, read_subrange_type): Update.
8821 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
8822 to be methods on struct attribute.
8823 (skip_one_die, process_imported_unit_die, read_namespace_alias)
8824 (read_call_site_scope, partial_die_info::read)
8825 (partial_die_info::read, lookup_die_type, follow_die_ref):
8826 Update.
8827 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
8828 from dwarf2_get_ref_die_offset.
8829 (attribute::constant_value): New method, from
8830 dwarf2_get_attr_constant_value.
8831 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
8832 Declare method.
8833 <constant_value>: New method.
8834
8835 2020-03-26 Tom Tromey <tom@tromey.com>
8836
8837 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
8838 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
8839 (dwarf_type_encoding_name): Move to stringify.c.
8840 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
8841 * dwarf2/stringify.c: New file.
8842 * dwarf2/stringify.h: New file.
8843
8844 2020-03-26 Tom Tromey <tom@tromey.com>
8845
8846 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
8847 Rewrite.
8848
8849 2020-03-26 Tom Tromey <tom@tromey.com>
8850
8851 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
8852 methods.
8853 * dwarf2/read.c (lookup_addr_base): Move to die.h.
8854 (lookup_ranges_base): Likewise.
8855 (read_cutu_die_from_dwo, read_full_die_1): Update.
8856
8857 2020-03-26 Tom Tromey <tom@tromey.com>
8858
8859 * dwarf2/read.c (read_import_statement, read_file_scope)
8860 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
8861 (read_lexical_block_scope, read_call_site_scope)
8862 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
8863 (handle_struct_member_die, process_structure_scope)
8864 (update_enumeration_type_from_children)
8865 (process_enumeration_scope, read_array_type, read_common_block)
8866 (read_namespace, read_module, read_subroutine_type): Update.
8867 (sibling_die): Remove.
8868
8869 2020-03-26 Tom Tromey <tom@tromey.com>
8870
8871 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
8872 (build_type_psymtabs_reader, read_structure_type)
8873 (read_enumeration_type, read_full_die_1): Update.
8874 (dwarf2_attr_no_follow): Move to die.h.
8875 * dwarf2/die.h (struct die_info) <attr>: New method.
8876
8877 2020-03-26 Tom Tromey <tom@tromey.com>
8878
8879 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
8880 <base_address>: Now an optional.
8881 (dwarf2_find_base_address, dwarf2_rnglists_process)
8882 (dwarf2_ranges_process, fill_in_loclist_baton)
8883 (dwarf2_symbol_mark_computed): Update.
8884
8885 2020-03-26 Tom Tromey <tom@tromey.com>
8886
8887 * dwarf2/read.c (struct die_info): Move to die.h.
8888 * dwarf2/die.h: New file.
8889
8890 2020-03-26 Tom Tromey <tom@tromey.com>
8891
8892 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
8893 * dwarf2/read.c
8894 (dwarf2_statement_list_fits_in_line_number_section_complaint):
8895 Move to line-header.c.
8896 (read_checked_initial_length_and_offset, read_formatted_entries):
8897 Likewise.
8898 (dwarf_decode_line_header): Split into two.
8899 * dwarf2/line-header.c
8900 (dwarf2_statement_list_fits_in_line_number_section_complaint):
8901 Move from read.c.
8902 (read_checked_initial_length_and_offset, read_formatted_entries):
8903 Likewise.
8904 (dwarf_decode_line_header): New function, split from read.c.
8905
8906 2020-03-26 Tom Tromey <tom@tromey.com>
8907
8908 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
8909 Declare method.
8910 * dwarf2/read.c (read_attribute_value): Update.
8911 (dwarf2_per_objfile::read_line_string): Rename from
8912 read_indirect_line_string.
8913 (read_formatted_entries): Update.
8914
8915 2020-03-26 Tom Tromey <tom@tromey.com>
8916
8917 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
8918 variable.
8919
8920 2020-03-26 Tom Tromey <tom@tromey.com>
8921
8922 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
8923 const.
8924 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
8925 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
8926 parameter const.
8927
8928 2020-03-26 Tom Tromey <tom@tromey.com>
8929
8930 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
8931 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
8932 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
8933 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
8934
8935 2020-03-26 Tom Tromey <tom@tromey.com>
8936
8937 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
8938 file_names_size, file_full_name, file_file_name>: Use const.
8939 <file_name_at, file_names>: Add const overload.
8940 * dwarf2/line-header.c (line_header::file_file_name)
8941 (line_header::file_full_name): Update.
8942
8943 2020-03-26 Tom Tromey <tom@tromey.com>
8944
8945 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
8946 (macro_start_file, consume_improper_spaces)
8947 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
8948 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
8949 (dwarf_decode_macros): Move to macro.c.
8950 * dwarf2/macro.c: New file.
8951 * dwarf2/macro.h: New file.
8952 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
8953
8954 2020-03-26 Tom Tromey <tom@tromey.com>
8955
8956 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
8957 method.
8958 * dwarf2/section.c: New method. From
8959 read_indirect_string_at_offset_from.
8960 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
8961 (read_indirect_string_at_offset_from): Move to section.c.
8962 (read_indirect_string_at_offset): Rewrite.
8963 (read_indirect_line_string_at_offset): Remove.
8964 (read_indirect_string, read_indirect_line_string)
8965 (dwarf_decode_macro_bytes): Update.
8966
8967 2020-03-26 Tom Tromey <tom@tromey.com>
8968
8969 * dwarf2/section.h (struct dwarf2_section_info)
8970 <overload_complaint>: Declare.
8971 (dwarf2_section_buffer_overflow_complaint): Don't declare.
8972 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
8973 Rename from dwarf2_section_buffer_overflow_complaint.
8974 * dwarf2/read.c (skip_one_die, partial_die_info::read)
8975 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
8976
8977 2020-03-26 Tom Tromey <tom@tromey.com>
8978
8979 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
8980 Declare.
8981 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
8982 Move from read.c.
8983 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
8984 to section.c.
8985
8986 2020-03-26 Tom Tromey <tom@tromey.com>
8987
8988 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
8989
8990 2020-03-26 Tom Tromey <tom@tromey.com>
8991
8992 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
8993 "builder".
8994 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
8995 parameter.
8996 (dwarf_decode_macros): Update.
8997
8998 2020-03-26 Tom Tromey <tom@tromey.com>
8999
9000 * dwarf2/read.c (read_attribute_value): Update.
9001 (read_indirect_string_from_dwz): Move to dwz.c; change into
9002 method.
9003 (dwarf_decode_macro_bytes): Update.
9004 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
9005 * dwarf2/dwz.c: New file.
9006 * Makefile.in (COMMON_SFILES): Add dwz.c.
9007
9008 2020-03-26 Tom Tromey <tom@tromey.com>
9009
9010 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
9011 * dwarf2/read.c: Add include.
9012 * dwarf2/index-write.c: Add include.
9013 * dwarf2/index-cache.c: Add include.
9014 * dwarf2/dwz.h: New file.
9015
9016 2020-03-25 Tom Tromey <tom@tromey.com>
9017
9018 * compile/compile-object-load.c (get_out_value_type): Mention
9019 correct symbol name in error message.
9020
9021 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
9022
9023 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
9024
9025 2020-03-25 Tom de Vries <tdevries@suse.de>
9026
9027 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
9028 * symmisc.c (dump_symtab_1): Print user and includes fields.
9029 (maintenance_info_symtabs): Same.
9030
9031 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
9032
9033 PR gdb/25534
9034 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
9035 (riscv_regcache_cooked_write): New function.
9036 (riscv_push_dummy_call): Use new function.
9037 (riscv_return_value): Likewise.
9038
9039 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
9040
9041 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
9042 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
9043 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
9044 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
9045 * infrun.c (follow_fork): Likewise.
9046 (follow_fork_inferior): Likewise.
9047 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
9048 * linux-nat.h (class linux_nat_target): Likewise.
9049 * remote.c (class remote_target) <follow_fork>: Likewise.
9050 (remote_target::follow_fork): Likewise.
9051 * target-delegates.c: Re-generate.
9052 * target.c (default_follow_fork): Likewise.
9053 (target_follow_fork): Likewise.
9054 * target.h (struct target_ops) <follow_fork>: Likewise.
9055 (target_follow_fork): Likewise.
9056
9057 2020-03-24 Tom de Vries <tdevries@suse.de>
9058
9059 * psymtab.c (maintenance_info_psymtabs): Print user field.
9060
9061 2020-03-20 Tom Tromey <tromey@adacore.com>
9062
9063 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
9064 const.
9065 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
9066 const.
9067
9068 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
9069
9070 * ptrace.m4: Don't check for ptrace declaration.
9071 * config.in: Re-generate.
9072 * configure: Re-generate.
9073 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
9074 not defined.
9075
9076 2020-03-20 Kamil Rytarowski <n54@gmx.com>
9077
9078 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
9079 `PTRACE_TYPE_RET'.
9080 * i386-bsd-nat.c (gdb_ptrace): Likewise.
9081 * sparc-nat.c (gdb_ptrace): Likewise.
9082 * x86-bsd-nat.c (gdb_ptrace): Likewise.
9083
9084 2020-03-20 Tom Tromey <tromey@adacore.com>
9085
9086 * c-exp.y (lex_one_token): Fix assert.
9087
9088 2020-03-20 Tom Tromey <tromey@adacore.com>
9089
9090 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
9091 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
9092 strncpy call.
9093
9094 2020-03-20 Tom Tromey <tromey@adacore.com>
9095
9096 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
9097
9098 2020-03-20 Tom Tromey <tromey@adacore.com>
9099
9100 * ada-valprint.c (print_variant_part): Remove parameters; switch
9101 to value-based API.
9102 (print_field_values): Likewise.
9103 (ada_val_print_struct_union): Likewise.
9104 (ada_value_print_1): Update.
9105
9106 2020-03-20 Kamil Rytarowski <n54@gmx.com>
9107
9108 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
9109 nbsd_nat_target instead of inf_ptrace_target.
9110 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
9111 nbsd_nat_target.
9112
9113 2020-03-20 Kamil Rytarowski <n54@gmx.com>
9114
9115 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
9116 it to the ptrace call.
9117 * (store_registers): Likewise.
9118
9119 2020-03-20 Kamil Rytarowski <n54@gmx.com>
9120
9121 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
9122 it to the ptrace call.
9123 * (store_registers): Likewise.
9124
9125 2020-03-19 Luis Machado <luis.machado@linaro.org>
9126
9127 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
9128 valid, fetch vg value from ptrace.
9129
9130 2020-03-19 Kamil Rytarowski <n54@gmx.com>
9131 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
9132 * inf-ptrace.c: Likewise.
9133 * (gdb_ptrace): Add.
9134 * (inf_ptrace_target::resume): Update.
9135 * (inf_ptrace_target::xfer_partial): Likewise.
9136 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
9137 * (inf_ptrace_peek_poke): Update.
9138
9139 2020-03-19 Kamil Rytarowski <n54@gmx.com>
9140
9141 * x86-bsd-nat.c (gdb_ptrace): New.
9142 * (x86bsd_dr_set): Add new argument `ptid'.
9143 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
9144 x86bsd_dr_set_addr): Update.
9145
9146 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
9147
9148 * remote.c (remote_target::process_stop_reply): Handle events for
9149 all threads differently.
9150
9151 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
9152
9153 * completer.c (completion_tracker::remove_completion): Define new
9154 function.
9155 * completer.h (completion_tracker::remove_completion): Declare new
9156 function.
9157 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
9158 when adding a C++ function symbol.
9159
9160 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
9161
9162 * completer.c (completion_tracker::completion_hash_entry): Define
9163 new class.
9164 (advance_to_filename_complete_word_point): Call
9165 recompute_lowest_common_denominator.
9166 (completion_tracker::completion_tracker): Call discard_completions
9167 to setup the hash table.
9168 (completion_tracker::discard_completions): Allow for being called
9169 from the constructor, pass new equal function, and element deleter
9170 when constructing the hash table. Initialise new class member
9171 variables.
9172 (completion_tracker::maybe_add_completion): Remove use of
9173 m_entries_vec, and store more information into m_entries_hash.
9174 (completion_tracker::recompute_lcd_visitor): New function, most
9175 content taken from...
9176 (completion_tracker::recompute_lowest_common_denominator):
9177 ...here, this now just visits each item in the hash calling the
9178 above visitor.
9179 (completion_tracker::build_completion_result): Remove use of
9180 m_entries_vec, call recompute_lowest_common_denominator.
9181 * completer.h (completion_tracker::have_completions): Remove use
9182 of m_entries_vec.
9183 (completion_tracker::completion_hash_entry): Declare new class.
9184 (completion_tracker::recompute_lowest_common_denominator): Change
9185 function signature.
9186 (completion_tracker::recompute_lcd_visitor): Declare new function.
9187 (completion_tracker::m_entries_vec): Delete.
9188 (completion_tracker::m_entries_hash): Initialize to NULL.
9189 (completion_tracker::m_lowest_common_denominator_valid): New
9190 member variable.
9191 (completion_tracker::m_lowest_common_denominator_max_length): New
9192 member variable.
9193
9194 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9195
9196 * regformats/regdef.h: Put reg in gdb namespace.
9197
9198 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9199
9200 * i386-bsd-nat.c (gdb_ptrace): New.
9201 * (i386bsd_fetch_inferior_registers,
9202 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
9203 * (i386bsd_fetch_inferior_registers,
9204 i386bsd_store_inferior_registers) Use gdb_ptrace.
9205
9206 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9207
9208 * amd64-bsd-nat.c (gdb_ptrace): New.
9209 * (amd64bsd_fetch_inferior_registers,
9210 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
9211 * (amd64bsd_fetch_inferior_registers,
9212 amd64bsd_store_inferior_registers) Use gdb_ptrace.
9213
9214 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9215
9216 * user-regs.c (user_reg::read): Rename to...
9217 (user_reg::xread): ...this.
9218 * (append_user_reg): Rename argument `read' to `xread'.
9219 * (user_reg_add_builtin): Likewise.
9220 * (user_reg_add): Likewise.
9221 * (value_of_user_reg): Likewise.
9222
9223 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9224
9225 * sparc-nat.c (gdb_ptrace): New.
9226 * sparc-nat.c (sparc_fetch_inferior_registers)
9227 (sparc_store_inferior_registers) Remove obsolete comment.
9228 * sparc-nat.c (sparc_fetch_inferior_registers)
9229 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
9230 * sparc-nat.c (sparc_fetch_inferior_registers)
9231 (sparc_store_inferior_registers) Use gdb_ptrace.
9232
9233 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9234
9235 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
9236 it to the ptrace call.
9237 * sh-nbsd-nat.c (store_registers): Likewise.
9238
9239 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9240
9241 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
9242 nbsd_nat_target instead of inf_ptrace_target.
9243 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
9244 nbsd_nat_target.
9245
9246 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9247
9248 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
9249
9250 2020-03-17 Kamil Rytarowski <n54@gmx.com>
9251
9252 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
9253 <sys/sysctl.h>.
9254 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
9255
9256 2020-03-17 Tom de Vries <tdevries@suse.de>
9257
9258 PR gdb/23710
9259 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
9260 fields.
9261 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
9262 fields.
9263 (process_imported_unit_die): Skip import of c++ CUs.
9264
9265 2020-03-16 Tom Tromey <tom@tromey.com>
9266
9267 * p-valprint.c (pascal_object_print_value): Initialize
9268 base_value.
9269
9270 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
9271 Shahab Vahedi <shahab@synopsys.com>
9272
9273 * Makefile.in: Add arch/arc.o
9274 * configure.tgt: Likewise.
9275 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
9276 (_initialize_arc_tdep): Don't initialize old target descriptions.
9277 (arc_read_description): New function to cache target descriptions.
9278 * arc-tdep.h (arc_read_description): Add proto type.
9279 * arch/arc.c: New file.
9280 * arch/arc.h: Likewise.
9281 * features/Makefile: Replace old target descriptions with new.
9282 * features/arc-arcompact.c: Remove.
9283 * features/arc-arcompact.xml: Likewise.
9284 * features/arc-v2.c: Likewise
9285 * features/arc-v2.xml: Likewise
9286 * features/arc/aux-arcompact.xml: New file.
9287 * features/arc/aux-v2.xml: Likewise.
9288 * features/arc/core-arcompact.xml: Likewise.
9289 * features/arc/core-v2.xml: Likewise.
9290 * features/arc/aux-arcompact.c: Generate.
9291 * features/arc/aux-v2.c: Likewise.
9292 * features/arc/core-arcompact.c: Likewise.
9293 * features/arc/core-v2.c: Likewise.
9294 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
9295
9296 2020-03-16 Tom Tromey <tromey@adacore.com>
9297
9298 PR gdb/25663:
9299 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
9300 putting value into bcache.
9301
9302 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9303
9304 PR gdb/21500
9305 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
9306 to...
9307 (amd64_windows_init_abi_common): ... this. Don't set size of
9308 long type.
9309 (amd64_windows_init_abi): New function.
9310 (amd64_cygwin_init_abi): New function.
9311 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
9312 the Cygwin OS ABI.
9313 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
9314 comment.
9315
9316 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9317
9318 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
9319 * windows-tdep.c (CYGWIN_DLL_NAME): New.
9320 (pe_import_directory_entry): New struct type.
9321 (is_linked_with_cygwin_dll): New function.
9322 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
9323 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
9324 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
9325
9326 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9327
9328 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
9329 i386_cygwin_core_osabi_sniffer.
9330
9331 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9332
9333 * i386-cygwin-tdep.c: Rename to...
9334 * i386-windows-tdep.c: ... this.
9335 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
9336 i386-windows-tdep.c.
9337 * configure.tgt: Likewise.
9338
9339 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9340
9341 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
9342 * osabi.c (gdb_osabi_names): Add "Windows".
9343 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
9344 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
9345 (i386_cygwin_core_osabi_sniffer): New function, extracted from
9346 i386_cygwin_osabi_sniffer.
9347 (_initialize_i386_cygwin_tdep): Register OS ABI
9348 GDB_OSABI_WINDOWS for i386.
9349 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
9350 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
9351 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
9352 for x86-64.
9353 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
9354 when the target matches '*-*-mingw*'.
9355
9356 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9357
9358 * defs.h (enum gdb_osabi): Move to...
9359 * osabi.h (enum gdb_osabi): ... here.
9360 * gdbarch.sh: Include osabi.h in gdbarch.h.
9361 * gdbarch.h: Re-generate.
9362
9363 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
9364
9365 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
9366 function.
9367 (_initialize_amd64_windows_tdep): Register osabi sniffer.
9368
9369 2020-03-14 Tom Tromey <tom@tromey.com>
9370
9371 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
9372 for C++.
9373 (c_type_print_modifier): Likewise. Add "language" parameter.
9374 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
9375 (c_type_print_base_1): Update.
9376 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
9377 constants.
9378 * type-stack.c (type_stack::insert): Handle tp_atomic and
9379 tp_restrict.
9380 (type_stack::follow_type_instance_flags): Likewise.
9381 (type_stack::follow_types): Likewise. Merge type-following code.
9382 * c-exp.y (RESTRICT, ATOMIC): New tokens.
9383 (space_identifier, cv_with_space_id)
9384 (const_or_volatile_or_space_identifier_noopt)
9385 (const_or_volatile_or_space_identifier): Remove.
9386 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
9387 rules.
9388 (ptr_operator, typebase): Update.
9389 (enum token_flag) <FLAG_C>: New constant.
9390 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
9391 "_Atomic".
9392 (lex_one_token): Handle FLAG_C.
9393
9394 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9395
9396 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
9397 it to the ptrace call.
9398 * m68k-bsd-nat.c (store_registers): Likewise.
9399
9400 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9401
9402 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
9403 gdb_byte *.
9404 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
9405 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
9406 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
9407
9408 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9409
9410 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
9411 nbsd_nat_target instead of inf_ptrace_target.
9412 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
9413 nbsd_nat_target.
9414
9415 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9416
9417 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
9418 register_t.
9419
9420 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9421
9422 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
9423 it to the ptrace call.
9424 * alpha-bsd-nat.c (store_registers): Likewise.
9425
9426 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9427
9428 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
9429 includes.
9430 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
9431 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
9432 fill_fpregset): Likewise.
9433
9434 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9435
9436 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
9437 nbsd_nat_target instead of inf_ptrace_target.
9438 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
9439 nbsd_nat_target.
9440
9441 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9442
9443 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
9444 register_t.
9445
9446 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9447
9448 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
9449 it to the ptrace call.
9450 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
9451 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
9452 * arm-nbsd-nat.c (store_register): Likewise.
9453 * arm-nbsd-nat.c (store_regs): Likewise.
9454 * arm-nbsd-nat.c (store_fp_register): Likewise.
9455 * arm-nbsd-nat.c (store_fp_regs): Likewise.
9456
9457 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9458
9459 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
9460 nbsd_nat_target instead of inf_ptrace_target.
9461 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
9462 nbsd_nat_target.
9463
9464 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9465
9466 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
9467 it to the ptrace call.
9468 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
9469
9470 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9471
9472 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
9473 it to the ptrace call.
9474 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
9475
9476 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9477
9478 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
9479 gdb_byte *.
9480 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
9481
9482 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9483
9484 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
9485 instead of inf_ptrace_target.
9486 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
9487 nbsd_nat_target.
9488
9489 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9490
9491 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
9492 register_t.
9493
9494 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9495
9496 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
9497 register_t.
9498
9499 2020-03-14 Kamil Rytarowski <n54@gmx.com>
9500
9501 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
9502 register_t.
9503
9504 2020-03-13 Tom Tromey <tom@tromey.com>
9505
9506 * value.h (val_print): Don't declare.
9507 * valprint.h (val_print_array_elements)
9508 (val_print_scalar_formatted, generic_val_print): Don't declare.
9509 * valprint.c (generic_val_print_array): Take a struct value.
9510 (generic_val_print_ptr, generic_val_print_memberptr)
9511 (generic_val_print_bool, generic_val_print_int)
9512 (generic_val_print_char, generic_val_print_complex)
9513 (generic_val_print): Remove.
9514 (generic_value_print): Update.
9515 (do_val_print): Remove unused parameters. Don't call
9516 la_val_print.
9517 (val_print): Remove.
9518 (common_val_print): Update. Don't call value_check_printable.
9519 (val_print_scalar_formatted, val_print_array_elements): Remove.
9520 * rust-lang.c (rust_val_print): Remove.
9521 (rust_language_defn): Update.
9522 * p-valprint.c (pascal_val_print): Remove.
9523 (pascal_value_print_inner): Update.
9524 (pascal_object_print_val_fields, pascal_object_print_val):
9525 Remove.
9526 (pascal_object_print_static_field): Update.
9527 * p-lang.h (pascal_val_print): Don't declare.
9528 * p-lang.c (pascal_language_defn): Update.
9529 * opencl-lang.c (opencl_language_defn): Update.
9530 * objc-lang.c (objc_language_defn): Update.
9531 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
9532 * m2-lang.h (m2_val_print): Don't declare.
9533 * m2-lang.c (m2_language_defn): Update.
9534 * language.h (struct language_defn) <la_val_print>: Remove.
9535 * language.c (unk_lang_value_print_inner): Rename. Change
9536 argument types.
9537 (unknown_language_defn, auto_language_defn): Update.
9538 * go-valprint.c (go_val_print): Remove.
9539 * go-lang.h (go_val_print): Don't declare.
9540 * go-lang.c (go_language_defn): Update.
9541 * f-valprint.c (f_val_print): Remove.
9542 * f-lang.h (f_value_print): Don't declare.
9543 * f-lang.c (f_language_defn): Update.
9544 * d-valprint.c (d_val_print): Remove.
9545 * d-lang.h (d_value_print): Don't declare.
9546 * d-lang.c (d_language_defn): Update.
9547 * cp-valprint.c (cp_print_value_fields)
9548 (cp_print_value_fields_rtti, cp_print_value): Remove.
9549 (cp_print_static_field): Update.
9550 * c-valprint.c (c_val_print_array, c_val_print_ptr)
9551 (c_val_print_struct, c_val_print_union, c_val_print_int)
9552 (c_val_print_memberptr, c_val_print): Remove.
9553 * c-lang.h (c_val_print_array, cp_print_value_fields)
9554 (cp_print_value_fields_rtti): Don't declare.
9555 * c-lang.c (c_language_defn, cplus_language_defn)
9556 (asm_language_defn, minimal_language_defn): Update.
9557 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
9558 (ada_val_print_enum): Take a struct value.
9559 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
9560 (ada_val_print): Remove.
9561 (ada_value_print_1): Update.
9562 (printable_val_type): Remove.
9563 * ada-lang.h (ada_val_print): Don't declare.
9564 * ada-lang.c (ada_language_defn): Update.
9565
9566 2020-03-13 Tom Tromey <tom@tromey.com>
9567
9568 * valprint.c (do_val_print): Update.
9569 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
9570 a struct value.
9571 (value_to_value_object_no_release): Declare.
9572 * python/py-value.c (value_to_value_object_no_release): New
9573 function.
9574 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
9575 struct value.
9576 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
9577 function.
9578 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
9579 a struct value.
9580 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
9581 Declare.
9582 (gdbscm_apply_val_pretty_printer): Take a struct value.
9583 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
9584 value.
9585 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
9586 value.
9587 * extension-priv.h (struct extension_language_ops)
9588 <apply_val_pretty_printer>: Take a struct value.
9589 * cp-valprint.c (cp_print_value): Create a struct value.
9590 (cp_print_value): Update.
9591
9592 2020-03-13 Tom Tromey <tom@tromey.com>
9593
9594 * ada-valprint.c (print_field_values): Call common_val_print.
9595
9596 2020-03-13 Tom Tromey <tom@tromey.com>
9597
9598 * ada-valprint.c (val_print_packed_array_elements): Remove
9599 bitoffset and val parameters. Call common_val_print.
9600 (ada_val_print_string): Remove offset, address, and original_value
9601 parameters.
9602 (ada_val_print_array): Update.
9603 (ada_value_print_array): New function.
9604 (ada_value_print_1): Call it.
9605
9606 2020-03-13 Tom Tromey <tom@tromey.com>
9607
9608 * ada-valprint.c (ada_value_print): Use common_val_print.
9609
9610 2020-03-13 Tom Tromey <tom@tromey.com>
9611
9612 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
9613
9614 2020-03-13 Tom Tromey <tom@tromey.com>
9615
9616 * ada-valprint.c (ada_value_print_num): New function.
9617 (ada_value_print_1): Use it.
9618
9619 2020-03-13 Tom Tromey <tom@tromey.com>
9620
9621 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
9622
9623 2020-03-13 Tom Tromey <tom@tromey.com>
9624
9625 * ada-valprint.c (ada_value_print_ptr): New function.
9626 (ada_value_print_1): Use it.
9627
9628 2020-03-13 Tom Tromey <tom@tromey.com>
9629
9630 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
9631 call common_val_print.
9632 (ada_val_print_1): Update.
9633 (ada_value_print_1): New function.
9634 (ada_value_print_inner): Rewrite.
9635
9636 2020-03-13 Tom Tromey <tom@tromey.com>
9637
9638 * cp-valprint.c (cp_print_value_fields): Update.
9639 (cp_print_value): New function.
9640
9641 2020-03-13 Tom Tromey <tom@tromey.com>
9642
9643 * m2-valprint.c (m2_value_print_inner): Use
9644 cp_print_value_fields.
9645 * cp-valprint.c (cp_print_value_fields): New function.
9646 * c-valprint.c (c_value_print_struct): New function.
9647 (c_value_print_inner): Use c_value_print_struct.
9648 * c-lang.h (cp_print_value_fields): Declare.
9649
9650 2020-03-13 Tom Tromey <tom@tromey.com>
9651
9652 * c-valprint.c (c_value_print_array): New function.
9653 (c_value_print_inner): Use it.
9654
9655 2020-03-13 Tom Tromey <tom@tromey.com>
9656
9657 * c-valprint.c (c_value_print_memberptr): New function.
9658 (c_value_print_inner): Use it.
9659
9660 2020-03-13 Tom Tromey <tom@tromey.com>
9661
9662 * c-valprint.c (c_value_print_int): New function.
9663 (c_value_print_inner): Use it.
9664
9665 2020-03-13 Tom Tromey <tom@tromey.com>
9666
9667 * c-valprint.c (c_value_print_ptr): New function.
9668 (c_value_print_inner): Use it.
9669
9670 2020-03-13 Tom Tromey <tom@tromey.com>
9671
9672 * c-valprint.c (c_value_print_inner): Rewrite.
9673
9674 2020-03-13 Tom Tromey <tom@tromey.com>
9675
9676 * valprint.c (generic_value_print_complex): New function.
9677 (generic_value_print): Use it.
9678
9679 2020-03-13 Tom Tromey <tom@tromey.com>
9680
9681 * valprint.c (generic_val_print_float): Don't call
9682 val_print_scalar_formatted.
9683 (generic_val_print, generic_value_print): Update.
9684
9685 2020-03-13 Tom Tromey <tom@tromey.com>
9686
9687 * valprint.c (generic_value_print_char): New function
9688 (generic_value_print): Use it.
9689
9690 2020-03-13 Tom Tromey <tom@tromey.com>
9691
9692 * valprint.c (generic_value_print_int): New function.
9693 (generic_value_print): Use it.
9694
9695 2020-03-13 Tom Tromey <tom@tromey.com>
9696
9697 * valprint.c (generic_value_print_bool): New function.
9698 (generic_value_print): Use it.
9699
9700 2020-03-13 Tom Tromey <tom@tromey.com>
9701
9702 * valprint.c (generic_val_print_func): Simplify.
9703 (generic_val_print, generic_value_print): Update.
9704
9705 2020-03-13 Tom Tromey <tom@tromey.com>
9706
9707 * valprint.c (generic_val_print_flags): Remove.
9708 (generic_val_print, generic_value_print): Update.
9709 (val_print_type_code_flags): Add original_value parameter.
9710
9711 2020-03-13 Tom Tromey <tom@tromey.com>
9712
9713 * valprint.c (generic_val_print): Update.
9714 (generic_value_print): Update.
9715 * valprint.c (generic_val_print_enum): Don't call
9716 val_print_scalar_formatted.
9717
9718 2020-03-13 Tom Tromey <tom@tromey.com>
9719
9720 * valprint.c (generic_value_print): Call generic_value_print_ptr.
9721 * valprint.c (generic_value_print_ptr): New function.
9722
9723 2020-03-13 Tom Tromey <tom@tromey.com>
9724
9725 * valprint.c (generic_value_print): Rewrite.
9726
9727 2020-03-13 Tom Tromey <tom@tromey.com>
9728
9729 * p-valprint.c (pascal_object_print_value_fields)
9730 (pascal_object_print_value): New functions.
9731
9732 2020-03-13 Tom Tromey <tom@tromey.com>
9733
9734 * p-valprint.c (pascal_value_print_inner): Rewrite.
9735
9736 2020-03-13 Tom Tromey <tom@tromey.com>
9737
9738 * f-valprint.c (f_value_print_innner): Rewrite.
9739
9740 2020-03-13 Tom Tromey <tom@tromey.com>
9741
9742 * m2-valprint.c (m2_print_unbounded_array): New overload.
9743 (m2_print_unbounded_array): Update.
9744 (m2_print_array_contents): Take a struct value.
9745 (m2_value_print_inner): Rewrite.
9746
9747 2020-03-13 Tom Tromey <tom@tromey.com>
9748
9749 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
9750 (d_value_print_inner): New function.
9751 * d-lang.h (d_value_print_inner): Declare.
9752 * d-lang.c (d_language_defn): Use d_value_print_inner.
9753
9754 2020-03-13 Tom Tromey <tom@tromey.com>
9755
9756 * go-valprint.c (go_value_print_inner): New function.
9757 * go-lang.h (go_value_print_inner): Declare.
9758 * go-lang.c (go_language_defn): Use go_value_print_inner.
9759
9760 2020-03-13 Tom Tromey <tom@tromey.com>
9761
9762 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
9763 API.
9764 (rust_val_print): Rewrite.
9765 (rust_value_print_inner): New function, from rust_val_print.
9766 (rust_language_defn): Use rust_value_print_inner.
9767
9768 2020-03-13 Tom Tromey <tom@tromey.com>
9769
9770 * ada-valprint.c (ada_value_print_inner): New function.
9771 * ada-lang.h (ada_value_print_inner): Declare.
9772 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
9773
9774 2020-03-13 Tom Tromey <tom@tromey.com>
9775
9776 * f-valprint.c (f_value_print_innner): New function.
9777 * f-lang.h (f_value_print_innner): Declare.
9778 * f-lang.c (f_language_defn): Use f_value_print_innner.
9779
9780 2020-03-13 Tom Tromey <tom@tromey.com>
9781
9782 * p-valprint.c (pascal_value_print_inner): New function.
9783 * p-lang.h (pascal_value_print_inner): Declare.
9784 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
9785
9786 2020-03-13 Tom Tromey <tom@tromey.com>
9787
9788 * m2-valprint.c (m2_value_print_inner): New function.
9789 * m2-lang.h (m2_value_print_inner): Declare.
9790 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
9791
9792 2020-03-13 Tom Tromey <tom@tromey.com>
9793
9794 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
9795 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
9796 * c-valprint.c (c_value_print_inner): New function.
9797 * c-lang.h (c_value_print_inner): Declare.
9798 * c-lang.c (c_language_defn, cplus_language_defn)
9799 (asm_language_defn, minimal_language_defn): Use
9800 c_value_print_inner.
9801
9802 2020-03-13 Tom Tromey <tom@tromey.com>
9803
9804 * p-valprint.c (pascal_object_print_value_fields): Now static.
9805 * p-lang.h (pascal_object_print_value_fields): Don't declare.
9806
9807 2020-03-13 Tom Tromey <tom@tromey.com>
9808
9809 * c-valprint.c (c_val_print_array): Simplify.
9810
9811 2020-03-13 Tom Tromey <tom@tromey.com>
9812
9813 * valprint.c (value_print_array_elements): New function.
9814 * valprint.h (value_print_array_elements): Declare.
9815
9816 2020-03-13 Tom Tromey <tom@tromey.com>
9817
9818 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
9819 * mips-tdep.c (mips_print_register): Use
9820 value_print_scalar_formatted.
9821
9822 2020-03-13 Tom Tromey <tom@tromey.com>
9823
9824 * valprint.h (value_print_scalar_formatted): Declare.
9825 * valprint.c (value_print_scalar_formatted): New function.
9826
9827 2020-03-13 Tom Tromey <tom@tromey.com>
9828
9829 * valprint.h (generic_value_print): Declare.
9830 * valprint.c (generic_value_print): New function.
9831
9832 2020-03-13 Tom Tromey <tom@tromey.com>
9833
9834 * valprint.c (do_val_print): Call la_value_print_inner, if
9835 available.
9836 * rust-lang.c (rust_language_defn): Update.
9837 * p-lang.c (pascal_language_defn): Update.
9838 * opencl-lang.c (opencl_language_defn): Update.
9839 * objc-lang.c (objc_language_defn): Update.
9840 * m2-lang.c (m2_language_defn): Update.
9841 * language.h (struct language_defn) <la_value_print_inner>: New
9842 member.
9843 * language.c (unknown_language_defn, auto_language_defn): Update.
9844 * go-lang.c (go_language_defn): Update.
9845 * f-lang.c (f_language_defn): Update.
9846 * d-lang.c (d_language_defn): Update.
9847 * c-lang.c (c_language_defn, cplus_language_defn)
9848 (asm_language_defn, minimal_language_defn): Update.
9849 * ada-lang.c (ada_language_defn): Update.
9850
9851 2020-03-13 Tom Tromey <tom@tromey.com>
9852
9853 * c-valprint.c (c_value_print): Use common_val_print.
9854
9855 2020-03-13 Tom Tromey <tom@tromey.com>
9856
9857 * cp-valprint.c (cp_print_static_field): Use common_val_print.
9858
9859 2020-03-13 Tom Tromey <tom@tromey.com>
9860
9861 * f-valprint.c (f77_print_array_1, f_val_print): Use
9862 common_val_print.
9863
9864 2020-03-13 Tom Tromey <tom@tromey.com>
9865
9866 * riscv-tdep.c (riscv_print_one_register_info): Use
9867 common_val_print.
9868
9869 2020-03-13 Tom Tromey <tom@tromey.com>
9870
9871 * mi/mi-main.c (output_register): Use common_val_print.
9872
9873 2020-03-13 Tom Tromey <tom@tromey.com>
9874
9875 * infcmd.c (default_print_one_register_info): Use
9876 common_val_print.
9877
9878 2020-03-13 Tom Tromey <tom@tromey.com>
9879
9880 * valprint.h (common_val_print_checked): Declare.
9881 * valprint.c (common_val_print_checked): New function.
9882 * stack.c (print_frame_arg): Use common_val_print_checked.
9883
9884 2020-03-13 Tom Tromey <tom@tromey.com>
9885
9886 * valprint.c (do_val_print): New function, from val_print.
9887 (val_print): Use do_val_print.
9888 (common_val_print): Use do_val_print.
9889
9890 2020-03-13 Tom Tromey <tom@tromey.com>
9891
9892 * valprint.c (value_print): Use scoped_value_mark.
9893
9894 2020-03-13 Tom de Vries <tdevries@suse.de>
9895
9896 PR symtab/25646
9897 * psymtab.c (partial_symtab::partial_symtab): Don't set
9898 globals_offset and statics_offset. Push element onto
9899 current_global_psymbols and current_static_psymbols stacks.
9900 (concat): New function.
9901 (end_psymtab_common): Set globals_offset and statics_offset. Pop
9902 element from current_global_psymbols and current_static_psymbols
9903 stacks. Concat popped elements to global_psymbols and
9904 static_symbols.
9905 (add_psymbol_to_list): Use current_global_psymbols and
9906 current_static_psymbols stacks.
9907 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
9908 current_static_psymbols fields.
9909
9910 2020-03-12 Christian Biesinger <cbiesinger@google.com>
9911
9912 * corelow.c (sniff_core_bfd): Remove.
9913 (class core_target) <m_core_vec>: Remove.
9914 (core_target::core_target): Update.
9915 (core_file_fns): Remove.
9916 (deprecated_add_core_fns): Remove.
9917 (default_core_sniffer): Remove.
9918 (sniff_core_bfd): Remove.
9919 (default_check_format): Remove.
9920 (gdb_check_format): Remove.
9921 (core_target_open): Update.
9922 (core_target::get_core_register_section): Update.
9923 (get_core_registers_cb): Update.
9924 (core_target::fetch_registers): Update.
9925 * gdbcore.h (struct core_fns): Remove.
9926 (deprecated_add_core_fns): Remove.
9927 (default_core_sniffer): Remove.
9928 (default_check_format): Remove.
9929
9930 2020-03-12 Tom Tromey <tom@tromey.com>
9931
9932 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
9933 CORE_ADDR.
9934 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
9935
9936 2020-03-12 Tom Tromey <tom@tromey.com>
9937
9938 * remote.c (remote_target::download_tracepoint)
9939 (remote_target::enable_tracepoint)
9940 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
9941 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
9942 sprintf_vma.
9943
9944 2020-03-12 Tom Tromey <tom@tromey.com>
9945
9946 * symfile-mem.c: Update CORE_ADDR size assert.
9947
9948 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
9949
9950 * selftest.m4: Move to gdbsupport/.
9951 * acinclude.m4: Update path to selftest.m4.
9952
9953 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
9954
9955 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
9956 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
9957 gdbarch-selfselftests.c and selftest-arch.c.
9958 (SUBDIR_UNITTESTS_OBS): Rename to...
9959 (SELFTESTS_OBS): ... this.
9960 (COMMON_SFILES): Remove disasm-selftests.c and
9961 gdbarch-selftests.c.
9962 * configure.ac: Don't add selftest-arch.{c,o} to
9963 CONFIG_{SRCS,OBS}.
9964 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
9965 preprocessor conditions.
9966
9967 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
9968
9969 * configure.ac: Don't source bfd/development.sh.
9970 * selftest.m4: Modify comment.
9971 * configure: Re-generate.
9972
9973 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
9974
9975 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
9976 not "true" or "false".
9977 * configure: Re-generate.
9978
9979 2020-03-12 Christian Biesinger <cbiesinger@google.com>
9980
9981 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
9982 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
9983 renamed to arm_nbsd_supply_gregset.
9984 (fetch_register): Update to call arm_nbsd_supply_gregset.
9985 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
9986 (arm_netbsd_nat_target::fetch_registers): Update.
9987 (fetch_elfcore_registers): Removed.
9988 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
9989 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
9990 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
9991 not require NetBSD system headers.
9992 (arm_nbsd_regset): New struct.
9993 (arm_nbsd_iterate_over_regset_sections): New function.
9994 (arm_netbsd_init_abi_common): Updated to call
9995 set_gdbarch_iterate_over_regset_sections.
9996 * arm-nbsd-tdep.h: New file.
9997
9998 2020-03-11 Kevin Buettner <kevinb@redhat.com>
9999
10000 * symtab.c (find_pc_sect_line): Add check which prevents infinite
10001 recursion.
10002
10003 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
10004
10005 * configure: Re-generate.
10006
10007 2020-03-11 Tom Tromey <tromey@adacore.com>
10008
10009 * ada-typeprint.c (print_choices): Fix comment.
10010
10011 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
10012
10013 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
10014 previous item in the list, when the list has no items.
10015
10016 2020-03-11 Tom de Vries <tdevries@suse.de>
10017
10018 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
10019 PROP_LOCLIST handling code.
10020
10021 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
10022
10023 * buildsym-legacy.c (record_line): Pass extra parameter to
10024 record_line.
10025 * buildsym.c (buildsym_compunit::record_line): Take an extra
10026 parameter, reduce duplication in the line table, and record the
10027 is_stmt flag in the line table.
10028 * buildsym.h (buildsym_compunit::record_line): Add extra
10029 parameter.
10030 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
10031 non-statement lines.
10032 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
10033 this to the symtab builder.
10034 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
10035 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
10036 through to dwarf_record_line_1.
10037 * infrun.c (process_event_stop_test): When stepping, don't stop at
10038 a non-statement instruction, and only refresh the step info when
10039 we land in the middle of a line's range. Also add an extra
10040 comment.
10041 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
10042 field.
10043 * record-btrace.c (btrace_find_line_range): Only record lines
10044 marked as is-statement.
10045 * stack.c (frame_show_address): Show the frame address if we are
10046 in a non-statement sal.
10047 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
10048 (maintenance_print_one_line_table): Print a header for the is_stmt
10049 column, and include is_stmt information in the output.
10050 * symtab.c (find_pc_sect_line): Find lines marked as statements in
10051 preference to non-statements.
10052 (find_pcs_for_symtab_line): Prefer is-statement entries.
10053 (find_line_common): Likewise.
10054 * symtab.h (struct linetable_entry): Add is_stmt field.
10055 (struct symtab_and_line): Likewise.
10056 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
10057 arranging the line table.
10058
10059 2020-03-07 Tom de Vries <tdevries@suse.de>
10060
10061 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
10062 DIE.
10063
10064 2020-03-07 Tom Tromey <tom@tromey.com>
10065
10066 * valops.c (value_literal_complex): Remove obsolete comment.
10067 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
10068 comment.
10069
10070 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
10071
10072 * infrun.h: Forward-declare thread_info.
10073 (set_step_info): Add thread_info parameter, add doc.
10074 * infrun.c (set_step_info): Add thread_info parameter, move doc
10075 to header.
10076 * infrun.c (process_event_stop_test): Pass thread to
10077 set_step_info call.
10078 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
10079 set_step_info.
10080 (prepare_one_step): Add thread_info parameter, pass it to
10081 set_step_frame and prepare_one_step (recursive) call.
10082 (step_1): Pass thread to prepare_one_step call.
10083 (step_command_fsm::should_stop): Pass thread to
10084 prepare_one_step.
10085 (until_next_fsm): Pass thread to set_step_frame call.
10086 (finish_command): Pass thread to set_step_info call.
10087
10088 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
10089
10090 * windows-tdep.c (windows_solib_create_inferior_hook):
10091 Check if inferior is running.
10092
10093 2020-03-06 Tom de Vries <tdevries@suse.de>
10094
10095 * NEWS: Fix "the the".
10096 * ctfread.c: Same.
10097
10098 2020-03-06 Tom de Vries <tdevries@suse.de>
10099
10100 * psymtab.c (psymtab_to_symtab): Don't print "done.".
10101
10102 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
10103
10104 * .dir-locals.el: Add a comment referencing the other copies of
10105 this file.
10106
10107 2020-03-05 John Baldwin <jhb@FreeBSD.org>
10108
10109 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
10110 psargs.
10111
10112 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10113
10114 * .gitattributes: New file.
10115
10116 2020-03-04 Tom Tromey <tom@tromey.com>
10117
10118 * symmisc.c (print_symbol_bcache_statistics)
10119 (print_objfile_statistics): Update.
10120 * symfile.c (allocate_symtab): Use intern.
10121 * psymtab.c (partial_symtab::partial_symtab): Use intern.
10122 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
10123 macro_cache>: Remove.
10124 <string_cache>: New member.
10125 (struct objfile) <intern>: New methods.
10126 * elfread.c (elf_symtab_read): Use intern.
10127 * dwarf2/read.c (fixup_go_packaging): Intern package name.
10128 (dwarf2_compute_name, dwarf2_physname)
10129 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
10130 names.
10131 (guess_partial_die_structure_name): Update.
10132 (partial_die_info::fixup): Intern name.
10133 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
10134 name.
10135 (dwarf2_name): Intern name. Update.
10136 * buildsym.c (buildsym_compunit::get_macro_table): Use
10137 string_cache.
10138
10139 2020-03-04 Tom Tromey <tom@tromey.com>
10140
10141 * jit.c (bfd_open_from_target_memory): Make "target" const.
10142 * corefile.c (gnutarget): Now const.
10143 * gdbcore.h (gnutarget): Now const.
10144
10145 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
10146
10147 * NEWS: Mention support for WOW64 processes.
10148 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
10149 (amd64_windows_segment_register_p): Remove static.
10150 (_initialize_amd64_windows_nat): Update.
10151 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
10152 * i386-windows-nat.c (context_offset): Update.
10153 (i386_mappings): Rename and remove static.
10154 (i386_windows_segment_register_p): Remove static.
10155 (_initialize_i386_windows_nat): Update.
10156 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
10157 (STATUS_WX86_SINGLE_STEP): New macro.
10158 (EnumProcessModulesEx): New macro.
10159 (Wow64SuspendThread): New macro.
10160 (Wow64GetThreadContext): New macro.
10161 (Wow64SetThreadContext): New macro.
10162 (Wow64GetThreadSelectorEntry): New macro.
10163 (windows_set_context_register_offsets): Add static.
10164 (windows_set_segment_register_p): Likewise.
10165 (windows_add_thread): Adapt for WOW64 processes.
10166 (windows_fetch_one_register): Likewise.
10167 (windows_nat_target::fetch_registers): Likewise.
10168 (windows_store_one_register): Likewise.
10169 (display_selector): Likewise.
10170 (display_selectors): Likewise.
10171 (handle_exception): Likewise.
10172 (windows_continue): Likewise.
10173 (windows_nat_target::resume): Likewise.
10174 (windows_add_all_dlls): Likewise.
10175 (do_initial_windows_stuff): Likewise.
10176 (windows_nat_target::attach): Likewise.
10177 (windows_get_exec_module_filename): Likewise.
10178 (windows_nat_target::create_inferior): Likewise.
10179 (windows_xfer_siginfo): Likewise.
10180 (_initialize_loadable): Initialize Wow64SuspendThread,
10181 Wow64GetThreadContext, Wow64SetThreadContext,
10182 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
10183 * windows-nat.h (windows_set_context_register_offsets):
10184 Remove declaration.
10185 (windows_set_segment_register_p): Likewise.
10186 (i386_windows_segment_register_p): Add declaration.
10187 (amd64_windows_segment_register_p): Likewise.
10188
10189 2020-03-04 Luis Machado <luis.machado@linaro.org>
10190
10191 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
10192 in "info registers" for AArch64/ARM.
10193
10194 The change caused "info registers" to not print GPR's.
10195
10196 gdb/ChangeLog:
10197
10198 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
10199
10200 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
10201 when reg->group is empty and reggroup is not.
10202
10203 2020-03-03 Tom Tromey <tromey@adacore.com>
10204
10205 * dwarf2/frame.c (struct dwarf2_frame_cache)
10206 <checked_tailcall_bottom, entry_cfa_sp_offset,
10207 entry_cfa_sp_offset_p>: Remove members.
10208 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
10209 (dwarf2_frame_prev_register): Don't call
10210 dwarf2_tailcall_sniffer_first.
10211 (dwarf2_append_unwinders): Don't append tailcall unwinder.
10212 * frame-unwind.c (add_unwinder): New fuction.
10213 (frame_unwind_init): Use it. Add tailcall unwinder.
10214
10215 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
10216 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
10217
10218 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
10219 value should be printed as true.
10220
10221 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
10222
10223 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
10224 (windows_init_abi): Set and use windows_so_ops.
10225
10226 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
10227
10228 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
10229 when verifying if dealing with a convenience variable.
10230
10231 2020-03-03 Luis Machado <luis.machado@linaro.org>
10232
10233 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
10234
10235 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
10236
10237 * infrun.c (gdbarch_supports_displaced_stepping): New.
10238 (use_displaced_stepping): Break up conditions in smaller pieces.
10239 Use gdbarch_supports_displaced_stepping.
10240 (displaced_step_prepare_throw): Use
10241 gdbarch_supports_displaced_stepping.
10242
10243 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
10244
10245 * NEWS: Mention new behaviour of the history filename.
10246 * top.c (write_history_p): Add comment.
10247 (show_write_history_p): Add header comment, give a different
10248 message when history writing is on, but the history filename is
10249 empty.
10250 (history_filename): Add comment.
10251 (history_filename_empty): New function.
10252 (show_history_filename): Add header comment, give a different
10253 message when the filename is empty.
10254 (init_history): Compare history_filename against nullptr, and only
10255 read history if the filename is not empty.
10256 (set_history_filename): Add header comment, and only make
10257 non-empty filenames absolute.
10258 (init_main): Make the filename argument to 'set history filename'
10259 optional.
10260
10261 2020-03-02 Christian Biesinger <cbiesinger@google.com>
10262
10263 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
10264 (arm_supply_vfpregset): ...this, and update to use VFP registers.
10265 (fetch_fp_register): Update.
10266 (fetch_fp_regs): Update.
10267 (store_fp_register): Update.
10268 (store_fp_regs): Update.
10269 (arm_netbsd_nat_target::read_description): New function.
10270 (fetch_elfcore_registers): Update.
10271
10272 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
10273
10274 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
10275 general_thread if the stop reply is missing a thread-id.
10276 (remote_target::process_stop_reply): Use the first non-exited
10277 thread if the target didn't pass a thread-id.
10278 * infrun.c (do_target_wait): Move call to
10279 switch_to_inferior_no_thread to ....
10280 (do_target_wait_1): ... here.
10281
10282 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
10283
10284 * debuginfod-support.c: Include defs.h first.
10285
10286 2020-02-28 Tom de Vries <tdevries@suse.de>
10287
10288 * symfile.c (set_initial_language): Use default language for lookup.
10289
10290 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
10291
10292 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
10293 reader variable, pass `this` to read_cutu_die_from_dwo.
10294
10295 2020-02-27 Aaron Merey <amerey@redhat.com>
10296
10297 * source.c (open_source_file): Check for nullptr when computing
10298 srcpath.
10299
10300 2020-02-27 Tom Tromey <tromey@adacore.com>
10301
10302 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
10303 member.
10304 (dwarf2_add_field): Don't update nfields.
10305 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
10306
10307 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
10308
10309 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
10310 abs.
10311
10312 2020-02-26 Tom Tromey <tom@tromey.com>
10313
10314 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
10315 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
10316 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
10317 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
10318 per_cu_data.
10319
10320 2020-02-26 Tom Tromey <tom@tromey.com>
10321
10322 * dwarf2/index-write.c (psym_index_map): Change type.
10323 (add_address_entry_worker, write_one_signatured_type)
10324 (recursively_count_psymbols, recursively_write_psymbols)
10325 (class debug_names, psyms_seen_size, write_gdbindex)
10326 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
10327
10328 2020-02-26 Aaron Merey <amerey@redhat.com>
10329
10330 * Makefile.in: Handle optional debuginfod support.
10331 * NEWS: Update.
10332 * README: Add --with-debuginfod summary.
10333 * config.in: Regenerate.
10334 * configure: Regenerate.
10335 * configure.ac: Handle optional debuginfod support.
10336 * debuginfod-support.c: debuginfod helper functions.
10337 * debuginfod-support.h: Ditto.
10338 * doc/gdb.texinfo: Add --with-debuginfod to configure options
10339 summary.
10340 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
10341 when a dwz file cannot be found.
10342 * elfread.c (elf_symfile_read): Query debuginfod servers when a
10343 debuginfo file cannot be found.
10344 * source.c (open_source_file): Query debuginfod servers when a
10345 source file cannot be found.
10346 * top.c (print_gdb_configuration): Include
10347 --{with,without}-debuginfod in the output.
10348
10349 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
10350
10351 * thread.c (thr_try_catch_cmd): Print thread name.
10352
10353 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
10354
10355 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
10356 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
10357 dwarf2_fetch_die_type_sect_off): Move to...
10358 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
10359 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
10360 dwarf2_fetch_die_type_sect_off): ... here.
10361 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
10362 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
10363 dwarf2_fetch_die_type_sect_off): Move doc to header file.
10364
10365 2020-02-26 Tom de Vries <tdevries@suse.de>
10366
10367 PR gdb/25603
10368 * symfile.c (set_initial_language): Exit-early if
10369 language_mode == language_mode_manual.
10370
10371 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
10372
10373 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
10374 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
10375 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
10376
10377 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
10378
10379 * gdbtypes.c (create_array_type_with_stride): Handle negative
10380 array strides.
10381 * valarith.c (value_subscripted_rvalue): Likewise.
10382
10383 2020-02-25 Luis Machado <luis.machado@linaro.org>
10384
10385 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
10386
10387 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
10388
10389 * loc.h (dwarf2_get_die_type): Move to...
10390 * read.h (dwarf2_get_die_type): ... here.
10391 * read.c (dwarf2_get_die_type): Move doc to header.
10392
10393 2020-02-25 Joel Brobecker <brobecker@adacore.com>
10394
10395 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
10396 'gnulib/Makefile.in' to the list.
10397
10398 2020-02-24 Tom Tromey <tom@tromey.com>
10399
10400 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
10401 Remove.
10402 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
10403 XOBNEWVEC.
10404
10405 2020-02-24 Tom Tromey <tom@tromey.com>
10406
10407 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
10408 New method.
10409 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
10410 (dw2_do_instantiate_symtab, dw2_get_file_names)
10411 (build_type_psymtab_dependencies, load_full_type_unit): Update.
10412
10413 2020-02-24 Tom Tromey <tom@tromey.com>
10414
10415 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
10416 make_scoped_restore.
10417 (dwarf2_psymtab::read_symtab): Don't clear
10418 reading_partial_symbols.
10419
10420 2020-02-24 Tom de Vries <tdevries@suse.de>
10421
10422 PR gdb/25592
10423 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
10424
10425 2020-02-24 Tom de Vries <tdevries@suse.de>
10426
10427 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
10428 commands layout next/prev/regs.
10429
10430 2020-02-22 Tom Tromey <tom@tromey.com>
10431
10432 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
10433 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
10434
10435 2020-02-22 Tom Tromey <tom@tromey.com>
10436
10437 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
10438
10439 2020-02-22 Tom Tromey <tom@tromey.com>
10440
10441 * tui/tui-win.c (_initialize_tui_win): Add usage text.
10442 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
10443 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
10444 * tui/tui.c (_initialize_tui): Add usage text.
10445
10446 2020-02-22 Tom Tromey <tom@tromey.com>
10447
10448 * tui/tui-win.c (tui_set_focus_command)
10449 (tui_set_win_height_command): Use error_no_arg.
10450 (_initialize_tui_win): Update help text.
10451 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
10452
10453 2020-02-22 Tom Tromey <tom@tromey.com>
10454
10455 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
10456 * tui/tui-disasm.h (struct tui_disasm_window)
10457 <display_start_addr>: Declare.
10458 * tui/tui-source.h (struct tui_source_window)
10459 <display_start_addr>: Declare.
10460 * tui/tui-winsource.h (struct tui_source_window_base)
10461 <show_source_line, display_start_addr>: New methods.
10462 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
10463 Rename and move to protected section.
10464 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
10465 (tui_source_window_base::do_erase_source_content): Update.
10466 (tui_source_window_base::show_source_line): Now a method.
10467 (tui_source_window_base::show_source_content)
10468 (tui_source_window_base::tui_source_window_base)
10469 (tui_source_window_base::rerender)
10470 (tui_source_window_base::refill)
10471 (tui_source_window_base::do_scroll_horizontal)
10472 (tui_source_window_base::set_is_exec_point_at)
10473 (tui_source_window_base::update_breakpoint_info)
10474 (tui_source_window_base::update_exec_info): Update.
10475 * tui/tui-source.c (tui_source_window::set_contents)
10476 (tui_source_window::showing_source_p)
10477 (tui_source_window::do_scroll_vertical)
10478 (tui_source_window::location_matches_p)
10479 (tui_source_window::line_is_displayed): Update.
10480 (tui_source_window::display_start_addr): New method.
10481 * tui/tui-disasm.c (tui_disasm_window::set_contents)
10482 (tui_disasm_window::do_scroll_vertical)
10483 (tui_disasm_window::location_matches_p): Update.
10484 (tui_disasm_window::display_start_addr): New method.
10485
10486 2020-02-22 Tom Tromey <tom@tromey.com>
10487
10488 * NEWS: Add entry for gdb.register_window_type.
10489 * tui/tui-layout.h (window_factory): New typedef.
10490 (tui_register_window): Declare.
10491 * tui/tui-layout.c (saved_tui_windows): New global.
10492 (tui_apply_current_layout): Use it.
10493 (tui_register_window): New function.
10494 * python/python.c (do_start_initialization): Call
10495 gdbpy_initialize_tui.
10496 (python_GdbMethods): Add "register_window_type" function.
10497 * python/python-internal.h (gdbpy_register_tui_window)
10498 (gdbpy_initialize_tui): Declare.
10499 * python/py-tui.c: New file.
10500 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
10501
10502 2020-02-22 Tom Tromey <tom@tromey.com>
10503
10504 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
10505
10506 2020-02-22 Tom Tromey <tom@tromey.com>
10507
10508 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
10509 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
10510 * tui/tui-data.c (tui_set_win_with_focus): Remove.
10511 (tui_set_win_focus_to): Move from tui-win.c.
10512
10513 2020-02-22 Tom Tromey <tom@tromey.com>
10514
10515 * tui/tui-layout.c (make_standard_window, get_locator_window): New
10516 functions.
10517 (known_window_types): New global.
10518 (tui_get_window_by_name): Reimplement.
10519 (initialize_known_windows): New function.
10520 (validate_window_name): Rewrite.
10521 (_initialize_tui_layout): Call initialize_known_windows.
10522
10523 2020-02-22 Tom Tromey <tom@tromey.com>
10524
10525 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
10526 Remove constants.
10527 * tui/tui-winsource.h (struct tui_source_window_base)
10528 <tui_source_window_base>: Remove parameter.
10529 * tui/tui-winsource.c
10530 (tui_source_window_base::tui_source_window_base): Remove
10531 parameter.
10532 (tui_source_window_base::refill): Update.
10533 * tui/tui-stack.h (struct tui_locator_window)
10534 <tui_locator_window>: Update.
10535 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
10536 Default the constructor.
10537 * tui/tui-regs.h (struct tui_data_item_window)
10538 <tui_data_item_window>: Default the constructor.
10539 (struct tui_data_window) <tui_data_window>: Likewise.
10540 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
10541 Default the constructor.
10542 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
10543 Default the constructor.
10544 <type>: Remove.
10545 (struct tui_win_info) <tui_win_info>: Default the constructor.
10546 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
10547 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
10548 Default the constructor.
10549
10550 2020-02-22 Tom Tromey <tom@tromey.com>
10551
10552 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
10553 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
10554 * tui/tui-win.c (tui_resize_all): Don't call
10555 tui_delete_invisible_windows.
10556 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
10557 done.
10558 (tui_set_layout): Update.
10559 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
10560 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
10561 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
10562
10563 2020-02-22 Tom Tromey <tom@tromey.com>
10564
10565 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
10566 correctly.
10567
10568 2020-02-22 Tom Tromey <tom@tromey.com>
10569
10570 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
10571
10572 2020-02-22 Tom Tromey <tom@tromey.com>
10573
10574 * tui/tui-winsource.h (struct tui_source_window_iterator)
10575 <inner_iterator>: New etytypedef.
10576 <tui_source_window_iterator>: Take "end" parameter.
10577 <tui_source_window_iterator>: Take iterator.
10578 <operator*, advance>: Update.
10579 <m_iter>: Change type.
10580 <m_end>: New field.
10581 (struct tui_source_windows) <begin, end>: Update.
10582 * tui/tui-layout.c (tui_windows): New global.
10583 (tui_apply_current_layout): Clear tui_windows.
10584 (tui_layout_window::apply): Update tui_windows.
10585 * tui/tui-data.h (tui_windows): Declare.
10586 (all_tui_windows): Now inline function.
10587 (class tui_window_iterator, struct all_tui_windows): Remove.
10588
10589 2020-02-22 Tom Tromey <tom@tromey.com>
10590
10591 PR tui/17850:
10592 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
10593 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
10594 "height" argument.
10595 (class tui_layout_window) <get_sizes>: Likewise.
10596 (class tui_layout_split) <tui_layout_split>: Add "vertical"
10597 argument.
10598 <get_sizes>: Add "height" argument.
10599 <m_vertical>: New field.
10600 * tui/tui-layout.c (tui_layout_split::clone): Update.
10601 (tui_layout_split::get_sizes): Add "height" argument.
10602 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
10603 (tui_new_layout_command): Parse "-horizontal".
10604 (_initialize_tui_layout): Update help string.
10605 (tui_layout_split::specification): Add "-horizontal" when needed.
10606 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
10607 argument.
10608 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
10609 New methods.
10610
10611 2020-02-22 Tom Tromey <tom@tromey.com>
10612
10613 * tui/tui-layout.h (enum tui_adjust_result): New.
10614 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
10615 (class tui_layout_window) <adjust_size>: Return
10616 tui_adjust_result. Rewrite.
10617 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
10618 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
10619
10620 2020-02-22 Tom Tromey <tom@tromey.com>
10621
10622 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
10623 parameter and return types.
10624 (class tui_layout_base) <specification>: Add "depth".
10625 (class tui_layout_window) <specification>: Add "depth".
10626 (class tui_layout_split) <specification>: Add "depth".
10627 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
10628 and return types.
10629 (tui_new_layout_command): Parse sub-layouts.
10630 (_initialize_tui_layout): Update help string.
10631 (tui_layout_window::specification): Add "depth".
10632 (add_layout_command): Update.
10633
10634 2020-02-22 Tom Tromey <tom@tromey.com>
10635
10636 * NEWS: Add "tui new-layout" item.
10637 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
10638 Add new-layout command to help text.
10639 (validate_window_name): New function.
10640 (tui_new_layout_command): New function.
10641 (_initialize_tui_layout): Register "new-layout".
10642 (tui_layout_window::specification): New method.
10643 (tui_layout_window::specification): New method.
10644 * tui/tui-layout.h (class tui_layout_base) <specification>: New
10645 method.
10646 (class tui_layout_window) <specification>: New method.
10647 (class tui_layout_split) <specification>: New method.
10648
10649 2020-02-22 Tom Tromey <tom@tromey.com>
10650
10651 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
10652 * tui/tui-win.c (window_name_completer): Update comment.
10653 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
10654 Declare method.
10655 (class tui_layout_window) <replace_window>: Likewise.
10656 (class tui_layout_split) <replace_window>: Likewise.
10657 (tui_set_layout): Don't declare.
10658 (tui_set_initial_layout): Declare function.
10659 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
10660 (asm_regs_layout): New globals.
10661 (tui_current_layout, show_layout): Remove.
10662 (tui_set_layout, tui_add_win_to_layout): Rewrite.
10663 (find_layout, tui_apply_layout): New function.
10664 (layout_completer): Remove.
10665 (tui_next_layout): Reimplement.
10666 (tui_next_layout_command): New function.
10667 (tui_set_initial_layout, tui_prev_layout_command): New functions.
10668 (tui_regs_layout): Reimplement.
10669 (tui_regs_layout_command): New function.
10670 (extract_display_start_addr): Rewrite.
10671 (next_layout, prev_layout): Remove.
10672 (tui_layout_window::replace_window): New method.
10673 (tui_layout_split::replace_window): New method.
10674 (destroy_layout): New function.
10675 (layout_list): New global.
10676 (add_layout_command): New function.
10677 (initialize_layouts): Update.
10678 (tui_layout_command): New function.
10679 (_initialize_tui_layout): Install "layout" commands.
10680 * tui/tui-data.h (enum tui_layout_type): Remove.
10681 (tui_current_layout): Don't declare.
10682
10683 2020-02-22 Tom Tromey <tom@tromey.com>
10684
10685 * tui/tui-regs.c (tui_reg_layout): Remove.
10686 (tui_reg_command): Use tui_regs_layout.
10687 * tui/tui-layout.h (tui_reg_command): Declare.
10688 * tui/tui-layout.c (tui_reg_command): New function.
10689
10690 2020-02-22 Tom Tromey <tom@tromey.com>
10691
10692 * tui/tui.c (tui_rl_delete_other_windows): Call
10693 tui_remove_some_windows.
10694 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
10695 Declare method.
10696 (class tui_layout_window) <remove_windows>: New method.
10697 (class tui_layout_split) <remove_windows>: Declare.
10698 (tui_remove_some_windows): Declare.
10699 * tui/tui-layout.c (tui_remove_some_windows): New function.
10700 (tui_layout_split::remove_windows): New method.
10701
10702 2020-02-22 Tom Tromey <tom@tromey.com>
10703
10704 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
10705 * tui/tui-layout.h (tui_next_layout): Declare.
10706 * tui/tui-layout.c (tui_next_layout): New function.
10707
10708 2020-02-22 Tom Tromey <tom@tromey.com>
10709
10710 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
10711 correct coordinates.
10712
10713 2020-02-22 Tom Tromey <tom@tromey.com>
10714
10715 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
10716 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
10717 DATA_WIN case.
10718
10719 2020-02-22 Tom Tromey <tom@tromey.com>
10720
10721 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
10722 TUI_DISASM_WIN, not tui_win_list.
10723
10724 2020-02-22 Tom Tromey <tom@tromey.com>
10725
10726 * valprint.c (generic_val_print_enum_1)
10727 (val_print_type_code_flags): Style member names.
10728 * rust-lang.c (val_print_struct, rust_print_enum)
10729 (rust_print_struct_def, rust_internal_print_type): Style member
10730 names.
10731 * p-valprint.c (pascal_object_print_value_fields): Style member
10732 names. Only call fprintf_symbol_filtered for static members.
10733 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
10734 * f-valprint.c (f_val_print): Style member names.
10735 * f-typeprint.c (f_type_print_base): Style member names.
10736 * cp-valprint.c (cp_print_value_fields): Style member names. Only
10737 call fprintf_symbol_filtered for static members.
10738 (cp_print_class_member): Style member names.
10739 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
10740 member names.
10741 * ada-valprint.c (ada_print_scalar): Style enum names.
10742 (ada_val_print_enum): Likewise.
10743 * ada-typeprint.c (print_enum_type): Style enum names.
10744
10745 2020-02-21 Tom Tromey <tom@tromey.com>
10746
10747 * psympriv.h (struct partial_symtab): Update comment.
10748
10749 2020-02-21 Tom Tromey <tromey@adacore.com>
10750
10751 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
10752 type is CORE_ADDR.
10753
10754 2020-02-21 Tom de Vries <tdevries@suse.de>
10755
10756 PR gdb/25534
10757 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
10758 if dependencies[i]->user != NULL.
10759
10760 2020-02-21 Ali Tamur <tamur@google.com>
10761
10762 * dwarf2/read.c (dwarf2_name): Add null check.
10763
10764 2020-02-20 Tom Tromey <tom@tromey.com>
10765
10766 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
10767 ">=", in binary search.
10768 (dwarf2_find_containing_comp_unit): New overload.
10769 (run_test): New self-test.
10770 (_initialize_dwarf2_read): Register new test.
10771
10772 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
10773
10774 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
10775 * riscv-tdep.h: Likewise.
10776 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
10777 rv32-only CSR.
10778 * features/riscv/64bit-csr.xml: Regenerated.
10779
10780 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10781 Tom Tromey <tom@tromey.com>
10782
10783 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
10784 of 'fputc_unfiltered'.
10785 (putchar_unfiltered): Call 'fputc_unfiltered'.
10786 (fputc_unfiltered): Call 'fputs_unfiltered'.
10787
10788 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
10789
10790 * config.in: Regenerate.
10791 * configure: Regenerate.
10792 * configure.ac: Add --with-python-libdir option.
10793 * main.c: Use WITH_PYTHON_LIBDIR.
10794
10795 2020-02-19 Tom Tromey <tom@tromey.com>
10796
10797 * symtab.c (general_symbol_info::compute_and_set_names): Use
10798 obstack_strndup. Simplify call to symbol_set_demangled_name.
10799
10800 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
10801
10802 * dwarf2/read.c (allocate_signatured_type_table,
10803 allocate_dwo_unit_table, allocate_type_unit_groups_table,
10804 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
10805 Remove objfile parameter, update all callers.
10806
10807 2020-02-19 Doug Evans <dje@google.com>
10808
10809 PR rust/25535
10810 * rust-lang.c (rust_print_enum): Apply embedded_offset to
10811 rust_enum_variant calculation.
10812
10813 2020-02-19 Tom Tromey <tromey@adacore.com>
10814
10815 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
10816
10817 2020-02-19 Tom Tromey <tromey@adacore.com>
10818
10819 * ada-lang.c (cache_symbol): Use obstack_strdup.
10820
10821 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
10822
10823 * configure: Regenerate.
10824
10825 2020-02-19 Tom Tromey <tromey@adacore.com>
10826
10827 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
10828 NULL check.
10829
10830 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
10831
10832 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
10833
10834 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
10835
10836 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
10837 if GDBSERVER is not defined.
10838 (riscv_tdesc_cache): Likewise, also store const target_desc.
10839 (STATIC_IN_GDB): Define.
10840 (riscv_create_target_description): Update declaration with
10841 STATIC_IN_GDB.
10842 (riscv_lookup_target_description): New function, only define if
10843 GDBSERVER is not defined.
10844 * arch/riscv.h (riscv_create_target_description): Declare only
10845 when GDBSERVER is defined.
10846 (riscv_lookup_target_description): New declaration when GDBSERVER
10847 is not defined.
10848 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
10849 (riscv_linux_read_features): ...this, and return
10850 riscv_gdbarch_features instead of target_desc.
10851 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
10852 (riscv_linux_read_description): Rename to...
10853 (riscv_linux_read_features): ...this.
10854 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
10855 Update to use riscv_gdbarch_features and
10856 riscv_lookup_target_description.
10857 * riscv-tdep.c (riscv_find_default_target_description): Use
10858 riscv_lookup_target_description instead of
10859 riscv_create_target_description.
10860
10861 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
10862
10863 * valprint.c (generic_val_print_enum_1): When printing a flag
10864 enum with value 0 and there is no enumerator with value 0, print
10865 just "0" instead of "(unknown: 0x0)".
10866
10867 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
10868
10869 * valprint.c (generic_val_print_enum_1): Print unknown part of
10870 flag enum in hex.
10871
10872 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
10873
10874 * dwarf2/read.c (update_enumeration_type_from_children): Allow
10875 flag enums to contain duplicate enumerators.
10876 * valprint.c (generic_val_print_enum_1): Update comment.
10877
10878 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
10879
10880 * dwarf2/read.c: Include "count-one-bits.h".
10881 (update_enumeration_type_from_children): If an enumerator has
10882 multiple bits set, don't treat the enumeration as a "flag enum".
10883 * valprint.c (generic_val_print_enum_1): Assert that enumerators
10884 of flag enums have 0 or 1 bit set.
10885
10886 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
10887
10888 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
10889 conversion.
10890 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
10891 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
10892 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
10893 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
10894 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
10895
10896 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
10897
10898 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
10899
10900 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
10901
10902 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
10903 displaced_step_closure_up.
10904 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
10905 (struct displaced_step_closure_up):
10906 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
10907 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
10908 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
10909 Likewise.
10910 * gdbarch.sh (displaced_step_copy_insn): Likewise.
10911 * gdbarch.c, gdbarch.h: Re-generate.
10912 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
10913 displaced_step_closure_up.
10914 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
10915 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
10916 * infrun.h (displaced_step_closure_up): New type alias.
10917 (struct displaced_step_inferior_state) <step_closure>: Change
10918 type to displaced_step_closure_up.
10919 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
10920 displaced_step_closure_up.
10921 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
10922
10923 2020-02-14 Tom Tromey <tom@tromey.com>
10924
10925 * minidebug.c (gnu_debug_key): New global.
10926 (find_separate_debug_file_in_section): Use it.
10927
10928 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
10929
10930 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
10931 std::unique_ptr.
10932 * gdbarch.c: Re-generate.
10933 * gdbarch.h: Re-generate.
10934 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
10935 change.
10936 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
10937 type to std::unique_ptr.
10938 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
10939 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
10940 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
10941 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
10942 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
10943 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
10944 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
10945 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
10946 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
10947
10948 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
10949
10950 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
10951 std::unique_ptr.
10952 (displaced_step_clear): Rename to...
10953 (displaced_step_reset): ... this. Just call displaced->reset ().
10954 (displaced_step_clear_cleanup): Rename to...
10955 (displaced_step_reset_cleanup): ... this.
10956 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
10957 (displaced_step_fixup): Likewise.
10958 (resume_1): Likewise.
10959 (handle_inferior_event): Restore child's memory before calling
10960 displaced_step_fixup on the parent.
10961 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
10962 to std::unique_ptr.
10963 <step_closure>: Change type to std::unique_ptr.
10964
10965 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
10966
10967 * arm-tdep.c: Include count-one-bits.h.
10968 (cleanup_block_store_pc): Use count_one_bits.
10969 (cleanup_block_load_pc): Use count_one_bits.
10970 (arm_copy_block_xfer): Use count_one_bits.
10971 (thumb2_copy_block_xfer): Use count_one_bits.
10972 (thumb_copy_pop_pc_16bit): Use count_one_bits.
10973 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
10974 (thumb_get_next_pcs_raw): Use count_one_bits.
10975 (arm_get_next_pcs_raw): Use count_one_bits_l.
10976 * arch/arm.c (bitcount): Remove.
10977 * arch/arm.h (bitcount): Remove.
10978
10979 2020-02-14 Tom Tromey <tromey@adacore.com>
10980
10981 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
10982 Update.
10983 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
10984 * dwarf2/loc.c (call_site_find_chain_1): Return
10985 unique_xmalloc_ptr.
10986 (call_site_find_chain): Likewise.
10987
10988 2020-02-14 Richard Biener <rguenther@suse.de>
10989
10990 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
10991 on expression with division operators.
10992
10993 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
10994
10995 * MAINTAINERS (Write After Approval): Adding myself.
10996
10997 2020-02-12 Tom Tromey <tom@tromey.com>
10998
10999 * event-loop.c (event_data, gdb_event, event_handler_func):
11000 Remove.
11001
11002 2020-02-12 Tom Tromey <tom@tromey.com>
11003
11004 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
11005 (dwarf2_frame_objfile_data): Add comment.
11006 (find_comp_unit, set_comp_unit): New functions.
11007 (dwarf2_frame_find_fde): Use find_comp_unit.
11008 (dwarf2_build_frame_info): Use set_comp_unit.
11009
11010 2020-02-12 Tom Tromey <tom@tromey.com>
11011
11012 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
11013 (comp_unit): Don't initialize objfile.
11014 (execute_cfa_program): Add text_offset parameter.
11015 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
11016 (dwarf2_frame_cache): Update.
11017 (dwarf2_build_frame_info): Don't set "objfile" member.
11018
11019 2020-02-12 Tom Tromey <tom@tromey.com>
11020
11021 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
11022 (decode_frame_entry): Likewise.
11023 (dwarf2_build_frame_info): Update.
11024
11025 2020-02-12 Tom Tromey <tom@tromey.com>
11026
11027 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
11028 (decode_frame_entry_1): Use the comp_unit obstack.
11029
11030 2020-02-12 Tom Tromey <tom@tromey.com>
11031
11032 * dwarf2/frame.c (struct comp_unit): Add initializers and
11033 constructor.
11034 (dwarf2_frame_objfile_data): Store a comp_unit.
11035 (dwarf2_frame_find_fde): Update.
11036 (dwarf2_build_frame_info): Use "new".
11037
11038 2020-02-12 Tom Tromey <tom@tromey.com>
11039
11040 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
11041 (dwarf2_fde_table): Typedef for std::vector.
11042 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
11043 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
11044 (decode_frame_entry): Update.
11045 (dwarf2_build_frame_info): Use "new".
11046
11047 2020-02-12 Christian Biesinger <cbiesinger@google.com>
11048
11049 * arm-tdep.c (arm_gdbarch_init): Update.
11050 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
11051 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
11052 have_neon, is_m>: Change to bool.
11053
11054 2020-02-12 Christian Biesinger <cbiesinger@google.com>
11055
11056 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
11057
11058 2020-02-12 Tom Tromey <tom@tromey.com>
11059
11060 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
11061
11062 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
11063
11064 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
11065 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
11066
11067 2020-02-11 Tom Tromey <tom@tromey.com>
11068
11069 * psymtab.h: Update comment.
11070
11071 2020-02-11 Tom Tromey <tom@tromey.com>
11072
11073 * gdb_obstack.h (struct auto_obstack): Use
11074 DISABLE_COPY_AND_ASSIGN.
11075
11076 2020-02-11 Tom Tromey <tom@tromey.com>
11077
11078 * dwarf2/frame.h (struct objfile): Don't forward declare.
11079
11080 2020-02-11 Christian Biesinger <cbiesinger@google.com>
11081
11082 * cris-tdep.c (cris_supply_gregset): Change signature to match
11083 what struct regset expects.
11084 (cris_regset): New struct.
11085 (fetch_core_registers): Remove.
11086 (cris_iterate_over_regset_sections): New function.
11087 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
11088 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
11089
11090 2020-02-11 Christian Biesinger <cbiesinger@google.com>
11091
11092 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
11093 registers.
11094
11095 2020-02-11 Christian Biesinger <cbiesinger@google.com>
11096
11097 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
11098
11099 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
11100
11101 * configure: Re-generate.
11102
11103 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
11104
11105 * configure: Re-generate.
11106
11107 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
11108
11109 * acinclude: Update warning.m4 path.
11110 * warning.m4: Move to gdbsupport.
11111
11112 2020-02-11 Tom Tromey <tromey@adacore.com>
11113
11114 * remote.c (remote_console_output): Update.
11115 * printcmd.c (printf_command): Update.
11116 * event-loop.c (gdb_wait_for_event): Update.
11117 * linux-nat.c (sigchld_handler): Update.
11118 * remote-sim.c (gdb_os_write_stdout): Update.
11119 (gdb_os_flush_stdout): Update.
11120 (gdb_os_flush_stderr): Update.
11121 (gdb_os_write_stderr): Update.
11122 * exceptions.c (print_exception): Update.
11123 * remote-fileio.c (remote_fileio_func_read): Update.
11124 (remote_fileio_func_write): Update.
11125 * tui/tui.c (tui_enable): Update.
11126 * tui/tui-interp.c (tui_interp::init): Update.
11127 * utils.c (init_page_info): Update.
11128 (putchar_unfiltered, fputc_unfiltered): Update.
11129 (gdb_flush): Update.
11130 (emit_style_escape): Update.
11131 (flush_wrap_buffer, fputs_maybe_filtered): Update.
11132 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
11133 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
11134 (stderr_file::write): Update.
11135 (stderr_file::puts): Update.
11136 * ui-file.h (ui_file_isatty, ui_file_write)
11137 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
11138 (ui_file_puts): Don't declare.
11139
11140 2020-02-10 Tom de Vries <tdevries@suse.de>
11141
11142 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
11143 sentinel to char *.
11144
11145 2020-02-09 Tom de Vries <tdevries@suse.de>
11146
11147 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
11148 filename if it matches "<artificial>".
11149
11150 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
11151
11152 * windows-tdep.c (struct enum_value_name): New struct.
11153 (create_enum): New function.
11154 (windows_get_siginfo_type): Create and use enum types.
11155
11156 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
11157
11158 * NEWS: Mention $_siginfo support for Windows.
11159 * windows-nat.c (handle_exception): Set siginfo_er.
11160 (windows_nat_target::mourn_inferior): Reset siginfo_er.
11161 (windows_xfer_siginfo): New function.
11162 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
11163 * windows-tdep.c (struct windows_gdbarch_data): New struct.
11164 (init_windows_gdbarch_data): New function.
11165 (get_windows_gdbarch_data): New function.
11166 (windows_get_siginfo_type): New function.
11167 (windows_init_abi): Register windows_get_siginfo_type.
11168 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
11169
11170 2020-02-08 Tom Tromey <tom@tromey.com>
11171
11172 * dwarf2/read.c (class cutu_reader) <cutu_reader,
11173 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
11174 <keep>: Declare method.
11175 <m_keep>: Remove member.
11176 <~cutu_reader>: Remove.
11177 (cutu_reader::init_tu_and_read_dwo_dies): Update.
11178 (cutu_reader::cutu_reader): Update.
11179 (cutu_reader::keep): Rename from ~cutu_reader.
11180 (process_psymtab_comp_unit, build_type_psymtabs_1)
11181 (process_skeletonless_type_unit, load_partial_comp_unit)
11182 (load_full_comp_unit, dwarf2_read_addr_index)
11183 (read_signatured_type): Update.
11184
11185 2020-02-08 Tom Tromey <tom@tromey.com>
11186
11187 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
11188 "want_partial_unit" parameter.
11189 (process_psymtab_comp_unit): Change want_partial_unit to bool.
11190 Inline check for DW_TAG_partial_unit.
11191 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
11192
11193 2020-02-08 Tom Tromey <tom@tromey.com>
11194
11195 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
11196 read.c.
11197 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
11198 read.c.
11199
11200 2020-02-08 Tom Tromey <tom@tromey.com>
11201
11202 * dwarf2/read.c (read_address): Move to comp-unit.c.
11203 (dwarf2_rnglists_process, dwarf2_ranges_process)
11204 (read_attribute_value, dwarf_decode_lines_1)
11205 (var_decode_location, decode_locdesc): Update.
11206 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
11207 read.c. Remove "cu" parameter.
11208 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
11209 method.
11210
11211 2020-02-08 Tom Tromey <tom@tromey.com>
11212
11213 * dwarf2/read.c (read_attribute_value, read_indirect_string)
11214 (read_indirect_line_string): Update.
11215 * dwarf2/comp-unit.c (read_offset): Remove.
11216 (read_comp_unit_head): Update.
11217 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
11218 method.
11219 (read_offset): Don't declare.
11220
11221 2020-02-08 Tom Tromey <tom@tromey.com>
11222
11223 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
11224 * dwarf2/read.c (struct comp_unit_head): Move to
11225 dwarf2/comp-unit.h.
11226 (enum class rcuh_kind): Move to comp-unit.h.
11227 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
11228 (read_comp_unit_head, error_check_comp_unit_head)
11229 (read_and_check_comp_unit_head): Move to comp-unit.c.
11230 (read_offset, dwarf_unit_type_name): Likewise.
11231 (create_debug_type_hash_table, read_cutu_die_from_dwo)
11232 (cutu_reader::cutu_reader, read_call_site_scope)
11233 (find_partial_die, follow_die_offset): Update.
11234 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
11235
11236 2020-02-08 Tom Tromey <tom@tromey.com>
11237
11238 * dwarf2/read.c (read_offset_1): Move to leb.c.
11239 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
11240 (dwarf_decode_macro_bytes): Update.
11241 * dwarf2/leb.c (read_offset): Rename; move from read.c.
11242 * dwarf2/leb.h (read_offset): Declare.
11243
11244 2020-02-08 Tom Tromey <tom@tromey.com>
11245
11246 * dwarf2/read.c (dwarf2_section_size): Remove.
11247 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
11248 Update.
11249 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
11250
11251 2020-02-08 Tom Tromey <tom@tromey.com>
11252
11253 * dwarf2/read.c (read_initial_length): Move to leb.c.
11254 * dwarf2/leb.h (read_initial_length): Declare.
11255 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
11256 handle_nonstd parameter.
11257 * dwarf2/frame.c (read_initial_length): Remove.
11258 (decode_frame_entry_1): Update.
11259
11260 2020-02-08 Tom Tromey <tom@tromey.com>
11261
11262 * dwarf2/loc.c (dwarf2_find_location_expression)
11263 (dwarf_evaluate_loc_desc::get_tls_address)
11264 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
11265 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
11266 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
11267 (dwarf2_compile_property_to_c)
11268 (dwarf2_loc_desc_get_symbol_read_needs)
11269 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
11270 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
11271 (loclist_describe_location, loclist_tracepoint_var_ref)
11272 (loclist_generate_c_location): Update.
11273 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
11274 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
11275 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
11276 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
11277 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
11278 (dwarf2_per_cu_data::addr_size)
11279 (dwarf2_per_cu_data::ref_addr_size)
11280 (dwarf2_per_cu_data::text_offset)
11281 (dwarf2_per_cu_data::addr_type): Now methods.
11282 (per_cu_header_read_in): Make per_cu "const".
11283 (dwarf2_version): Remove.
11284 (dwarf2_per_cu_data::int_type): Now a method.
11285 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
11286 (set_die_type, read_array_type, read_subrange_index_type)
11287 (read_tag_string_type, read_subrange_type): Update.
11288 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
11289 offset_size, ref_addr_size, text_offset, addr_type, version,
11290 objfile, int_type, addr_sized_int_type>: Declare methods.
11291
11292 2020-02-08 Tom Tromey <tom@tromey.com>
11293
11294 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
11295 Move earlier.
11296
11297 2020-02-08 Tom Tromey <tom@tromey.com>
11298
11299 * dwarf2/read.h (dwarf_line_debug): Declare.
11300 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
11301 * dwarf2/read.c: Move line_header code to new files.
11302 (dwarf_line_debug): No longer static.
11303 * dwarf2/line-header.c: New file.
11304 * dwarf2/line-header.h: New file.
11305
11306 2020-02-08 Tom Tromey <tom@tromey.com>
11307
11308 * dwarf2/read.c (struct line_header) <file_full_name,
11309 file_file_name>: Return unique_xmalloc_ptr.
11310 (line_header::file_file_name): Update.
11311 (line_header::file_full_name): Update.
11312 (dw2_get_file_names_reader): Update.
11313 (macro_start_file): Update.
11314
11315 2020-02-08 Tom Tromey <tom@tromey.com>
11316
11317 * dwarf2/read.c (struct line_header) <file_full_name,
11318 file_file_name>: Declare methods.
11319 (dw2_get_file_names_reader): Update.
11320 (file_file_name): Now a method.
11321 (file_full_name): Likewise.
11322 (macro_start_file): Update.
11323
11324 2020-02-08 Tom Tromey <tom@tromey.com>
11325
11326 * dwarf2/read.c (dwarf_always_disassemble)
11327 (show_dwarf_always_disassemble): Move to loc.c.
11328 (_initialize_dwarf2_read): Move "always-disassemble" registration
11329 to loc.c.
11330 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
11331 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
11332 static.
11333 (show_dwarf_always_disassemble): Move from read.c.
11334 (_initialize_dwarf2loc): Move always-disassemble from read.c.
11335
11336 2020-02-08 Tom Tromey <tom@tromey.com>
11337
11338 * dwarf2/read.c (~dwarf2_per_objfile): Update.
11339 (create_quick_file_names_table): Return htab_up.
11340 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
11341 Update.
11342 * dwarf2/read.h (struct dwarf2_per_objfile)
11343 <quick_file_names_table>: Now htab_up.
11344
11345 2020-02-08 Tom Tromey <tom@tromey.com>
11346
11347 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
11348
11349 2020-02-08 Tom Tromey <tom@tromey.com>
11350
11351 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
11352 Rewrite.
11353 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
11354 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
11355 (abbrev_table::abbrev_table): No longer inline.
11356 (ABBREV_HASH_SIZE): Remove.
11357 (abbrev_table::m_abbrevs): Now an htab_up.
11358
11359 2020-02-08 Tom Tromey <tom@tromey.com>
11360
11361 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
11362 (cutu_reader): Update.
11363 (build_type_psymtabs_1): Update.
11364 * dwarf2/abbrev.c (abbrev_table::read): Rename.
11365 (abbrev_table::alloc_abbrev): Update.
11366 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
11367 (abbrev_table::read): New static method, renamed from
11368 abbrev_table_read_table.
11369 (abbrev_table::alloc_abbrev)
11370 (abbrev_table::add_abbrev): Now private.
11371 (abbrev_table::abbrev_table): Now private.
11372 (abbrev_table::m_abbrev_obstack): Now private. Rename.
11373
11374 2020-02-08 Tom Tromey <tom@tromey.com>
11375
11376 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
11377 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
11378 htab_up.
11379
11380 2020-02-08 Tom Tromey <tom@tromey.com>
11381
11382 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
11383 htab_up.
11384 (lookup_dwo_unit_in_dwp): Update.
11385 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
11386 on obstack.
11387
11388 2020-02-08 Tom Tromey <tom@tromey.com>
11389
11390 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
11391 obstack.
11392
11393 2020-02-08 Tom Tromey <tom@tromey.com>
11394
11395 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
11396 line_header_hash.
11397 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
11398 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
11399 Change type to htab_up.
11400
11401 2020-02-08 Tom Tromey <tom@tromey.com>
11402
11403 * dwarf2/read.c (allocate_type_unit_groups_table): Return
11404 htab_up. Don't allocate on obstack.
11405 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
11406 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
11407 Change type to htab_up.
11408
11409 2020-02-08 Tom Tromey <tom@tromey.com>
11410
11411 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
11412 Change type to htab_up.
11413 * dwarf2/read.c (create_signatured_type_table_from_index)
11414 (create_signatured_type_table_from_debug_names)
11415 (create_all_type_units, add_type_unit)
11416 (lookup_dwo_signatured_type, lookup_signatured_type)
11417 (process_skeletonless_type_unit): Update.
11418 (create_debug_type_hash_table, create_debug_types_hash_table):
11419 Change type of types_htab.
11420 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
11421 htab_up. Don't allocate on obstack.
11422 (create_cus_hash_table): Change type of cus_htab parameter.
11423 (struct dwo_file) <cus, tus>: Now htab_up.
11424 (lookup_dwo_signatured_type, lookup_dwo_cutu)
11425 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
11426 (queue_and_load_all_dwo_tus): Update.
11427 * dwarf2/index-write.c (write_gdbindex): Update.
11428 (write_debug_names): Update.
11429
11430 2020-02-08 Tom Tromey <tom@tromey.com>
11431
11432 * dwarf2/read.h (struct dwarf2_queue_item): Move from
11433 dwarf2/read.c. Remove "next" member. Add constructor ntad
11434 destructor.
11435 (struct dwarf2_per_objfile) <queue>: New member.
11436 * dwarf2/read.c (struct dwarf2_queue_item): Move to
11437 dwarf2/read.h.
11438 (dwarf2_queue, dwarf2_queue_tail): Remove.
11439 (class dwarf2_queue_guard): Add parameter to constructor. Use
11440 DISABLE_COPY_AND_ASSIGN.
11441 <m_per_objfile>: New member.
11442 <~dwarf2_queue_guard>: Rewrite.
11443 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
11444 Update.
11445 (~dwarf2_queue_item): New.
11446
11447 2020-02-08 Tom Tromey <tom@tromey.com>
11448
11449 * dwarf2/read.c (struct die_info) <has_children>: New member.
11450 (dw2_get_file_names_reader): Remove has_children.
11451 (dw2_get_file_names): Update.
11452 (read_cutu_die_from_dwo): Remove has_children.
11453 (cutu_reader::init_tu_and_read_dwo_dies)
11454 (cutu_reader::cutu_reader): Update.
11455 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
11456 Remove has_children.
11457 (build_type_psymtabs_1, process_skeletonless_type_unit)
11458 (load_partial_comp_unit, load_full_comp_unit): Update.
11459 (create_dwo_cu_reader): Remove has_children.
11460 (create_cus_hash_table, read_die_and_children): Update.
11461 (read_full_die_1,read_full_die): Remove has_children.
11462 (read_signatured_type): Update.
11463 (class cutu_reader) <has_children>: Remove.
11464
11465 2020-02-08 Tom Tromey <tom@tromey.com>
11466
11467 * dwarf2/expr.c: Rename from dwarf2expr.c.
11468 * dwarf2/expr.h: Rename from dwarf2expr.h.
11469 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
11470 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
11471 * dwarf2/frame.c: Rename from dwarf2-frame.c.
11472 * dwarf2/frame.h: Rename from dwarf2-frame.h.
11473 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
11474 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
11475 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
11476 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
11477 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
11478 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
11479 * dwarf2/loc.c: Rename from dwarf2loc.c.
11480 * dwarf2/loc.h: Rename from dwarf2loc.h.
11481 * dwarf2/read.c: Rename from dwarf2read.c.
11482 * dwarf2/read.h: Rename from dwarf2read.h.
11483 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
11484 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
11485 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
11486 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
11487 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
11488 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
11489 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
11490 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
11491 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
11492 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
11493 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
11494 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
11495 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
11496 Update.
11497 * Makefile.in (COMMON_SFILES): Update.
11498 (HFILES_NO_SRCDIR): Update.
11499
11500 2020-02-08 Tom Tromey <tom@tromey.com>
11501
11502 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
11503 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
11504
11505 2020-02-08 Tom Tromey <tom@tromey.com>
11506
11507 * dwarf2read.h (struct die_info): Don't declare.
11508
11509 2020-02-08 Tom Tromey <tom@tromey.com>
11510
11511 * dwarf2read.h (die_info_ptr): Remove typedef.
11512
11513 2020-02-08 Tom Tromey <tom@tromey.com>
11514
11515 * dwarf2read.c (read_call_site_scope)
11516 (handle_data_member_location, dwarf2_add_member_fn)
11517 (mark_common_block_symbol_computed, read_common_block)
11518 (attr_to_dynamic_prop, partial_die_info::read)
11519 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
11520 (dwarf2_symbol_mark_computed, set_die_type): Update.
11521 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
11522 method.
11523 (attr_form_is_block): Don't declare.
11524 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
11525
11526 2020-02-08 Tom Tromey <tom@tromey.com>
11527
11528 * dwarf2read.c (dwarf2_find_base_address, )
11529 (read_call_site_scope, rust_containing_type)
11530 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
11531 (handle_data_member_location, dwarf2_add_member_fn)
11532 (get_alignment, read_structure_type, process_structure_scope)
11533 (mark_common_block_symbol_computed, read_common_block)
11534 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
11535 (partial_die_info::read, read_attribute_value, new_symbol)
11536 (lookup_die_type, dwarf2_get_ref_die_offset)
11537 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
11538 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
11539 (dwarf2_symbol_mark_computed): Update.
11540 * dwarf2/attribute.h (struct attribute) <value_as_address,
11541 form_is_section_offset, form_is_constant, form_is_ref>: Declare
11542 methods.
11543 (value_as_address, attr_form_is_section_offset)
11544 (attr_form_is_constant, attr_form_is_ref): Don't declare.
11545 * dwarf2/attribute.c (attribute::value_as_address)
11546 (attribute::form_is_section_offset, attribute::form_is_constant)
11547 (attribute::form_is_ref): Now methods.
11548
11549 2020-02-08 Tom Tromey <tom@tromey.com>
11550
11551 * dwarf2read.c (struct attribute, DW_STRING)
11552 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
11553 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
11554 (attr_form_is_block, attr_form_is_section_offset)
11555 (attr_form_is_constant, attr_form_is_ref): Move.
11556 * dwarf2/attribute.h: New file.
11557 * dwarf2/attribute.c: New file, from dwarf2read.c.
11558 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
11559
11560 2020-02-08 Tom Tromey <tom@tromey.com>
11561
11562 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
11563 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
11564 Move.
11565 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
11566 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
11567 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
11568 abbrev.c.
11569 * dwarf2/abbrev.h: New file.
11570 * dwarf2/abbrev.c: New file, from dwarf2read.c.
11571 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
11572
11573 2020-02-08 Tom Tromey <tom@tromey.com>
11574
11575 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
11576 (dwarf2_section_size, dwarf2_get_section_info)
11577 (create_signatured_type_table_from_debug_names)
11578 (create_addrmap_from_aranges, read_debug_names_from_section)
11579 (get_gdb_index_contents_from_section, read_comp_unit_head)
11580 (error_check_comp_unit_head, read_abbrev_offset)
11581 (create_debug_type_hash_table, init_cu_die_reader)
11582 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
11583 (read_comp_units_from_section, create_cus_hash_table)
11584 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
11585 (create_dwp_v2_section, dwarf2_rnglists_process)
11586 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
11587 (abbrev_table_read_table, read_indirect_string_at_offset_from)
11588 (read_indirect_string_from_dwz, read_addr_index_1)
11589 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
11590 (dwarf_decode_macro_bytes, dwarf_decode_macros)
11591 (fill_in_loclist_baton): Update.
11592 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
11593 get_containing_section, get_bfd_owner, get_bfd_section,
11594 get_file_name, get_id, get_flags, empty, read>: Declare methods.
11595 (dwarf2_read_section, get_section_name, get_section_file_name)
11596 (get_containing_section, get_section_bfd_owner)
11597 (get_section_bfd_section, get_section_name, get_section_file_name)
11598 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
11599 declare.
11600 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
11601 (dwarf2_section_info::get_bfd_owner)
11602 (dwarf2_section_info::get_bfd_section)
11603 (dwarf2_section_info::get_name)
11604 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
11605 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
11606 (dwarf2_section_info::read): Now methods.
11607 * dwarf-index-write.c (class debug_names): Update.
11608
11609 2020-02-08 Tom Tromey <tom@tromey.com>
11610
11611 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
11612 Move to dwarf2/section.h.
11613 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
11614 (get_section_bfd_section, get_section_name)
11615 (get_section_file_name, get_section_id, get_section_flags)
11616 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
11617 dwarf2/section.c.
11618 * dwarf2/section.h: New file.
11619 * dwarf2/section.c: New file, from dwarf2read.c.
11620 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
11621
11622 2020-02-08 Tom Tromey <tom@tromey.com>
11623
11624 * dwarf2read.h (read_unsigned_leb128): Don't declare.
11625 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
11626 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
11627 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
11628 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
11629 * dwarf2/leb.h: New file, from dwarf2read.c.
11630 * dwarf2/leb.c: New file, from dwarf2read.c.
11631 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
11632 Remove.
11633 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
11634 (COMMON_SFILES): Add dwarf2/leb.c.
11635
11636 2020-02-08 Joel Brobecker <brobecker@adacore.com>
11637
11638 GDB 9.1 released.
11639
11640 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
11641
11642 PR gdb/25190:
11643 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
11644 * gdb/remote.c (remote_console_output): Update.
11645 * gdb/ui-file.c (fputs_unfiltered): Rename to...
11646 (ui_file_puts): ...this.
11647 * gdb/ui-file.h (ui_file_puts): Add declaration.
11648 * gdb/utils.c (emit_style_escape): Update.
11649 (flush_wrap_buffer): Update.
11650 (fputs_maybe_filtered): Update.
11651 (fputs_unfiltered): Add function.
11652
11653 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
11654
11655 * gdb/event-loop.c (gdb_wait_for_event): Update.
11656 * gdb/printcmd.c (printf_command): Update.
11657 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
11658 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
11659 (gdb_os_flush_stderr): Update.
11660 * gdb/remote.c (remote_console_output): Update.
11661 * gdb/ui-file.c (gdb_flush): Rename to...
11662 (ui_file_flush): ...this.
11663 (stderr_file::write): Update.
11664 (stderr_file::puts): Update.
11665 * gdb/ui-file.h (gdb_flush): Rename to...
11666 (ui_file_flush): ...this.
11667 * gdb/utils.c (gdb_flush): Add function.
11668 * gdb/utils.h (gdb_flush): Add declaration.
11669
11670 2020-02-07 Tom Tromey <tromey@adacore.com>
11671
11672 PR breakpoints/24915:
11673 * source.c (find_and_open_source): Do not check basenames_may_differ.
11674
11675 2020-02-07 Tom Tromey <tom@tromey.com>
11676
11677 * README: Update gdbserver documentation.
11678 * gdbserver: Move to top level.
11679 * configure.tgt (build_gdbserver): Remove.
11680 * configure.ac: Remove --enable-gdbserver.
11681 * configure: Rebuild.
11682 * Makefile.in (distclean): Don't mention gdbserver.
11683
11684 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
11685
11686 * source-cache.c (source_cache::ensure): Surround
11687 get_plain_source_lines with a try/catch.
11688 (source_cache::get_line_charpos): Get rid of try/catch
11689 and only check for the return value of "ensure".
11690 * tui/tui-source.c (tui_source_window::set_contents):
11691 Simplify "nlines" calculation.
11692
11693 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
11694
11695 * MAINTAINERS (Write After Approval): Add myself.
11696
11697 2020-02-05 Christian Biesinger <cbiesinger@google.com>
11698
11699 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
11700 function call.
11701
11702 2020-02-05 Christian Biesinger <cbiesinger@google.com>
11703
11704 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
11705
11706 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
11707
11708 * nat/riscv-linux-tdesc.h: New file.
11709 * nat/riscv-linux-tdesc.c: New file, taking code from...
11710 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
11711 ... here.
11712 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
11713 NATDEPFILES.
11714
11715 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
11716
11717 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
11718 we don't set the fake simulator ptid to the null_ptid.
11719
11720 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
11721
11722 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
11723 * gdbthread.h (class thread_info) <resumed>: Likewise.
11724 * infrun.c (resume_1): Likewise.
11725 (proceed): Likewise.
11726 (infrun_thread_stop_requested): Likewise.
11727 (stop_all_threads): Likewise.
11728 (handle_inferior_event): Likewise.
11729 (restart_threads): Likewise.
11730 (finish_step_over): Likewise.
11731 (keep_going_stepped_thread): Likewise.
11732 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
11733 (linux_handle_extended_wait): Likewise.
11734 * record-btrace.c (get_thread_current_frame_id): Likewise.
11735 * record-full.c (record_full_wait_1): Likewise.
11736 * remote.c (remote_target::process_initial_stop_replies): Likewise.
11737 * target.c (target_resume): Likewise.
11738 * thread.c (set_running_thread): Likewise.
11739
11740 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
11741
11742 * f-valprint.c (f77_print_array_1): Changed datatype of index
11743 variable to LONGEST from int to enable it to contain bound
11744 values correctly.
11745
11746 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
11747
11748 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
11749 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
11750 offsets according to FLEN determined.
11751 (riscv_linux_nat_target::read_description): Determine FLEN
11752 dynamically.
11753 (riscv_linux_nat_target::fetch_registers): Size regset buffer
11754 according to FLEN determined.
11755 (riscv_linux_nat_target::store_registers): Likewise.
11756
11757 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
11758
11759 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
11760 when reg->group is empty and reggroup is not.
11761
11762 2020-01-31 Tom Tromey <tromey@adacore.com>
11763
11764 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
11765 Call beneath target's mourn_inferior after unpushing.
11766
11767 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
11768
11769 PR tui/9765
11770 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
11771 have enough lines to fill the screen, still return the lowest
11772 address we found.
11773
11774 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
11775
11776 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
11777 '-', '<', and '>' commands.
11778
11779 2020-01-29 Pedro Alves <palves@redhat.com>
11780 Sergio Durigan Junior <sergiodj@redhat.com>
11781
11782 * infcmd.c (construct_inferior_arguments): Assert that
11783 'argc' is greater than 0.
11784
11785 2020-01-29 Luis Machado <luis.machado@linaro.org>
11786
11787 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
11788 (BRK_INSN_MASK): Define to 0xd4200000.
11789 (aarch64_program_breakpoint_here_p): New function.
11790 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
11791 * arch-utils.c (default_program_breakpoint_here_p): Moved from
11792 breakpoint.c.
11793 * arch-utils.h (default_program_breakpoint_here_p): Moved from
11794 breakpoint.h
11795 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
11796 call gdbarch_program_breakpoint_here_p.
11797 (program_breakpoint_here): Moved to arch-utils.c, renamed to
11798 default_program_breakpoint_here_p, changed return type to bool and
11799 simplified.
11800 * breakpoint.h (program_breakpoint_here): Moved prototype to
11801 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
11802 return type to bool.
11803 * gdbarch.c: Regenerate.
11804 * gdbarch.h: Regenerate.
11805 * gdbarch.sh (program_breakpoint_here_p): New method.
11806 * infrun.c (handle_signal_stop): Call
11807 gdbarch_program_breakpoint_here_p.
11808
11809 2020-01-26 Tom Tromey <tom@tromey.com>
11810
11811 * ctfread.c (struct ctf_fp_info): Reindent.
11812 (_initialize_ctfread): Remove.
11813
11814 2020-01-26 Tom Tromey <tom@tromey.com>
11815
11816 * psymtab.c (partial_map_expand_apply)
11817 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
11818 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
11819 (psym_print_stats, psym_expand_symtabs_for_function)
11820 (psym_map_symbol_filenames, psym_map_matching_symbols)
11821 (psym_expand_symtabs_matching)
11822 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
11823 (maintenance_check_psymtabs): Use new methods.
11824 * psympriv.h (struct partial_symtab) <readin_p,
11825 get_compunit_symtab>: New methods.
11826 <readin, compunit_symtab>: Remove members.
11827 (struct standard_psymtab): New.
11828 (struct legacy_psymtab): Derive from standard_psymtab.
11829 * dwarf2read.h (struct dwarf2_psymtab): Derive from
11830 standard_psymtab.
11831 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
11832
11833 2020-01-26 Tom Tromey <tom@tromey.com>
11834
11835 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
11836 read_dependencies. Add assert.
11837 * psymtab.c (partial_symtab::read_dependencies): New method.
11838 * psympriv.h (struct partial_symtab) <read_dependencies>: New
11839 method.
11840 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
11841 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
11842 read_dependencies.
11843 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
11844 Add assert.
11845
11846 2020-01-26 Tom Tromey <tom@tromey.com>
11847
11848 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
11849 Call expand_psymtab.
11850 (xcoff_read_symtab): Call expand_psymtab.
11851 (xcoff_start_psymtab, xcoff_end_psymtab): Set
11852 legacy_expand_psymtab.
11853 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
11854 method.
11855 (struct legacy_psymtab) <expand_psymtab>: Implement.
11856 <legacy_expand_psymtab>: New member.
11857 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
11858 (parse_partial_symbols): Set legacy_expand_psymtab.
11859 (psymtab_to_symtab_1): Change argument order. Call
11860 expand_psymtab.
11861 (new_psymtab): Set legacy_expand_psymtab.
11862 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
11863 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
11864 expand_psymtab.
11865 (dwarf2_psymtab::expand_psymtab): Rename from
11866 psymtab_to_symtab_1. Call expand_psymtab.
11867 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
11868 (dbx_end_psymtab): Likewise.
11869 (dbx_psymtab_to_symtab_1): Change argument order. Call
11870 expand_psymtab.
11871 (dbx_read_symtab): Call expand_psymtab.
11872 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
11873 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
11874 (ctf_psymtab::read_symtab): Call expand_psymtab.
11875
11876 2020-01-26 Tom Tromey <tom@tromey.com>
11877
11878 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
11879 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
11880 messages.
11881 * mdebugread.c (mdebug_read_symtab): Remove prints.
11882 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
11883 assert.
11884 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
11885
11886 2020-01-26 Tom Tromey <tom@tromey.com>
11887
11888 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
11889 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
11890 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
11891 legacy_symtab.
11892 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
11893 * psymtab.c (psymtab_to_symtab): Call method.
11894 (dump_psymtab): Update.
11895 * psympriv.h (struct partial_symtab): Add virtual destructor.
11896 <read_symtab>: New method.
11897 (struct legacy_symtab): New.
11898 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
11899 (struct pst_map) <pst>: Now a legacy_psymtab.
11900 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
11901 (new_psymtab): Use legacy_psymtab.
11902 * dwarf2read.h (struct dwarf2_psymtab): New.
11903 (struct dwarf2_per_cu_data) <psymtab>: Use it.
11904 * dwarf2read.c (dwarf2_create_include_psymtab)
11905 (dwarf2_build_include_psymtabs, create_type_unit_group)
11906 (create_partial_symtab, process_psymtab_comp_unit_reader)
11907 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
11908 (set_partial_user): Use dwarf2_psymtab.
11909 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
11910 (psymtab_to_symtab_1, process_full_comp_unit)
11911 (process_full_type_unit, dwarf2_ranges_read)
11912 (dwarf2_get_pc_bounds, psymtab_include_file_name)
11913 (dwarf_decode_lines): Use dwarf2_psymtab.
11914 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
11915 (add_address_entry_worker, write_one_signatured_type)
11916 (recursively_count_psymbols, recursively_write_psymbols)
11917 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
11918 (write_debug_names): Likewise.
11919 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
11920 <pst>: Now a legacy_psymtab.
11921 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
11922 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
11923 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
11924 * ctfread.c (struct ctf_psymtab): New.
11925 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
11926 ctf_psymtab.
11927 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
11928 (create_partial_symtab): Return a ctf_psymtab.
11929 (scan_partial_symbols): Update.
11930
11931 2020-01-26 Tom Tromey <tom@tromey.com>
11932
11933 * xcoffread.c (xcoff_start_psymtab): Use new.
11934 * psymtab.c (partial_symtab::partial_symtab): New constructor,
11935 renamed from start_psymtab_common.
11936 * psympriv.h (struct partial_symtab): Add new constructor.
11937 (start_psymtab_common): Don't declare.
11938 * mdebugread.c (parse_partial_symbols): Use new.
11939 * dwarf2read.c (create_partial_symtab): Use new.
11940 * dbxread.c (start_psymtab): Use new.
11941 * ctfread.c (create_partial_symtab): Use new.
11942
11943 2020-01-26 Tom Tromey <tom@tromey.com>
11944
11945 * xcoffread.c (xcoff_end_psymtab): Use new.
11946 * psymtab.c (start_psymtab_common): Use new.
11947 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
11948 Update.
11949 * psympriv.h (struct partial_symtab): Add parameters to
11950 constructor. Don't inline.
11951 (allocate_psymtab): Don't declare.
11952 * mdebugread.c (new_psymtab): Use new.
11953 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
11954 * dbxread.c (dbx_end_psymtab): Use new.
11955
11956 2020-01-26 Tom Tromey <tom@tromey.com>
11957
11958 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
11959 allocate_psymtab. Update documentation.
11960 * psymtab.c (psymtab_storage::install_psymtab): Rename from
11961 allocate_psymtab. Do not use new.
11962 (allocate_psymtab): Use new. Update.
11963
11964 2020-01-26 Tom Tromey <tom@tromey.com>
11965
11966 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
11967 * psymtab.c (psym_print_stats): Update.
11968 * psympriv.h (struct partial_symtab) <readin,
11969 psymtabs_addrmap_supported, anonymous>: Now bool.
11970 * mdebugread.c (psymtab_to_symtab_1): Update.
11971 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
11972 (build_type_psymtabs_reader, psymtab_to_symtab_1)
11973 (process_full_comp_unit, process_full_type_unit): Update.
11974 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
11975 * ctfread.c (psymtab_to_symtab): Update.
11976
11977 2020-01-26 Tom Tromey <tom@tromey.com>
11978
11979 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
11980 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
11981 * psymtab.c (psymtab_storage): Delete psymtabs.
11982 (psymtab_storage::allocate_psymtab): Use new.
11983 (psymtab_storage::discard_psymtab): Use delete.
11984 * psympriv.h (struct partial_symtab): Add constructor and
11985 initializers.
11986
11987 2020-01-26 Tom Tromey <tom@tromey.com>
11988
11989 * machoread.c: Do not include psympriv.h.
11990
11991 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
11992
11993 * NEWS: Mention the new option and the set/show commands.
11994
11995 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
11996
11997 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
11998 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
11999 (validate_exec_file): New variables, enums, functions.
12000 (exec_file_locate_attach, print_section_info): Style the filenames.
12001 (_initialize_exec): Install show_exec_file_mismatch_command and
12002 set_exec_file_mismatch_command.
12003 * gdbcore.h (validate_exec_file): Declare.
12004 * infcmd.c (attach_command): Call validate_exec_file.
12005 * remote.c ( remote_target::remote_add_inferior): Likewise.
12006
12007 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
12008
12009 * frame.c (find_frame_sal): Move call to get_next_frame into more
12010 inner scope.
12011 * inline-frame.c (inilne_state) <inline_state>: Update argument
12012 types.
12013 (inilne_state) <skipped_symbol>: Rename to...
12014 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
12015 (skip_inline_frames): Build vector of skipped symbols and use this
12016 to reate the inline_state.
12017 (inline_skipped_symbol): Add a comment and some assertions, fetch
12018 skipped symbol from the list.
12019
12020 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
12021
12022 * buildsym.c (lte_is_less_than): Delete.
12023 (buildsym_compunit::end_symtab_with_blockvector): Create local
12024 lambda function to sort line table entries, and use
12025 std::stable_sort instead of std::sort.
12026 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
12027 markers when looking for a previous line.
12028
12029 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
12030
12031 * dwarf2read.c (lnp_state_machine::record_line): Include
12032 end_sequence parameter in debug print out. Record the line if we
12033 are at an end_sequence marker even if it's not the start of a
12034 statement.
12035 * symmisc.c (maintenance_print_one_line_table): Print end of
12036 sequence markers with 'END' not '0'.
12037
12038 2020-01-24 Pedro Alves <palves@redhat.com>
12039
12040 PR gdb/25410
12041 * thread.c (scoped_restore_current_thread::restore): Use
12042 switch_to_inferior_no_thread.
12043 * exec.c: Include "progspace-and-thread.h".
12044 (add_target_sections, remove_target_sections):
12045 scoped_restore_current_pspace_and_thread instead of
12046 scoped_restore_current_thread.
12047 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
12048 and aspace to the inferior before calling clone_program_space.
12049 Remove stale comment.
12050
12051 2020-01-24 Christian Biesinger <cbiesinger@google.com>
12052
12053 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
12054 (arm_netbsd_nat_target::fetch_registers): ...this.
12055 (arm_nbsd_nat_target::store_registers): Rename to...
12056 (arm_netbsd_nat_target::store_registers): ...this.
12057
12058 2020-01-24 Christian Biesinger <cbiesinger@google.com>
12059
12060 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
12061 register_t.
12062
12063 2020-01-24 Christian Biesinger <cbiesinger@google.com>
12064
12065 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
12066 Update comment.
12067 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
12068 Likewise.
12069 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
12070 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
12071 the correct replacement (iterate_over_regset_sections).
12072 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
12073 Update comment.
12074
12075 2020-01-24 Graham Markall <graham.markall@embecosm.com>
12076
12077 PR gdb/23718
12078 * gdb/python/python.c (execute_gdb_command): Call
12079 async_enable_stdin in catch block.
12080
12081 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
12082
12083 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
12084 SWITCH_THRU_ALL_UIS.
12085
12086 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
12087
12088 PR tui/9765
12089 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
12090 comment, add extra parameter, and update to store previous symbol
12091 when appropriate.
12092 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
12093 add extra parameter.
12094 * tui/tui-disasm.c (tui_disassemble): Update header comment,
12095 remove unneeded parameter, add try/catch around gdb_print_insn,
12096 rewrite to add items to asm_lines vector.
12097 (tui_find_backward_disassembly_start_address): New function.
12098 (tui_find_disassembly_address): Updated throughout.
12099 (tui_disasm_window::set_contents): Update for changes to
12100 tui_disassemble.
12101 (tui_disasm_window::do_scroll_vertical): No need to adjust the
12102 number of lines to scroll.
12103
12104 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
12105
12106 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
12107 (SECT_OFF_DATA): Likewise.
12108 (SECT_OFF_RODATA): Likewise.
12109 (SECT_OFF_TEXT): Likewise.
12110 (SECT_OFF_BSS): Likewise.
12111 (struct objfile) <text_section_offset, data_section_offset>: New
12112 methods.
12113 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
12114 objfile::text_section_offset.
12115 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
12116 * coffread.c (coff_symtab_read): Likewise.
12117 (enter_linenos): Likewise.
12118 (process_coff_symbol): Likewise.
12119 * ctfread.c (get_objfile_text_range): Likewise.
12120 * dtrace-probe.c (dtrace_probe::get_relocated_address):
12121 Use objfile::data_section_offset.
12122 * dwarf2-frame.c (execute_cfa_program): Use
12123 objfile::text_section_offset.
12124 (dwarf2_frame_find_fde): Likewise.
12125 * dwarf2read.c (create_addrmap_from_index): Likewise.
12126 (create_addrmap_from_aranges): Likewise.
12127 (dw2_find_pc_sect_compunit_symtab): Likewise.
12128 (process_psymtab_comp_unit_reader): Likewise.
12129 (add_partial_symbol): Likewise.
12130 (add_partial_subprogram): Likewise.
12131 (process_full_comp_unit): Likewise.
12132 (read_file_scope): Likewise.
12133 (read_func_scope): Likewise.
12134 (read_lexical_block_scope): Likewise.
12135 (read_call_site_scope): Likewise.
12136 (dwarf2_rnglists_process): Likewise.
12137 (dwarf2_ranges_process): Likewise.
12138 (dwarf2_ranges_read): Likewise.
12139 (dwarf_decode_lines_1): Likewise.
12140 (new_symbol): Likewise.
12141 (dwarf2_fetch_die_loc_sect_off): Likewise.
12142 (dwarf2_per_cu_text_offset): Likewise.
12143 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
12144 * hppa-tdep.c (read_unwind_info): Likewise.
12145 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
12146 * psympriv.h (struct partial_symtab): Likewise.
12147 * psymtab.c (find_pc_sect_psymtab): Likewise.
12148 * solib-svr4.c (enable_break): Likewise.
12149 * stap-probe.c (relocate_address): Use
12150 objfile::data_section_offset.
12151 * xcoffread.c (enter_line_range): Use
12152 objfile::text_section_offset.
12153 (read_xcoff_symtab): Likewise.
12154
12155 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
12156
12157 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
12158 declaration to narrower scopes.
12159
12160 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
12161
12162 * darwin-nat.h (struct darwin_exception_msg, enum
12163 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
12164 Move up.
12165 (class darwin_nat_target) <wait_1, check_new_threads,
12166 decode_exception_message, decode_message, stop_inferior,
12167 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
12168 * darwin-nat.c (darwin_check_new_threads): Rename to...
12169 (darwin_nat_target::check_new_threads): ... this.
12170 (darwin_suspend_inferior_it): Remove.
12171 (darwin_decode_exception_message): Rename to...
12172 (darwin_nat_target::decode_exception_message): ... this.
12173 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
12174 (darwin_decode_message): Rename to...
12175 (darwin_nat_target::decode_message): ... this.
12176 (cancel_breakpoint): Rename to...
12177 (darwin_nat_target::cancel_breakpoint): ... this.
12178 (darwin_wait): Rename to...
12179 (darwin_nat_target::wait_1): ... this. Use range-based for loop
12180 instead of iterate_over_inferiors.
12181 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
12182 (darwin_stop_inferior): Rename to...
12183 (darwin_nat_target::stop_inferior): ... this.
12184 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
12185 (darwin_init_thread_list): Rename to...
12186 (darwin_nat_target::init_thread_list): ... this.
12187 (darwin_ptrace_him): Rename to...
12188 (darwin_nat_target::ptrace_him): ... this.
12189 (darwin_nat_target::create_inferior): Pass lambda function to
12190 fork_inferior.
12191 (darwin_nat_target::detach): Call stop_inferior instead of
12192 darwin_stop_inferior.
12193 * fork-inferior.h (fork_inferior): Change init_trace_fun
12194 parameter to gdb::function_view.
12195 * fork-inferior.c (fork_inferior): Likewise.
12196
12197 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
12198
12199 * i386-cygwin-tdep.c (core_process_module_section): Update.
12200 * windows-nat.c (struct lm_info_windows): Add text_offset.
12201 (windows_xfer_shared_libraries): Update.
12202 * windows-tdep.c (windows_xfer_shared_library):
12203 Add text_offset_cached argument.
12204 * windows-tdep.h (windows_xfer_shared_library): Update.
12205
12206 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
12207
12208 * gdbarch.sh: Add declaration for _initialize_gdbarch.
12209
12210 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
12211
12212 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
12213 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
12214 replace with range-based for.
12215 (gdbsim_interrupt_inferior): Remove.
12216 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
12217 with a range-based for. Inline code from
12218 gdbsim_interrupt_inferior.
12219
12220 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
12221
12222 * infrun.c (proceed): Fix indentation.
12223
12224 2020-01-21 Tom Tromey <tromey@adacore.com>
12225
12226 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
12227 * python/python.c (python_extension_ops): Update.
12228 (gdbpy_colorize): New function.
12229 * python/lib/gdb/__init__.py (colorize): New function.
12230 * extension.h (ext_lang_colorize): Declare.
12231 * extension.c (ext_lang_colorize): New function.
12232 * extension-priv.h (struct extension_language_ops) <colorize>: New
12233 member.
12234 * cli/cli-style.c (_initialize_cli_style): Update help text.
12235
12236 2020-01-21 Luis Machado <luis.machado@linaro.org>
12237
12238 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
12239 <cond>: Change type to bool.
12240 (aarch64_displaced_step_b_cond): Update cond to use bool type.
12241 (aarch64_displaced_step_cb): Likewise.
12242 (aarch64_displaced_step_tb): Likewise.
12243
12244 2020-01-21 Luis Machado <luis.machado@linaro.org>
12245
12246 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
12247 output.
12248
12249 2020-01-21 Luis Machado <luis.machado@linaro.org>
12250
12251 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
12252 <pc_adjust>: Adjust the documentation.
12253 (aarch64_displaced_step_fixup): Check if PC really moved before
12254 adjusting it.
12255
12256 2020-01-19 Tom Tromey <tom@tromey.com>
12257
12258 * disasm.c (~gdb_disassembler): New destructor.
12259 (gdb_buffered_insn_length): Call disassemble_free_target.
12260 * disasm.h (class gdb_disassembler): Declare destructor. Use
12261 DISABLE_COPY_AND_ASSIGN.
12262
12263 2020-01-19 Tom Tromey <tom@tromey.com>
12264
12265 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
12266 (die_reader_func_ftype): Remove.
12267 (cutu_reader): New class.
12268 (dw2_get_file_names_reader): Remove "data" parameter.
12269 (dw2_get_file_names): Use cutu_reader.
12270 (create_debug_type_hash_table): Update.
12271 (read_cutu_die_from_dwo): Update comment.
12272 (lookup_dwo_unit): Add dwo_name parameter.
12273 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
12274 die_reader_func_ftype and data parameters.
12275 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
12276 Remove die_reader_func_ftype and data parameters.
12277 (~cutu_reader): New; from init_cutu_and_read_dies.
12278 (cutu_reader::cutu_reader): Rename from
12279 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
12280 and data parameters.
12281 (init_cutu_and_read_dies_simple): Remove.
12282 (struct process_psymtab_comp_unit_data): Remove.
12283 (process_psymtab_comp_unit_reader): Remove data parameter; add
12284 want_partial_unit and pretend_language parameters.
12285 (process_psymtab_comp_unit): Use cutu_reader.
12286 (build_type_psymtabs_reader): Remove data parameter.
12287 (build_type_psymtabs_1): Use cutu_reader.
12288 (process_skeletonless_type_unit): Likewise.
12289 (load_partial_comp_unit_reader): Remove.
12290 (load_partial_comp_unit): Use cutu_reader.
12291 (load_full_comp_unit_reader): Remove.
12292 (load_full_comp_unit): Use cutu_reader.
12293 (struct create_dwo_cu_data): Remove.
12294 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
12295 dwo_unit parameters.
12296 (create_cus_hash_table): Use cutu_reader.
12297 (struct dwarf2_read_addr_index_data): Remove.
12298 (dwarf2_read_addr_index_reader): Remove.
12299 (dwarf2_read_addr_index): Use cutu_reader.
12300 (read_signatured_type_reader): Remove.
12301 (read_signatured_type): Use cutu_reader.
12302
12303 2020-01-19 Tom Tromey <tom@tromey.com>
12304
12305 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
12306 * tui/tui-wingeneral.h (class tui_suppress_output): New.
12307 (tui_wrefresh): Declare.
12308 * tui/tui-wingeneral.c (suppress_output): New global.
12309 (tui_suppress_output, ~tui_suppress_output): New constructor and
12310 destructor.
12311 (tui_wrefresh): New function.
12312 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
12313 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
12314 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
12315 method.
12316 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
12317 tui_wrefresh.
12318 (tui_data_window::no_refresh): New method.
12319 (tui_data_item_window::refresh_window): Call tui_wrefresh.
12320 (tui_reg_command): Use tui_suppress_output
12321 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
12322 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
12323 method.
12324 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
12325
12326 2020-01-19 Tom Tromey <tom@tromey.com>
12327
12328 * tui/tui-winsource.c (tui_update_source_windows_with_line):
12329 Handle case where symtab is null.
12330
12331 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
12332
12333 * linux-fork.c (one_fork_p): Simplify.
12334
12335 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
12336
12337 * top.c (struct qt_args): Remove.
12338 (kill_or_detach): Change return type to void, replace `void *`
12339 parameter with a proper one.
12340 (print_inferior_quit_action): Likewise.
12341 (quit_confirm): Use range-based for loop to iterate over inferiors.
12342 (quit_force): Likewise.
12343
12344 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
12345
12346 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
12347 `void *` parameter with proper parameters.
12348 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
12349 (print_one_inferior): Change return type to void, replace `void *`
12350 parameter with proper parameters.
12351 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
12352 inferiors.
12353 (get_other_inferior): Remove.
12354 (mi_cmd_remove_inferior): Use range-based loop to iterate over
12355 inferiors.
12356
12357 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
12358
12359 * mi/mi-interp.c (report_initial_inferior): Remove.
12360 (mi_interp::init): Use range-based for to iterate over inferiors.
12361
12362 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
12363
12364 * python/py-inferior.c (build_inferior_list): Remove.
12365 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
12366
12367 2020-01-16 Christian Biesinger <cbiesinger@google.com>
12368
12369 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
12370 (btrace_stitch_trace): Likewise.
12371 * charset.c (intermediate_encoding): Likewise (vaild).
12372 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
12373 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
12374 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
12375
12376 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
12377
12378 * windows-tdep.c (windows_get_tlb_type):
12379 Add rtl_user_process_parameters type.
12380
12381 2020-01-16 Pedro Alves <palves@redhat.com>
12382 Norbert Lange <nolange79@gmail.com>
12383
12384 PR build/24805
12385 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
12386 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
12387 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
12388 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
12389 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
12390 (ps_plog): Redeclare exported functions with default visibility.
12391
12392 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
12393
12394 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
12395 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
12396
12397 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
12398
12399 * infcmd.c (post_create_inferior): Use get_thread_regcache
12400 instead of get_current_regcache.
12401
12402 2020-01-14 Tom Tromey <tom@tromey.com>
12403
12404 PR symtab/12535:
12405 * python/python.c (gdbpy_decode_line): Treat empty string the same
12406 as no argument.
12407
12408 2020-01-14 Tom Tromey <tom@tromey.com>
12409
12410 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
12411
12412 2020-01-14 Tom Tromey <tom@tromey.com>
12413
12414 * nat/linux-btrace.c: Don't include <config.h>.
12415 * nat/linux-ptrace.c: Don't include <config.h>.
12416 * nat/x86-linux-dregs.c: Don't include <config.h>.
12417
12418 2020-01-14 Tom Tromey <tom@tromey.com>
12419
12420 * configure: Rebuild.
12421 * configure.ac: Move many checks to ../gdbsupport/common.m4.
12422
12423 2020-01-14 Tom Tromey <tom@tromey.com>
12424
12425 * nat/x86-linux-dregs.c: Include configh.h.
12426 * nat/linux-ptrace.c: Include configh.h.
12427 * nat/linux-btrace.c: Include configh.h.
12428 * defs.h: Include config.h, bfd.h.
12429 * configure.ac: Don't source common.host.
12430 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
12431 * configure: Rebuild.
12432 * acinclude.m4: Update path.
12433 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
12434 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
12435 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
12436 (CLIBS): Add LIBSUPPORT.
12437 (CDEPS): Likewise.
12438 (COMMON_SFILES): Remove gdbsupport files.
12439 (HFILES_NO_SRCDIR): Likewise.
12440 (stamp-version): Update path to create-version.sh.
12441 (ALLDEPFILES): Remove gdbsupport files.
12442
12443 2020-01-14 Tom Tromey <tom@tromey.com>
12444
12445 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
12446 USE_WIN32API when needed.
12447 * configure.ac (USE_WIN32API): Don't define.
12448 (WIN32LIBS): Use WIN32APILIBS.
12449 * configure: Rebuild.
12450
12451 2020-01-14 Tom Tromey <tom@tromey.com>
12452
12453 * configure: Rebuild.
12454 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
12455
12456 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
12457
12458 * skip.c (skip_function_command): Make skip w/o arguments use the
12459 name of the inlined function if pc is inside any inlined function.
12460
12461 2020-01-14 Luis Machado <luis.machado@linaro.org>
12462
12463 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
12464 * infrun.c (resume_1): Likewise.
12465 (handle_inferior_event): Remove stale comment.
12466 * linux-nat.c (linux_nat_target::resume): Update comments.
12467 (save_stop_reason): Likewise.
12468 (linux_nat_filter_event): Likewise.
12469 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
12470
12471 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
12472
12473 * elfread.c (record_minimal_symbol): Set section index to 0 for
12474 non-allocatable sections.
12475
12476
12477 2020-01-13 Ali Tamur <tamur@google.com>
12478
12479 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
12480 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
12481 to gdb::optional. Update comments.
12482 (dwo_file): Update comments.
12483 (read_attribute): Update API to take an additional out parameter,
12484 need_reprocess. This is used to mark attributes that need other
12485 attributes (e.g. str_offsets_base) for correct computation which may not
12486 have been read yet.
12487 (read_attribute_reprocess): New function declaration.
12488 (read_addr_index): Likewise.
12489 (read_dwo_str_index): Likewise.
12490 (read_stub_str_index): Likewise.
12491 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
12492 (lookup_addr_base): New function definition.
12493 (lookup_ranges_base): Likewise.
12494 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
12495 lookup_ranges_base.
12496 (init_cutu_and_read_dies): Update comments.
12497 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
12498 unit. This is used to inherit parent's str_offsets_base and addr_base.
12499 Update comments.
12500 (init_cutu_and_read_dies_simple): Reflect API changes.
12501 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
12502 (create_cus_hash_table): Change API to take parent compile unit.
12503 Reflect API changes.
12504 (open_and_init_dwo_file): Reflect API changes.
12505 (dwarf2_get_pc_bounds): Update comments.
12506 (dwarf2_record_block_ranges): Likewise.
12507 (read_full_die_1): Change implementation to reprocess attributes that
12508 need str_offsets_base and addr_base.
12509 (partial_die_info::read): Likewise.
12510 (read_attribute_reprocess): New function definition.
12511 (read_attribute_value): Change API to take an additional out parameter,
12512 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
12513 when a non-dwo compile unit has index based attributes.
12514 (read_attribute): Reflect API changes.
12515 (read_addr_index_1): Reflect API changes. Update comments.
12516 (dwarf2_read_addr_index_data): Reflect API changes.
12517 (dwarf2_read_addr_index): Likewise.
12518 (read_str_index): Change API and implementation. This becomes a helper
12519 to be used by the new string index related methods. Update error
12520 message and comments.
12521 (read_dwo_str_index): New function definition.
12522 (read_stub_str_index): Likewise.
12523 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
12524 * symfile.h (dwarf2_debug_sections): Likewise.
12525 * xcoffread.c (dwarf2_debug_sections): Likewise.
12526
12527 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
12528
12529 * gdbcore.h (struct core_fns) <core_read_registers>: Change
12530 core_reg_sect type to gdb_byte *.
12531 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
12532 * cris-tdep.c (fetch_core_registers): Likewise.
12533 * corelow.c (core_target::get_core_register_section): Change
12534 type of `contents` to gdb::byte_vector.
12535
12536 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
12537
12538 * tui/tui-wingeneral.c (box_win): Position the title in the center
12539 of the border.
12540
12541 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
12542
12543 * corelow.c (core_target::get_core_register_section): Use
12544 std::vector instead of alloca.
12545
12546 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
12547
12548 * warning.m4: Add -Wmissing-declarations to build_warnings.
12549 * configure: Re-generate.
12550
12551 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
12552
12553 * python/python.c (init__gdb_module): Add declaration.
12554
12555 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
12556
12557 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
12558 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
12559 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
12560 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
12561 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
12562 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
12563 * ada-exp.y (_initialize_ada_exp): Add declaration.
12564 * ada-lang.c (_initialize_ada_language): Add declaration.
12565 * ada-tasks.c (_initialize_tasks): Add declaration.
12566 * agent.c (_initialize_agent): Add declaration.
12567 * aix-thread.c (_initialize_aix_thread): Add declaration.
12568 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
12569 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
12570 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
12571 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
12572 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
12573 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
12574 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
12575 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
12576 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
12577 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
12578 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
12579 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
12580 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
12581 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
12582 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
12583 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
12584 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
12585 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
12586 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
12587 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
12588 * annotate.c (_initialize_annotate): Add declaration.
12589 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
12590 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
12591 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
12592 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
12593 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
12594 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
12595 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
12596 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
12597 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
12598 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
12599 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
12600 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
12601 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
12602 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
12603 * auto-load.c (_initialize_auto_load): Add declaration.
12604 * auxv.c (_initialize_auxv): Add declaration.
12605 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
12606 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
12607 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
12608 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
12609 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
12610 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
12611 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
12612 * breakpoint.c (_initialize_breakpoint): Add declaration.
12613 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
12614 * btrace.c (_initialize_btrace): Add declaration.
12615 * charset.c (_initialize_charset): Add declaration.
12616 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
12617 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
12618 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
12619 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
12620 * cli/cli-script.c (_initialize_cli_script): Add declaration.
12621 * cli/cli-style.c (_initialize_cli_style): Add declaration.
12622 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
12623 * coffread.c (_initialize_coffread): Add declaration.
12624 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
12625 * compile/compile.c (_initialize_compile): Add declaration.
12626 * complaints.c (_initialize_complaints): Add declaration.
12627 * completer.c (_initialize_completer): Add declaration.
12628 * copying.c (_initialize_copying): Add declaration.
12629 * corefile.c (_initialize_core): Add declaration.
12630 * corelow.c (_initialize_corelow): Add declaration.
12631 * cp-abi.c (_initialize_cp_abi): Add declaration.
12632 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
12633 * cp-support.c (_initialize_cp_support): Add declaration.
12634 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
12635 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
12636 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
12637 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
12638 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
12639 * ctfread.c (_initialize_ctfread): Add declaration.
12640 * d-lang.c (_initialize_d_language): Add declaration.
12641 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
12642 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
12643 * dbxread.c (_initialize_dbxread): Add declaration.
12644 * dcache.c (_initialize_dcache): Add declaration.
12645 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
12646 * disasm.c (_initialize_disasm): Add declaration.
12647 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
12648 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
12649 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
12650 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
12651 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
12652 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
12653 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
12654 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
12655 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
12656 * elfread.c (_initialize_elfread): Add declaration.
12657 * exec.c (_initialize_exec): Add declaration.
12658 * extension.c (_initialize_extension): Add declaration.
12659 * f-lang.c (_initialize_f_language): Add declaration.
12660 * f-valprint.c (_initialize_f_valprint): Add declaration.
12661 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
12662 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
12663 * filesystem.c (_initialize_filesystem): Add declaration.
12664 * findcmd.c (_initialize_mem_search): Add declaration.
12665 * findvar.c (_initialize_findvar): Add declaration.
12666 * fork-child.c (_initialize_fork_child): Add declaration.
12667 * frame-base.c (_initialize_frame_base): Add declaration.
12668 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
12669 * frame.c (_initialize_frame): Add declaration.
12670 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
12671 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
12672 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
12673 * gcore.c (_initialize_gcore): Add declaration.
12674 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
12675 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
12676 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
12677 * gdbarch.c (_initialize_gdbarch): Add declaration.
12678 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
12679 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
12680 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
12681 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
12682 * go-lang.c (_initialize_go_language): Add declaration.
12683 * go32-nat.c (_initialize_go32_nat): Add declaration.
12684 * guile/guile.c (_initialize_guile): Add declaration.
12685 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
12686 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
12687 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
12688 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
12689 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
12690 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
12691 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
12692 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
12693 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
12694 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
12695 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
12696 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
12697 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
12698 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
12699 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
12700 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
12701 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
12702 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
12703 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
12704 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
12705 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
12706 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
12707 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
12708 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
12709 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
12710 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
12711 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
12712 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
12713 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
12714 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
12715 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
12716 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
12717 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
12718 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
12719 * infcall.c (_initialize_infcall): Add declaration.
12720 * infcmd.c (_initialize_infcmd): Add declaration.
12721 * inflow.c (_initialize_inflow): Add declaration.
12722 * infrun.c (_initialize_infrun): Add declaration.
12723 * interps.c (_initialize_interpreter): Add declaration.
12724 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
12725 * jit.c (_initialize_jit): Add declaration.
12726 * language.c (_initialize_language): Add declaration.
12727 * linux-fork.c (_initialize_linux_fork): Add declaration.
12728 * linux-nat.c (_initialize_linux_nat): Add declaration.
12729 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
12730 * linux-thread-db.c (_initialize_thread_db): Add declaration.
12731 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
12732 * m2-lang.c (_initialize_m2_language): Add declaration.
12733 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
12734 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
12735 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
12736 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
12737 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
12738 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
12739 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
12740 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
12741 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
12742 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
12743 * machoread.c (_initialize_machoread): Add declaration.
12744 * macrocmd.c (_initialize_macrocmd): Add declaration.
12745 * macroscope.c (_initialize_macroscope): Add declaration.
12746 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
12747 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
12748 * maint.c (_initialize_maint_cmds): Add declaration.
12749 * mdebugread.c (_initialize_mdebugread): Add declaration.
12750 * memattr.c (_initialize_mem): Add declaration.
12751 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
12752 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
12753 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
12754 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
12755 * mi/mi-main.c (_initialize_mi_main): Add declaration.
12756 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
12757 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
12758 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
12759 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
12760 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
12761 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
12762 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
12763 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
12764 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
12765 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
12766 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
12767 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
12768 * mipsread.c (_initialize_mipsread): Add declaration.
12769 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
12770 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
12771 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
12772 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
12773 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
12774 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
12775 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
12776 * nto-procfs.c (_initialize_procfs): Add declaration.
12777 * objc-lang.c (_initialize_objc_language): Add declaration.
12778 * observable.c (_initialize_observer): Add declaration.
12779 * opencl-lang.c (_initialize_opencl_language): Add declaration.
12780 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
12781 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
12782 * osabi.c (_initialize_gdb_osabi): Add declaration.
12783 * osdata.c (_initialize_osdata): Add declaration.
12784 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
12785 * parse.c (_initialize_parse): Add declaration.
12786 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
12787 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
12788 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
12789 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
12790 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
12791 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
12792 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
12793 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
12794 * printcmd.c (_initialize_printcmd): Add declaration.
12795 * probe.c (_initialize_probe): Add declaration.
12796 * proc-api.c (_initialize_proc_api): Add declaration.
12797 * proc-events.c (_initialize_proc_events): Add declaration.
12798 * proc-service.c (_initialize_proc_service): Add declaration.
12799 * procfs.c (_initialize_procfs): Add declaration.
12800 * producer.c (_initialize_producer): Add declaration.
12801 * psymtab.c (_initialize_psymtab): Add declaration.
12802 * python/python.c (_initialize_python): Add declaration.
12803 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
12804 * record-btrace.c (_initialize_record_btrace): Add declaration.
12805 * record-full.c (_initialize_record_full): Add declaration.
12806 * record.c (_initialize_record): Add declaration.
12807 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
12808 * regcache.c (_initialize_regcache): Add declaration.
12809 * reggroups.c (_initialize_reggroup): Add declaration.
12810 * remote-notif.c (_initialize_notif): Add declaration.
12811 * remote-sim.c (_initialize_remote_sim): Add declaration.
12812 * remote.c (_initialize_remote): Add declaration.
12813 * reverse.c (_initialize_reverse): Add declaration.
12814 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
12815 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
12816 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
12817 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
12818 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
12819 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
12820 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
12821 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
12822 Add declaration.
12823 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
12824 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
12825 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
12826 * rust-exp.y (_initialize_rust_exp): Add declaration.
12827 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
12828 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
12829 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
12830 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
12831 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
12832 * score-tdep.c (_initialize_score_tdep): Add declaration.
12833 * ser-go32.c (_initialize_ser_dos): Add declaration.
12834 * ser-mingw.c (_initialize_ser_windows): Add declaration.
12835 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
12836 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
12837 * ser-uds.c (_initialize_ser_socket): Add declaration.
12838 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
12839 * serial.c (_initialize_serial): Add declaration.
12840 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
12841 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
12842 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
12843 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
12844 * skip.c (_initialize_step_skip): Add declaration.
12845 * sol-thread.c (_initialize_sol_thread): Add declaration.
12846 * solib-aix.c (_initialize_solib_aix): Add declaration.
12847 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
12848 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
12849 * solib-frv.c (_initialize_frv_solib): Add declaration.
12850 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
12851 * solib-target.c (_initialize_solib_target): Add declaration.
12852 * solib.c (_initialize_solib): Add declaration.
12853 * source-cache.c (_initialize_source_cache): Add declaration.
12854 * source.c (_initialize_source): Add declaration.
12855 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
12856 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
12857 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
12858 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
12859 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
12860 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
12861 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
12862 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
12863 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
12864 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
12865 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
12866 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
12867 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
12868 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
12869 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
12870 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
12871 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
12872 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
12873 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
12874 * stabsread.c (_initialize_stabsread): Add declaration.
12875 * stack.c (_initialize_stack): Add declaration.
12876 * stap-probe.c (_initialize_stap_probe): Add declaration.
12877 * std-regs.c (_initialize_frame_reg): Add declaration.
12878 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
12879 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
12880 * symfile.c (_initialize_symfile): Add declaration.
12881 * symmisc.c (_initialize_symmisc): Add declaration.
12882 * symtab.c (_initialize_symtab): Add declaration.
12883 * target.c (_initialize_target): Add declaration.
12884 * target-connection.c (_initialize_target_connection): Add
12885 declaration.
12886 * target-dcache.c (_initialize_target_dcache): Add declaration.
12887 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
12888 * thread.c (_initialize_thread): Add declaration.
12889 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
12890 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
12891 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
12892 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
12893 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
12894 * tracectf.c (_initialize_ctf): Add declaration.
12895 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
12896 * tracefile.c (_initialize_tracefile): Add declaration.
12897 * tracepoint.c (_initialize_tracepoint): Add declaration.
12898 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
12899 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
12900 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
12901 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
12902 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
12903 * tui/tui-win.c (_initialize_tui_win): Add declaration.
12904 * tui/tui.c (_initialize_tui): Add declaration.
12905 * typeprint.c (_initialize_typeprint): Add declaration.
12906 * ui-style.c (_initialize_ui_style): Add declaration.
12907 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
12908 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
12909 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
12910 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
12911 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
12912 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
12913 * unittests/filtered_iterator-selftests.c
12914 (_initialize_filtered_iterator_selftests): Add declaration.
12915 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
12916 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
12917 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
12918 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
12919 * unittests/main-thread-selftests.c
12920 (_initialize_main_thread_selftests): Add declaration.
12921 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
12922 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
12923 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
12924 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
12925 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
12926 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
12927 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
12928 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
12929 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
12930 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
12931 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
12932 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
12933 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
12934 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
12935 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
12936 declaration.
12937 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
12938 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
12939 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
12940 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
12941 * user-regs.c (_initialize_user_regs): Add declaration.
12942 * utils.c (_initialize_utils): Add declaration.
12943 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
12944 * valops.c (_initialize_valops): Add declaration.
12945 * valprint.c (_initialize_valprint): Add declaration.
12946 * value.c (_initialize_values): Add declaration.
12947 * varobj.c (_initialize_varobj): Add declaration.
12948 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
12949 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
12950 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
12951 * windows-nat.c (_initialize_windows_nat): Add declaration.
12952 (_initialize_check_for_gdb_ini): Add declaration.
12953 (_initialize_loadable): Add declaration.
12954 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
12955 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
12956 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
12957 * xcoffread.c (_initialize_xcoffread): Add declaration.
12958 * xml-support.c (_initialize_xml_support): Add declaration.
12959 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
12960 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
12961 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
12962 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
12963
12964 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
12965
12966 * regformats/regdat.sh: Generate declaration for init function.
12967
12968 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
12969
12970 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
12971 up.
12972 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
12973 close_one_inferior>: New methods.
12974 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
12975 pass down target to find_inferior_pid.
12976 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
12977 Pass down target to find_inferior_ptid.
12978 (gdbsim_target::create_inferior): Pass down target to
12979 add_thread_silent.
12980 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
12981 target down to find_inferior_ptid and switch_to_thread.
12982 (gdbsim_target::close): Update to call close_one_inferior.
12983 (struct resume_data): Remove.
12984 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
12985 directly, rather than through a void pointer.
12986 (gdbsim_target::resume): Update to call resume_one_inferior.
12987
12988 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
12989
12990 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
12991
12992 2020-01-12 Pedro Alves <palves@redhat.com>
12993
12994 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
12995 directly for the current inferior instead of
12996 discard_all_inferiors.
12997 (discard_all_inferiors): Delete.
12998
12999 2020-01-11 Tom Tromey <tom@tromey.com>
13000
13001 * tui/tui-wingeneral.c (box_win): Check cli_styling.
13002 * tui/tui-winsource.c (tui_source_window_base::refill): Use
13003 deprecated_safe_get_selected_frame.
13004
13005 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
13006
13007 * inferior.c (print_inferior): Switch inferior before printing it.
13008
13009 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
13010 Pedro Alves <palves@redhat.com>
13011
13012 * progspace-and-thread.c (switch_to_program_space_and_thread):
13013 Assert there's an inferior for PSPACE. Use
13014 switch_to_inferior_no_thread to switch the inferior too.
13015 * progspace.c (program_space::~program_space): Call
13016 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
13017 (program_space::free_all_objfiles): Don't call clear_symtab_users
13018 here.
13019 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
13020
13021 2020-01-10 Pedro Alves <palves@redhat.com>
13022
13023 * NEWS: Mention multi-target debugging, "info connections", and
13024 "add-inferior -no-connection".
13025
13026 2020-01-10 Pedro Alves <palves@redhat.com>
13027
13028 * infrun.c: Include "target-connection.h".
13029 (check_multi_target_resumption): New.
13030 (proceed): Call it.
13031 * target-connection.c (make_target_connection_string): Make
13032 extern.
13033 * target-connection.h (make_target_connection_string): Declare.
13034
13035 2020-01-10 Pedro Alves <palves@redhat.com>
13036
13037 * Makefile.in (COMMON_SFILES): Add target-connection.c.
13038 * inferior.c (uiout_field_connection): New function.
13039 (print_inferior): Add new "connection-id" column.
13040 (add_inferior_command): Show connection number/string of added
13041 inferior.
13042 * process-stratum-target.h
13043 (process_stratum_target::connection_string): New virtual method.
13044 (process_stratum_target::connection_number): New field.
13045 * remote.c (remote_target::connection_string): New override.
13046 * target-connection.c: New file.
13047 * target-connection.h: New file.
13048 * target.c (decref_target): Remove process_stratum targets from
13049 the connection list.
13050 (target_stack::push): Add process_stratum targets to the
13051 connection list.
13052
13053 2020-01-10 Pedro Alves <palves@redhat.com>
13054
13055 Revert:
13056 2016-04-12 Pedro Alves <palves@redhat.com>
13057 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
13058 Remove references to name.
13059 * serial.h (struct serial) <name>: Delete.
13060
13061 2020-01-10 Pedro Alves <palves@redhat.com>
13062
13063 * gdbarch-selftests.c (register_to_value_test): Remove "target
13064 already pushed" check.
13065
13066 2020-01-10 Pedro Alves <palves@redhat.com>
13067 John Baldwin <jhb@FreeBSD.org>
13068
13069 * aarch64-linux-nat.c
13070 (aarch64_linux_nat_target::thread_architecture): Adjust.
13071 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
13072 (task_command_1): Likewise.
13073 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
13074 (aix_thread_target::wait, aix_thread_target::fetch_registers)
13075 (aix_thread_target::store_registers)
13076 (aix_thread_target::thread_alive): Adjust.
13077 * amd64-fbsd-tdep.c: Include "inferior.h".
13078 (amd64fbsd_get_thread_local_address): Pass down target.
13079 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
13080 thread's gdbarch instead of target_gdbarch.
13081 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
13082 get_last_target_status.
13083 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
13084 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
13085 inferiors.
13086 (update_inserted_breakpoint_locations): Skip if inferiors with no
13087 execution.
13088 (update_global_location_list): When handling moribund locations,
13089 find representative inferior for location's pspace, and use thread
13090 count of its process_stratum target.
13091 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
13092 * bsd-uthread.c (bsd_uthread_target::wait): Use
13093 as_process_stratum_target and adjust thread_change_ptid and
13094 add_thread calls.
13095 (bsd_uthread_target::update_thread_list): Use
13096 as_process_stratum_target and adjust find_thread_ptid,
13097 thread_change_ptid and add_thread calls.
13098 * btrace.c (maint_btrace_packet_history_cmd): Adjust
13099 find_thread_ptid call.
13100 * corelow.c (add_to_thread_list): Adjust add_thread call.
13101 (core_target_open): Adjust add_thread_silent and thread_count
13102 calls.
13103 (core_target::pid_to_str): Adjust find_inferior_ptid call.
13104 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
13105 * event-top.c (async_disconnect): Pop targets from all inferiors.
13106 * exec.c (add_target_sections): Push exec target on all inferiors
13107 sharing the program space.
13108 (remove_target_sections): Remove the exec target from all
13109 inferiors sharing the program space.
13110 (exec_on_vfork): New.
13111 * exec.h (exec_on_vfork): Declare.
13112 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
13113 Pass it down.
13114 (fbsd_nat_target::update_thread_list): Adjust.
13115 (fbsd_nat_target::resume): Adjust.
13116 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
13117 down.
13118 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
13119 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
13120 get_thread_arch_regcache call.
13121 * fork-child.c (gdb_startup_inferior): Pass target down to
13122 startup_inferior and set_executing.
13123 * gdbthread.h (struct process_stratum_target): Forward declare.
13124 (add_thread, add_thread_silent, add_thread_with_info)
13125 (in_thread_list): Add process_stratum_target parameter.
13126 (find_thread_ptid(inferior*, ptid_t)): New overload.
13127 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
13128 parameter.
13129 (all_threads()): Delete overload.
13130 (all_threads, all_non_exited_threads): Add process_stratum_target
13131 parameter.
13132 (all_threads_safe): Use brace initialization.
13133 (thread_count): Add process_stratum_target parameter.
13134 (set_resumed, set_running, set_stop_requested, set_executing)
13135 (threads_are_executing, finish_thread_state): Add
13136 process_stratum_target parameter.
13137 (switch_to_thread): Use is_current_thread.
13138 * i386-fbsd-tdep.c: Include "inferior.h".
13139 (i386fbsd_get_thread_local_address): Pass down target.
13140 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
13141 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
13142 have_inferiors check.
13143 * inf-ptrace.c (inf_ptrace_target::create_inferior)
13144 (inf_ptrace_target::attach): Adjust.
13145 * infcall.c (run_inferior_call): Adjust.
13146 * infcmd.c (run_command_1): Pass target to
13147 scoped_finish_thread_state.
13148 (proceed_thread_callback): Skip inferiors with no execution.
13149 (continue_command): Rename 'all_threads' local to avoid hiding
13150 'all_threads' function. Adjust get_last_target_status call.
13151 (prepare_one_step): Adjust set_running call.
13152 (signal_command): Use user_visible_resume_target. Compare thread
13153 pointers instead of inferior_ptid.
13154 (info_program_command): Adjust to pass down target.
13155 (attach_command): Mark target's 'thread_executing' flag.
13156 (stop_current_target_threads_ns): New, factored out from ...
13157 (interrupt_target_1): ... this. Switch inferior before making
13158 target calls.
13159 * inferior-iter.h
13160 (struct all_inferiors_iterator, struct all_inferiors_range)
13161 (struct all_inferiors_safe_range)
13162 (struct all_non_exited_inferiors_range): Filter on
13163 process_stratum_target too. Remove explicit.
13164 * inferior.c (inferior::inferior): Push dummy target on target
13165 stack.
13166 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
13167 Add process_stratum_target parameter, and pass it down.
13168 (have_live_inferiors): Adjust.
13169 (switch_to_inferior_and_push_target): New.
13170 (add_inferior_command, clone_inferior_command): Handle
13171 "-no-connection" parameter. Use
13172 switch_to_inferior_and_push_target.
13173 (_initialize_inferior): Mention "-no-connection" option in
13174 the help of "add-inferior" and "clone-inferior" commands.
13175 * inferior.h: Include "process-stratum-target.h".
13176 (interrupt_target_1): Use bool.
13177 (struct inferior) <push_target, unpush_target, target_is_pushed,
13178 find_target_beneath, top_target, process_target, target_at,
13179 m_stack>: New.
13180 (discard_all_inferiors): Delete.
13181 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
13182 (all_inferiors, all_non_exited_inferiors): Add
13183 process_stratum_target parameter.
13184 * infrun.c: Include "gdb_select.h" and <unordered_map>.
13185 (target_last_proc_target): New global.
13186 (follow_fork_inferior): Push target on new inferior. Pass target
13187 to add_thread_silent. Call exec_on_vfork. Handle target's
13188 reference count.
13189 (follow_fork): Adjust get_last_target_status call. Also consider
13190 target.
13191 (follow_exec): Push target on new inferior.
13192 (struct execution_control_state) <target>: New field.
13193 (user_visible_resume_target): New.
13194 (do_target_resume): Call target_async.
13195 (resume_1): Set target's threads_executing flag. Consider resume
13196 target.
13197 (commit_resume_all_targets): New.
13198 (proceed): Also consider resume target. Skip threads of inferiors
13199 with no execution. Commit resumtion in all targets.
13200 (start_remote): Pass current inferior to wait_for_inferior.
13201 (infrun_thread_stop_requested): Consider target as well. Pass
13202 thread_info pointer to clear_inline_frame_state instead of ptid.
13203 (infrun_thread_thread_exit): Consider target as well.
13204 (random_pending_event_thread): New inferior parameter. Use it.
13205 (do_target_wait): Rename to ...
13206 (do_target_wait_1): ... this. Add inferior parameter, and pass it
13207 down.
13208 (threads_are_resumed_pending_p, do_target_wait): New.
13209 (prepare_for_detach): Adjust calls.
13210 (wait_for_inferior): New inferior parameter. Handle it. Use
13211 do_target_wait_1 instead of do_target_wait.
13212 (fetch_inferior_event): Adjust. Switch to representative
13213 inferior. Pass target down.
13214 (set_last_target_status): Add process_stratum_target parameter.
13215 Save target in global.
13216 (get_last_target_status): Add process_stratum_target parameter and
13217 handle it.
13218 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
13219 (context_switch): Check inferior_ptid == null_ptid before calling
13220 inferior_thread().
13221 (get_inferior_stop_soon): Pass down target.
13222 (wait_one): Rename to ...
13223 (poll_one_curr_target): ... this.
13224 (struct wait_one_event): New.
13225 (wait_one): New.
13226 (stop_all_threads): Adjust.
13227 (handle_no_resumed, handle_inferior_event): Adjust to consider the
13228 event's target.
13229 (switch_back_to_stepped_thread): Also consider target.
13230 (print_stop_event): Update.
13231 (normal_stop): Update. Also consider the resume target.
13232 * infrun.h (wait_for_inferior): Remove declaration.
13233 (user_visible_resume_target): New declaration.
13234 (get_last_target_status, set_last_target_status): New
13235 process_stratum_target parameter.
13236 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
13237 process_stratum_target parameter, and use it.
13238 (clear_inline_frame_state (thread_info*)): New.
13239 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
13240 process_stratum_target parameter.
13241 (clear_inline_frame_state (thread_info*)): Declare.
13242 * linux-fork.c (delete_checkpoint_command): Pass target down to
13243 find_thread_ptid.
13244 (checkpoint_command): Adjust.
13245 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
13246 instead of just tweaking inferior_ptid.
13247 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
13248 (exit_lwp): Pass target down to find_thread_ptid.
13249 (attach_proc_task_lwp_callback): Pass target down to
13250 add_thread/set_running/set_executing.
13251 (linux_nat_target::attach): Pass target down to
13252 thread_change_ptid.
13253 (get_detach_signal): Pass target down to find_thread_ptid.
13254 Consider last target status's target.
13255 (linux_resume_one_lwp_throw, resume_lwp)
13256 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
13257 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
13258 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
13259 (linux_nat_target::async_wait_fd): New.
13260 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
13261 target down.
13262 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
13263 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
13264 * linux-thread-db.c (struct thread_db_info::process_target): New
13265 field.
13266 (add_thread_db_info): Save target.
13267 (get_thread_db_info): New process_stratum_target parameter. Also
13268 match target.
13269 (delete_thread_db_info): New process_stratum_target parameter.
13270 Also match target.
13271 (thread_from_lwp): Adjust to pass down target.
13272 (thread_db_notice_clone): Pass down target.
13273 (check_thread_db_callback): Pass down target.
13274 (try_thread_db_load_1): Always push the thread_db target.
13275 (try_thread_db_load, record_thread): Pass target down.
13276 (thread_db_target::detach): Pass target down. Always unpush the
13277 thread_db target.
13278 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
13279 target down. Always unpush the thread_db target.
13280 (find_new_threads_callback, thread_db_find_new_threads_2)
13281 (thread_db_target::update_thread_list): Pass target down.
13282 (thread_db_target::pid_to_str): Pass current inferior down.
13283 (thread_db_target::get_thread_local_address): Pass target down.
13284 (thread_db_target::resume, maintenance_check_libthread_db): Pass
13285 target down.
13286 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
13287 * procfs.c (procfs_target::procfs_init_inferior): Declare.
13288 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
13289 (procfs_init_inferior): Rename to ...
13290 (procfs_target::procfs_init_inferior): ... this and adjust.
13291 (procfs_target::create_inferior, procfs_notice_thread)
13292 (procfs_do_thread_registers): Adjust.
13293 * ppc-fbsd-tdep.c: Include "inferior.h".
13294 (ppcfbsd_get_thread_local_address): Pass down target.
13295 * proc-service.c (ps_xfer_memory): Switch current inferior and
13296 program space as well.
13297 (get_ps_regcache): Pass target down.
13298 * process-stratum-target.c
13299 (process_stratum_target::thread_address_space)
13300 (process_stratum_target::thread_architecture): Pass target down.
13301 * process-stratum-target.h
13302 (process_stratum_target::threads_executing): New field.
13303 (as_process_stratum_target): New.
13304 * ravenscar-thread.c
13305 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
13306 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
13307 down.
13308 * record-btrace.c (record_btrace_target::info_record): Adjust.
13309 (record_btrace_target::record_method)
13310 (record_btrace_target::record_is_replaying)
13311 (record_btrace_target::fetch_registers)
13312 (get_thread_current_frame_id, record_btrace_target::resume)
13313 (record_btrace_target::wait, record_btrace_target::stop): Pass
13314 target down.
13315 * record-full.c (record_full_wait_1): Switch to event thread.
13316 Pass target down.
13317 * regcache.c (regcache::regcache)
13318 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
13319 process_stratum_target parameter and handle it.
13320 (current_thread_target): New global.
13321 (get_thread_regcache): Add process_stratum_target parameter and
13322 handle it. Switch inferior before calling target method.
13323 (get_thread_regcache): Pass target down.
13324 (get_thread_regcache_for_ptid): Pass target down.
13325 (registers_changed_ptid): Add process_stratum_target parameter and
13326 handle it.
13327 (registers_changed_thread, registers_changed): Pass target down.
13328 (test_get_thread_arch_aspace_regcache): New.
13329 (current_regcache_test): Define a couple local test_target_ops
13330 instances and use them for testing.
13331 (readwrite_regcache): Pass process_stratum_target parameter.
13332 (cooked_read_test, cooked_write_test): Pass mock_target down.
13333 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
13334 (get_thread_arch_aspace_regcache): Add process_stratum_target
13335 parameter.
13336 (regcache::target): New method.
13337 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
13338 (regcache::registers_changed_ptid): Add process_stratum_target
13339 parameter.
13340 (regcache::m_target): New field.
13341 (registers_changed_ptid): Add process_stratum_target parameter.
13342 * remote.c (remote_state::supports_vCont_probed): New field.
13343 (remote_target::async_wait_fd): New method.
13344 (remote_unpush_and_throw): Add remote_target parameter.
13345 (get_current_remote_target): Adjust.
13346 (remote_target::remote_add_inferior): Push target.
13347 (remote_target::remote_add_thread)
13348 (remote_target::remote_notice_new_inferior)
13349 (get_remote_thread_info): Pass target down.
13350 (remote_target::update_thread_list): Skip threads of inferiors
13351 bound to other targets. (remote_target::close): Don't discard
13352 inferiors. (remote_target::add_current_inferior_and_thread)
13353 (remote_target::process_initial_stop_replies)
13354 (remote_target::start_remote)
13355 (remote_target::remote_serial_quit_handler): Pass down target.
13356 (remote_target::remote_unpush_target): New remote_target
13357 parameter. Unpush the target from all inferiors.
13358 (remote_target::remote_unpush_and_throw): New remote_target
13359 parameter. Pass it down.
13360 (remote_target::open_1): Check whether the current inferior has
13361 execution instead of checking whether any inferior is live. Pass
13362 target down.
13363 (remote_target::remote_detach_1): Pass down target. Use
13364 remote_unpush_target.
13365 (extended_remote_target::attach): Pass down target.
13366 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
13367 (remote_target::append_resumption): Pass down target.
13368 (remote_target::append_pending_thread_resumptions)
13369 (remote_target::remote_resume_with_hc, remote_target::resume)
13370 (remote_target::commit_resume): Pass down target.
13371 (remote_target::remote_stop_ns): Check supports_vCont_probed.
13372 (remote_target::interrupt_query)
13373 (remote_target::remove_new_fork_children)
13374 (remote_target::check_pending_events_prevent_wildcard_vcont)
13375 (remote_target::remote_parse_stop_reply)
13376 (remote_target::process_stop_reply): Pass down target.
13377 (first_remote_resumed_thread): New remote_target parameter. Pass
13378 it down.
13379 (remote_target::wait_as): Pass down target.
13380 (unpush_and_perror): New remote_target parameter. Pass it down.
13381 (remote_target::readchar, remote_target::remote_serial_write)
13382 (remote_target::getpkt_or_notif_sane_1)
13383 (remote_target::kill_new_fork_children, remote_target::kill): Pass
13384 down target.
13385 (remote_target::mourn_inferior): Pass down target. Use
13386 remote_unpush_target.
13387 (remote_target::core_of_thread)
13388 (remote_target::remote_btrace_maybe_reopen): Pass down target.
13389 (remote_target::pid_to_exec_file)
13390 (remote_target::thread_handle_to_thread_info): Pass down target.
13391 (remote_target::async_wait_fd): New.
13392 * riscv-fbsd-tdep.c: Include "inferior.h".
13393 (riscv_fbsd_get_thread_local_address): Pass down target.
13394 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
13395 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
13396 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
13397 Adjust.
13398 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
13399 * solib-svr4.c (enable_break): Pass down target.
13400 * spu-multiarch.c (parse_spufs_run): Pass down target.
13401 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
13402 * target-delegates.c: Regenerate.
13403 * target.c (g_target_stack): Delete.
13404 (current_top_target): Return the current inferior's top target.
13405 (target_has_execution_1): Refer to the passed-in inferior's top
13406 target.
13407 (target_supports_terminal_ours): Check whether the initial
13408 inferior was already created.
13409 (decref_target): New.
13410 (target_stack::push): Incref/decref the target.
13411 (push_target, push_target, unpush_target): Adjust.
13412 (target_stack::unpush): Defref target.
13413 (target_is_pushed): Return bool. Adjust to refer to the current
13414 inferior's target stack.
13415 (dispose_inferior): Delete, and inline parts ...
13416 (target_preopen): ... here. Only dispose of the current inferior.
13417 (target_detach): Hold strong target reference while detaching.
13418 Pass target down.
13419 (target_thread_name): Add assertion.
13420 (target_resume): Pass down target.
13421 (target_ops::beneath, find_target_at): Adjust to refer to the
13422 current inferior's target stack.
13423 (get_dummy_target): New.
13424 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
13425 has a thread running.
13426 (initialize_targets): Rename to ...
13427 (_initialize_target): ... this.
13428 * target.h: Include "gdbsupport/refcounted-object.h".
13429 (struct target_ops): Inherit refcounted_object.
13430 (target_ops::shortname, target_ops::longname): Make const.
13431 (target_ops::async_wait_fd): New method.
13432 (decref_target): Declare.
13433 (struct target_ops_ref_policy): New.
13434 (target_ops_ref): New typedef.
13435 (get_dummy_target): Declare function.
13436 (target_is_pushed): Return bool.
13437 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
13438 (all_matching_threads_iterator::all_matching_threads_iterator):
13439 Handle filter target.
13440 * thread-iter.h (struct all_matching_threads_iterator, struct
13441 all_matching_threads_range, class all_non_exited_threads_range):
13442 Filter by target too. Remove explicit.
13443 * thread.c (threads_executing): Delete.
13444 (inferior_thread): Pass down current inferior.
13445 (clear_thread_inferior_resources): Pass down thread pointer
13446 instead of ptid_t.
13447 (add_thread_silent, add_thread_with_info, add_thread): Add
13448 process_stratum_target parameter. Use it for thread and inferior
13449 searches.
13450 (is_current_thread): New.
13451 (thread_info::deletable): Use it.
13452 (find_thread_ptid, thread_count, in_thread_list)
13453 (thread_change_ptid, set_resumed, set_running): New
13454 process_stratum_target parameter. Pass it down.
13455 (set_executing): New process_stratum_target parameter. Pass it
13456 down. Adjust reference to 'threads_executing'.
13457 (threads_are_executing): New process_stratum_target parameter.
13458 Adjust reference to 'threads_executing'.
13459 (set_stop_requested, finish_thread_state): New
13460 process_stratum_target parameter. Pass it down.
13461 (switch_to_thread): Also match inferior.
13462 (switch_to_thread): New process_stratum_target parameter. Pass it
13463 down.
13464 (update_threads_executing): Reimplement.
13465 * top.c (quit_force): Pop targets from all inferior.
13466 (gdb_init): Don't call initialize_targets.
13467 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
13468 Declare.
13469 (windows_add_thread, windows_delete_thread): Adjust.
13470 (get_windows_debug_event): Rename to ...
13471 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
13472 * tracefile-tfile.c (tfile_target_open): Pass down target.
13473 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
13474 Forward declare.
13475 (switch_to_thread): Add process_stratum_target parameter.
13476 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
13477 parameter. Use it.
13478 (mi_on_resume): Pass target down.
13479 * nat/fork-inferior.c (startup_inferior): Add
13480 process_stratum_target parameter. Pass it down.
13481 * nat/fork-inferior.h (startup_inferior): Add
13482 process_stratum_target parameter.
13483 * python/py-threadevent.c (py_get_event_thread): Pass target down.
13484
13485 2020-01-10 Pedro Alves <palves@redhat.com>
13486
13487 * remote.c (remote_target::start_remote): Don't set inferior_ptid
13488 directly. Instead find the first thread in the thread list and
13489 use switch_to_thread.
13490
13491 2020-01-10 Pedro Alves <palves@redhat.com>
13492
13493 * remote.c (remote_target::remote_add_inferior): Don't bind a
13494 process to the current inferior if the current inferior is already
13495 bound to a process.
13496
13497 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
13498 Pedro Alves <palves@redhat.com>
13499
13500 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
13501 If no process is specified, return null_ptid instead of
13502 inferior_ptid.
13503 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
13504 TARGET_WAITKIND_SIGNALLED with no pid.
13505
13506 2020-01-10 Pedro Alves <palves@redhat.com>
13507
13508 * remote.c (first_remote_resumed_thread): New.
13509 (remote_target::wait_as): Use it as default event_ptid instead of
13510 inferior_ptid.
13511
13512 2020-01-10 Pedro Alves <palves@redhat.com>
13513
13514 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
13515
13516 2020-01-10 Pedro Alves <palves@redhat.com>
13517
13518 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
13519 not -1.
13520
13521 2020-01-10 Pedro Alves <palves@redhat.com>
13522
13523 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
13524 ptid to get_last_target_status.
13525 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
13526 ptid to get_last_target_status.
13527 * infcmd.c (continue_command): Don't pass a target_waitstatus to
13528 get_last_target_status.
13529 (info_program_command): Don't pass a target_waitstatus to
13530 get_last_target_status.
13531 * infrun.c (init_wait_for_inferior): Use
13532 nullify_last_target_wait_ptid.
13533 (get_last_target_status): Handle nullptr arguments.
13534 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
13535 (print_stop_event): Don't pass a ptid to get_last_target_status.
13536 (normal_stop): Don't pass a ptid to get_last_target_status.
13537 * infrun.h (get_last_target_status, set_last_target_status): Move
13538 comments here and update.
13539 (nullify_last_target_wait_ptid): Declare.
13540 * linux-fork.c (fork_load_infrun_state): Remove local extern
13541 declaration of nullify_last_target_wait_ptid.
13542 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
13543 to get_last_target_status.
13544
13545 2020-01-10 Pedro Alves <palves@redhat.com>
13546
13547 * gdbthread.h (scoped_restore_current_thread)
13548 <dont_restore, restore, m_dont_restore>: Declare.
13549 * thread.c (thread_alive): Add assertion. Return bool.
13550 (switch_to_thread_if_alive): New.
13551 (prune_threads): Switch inferior/thread.
13552 (print_thread_info_1): Switch thread before calling target methods.
13553 (scoped_restore_current_thread::restore): New, factored out from
13554 ...
13555 (scoped_restore_current_thread::~scoped_restore_current_thread):
13556 ... this.
13557 (scoped_restore_current_thread::scoped_restore_current_thread):
13558 Add assertion.
13559 (thread_apply_all_command, thread_select): Use
13560 switch_to_thread_if_alive.
13561 * infrun.c (proceed, restart_threads, handle_signal_stop)
13562 (switch_back_to_stepped_thread): Switch current thread before
13563 calling target methods.
13564
13565 2020-01-10 Pedro Alves <palves@redhat.com>
13566
13567 * inferior.c (switch_to_inferior_no_thread): New function,
13568 factored out from ...
13569 (inferior_command): ... here.
13570 * inferior.h (switch_to_inferior_no_thread): Declare.
13571 * mi/mi-main.c (run_one_inferior): Use
13572 switch_to_inferior_no_thread.
13573
13574 2020-01-10 Pedro Alves <palves@redhat.com>
13575
13576 * infcmd.c (kill_command): Remove dead code.
13577
13578 2020-01-10 Pedro Alves <palves@redhat.com>
13579
13580 * remote.c (remote_target::mourn_inferior): No longer check
13581 whether the target is running.
13582
13583 2020-01-10 Pedro Alves <palves@redhat.com>
13584
13585 * corelow.c (core_target::has_execution): Change parameter type to
13586 inferior pointer.
13587 * inferior.c (number_of_live_inferiors): Use
13588 inferior::has_execution instead of target_has_execution_1.
13589 * inferior.h (inferior::has_execution): New.
13590 * linux-thread-db.c (thread_db_target::update_thread_list): Use
13591 inferior::has_execution instead of target_has_execution_1.
13592 * process-stratum-target.c
13593 (process_stratum_target::has_execution): Change parameter type to
13594 inferior pointer. Check the inferior's PID instead of
13595 inferior_ptid.
13596 * process-stratum-target.h
13597 (process_stratum_target::has_execution): Change parameter type to
13598 inferior pointer.
13599 * record-full.c (record_full_core_target::has_execution): Change
13600 parameter type to inferior pointer.
13601 * target.c (target_has_execution_1): Change parameter type to
13602 inferior pointer.
13603 (target_has_execution_current): Adjust.
13604 * target.h (target_ops::has_execution): Change parameter type to
13605 inferior pointer.
13606 (target_has_execution_1): Change parameter type to inferior
13607 pointer. Change return type to bool.
13608 * tracefile.h (tracefile_target::has_execution): Change parameter
13609 type to inferior pointer.
13610
13611 2020-01-10 Pedro Alves <palves@redhat.com>
13612
13613 * exceptions.c (print_flush): Remove current_top_target() check.
13614
13615 2020-01-10 Pedro Alves <palves@redhat.com>
13616
13617 * remote.c (show_remote_exec_file): Show the current inferior's
13618 exec-file instead of the command variable's value.
13619
13620 2020-01-10 Pedro Alves <palves@redhat.com>
13621
13622 * record-full.c (record_full_resume_ptid): New global.
13623 (record_full_target::resume): Set it.
13624 (record_full_wait_1): Use record_full_resume_ptid instead of
13625 inferior_ptid.
13626
13627 2020-01-10 Pedro Alves <palves@redhat.com>
13628
13629 * gdbthread.h (scoped_restore_current_thread)
13630 <dont_restore, restore, m_dont_restore>: Declare.
13631 * thread.c (thread_alive): Add assertion. Return bool.
13632 (switch_to_thread_if_alive): New.
13633 (prune_threads): Switch inferior/thread.
13634 (print_thread_info_1): Switch thread before calling target methods.
13635 (scoped_restore_current_thread::restore): New, factored out from
13636 ...
13637 (scoped_restore_current_thread::~scoped_restore_current_thread):
13638 ... this.
13639 (scoped_restore_current_thread::scoped_restore_current_thread):
13640 Add assertion.
13641 (thread_apply_all_command, thread_select): Use
13642 switch_to_thread_if_alive.
13643
13644 2020-01-10 George Barrett <bob@bob131.so>
13645
13646 * stap-probe.c (stap_modify_semaphore): Don't check for null
13647 semaphores.
13648 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
13649 for null semaphores.
13650
13651 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
13652
13653 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
13654 all source windows, and maintain horizontal scroll status while
13655 doing so.
13656
13657 2020-01-09 Tom Tromey <tom@tromey.com>
13658
13659 PR tui/18932:
13660 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
13661 update_source_window, not print_source_lines.
13662
13663 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
13664
13665 * tui/tui.c (tui_enable): Register tui hooks after calling
13666 tui_display_main.
13667
13668 2020-01-09 Christian Biesinger <cbiesinger@google.com>
13669
13670 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
13671
13672 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
13673
13674 * thread.c (print_thread_info_1): Fix indentation.
13675
13676 2020-01-09 Christian Biesinger <cbiesinger@google.com>
13677
13678 * symtab.c (general_symbol_info::compute_and_set_names): Move the
13679 unique_xmalloc_ptr outside the if to always free the demangled name.
13680
13681 2020-01-08 Tom Tromey <tromey@adacore.com>
13682
13683 * xcoffread.c (enter_line_range, read_xcoff_symtab)
13684 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
13685 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
13686 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
13687 Remove.
13688 (section_offsets): New typedef.
13689 * symtab.c (fixup_section, get_msymbol_address): Update.
13690 * symmisc.c (dump_msymbols): Update.
13691 * symfile.h (relative_addr_info_to_section_offsets)
13692 (symfile_map_offsets_to_segments): Update.
13693 * symfile.c (build_section_addr_info_from_objfile)
13694 (init_objfile_sect_indices): Update.
13695 (struct place_section_arg): Change type of "offsets".
13696 (place_section): Update.
13697 (relative_addr_info_to_section_offsets): Change type of
13698 "section_offsets". Remove "num_sections" parameter.
13699 (default_symfile_offsets, syms_from_objfile_1)
13700 (set_objfile_default_section_offset): Update.
13701 (reread_symbols): No need to preserve section offsets by hand.
13702 (symfile_map_offsets_to_segments): Change type of "offsets".
13703 * stap-probe.c (relocate_address): Update.
13704 * stabsread.h (process_one_symbol): Update.
13705 * solib-target.c (struct lm_info_target) <offsets>: Change type.
13706 (solib_target_relocate_section_addresses): Update.
13707 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
13708 Update.
13709 * solib-frv.c (frv_relocate_main_executable): Update.
13710 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
13711 * solib-aix.c (solib_aix_get_section_offsets): Change return
13712 type.
13713 (solib_aix_solib_create_inferior_hook): Update.
13714 * remote.c (remote_target::get_offsets): Update.
13715 * psymtab.c (find_pc_sect_psymtab): Update.
13716 * psympriv.h (struct partial_symbol) <address, text_low,
13717 text_high>: Update.
13718 * objfiles.h (obj_section_offset): Update.
13719 (struct objfile) <section_offsets>: Change type.
13720 <num_sections>: Remove.
13721 (objfile_relocate): Update.
13722 * objfiles.c (entry_point_address_query): Update
13723 (relocate_one_symbol): Change type of "section_offsets".
13724 (objfile_relocate1, objfile_relocate1): Change type of
13725 "new_offsets".
13726 (objfile_rebase1): Update.
13727 * mipsread.c (mipscoff_symfile_read): Update.
13728 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
13729 parameter.
13730 * mdebugread.c (parse_symbol): Change type of "section_offsets".
13731 (parse_external, psymtab_to_symtab_1): Update.
13732 * machoread.c (macho_symfile_offsets): Update.
13733 * ia64-tdep.c (ia64_find_unwind_table): Update.
13734 * hppa-tdep.c (read_unwind_info): Update.
13735 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
13736 * dwarf2read.c (create_addrmap_from_index)
13737 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
13738 (process_psymtab_comp_unit_reader, add_partial_symbol)
13739 (add_partial_subprogram, process_full_comp_unit)
13740 (read_file_scope, read_func_scope, read_lexical_block_scope)
13741 (read_call_site_scope, dwarf2_rnglists_process)
13742 (dwarf2_ranges_process, dwarf2_ranges_read)
13743 (dwarf_decode_lines_1, var_decode_location, new_symbol)
13744 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
13745 Update.
13746 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
13747 Update.
13748 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
13749 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
13750 (process_one_symbol): Change type of "section_offsets".
13751 * ctfread.c (get_objfile_text_range): Update.
13752 * coffread.c (coff_symtab_read, enter_linenos)
13753 (process_coff_symbol): Update.
13754 * coff-pe-read.c (add_pe_forwarded_sym): Update.
13755 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
13756
13757 2020-01-08 Tom Tromey <tromey@adacore.com>
13758
13759 * dwarf2read.c (parse_macro_definition): Use std::string.
13760 (parse_macro_definition): Likewise.
13761
13762 2020-01-08 Tom Tromey <tromey@adacore.com>
13763
13764 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
13765 (ATTR_ALLOC_CHUNK): Remove.
13766
13767 2020-01-08 Tom Tromey <tromey@adacore.com>
13768
13769 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
13770
13771 2020-01-08 Tom Tromey <tromey@adacore.com>
13772
13773 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
13774 (dwarf2_compute_name, open_dwo_file): Likewise.
13775 (process_enumeration_scope): Use std::vector.
13776 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
13777 (partial_die_info::fixup, dwarf2_start_subfile)
13778 (guess_full_die_structure_name, dwarf2_name): Likewise.
13779 (determine_prefix): Update.
13780 (guess_full_die_structure_name): Make return type const.
13781 (partial_die_full_name): Return unique_xmalloc_ptr.
13782 (DW_FIELD_ALLOC_CHUNK): Remove.
13783
13784 2020-01-07 Tom Tromey <tromey@adacore.com>
13785
13786 PR build/24937:
13787 * stap-probe.c (class stap_static_probe_ops): Add constructor.
13788
13789 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
13790
13791 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
13792
13793 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
13794
13795 * stack.c (print_frame_info): Move disassemble_next_line code
13796 inside source_print block.
13797
13798 2020-01-06 Eli Zaretskii <eliz@gnu.org>
13799
13800 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
13801 gdb/signals.h, as we are now using native signal symbols.
13802
13803 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
13804
13805 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
13806 overflow by an early check of content vs threshold.
13807 * tui/tui-source.c (tui_source_window::line_is_displayed):
13808 Likewise.
13809
13810 2020-01-06 Eli Zaretskii <eliz@gnu.org>
13811
13812 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
13813
13814 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
13815
13816 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
13817 export table if no section contains it's RVA.
13818
13819 2020-01-06 Eli Zaretskii <eliz@gnu.org>
13820
13821 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
13822
13823 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
13824
13825 * source.c (print_source_lines_base): Set last_line_listed.
13826
13827 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
13828
13829 * tui/tui-disasm.c: Remove trailing spaces.
13830
13831 2020-01-06 Eli Zaretskii <eliz@gnu.org>
13832 Pedro Alves <palves@redhat.com>
13833
13834 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
13835 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
13836 (windows_gdb_signal_to_target): New function, uses the above
13837 enumeration to convert GDB internal signal codes to equivalent
13838 Windows codes.
13839 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
13840 * windows-nat.c: Include "gdb_wait.h".
13841 (get_windows_debug_event): Extract the fatal exception from the
13842 exit status and convert to the equivalent Posix signal number.
13843 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
13844 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
13845 * gdbsupport/gdb_wait.c: New file, implements
13846 windows_status_to_termsig.
13847 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
13848 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
13849
13850 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
13851
13852 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
13853 show_layout.
13854
13855 2020-01-05 Luis Machado <luis.machado@linaro.org>
13856
13857 * aarch64-linux-nat.c
13858 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
13859 and bfd_mach_aarch64.
13860
13861 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
13862
13863 * ui-file.c (stdio_file::can_emit_style_escape)
13864 (tee_file::can_emit_style_escape): Ensure style is used also on
13865 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
13866 to gdb_stdout.
13867 * main.c (set_gdb_data_directory): Use file style to output the
13868 warning that the given pathname is not a directory.
13869 * top.c (show_history_filename, gdb_safe_append_history)
13870 (show_gdb_datadir): Use file style.
13871
13872 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
13873
13874 * solib-target.c (struct lm_info_target):
13875 Change offsets to be a unique_xmalloc_ptr.
13876 (solib_target_relocate_section_addresses): Update.
13877
13878 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
13879
13880 * windows-nat.c (windows_clear_solib): Free so_list linked list.
13881
13882 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
13883
13884 * MAINTAINERS (Write After Approval): Add myself.
13885
13886 2020-01-02 Luis Machado <luis.machado@linaro.org>
13887
13888 * proc-service.c (get_ps_regcache): Remove reference to obsolete
13889 Cell BE architecture.
13890 * target.h (struct target_ops) <thread_architecture>: Likewise.
13891
13892 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
13893
13894 * Makefile.in: Use INSTALL_PROGRAM_ENV.
13895
13896 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
13897
13898 * MAINTAINERS (Write After Approval): Add myself.
13899
13900 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13901
13902 * gdbarch.sh: Update copyright year range of generated files.
13903
13904 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13905
13906 Update copyright year range in all GDB files.
13907
13908 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13909
13910 * copyright.py: Convert to Python 3.
13911
13912 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13913
13914 * copyright.py: Adapt after move of gnulib directory from gdb
13915 directory to toplevel directory.
13916
13917 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13918
13919 * copyright.py (main): Exit if run from the wrong directory.
13920
13921 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13922
13923 * top.c (print_gdb_version): Change copyright year to 2020.
13924
13925 2020-01-01 Joel Brobecker <brobecker@adacore.com>
13926
13927 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
13928
13929 For older changes see ChangeLog-2019.
13930 \f
13931 Local Variables:
13932 mode: change-log
13933 left-margin: 8
13934 fill-column: 74
13935 version-control: never
13936 coding: utf-8
13937 End:
This page took 0.315334 seconds and 4 git commands to generate.