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