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