]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
Retire the now-unused gdbarch handle_segmentation_fault hook.
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2020-07-21 John Baldwin <jhb@FreeBSD.org>
2
3 * gdbarch.c: Regenerate.
4 * gdbarch.h: Regenerate.
5 * gdbarch.sh (handle_segmentation_fault): Remove method.
6 * infrun.c (handle_segmentation_fault): Remove.
7 (print_signal_received_reason): Remove call to
8 handle_segmentation_fault.
9
10 2020-07-21 John Baldwin <jhb@FreeBSD.org>
11
12 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
13 Rename to sparc64_linux_report_signal_info and add siggnal
14 argument.
15 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
16 instead of sparc64_linux_handle_segmentation_fault.
17
18 2020-07-21 John Baldwin <jhb@FreeBSD.org>
19
20 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
21 i386_linux_report_signal_info instead of
22 i386_linux_handle_segmentation_fault.
23 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
24 to i386_linux_report_signal_info and add siggnal argument.
25 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
26 of i386_linux_handle_segmentation_fault.
27 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
28 to i386_linux_report_signal_info and add siggnal argument.
29
30 2020-07-21 John Baldwin <jhb@FreeBSD.org>
31
32 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
33 hook if present.
34
35 2020-07-21 John Baldwin <jhb@FreeBSD.org>
36
37 * gdbarch.c: Regenerate.
38 * gdbarch.h: Regenerate.
39 * gdbarch.sh (report_signal_info): New method.
40 * infrun.c (print_signal_received_reason): Invoke gdbarch
41 report_signal_info hook if present.
42
43 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
44
45 * python/py-registers.c : Add 'unordered_map' include.
46 (gdbpy_new_reggroup): Renamed to...
47 (gdbpy_get_reggroup): ...this. Update to only create register
48 group descriptors when needed.
49 (gdbpy_reggroup_iter_next): Update.
50
51 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
52
53 * python/py-registers.c (gdbpy_register_object_data): New static
54 global.
55 (gdbpy_register_object_data_init): New function.
56 (gdbpy_new_register_descriptor): Renamed to...
57 (gdbpy_get_register_descriptor): ...this, and update to reuse
58 existing register descriptors where possible.
59 (gdbpy_register_descriptor_iter_next): Update.
60 (gdbpy_initialize_registers): Register new gdbarch data.
61
62 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
63
64 * linux-nat.c (stopped_pids): Make static.
65
66 2020-07-21 Simon Marchi <simon.marchi@polymtl.ca>
67
68 PR ada/26235
69 * gdbtypes.c (ada_discrete_type_low_bound,
70 ada_discrete_type_high_bound): Handle undefined bounds.
71
72 2020-07-21 Kamil Rytarowski <n54@gmx.com>
73
74 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
75 declaration.
76 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
77 function.
78
79 2020-07-20 John Baldwin <jhb@FreeBSD.org>
80
81 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
82 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
83 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
84 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
85 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
86 method.
87
88 2020-07-20 Ludovic Courtès <ludo@gnu.org>
89
90 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
91 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
92 which are deprecated in Guile 3.0.
93 * configure.ac (try_guile_versions): Add "guile-3.0".
94 * configure (try_guile_versions): Regenerate.
95 * NEWS: Update entry.
96
97 2020-07-20 Ludovic Courtès <ludo@gnu.org>
98 Doug Evans <dje@google.com>
99
100 PR gdb/21104
101 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
102 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
103 USING_GUILE_BEFORE_2_2.
104 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
105 Change type to 'scm_t_port_type *'.
106 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
107 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
108 parameter and honor it. Update callers.
109 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
110 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
111 functions.
112 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
113 USING_GUILE_BEFORE_2_2.
114 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
115 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
116 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
117 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
118 and 'SCM_PORT_TYPE'.
119 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
120 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
121 (gdbscm_memory_port_read, gdbscm_memory_port_write)
122 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
123 [!USING_GUILE_BEFORE_2_2]: New functions.
124 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
125 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
126 'gdbscm_memory_port_read'.
127 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
128 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
129 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
130 function.
131 (ioscm_init_memory_port): Remove.
132 (ioscm_init_memory_port_stream): New function
133 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
134 function.
135 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
136 Return scm_from_uint (0).
137 (gdbscm_set_memory_port_read_buffer_size_x)
138 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
139 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
140 Return scm_from_uint (0).
141 (gdbscm_set_memory_port_write_buffer_size_x)
142 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
143 * configure.ac (try_guile_versions): Add "guile-2.2".
144 * configure: Regenerate.
145 * NEWS: Add entry.
146
147 2020-07-18 Tom Tromey <tom@tromey.com>
148
149 * linux-nat.c (linux_multi_process): Remove.
150 (linux_nat_target::supports_multi_process): Return true.
151
152 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
153
154 * arch/riscv.c (riscv_tdesc_cache): Change map type.
155 (riscv_lookup_target_description): Return pointer out of
156 unique_ptr.
157 * target-descriptions.c (allocate_target_description): Add
158 comment.
159 (target_desc_deleter::operator()): Likewise.
160 * target-descriptions.h (struct target_desc_deleter): Moved to
161 gdbsupport/tdesc.h.
162 (target_desc_up): Likewise.
163
164 2020-07-17 Tom Tromey <tromey@adacore.com>
165
166 * linux-nat.c (linux_nat_target::supports_non_stop)
167 (linux_nat_target::always_non_stop_p): Use "true".
168 (linux_nat_target::supports_disable_randomization): Use "true" and
169 "false".
170
171 2020-07-16 Caroline Tice <cmtice@google.com>
172
173 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
174 (RNGLIST_HEADER_SIZE64): New constant definition.
175 (struct dwop_section_names): Add rnglists_dwo.
176 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
177 (struct loclist_header): Rename to 'loclists_rnglists_header'.
178 (struct dwo_sections): Add rnglists field.
179 (read_attribut_reprocess): Add tag parameter.
180 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
181 (cu_debug_rnglists_section): New function (decl & definition).
182 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
183 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
184 die whose range is being checked; get rnglist section from
185 cu_debug_rnglists_section, to get from either objfile or dwo file as
186 appropriate. Add cases for DW_RLE_base_addressx,
187 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
188 the base address to DW_RLE_offset_pairs (not to all ranges), moving
189 test inside if-condition and updating complaint message.
190 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
191 dwarf2_rnglists_process.
192 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
193 dwarf2_ranges_process.
194 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
195 need_ranges_base and update comment appropriately. Also pass die tag
196 to dwarf2_ranges_read.
197 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
198 need_ranges_base and update comment appropriately. Also pass die tag
199 to dwarf2_ranges_process.
200 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
201 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
202 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
203 need_ranges_base and update comment appropriately. Also pass die tag
204 to read_attribute_reprocess and dwarf2_ranges_read.
205 (read_loclist_header): Rename function to read_loclists_rnglists_header,
206 and update function comment appropriately.
207 (read_loclist_index): Call read_loclists_rnglists_header instead of
208 read_loclist_header.
209 (read_rnglist_index): New function.
210 (read_attribute_reprocess): Add tag parameter. Add code for
211 DW_FORM_rnglistx, passing tag to read_rnglist_index.
212 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
213
214 2020-07-15 Andrew Burgess <andrew.burgess@embecosm.com>
215
216 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
217 being resolved.
218
219 2020-07-14 Andrew Burgess <andrew.burgess@embecosm.com>
220
221 * arch-utils.c (show_architecture): Update formatting of messages.
222
223 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
224
225 * gdbtypes.h (struct type) <bounds>: Handle array and string
226 types.
227 * ada-lang.c (assign_aggregate): Use type::bounds on
228 array/string type.
229 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
230 * c-varobj.c (c_number_of_children): Likewise.
231 (c_describe_child): Likewise.
232 * eval.c (evaluate_subexp_for_sizeof): Likewise.
233 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
234 (f_type_print_base): Likewise.
235 * f-valprint.c (f77_array_offset_tbl): Likewise.
236 (f77_get_upperbound): Likewise.
237 (f77_print_array_1): Likewise.
238 * guile/scm-type.c (gdbscm_type_range): Likewise.
239 * m2-typeprint.c (m2_array): Likewise.
240 (m2_is_long_set_of_type): Likewise.
241 * m2-valprint.c (get_long_set_bounds): Likewise.
242 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
243 * python/py-type.c (typy_range): Likewise.
244 * rust-lang.c (rust_internal_print_type): Likewise.
245 * type-stack.c (type_stack::follow_types): Likewise.
246 * valarith.c (value_subscripted_rvalue): Likewise.
247 * valops.c (value_cast): Likewise.
248
249 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
250
251 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
252 callers to use the equivalent accessor methods.
253
254 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
255
256 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
257 (struct type) <bit_stride>: New method.
258 (TYPE_BIT_STRIDE): Remove.
259 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
260
261 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
262
263 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
264 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
265 callers to use the equivalent accessor methods instead.
266
267 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
268
269 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
270 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
271 callers to use the equivalent accessor methods instead.
272
273 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
274
275 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
276 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
277 to use dynamic_prop::kind.
278
279 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
280
281 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
282 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
283 to get the bound property's kind and check against
284 PROP_UNDEFINED.
285
286 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
287
288 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
289 all callers to use type::range_bounds followed by
290 dynamic_prop::{low,high}.
291
292 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
293
294 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
295 const_val, set_const_val, baton, set_locexpr, set_loclist,
296 set_addr_offset, variant_parts, set_variant_parts,
297 original_type, set_original_type>: New methods.
298 <kind>: Rename to...
299 <m_kind>: ... this. Update all users to use the new methods
300 instead.
301 <data>: Rename to...
302 <m_data>: ... this. Update all users to use the new methods
303 instead.
304
305 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
306
307 * gdbtypes.c (get_discrete_bounds): Return failure if
308 the range type's bounds are not both defined and constant
309 values.
310 (get_array_bounds): Update comment. Remove undefined bound check.
311
312 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
313
314 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
315 the type::bounds method directly.
316
317 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
318
319 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
320 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
321 are used to set the range type's bounds to use set_bounds.
322
323 2020-07-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
324
325 * exec.c (_initialize_exec): Update exec-file-mismatch help.
326
327 2020-07-10 Pedro Alves <pedro@palves.net>
328
329 * gdbthread.h (inferior_ref): Define.
330 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
331 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
332 * thread.c
333 (scoped_restore_current_thread::restore):
334 Adjust to gdb::ref_ptr.
335 (scoped_restore_current_thread::~scoped_restore_current_thread):
336 Remove manual decref handling.
337 (scoped_restore_current_thread::scoped_restore_current_thread):
338 Adjust to use
339 inferior_ref::new_reference/thread_info_ref::new_reference.
340 Incref the thread before calling get_frame_id instead of after.
341 Let TARGET_CLOSE_ERROR propagate.
342
343 2020-07-10 Pedro Alves <pedro@palves.net>
344
345 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
346 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
347 NOT_AVAILABLE_ERROR.
348 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
349 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
350
351 2020-07-10 Simon Marchi <simon.marchi@polymtl.ca>
352 Pedro Alves <pedro@palves.net>
353
354 PR gdb/26199
355 * infrun.c (threads_are_resumed_pending_p): Delete.
356 (do_target_wait): Remove threads_are_executing and
357 threads_are_resumed_pending_p checks from the inferior_matches
358 lambda. Update comments.
359
360 2020-07-10 Pedro Alves <pedro@palves.net>
361
362 PR gdb/26199
363 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
364 executing threads.
365
366 2020-07-10 Pedro Alves <pedro@palves.net>
367
368 PR gdb/26199
369 * infrun.c (handle_no_resumed): Handle multiple targets.
370
371 2020-07-10 Pedro Alves <pedro@palves.net>
372
373 PR gdb/26199
374 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
375 target_is_async_p.
376
377 2020-07-10 Pedro Alves <pedro@palves.net>
378
379 PR gdb/26199
380 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
381 threads, not all threads.
382
383 2020-07-10 Pedro Alves <pedro@palves.net>
384
385 PR gdb/26199
386 * remote.c (remote_target::open_1): Pass remote target pointer as
387 data to create_async_event_handler.
388 (remote_async_inferior_event_handler): Mark async event handler
389 before returning if the remote target still has either pending
390 events or unacknowledged notifications.
391
392 2020-07-10 John Baldwin <jhb@FreeBSD.org>
393
394 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
395 declaration.
396 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
397 function.
398
399 2020-07-09 John Baldwin <jhb@FreeBSD.org>
400
401 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
402 inferior_ptid.
403
404 2020-07-09 John Baldwin <jhb@FreeBSD.org>
405
406 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
407 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
408 AT_FREEBSD_PS_STRINGS.
409
410 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
411
412 * auto-load.c (auto_load_objfile_script_1): Convert drive part
413 of debugfile path on Windows.
414
415 2020-07-08 John Baldwin <jhb@FreeBSD.org>
416
417 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
418 argument to 'data'.
419
420 2020-07-08 Tom Tromey <tromey@adacore.com>
421
422 * ada-lang.c (ada_exception_message_1): Use read_memory.
423
424 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
425
426 PR python/22748
427 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
428 special handling for inline frames.
429 * findvar.c (value_of_register_lazy): Skip inline frames when
430 creating lazy register values.
431 * frame.c (frame_id_computed_p): Delete definition.
432 * frame.h (frame_id_computed_p): Delete declaration.
433
434 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
435
436 * NEWS: Mention additions to Python API.
437 * python/py-arch.c (archpy_register_groups): New function.
438 (arch_object_methods): Add 'register_groups' method.
439 * python/py-registers.c (reggroup_iterator_object): New struct.
440 (reggroup_object): New struct.
441 (gdbpy_new_reggroup): New function.
442 (gdbpy_reggroup_to_string): New function.
443 (gdbpy_reggroup_name): New function.
444 (gdbpy_reggroup_iter): New function.
445 (gdbpy_reggroup_iter_next): New function.
446 (gdbpy_new_reggroup_iterator): New function
447 (gdbpy_initialize_registers): Register new types.
448 (reggroup_iterator_object_type): Define new Python type.
449 (gdbpy_reggroup_getset): New static global.
450 (reggroup_object_type): Define new Python type.
451 * python/python-internal.h
452
453 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
454
455 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
456 * python/py-arch.c (archpy_registers): New function.
457 (arch_object_methods): Add 'registers' method.
458 * python/py-registers.c: New file.
459 * python/python-internal.h
460 (gdbpy_new_register_descriptor_iterator): Declare.
461 (gdbpy_initialize_registers): Declare.
462 * python/python.c (do_start_initialization): Call
463 gdbpy_initialize_registers.
464 * NEWS: Mention additions to the Python API.
465
466 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
467
468 * NEWS: Mention new Python API method.
469 * python/py-unwind.c (pending_framepy_architecture): New function.
470 (pending_frame_object_methods): Add architecture method.
471
472 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
473
474 * gdbarch.c: Regenerate.
475 * gdbarch.h: Regenerate.
476 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
477 (gdbarch_data): Use internal_error for the case where
478 deprecated_set_gdbarch_data was originally needed.
479 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
480 and use passed in obstack.
481 (libunwind_frame_set_descr): Should no longer get back NULL from
482 gdbarch_data.
483 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
484 type.
485 * user-regs.c (user_regs_init): Update parameters, and use passed
486 in obstack.
487 (user_reg_add): Should no longer get back NULL from gdbarch_data.
488 (_initialize_user_regs): Register as a pre-init gdbarch data type.
489
490 2020-07-06 Tom de Vries <tdevries@suse.de>
491
492 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
493 End-Of-Sequence in lte_is_less_than.
494 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
495 "gdb: Don't reorder line table entries too much when sorting".
496
497 2020-07-06 Tom de Vries <tdevries@suse.de>
498
499 PR tui/26205
500 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
501
502 2020-07-05 Tom de Vries <tdevries@suse.de>
503
504 PR build/26187
505 * inferior.h (struct infcall_suspend_state_deleter): If available, use
506 std::uncaught_exceptions instead of deprecated
507 std::uncaught_exception.
508
509 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
510
511 * macroexp.h (macro_stringify): Return
512 gdb::unique_xmalloc_ptr<char>.
513 * macroexp.c (macro_stringify): Likewise.
514 * macrotab.c (fixup_definition): Update.
515
516 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
517
518 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
519 (lex_one_token): Update.
520 * macroexp.c (struct macro_buffer) <release>: Return
521 gdb::unique_xmalloc_ptr<char>.
522 (macro_stringify): Update.
523 (macro_expand): Update.
524 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
525 * macroexp.h (macro_expand_next): Likewise.
526
527 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
528
529 * macroexp.h (macro_lookup_ftype): Remove.
530 (macro_expand, macro_expand_once, macro_expand_next): Remove
531 lookup function parameters, add scope parameter.
532 * macroexp.c (scan, substitute_args, expand, maybe_expand,
533 macro_expand, macro_expand_once, macro_expand_next): Likewise.
534 * macroscope.h (standard_macro_lookup): Change parameter type
535 to macro_scope.
536 * macroscope.c (standard_macro_lookup): Likewise.
537 * c-exp.y (lex_one_token): Update.
538 * macrocmd.c (macro_expand_command): Likewise.
539 (macro_expand_once_command): Likewise.
540
541 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
542
543 * inf-loop.c (inferior_event_handler): Remove client_data param.
544 * inf-loop.h (inferior_event_handler): Likewise.
545 * infcmd.c (step_1): Adjust.
546 * infrun.c (proceed): Adjust.
547 (fetch_inferior_event): Remove client_data param.
548 (infrun_async_inferior_event_handler): Adjust.
549 * infrun.h (fetch_inferior_event): Remove `void *` param.
550 * linux-nat.c (handle_target_event): Adjust.
551 * record-btrace.c (record_btrace_handle_async_inferior_event):
552 Adjust.
553 * record-full.c (record_full_async_inferior_event_handler):
554 Adjust.
555 * remote.c (remote_async_inferior_event_handler): Adjust.
556
557 2020-07-01 Tom Tromey <tom@tromey.com>
558
559 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
560 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
561
562 2020-07-01 Tom Tromey <tom@tromey.com>
563
564 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
565 tui_gen_win_info.
566 (tui_win_info::make_window): Merge with
567 tui_gen_win_info::make_window.
568 (tui_win_info::make_visible): Move from tui_gen_win_info.
569 * tui/tui-win.c (tui_win_info::max_width): Move from
570 tui_gen_win_info.
571 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
572 type.
573 <window_factory>: Likewise.
574 * tui/tui-layout.c (tui_win_info::resize): Move from
575 tui_gen_win_info.
576 (make_standard_window): Change return type.
577 (get_locator_window, tui_get_window_by_name): Likewise.
578 (tui_layout_window::apply): Remove a cast.
579 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
580 (struct tui_win_info): Merge with tui_gen_win_info.
581 (struct tui_gen_win_info): Remove.
582
583 2020-07-01 Tom Tromey <tom@tromey.com>
584
585 * tui/tui-stack.h (struct tui_locator_window): Derive from
586 tui_win_info.
587 <do_scroll_horizontal, do_scroll_vertical>: New methods.
588 <can_box>: New method.
589
590 2020-07-01 Tom Tromey <tom@tromey.com>
591
592 * tui/tui-stack.h (struct tui_locator_window): Remove body.
593
594 2020-07-01 Tom Tromey <tom@tromey.com>
595
596 * tui/tui-regs.c (tui_data_window::display_registers_from)
597 (tui_data_window::display_registers_from)
598 (tui_data_window::first_data_item_displayed)
599 (tui_data_window::delete_data_content_windows): Update.
600 (tui_data_window::refresh_window, tui_data_window::no_refresh):
601 Remove.
602 (tui_data_window::check_register_values): Update.
603 (tui_data_item_window::rerender): Add parameters. Update.
604 (tui_data_item_window::refresh_window): Remove.
605 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
606 virtual.
607 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
608 tui_gen_win_info.
609 <refresh_window, max_height, min_height>: Remove.
610 <rerender>: Add parameters.
611 <x, y, visible>: New members.
612 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
613 <m_item_width>: New member.
614
615 2020-07-01 Tom Tromey <tom@tromey.com>
616
617 * tui/tui-regs.c (tui_data_window::show_register_group)
618 (tui_data_window::check_register_values): Update.
619 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
620 from item_no.
621
622 2020-07-01 Tom Tromey <tom@tromey.com>
623
624 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
625 useless "if".
626
627 2020-07-01 Tom Tromey <tom@tromey.com>
628
629 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
630 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
631
632 2020-07-01 Tom Tromey <tom@tromey.com>
633
634 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
635 * tui/tui-winsource.h (enum tui_line_or_address_kind)
636 (struct tui_line_or_address): Move from tui-data.h.
637 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
638 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
639 (tui_cmd_window, tui_source_window_base, tui_source_window)
640 (tui_disasm_window): Don't declare.
641 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
642 to tui-winsource.h.
643 (SINGLE_KEY): Move to tui-stack.c.
644
645 2020-07-01 Tom Tromey <tom@tromey.com>
646
647 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
648 std::string.
649 * tui/tui-regs.c (class tab_expansion_file): New.
650 (tab_expansion_file::write): New method.
651 (tui_register_format): Change return type. Use
652 tab_expansion_file.
653 (tui_get_register, tui_data_window::display_registers_from)
654 (tui_data_item_window::rerender): Update.
655 * tui/tui-io.h (tui_expand_tabs): Don't declare.
656 * tui/tui-io.c (tui_expand_tabs): Remove.
657
658 2020-07-01 Tom Tromey <tom@tromey.com>
659
660 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
661
662 2020-07-01 Fangrui Song <maskray@google.com>
663
664 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
665
666 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
667
668 * dwarf2/read.c (set_die_type): Removed conditions to restrict
669 forms for DW_AT_associated and DW_AT_allocated attributes,
670 which is already checked in function attr_to_dynamic_prop.
671
672 2020-06-30 Tom Tromey <tromey@adacore.com>
673
674 * dwarf2/read.c (quirk_rust_enum): Correctly call
675 alloc_rust_variant for default-less enum.
676
677 2020-06-30 Tom Tromey <tromey@adacore.com>
678
679 PR build/26183:
680 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
681 gdb::to_string.
682
683 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
684
685 * gdbarch.sh (displaced_step_copy_insn): Update doc.
686 * gdbarch.h: Re-generate.
687
688 2020-06-28 Tom Tromey <tom@tromey.com>
689
690 * command.h (cmd_types): Remove.
691 (cmd_type): Don't declare.
692 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
693 typedef.
694 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
695 * cli/cli-decode.c (cmd_type): Remove.
696
697 2020-06-27 Pedro Alves <palves@redhat.com>
698
699 * fork-child.c (prefork_hook): Adjust.
700 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
701 Delete.
702 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
703 * inferior.c (inferior::set_tty, inferior::tty): New methods.
704 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
705 Remove declarations.
706 (struct inferior) <set_tty, tty>: New methods.
707 (struct inferior) <terminal>: Rename to ...
708 (struct inferior) <m_terminal>: ... this and make private.
709 * main.c (captured_main_1): Adjust.
710 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
711 (mi_cmd_inferior_tty_show): Adjust.
712 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
713 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
714
715 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
716
717 * configure.ac: Add --enable-libctf: handle --disable-static
718 properly.
719 * acinclude.m4: sinclude ../config/enable.m4.
720 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
721 (LIBCTF): Substitute in.
722 (CTF_DEPS): New, likewise.
723 (CLIBS): libctf needs symbols from libbfd: move earlier.
724 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
725 flags.
726 * ctfread.c: Surround in ENABLE_LIBCTF.
727 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
728 * configure: Regenerate.
729 * config.in: Likewise.
730
731 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
732
733 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
734
735 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
736
737 * inferior.h (struct inferior) <terminal>: Change type to
738 gdb::unique_xmalloc_ptr<char>.
739 * inferior.c (inferior::~inferior): Don't free inf->terminal.
740 * infcmd.c (set_inferior_io_terminal): Don't free terminal
741 field, adjust to unique pointer.
742 (get_inferior_io_terminal): Adjust to unique pointer.
743
744 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
745
746 * riscv-tdep.c (riscv_print_registers_info): Loop over all
747 registers, not just the known core set of registers.
748
749 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
750
751 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
752 fflags, frm, and fcsr registers.
753 (riscv_register_reggroup_p): Remove unknown CSRs from save and
754 restore groups.
755 (riscv_tdesc_unknown_reg): New function.
756 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
757 tdesc_use_registers.
758 * riscv-tdep.h (struct gdbarch_tdep): Add
759 unknown_csrs_first_regnum, unknown_csrs_count,
760 duplicate_fflags_regnum, duplicate_frm_regnum, and
761 duplicate_fcsr_regnum fields.
762
763 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
764
765 * target-descriptions.c (tdesc_use_registers): Add new parameter a
766 callback, use the callback (when not null) to help number unknown
767 registers.
768 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
769 (tdesc_use_registers): Add extra parameter to declaration.
770
771 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
772
773 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
774 in the file.
775 (class riscv_pending_register_alias): Likewise.
776 (riscv_register_feature::register_info): Change 'required_p' field
777 to 'required', and change its type. Add 'check' member function.
778 (riscv_register_feature::register_info::check): Define new member
779 function.
780 (riscv_xreg_feature): Change initialisation of 'required' field.
781 (riscv_freg_feature): Likewise.
782 (riscv_virtual_feature): Likewise.
783 (riscv_csr_feature): Likewise.
784 (riscv_check_tdesc_feature): Take extra parameter, the csr
785 tdesc_feature, rewrite the function to use the new
786 riscv_register_feature::register_info::check function.
787 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
788
789 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
790
791 * features/Makefile: Remove all references to the deleted files
792 below.
793 * features/riscv/32bit-csr.c: Deleted.
794 * features/riscv/32bit-csr.xml: Deleted.
795 * features/riscv/64bit-csr.c: Deleted.
796 * features/riscv/64bit-csr.xml: Deleted.
797 * features/riscv/rebuild-csr-xml.sh: Deleted.
798
799 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
800
801 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
802 whitespace error for declaration of names member variable.
803 (struct riscv_register_feature): Add new prefer_first_name member
804 variable, and fix whitespace error in declaration of registers.
805 (riscv_xreg_feature): Initialize prefer_first_name field.
806 (riscv_freg_feature): Likewise.
807 (riscv_virtual_feature): Likewise.
808 (riscv_csr_feature): Likewise.
809 (riscv_register_name): Expand on comments. Remove register name
810 modifications for CSR and virtual registers.
811
812 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
813
814 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
815 errors.
816
817 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
818
819 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
820 riscv-opc.h.
821 (class riscv_pending_register_alias): New class.
822 (riscv_check_tdesc_feature): Take vector of pending aliases and
823 populate it as appropriate.
824 (riscv_setup_register_aliases): Delete.
825 (riscv_gdbarch_init): Create vector of pending aliases and pass it
826 to riscv_check_tdesc_feature in all cases. Use the vector to
827 create the register aliases.
828
829 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
830
831 * sol2-tdep.c (sol2_static_transform_name): Remove.
832 (sol2_init_abi): Don't register it.
833 * gdbarch.sh (static_transform_name): Remove.
834 * gdbarch.c, gdbarch.h: Regenerate.
835
836 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
837 gdbarch_static_transform_name.
838 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
839 * stabsread.c (define_symbol) <'X'>: Remove.
840 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
841 handling.
842 <'V'>: Likewise.
843 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
844 <'S'>: Remove call to gdbarch_static_transform_name.
845
846 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
847
848 * procfs.c (procfs_pre_trace): New function.
849 (procfs_target::create_inferior): Pass it to fork_inferior.
850
851 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
852
853 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
854 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
855 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
856 sol2-tdep.o, sparc-sol2-tdep.o.
857 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
858 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
859 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
860 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
861
862 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
863
864 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
865 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
866 Call sol2_init_abi.
867 Remove calls to set_gdbarch_skip_solib_resolver,
868 set_gdbarch_core_pid_to_str.
869 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
870 (i386_sol2_static_transform_name): Remove.
871 (i386_sol2_init_abi): Call sol2_init_abi.
872 Remove calls to set_gdbarch_sofun_address_maybe_missing,
873 set_gdbarch_static_transform_name,
874 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
875 Use sol2_sigtramp_p.
876 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
877 (sol2_sigtramp_p): New function.
878 (sol2_static_transform_name): New function.
879 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
880 (sol2_init_abi): New function.
881 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
882 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
883 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
884 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
885 (sparc_sol2_static_transform_name): Remove.
886 (sparc32_sol2_init_abi): Call sol2_init_abi.
887 Remove calls to set_gdbarch_sofun_address_maybe_missing,
888 set_gdbarch_static_transform_name,
889 set_gdbarch_skip_solib_resolver,
890 set_gdbarch_core_pid_to_str.
891 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
892 (sparc_sol2_static_transform_name): Remove
893 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
894 call sol2_sigtramp_p.
895 (sparc64_sol2_init_abi): Call sol2_init_abi.
896 Remove calls to set_gdbarch_sofun_address_maybe_missing,
897 set_gdbarch_static_transform_name,
898 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
899
900 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
901
902 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
903 * exec.c (validate_exec_file): If from_tty, set both
904 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
905 * symfile.c (symbol_file_add_with_addrs): if always_confirm
906 and from_tty, unconditionally ask a confirmation.
907
908 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
909
910 * target-descriptions.c (tdesc_architecture_name): Protect against
911 NULL pointer dereference.
912 (maint_print_xml_tdesc_cmd): New function.
913 (_initialize_target_descriptions): Register new 'maint print
914 xml-tdesc' command and give it the filename completer.
915 * NEWS: Mention new 'maint print xml-tdesc' command.
916
917 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
918
919 * target-descriptions.c (class tdesc_compatible_info): New class.
920 (struct target_desc): Change type of compatible vector.
921 (tdesc_compatible_p): Update for change in type of
922 target_desc::compatible.
923 (tdesc_compatible_info_list): New function.
924 (tdesc_compatible_info_arch_name): New function.
925 (tdesc_add_compatible): Update for change in type of
926 target_desc::compatible.
927 (print_c_tdesc::visit_pre): Likewise.
928
929 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
930
931 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
932 whitespace to underscore.
933 (maint_print_c_tdesc_cmd): Use fake filename for target
934 descriptions that came from the target.
935 (_initialize_target_descriptions): Add filename command completion
936 for 'maint print c-tdesc'.
937
938 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
939
940 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
941 lines.
942
943 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
944
945 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
946 lines.
947 (dwarf2_find_location_expression): Likewise.
948 (call_site_parameter_matches): Likewise.
949 (dwarf2_compile_expr_to_ax): Likewise.
950 (disassemble_dwarf_expression): Likewise.
951 (loclist_describe_location): Likewise.
952
953 2020-06-23 Pedro Alves <palves@redhat.com>
954
955 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
956 progspace-and-thread.h. Include scoped-mock-context.h instead.
957 (register_to_value_test): Use scoped_mock_context.
958 * regcache.c: Include "scoped-mock-context.h".
959 (cooked_read_test): Don't error out if a target is already pushed.
960 Use scoped_mock_context. Adjust.
961 * scoped-mock-context.h: New file.
962
963 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
964
965 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
966 initializer.
967 (ada_language::is_string_type_p): New member function.
968 * c-lang.c (c_language_data): Delete la_is_string_type_p
969 initializer.
970 (cplus_language_data): Likewise.
971 (asm_language_data): Likewise.
972 (minimal_language_data): Likewise.
973 * d-lang.c (d_language_data): Likewise.
974 * f-lang.c (f_is_string_type_p): Delete function, implementation
975 moved to f_language::is_string_type_p.
976 (f_language_data): Delete la_is_string_type_p initializer.
977 (f_language::is_string_type_p): New member function,
978 implementation from f_is_string_type_p.
979 * go-lang.c (go_is_string_type_p): Delete function, implementation
980 moved to go_language::is_string_type_p.
981 (go_language_data): Delete la_is_string_type_p initializer.
982 (go_language::is_string_type_p): New member function,
983 implementation from go_is_string_type_p.
984 * language.c (language_defn::is_string_type_p): Define new member
985 function.
986 (default_is_string_type_p): Make static, add comment copied from
987 header file.
988 (unknown_language_data): Delete la_is_string_type_p initializer.
989 (unknown_language::is_string_type_p): New member function.
990 (auto_language_data): Delete la_is_string_type_p initializer.
991 (auto_language::is_string_type_p): New member function.
992 * language.h (language_data): Delete la_is_string_type_p field.
993 (language_defn::is_string_type_p): Declare new function.
994 (default_is_string_type_p): Delete desclaration, move comment to
995 definition.
996 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
997 moved to m2_language::is_string_type_p.
998 (m2_language_data): Delete la_is_string_type_p initializer.
999 (m2_language::is_string_type_p): New member function,
1000 implementation from m2_is_string_type_p.
1001 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
1002 initializer.
1003 * opencl-lang.c (opencl_language_data): Likewise.
1004 * p-lang.c (pascal_is_string_type_p): Delete function,
1005 implementation moved to pascal_language::is_string_type_p.
1006 (pascal_language_data): Delete la_is_string_type_p initializer.
1007 (pascal_language::is_string_type_p): New member function,
1008 implementation from pascal_is_string_type_p.
1009 * rust-lang.c (rust_is_string_type_p): Delete function,
1010 implementation moved to rust_language::is_string_type_p.
1011 (rust_language_data): Delete la_is_string_type_p initializer.
1012 (rust_language::is_string_type_p): New member function,
1013 implementation from rust_is_string_type_p.
1014 * valprint.c (val_print_scalar_or_string_type_p): Update call to
1015 is_string_type_p.
1016
1017 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1018
1019 * ada-lang.c (ada_language_data): Delete la_print_typedef
1020 initializer.
1021 (ada_language::print_typedef): New member function.
1022 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
1023 (cplus_language_data): Likewise.
1024 (asm_language_data): Likewise.
1025 (minimal_language_data): Likewise.
1026 * d-lang.c (d_language_data): Likewise.
1027 * f-lang.c (f_language_data): Likewise.
1028 (f_language::print_typedef): New member function.
1029 * go-lang.c (go_language_data): Delete la_print_typedef
1030 initializer.
1031 * language.c (language_defn::print_typedef): Define member
1032 function.
1033 (unknown_language_data): Delete la_print_typedef initializer.
1034 (unknown_language::print_typedef): New member function.
1035 (auto_language_data): Delete la_print_typedef initializer.
1036 (auto_language::print_typedef): New member function.
1037 * language.h (language_data): Delete la_print_typedef field.
1038 (language_defn::print_typedef): Declare new member function.
1039 (LA_PRINT_TYPEDEF): Update call to print_typedef.
1040 (default_print_typedef): Delete declaration.
1041 * m2-lang.c (m2_language_data): Delete la_print_typedef
1042 initializer.
1043 (m2_language::print_typedef): New member function.
1044 * objc-lang.c (objc_language_data): Delete la_print_typedef
1045 initializer.
1046 * opencl-lang.c (opencl_language_data): Likewise.
1047 * p-lang.c (pascal_language_data): Likewise.
1048 (pascal_language::print_typedef): New member function.
1049 * rust-lang.c (rust_print_typedef): Delete function,
1050 implementation moved to rust_language::print_typedef.
1051 (rust_language): Delete la_print_typedef initializer.
1052 (rust_language::print_typedef): New member function,
1053 implementation from rust_print_typedef.
1054 * typeprint.c (default_print_typedef): Delete.
1055
1056 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1057
1058 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
1059 (ada_language::printstr): New member function.
1060 * c-lang.c (c_language_data): Delete la_printstr initializer.
1061 (cplus_language_data): Likewise.
1062 (asm_language_data): Likewise.
1063 (minimal_language_data): Likewise.
1064 * d-lang.c (d_language_data): Likewise.
1065 * f-lang.c (f_printstr): Rename to f_language::printstr.
1066 (f_language_data): Delete la_printstr initializer.
1067 (f_language::printstr): New member function, implementation from
1068 f_printstr.
1069 * go-lang.c (go_language_data): Delete la_printstr initializer.
1070 * language.c (language_defn::printstr): Define new member
1071 function.
1072 (unk_lang_printstr): Delete.
1073 (unknown_language_data): Delete la_printstr initializer.
1074 (unknown_language::printstr): New member function.
1075 (auto_language_data): Delete la_printstr initializer.
1076 (auto_language::printstr): New member function.
1077 * language.h (language_data): Delete la_printstr field.
1078 (language_defn::printstr): Declare new member function.
1079 (LA_PRINT_STRING): Update call to printstr.
1080 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
1081 (m2_language_data): Delete la_printstr initializer.
1082 (m2_language::printstr): New member function, implementation from
1083 m2_printstr.
1084 * objc-lang.c (objc_language_data): Delete la_printstr
1085 initializer.
1086 * opencl-lang.c (opencl_language_data): Likewise.
1087 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
1088 (pascal_language_data): Delete la_printstr initializer.
1089 (pascal_language::printstr): New member function, implementation
1090 from pascal_printstr.
1091 * p-lang.h (pascal_printstr): Delete declaration.
1092 * rust-lang.c (rust_printstr): Update header comment.
1093 (rust_language_data): Delete la_printstr initializer.
1094 (rust_language::printstr): New member function.
1095
1096 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1097
1098 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
1099 (ada_language::printchar): New member function.
1100 * c-lang.c (c_language_data): Delete la_printchar initializer.
1101 (cplus_language_data): Likewise.
1102 (asm_language_data): Likewise.
1103 (minimal_language_data): Likewise.
1104 * d-lang.c (d_language_data): Likewise.
1105 * f-lang.c (f_printchar): Rename to f_language::printchar.
1106 (f_language_data): Delete la_printchar initializer.
1107 (f_language::printchar): New member function, implementation from
1108 f_printchar.
1109 * go-lang.c (go_language_data): Delete la_printchar initializer.
1110 * language.c (unk_lang_printchar): Delete.
1111 (language_defn::printchar): Define new member function.
1112 (unknown_language_data): Delete la_printchar initializer.
1113 (unknown_language::printchar): New member function.
1114 (auto_language_data): Delete la_printchar initializer.
1115 (auto_language::printchar): New member function.
1116 * language.h (language_data): Delete la_printchar field.
1117 (language_defn::printchar): Declare new member function.
1118 (LA_PRINT_CHAR): Update call to printchar.
1119 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
1120 (m2_language::printchar): New member function.
1121 * objc-lang.c (objc_language_data): Delete la_printchar
1122 initializer.
1123 * opencl-lang.c (opencl_language_data): Likewise.
1124 * p-lang.c (pascal_language_data): Delete la_printchar
1125 initializer.
1126 (pascal_language::printchar): New member function.
1127 * rust-lang.c (rust_printchar): Rename to
1128 rust_language::printchar.
1129 (rust_language_data): Delete la_printchar initializer.
1130 (rust_language::printchar): New member function, implementation
1131 from rust_printchar.
1132
1133 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1134
1135 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
1136 (ada_language_data): Delete la_emitchar initializer.
1137 (ada_language::emitchar): New member function, implementation from
1138 emit_char.
1139 * c-lang.c (c_language_data): Delete la_emitchar initializer.
1140 (cplus_language_data): Likewise.
1141 (asm_language_data): Likewise.
1142 (minimal_language_data): Likewise.
1143 * d-lang.c (d_language_data): Likewise.
1144 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
1145 (f_language_data): Delete la_emitchar initializer.
1146 (f_language::emitchar): New member function, implementation from
1147 f_emit_char.
1148 * go-lang.c (go_language_data): Delete la_emitchar initializer.
1149 * language.c (unk_lang_emit_char): Delete.
1150 (language_defn::emitchar): New member function definition.
1151 (unknown_language_data): Delete la_emitchar initializer.
1152 (unknown_language::emitchar): New member function.
1153 (auto_language_data): Delete la_emitchar initializer.
1154 (auto_language::emitchar): New member function.
1155 * language.h (language_data): Delete la_emitchar field.
1156 (language_defn::emitchar): New member field declaration.
1157 (LA_EMIT_CHAR): Update call to emitchar.
1158 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
1159 (m2_language_data): Delete la_emitchar initializer.
1160 (m2_language::emitchar): New member function, implementation from
1161 m2_emit_char.
1162 * objc-lang.c (objc_language_data): Delete la_emitchar
1163 initializer.
1164 * opencl-lang.c (opencl_language_data): Likewise.
1165 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
1166 (pascal_language_data): Delete la_emitchar initializer.
1167 (pascal_language::emitchar): New member function, implementation
1168 from pascal_emit_char.
1169 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
1170 (rust_language_data): Delete la_emitchar initializer.
1171 (rust_language::emitchar): New member function, implementation
1172 from rust_emitchar.
1173
1174 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1175
1176 * ada-lang.c (resolve): Rename to ada_language::post_parser.
1177 (ada_language_data): Delete la_post_parser initializer.
1178 (ada_language::post_parser): New member function.
1179 * c-lang.c (c_language_data): Delete la_post_parser initializer.
1180 (cplus_language_data): Likewise.
1181 (asm_language_data): Likewise.
1182 (minimal_language_data): Likewise.
1183 * d-lang.c (d_language_data): Likewise.
1184 * f-lang.c (f_language_data): Likewise.
1185 * go-lang.c (go_language_data): Likewise.
1186 * language.c (unknown_language_data): Likewise.
1187 (auto_language_data): Likewise.
1188 * language.h (language_data): Delete la_post_parser field.
1189 (language_defn::post_parser): New member function.
1190 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
1191 * objc-lang.c (objc_language_data): Likewise.
1192 * opencl-lang.c (opencl_language_data): Likewise.
1193 * p-lang.c (pascal_language_data): Likewise.
1194 * parse.c (parse_exp_in_context): Update call to post_parser.
1195 (null_post_parser): Delete definition.
1196 * parser-defs.h (null_post_parser): Delete declaration.
1197 * rust-lang.c (rust_language_data): Delete la_post_parser
1198 initializer.
1199
1200 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1201
1202 * ada-lang.c (parse): Rename to ada_language::parser.
1203 (ada_language_data): Delete la_parser initializer.
1204 (ada_language::parser): New member function, implementation from
1205 parse.
1206 * c-lang.c (c_language_data): Delete la_parser initializer.
1207 (cplus_language_data): Likewise.
1208 (asm_language_data): Likewise.
1209 (minimal_language_data): Likewise.
1210 * d-lang.c (d_language_data): Likewise.
1211 (d_language::parser): New member function.
1212 * f-lang.c (f_language_data): Delete la_parser initializer.
1213 (f_language::parser): New member function.
1214 * go-lang.c (go_language_data): Delete la_parser initializer.
1215 (go_language::parser): New member function.
1216 * language.c (unk_lang_parser): Delete.
1217 (language_defn::parser): Define new member function.
1218 (unknown_language_data): Delete la_parser initializer.
1219 (unknown_language::parser): New member function.
1220 (auto_language_data): Delete la_parser initializer.
1221 (auto_language::parser): New member function.
1222 * language.h (language_data): Delete la_parser field.
1223 (language_defn::parser): Declare new member function.
1224 * m2-lang.c (m2_language_data): Delete la_parser initializer.
1225 (m2_language::parser): New member function.
1226 * objc-lang.c (objc_language_data): Delete la_parser initializer.
1227 * opencl-lang.c (opencl_language_data): Likewise.
1228 * p-lang.c (pascal_language_data): Likewise.
1229 (pascal_language::parser): New member function.
1230 * parse.c (parse_exp_in_context): Update call to parser.
1231 * rust-lang.c (rust_language_data): Delete la_parser initializer.
1232 (rust_language::parser): New member function.
1233
1234 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1235
1236 * top.c (print_gdb_configuration): Print --with-python-libdir
1237 configuration value.
1238
1239 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1240
1241 * NEWS: Mention change to the alias command.
1242
1243 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1244
1245 * cli/cli-cmds.c (lookup_cmd_for_default_args)
1246 (alias_command_completer)
1247 (make_alias_options_def_group): New functions.
1248 (alias_opts, alias_option_defs): New struct and array.
1249 (alias_usage_error): Update usage.
1250 (alias_command): Handles optional DEFAULT-ARGS... arguments.
1251 Use option framework.
1252 (_initialize_cli_cmds): Update alias command help.
1253 Update aliases command help.
1254 (show_user):
1255 Add NULL for new default_args lookup_cmd argument.
1256 (valid_command_p): Rename to validate_aliased_command.
1257 Add NULL for new default_args lookup_cmd argument. Verify that the
1258 aliased_command has no default args.
1259 * cli/cli-decode.c (help_cmd): Show aliases definitions.
1260 (lookup_cmd_1, lookup_cmd): New argument default_args.
1261 (add_alias_cmd):
1262 Add NULL for new default_args lookup_cmd argument.
1263 (print_help_for_command): Show default args under the layout
1264 alias some_alias = some_aliased_cmd some_alias_default_arg.
1265 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
1266 xfree default_args in destructor.
1267 * cli/cli-script.c (process_next_line, do_define_command):
1268 Add NULL for new default_args lookup_cmd argument.
1269 * command.h: Declare new default_args argument in lookup_cmd
1270 and lookup_cmd_1.
1271 * completer.c (complete_line_internal_1):
1272 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1273 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
1274 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
1275 Likewise.
1276 * infcmd.c (_initialize_infcmd): Likewise.
1277 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
1278 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
1279 * python/py-param.c (add_setshow_generic): Likewise.
1280 * remote.c (_initialize_remote): Likewise.
1281 * top.c (execute_command): Prepend default_args if command has some.
1282 (set_verbose):
1283 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1284 * tracepoint.c (validate_actionline, encode_actions_1):
1285 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1286
1287 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1288
1289 * jit.c (jit_read_descriptor): Use bool as the return type.
1290 (jit_breakpoint_re_set_internal): Use bool as the return type.
1291 Invert the return value logic; return true if the jit breakpoint
1292 has been successfully initialized.
1293 (jit_inferior_init): Update the call to
1294 jit_breakpoint_re_set_internal.
1295
1296 2020-06-22 Pedro Alves <palves@redhat.com>
1297
1298 PR gdb/25939
1299 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
1300 Use the current inferior instead. Don't return
1301 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
1302 wait again.
1303 * sol-thread.c (sol_thread_target::wait): Don't reference
1304 inferior_ptid.
1305 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
1306 (sol_update_thread_list_callback): Use the current inferior's pid
1307 instead of inferior_ptid.
1308
1309 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1310
1311 * procfs.c: Cleanup many comments.
1312
1313 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
1314 (AFTER_WATCHFLAG): Replace by value.
1315
1316 (MAIN_PROC_NAME_FORMAT): Inline ...
1317 (create_procinfo): ... here.
1318
1319 (procfs_debug_inferior): Remove SYS_exec handling.
1320 (syscall_is_exec): Likewise.
1321 (procfs_set_exec_trap): Likewise.
1322
1323 (syscall_is_lwp_exit): Inline in callers.
1324 (syscall_is_exit): Likewise.
1325 (syscall_is_exec): Likewise.
1326 (syscall_is_lwp_create): Likewise.
1327
1328 (invalidate_cache): Remove #if 0 code.
1329
1330 (make_signal_thread_runnable): Remove.
1331 (procfs_target::resume): Remove #if 0 code.
1332
1333 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1334
1335 PR gdb/25939
1336 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
1337 call ...
1338 (procfs_target::create_inferior): ... here.
1339
1340 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1341
1342 * exec.c (validate_exec_file): Ensure the build-id is up to
1343 date by calling reopen_exec_file (that checks file timestamp
1344 to decide to re-read the file).
1345
1346 2020-06-18 Pedro Alves <palves@redhat.com>
1347
1348 PR gdb/25412
1349 * gdbthread.h (delete_thread, delete_thread_silent)
1350 (find_thread_ptid): Update comments.
1351 * thread.c (current_thread_): New global.
1352 (is_current_thread): Move higher, and reimplement.
1353 (inferior_thread): Reimplement.
1354 (set_thread_exited): Use bool. Add assertions.
1355 (add_thread_silent): Simplify thread-reuse handling by always
1356 calling delete_thread.
1357 (delete_thread): Remove intro comment.
1358 (find_thread_ptid): Skip exited threads.
1359 (switch_to_thread_no_regs): Write to current_thread_.
1360 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
1361 INFERIOR_PTID. Clear current_thread_.
1362
1363 2020-06-18 Pedro Alves <palves@redhat.com>
1364
1365 * aix-thread.c (pd_update): Use switch_to_thread.
1366
1367 2020-06-18 Pedro Alves <palves@redhat.com>
1368
1369 * ravenscar-thread.c (ravenscar_thread_target): Update.
1370 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
1371 (ravenscar_thread_target::add_active_thread): ... this. Don't
1372 set m_base_ptid here. Update to avoid referencing inferior_ptid.
1373 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
1374
1375 2020-06-18 Pedro Alves <palves@redhat.com>
1376
1377 * nat/windows-nat.c (current_windows_thread): Remove.
1378 * nat/windows-nat.h (current_windows_thread): Remove.
1379 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
1380 Adjust.
1381 (display_selectors): Adjust to fetch the current
1382 windows_thread_info based on inferior_ptid.
1383 (fake_create_process): No longer write to current_windows_thread.
1384 (windows_nat_target::get_windows_debug_event):
1385 Don't set inferior_ptid or current_windows_thread.
1386 (windows_nat_target::wait): Adjust to not rely on
1387 current_windows_thread.
1388 (do_initial_windows_stuff): Now a method of windows_nat_target.
1389 Switch to the last_ptid thread.
1390 (windows_nat_target::attach): Adjust.
1391 (windows_nat_target::detach): Use switch_to_no_thread instead of
1392 writing to inferior_ptid directly.
1393 (windows_nat_target::create_inferior): Adjust.
1394
1395 2020-06-18 Pedro Alves <palves@redhat.com>
1396
1397 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
1398
1399 2020-06-18 Pedro Alves <palves@redhat.com>
1400
1401 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
1402 after creating it, instead of writing to inferior_ptid. Don't
1403 write to inferior_ptid.
1404
1405 2020-06-18 Pedro Alves <palves@redhat.com>
1406
1407 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
1408
1409 2020-06-18 Pedro Alves <palves@redhat.com>
1410
1411 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
1412 it, instead of writing to inferior_ptid.
1413
1414 2020-06-18 Pedro Alves <palves@redhat.com>
1415
1416 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
1417 to inferior_ptid.
1418
1419 2020-06-18 Pedro Alves <palves@redhat.com>
1420
1421 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
1422 instead of writing to inferior_ptid directly.
1423
1424 2020-06-18 Pedro Alves <palves@redhat.com>
1425
1426 * corelow.c (core_target::close): Use switch_to_no_thread instead
1427 of writing to inferior_ptid directly.
1428 (add_to_thread_list, core_target_open): Use switch_to_thread
1429 instead of writing to inferior_ptid directly.
1430
1431 2020-06-18 Pedro Alves <palves@redhat.com>
1432
1433 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
1434 inferior_ptid.
1435 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
1436 inferior_ptid.
1437 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
1438 inferior_ptid directly.
1439 (darwin_nat_target::init_thread_list): Switch to thread, instead
1440 of writing to inferior_ptid.
1441 (darwin_nat_target::attach): Don't write to inferior_ptid.
1442 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
1443
1444 2020-06-18 Pedro Alves <palves@redhat.com>
1445
1446 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
1447 thread.
1448 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
1449 Instead use switch_to_thread.
1450 (gnu_nat_target::detach): Use switch_to_no_thread
1451 instead of writing to inferior_ptid directly. Used passed-in
1452 inferior instead of looking up the inferior by pid.
1453
1454 2020-06-18 Pedro Alves <palves@redhat.com>
1455
1456 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
1457 inferior_ptid.
1458
1459 2020-06-18 Pedro Alves <palves@redhat.com>
1460
1461 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
1462 inferior_ptid.
1463 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
1464 thread.
1465 (nto_procfs_target::detach): Avoid referencing
1466 inferior_ptid. Use switch_to_no_thread instead of writing to
1467 inferior_ptid directly.
1468 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
1469 instead of writing to inferior_ptid directly.
1470 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
1471 to thread.
1472
1473 2020-06-18 Pedro Alves <palves@redhat.com>
1474
1475 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
1476 after creating it, instead of writing to inferior_ptid.
1477 (gdbsim_target_open): Use switch_to_no_thread instead of writing
1478 to inferior_ptid directly.
1479 (gdbsim_target::wait): Don't write to inferior_ptid.
1480
1481 2020-06-18 Pedro Alves <palves@redhat.com>
1482
1483 * remote.c (remote_target::remote_notice_new_inferior): Use
1484 switch_to_thread instead of writing to inferior_ptid directly.
1485 (remote_target::add_current_inferior_and_thread): Use
1486 switch_to_no_thread instead of writing to inferior_ptid directly.
1487 (extended_remote_target::attach): Use switch_to_inferior_no_thread
1488 and switch_to_thread instead of using set_current_inferior or
1489 writing to inferior_ptid directly.
1490
1491 2020-06-18 Pedro Alves <palves@redhat.com>
1492
1493 * tracectf.c (ctf_target_open): Switch to added thread instead of
1494 writing to inferior_ptid directly.
1495 (ctf_target::close): Use switch_to_no_thread instead of writing to
1496 inferior_ptid directly.
1497
1498 2020-06-18 Pedro Alves <palves@redhat.com>
1499
1500 * tracefile-tfile.c (tfile_target_open): Don't write to
1501 inferior_ptid directly, instead switch to added thread.
1502 (tfile_target::close): Use switch_to_no_thread instead of writing
1503 to inferior_ptid directly.
1504
1505 2020-06-18 Pedro Alves <palves@redhat.com>
1506
1507 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
1508 (procfs_target::detach): Use switch_to_no_thread
1509 instead of writing to inferior_ptid directly.
1510 (do_attach): Change return type to void. Switch to the added
1511 thread.
1512 (procfs_target::create_inferior): Switch to the added thread.
1513 (procfs_do_thread_registers): Don't write to inferior_ptid.
1514
1515 2020-06-18 Pedro Alves <palves@redhat.com>
1516
1517 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
1518 of writing to inferior_ptid.
1519 (scoped_restore_exited_inferior): Delete.
1520 (handle_vfork_child_exec_or_exit): Simplify using
1521 scoped_restore_current_pspace_and_thread. Use switch_to_thread
1522 instead of writing to inferior_ptid.
1523 (THREAD_STOPPED_BY): Delete.
1524 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
1525 (thread_stopped_by_hw_breakpoint): Delete.
1526 (save_waitstatus): Use
1527 scoped_restore_current_thread+switch_to_thread, and call
1528 target_stopped_by_watchpoint instead of
1529 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
1530 instead of thread_stopped_by_sw_breakpoint, and
1531 target_stopped_by_hw_breakpoint instead of
1532 thread_stopped_by_hw_breakpoint.
1533 (handle_inferior_event)
1534 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
1535 inferior_ptid directly, nor
1536 set_current_inferior/set_current_program_space. Use
1537 switch_to_thread / switch_to_inferior_no_thread instead.
1538
1539 2020-06-18 Pedro Alves <palves@redhat.com>
1540
1541 * target.c (generic_mourn_inferior): Use switch_to_no_thread
1542 instead of writing to inferior_ptid.
1543
1544 2020-06-18 Pedro Alves <palves@redhat.com>
1545
1546 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
1547 added thread.
1548 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
1549 to the added thread.
1550 (inf_ptrace_target::detach_success): Use switch_to_no_thread
1551 instead of writing to inferior_ptid.
1552
1553 2020-06-18 Pedro Alves <palves@redhat.com>
1554
1555 * gdbarch-selftests.c: Include "progspace-and-thread.h".
1556 (register_to_value_test): Mock a program_space too. Heap-allocate
1557 the address space. Don't write to inferior_ptid. Use
1558 switch_to_thread instead.
1559
1560 2020-06-18 Pedro Alves <palves@redhat.com>
1561
1562 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
1563 Delete.
1564 (find_signalled_thread()): New, factored out from
1565 linux_make_corefile_notes and adjusted to handle exited threads.
1566 (linux_make_corefile_notes): Adjust to use the new
1567 find_signalled_thread.
1568
1569 2020-06-18 Pedro Alves <palves@redhat.com>
1570
1571 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
1572 of saving/restoring inferior_ptid.
1573
1574 2020-06-17 Tom Tromey <tom@tromey.com>
1575
1576 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
1577 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
1578 declare.
1579 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
1580
1581 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
1582
1583 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
1584 of partial symtabs.
1585
1586 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1587
1588 * regformats/reg-arm.dat: Remove.
1589 * regformats/reg-bfin.dat: Remove.
1590 * regformats/reg-cris.dat: Remove.
1591 * regformats/reg-crisv32.dat: Remove.
1592 * regformats/reg-m32r.dat: Remove.
1593 * regformats/reg-tilegx.dat: Remove.
1594 * regformats/reg-tilegx32.dat: Remove.
1595
1596 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1597
1598 * features/Makefile (WHICH): Remove arm files.
1599 * regformats/arm/arm-with-iwmmxt.dat: Remove.
1600 * regformats/arm/arm-with-neon.dat: Remove.
1601 * regformats/arm/arm-with-vfpv2.dat: Remove.
1602 * regformats/arm/arm-with-vfpv3.dat: Remove.
1603
1604 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1605
1606 * features/Makefile (XMLTOC): Remove rx.xml.
1607
1608 2020-06-17 Pedro Alves <palves@redhat.com>
1609
1610 * gdbthread.h (thread_control_state) <trap_expected> Update
1611 comments.
1612
1613 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1614
1615 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
1616 ada_language::lookup_symbol_nonlocal.
1617 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
1618 (ada_language::lookup_symbol_nonlocal): New member function,
1619 implementation from ada_lookup_symbol_nonlocal.
1620 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
1621 initializer.
1622 (cplus_language_data): Delete la_lookup_symbol_nonlocal
1623 initializer.
1624 (cplus_language::lookup_symbol_nonlocal): New member function.
1625 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
1626 (minimal_language_data) Likewise.
1627 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
1628 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
1629 initializer.
1630 (d_language::lookup_symbol_nonlocal): New member function.
1631 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
1632 initializer.
1633 (f_language::lookup_symbol_nonlocal): New member function.
1634 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
1635 initializer.
1636 * language.c (unknown_language_data): Likewise.
1637 (auto_language_data): Likewise.
1638 * language.h (language_data): Delete la_lookup_symbol_nonlocal
1639 field.
1640 (language_defn::lookup_symbol_nonlocal): New member function.
1641 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
1642 initializer.
1643 * objc-lang.c (objc_language_data): Likewise.
1644 * opencl-lang.c (opencl_language_data): Likewise.
1645 * p-lang.c (pascal_language_data): Likewise.
1646 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
1647 rust_language::lookup_symbol_nonlocal.
1648 (rust_language_data): Delete la_lookup_symbol_nonlocal
1649 initializer.
1650 (rust_language::lookup_symbol_nonlocal): New member function,
1651 implementation from rust_lookup_symbol_nonlocal.
1652 * symtab.c (lookup_symbol_aux): Update call to
1653 lookup_symbol_nonlocal.
1654 (basic_lookup_symbol_nonlocal): Rename to...
1655 (language_defn::lookup_symbol_nonlocal): ...this, and update
1656 header comment. Remove language_defn parameter, and replace with
1657 uses of `this'.
1658 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
1659
1660 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1661
1662 * ada-lang.c (ada_language_data): Delete la_value_print_inner
1663 initializer.
1664 (ada_language::value_print_inner): New member function.
1665 * c-lang.c (c_language_data): Delete la_value_print_inner
1666 initializer.
1667 (cplus_language_data): Likewise.
1668 (asm_language_data): Likewise.
1669 (minimal_language_data): Likewise.
1670 * d-lang.c (d_language_data): Likewise.
1671 (d_language::value_print_inner): New member function.
1672 * f-lang.c (f_language_data): Delete la_value_print_inner
1673 initializer.
1674 (f_language::value_print_inner): New member function.
1675 * f-lang.h (f_value_print_innner): Rename to...
1676 (f_value_print_inner): ...this (note spelling of 'inner').
1677 * f-valprint.c (f_value_print_innner): Rename to...
1678 (f_value_print_inner): ...this (note spelling of 'inner').
1679 * go-lang.c (go_language_data): Delete la_value_print_inner
1680 initializer.
1681 (go_language::value_print_inner): New member function.
1682 * language.c (language_defn::value_print_inner): Define new member
1683 function.
1684 (unk_lang_value_print_inner): Delete.
1685 (unknown_language_data): Delete la_value_print_inner initializer.
1686 (unknown_language::value_print_inner): New member function.
1687 (auto_language_data): Delete la_value_print_inner initializer.
1688 (auto_language::value_print_inner): New member function.
1689 * language.h (language_data): Delete la_value_print_inner field.
1690 (language_defn::value_print_inner): Delcare new member function.
1691 * m2-lang.c (m2_language_data): Delete la_value_print_inner
1692 initializer.
1693 (m2_language::value_print_inner): New member function.
1694 * objc-lang.c (objc_language_data): Delete la_value_print_inner
1695 initializer.
1696 * opencl-lang.c (opencl_language_data): Likewise.
1697 * p-lang.c (pascal_language_data): Likewise.
1698 (pascal_language::value_print_inner): New member function.
1699 * rust-lang.c (rust_language_data): Delete la_value_print_inner
1700 initializer.
1701 (rust_language::value_print_inner): New member function.
1702 * valprint.c (do_val_print): Update call to value_print_inner.
1703
1704 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1705
1706 * ada-lang.c (ada_language_data): Delete la_value_print
1707 initializer.
1708 (ada_language::value_print): New member function.
1709 * c-lang.c (c_language_data): Delete la_value_print initializer.
1710 (cplus_language_data): Likewise.
1711 (asm_language_data): Likewise.
1712 (minimal_language_data): Likewise.
1713 * d-lang.c (d_language_data): Likewise.
1714 * f-lang.c (f_language_data): Likewise.
1715 * go-lang.c (go_language_data): Likewise.
1716 * language.c (unk_lang_value_print): Delete.
1717 (language_defn::value_print): Define new member function.
1718 (unknown_language_data): Delete la_value_print initializer.
1719 (unknown_language::value_print): New member function.
1720 (auto_language_data): Delete la_value_print initializer.
1721 (auto_language::value_print): New member function.
1722 * language.h (language_data): Delete la_value_print field.
1723 (language_defn::value_print): Declare new member function.
1724 (LA_VALUE_PRINT): Update call to value_print.
1725 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
1726 * objc-lang.c (objc_language_data): Likewise.
1727 * opencl-lang.c (opencl_language_data): Likewise.
1728 * p-lang.c (pascal_language_data): Likewise.
1729 (pascal_language::value_print): New member function.
1730 * rust-lang.c (rust_language_data): Delete la_value_print
1731 initializer.
1732
1733 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1734
1735 * ada-lang.c (ada_watch_location_expression): Rename to
1736 ada_language::watch_location_expression.
1737 (ada_language_data): Delete la_watch_location_expression
1738 initializer.
1739 (ada_language::watch_location_expression): New member function,
1740 implementation from ada_watch_location_expression.
1741 * breakpoint.c (watch_command_1): Update call to
1742 watch_location_expression.
1743 * c-lang.c (c_watch_location_expression): Rename to
1744 language_defn::watch_location_expression.
1745 (c_language_data): Delete la_watch_location_expression
1746 initializer.
1747 (cplus_language_data): Likewise.
1748 (asm_language_data): Likewise.
1749 (minimal_language_data): Likewise.
1750 * c-lang.h (c_watch_location_expression): Delete declaration.
1751 * d-lang.c (d_language_data): Delete la_watch_location_expression
1752 initializer.
1753 * f-lang.c (f_language_data): Likewise.
1754 * go-lang.c (go_language_data): Likewise.
1755 * language.c (language_defn::watch_location_expression): Member
1756 function implementation from c_watch_location_expression.
1757 (unknown_language_data): Delete la_watch_location_expression
1758 initializer.
1759 (auto_language_data): Likewise.
1760 * language.h (language_data): Delete la_watch_location_expression
1761 field.
1762 (language_defn::watch_location_expression): Declare new member
1763 function.
1764 * m2-lang.c (m2_language_data): Delete
1765 la_watch_location_expression initializer.
1766 * objc-lang.c (objc_language_data): Likewise.
1767 * opencl-lang.c (opencl_language_data): Likewise.
1768 * p-lang.c (pascal_language_data): Likewise.
1769 * rust-lang.c (rust_watch_location_expression): Rename to
1770 rust_language::watch_location_expression.
1771 (rust_language_data): Delete la_watch_location_expression
1772 initializer.
1773 (rust_language::watch_location_expression): New member function,
1774 implementation from rust_watch_location_expression.
1775
1776 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1777
1778 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
1779 ada_language::collect_symbol_completion_matches.
1780 (ada_language_data): Delete la_collect_symbol_completion_matches
1781 initializer.
1782 (ada_language::collect_symbol_completion_matches): New member
1783 function, implementation from
1784 ada_collect_symbol_completion_matches.
1785 * c-lang.c (c_language_data): Delete
1786 la_collect_symbol_completion_matches initializer.
1787 (cplus_language_data): Likewise.
1788 (asm_language_data): Likewise.
1789 (minimal_language_data): Likewise.
1790 * d-lang.c (d_language_data): Likewise.
1791 * f-lang.c (f_collect_symbol_completion_matches): Rename to
1792 f_language::collect_symbol_completion_matches.
1793 (f_language_data): Delete la_collect_symbol_completion_matches
1794 initializer.
1795 (f_language::collect_symbol_completion_matches) New member
1796 function, implementation from f_collect_symbol_completion_matches.
1797 * go-lang.c (go_language_data): Delete
1798 la_collect_symbol_completion_matches initializer.
1799 * language.c (unknown_language_data): Likewise.
1800 (auto_language_data): Likewise.
1801 * language.h (language_data): Delete
1802 la_collect_symbol_completion_matches field.
1803 (language_defn::collect_symbol_completion_matches): New member
1804 function.
1805 * m2-lang.c (m2_language_data): Delete
1806 la_collect_symbol_completion_matches initializer.
1807 * objc-lang.c (objc_language_data): Likewise.
1808 * opencl-lang.c (opencl_language_data): Likewise.
1809 * p-lang.c (pascal_language_data): Likewise.
1810 * rust-lang.c (rust_language_data): Likewise.
1811 * symtab.c (default_collect_symbol_completion_matches): Delete.
1812 (collect_symbol_completion_matches): Update call to
1813 collect_symbol_completion_matches.
1814 (collect_symbol_completion_matches_type): Likewise.
1815 * symtab.h (default_collect_symbol_completion_matches): Delete
1816 declaration.
1817
1818 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1819
1820 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
1821 (ada_language_data): Delete la_word_break_characters initializer.
1822 (ada_language::word_break_characters): New member function.
1823 * c-lang.c (c_language_data): Delete la_word_break_characters
1824 initializer.
1825 (cplus_language_data): Likewise.
1826 (asm_language_data): Likewise.
1827 (minimal_language_data): Likewise.
1828 * completer.c: Update global comment.
1829 (advance_to_expression_complete_word_point): Update call to
1830 word_break_characters.
1831 (complete_files_symbols): Likewise.
1832 (complete_line_internal_1): Likewise.
1833 (default_completer_handle_brkchars): Likewise.
1834 (skip_quoted_chars): Likewise.
1835 * d-lang.c (d_language_data): Delete la_word_break_characters
1836 initializer.
1837 * f-lang.c (f_word_break_characters): Delete.
1838 (f_language_data): Delete la_word_break_characters initializer.
1839 (f_language::word_break_characters): New member function.
1840 * go-lang.c (go_language_data): Delete la_word_break_characters
1841 initializer.
1842 * language.c (unknown_language_data): Likewise.
1843 (auto_language_data): Likewise.
1844 * language.h (default_word_break_characters): Move declaration to
1845 earlier in the file.
1846 (language_data): Delete la_word_break_characters field.
1847 (language_defn::word_break_characters): New member function.
1848 * m2-lang.c (m2_language_data): Delete la_word_break_characters
1849 initializer.
1850 * objc-lang.c (objc_language_data): Likewise.
1851 * opencl-lang.c (opencl_language_data): Likewise.
1852 * p-lang.c (pascal_language_data): Likewise.
1853 * rust-lang.c (rust_language_data): Likewise.
1854
1855 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1856
1857 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
1858 (ada_language_data): Delete la_get_symbol_name_matcher
1859 initializer.
1860 (language_defn::get_symbol_name_matcher_inner): New member
1861 function.
1862 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
1863 initializer.
1864 (cplus_language_data): Likewise.
1865 (cplus_language::get_symbol_name_matcher_inner): New member
1866 function.
1867 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
1868 (minimal_language_data): Likewise.
1869 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
1870 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
1871 initializer.
1872 * dictionary.c (iter_match_first_hashed): Update call to
1873 get_symbol_name_matcher.
1874 (iter_match_next_hashed): Likewise.
1875 (iter_match_next_linear): Likewise.
1876 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
1877 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
1878 initializer.
1879 (f_language::get_symbol_name_matcher_inner): New member function.
1880 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
1881 initializer.
1882 * language.c (default_symbol_name_matcher): Update header comment,
1883 make static.
1884 (language_defn::get_symbol_name_matcher): New definition.
1885 (language_defn::get_symbol_name_matcher_inner): Likewise.
1886 (get_symbol_name_matcher): Delete.
1887 (unknown_language_data): Delete la_get_symbol_name_matcher
1888 initializer.
1889 (auto_language_data): Likewise.
1890 * language.h (language_data): Delete la_get_symbol_name_matcher
1891 field.
1892 (language_defn::get_symbol_name_matcher): New member function.
1893 (language_defn::get_symbol_name_matcher_inner): Likewise.
1894 (default_symbol_name_matcher): Delete declaration.
1895 * linespec.c (find_methods): Update call to
1896 get_symbol_name_matcher.
1897 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
1898 initializer.
1899 * minsyms.c (lookup_minimal_symbol): Update call to
1900 get_symbol_name_matcher.
1901 (iterate_over_minimal_symbols): Likewise.
1902 * objc-lang.c (objc_language_data): Delete
1903 la_get_symbol_name_matcher initializer.
1904 * opencl-lang.c (opencl_language_data): Likewise.
1905 * p-lang.c (pascal_language_data): Likewise.
1906 * psymtab.c (psymbol_name_matches): Update call to
1907 get_symbol_name_matcher.
1908 * rust-lang.c (rust_language_data): Delete
1909 la_get_symbol_name_matcher initializer.
1910 * symtab.c (symbol_matches_search_name): Update call to
1911 get_symbol_name_matcher.
1912 (compare_symbol_name): Likewise.
1913
1914 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1915
1916 * ada-lang.c (ada_language_data): Delete la_compute_program
1917 initializer.
1918 * c-lang.c (c_language_data): Likewise.
1919 (c_language::compute_program): New member function.
1920 (cplus_language_data): Delete la_compute_program initializer.
1921 (cplus_language::compute_program): New member function.
1922 (asm_language_data): Delete la_compute_program initializer.
1923 (minimal_language_data): Likewise.
1924 * c-lang.h (c_compute_program): Update comment.
1925 (cplus_compute_program): Likewise.
1926 * compile/compile-c-support.c (c_compute_program): Likewise.
1927 (cplus_compute_program): Likewise.
1928 * compile/compile.c (compile_to_object): Update call to
1929 la_compute_program.
1930 * d-lang.c (d_language_data): Delete la_compute_program
1931 initializer.
1932 * f-lang.c (f_language_data): Likewise.
1933 * go-lang.c (go_language_data): Likewise.
1934 * language.c (unknown_language_data): Likewise.
1935 (auto_language_data): Likewise.
1936 * language.h (language_data): Delete la_compute_program field.
1937 (language_defn::compute_program): New member function.
1938 * m2-lang.c (m2_language_data): Delete la_compute_program
1939 initializer.
1940 * objc-lang.c (objc_language_data): Likewise.
1941 * opencl-lang.c (opencl_language_data): Likewise.
1942 * p-lang.c (pascal_language_data): Likewise.
1943 * rust-lang.c (rust_language_data): Likewise.
1944
1945 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1946
1947 * ada-lang.c (ada_language_data) Delete
1948 la_class_name_from_physname initializer.
1949 * c-lang.c (c_language_data): Likewise.
1950 (cplus_language_data): Likewise.
1951 (cplus_language::class_name_from_physname): New member function.
1952 (asm_language_data): Delete la_class_name_from_physname
1953 initializer.
1954 (minimal_language_data): Likewise.
1955 * d-lang.c (d_language_data): Likewise.
1956 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
1957 method on language_defn class.
1958 (guess_full_die_structure_name): Likewise.
1959 * f-lang.c (f_language_data): Delete la_class_name_from_physname
1960 initializer.
1961 * go-lang.c (go_language_data): Likewise.
1962 * language.c (language_class_name_from_physname): Delete.
1963 (unk_lang_class_name): Delete.
1964 (unknown_language_data): Delete la_class_name_from_physname
1965 initializer.
1966 (auto_language_data): Likewise.
1967 * language.h (language_data): Delete la_class_name_from_physname
1968 field.
1969 (language_defn::class_name_from_physname): New function.
1970 (language_class_name_from_physname): Delete declaration.
1971 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
1972 initializer.
1973 * objc-lang.c (objc_language_data): Likewise.
1974 * opencl-lang.c (opencl_language_data): Likewise.
1975 * p-lang.c (pascal_language_data): Likewise.
1976 * rust-lang.c (rust_language_data): Likewise.
1977
1978 2020-06-16 Tom Tromey <tom@tromey.com>
1979
1980 * tui/tui-data.h (STATUS_NAME): New macro.
1981 * tui/tui-layout.c (tui_remove_some_windows)
1982 (initialize_known_windows, tui_register_window)
1983 (tui_layout_split::remove_windows, initialize_layouts)
1984 (tui_new_layout_command): Don't use hard-coded window names.
1985
1986 2020-06-16 Tom Tromey <tom@tromey.com>
1987
1988 PR tui/25348:
1989 * tui/tui.c (tui_ensure_readline_initialized): Rename from
1990 tui_initialize_readline. Only run once. Call rl_initialize.
1991 * tui/tui.h (tui_ensure_readline_initialized): Rename from
1992 tui_initialize_readline.
1993 * tui/tui-io.c (tui_setup_io): Call
1994 tui_ensure_readline_initialized.
1995 * tui/tui-interp.c (tui_interp::init): Update.
1996
1997 2020-06-16 Tom Tromey <tom@tromey.com>
1998
1999 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
2000 Also preserve the status window.
2001
2002 2020-06-16 Tom Tromey <tom@tromey.com>
2003
2004 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
2005 where m_window==nullptr.
2006
2007 2020-06-15 Tom Tromey <tromey@adacore.com>
2008
2009 * windows-nat.c (windows_nat::handle_output_debug_string):
2010 Update.
2011 (windows_nat::handle_ms_vc_exception): Update.
2012 * target.h (target_read_string): Change API.
2013 * target.c (target_read_string): Change API.
2014 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
2015 Update.
2016 * solib-frv.c (frv_current_sos): Update.
2017 * solib-dsbt.c (dsbt_current_sos): Update.
2018 * solib-darwin.c (darwin_current_sos): Update.
2019 * linux-thread-db.c (inferior_has_bug): Update.
2020 * expprint.c (print_subexp_standard): Update.
2021 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
2022 (ada_exception_message_1): Update.
2023
2024 2020-06-15 Tom Tromey <tromey@adacore.com>
2025
2026 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
2027
2028 2020-06-15 Tom Tromey <tromey@adacore.com>
2029
2030 * valprint.c (read_string): Update comment.
2031 * target.c (MIN): Remove.
2032 (target_read_string): Rewrite.
2033
2034 2020-06-15 Tom Tromey <tromey@adacore.com>
2035
2036 * corefile.c (read_memory_string): Remove.
2037 * ada-valprint.c (ada_value_print_ptr): Update.
2038 * ada-lang.h (ada_tag_name): Change return type.
2039 * ada-lang.c (type_from_tag): Update.
2040 (ada_tag_name_from_tsd): Change return type. Use
2041 target_read_string.
2042 (ada_tag_name): Likewise.
2043 * gdbcore.h (read_memory_string): Don't declare.
2044
2045 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
2046
2047 * symtab.c (rbreak_command): Ignore Windows drive colon.
2048
2049 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
2050
2051 * NEWS: Mention removed GDBserver host support.
2052
2053 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
2054
2055 * features/riscv/rebuild-csr-xml.sh: Updated.
2056
2057 2020-06-11 Tom Tromey <tom@tromey.com>
2058
2059 PR gdb/18318:
2060 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
2061
2062 2020-06-09 Jonny Grant <jg@jguk.org>
2063 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
2064
2065 * main.c (captured_main_1): Don't print new line after help.
2066 (print_gdb_help): add mailing list and IRC channel information
2067 to --help. Add new lines between items in the footer. Remove
2068 quotes around bug url.
2069
2070 2020-06-11 Keith Seitz <keiths@redhat.com>
2071
2072 PR gdb/21356
2073 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
2074 Resolve typedefs for type length calculations.
2075
2076 2020-06-10 Tom de Vries <tdevries@suse.de>
2077
2078 PR ada/24713
2079 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
2080 (write_psymbols): Enable .gdb_index for ada.
2081 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
2082 ada.
2083
2084 2020-06-10 Tom de Vries <tdevries@suse.de>
2085
2086 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
2087 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
2088 namei" instead of "const char *name" argument.
2089 (dw2_map_matching_symbols): Use "offset_type namei" variant of
2090 dw2_symtab_iter_init.
2091
2092 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2093
2094 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
2095 to use type::field and field::type instead.
2096
2097 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2098
2099 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
2100 to use field::type instead.
2101
2102 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2103
2104 * gdbtypes.h (struct field) <type, set_type>: New methods.
2105 Rename `type` field to...
2106 <m_type>: ... this. Change references throughout to use type or
2107 set_type methods.
2108 (FIELD_TYPE): Use field::type. Change call sites that modify
2109 the field's type to use field::set_type instead.
2110
2111 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2112
2113 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
2114 to use type::index_type instead.
2115
2116 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2117
2118 * gdbtypes.h (struct type) <index_type, set_index_type>: New
2119 methods.
2120 (TYPE_INDEX_TYPE): Use type::index_type.
2121 * gdbtypes.c (create_array_type_with_stride): Likewise.
2122
2123 2020-06-07 Tom Tromey <tom@tromey.com>
2124
2125 * valprint.c (generic_val_print_float): Remove "embedded_offset"
2126 parameter.
2127 (generic_value_print): Update.
2128
2129 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
2130
2131 Revert commit 982a38f60b0.
2132 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
2133
2134 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
2135
2136 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
2137 avoid use after free.
2138
2139 2020-06-05 Tom de Vries <tdevries@suse.de>
2140
2141 * NEWS: Fix typos.
2142
2143 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
2144
2145 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
2146 the per_bfd object.
2147 (dwarf2_read_debug_names): Likewise.
2148 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
2149 object when re-using a per_bfd object with an index.
2150
2151 2020-06-03 Tom de Vries <tdevries@suse.de>
2152
2153 PR symtab/26046
2154 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
2155 children for C++.
2156 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
2157 DW_TAG_subprogram.
2158
2159 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2160
2161 * ada-lang.c (ada_language_data): Delete skip_trampoline
2162 initializer.
2163 * c-lang.c (c_language_data): Likewise.
2164 (cplus_language_data): Likewise.
2165 (cplus_language::skip_trampoline): New member function.
2166 (asm_language_data): Delete skip_trampoline initializer.
2167 (minimal_language_data): Likewise.
2168 * d-lang.c (d_language_data): Likewise.
2169 * f-lang.c (f_language_data): Likewise.
2170 * go-lang.c (go_language_data): Likewise.
2171 * language.c (unk_lang_trampoline): Delete function.
2172 (skip_language_trampoline): Update.
2173 (unknown_language_data): Delete skip_trampoline initializer.
2174 (auto_language_data): Likewise.
2175 * language.h (language_data): Delete skip_trampoline field.
2176 (language_defn::skip_trampoline): New function.
2177 * m2-lang.c (m2_language_data): Delete skip_trampoline
2178 initializer.
2179 * objc-lang.c (objc_skip_trampoline): Delete function, move
2180 implementation to objc_language::skip_trampoline.
2181 (objc_language_data): Delete skip_trampoline initializer.
2182 (objc_language::skip_trampoline): New member function with
2183 implementation from objc_skip_trampoline.
2184 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
2185 initializer.
2186 * p-lang.c (pascal_language_data): Likewise.
2187 * rust-lang.c (rust_language_data): Likewise.
2188
2189 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2190
2191 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
2192 (ada_language::demangle): New member function.
2193 * c-lang.c (c_language_data): Delete la_demangle initializer.
2194 (cplus_language_data): Delete la_demangle initializer.
2195 (cplus_language::demangle): New member function.
2196 (asm_language_data): Delete la_demangle initializer.
2197 (minimal_language_data): Delete la_demangle initializer.
2198 * d-lang.c (d_language_data): Delete la_demangle initializer.
2199 (d_language::demangle): New member function.
2200 * f-lang.c (f_language_data): Delete la_demangle initializer.
2201 (f_language::demangle): New member function.
2202 * go-lang.c (go_language_data): Delete la_demangle initializer.
2203 (go_language::demangle): New member function.
2204 * language.c (language_demangle): Update.
2205 (unk_lang_demangle): Delete.
2206 (unknown_language_data): Delete la_demangle initializer.
2207 (unknown_language::demangle): New member function.
2208 (auto_language_data): Delete la_demangle initializer.
2209 (auto_language::demangle): New member function.
2210 * language.h (language_data): Delete la_demangle field.
2211 (language_defn::demangle): New function.
2212 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
2213 * objc-lang.c (objc_language_data): Delete la_demangle
2214 initializer.
2215 (objc_language::demangle): New member function.
2216 * opencl-lang.c (opencl_language_data): Delete la_demangle
2217 initializer.
2218 * p-lang.c (pascal_language_data): Likewise.
2219 * rust-lang.c (rust_language_data): Likewise.
2220 (rust_language::demangle): New member function.
2221
2222 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2223
2224 * ada-lang.c (ada_language_data): Delete la_print_type
2225 initializer.
2226 (ada_language::print_type): New member function.
2227 * c-lang.c (c_language_data): Delete la_print_type initializer.
2228 (c_language::print_type): New member function.
2229 (cplus_language_data): Delete la_print_type initializer.
2230 (cplus_language::print_type): New member function.
2231 (asm_language_data): Delete la_print_type initializer.
2232 (asm_language::print_type): New member function.
2233 (minimal_language_data): Delete la_print_type initializer.
2234 (minimal_language::print_type): New member function.
2235 * d-lang.c (d_language_data): Delete la_print_type initializer.
2236 (d_language::print_type): New member function.
2237 * f-lang.c (f_language_data): Delete la_print_type initializer.
2238 (f_language::print_type): New member function.
2239 * go-lang.c (go_language_data): Delete la_print_type initializer.
2240 (go_language::print_type): New member function.
2241 * language.c (unk_lang_print_type): Delete.
2242 (unknown_language_data): Delete la_print_type initializer.
2243 (unknown_language::print_type): New member function.
2244 (auto_language_data): Delete la_print_type initializer.
2245 (auto_language::print_type): New member function.
2246 * language.h (language_data): Delete la_print_type field.
2247 (language_defn::print_type): New function.
2248 (LA_PRINT_TYPE): Update.
2249 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
2250 (m2_language::print_type): New member function.
2251 * objc-lang.c (objc_language_data): Delete la_print_type
2252 initializer.
2253 (objc_language::print_type): New member function.
2254 * opencl-lang.c (opencl_print_type): Delete, implementation moved
2255 to opencl_language::print_type.
2256 (opencl_language_data): Delete la_print_type initializer.
2257 (opencl_language::print_type): New member function, implementation
2258 from opencl_print_type.
2259 * p-lang.c (pascal_language_data): Delete la_print_type
2260 initializer.
2261 (pascal_language::print_type): New member function.
2262 * rust-lang.c (rust_print_type): Delete, implementation moved to
2263 rust_language::print_type.
2264 (rust_language_data): Delete la_print_type initializer.
2265 (rust_language::print_type): New member function, implementation
2266 from rust_print_type.
2267
2268 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2269
2270 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
2271 implementation moves to...
2272 (ada_language::sniff_from_mangled_name): ...here. Update return
2273 type.
2274 (ada_language_data): Delete la_sniff_from_mangled_name
2275 initializer.
2276 * c-lang.c (c_language_data): Likewise.
2277 (cplus_language_data): Likewise.
2278 (cplus_language::sniff_from_mangled_name): New member function,
2279 implementation taken from gdb_sniff_from_mangled_name.
2280 (asm_language_data): Delete la_sniff_from_mangled_name
2281 initializer.
2282 (minimal_language_data): Likewise.
2283 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
2284 implementation moves to cplus_language::sniff_from_mangled_name.
2285 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
2286 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
2287 moves to...
2288 (d_language::sniff_from_mangled_name): ...here.
2289 (d_language_data): Delete la_sniff_from_mangled_name initializer.
2290 * f-lang.c (f_language_data): Likewise.
2291 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
2292 moves to...
2293 (go_language::sniff_from_mangled_name): ...here.
2294 (go_language_data): Delete la_sniff_from_mangled_name initializer.
2295 * language.c (language_sniff_from_mangled_name): Delete.
2296 (unknown_language_data): Delete la_sniff_from_mangled_name
2297 initializer.
2298 (auto_language_data): Likewise.
2299 * language.h (language_data): Delete la_sniff_from_mangled_name
2300 field.
2301 (language_defn::sniff_from_mangled_name): New function.
2302 (language_sniff_from_mangled_name): Delete declaration.
2303 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
2304 field.
2305 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
2306 implementation moves to...
2307 (objc_language::sniff_from_mangled_name): ...here.
2308 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
2309 * opencl-lang.c (opencl_language_data): Likewise.
2310 * p-lang.c (pascal_language_data): Likewise.
2311 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
2312 implementation moves to...
2313 (rust_language::sniff_from_mangled_name): ...here.
2314 (rust_language_data): Delete la_sniff_from_mangled_name
2315 initializer.
2316 * symtab.c (symbol_find_demangled_name): Call
2317 sniff_from_mangled_name member function.
2318
2319 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2320
2321 * ada-lang.c (ada_language_data): Delete la_search_name_hash
2322 initializer.
2323 * c-lang.c (c_language_data): Likewise.
2324 (cplus_language_data): Likewise.
2325 (cplus_language::search_name_hash): New member function.
2326 (asm_language_data): Delete la_search_name_hash initializer.
2327 (minimal_language_data): Likewise.
2328 * d-lang.c (d_language_data): Likewise.
2329 * dictionary.c (default_search_name_hash): Rename to...
2330 (language_defn::search_name_hash): ...this.
2331 * f-lang.c (f_language_data): Likewise.
2332 (f_language::search_name_hash): New member function.
2333 * go-lang.c (go_language_data): Delete la_search_name_hash
2334 initializer.
2335 * language.c (unknown_language_data): Likewise.
2336 (auto_language_data): Likewise.
2337 * language.h (struct language_data): Delete la_search_name_hash
2338 field.
2339 (language_defn::search_name_hash): Declare new member function.
2340 (default_search_name_hash): Delete declaration.
2341 * m2-lang.c (m2_language_data): Delete la_search_name_hash
2342 initializer.
2343 * objc-lang.c (objc_language_data): Likewise.
2344 * opencl-lang.c (opencl_language_data): Likewise.
2345 * p-lang.c (pascal_language_data): Likewise.
2346 * rust-lang.c (rust_language_data): Likewise.
2347 * symtab.c (search_name_hash): Update call.
2348
2349 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2350
2351 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
2352 initializer.
2353 * c-lang.c (class compile_instance): Declare.
2354 (c_language_data): Delete la_get_compile_instance initializer.
2355 (c_language::get_compile_instance): New member function.
2356 (cplus_language_data): Delete la_get_compile_instance initializer.
2357 (cplus_language::get_compile_instance): New member function.
2358 (asm_language_data): Delete la_get_compile_instance initializer.
2359 (minimal_language_data): Likewise.
2360 * c-lang.h (c_get_compile_context): Update comment.
2361 (cplus_get_compile_context): Update comment.
2362 * compile/compile.c (compile_to_object): Update calls, don't rely
2363 on function pointer being NULL.
2364 * d-lang.c (d_language_data): Delete la_get_compile_instance
2365 initializer.
2366 * f-lang.c (f_language_data): Likewise.
2367 * go-lang.c (go_language_data): Likewise.
2368 * language.c (unknown_language_data): Likewise.
2369 (auto_language_data): Likewise.
2370 * language.h (language_data): Delete la_get_compile_instance field.
2371 (language_defn::get_compile_instance): New member function.
2372 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
2373 initializer.
2374 * objc-lang.c (objc_language_data): Likewise.
2375 * opencl-lang.c (opencl_language_data): Likewise.
2376 * p-lang.c (pascal_language_data): Likewise.
2377 * rust-lang.c (rust_language_data): Likewise.
2378
2379 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2380
2381 * ada-lang.c (ada_add_all_symbols): Update comment.
2382 (ada_iterate_over_symbols): Delete, move implementation to...
2383 (ada_language::iterate_over_symbols): ...here, a new member
2384 function, rewrite to use range based for loop.
2385 (ada_language_data): Delete la_iterate_over_symbols initializer.
2386 * c-lang.c (c_language_data): Likewise.
2387 (cplus_language_data): Likewise.
2388 (asm_language_data): Likewise.
2389 (minimal_language_data): Likewise.
2390 * d-lang.c (d_language_data): Likewise.
2391 * f-lang.c (f_language_data): Likewise.
2392 * go-lang.c (go_language_data): Likewise.
2393 * language.c (unknown_language_data): Likewise.
2394 (auto_language_data): Likewise.
2395 * language.h (language_data): Delete la_iterate_over_symbols field.
2396 (language_defn::iterate_over_symbols): New member function.
2397 (LA_ITERATE_OVER_SYMBOLS): Update.
2398 * linespec.c (iterate_over_all_matching_symtabs): Update.
2399 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
2400 initializer.
2401 * objc-lang.c (objc_language_data): Likewise.
2402 * opencl-lang.c (opencl_language_data): Likewise.
2403 * p-lang.c (pascal_language_data): Likewise.
2404 * rust-lang.c (rust_language_data): Likewise.
2405
2406 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2407
2408 * ada-lang.c (ada_language_data): Delete
2409 la_lookup_transparent_type initializer.
2410 * c-lang.c (c_language_data): Likewise.
2411 (cplus_language_data): Likewise.
2412 (cplus_language::lookup_transparent_type): New member function.
2413 (asm_language_data): Delete la_lookup_transparent_type
2414 initializer.
2415 (minimal_language_data): Likewise.
2416 * d-lang.c (d_language_data): Likewise.
2417 * f-lang.c (f_language_data): Likewise.
2418 * go-lang.c (go_language_data): Likewise.
2419 * language.c (unknown_language_data): Likewise.
2420 (auto_language_data): Likewise.
2421 * language.h (struct language_data): Delete
2422 la_lookup_transparent_type field.
2423 (language_defn::lookup_transparent_type): New member function.
2424 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
2425 initializer.
2426 * objc-lang.c (objc_language_data): Likewise.
2427 * opencl-lang.c (opencl_language_data): Likewise.
2428 * p-lang.c (pascal_language_data): Likewise.
2429 * rust-lang.c (rust_language_data): Likewise.
2430 * symtab.c (symbol_matches_domain): Update call.
2431
2432 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2433
2434 * ada-lang.c (ada_language_arch_info): Delete function, move
2435 implementation to...
2436 (ada_language::language_arch_info): ...here, a new member
2437 function.
2438 (ada_language_data): Delete la_language_arch_info.
2439 * c-lang.c (c_language_data): Likewise.
2440 (c_language::language_arch_info): New member function.
2441 (cplus_language_arch_info): Delete function, move
2442 implementation to...
2443 (cplus_language::language_arch_info): ...here, a new member
2444 function.
2445 (cplus_language_data): Delete la_language_arch_info.
2446 (asm_language_data): Likewise.
2447 (asm_language::language_arch_info): New member function.
2448 (minimal_language_data): Delete la_language_arch_info.
2449 (minimal_language::language_arch_info): New member function.
2450 * d-lang.c (d_language_arch_info): Delete function, move
2451 implementation to...
2452 (d_language::language_arch_info): ...here, a new member
2453 function.
2454 (d_language_data): Delete la_language_arch_info.
2455 * f-lang.c (f_language_arch_info): Delete function, move
2456 implementation to...
2457 (f_language::language_arch_info): ...here, a new member
2458 function.
2459 (f_language_data): Delete la_language_arch_info.
2460 * go-lang.c (go_language_arch_info): Delete function, move
2461 implementation to...
2462 (go_language::language_arch_info): ...here, a new member
2463 function.
2464 (go_language_data): Delete la_language_arch_info.
2465 * language.c (unknown_language_data): Likewise.
2466 (unknown_language::language_arch_info): New member function.
2467 (auto_language_data): Delete la_language_arch_info.
2468 (auto_language::language_arch_info): New member function.
2469 (language_gdbarch_post_init): Update call to
2470 la_language_arch_info.
2471 * language.h (language_data): Delete la_language_arch_info
2472 function pointer.
2473 (language_defn::language_arch_info): New function.
2474 * m2-lang.c (m2_language_arch_info): Delete function, move
2475 implementation to...
2476 (m2_language::language_arch_info): ...here, a new member
2477 function.
2478 (m2_language_data): Delete la_language_arch_info.
2479 * objc-lang.c (objc_language_arch_info): Delete function, move
2480 implementation to...
2481 (objc_language::language_arch_info): ...here, a new member
2482 function.
2483 (objc_language_data): Delete la_language_arch_info.
2484 * opencl-lang.c (opencl_language_arch_info): Delete function, move
2485 implementation to...
2486 (opencl_language::language_arch_info): ...here, a new member
2487 function.
2488 (opencl_language_data): Delete la_language_arch_info.
2489 * p-lang.c (pascal_language_arch_info): Delete function, move
2490 implementation to...
2491 (pascal_language::language_arch_info): ...here, a new member
2492 function.
2493 (pascal_language_data): Delete la_language_arch_info.
2494 * rust-lang.c (rust_language_arch_info): Delete function, move
2495 implementation to...
2496 (rust_language::language_arch_info): ...here, a new member
2497 function.
2498 (rust_language_data): Delete la_language_arch_info.
2499
2500 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2501
2502 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
2503 initializer.
2504 * c-lang.c (c_language_data): Likewise.
2505 (cplus_language_data): Likewise.
2506 (cplus_language::pass_by_reference_info): New method.
2507 (asm_language_data): Delete la_pass_by_reference initializer.
2508 (minimal_language_data): Likewise.
2509 * cp-abi.c (cp_pass_by_reference): Remove use of
2510 default_pass_by_reference.
2511 * d-lang.c (d_language_data): Likewise.
2512 * f-lang.c (f_language_data): Likewise.
2513 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
2514 default_pass_by_reference.
2515 * go-lang.c (go_language_data): Likewise.
2516 * language.c (language_pass_by_reference): Update.
2517 (default_pass_by_reference): Delete.
2518 (unknown_language_data): Delete la_pass_by_reference
2519 initializer.
2520 (auto_language_data): Likewise.
2521 * language.h (struct language_data): Delete la_pass_by_reference
2522 field.
2523 (language_defn::pass_by_reference_info): New member function.
2524 (default_pass_by_reference): Delete declaration.
2525 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
2526 initializer.
2527 * objc-lang.c (objc_language_data): Likewise.
2528 * opencl-lang.c (opencl_language_data): Likewise.
2529 * p-lang.c (pascal_language_data): Likewise.
2530 * rust-lang.c (rust_language_data): Likewise.
2531
2532 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2533
2534 * ada-lang.c (ada_read_var_value): Delete function, move
2535 implementation to...
2536 (ada_language::read_var_value): ...here.
2537 (ada_language_data): Delete la_read_var_value initializer.
2538 * c-lang.c (c_language_data): Likewise.
2539 (cplus_language_data): Likewise.
2540 (minimal_language_data): Likewise.
2541 * d-lang.c (d_language_data): Likewise.
2542 * f-lang.c (f_language_data): Likewise.
2543 * findvar.c (default_read_var_value): Rename to...
2544 (language_defn::read_var_value): ...this.
2545 * findvar.c (read_var_value): Update header comment, and change to
2546 call member function instead of function pointer.
2547 * go-lang.c (go_language_data): Likewise.
2548 * language.c (unknown_language_data): Delete la_read_var_value
2549 initializer.
2550 (auto_language_data): Likewise.
2551 * language.h (struct language_data): Delete la_read_var_value
2552 field.
2553 (language_defn::read_var_value): New member function.
2554 (default_read_var_value): Delete declaration.
2555 * m2-lang.c (m2_language_data): Delete la_read_var_value
2556 initializer.
2557 * objc-lang.c (objc_language_data): Likewise.
2558 * opencl-lang.c (opencl_language_data): Likewise.
2559 * p-lang.c (pascal_language_data): Likewise.
2560 * rust-lang.c (rust_language_data): Likewise.
2561 * value.h (default_read_var_value): Delete declaration.
2562
2563 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2564
2565 * ada-lang.c (ada_print_array_index): Delete function, move
2566 implementation to...
2567 (ada_language::print_array_index): ...here.
2568 (ada_language_data): Delete la_print_array_index initializer.
2569 * c-lang.c (c_language_data): Likewise.
2570 (cplus_language_data): Likewise.
2571 (minimal_language_data): Likewise.
2572 * d-lang.c (d_language_data): Likewise.
2573 * f-lang.c (f_language_data): Likewise.
2574 * go-lang.c (go_language_data): Likewise.
2575 * language.c (default_print_array_index): Delete function, move
2576 implementation to...
2577 (language_defn::print_array_index): ...here.
2578 (unknown_language_data): Delete la_print_array_index initializer.
2579 (auto_language_data): Likewise.
2580 * language.h (struct language_data): Delete la_print_array_index
2581 field.
2582 (language_defn::print_array_index): New member function.
2583 (LA_PRINT_ARRAY_INDEX): Update.
2584 (default_print_array_index): Delete declaration.
2585 * m2-lang.c (m2_language_data): Delete la_print_array_index
2586 initializer.
2587 * objc-lang.c (objc_language_data): Likewise.
2588 * opencl-lang.c (opencl_language_data): Likewise.
2589 * p-lang.c (pascal_language_data): Likewise.
2590 * rust-lang.c (rust_language_data): Likewise.
2591
2592 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2593
2594 * gdb/ada-lang.c (ada_language_defn): Convert to...
2595 (ada_language_data): ...this.
2596 (class ada_language): New class.
2597 (ada_language_defn): New static global.
2598 * gdb/c-lang.c (c_language_defn): Convert to...
2599 (c_language_data): ...this.
2600 (class c_language): New class.
2601 (c_language_defn): New static global.
2602 (cplus_language_defn): Convert to...
2603 (cplus_language_data): ...this.
2604 (class cplus_language): New class.
2605 (cplus_language_defn): New static global.
2606 (asm_language_defn): Convert to...
2607 (asm_language_data): ...this.
2608 (class asm_language): New class.
2609 (asm_language_defn): New static global.
2610 (minimal_language_defn): Convert to...
2611 (minimal_language_data): ...this.
2612 (class minimal_language): New class.
2613 (minimal_language_defn): New static global.
2614 * gdb/d-lang.c (d_language_defn): Convert to...
2615 (d_language_data): ...this.
2616 (class d_language): New class.
2617 (d_language_defn): New static global.
2618 * gdb/f-lang.c (f_language_defn): Convert to...
2619 (f_language_data): ...this.
2620 (class f_language): New class.
2621 (f_language_defn): New static global.
2622 * gdb/go-lang.c (go_language_defn): Convert to...
2623 (go_language_data): ...this.
2624 (class go_language): New class.
2625 (go_language_defn): New static global.
2626 * gdb/language.c (unknown_language_defn): Remove declaration.
2627 (current_language): Initialize to nullptr, real initialization is
2628 moved to _initialize_language.
2629 (languages): Delete global.
2630 (language_defn::languages): Define.
2631 (set_language_command): Use language_defn::languages.
2632 (set_language): Likewise.
2633 (range_error): Likewise.
2634 (language_enum): Likewise.
2635 (language_def): Likewise.
2636 (add_set_language_command): Use language_def::languages for the
2637 language list, and language_def to lookup language pointers.
2638 (skip_language_trampoline): Use language_defn::languages.
2639 (unknown_language_defn): Convert to...
2640 (unknown_language_data): ...this.
2641 (class unknown_language): New class.
2642 (unknown_language_defn): New static global.
2643 (auto_language_defn): Convert to...
2644 (auto_language_data): ...this.
2645 (class auto_language): New class.
2646 (auto_language_defn): New static global.
2647 (language_gdbarch_post_init): Use language_defn::languages.
2648 (_initialize_language): Initialize current_language.
2649 * gdb/language.h (struct language_defn): Rename to...
2650 (struct language_data): ...this.
2651 (struct language_defn): New.
2652 (auto_language_defn): Delete.
2653 (unknown_language_defn): Delete.
2654 (minimal_language_defn): Delete.
2655 (ada_language_defn): Delete.
2656 (asm_language_defn): Delete.
2657 (c_language_defn): Delete.
2658 (cplus_language_defn): Delete.
2659 (d_language_defn): Delete.
2660 (f_language_defn): Delete.
2661 (go_language_defn): Delete.
2662 (m2_language_defn): Delete.
2663 (objc_language_defn): Delete.
2664 (opencl_language_defn): Delete.
2665 (pascal_language_defn): Delete.
2666 (rust_language_defn): Delete.
2667 * gdb/m2-lang.c (m2_language_defn): Convert to...
2668 (m2_language_data): ...this.
2669 (class m2_language): New class.
2670 (m2_language_defn): New static global.
2671 * gdb/objc-lang.c (objc_language_defn): Convert to...
2672 (objc_language_data): ...this.
2673 (class objc_language): New class.
2674 (objc_language_defn): New static global.
2675 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
2676 (opencl_language_data): ...this.
2677 (class opencl_language): New class.
2678 (opencl_language_defn): New static global.
2679 * gdb/p-lang.c (pascal_language_defn): Convert to...
2680 (pascal_language_data): ...this.
2681 (class pascal_language): New class.
2682 (pascal_language_defn): New static global.
2683 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
2684 language pointer, update comment format.
2685 * gdb/rust-lang.c (rust_language_defn): Convert to...
2686 (rust_language_data): ...this.
2687 (class rust_language): New class.
2688 (rust_language_defn): New static global.
2689
2690 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
2691
2692 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
2693 member variable.
2694 <m_stmt_at_address>: New member variable.
2695 (lnp_state_machine::record_line): Don't record some lines, update
2696 tracking of is_stmt at the same address.
2697 (lnp_state_machine::lnp_state_machine): Initialise new member
2698 variables.
2699
2700 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
2701
2702 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
2703 "-include gnu-nat-mig.h".
2704 * gnu-nat-mig.h: New file.
2705 * gnu-nat.c: Include "gnu-nat-mig.h".
2706 (exc_server, msg_reply_server, notify_server,
2707 process_reply_server): Remove declarations.
2708
2709 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2710
2711 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
2712 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
2713 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
2714 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
2715 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
2716 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
2717 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
2718 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
2719 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
2720 to gnu_nat_target class.
2721 * gnu-nat.c: Likewise.
2722 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
2723 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
2724 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
2725 object.
2726 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
2727 instead of `gnu_target'.
2728
2729 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2730
2731 * i386-gnu-tdep.c: Include "gdbcore.h"
2732 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
2733 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
2734 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
2735 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
2736 i386_gnu_sigcontext_addr): New functions
2737 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
2738 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
2739 tdep.
2740
2741 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2742
2743 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
2744 before fork_inferior call. Avoid calling it if target_is_pushed returns
2745 true.
2746
2747 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2748
2749 * gnu-nat.h (gnu_target): New variable declaration.
2750 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
2751 gnu_target.
2752 * gnu-nat.c (gnu_target): New variable.
2753 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
2754 add_thread_silent, and add_thread calls.
2755 (gnu_nat_target::create_inferior): Pass gnu_target to
2756 add_thread_silent, thread_change_ptid call.
2757 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
2758 call.
2759
2760 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2761
2762 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
2763 (gnu_nat_target::find_memory_regions): Remove unused
2764 `old_address' variable.
2765
2766 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2767
2768 * gnu-nat.c: Include "gdbarch.h".
2769
2770 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2771
2772 * reply_mig_hack.awk (Error return): Cast function through
2773 void *, to bypass compiler function call check.
2774
2775 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2776
2777 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
2778 $(srcdir)/reply_mig_hack.awk.
2779
2780 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2781
2782 * gnu-nat.h (gnu_debug_flag): Set type to bool.
2783
2784 2020-05-30 Jonny Grant <jg@jguk.org>
2785
2786 * configure.ac (ACX_BUGURL): change bug URL to https.
2787
2788 2020-05-30 Pedro Alves <palves@redhat.com>
2789
2790 * cp-support.c (replace_typedefs_template): New.
2791 (replace_typedefs_qualified_name): Handle
2792 DEMANGLE_COMPONENT_TEMPLATE.
2793
2794 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
2795
2796 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
2797 dwarf2/index-cache.h, dwarf2/index-write.c,
2798 dwarf2/index-write.h, dwarf2/line-header.c,
2799 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
2800 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
2801 variables and fields from `dwarf2_per_objfile` to just
2802 `per_objfile` throughout.
2803
2804 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
2805
2806 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2807 <push_dwarf_reg_entry_value>: Add comment.
2808
2809 2020-05-28 Kevin Buettner <kevinb@redhat.com>
2810 Keith Seitz <keiths@redhat.com>
2811
2812 * python/python.c (do_start_initialization): Call PyEval_SaveThread
2813 instead of PyEval_ReleaseLock.
2814 (class gdbpy_gil): Move to earlier in file.
2815 (finalize_python): Set gdb_python_initialized.
2816 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
2817 when not initialized.
2818
2819 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
2820
2821 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2822 <push_dwarf_reg_entry_value>: Remove assert. Override
2823 per_objfile with caller_per_objfile.
2824
2825 2020-05-28 Tom de Vries <tdevries@suse.de>
2826
2827 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
2828 PR gold/15646 workaround to symbol kind "type".
2829
2830 2020-05-27 Tom Tromey <tromey@adacore.com>
2831
2832 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
2833
2834 2020-05-27 Tom Tromey <tromey@adacore.com>
2835
2836 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
2837 Use htab_find_with_hash.
2838 <add_abbrev>: Remove "abbrev_number" parameter.
2839 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
2840 "abbrev_number" parameter. Use htab_find_slot_with_hash.
2841 (hash_abbrev): Add comment.
2842 (abbrev_table::lookup_abbrev): Move to header file.
2843 (abbrev_table::read): Update.
2844
2845 2020-05-27 Tom Tromey <tromey@adacore.com>
2846
2847 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
2848 method.
2849 <canonical_name>: New member.
2850 <raw_name>: Rename from "name".
2851 (partial_die_info): Initialize canonical_name.
2852 (scan_partial_symbols): Check raw_name.
2853 (partial_die_parent_scope, partial_die_full_name)
2854 (add_partial_symbol, add_partial_subprogram)
2855 (add_partial_enumeration, load_partial_dies): Use "name" method.
2856 (partial_die_info::name): New method.
2857 (partial_die_info::read, guess_partial_die_structure_name)
2858 (partial_die_info::fixup): Update.
2859
2860 2020-05-27 Tom Tromey <tromey@adacore.com>
2861
2862 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
2863 <get_ref_die_offset>: Inline.
2864 <get_ref_die_offset_complaint>: New method.
2865 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
2866 (attribute::get_ref_die_offset_complaint): Rename from
2867 get_ref_die_offset. Just issue complaint.
2868
2869 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2870
2871 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
2872
2873 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2874
2875 * exec.c (exec_file_attach): Use errno value of first openp failure.
2876
2877 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2878
2879 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
2880 Don't close thread handle.
2881
2882 2020-05-27 Tom Tromey <tom@tromey.com>
2883 Simon Marchi <simon.marchi@efficios.com>
2884
2885 * objfiles.h (struct objfile) <partial_symtabs>: Now a
2886 shared_ptr.
2887 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
2888 member.
2889 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
2890 dwarf2_per_bfd_objfile_data_key>: New globals.
2891 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
2892 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
2893 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
2894 shared.
2895 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
2896 short-circuit when sharing.
2897 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
2898 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
2899
2900 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2901
2902 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
2903 to...
2904 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
2905 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
2906
2907 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2908
2909 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
2910 build_name_components, find_name_components_bounds>:
2911 Add per_objfile parameter.
2912 (struct mapped_index) <symbol_name_at>: Likewise.
2913 (struct mapped_debug_names): Remove constructor.
2914 <dwarf2_per_objfile>: Remove field.
2915 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
2916 (mapped_index_base::find_name_components_bounds,
2917 mapped_index_base::build_name_components,
2918 dw2_expand_symtabs_matching_symbol): Likewise.
2919 (class mock_mapped_index) <symbol_name_at>: Likewise.
2920 (check_match): Likewise.
2921 (check_find_bounds_finds): Likewise.
2922 (test_mapped_index_find_name_component_bounds): Update.
2923 (CHECK_MATCH): Update.
2924 (dw2_expand_symtabs_matching): Update.
2925 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
2926 per_objfile parameter.
2927 <find_vec_in_debug_names>: Likewise.
2928 <m_per_objfile>: New field.
2929 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
2930 parameter.
2931 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
2932 (dw2_debug_names_iterator::next): Update.
2933 (dw2_debug_names_lookup_symbol): Update.
2934 (dw2_debug_names_expand_symtabs_for_function): Update.
2935 (dw2_debug_names_map_matching_symbols): Update.
2936 (dw2_debug_names_expand_symtabs_matching): Update.
2937 (dwarf2_read_debug_names): Update.
2938
2939 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2940
2941 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
2942 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
2943 move to dwarf2_per_objfile.
2944 <read_in_chain>: Remove.
2945 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
2946 remove_all_cus, age_comp_units>: New methods.
2947 <m_dwarf2_cus>: New member.
2948 (struct dwarf2_per_cu_data) <cu>: Remove.
2949 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
2950 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
2951 moved to methods of dwarf2_per_objfile.
2952 (dwarf2_clear_marks): Remove.
2953 (dwarf2_queue_item::~dwarf2_queue_item): Update.
2954 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
2955 (dwarf2_per_bfd::free_cached_comp_units): Remove.
2956 (dwarf2_per_objfile::remove_all_cus): New.
2957 (class free_cached_comp_units) <~free_cached_comp_units>:
2958 Update.
2959 (load_cu): Update.
2960 (dw2_do_instantiate_symtab): Adjust.
2961 (fill_in_sig_entry_from_dwo_entry): Adjust.
2962 (cutu_reader::init_tu_and_read_dwo_dies): Update.
2963 (cutu_reader::cutu_reader): Likewise.
2964 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
2965 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
2966 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
2967 and dwarf2_per_objfile::age_comp_units.
2968 (load_partial_comp_unit): Update.
2969 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
2970 (process_queue): Likewise.
2971 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
2972 backlink.
2973 (dwarf2_read_addr_index): Likewise.
2974 (follow_die_offset): Likewise.
2975 (dwarf2_fetch_die_loc_sect_off): Likewise.
2976 (dwarf2_fetch_constant_bytes): Likewise.
2977 (dwarf2_fetch_die_type_sect_off): Likewise.
2978 (follow_die_sig_1): Likewise.
2979 (load_full_type_unit): Likewise.
2980 (read_signatured_type): Likewise.
2981 (dwarf2_cu::dwarf2_cu): Don't set cu field.
2982 (dwarf2_cu::~dwarf2_cu): Remove.
2983 (dwarf2_per_objfile::get_cu): New.
2984 (dwarf2_per_objfile::set_cu): New.
2985 (age_cached_comp_units): Rename to...
2986 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
2987 to std::unordered_map.
2988 (free_one_cached_comp_unit): Rename to...
2989 (dwarf2_per_objfile::remove_cu): ... this. Adjust
2990 to std::unordered_map.
2991 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
2992 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
2993 a dwarf2_per_objfile in data.
2994 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
2995 (dwarf2_clear_marks): Remove.
2996
2997 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2998
2999 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
3000 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
3001 (init_tu_and_read_dwo_dies): Likewise.
3002 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
3003 (cutu_reader::cutu_reader): Likewise.
3004 (load_partial_comp_unit): Likewise.
3005 (process_psymtab_comp_unit): Update.
3006 (build_type_psymtabs_1): Update.
3007 (process_skeletonless_type_unit): Update.
3008 (load_full_comp_unit): Update.
3009 (find_partial_die): Update.
3010 (dwarf2_read_addr_index): Update.
3011 (read_signatured_type): Update.
3012
3013 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3014
3015 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
3016 m_header_read_in>: New fields.
3017 <get_header>: New method.
3018 * dwarf2/read.c (per_cu_header_read_in): Remove.
3019 (dwarf2_per_cu_data::get_header): New.
3020 (dwarf2_per_cu_data::addr_size): Update.
3021 (dwarf2_per_cu_data::offset_size): Update.
3022 (dwarf2_per_cu_data::ref_addr_size): Update.
3023
3024 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3025
3026 * dwarf2/read.c (load_cu): Return dwarf2_cu.
3027 (dw2_do_instantiate_symtab): Update.
3028 (queue_and_load_all_dwo_tus): Change parameter from
3029 dwarf2_per_cu_data to dwarf2_cu.
3030 (dwarf2_fetch_die_loc_sect_off): Update.
3031 (dwarf2_fetch_constant_bytes): Update.
3032 (dwarf2_fetch_die_type_sect_off): Update.
3033
3034 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3035
3036 * dwarf2/read.c (process_full_comp_unit,
3037 process_full_type_unit): Remove per_cu, per_objfile paramters.
3038 Add dwarf2_cu parameter.
3039 (process_queue): Update.
3040
3041 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3042
3043 * dwarf2/read.c (create_cu_from_index_list): Replace
3044 dwarf2_per_objfile parameter with dwarf2_per_bfd.
3045 (create_cus_from_index_list): Likewise.
3046 (create_cus_from_index): Likewise.
3047 (create_signatured_type_table_from_index): Likewise.
3048 (create_cus_from_debug_names_list): Likewise.
3049 (create_cus_from_debug_names): Likewise.
3050 (dwarf2_read_gdb_index): Update.
3051 (dwarf2_read_debug_names): Update.
3052
3053 2020-05-27 Tom Tromey <tom@tromey.com>
3054 Simon Marchi <simon.marchi@efficios.com>
3055
3056 * dwarf2/read.h (struct dwarf2_per_objfile)
3057 <get_type_for_signatured_type, set_type_for_signatured_type>:
3058 New methods.
3059 <m_type_map>: New member.
3060 (struct signatured_type) <type>: Remove.
3061 * dwarf2/read.c
3062 (dwarf2_per_objfile::get_type_for_signatured_type,
3063 dwarf2_per_objfile::set_type_for_signatured_type): New.
3064 (get_signatured_type): Use new methods.
3065
3066 2020-05-27 Tom Tromey <tom@tromey.com>
3067 Simon Marchi <simon.marchi@efficios.com>
3068
3069 * dwarf2/read.h (struct type_unit_group_unshareable): New.
3070 (struct dwarf2_per_objfile) <type_units>: New member.
3071 <get_type_unit_group_unshareable>: New method.
3072 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
3073 num_symtabs, symtabs>: Remove; move to
3074 type_unit_group_unshareable.
3075 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
3076 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
3077 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
3078
3079 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3080
3081 * dwarf2/read.h (struct dwarf2_per_cu_data):
3082 <dwarf2_per_objfile>: Remove.
3083 * dwarf2/read.c (create_cu_from_index_list): Don't assign
3084 dwarf2_per_objfile.
3085 (create_signatured_type_table_from_index): Likewise.
3086 (create_signatured_type_table_from_debug_names): Likewise.
3087 (create_debug_type_hash_table): Likewise.
3088 (fill_in_sig_entry_from_dwo_entry): Likewise.
3089 (create_type_unit_group): Likewise.
3090 (read_comp_units_from_section): Likewise.
3091 (create_cus_hash_table): Likewise.
3092
3093 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3094
3095 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
3096 dwarf2_per_cu_data::dwarf2_per_objfile.
3097 (compute_compunit_symtab_includes): Likewise.
3098 (dwarf2_cu::start_symtab): Likewise.
3099
3100 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3101
3102 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
3103 parameter.
3104 * dwarf2/read.c (get_die_type_at_offset): Likewise.
3105 (read_namespace_alias): Update.
3106 (lookup_die_type): Update.
3107 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
3108 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
3109 Update.
3110 (disassemble_dwarf_expression): Update.
3111
3112 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3113
3114 * dwarf2/read.h (struct dwarf2_queue_item): Add
3115 dwarf2_per_objfile parameter, assign new parameter.
3116 <per_objfile>: New field.
3117 * dwarf2/read.c (free_one_cached_comp_unit): Add
3118 dwarf2_per_objfile parameter.
3119 (queue_comp_unit): Likewise.
3120 (dw2_do_instantiate_symtab): Update.
3121 (process_psymtab_comp_unit): Update.
3122 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
3123 (process_imported_unit_die): Update.
3124 (queue_and_load_dwo_tu): Update.
3125 (follow_die_offset): Update.
3126 (follow_die_sig_1): Update.
3127
3128 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3129
3130 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
3131 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
3132 (read_call_site_scope): Assign per_objfile.
3133 (dwarf2_per_cu_data::objfile): Remove.
3134 * gdbtypes.h (struct call_site) <per_objfile>: New member.
3135 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
3136 dwarf2_per_objfile parameter.
3137 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
3138 dwarf2_per_objfile parameter.
3139 (dwarf_expr_reg_to_entry_parameter): Add output
3140 dwarf2_per_objfile parameter.
3141 (locexpr_get_frame_base): Update.
3142 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
3143 <push_dwarf_reg_entry_value>: Update.
3144 <call_site_to_target_addr>: Update.
3145 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
3146 parameter.
3147 (value_of_dwarf_reg_entry): Update.
3148 (rw_pieced_value): Update.
3149 (indirect_synthetic_pointer): Update.
3150 (dwarf2_evaluate_property): Update.
3151 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
3152 parameter.
3153 (locexpr_read_variable): Update.
3154 (locexpr_get_symbol_read_needs): Update.
3155 (loclist_read_variable): Update.
3156
3157 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3158
3159 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
3160 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
3161 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
3162 parameter.
3163 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
3164 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
3165 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
3166 parameter.
3167 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
3168 sect_variable_value): Add dwarf2_per_objfile parameter.
3169 (class dwarf_evaluate_loc_desc) <dwarf_call,
3170 dwarf_variable_value>: Update.
3171 (fetch_const_value_from_synthetic_pointer): Add
3172 dwarf2_per_objfile parameter.
3173 (fetch_const_value_from_synthetic_pointer): Update.
3174 (coerced_pieced_ref): Update.
3175 (class symbol_needs_eval_context) <dwarf_call,
3176 dwarf_variable_value>: Update.
3177 (dwarf2_compile_expr_to_ax): Update.
3178
3179 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3180
3181 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
3182 parameter.
3183 (dwarf2_evaluate_loc_desc_full): Update.
3184
3185 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3186
3187 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
3188 parameter.
3189 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
3190 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
3191 dwarf2_per_objfile parameter.
3192 (decode_debug_loc_dwo_addresses): Likewise.
3193 (dwarf2_find_location_expression): Update.
3194 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
3195 (locexpr_describe_location_piece): Add dwarf2_per_objfile
3196 parameter.
3197 (disassemble_dwarf_expression): Add dwarf2_per_objfile
3198 parameter.
3199 (locexpr_describe_location_1): Likewise.
3200 (locexpr_describe_location): Update.
3201
3202 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3203
3204 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
3205 Remove.
3206 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
3207 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
3208 (dwarf2_compile_property_to_c): Update.
3209 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
3210 use text offset from objfile.
3211 (locexpr_tracepoint_var_ref): Update.
3212 (locexpr_generate_c_location): Update.
3213 (loclist_describe_location): Update.
3214 (loclist_tracepoint_var_ref): Update.
3215 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
3216 dwarf2_per_objfile parameter.
3217 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
3218 use text offset from objfile.
3219 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
3220
3221 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3222
3223 * dwarf2/expr.h (struct dwarf_expr_context)
3224 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
3225 <offset>: Remove.
3226 <per_objfile>: New member.
3227 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
3228 dwarf2_per_objfile parameter. Don't set offset, set
3229 per_objfile.
3230 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
3231 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
3232 a dwarf2_per_objfile object instead of an offset.
3233 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
3234 constructor.
3235 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
3236 to dwarf2_expr_executor constructor. Don't set offset.
3237 (dwarf2_fetch_cfa_info): Update.
3238 (struct dwarf2_frame_cache) <text_offset>: Remove.
3239 <per_objfile>: New field.
3240 (dwarf2_frame_cache): Update.
3241 (dwarf2_frame_prev_register): Update.
3242 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3243 <dwarf_evaluate_loc_desc>: Add constructor.
3244 (dwarf2_evaluate_loc_desc_full): Update.
3245 (dwarf2_locexpr_baton_eval): Update.
3246 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
3247 Add constructor.
3248 (dwarf2_loc_desc_get_symbol_read_needs): Update.
3249
3250 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3251
3252 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
3253 addr_sized_int_type>: Move to dwarf2_cu.
3254 <int_type>: Move to dwarf2_per_objfile.
3255 (struct dwarf2_per_objfile) <int_type>: Move here.
3256 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
3257 addr_sized_int_type>: Move here.
3258 (read_func_scope): Update.
3259 (read_array_type): Update.
3260 (read_tag_string_type): Update.
3261 (attr_to_dynamic_prop): Update.
3262 (dwarf2_per_cu_data::int_type): Rename to...
3263 (dwarf2_per_objfile::int_type): ... this.
3264 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
3265 (dwarf2_cu::addr_sized_int_type): ... this.
3266 (read_subrange_type): Update.
3267 (dwarf2_per_cu_data::addr_type): Rename to...
3268 (dwarf2_cu::addr_type): ... this.
3269 (set_die_type): Update.
3270
3271 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3272
3273 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
3274 data through per_cu->cu.
3275
3276 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3277
3278 * dwarf2/read.c (lookup_dwo_comp_unit): Change
3279 dwarf2_per_cu_data parameter fo dwarf2_cu.
3280 (lookup_dwo_type_unit): Likewise.
3281 (read_cutu_die_from_dwo): Likewise.
3282 (lookup_dwo_unit): Likewise.
3283 (open_and_init_dwo_file): Likewise.
3284 (lookup_dwo_cutu): Likewise.
3285 (lookup_dwo_comp_unit): Likewise.
3286 (lookup_dwo_type_unit): Likewise.
3287 (cutu_reader::init_tu_and_read_dwo_dies): Update.
3288 (cutu_reader::cutu_reader): Update.
3289
3290 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3291
3292 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
3293 parameter.
3294 (process_full_type_unit): Likewise.
3295 (process_queue): Update.
3296
3297 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3298
3299 * dwarf2/read.c (recursively_compute_inclusions): Add
3300 dwarf2_per_objfile parameter.
3301 (compute_compunit_symtab_includes): Likewise.
3302 (process_cu_includes): Update.
3303
3304 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3305
3306 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
3307 parameter.
3308 (create_type_unit_group): Update.
3309 (process_psymtab_comp_unit_reader): Update.
3310 (build_type_psymtabs_reader): Update.
3311
3312 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3313
3314 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
3315 object through m_this_cu->cu.
3316
3317 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3318
3319 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
3320 the info parameter.
3321 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
3322
3323 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3324
3325 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
3326 per_objfile parameter.
3327 (load_full_type_unit): Add per_objfile parameter.
3328 (read_signatured_type): Likewise.
3329 (load_full_comp_unit): Likewise.
3330 (load_cu): Likewise.
3331 (dw2_do_instantiate_symtab): Likewise.
3332 (dw2_get_file_names): Likewise.
3333 (dw2_map_symtabs_matching_filename): Update.
3334 (dw_expand_symtabs_matching_file_matcher): Update.
3335 (dw2_map_symbol_filenames): Update.
3336 (process_psymtab_comp_unit): Add per_objfile parameter.
3337 (build_type_psymtabs_1): Update.
3338 (process_skeletonless_type_unit): Update.
3339 (dwarf2_build_psymtabs_hard): Update.
3340 (load_partial_comp_unit): Add per_objfile parameter.
3341 (scan_partial_symbols): Update.
3342 (load_full_comp_unit): Add per_objfile parameter.
3343 (process_imported_unit_die): Update.
3344 (create_cus_hash_table): Update.
3345 (find_partial_die): Update.
3346 (dwarf2_read_addr_index): Update.
3347 (follow_die_offset): Update.
3348 (dwarf2_fetch_die_loc_sect_off): Update.
3349 (dwarf2_fetch_constant_bytes): Update.
3350 (dwarf2_fetch_die_type_sect_off): Update.
3351 (follow_die_sig_1): Update.
3352 (load_full_type_unit): Add per_objfile parameter.
3353 (read_signatured_type): Likewise.
3354
3355 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3356
3357 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
3358 of objfile_name.
3359
3360 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3361
3362 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
3363 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
3364 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
3365 field.
3366 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
3367 (create_cus_from_index): Update.
3368 (dwarf2_read_gdb_index): Update.
3369 (create_cus_from_debug_names): Update.
3370 (dwarf2_read_debug_names): Update.
3371 (get_abbrev_section_for_cu): Update.
3372 (create_all_comp_units): Update.
3373 (read_attribute_value): Update.
3374 (get_debug_line_section): Update.
3375 * dwarf2/index-cache.c (index_cache::store): Update.
3376 * dwarf2/index-write.c (save_gdb_index_command): Update.
3377 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
3378
3379 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3380
3381 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
3382 member.
3383 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
3384 dwarf2_per_cu_data::per_bfd.
3385 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
3386 (create_type_unit_group): Likewise.
3387 (queue_comp_unit): Remove reference to
3388 per_cu->dwarf2_per_objfile.
3389 (maybe_queue_comp_unit): Likewise.
3390 (fill_in_sig_entry_from_dwo_entry): Assign new field.
3391 (create_cus_hash_table): Assign new field.
3392
3393 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3394
3395 * dwarf2/read.c: Replace
3396 dwarf2_cu->per_cu->dwarf2_per_objfile references with
3397 dwarf2_cu->per_objfile throughout.
3398
3399 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3400
3401 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
3402 parameter, don't use per_cu->dwarf2_per_objfile.
3403 (dw2_instantiate_symtab): Likewise.
3404 (dw2_find_last_source_symtab): Update.
3405 (dw2_map_expand_apply): Update.
3406 (dw2_lookup_symbol): Update.
3407 (dw2_expand_symtabs_for_function): Update.
3408 (dw2_expand_all_symtabs): Update.
3409 (dw2_expand_symtabs_with_fullname): Update.
3410 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
3411 don't use per_cu->dwarf2_per_objfile.
3412 (dw2_expand_marked_cus): Update.
3413 (dw2_find_pc_sect_compunit_symtab): Update.
3414 (dw2_debug_names_lookup_symbol): Update.
3415 (dw2_debug_names_expand_symtabs_for_function): Update.
3416 (dw2_debug_names_map_matching_symbols): Update.
3417 (dwarf2_psymtab::expand_psymtab): Update.
3418
3419 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3420
3421 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
3422 <per_objfile>: New member.
3423 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
3424 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
3425 call to dwarf2_cu.
3426 (cutu_reader::cutu_reader): Update.
3427 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
3428
3429 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3430
3431 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
3432 struct dwarf2_per_objfile.
3433 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
3434 dwarf2_per_bfd.
3435 * dwarf2/read.c (set_die_type): Update.
3436 (get_die_type_at_offset): Update.
3437
3438 2020-05-27 Tom Tromey <tom@tromey.com>
3439 Simon Marchi <simon.marchi@efficios.com>
3440
3441 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
3442 method.
3443 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
3444 get_symtab, set_symtab>: New methods.
3445 <m_symtabs>: New field.
3446 (struct dwarf2_psymtab): Derive from partial_symtab.
3447 <readin_p, get_compunit_symtab>: Declare methods.
3448 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
3449 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
3450 New methods.
3451 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
3452 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
3453 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
3454 (dw2_symtab_iter_next, dw2_print_stats)
3455 (dw2_expand_symtabs_with_fullname)
3456 (dw2_expand_symtabs_matching_one)
3457 (dw_expand_symtabs_matching_file_matcher)
3458 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
3459 (dw2_debug_names_iterator::next)
3460 (dw2_debug_names_map_matching_symbols)
3461 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
3462 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
3463 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
3464 New methods.
3465 (get_compunit_symtab, process_full_comp_unit)
3466 (process_full_type_unit): Update.
3467 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
3468
3469 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3470
3471 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
3472 then introduce a new dwarf2_per_objfile type.
3473 <read_line_string>: Move to the new dwarf2_per_objfile type.
3474 <objfile>: Likewise.
3475 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
3476 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
3477 dwarf2_per_objfile->per_bfd.
3478 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
3479 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
3480 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
3481 (dwarf2_per_bfd::free_cached_comp_units): ... this.
3482 (dwarf2_has_info): Allocate dwarf2_per_bfd.
3483 (dwarf2_per_objfile::locate_sections): Rename to...
3484 (dwarf2_per_bfd::locate_sections): ... this.
3485 (dwarf2_per_objfile::get_cutu): Rename to...
3486 (dwarf2_per_bfd::get_cutu): ... this.
3487 (dwarf2_per_objfile::get_cu): Rename to...
3488 (dwarf2_per_bfd::get_cu): ... this.
3489 (dwarf2_per_objfile::get_tu): Rename to...
3490 (dwarf2_per_bfd::get_tu): ... this.
3491 (dwarf2_per_objfile::allocate_per_cu): Rename to...
3492 (dwarf2_per_bfd::allocate_per_cu): ... this.
3493 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
3494 (dwarf2_per_bfd::allocate_signatured_type): ... this.
3495 (get_gdb_index_contents_ftype): Change parameter from
3496 dwarf2_per_objfile to dwarf2_per_bfd.
3497 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
3498 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
3499
3500 2020-05-27 Tom Tromey <tom@tromey.com>
3501 Simon Marchi <simon.marchi@efficios.com>
3502
3503 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
3504 (allocate_piece_closure): Set "per_objfile" member.
3505 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
3506 (locexpr_describe_location, loclist_describe_location): Use new
3507 member.
3508 * dwarf2/read.c (read_call_site_scope)
3509 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
3510 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
3511 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
3512 handle_data_member_location): Set per_objfile member.
3513 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
3514 member.
3515 (struct dwarf2_loclist_baton) <per_objfile>: New member.
3516
3517 2020-05-27 Tom Tromey <tom@tromey.com>
3518
3519 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
3520 allocate_signatured_type>: Declare new methods.
3521 <m_num_psymtabs>: New member.
3522 (struct dwarf2_per_cu_data) <index>: New member.
3523 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
3524 (dwarf2_per_objfile::allocate_signatured_type): New methods.
3525 (create_cu_from_index_list): Use allocate_per_cu.
3526 (create_signatured_type_table_from_index)
3527 (create_signatured_type_table_from_debug_names)
3528 (create_debug_type_hash_table, add_type_unit)
3529 (read_comp_units_from_section): Use allocate_signatured_type.
3530
3531 2020-05-27 Tom Tromey <tom@tromey.com>
3532
3533 * psymtab.c (partial_map_expand_apply)
3534 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
3535 (psym_lookup_global_symbol_language)
3536 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
3537 (psym_print_stats, psym_expand_symtabs_for_function)
3538 (psym_map_symbol_filenames, psym_map_matching_symbols)
3539 (psym_expand_symtabs_matching)
3540 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
3541 (maintenance_check_psymtabs): Update.
3542 * psympriv.h (struct partial_symtab) <readin_p,
3543 get_compunit_symtab>: Add objfile parameter.
3544 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
3545 Likewise.
3546 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
3547 get_compunit_symtab>: Likewise.
3548 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
3549
3550 2020-05-27 Tom Tromey <tom@tromey.com>
3551
3552 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
3553 member.
3554 * dwarf2/read.c (delete_file_name_entry): Fix comment.
3555 (create_cu_from_index_list)
3556 (create_signatured_type_table_from_index)
3557 (create_signatured_type_table_from_debug_names)
3558 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
3559 (dwarf2_create_include_psymtab)
3560 (create_debug_type_hash_table, add_type_unit)
3561 (create_type_unit_group, read_comp_units_from_section)
3562 (dwarf2_compute_name, create_cus_hash_table)
3563 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
3564 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
3565 obstack.
3566 (dw2_get_real_path): Likewise. Change argument to
3567 dwarf2_per_objfile.
3568
3569 2020-05-27 Luis Machado <luis.machado@linaro.org>
3570
3571 PR tdep/26000
3572 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
3573 for ldrd (immediate).
3574
3575 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3576
3577 * command.h: Add comment giving the name of class_tui.
3578 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
3579 create the fake command for the help for class_tui.
3580
3581 2020-05-26 Tom Tromey <tromey@adacore.com>
3582
3583 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
3584 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
3585 (val_atr): New function.
3586 (value_val_atr): Use it.
3587 * ada-valprint.c (print_optional_low_bound): Change low bound
3588 handling for enums.
3589 (val_print_packed_array_elements): Don't call discrete_position.
3590 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
3591 discrete_position for enum types.
3592 * language.c (default_print_array_index): Change type.
3593 * language.h (struct language_defn) <la_print_array_index>: Add
3594 index_type parameter, change type of index_value.
3595 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
3596 (default_print_array_index): Update.
3597 * valprint.c (maybe_print_array_index): Don't call
3598 value_from_longest. Update.
3599 (value_print_array_elements): Don't call discrete_position.
3600
3601 2020-05-26 Tom Tromey <tromey@adacore.com>
3602
3603 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
3604 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
3605
3606 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
3607
3608 PR gdb/13519
3609 * avr-tdep.c (avr_integer_to_address): Return data or code
3610 address accordingly to the second 'type' argument of the
3611 function.
3612
3613 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
3614
3615 * infcmd.c, inferior.h: (construct_inferior_arguments):
3616 Moved function from here to gdbsupport/common-inferior.{h,cc}
3617
3618 2020-05-23 Tom Tromey <tom@tromey.com>
3619
3620 Revert commit eca1f90c:
3621 * NEWS: Remove entry for completion styling.
3622 * completer.c (_rl_completion_prefix_display_length): Move
3623 declaration later.
3624 (gdb_fnprint): Revert.
3625 (gdb_display_match_list_1): Likewise.
3626 * cli/cli-style.c (completion_prefix_style)
3627 (completion_difference_style, completion_suffix_style): Remove.
3628 (_initialize_cli_style): Revert.
3629 * cli/cli-style.h (completion_prefix_style)
3630 (completion_difference_style, completion_suffix_style): Don't
3631 declare.
3632
3633 2020-05-24 Pedro Alves <palves@redhat.com>
3634
3635 * symtab.c (completion_list_add_name): Return boolean indication
3636 of whether the symbol matched.
3637 (completion_list_add_symbol): Don't try to remove C++ aliases if
3638 the symbol didn't match in the first place.
3639 * symtab.h (completion_list_add_name): Return bool.
3640
3641 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
3642
3643 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
3644 type::field.
3645
3646 2020-05-23 Joel Brobecker <brobecker@adacore.com>
3647
3648 GDB 9.2 released.
3649
3650 2020-05-23 Tom Tromey <tom@tromey.com>
3651
3652 * NEWS: Add entry for completion styling.
3653 * completer.c (_rl_completion_prefix_display_length): Move
3654 declaration earlier.
3655 (gdb_fnprint): Use completion_style.
3656 (gdb_display_match_list_1): Likewise.
3657 * cli/cli-style.c (completion_prefix_style)
3658 (completion_difference_style, completion_suffix_style): New
3659 globals.
3660 (_initialize_cli_style): Register new globals.
3661 * cli/cli-style.h (completion_prefix_style)
3662 (completion_difference_style, completion_suffix_style): Declare.
3663
3664 2020-05-23 Pedro Alves <palves@redhat.com>
3665
3666 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
3667 (parse_escape): Use ISDIGIT instead of isdigit.
3668 (puts_debug): Use gdb_isprint instead of isprint.
3669 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
3670 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
3671 ISSPACE instead of isspace.
3672 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
3673 instead of isspace.
3674 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
3675 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
3676 instead of isxdigit and ISDIGIT instead of isdigit.
3677
3678 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3679
3680 * gdbtypes.h (struct type) <field>: New method.
3681 (TYPE_FIELDS): Remove, replace all uses with either type::fields
3682 or type::field.
3683
3684 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3685
3686 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
3687 (TYPE_FIELDS): Use type::fields. Change all call sites that
3688 modify the propery to use type::set_fields instead.
3689
3690 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3691
3692 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
3693 type::num_fields instead.
3694
3695 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3696
3697 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
3698 methods.
3699 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
3700 that modify the number of fields to use type::set_num_fields
3701 instead.
3702
3703 2020-05-22 Tom Tromey <tromey@adacore.com>
3704
3705 * compile/compile-object-load.h (munmap_list_free): Don't
3706 declare.
3707
3708 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
3709
3710 * annotate.c (annotate_source_line): Update return type, add call
3711 to update current symtab and line.
3712 * annotate.h (annotate_source_line): Update return type, and
3713 extend header comment.
3714 * source.c (info_line_command): Check annotation_level before
3715 calling annotate_source_line.
3716 * stack.c (print_frame_info): If calling annotate_source_line
3717 returns true, then don't print any other source line information.
3718
3719 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
3720
3721 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
3722
3723 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
3724
3725 * coffread.c (patch_type): Remove NULL check before xfree.
3726 * corefile.c (set_gnutarget): Likewise.
3727 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
3728 * exec.c (build_section_table): Likewise.
3729 * remote.c (remote_target::pass_signals): Likewise.
3730 * utils.c (n_spaces): Likewise.
3731 * cli/cli-script.c (document_command): Likewise.
3732 * i386-windows-tdep.c (core_process_module_section): Likewise.
3733 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
3734
3735 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
3736
3737 * symfile.c (reread_symbols): Clear objfile's section_offsets
3738 vector and section indices, re-compute them by calling
3739 sym_offsets.
3740
3741 2020-05-20 Tom Tromey <tromey@adacore.com>
3742
3743 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
3744 (desc_one_bound, desc_index_type): Compute field name.
3745
3746 2020-05-20 Tom de Vries <tdevries@suse.de>
3747
3748 PR symtab/25833
3749 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
3750
3751 2020-05-20 Alan Modra <amodra@gmail.com>
3752
3753 PR 25993
3754 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
3755 bfd_set_filename.
3756 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
3757 passed to bfd_set_filename.
3758 * symfile-mem.c (add_vsyscall_page): Likewise for string
3759 passed to symbol_file_add_from_memory.
3760 (symbol_file_add_from_memory): Make name param a const char* and
3761 don't strdup.
3762
3763 2020-05-20 Alan Modra <amodra@gmail.com>
3764
3765 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
3766 rather than accessing bfd->filename directly.
3767 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
3768 and use bfd_section_name.
3769 * dwarf2/frame.c (decode_frame_entry): Likewise.
3770 * exec.c (exec_set_section_address): Likewise.
3771 * solib-aix.c (solib_aix_bfd_open): Likewise.
3772 * stap-probe.c (get_stap_base_address): Likewise.
3773 * symfile.c (reread_symbols): Likewise.
3774
3775 2020-05-19 Tom Tromey <tromey@adacore.com>
3776
3777 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
3778
3779 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3780
3781 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
3782
3783 2020-05-19 Pedro Alves <palves@redhat.com>
3784
3785 * NEWS (set exec-file-mismatch): Adjust entry.
3786 * exec.c: Include "build-id.h".
3787 (validate_exec_file): Try to match build IDs instead of filenames.
3788 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
3789 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
3790 and pass down 'warn_if_slow'.
3791 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
3792 gdb_bfd_open_closure to pass it down.
3793 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
3794
3795 2020-05-19 Pedro Alves <palves@redhat.com>
3796
3797 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
3798 * target.c (target_fileio_open_1): Rename to target_fileio_open
3799 and make extern. Use bool.
3800 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
3801 (target_fileio_read_alloc_1): Adjust.
3802 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
3803 (target_fileio_open_warn_if_slow): Delete declaration.
3804
3805 2020-05-19 Pedro Alves <palves@redhat.com>
3806
3807 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
3808 Adjust all callers.
3809
3810 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
3811
3812 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
3813 whether disp is negative.
3814
3815 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3816
3817 * symfile.h (struct symfile_segment_data)
3818 <~symfile_segment_data>: Remove.
3819 <segment_info>: Change to std::vector.
3820 * symfile.c (default_symfile_segments): Update.
3821 * elfread.c (elf_symfile_segments): Update.
3822
3823 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3824
3825 * symfile.h (struct symfile_segment_data) <struct segment>: New.
3826 <segments>: New.
3827 <segment_bases, segment_sizes>: Remove.
3828 * symfile.c (default_symfile_segments): Update.
3829 * elfread.c (elf_symfile_segments): Update.
3830 * remote.c (remote_target::get_offsets): Update.
3831 * solib-target.c (solib_target_relocate_section_addresses):
3832 Update.
3833
3834 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3835
3836 * symfile.h (struct symfile_segment_data): Initialize fields.
3837 <~symfile_segment_data>: Add.
3838 (symfile_segment_data_up): New.
3839 (struct sym_fns) <sym_segments>: Return a
3840 symfile_segment_data_up.
3841 (default_symfile_segments): Return a symfile_segment_data_up.
3842 (free_symfile_segment_data): Remove.
3843 (get_symfile_segment_data): Return a symfile_segment_data_up.
3844 * symfile.c (default_symfile_segments): Likewise.
3845 (get_symfile_segment_data): Likewise.
3846 (free_symfile_segment_data): Remove.
3847 (symfile_find_segment_sections): Update.
3848 * elfread.c (elf_symfile_segments): Return a
3849 symfile_segment_data_up.
3850 * remote.c (remote_target::get_offsets): Update.
3851 * solib-target.c (solib_target_relocate_section_addresses):
3852 Update.
3853 * symfile-debug.c (debug_sym_segments): Return a
3854 symfile_segment_data_up.
3855
3856 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3857
3858 PR build/25981
3859 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
3860 Hardcode register numbers.
3861
3862 PR build/25981
3863 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
3864 procfs_find_LDT_entry): Remove.
3865 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
3866 procfs_find_LDT_entry): Remove.
3867 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
3868 Remove.
3869
3870 2020-05-17 Pedro Alves <palves@redhat.com>
3871 Andrew Burgess <andrew.burgess@embecosm.com>
3872 Keno Fischer <keno@juliacomputing.com>
3873
3874 PR gdb/25741
3875 * breakpoint.c (build_target_condition_list): Update comments.
3876 (build_target_command_list): Update comments and skip matching
3877 locations.
3878 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
3879 a separate function. Simplify "set breakpoint auto-hw off"
3880 handling.
3881 (insert_breakpoints): Update comment.
3882 (tracepoint_locations_match): New parameter. For breakpoints,
3883 compare location types too, if the caller wants to.
3884 (handle_automatic_hardware_breakpoints): New functions.
3885 (bp_location_is_less_than): Also sort by location type and
3886 hardware breakpoint length.
3887 (update_global_location_list): Handle "set breakpoint auto-hw on"
3888 here.
3889 (update_breakpoint_locations): Ask breakpoint_locations_match to
3890 ignore location types.
3891
3892 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3893
3894 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
3895 type::name instead.
3896
3897 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3898
3899 * gdbtypes.h (struct type) <name, set_name>: New methods.
3900 (TYPE_CODE): Use type::name. Change all call sites used to set
3901 the name to use type::set_name instead.
3902
3903 2020-05-16 Tom Tromey <tom@tromey.com>
3904
3905 * top.c (quit_force): Update.
3906 * infrun.c (handle_no_resumed): Update.
3907 * top.h (all_uis): New function.
3908 (ALL_UIS): Remove.
3909
3910 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3911
3912 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
3913
3914 2020-05-16 Pedro Alves <palves@redhat.com>
3915
3916 * ia64-linux-nat.c
3917 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
3918 Declare method.
3919 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
3920
3921 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
3922
3923 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
3924 (sparc64_adi_info): Likewise.
3925
3926 2020-05-15 Tom Tromey <tom@tromey.com>
3927
3928 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
3929 block_objfile.
3930 (lookup_objfile_from_block): Remove.
3931 (lookup_symbol_in_block, lookup_symbol_in_static_block)
3932 (lookup_global_symbol): Use block_objfile.
3933 * symtab.h (lookup_objfile_from_block): Don't declare.
3934 * printcmd.c (clear_dangling_display_expressions): Use
3935 block_objfile.
3936 * parse.c (operator_check_standard): Use block_objfile.
3937
3938 2020-05-15 Tom Tromey <tom@tromey.com>
3939
3940 * language.c (language_alloc_type_symbol): Set
3941 SYMBOL_SECTION.
3942 * symtab.c (initialize_objfile_symbol): Remove.
3943 (allocate_symbol): Remove.
3944 (allocate_template_symbol): Remove.
3945 * dwarf2/read.c (fixup_go_packaging): Use "new".
3946 (new_symbol): Use "new".
3947 (read_variable): Don't call initialize_objfile_symbol. Use
3948 "new".
3949 (read_func_scope): Use "new".
3950 * xcoffread.c (process_xcoff_symbol): Don't call
3951 initialize_objfile_symbol.
3952 (SYMBOL_DUP): Remove.
3953 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
3954 "new".
3955 * symtab.h (allocate_symbol, initialize_objfile_symbol)
3956 (allocate_template_symbol): Don't declare.
3957 (struct symbol): Add copy constructor. Change defaults.
3958 * jit.c (finalize_symtab): Use "new".
3959 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
3960 Use "new".
3961 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
3962 (common_block_end): Use "new".
3963 * mdebugread.c (parse_symbol): Use "new".
3964 (new_symbol): Likewise.
3965
3966 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3967
3968 * NEWS: Mention changes to help and apropos.
3969
3970 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3971
3972 * command.h (enum command_class): Improve comments, document
3973 that class_alias is for user-defined aliases, give the class
3974 name for each class, remove unused class_xdb.
3975 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
3976 * breakpoint.c (_initialize_breakpoint): Replace class_alias
3977 by a precise class.
3978 * infcmd.c (_initialize_infcmd): Likewise.
3979 * reverse.c (_initialize_reverse): Likewise.
3980 * stack.c (_initialize_stack): Likewise.
3981 * symfile.c (_initialize_symfile): Likewise.
3982 * tracepoint.c (_initialize_tracepoint): Likewise.
3983
3984 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3985
3986 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
3987 when their aliased command is traversed.
3988 (help_cmd): Add fput_command_names_styled call to
3989 output command name and aliases when command has an alias.
3990
3991 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3992
3993 * cli/cli-decode.h (help_cmd_list): Remove declaration.
3994 * cli/cli-decode.c (help_cmd_list): Declare as static,
3995 remove prefix argument, use bool for recurse arg, rework to show the aliases of
3996 a command together with the command.
3997 (fput_command_name_styled, fput_command_names_styled): New functions.
3998 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
3999 fput_command_name_styled.
4000 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
4001 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
4002
4003 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4004
4005 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
4006 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
4007 * command.h (cmd_show_list): Likewise.
4008 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
4009 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
4010
4011 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4012
4013 * unittests/command-def-selftests.c (traverse_command_structure):
4014 Verify all commands of a list have the same prefix command and
4015 that only the top cmdlist commands have a null prefix.
4016
4017 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4018
4019 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
4020 as prefix, not one of its aliases.
4021 (set_cmd_prefix): Remove.
4022 (do_add_cmd): Centralize the setting of the prefix of a command, when
4023 command is defined after its full chain of prefix commands.
4024 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
4025 (add_setshow_cmd_full): Likewise.
4026 (update_prefix_field_of_prefixed_commands): New function.
4027 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
4028 update_prefix_field_of_prefixed_commands.
4029 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
4030 addresses of remote_set_cmdlist and remote_show_cmdlist given
4031 as argument, not the address of an argument.
4032 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
4033 * gdb/remote.c (_initialize_remote): Likewise.
4034
4035 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4036
4037 * cli/cli-cmds.c (alias_command): Check for an existing alias
4038 using lookup_cmd_composition, as valid_command_p is too strict
4039 and forbids aliases that are the prefix of an existing alias
4040 or command.
4041 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
4042 command is properly recognised as a valid command.
4043
4044 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4045
4046 * unittests/help-doc-selftests.c: Rename to
4047 unittests/command-def-selftests.c
4048 * unittests/command-def-selftests.c (help_doc_tests): Update some
4049 comments.
4050 (command_structure_tests, traverse_command_structure): New namespace
4051 and function.
4052 (command_structure_invariants_tests): New function.
4053 (_initialize_command_def_selftests) Renamed from
4054 _initialize_help_doc_selftests, register command_structure_invariants
4055 selftest.
4056
4057 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4058
4059 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
4060 an alias of 'show'.
4061
4062 2020-05-15 Joel Brobecker <brobecker@adacore.com>
4063
4064 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
4065 ada_is_fixed_point_type. Update all callers.
4066 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
4067 all callers.
4068 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
4069 Update all callers.
4070 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
4071 print_fixed_point_type. Update all callers.
4072 * ada-valprint.c (ada_value_print_num): Replace call to
4073 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
4074
4075 2020-05-14 Kevin Buettner <kevinb@redhat.com>
4076
4077 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
4078 processors.
4079 (cpu_supports_bts): Add CV_AMD case.
4080
4081 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
4082 Simon Marchi <simon.marchi@efficios.com>
4083
4084 * infrun.c (stop_all_threads): Collect multiple wait events at
4085 each pass.
4086
4087 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
4088
4089 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
4090 type::code instead.
4091
4092 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
4093
4094 * gdbtypes.h (struct type) <code, set_code>: New methods.
4095 (TYPE_CODE): Use type::code. Change all call sites used to set
4096 the code to use type::set_code instead.
4097
4098 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4099 Tom de Vries <tdevries@suse.de>
4100 Pedro Alves <palves@redhat.com>
4101
4102 PR threads/25478
4103 * infrun.c (stop_all_threads): Do NOT ignore
4104 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
4105 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
4106 received.
4107 (handle_no_resumed): Remove code handling a live inferior with no
4108 threads.
4109 * remote.c (has_single_non_exited_thread): New.
4110 (remote_target::update_thread_list): Do not delete a thread if is
4111 the last thread of the process.
4112 * thread.c (thread_select): Call delete_exited_threads instead of
4113 prune_threads.
4114
4115 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4116
4117 * infrun.c (stop_all_threads): Enable/disable thread events of all
4118 targets. Move a debug message denoting the end of the function
4119 into the SCOPED_EXIT block.
4120
4121 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4122
4123 * process-stratum-target.h: Include <set>.
4124 (all_non_exited_process_targets, switch_to_target_no_thread): New
4125 function declarations.
4126 * process-stratum-target.c (all_non_exited_process_targets)
4127 (switch_to_target_no_thread): New function implementations.
4128
4129 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4130
4131 * infrun.c (handle_inferior_event): Extract out a piece of code
4132 into...
4133 (mark_non_executing_threads): ...this new function.
4134
4135 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4136
4137 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
4138 use.
4139
4140 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4141
4142 * regcache.c (regcache_read_pc_protected): New function
4143 implementation that returns 0 if the PC cannot read via
4144 'regcache_read_pc'.
4145 * infrun.c (proceed): Call 'regcache_read_pc_protected'
4146 instead of 'regcache_read_pc'.
4147 (keep_going_pass_signal): Ditto.
4148
4149 2020-05-13 Tom Tromey <tromey@adacore.com>
4150
4151 * ada-lang.c (align_value): Remove.
4152 (ada_template_to_fixed_record_type_1): Use align_up.
4153
4154 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4155
4156 * async-event.c: Update the copyright year.
4157 * async-event.h: Update the copyright year.
4158
4159 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
4160
4161 * objfiles.h (is_addr_in_objfile,
4162 shared_objfile_contains_address_p): Return bool.
4163 * objfile.c (is_addr_in_objfile,
4164 shared_objfile_contains_address_p): Return bool.
4165
4166 2020-05-11 Tom Tromey <tromey@adacore.com>
4167
4168 * cli/cli-cmds.c (info_command): Restore.
4169 (_initialize_cli_cmds): Use add_prefix_command for "info".
4170 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
4171
4172 2020-05-11 Tom Tromey <tromey@adacore.com>
4173
4174 * ada-lang.c (ada_value_primitive_field): Now public.
4175 * ada-lang.h (ada_value_primitive_field): Declare.
4176 * ada-valprint.c (print_field_values): Use
4177 ada_value_primitive_field for wrapper fields.
4178
4179 2020-05-11 Tom de Vries <tdevries@suse.de>
4180
4181 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
4182 MODULE_DOMAIN.
4183
4184 2020-05-11 Tom de Vries <tdevries@suse.de>
4185
4186 PR symtab/25941
4187 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
4188 with length 0, if not gdb-produced.
4189 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
4190
4191 2020-05-09 Tom de Vries <tdevries@suse.de>
4192
4193 PR gdb/25955
4194 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
4195 calculation.
4196
4197 2020-05-09 Tom Tromey <tom@tromey.com>
4198
4199 * top.c (server_command): Now bool.
4200 * top.h (server_command): Now bool.
4201
4202 2020-05-08 Tom Tromey <tromey@adacore.com>
4203
4204 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
4205 already being processed.
4206
4207 2020-05-08 Tom Tromey <tom@tromey.com>
4208
4209 * printcmd.c (struct display) <next>: Remove.
4210 <display>: New constructor.
4211 <exp_string>: Now a std::string.
4212 <enabled_p>: Now a bool.
4213 (display_number): Move definition earlier.
4214 (displays): Rename from display_chain. Now a std::vector.
4215 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
4216 (display_command): Update.
4217 (do_one_display, disable_display)
4218 (enable_disable_display_command, do_enable_disable_display):
4219 Update.
4220 (free_display): Remove.
4221 (clear_displays): Rewrite.
4222 (delete_display): Update.
4223 (map_display_numbers): Use function_view. Remove "data"
4224 parameter. Update.
4225 (do_delete_display): Remove.
4226 (undisplay_command): Update.
4227 (do_one_display, do_displays, disable_display)
4228 (info_display_command): Update.
4229 (do_enable_disable_display): Remove.
4230 (enable_disable_display_command)
4231 (clear_dangling_display_expressions): Update.
4232
4233 2020-05-08 Tom Tromey <tom@tromey.com>
4234
4235 * symtab.c (set_symbol_cache_size)
4236 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
4237 (maintenance_print_symbol_cache_statistics): Update.
4238 * symmisc.c (print_symbol_bcache_statistics)
4239 (print_objfile_statistics, maintenance_print_objfiles)
4240 (maintenance_info_symtabs, maintenance_check_symtabs)
4241 (maintenance_expand_symtabs, maintenance_info_line_tables):
4242 Update.
4243 * symfile-debug.c (set_debug_symfile): Update.
4244 * source.c (forget_cached_source_info): Update.
4245 * python/python.c (gdbpy_progspaces): Update.
4246 * psymtab.c (maintenance_info_psymtabs): Update.
4247 * probe.c (parse_probes): Update.
4248 * linespec.c (iterate_over_all_matching_symtabs)
4249 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
4250 * guile/scm-progspace.c (gdbscm_progspaces): Update.
4251 * exec.c (exec_target::close): Update.
4252 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
4253 * breakpoint.c (print_one_breakpoint_location)
4254 (create_longjmp_master_breakpoint)
4255 (create_std_terminate_master_breakpoint): Update.
4256 * progspace.c (program_spaces): Now a std::vector.
4257 (maybe_new_address_space): Update.
4258 (add_program_space): Remove.
4259 (program_space::program_space): Update.
4260 (remove_program_space): Update.
4261 (number_of_program_spaces): Remove.
4262 (print_program_space, update_address_spaces): Update.
4263 * progspace.h (program_spaces): Change type.
4264 (ALL_PSPACES): Remove.
4265 (number_of_program_spaces): Don't declare.
4266 (struct program_space) <next>: Remove.
4267
4268 2020-05-08 Tom Tromey <tom@tromey.com>
4269
4270 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
4271 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
4272 (enable_break): Update.
4273 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
4274 (frv_fdpic_find_canonical_descriptor): Update.
4275 (frv_fetch_objfile_link_map): Update.
4276 * progspace.c (program_space::free_all_objfiles): Update.
4277 (program_space::solibs): New method.
4278 * progspace.h (struct program_space) <solibs>: New method.
4279 * solist.h (master_so_list): Don't declare.
4280 (ALL_SO_LIBS): Remove.
4281 * solib.h (so_list_head): Remove.
4282 (update_solib_list): Update comment.
4283 * solib.c (master_so_list): Remove.
4284 (solib_used, update_solib_list, solib_add)
4285 (info_sharedlibrary_command, clear_solib)
4286 (reload_shared_libraries_1, remove_user_added_objfile): Update.
4287
4288 2020-05-08 Tom Tromey <tom@tromey.com>
4289
4290 * extension.c (extension_languages): Now a std::array.
4291 (ALL_EXTENSION_LANGUAGES): Remove.
4292 (get_ext_lang_defn, get_ext_lang_of_file)
4293 (eval_ext_lang_from_control_command): Update.
4294 (finish_ext_lang_initialization)
4295 (auto_load_ext_lang_scripts_for_objfile)
4296 (ext_lang_type_printers::ext_lang_type_printers)
4297 (apply_ext_lang_type_printers)
4298 (ext_lang_type_printers::~ext_lang_type_printers)
4299 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
4300 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
4301 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
4302 (get_matching_xmethod_workers, ext_lang_colorize)
4303 (ext_lang_before_prompt): Update.
4304 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
4305
4306 2020-05-08 Tom Tromey <tom@tromey.com>
4307
4308 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
4309 overload.
4310 <swap_string, m_string>: Remove.
4311 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
4312 Update.
4313 * stabsread.c (define_symbol, read_type): Update.
4314 * linespec.c (find_linespec_symbols): Update.
4315 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
4316 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
4317 * dbxread.c (read_dbx_symtab): Update.
4318 * cp-support.h (cp_canonicalize_string_full)
4319 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
4320 Return unique_xmalloc_ptr.
4321 * cp-support.c (inspect_type): Update.
4322 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
4323 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
4324 Likewise.
4325 * c-typeprint.c (print_name_maybe_canonical): Update.
4326 * break-catch-throw.c (check_status_exception_catchpoint):
4327 Update.
4328
4329 2020-05-08 Tom de Vries <tdevries@suse.de>
4330
4331 * infrun.c (follow_fork): Copy current_line and current_symtab to
4332 child thread.
4333
4334 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4335
4336 * async-event.c (struct async_signal_handler, struct
4337 async_event_handler): Reformat, remove typedef.
4338
4339 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4340
4341 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
4342 access thistype->main_type->dyn_prop_list directly.
4343
4344 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4345
4346 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
4347 (remove_dyn_prop): Remove. Update all users to use
4348 type::remove_dyn_prop.
4349 * gdbtypes.c (remove_dyn_prop): Rename to...
4350 (type::remove_dyn_prop): ... this.
4351
4352 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
4353
4354 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
4355 (add_dyn_prop): Remove. Update all users to use
4356 type::add_dyn_prop.
4357 * gdbtypes.c (add_dyn_prop): Rename to...
4358 (type::add_dyn_prop): ... this.
4359
4360 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4361
4362 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
4363 (get_dyn_prop): Remove. Update all users to use
4364 type::dyn_prop.
4365 * gdbtypes.c (get_dyn_prop): Rename to...
4366 (type::dyn_prop): ... this.
4367
4368 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
4369
4370 * gdbtypes.h (struct main_type) <flag_static>: Remove.
4371
4372 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
4373
4374 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
4375 instruction, skip it if it's there.
4376
4377 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
4378
4379 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
4380
4381 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
4382
4383 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
4384 * gdbtypes.c (recursive_dump_type): Remove use of
4385 TYPE_INCOMPLETE.
4386
4387 2020-05-03 Tom Tromey <tom@tromey.com>
4388
4389 * breakpoint.c (catch_command, tcatch_command): Remove.
4390 (_initialize_breakpoint): Use add_basic_prefix_cmd,
4391 add_show_prefix_cmd.
4392 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
4393 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4394 Remove.
4395 (add_internal_problem_command): Use add_basic_prefix_cmd,
4396 add_show_prefix_cmd.
4397 * mips-tdep.c (set_mipsfpu_command): Remove.
4398 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
4399 * dwarf2/index-cache.c (set_index_cache_command): Remove.
4400 (_initialize_index_cache): Use add_basic_prefix_cmd.
4401 * memattr.c (dummy_cmd): Remove.
4402 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
4403 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
4404 (_initialize_tui_win): Use add_basic_prefix_cmd,
4405 add_show_prefix_cmd.
4406 * cli/cli-logging.c (set_logging_command): Remove.
4407 (_initialize_cli_logging): Use add_basic_prefix_cmd,
4408 add_show_prefix_cmd.
4409 (show_logging_command): Remove.
4410 * target.c (target_command): Remove.
4411 (add_target): Use add_basic_prefix_cmd.
4412
4413 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
4414
4415 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
4416
4417 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4418
4419 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
4420 info_command.
4421
4422 2020-04-30 Kamil Rytarowski <n54@gmx.com>
4423
4424 * nbsd-nat.c (nbsd_enable_proc_events)
4425 (nbsd_nat_target::post_startup_inferior): Add.
4426 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
4427 (nbsd_nat_target::update_thread_list): Rewrite.
4428 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
4429 "PTRACE_LWP_CREATE".
4430 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
4431
4432 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4433
4434 * stack.c (_initialize_stack): Remove duplicated creation
4435 of "frame" command and "f" alias.
4436
4437 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4438
4439 PR gdb/18706
4440 * gdbtypes.c (check_typedef): Calculate size of array of
4441 stubbed type.
4442
4443 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4444
4445 PR gdb/15559
4446 * i386-tdep.c (i386_push_dummy_call): Call
4447 i386_thiscall_push_dummy_call.
4448 (i386_thiscall_push_dummy_call): New function.
4449 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
4450 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
4451 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
4452
4453 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4454
4455 * gdbarch.sh (do_read): Add shellcheck disable directive for
4456 warning SC2162.
4457
4458 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4459
4460 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
4461 "referenced but not assigned" warning.
4462
4463 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4464
4465 * gdbarch.sh: Remove code that sets fallbackdefault.
4466
4467 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4468
4469 * gdbarch.sh: Use shell operators && and || instead of
4470 -a and -o.
4471
4472 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4473
4474 * gdbarch.sh: Use $(...) instead of `...`.
4475
4476 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4477
4478 * gdbarch.sh: Use double quotes around variables.
4479
4480 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4481
4482 * gdbarch.sh: Use %s with printf, instead of variables in the
4483 format string.
4484
4485 2020-04-29 Tom Tromey <tromey@adacore.com>
4486
4487 PR ada/25875:
4488 * dwarf2/read.c (update_enumeration_type_from_children): Compute
4489 type fields here.
4490 (read_enumeration_type): Call
4491 update_enumeration_type_from_children later. Update comments.
4492 (process_enumeration_scope): Don't create type fields.
4493
4494 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4495
4496 * nbsd-tdep.c: Include "xml-syscall.h".
4497 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
4498
4499 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4500
4501 * nbsd-nat.c: Include "sys/wait.h".
4502 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
4503 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
4504 (nbsd_nat_target::remove_exec_catchpoint)
4505 (nbsd_nat_target::set_syscall_catchpoint): Add.
4506 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
4507 (nbsd_nat_target::insert_exec_catchpoint)
4508 (nbsd_nat_target::remove_exec_catchpoint)
4509 (nbsd_nat_target::set_syscall_catchpoint): Add.
4510 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
4511 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
4512 `nbsd_get_syscall_number'.
4513
4514 2020-04-29 Tom Tromey <tom@tromey.com>
4515
4516 * stack.c (print_block_frame_labels): Remove.
4517
4518 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
4519
4520 PR gdb/17320
4521 * ada-valprint.c (val_print_packed_array_elements): Move array
4522 end bracket to new line.
4523 (ada_val_print_string): Remove extra spaces before first array
4524 element.
4525 * c-valprint.c (c_value_print_array): Likewise.
4526 * m2-valprint.c (m2_print_array_contents): Likewise.
4527 (m2_value_print_inner): Likewise.
4528 * p-valprint.c (pascal_value_print_inner): Likewise.
4529 * valprint.c (generic_val_print_array): Likewise.
4530 (value_print_array_elements): Move first array element and array
4531 end bracket to new line.
4532
4533 2020-04-29 Tom de Vries <tdevries@suse.de>
4534
4535 PR symtab/25889
4536 * linespec.c (find_method): Fix ix calculation.
4537
4538 2020-04-28 Kamil Rytarowski <n54@gmx.com>
4539
4540 * syscalls/update-netbsd.sh: New file.
4541 * syscalls/netbsd.xml: Regenerate.
4542 * data-directory/Makefile.in: Register `netbsd.xml' in
4543 `SYSCALLS_FILES'.
4544
4545 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
4546
4547 * syscalls/update-freebsd.sh: Add double quotes.
4548
4549 2020-04-28 Tom Tromey <tom@tromey.com>
4550
4551 * NEWS: Update.
4552 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
4553 (cmdpy_init): Allow class_tui.
4554
4555 2020-04-28 Mark Williams <mark@myosotissp.com>
4556
4557 PR gdb/24480
4558 * dwarf2read.c: Add missing assingments to list_in_scope when
4559 start_symtab was already called.
4560
4561 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
4562
4563 PR gdb/25881
4564 * dwarf2/read.c (offset_map_type): Use
4565 gdb:hash_enum<sect_offset> as hash function.
4566
4567 2020-04-28 Tom de Vries <tdevries@suse.de>
4568
4569 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
4570 with DW_AT_signature.
4571
4572 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
4573
4574 * configure.ac: Remove check for fs_base/gs_base in
4575 user_regs_struct.
4576 * configure: Re-generate.
4577 * config.in: Re-generate.
4578 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
4579 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
4580 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
4581
4582 2020-04-27 Luis Machado <luis.machado@linaro.org>
4583
4584 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
4585 problematic inline frame unwinding situation.
4586 * frame.c (frame_id_computed_p): New function.
4587 * frame.h (frame_id_computed_p): New prototype.
4588
4589 2020-04-26 Tom Tromey <tom@tromey.com>
4590
4591 * command.h (enum command_class) <class_pseudo>: Remove.
4592
4593 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4594
4595 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
4596 and whitespace.
4597
4598 2020-04-25 Kamil Rytarowski <n54@gmx.com>
4599
4600 * inf-ptrace.c (inf_ptrace_target::wait): Remove
4601 `PT_GET_PROCESS_STATE' block.
4602
4603 2020-04-24 Tom Tromey <tom@tromey.com>
4604
4605 * symtab.h (symbol_get_demangled_name): Don't declare.
4606 * symtab.c (symbol_get_demangled_name): Remove.
4607 (general_symbol_info::natural_name)
4608 (general_symbol_info::demangled_name): Update.
4609
4610 2020-04-24 Tom Tromey <tom@tromey.com>
4611
4612 PR rust/25025:
4613 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
4614
4615 2020-04-24 Tom Tromey <tom@tromey.com>
4616
4617 PR symtab/12707:
4618 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
4619 exists.
4620 (new_symbol): Likewise.
4621 * compile/compile-object-load.c (get_out_value_type): Use
4622 symbol_matches_search_name.
4623
4624 2020-04-24 Tom Tromey <tom@tromey.com>
4625
4626 * dwarf2/read.c (add_partial_symbol): Do not call
4627 compute_and_set_names.
4628
4629 2020-04-24 Tom Tromey <tom@tromey.com>
4630
4631 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
4632 overload.
4633
4634 2020-04-24 Tom Tromey <tom@tromey.com>
4635
4636 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
4637 (add_psymbol_to_list): New overload. Make old overload call new
4638 one.
4639 * psympriv.h (add_psymbol_to_list): New overload.
4640
4641 2020-04-24 Tom Tromey <tom@tromey.com>
4642
4643 * dwarf2/read.c (partial_die_info::read) <case
4644 DW_AT_linkage_name>: Use value_as_string.
4645 (dwarf2_string_attr): Use value_as_string.
4646 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
4647 method.
4648 * dwarf2/attribute.c (attribute::value_as_string): New method.
4649
4650 2020-04-24 Tom Tromey <tom@tromey.com>
4651
4652 * symtab.c (general_symbol_info::natural_name)
4653 (general_symbol_info::demangled_name): Check for language_rust.
4654
4655 2020-04-24 Tom Tromey <tom@tromey.com>
4656
4657 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
4658 (dwarf2_physname): ... from here.
4659 (partial_die_info::read): Add Rust "{" hack.
4660
4661 2020-04-24 Tom Tromey <tom@tromey.com>
4662
4663 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
4664 method.
4665 (symbol_set_demangled_name): Don't declare.
4666 * symtab.c (general_symbol_info::set_demangled_name): Rename from
4667 symbol_set_demangled_name.
4668 (general_symbol_info::set_language)
4669 (general_symbol_info::compute_and_set_names): Update.
4670 * minsyms.c (minimal_symbol_reader::install): Update.
4671 * dwarf2/read.c (new_symbol): Update.
4672
4673 2020-04-24 Tom Tromey <tromey@adacore.com>
4674
4675 PR python/23662:
4676 * python/py-type.c (convert_field): Handle
4677 FIELD_LOC_KIND_DWARF_BLOCK.
4678 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
4679 (typy_get_dynamic): Nw function.
4680 (type_object_getset): Add "dynamic".
4681 * NEWS: Add entry.
4682
4683 2020-04-24 Tom Tromey <tromey@adacore.com>
4684
4685 * ada-typeprint.c (print_choices, print_variant_part)
4686 (print_record_field_types_dynamic): New functions.
4687 (print_record_field_types): Use print_record_field_types_dynamic.
4688
4689 2020-04-24 Tom Tromey <tromey@adacore.com>
4690
4691 * dwarf2/read.c (handle_data_member_location): New overload.
4692 (dwarf2_add_field): Use it.
4693 (decode_locdesc): Add "computed" parameter. Update comment.
4694 * gdbtypes.c (is_dynamic_type_internal): Also look for
4695 FIELD_LOC_KIND_DWARF_BLOCK.
4696 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
4697 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
4698 virtual base classes.
4699 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
4700 FIELD_LOC_KIND_DWARF_BLOCK.
4701
4702 2020-04-24 Tom Tromey <tromey@adacore.com>
4703
4704 * dwarf2/read.c (read_structure_type): Handle dynamic length.
4705 * gdbtypes.c (is_dynamic_type_internal): Check
4706 TYPE_HAS_DYNAMIC_LENGTH.
4707 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
4708 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
4709 New macros.
4710 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
4711 constant.
4712
4713 2020-04-24 Tom Tromey <tromey@adacore.com>
4714
4715 * dwarf2/read.c (struct variant_field): Rewrite.
4716 (struct variant_part_builder): New.
4717 (struct nextfield): Remove "variant" field. Add "offset".
4718 (struct field_info): Add "current_variant_part" and
4719 "variant_parts".
4720 (alloc_discriminant_info): Remove.
4721 (alloc_rust_variant): New function.
4722 (quirk_rust_enum): Update.
4723 (dwarf2_add_field): Set "offset" member. Don't handle
4724 DW_TAG_variant_part.
4725 (offset_map_type): New typedef.
4726 (convert_variant_range, create_one_variant)
4727 (create_one_variant_part, create_variant_parts)
4728 (add_variant_property): New functions.
4729 (dwarf2_attach_fields_to_type): Call add_variant_property.
4730 (read_structure_type): Don't handle DW_TAG_variant_part.
4731 (handle_variant_part, handle_variant): New functions.
4732 (handle_struct_member_die): Use them.
4733 (process_structure_scope): Don't handle variant parts.
4734 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
4735 (struct discriminant_info): Remove.
4736 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
4737 (struct main_type) <flag_discriminated_union>: Remove.
4738 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
4739 (rust_enum_variant): Return int. Remove "contents". Rewrite.
4740 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
4741 Update.
4742 * valops.c (value_union_variant): Remove.
4743 * value.h (value_union_variant): Don't declare.
4744
4745 2020-04-24 Tom Tromey <tromey@adacore.com>
4746
4747 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
4748 (ada_value_primitive_packed_val): Update.
4749 * ada-valprint.c (ada_value_print_1): Update.
4750 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
4751 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
4752 just an address. Use evaluate_for_locexpr_baton.
4753 (dwarf2_evaluate_property): Update.
4754 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
4755 array_view.
4756 * findvar.c (default_read_var_value): Update.
4757 * gdbtypes.c (compute_variant_fields_inner)
4758 (resolve_dynamic_type_internal): Update.
4759 (resolve_dynamic_type): Change type of valaddr parameter.
4760 * gdbtypes.h (resolve_dynamic_type): Update.
4761 * valarith.c (value_subscripted_rvalue): Update.
4762 * value.c (value_from_contents_and_address): Update.
4763
4764 2020-04-24 Tom Tromey <tromey@adacore.com>
4765
4766 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
4767 "push_initial_value" parameter.
4768 (dwarf2_evaluate_property): Likewise.
4769 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
4770
4771 2020-04-24 Tom Tromey <tromey@adacore.com>
4772
4773 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
4774 (variant::matches, compute_variant_fields_recurse)
4775 (compute_variant_fields_inner, compute_variant_fields): New
4776 functions.
4777 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
4778 Use resolved_type after type is made.
4779 (operator==): Add new cases.
4780 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
4781 (struct discriminant_range, struct variant, struct variant_part):
4782 New.
4783 (union dynamic_prop_data) <variant_parts, original_type>: New
4784 members.
4785 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
4786 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
4787 constants.
4788 * value.c (unpack_bits_as_long): Now public.
4789 * value.h (unpack_bits_as_long): Declare.
4790
4791 2020-04-24 Tom Tromey <tromey@adacore.com>
4792
4793 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
4794 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
4795
4796 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
4797
4798 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
4799
4800 2020-04-24 Kamil Rytarowski <n54@gmx.com>
4801
4802 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
4803 (remove_fork_catchpoint, post_startup_inferior)
4804 (post_attach): Move...
4805 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
4806 (remove_fork_catchpoint, post_startup_inferior)
4807 (post_attach): ...here.
4808 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
4809 (remove_fork_catchpoint, post_startup_inferior)
4810 (post_attach): Move...
4811 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
4812 (remove_fork_catchpoint, post_startup_inferior)
4813 (post_attach): ...here.
4814
4815 2020-04-24 Tom Tromey <tromey@adacore.com>
4816
4817 * nat/windows-nat.h (struct windows_thread_info)
4818 <pc_adjusted>: New member.
4819 * windows-nat.c (windows_fetch_one_register): Check
4820 pc_adjusted.
4821 (windows_nat_target::get_windows_debug_event)
4822 (windows_nat_target::wait): Set pc_adjusted.
4823
4824 2020-04-24 Tom de Vries <tdevries@suse.de>
4825
4826 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
4827 Run gdb-add-index inside temp dir.
4828
4829 2020-04-23 Tom Tromey <tromey@adacore.com>
4830
4831 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
4832 in loop.
4833
4834 2020-04-23 Luis Machado <luis.machado@linaro.org>
4835
4836 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
4837 get_frame_register instead of gdbarch_unwind_pc.
4838
4839 2020-04-23 Tom de Vries <tdevries@suse.de>
4840
4841 * symtab.c (lookup_global_symbol): Prefer def over decl.
4842
4843 2020-04-23 Tom de Vries <tdevries@suse.de>
4844
4845 PR symtab/25807
4846 * block.c (best_symbol, better_symbol): Promote to external.
4847 * block.h (best_symbol, better_symbol): Declare.
4848 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
4849 decl.
4850
4851 2020-04-23 Tom Tromey <tromey@adacore.com>
4852
4853 PR ada/25837:
4854 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
4855 "const char *", not a "const std::string &".
4856 <name_and_matcher::operator==>: Update.
4857 * unittests/lookup_name_info-selftests.c: Change type of
4858 "result".
4859
4860 2020-04-23 Tom Tromey <tom@tromey.com>
4861
4862 * inferior.h (iterate_over_inferiors): Don't declare.
4863 * inferior.c (iterate_over_inferiors): Remove.
4864 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
4865 Remove.
4866 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
4867 use iterate_over_inferiors.
4868 (darwin_resume_inferior_it)
4869 (struct resume_inferior_threads_param)
4870 (darwin_resume_inferior_threads_it): Remove.
4871 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
4872
4873 2020-04-23 Tom de Vries <tdevries@suse.de>
4874
4875 * blockframe.c (find_pc_partial_function): Use
4876 find_pc_sect_compunit_symtab rather than
4877 objfile->sf->qf->find_pc_sect_compunit_symtab.
4878
4879 2020-04-22 Tom de Vries <tdevries@suse.de>
4880
4881 PR symtab/25764
4882 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
4883 in psymtabs.
4884
4885 2020-04-22 Tom de Vries <tdevries@suse.de>
4886
4887 PR symtab/25801
4888 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
4889 symtabs.
4890
4891 2020-04-22 Tom de Vries <tdevries@suse.de>
4892
4893 PR symtab/25700
4894 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
4895 CU if already created.
4896
4897 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4898
4899 * infrun.c (displaced_step_fixup): Switch to the event_thread
4900 before calling displaced_step_restore, not after.
4901
4902 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4903
4904 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
4905 its inferior is not recorded by us.
4906 (record_btrace_target_open): Replace call to
4907 all_non_exited_threads () with call to current_inferior
4908 ()->non_exited_threads ().
4909 (record_btrace_target::stop_recording): Likewise.
4910 (record_btrace_target::close): Likewise.
4911 (record_btrace_target::wait): Likewise.
4912 (record_btrace_target::record_stop_replaying): Likewise.
4913
4914 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4915
4916 * btrace.c (btrace_enable): Throw an error on double enables and
4917 when enabling recording fails.
4918 (btrace_disable): Throw an error if the thread is not recorded.
4919
4920 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4921
4922 * record-btrace.c (record_btrace_target::fetch_registers): Forward
4923 request if we do not have a thread_info.
4924
4925 2020-04-21 Tom de Vries <tdevries@suse.de>
4926
4927 PR gdb/25471
4928 * thread.c
4929 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
4930 exception in get_frame_id.
4931
4932 2020-04-20 Tom Tromey <tromey@adacore.com>
4933
4934 * python/python.c (struct gdbpy_event): Mark move constructor as
4935 noexcept.
4936 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
4937 constructor as noexcept.
4938 * completer.h (struct completion_result): Mark move constructor as
4939 noexcept.
4940 * completer.c (completion_result::completion_result): Use
4941 initialization style. Don't call reset_match_list.
4942
4943 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
4944
4945 * MAINTAINERS (Write After Approval): Add myself.
4946
4947 2020-04-18 Tom Tromey <tom@tromey.com>
4948
4949 * windows-tdep.c (init_w32_command_list)
4950 (w32_prefix_command_valid): Restore.
4951 (_initialize_windows_tdep): Call init_w32_command_list.
4952
4953 2020-04-18 Tom Tromey <tom@tromey.com>
4954
4955 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
4956 * value.c (value_fn_field): Update.
4957 * valops.c (find_function_in_inferior)
4958 (value_allocate_space_in_inferior): Update.
4959 * tui/tui-winsource.c (tui_update_source_windows_with_line):
4960 Update.
4961 * tui/tui-source.c (tui_source_window::set_contents): Update.
4962 * symtab.c (lookup_global_or_static_symbol)
4963 (find_function_start_sal_1, skip_prologue_sal)
4964 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
4965 * symmisc.c (dump_msymbols, dump_symtab_1)
4966 (maintenance_print_one_line_table): Update.
4967 * symfile.c (init_entry_point_info, section_is_mapped)
4968 (list_overlays_command, simple_read_overlay_table)
4969 (simple_overlay_update_1): Update.
4970 * stap-probe.c (handle_stap_probe): Update.
4971 * stabsread.c (dbx_init_float_type, define_symbol)
4972 (read_one_struct_field, read_enum_type, read_range_type): Update.
4973 * source.c (info_line_command): Update.
4974 * python/python.c (gdbpy_source_objfile_script)
4975 (gdbpy_execute_objfile_script): Update.
4976 * python/py-type.c (save_objfile_types): Update.
4977 * python/py-objfile.c (py_free_objfile): Update.
4978 * python/py-inferior.c (python_new_objfile): Update.
4979 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
4980 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
4981 (maintenance_check_psymtabs): Update.
4982 * printcmd.c (info_address_command): Update.
4983 * objfiles.h (struct objfile) <arch>: New method, from
4984 get_objfile_arch.
4985 (get_objfile_arch): Don't declare.
4986 * objfiles.c (get_objfile_arch): Remove.
4987 (filter_overlapping_sections): Update.
4988 * minsyms.c (msymbol_is_function): Update.
4989 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
4990 (output_nondebug_symbol): Update.
4991 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
4992 (mdebug_expand_psymtab): Update.
4993 * machoread.c (macho_add_oso_symfile): Update.
4994 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
4995 Update.
4996 * linux-fork.c (checkpoint_command): Update.
4997 * linespec.c (convert_linespec_to_sals): Update.
4998 * jit.c (finalize_symtab): Update.
4999 * infrun.c (insert_exception_resume_from_probe): Update.
5000 * ia64-tdep.c (ia64_find_unwind_table): Update.
5001 * hppa-tdep.c (internalize_unwinds): Update.
5002 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
5003 Update.
5004 * gcore.c (call_target_sbrk): Update.
5005 * elfread.c (record_minimal_symbol, elf_symtab_read)
5006 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
5007 (elf_gnu_ifunc_resolve_by_got): Update.
5008 * dwarf2/read.c (create_addrmap_from_index)
5009 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
5010 (read_debug_names_from_section)
5011 (process_psymtab_comp_unit_reader, add_partial_symbol)
5012 (add_partial_subprogram, process_full_comp_unit)
5013 (read_file_scope, read_func_scope, read_lexical_block_scope)
5014 (read_call_site_scope, dwarf2_ranges_read)
5015 (dwarf2_record_block_ranges, dwarf2_add_field)
5016 (mark_common_block_symbol_computed, read_tag_pointer_type)
5017 (read_tag_string_type, dwarf2_init_float_type)
5018 (dwarf2_init_complex_target_type, read_base_type)
5019 (partial_die_info::read, partial_die_info::read)
5020 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
5021 (dwarf2_fetch_die_loc_sect_off): Update.
5022 * dwarf2/loc.c (dwarf2_find_location_expression)
5023 (class dwarf_evaluate_loc_desc, rw_pieced_value)
5024 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
5025 (dwarf2_loc_desc_get_symbol_read_needs)
5026 (locexpr_describe_location_piece, locexpr_describe_location_1)
5027 (loclist_describe_location): Update.
5028 * dwarf2/index-write.c (write_debug_names): Update.
5029 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
5030 * dtrace-probe.c (dtrace_process_dof): Update.
5031 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
5032 (process_one_symbol): Update.
5033 * ctfread.c (ctf_init_float_type, read_base_type): Update.
5034 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
5035 (coff_read_enum_type): Update.
5036 * cli/cli-cmds.c (edit_command, list_command): Update.
5037 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
5038 * breakpoint.c (create_overlay_event_breakpoint)
5039 (create_longjmp_master_breakpoint)
5040 (create_std_terminate_master_breakpoint)
5041 (create_exception_master_breakpoint, get_sal_arch): Update.
5042 * block.c (block_gdbarch): Update.
5043 * annotate.c (annotate_source_line): Update.
5044
5045 2020-04-17 Tom Tromey <tromey@adacore.com>
5046
5047 * auto-load.c (show_auto_load_cmd): Remove.
5048 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
5049 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
5050 (maintenance_print_arc_command): Remove.
5051 * tui/tui-win.c (tui_command): Remove.
5052 (tui_get_cmd_list): Use add_basic_prefix_cmd.
5053 * tui/tui-layout.c (tui_layout_command): Remove.
5054 (_initialize_tui_layout): Use add_basic_prefix_cmd.
5055 * python/python.c (user_set_python, user_show_python): Remove.
5056 (_initialize_python): Use add_basic_prefix_cmd,
5057 add_show_prefix_cmd.
5058 * guile/guile.c (set_guile_command, show_guile_command): Remove.
5059 (install_gdb_commands): Use add_basic_prefix_cmd,
5060 add_show_prefix_cmd.
5061 (info_guile_command): Remove.
5062 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
5063 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
5064 add_show_prefix_cmd.
5065 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
5066 Remove do_set and do_show parameters.
5067 * cli/cli-style.c (set_style, show_style): Remove.
5068 (_initialize_cli_style): Use add_basic_prefix_cmd,
5069 add_show_prefix_cmd.
5070 (cli_style_option::add_setshow_commands): Remove do_set and
5071 do_show parameters.
5072 (cli_style_option::add_setshow_commands): Use
5073 add_basic_prefix_cmd, add_show_prefix_cmd.
5074 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
5075 (set_style_name): Remove.
5076 * cli/cli-dump.c (dump_command, append_command): Remove.
5077 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5078 (tekhex_dump_command, binary_dump_command)
5079 (binary_append_command): Remove.
5080 (_initialize_cli_dump): Use add_basic_prefix_cmd.
5081 * windows-tdep.c (w32_prefix_command_valid): Remove global.
5082 (init_w32_command_list): Remove; move into ...
5083 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
5084 * valprint.c (set_print, show_print, set_print_raw)
5085 (show_print_raw): Remove.
5086 (_initialize_valprint): Use add_basic_prefix_cmd,
5087 add_show_prefix_cmd.
5088 * typeprint.c (set_print_type, show_print_type): Remove.
5089 (_initialize_typeprint): Use add_basic_prefix_cmd,
5090 add_show_prefix_cmd.
5091 * record.c (set_record_command, show_record_command): Remove.
5092 (_initialize_record): Use add_basic_prefix_cmd,
5093 add_show_prefix_cmd.
5094 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
5095 add_show_prefix_cmd.
5096 (info_command, show_command, set_debug, show_debug): Remove.
5097 * top.h (set_history, show_history): Don't declare.
5098 * top.c (set_history, show_history): Remove.
5099 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5100 (unset_tdesc_cmd): Remove.
5101 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
5102 add_show_prefix_cmd.
5103 * symtab.c (info_module_command): Remove.
5104 (_initialize_symtab): Use add_basic_prefix_cmd.
5105 * symfile.c (overlay_command): Remove.
5106 (_initialize_symfile): Use add_basic_prefix_cmd.
5107 * sparc64-tdep.c (info_adi_command): Remove.
5108 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
5109 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
5110 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
5111 add_show_prefix_cmd.
5112 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
5113 (_initialize_serial): Use add_basic_prefix_cmd,
5114 add_show_prefix_cmd.
5115 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
5116 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
5117 add_show_prefix_cmd.
5118 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
5119 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
5120 add_show_prefix_cmd.
5121 * riscv-tdep.c (show_riscv_command, set_riscv_command)
5122 (show_debug_riscv_command, set_debug_riscv_command): Remove.
5123 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
5124 add_show_prefix_cmd.
5125 * remote.c (remote_command, set_remote_cmd): Remove.
5126 (_initialize_remote): Use add_basic_prefix_cmd.
5127 * record-full.c (set_record_full_command)
5128 (show_record_full_command): Remove.
5129 (_initialize_record_full): Use add_basic_prefix_cmd,
5130 add_show_prefix_cmd.
5131 * record-btrace.c (cmd_set_record_btrace)
5132 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
5133 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
5134 (cmd_show_record_btrace_pt): Remove.
5135 (_initialize_record_btrace): Use add_basic_prefix_cmd,
5136 add_show_prefix_cmd.
5137 * ravenscar-thread.c (set_ravenscar_command)
5138 (show_ravenscar_command): Remove.
5139 (_initialize_ravenscar): Use add_basic_prefix_cmd,
5140 add_show_prefix_cmd.
5141 * mips-tdep.c (show_mips_command, set_mips_command)
5142 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
5143 add_show_prefix_cmd.
5144 * maint.c (maintenance_command, maintenance_info_command)
5145 (maintenance_check_command, maintenance_print_command)
5146 (maintenance_set_cmd, maintenance_show_cmd): Remove.
5147 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
5148 add_show_prefix_cmd.
5149 (show_per_command_cmd): Remove.
5150 * maint-test-settings.c (maintenance_set_test_settings_cmd):
5151 Remove.
5152 (maintenance_show_test_settings_cmd): Remove.
5153 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
5154 add_show_prefix_cmd.
5155 * maint-test-options.c (maintenance_test_options_command):
5156 Remove.
5157 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
5158 * macrocmd.c (macro_command): Remove
5159 (_initialize_macrocmd): Use add_basic_prefix_cmd.
5160 * language.c (set_check, show_check): Remove.
5161 (_initialize_language): Use add_basic_prefix_cmd,
5162 add_show_prefix_cmd.
5163 * infcmd.c (unset_command): Remove.
5164 (_initialize_infcmd): Use add_basic_prefix_cmd.
5165 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
5166 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
5167 add_show_prefix_cmd.
5168 * go32-nat.c (go32_info_dos_command): Remove.
5169 (_initialize_go32_nat): Use add_basic_prefix_cmd.
5170 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
5171 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
5172 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
5173 (_initialize_frame): Use add_basic_prefix_cmd,
5174 add_show_prefix_cmd.
5175 * dcache.c (set_dcache_command, show_dcache_command): Remove.
5176 (_initialize_dcache): Use add_basic_prefix_cmd,
5177 add_show_prefix_cmd.
5178 * cp-support.c (maint_cplus_command): Remove.
5179 (_initialize_cp_support): Use add_basic_prefix_cmd.
5180 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5181 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5182 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
5183 add_basic_prefix_cmd, add_show_prefix_cmd.
5184 * breakpoint.c (save_command): Remove.
5185 (_initialize_breakpoint): Use add_basic_prefix_cmd.
5186 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
5187 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
5188 add_show_prefix_cmd.
5189 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
5190 (set_ada_command, show_ada_command): Remove.
5191 (_initialize_ada_language): Use add_basic_prefix_cmd,
5192 add_show_prefix_cmd.
5193 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
5194
5195 2020-04-16 Kamil Rytarowski <n54@gmx.com>
5196
5197 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
5198 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
5199
5200 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
5201
5202 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
5203 warning messages.
5204
5205 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
5206
5207 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
5208 import table is not at beginning of .idata section.
5209
5210 2020-04-16 Pedro Alves <palves@redhat.com>
5211
5212 * inferior.c (delete_inferior): Use delete operator directly
5213 instead of delete_program_space.
5214 * progspace.c (add_program_space): New, factored out from
5215 program_space::program_space.
5216 (remove_program_space): New, factored out from
5217 delete_program_space.
5218 (program_space::program_space): Remove intro comment. Rewrite.
5219 (program_space::~program_space): Remove intro comment. Call
5220 remove_program_space.
5221 (delete_program_space): Delete.
5222 * progspace.h (program_space::program_space): Make explicit. Move
5223 intro comment here, adjusted.
5224 (program_space::~program_space): Move intro comment here,
5225 adjusted.
5226 (delete_program_space): Remove.
5227
5228 2020-04-16 Tom Tromey <tromey@adacore.com>
5229
5230 * windows-nat.c (windows_nat::handle_access_violation): New
5231 function.
5232 * nat/windows-nat.h (handle_access_violation): Declare.
5233 * nat/windows-nat.c (handle_exception): Move Cygwin code to
5234 windows-nat.c. Call handle_access_violation.
5235
5236 2020-04-16 Tom de Vries <tdevries@suse.de>
5237
5238 PR symtab/25791
5239 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
5240 CUs without psymtab.
5241
5242 2020-04-16 Kevin Buettner <kevinb@redhat.com>
5243
5244 * python/python.c (do_start_initialization): Don't call
5245 PyEval_InitThreads for Python 3.9 and beyond.
5246
5247 2020-04-15 Kamil Rytarowski <n54@gmx.com>
5248
5249 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
5250 thread functions.
5251 (obsd_nat_target::wait): Likewise.
5252
5253 2020-04-15 Tom Tromey <tromey@adacore.com>
5254
5255 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
5256 (DEBUG_EXCEPT): Use debug_printf.
5257
5258 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
5259
5260 * completer.c (class completion_tracker::completion_hash_entry)
5261 <hash_name>: New member function.
5262 (completion_tracker::discard_completions): New callback to hash a
5263 completion_hash_entry, pass this to htab_create_alloc.
5264
5265 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
5266
5267 * windows-nat.c (windows_make_so): Warn rather than stopping with
5268 an error if realpath() fails.
5269
5270 2020-04-14 Kamil Rytarowski <n54@gmx.com>
5271
5272 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
5273 (nbsd_nat_target::info_proc): Add do_status.
5274
5275 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
5276 Tom de Vries <tdevries@suse.de>
5277
5278 PR symtab/25718
5279 * psympriv.h (struct partial_symtab::read_symtab)
5280 (struct partial_symtab::expand_psymtab)
5281 (struct partial_symtab::read_dependencies): Update comments.
5282 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
5283 read_symtab for includer.
5284 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
5285 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
5286 (struct dwarf2_include_psymtab::m_readin): Remove.
5287 (struct dwarf2_include_psymtab::includer): New member function.
5288 (dwarf2_psymtab::expand_psymtab): Assert !readin.
5289
5290 2020-04-14 Tom de Vries <tdevries@suse.de>
5291
5292 PR symtab/25720
5293 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
5294 with NULL symbol_matcher and lookup_name.
5295 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
5296 and lookup_name.
5297 * dwarf2/read.c (dw2_expand_symtabs_matching)
5298 (dw2_debug_names_expand_symtabs_matching): Same.
5299 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
5300 Make lookup_name a pointer. Update comment.
5301 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
5302 lookup_name being a pointer.
5303 * symfile.c (expand_symtabs_matching): Same.
5304 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
5305 * linespec.c (iterate_over_all_matching_symtabs): Same.
5306
5307 2020-04-13 Tom Tromey <tom@tromey.com>
5308
5309 * run-on-main-thread.c: Update include.
5310 * unittests/main-thread-selftests.c: Update include.
5311 * tui/tui-win.c: Update include.
5312 * tui/tui-io.c: Update include.
5313 * tui/tui-interp.c: Update include.
5314 * tui/tui-hooks.c: Update include.
5315 * top.h: Update include.
5316 * top.c: Update include.
5317 * ser-base.c: Update include.
5318 * remote.c: Update include.
5319 * remote-notif.c: Update include.
5320 * remote-fileio.c: Update include.
5321 * record-full.c: Update include.
5322 * record-btrace.c: Update include.
5323 * python/python.c: Update include.
5324 * posix-hdep.c: Update include.
5325 * mingw-hdep.c: Update include.
5326 * mi/mi-main.c: Update include.
5327 * mi/mi-interp.c: Update include.
5328 * main.c: Update include.
5329 * linux-nat.c: Update include.
5330 * interps.c: Update include.
5331 * infrun.c: Update include.
5332 * inf-loop.c: Update include.
5333 * event-top.c: Update include.
5334 * event-loop.c: Move to ../gdbsupport/.
5335 * event-loop.h: Move to ../gdbsupport/.
5336 * async-event.h: Update include.
5337 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
5338
5339 2020-04-13 Tom Tromey <tom@tromey.com>
5340
5341 * tui/tui-win.c: Include async-event.h.
5342 * remote.c: Include async-event.h.
5343 * remote-notif.c: Include async-event.h.
5344 * record-full.c: Include async-event.h.
5345 * record-btrace.c: Include async-event.h.
5346 * infrun.c: Include async-event.h.
5347 * event-top.c: Include async-event.h.
5348 * event-loop.h: Move some declarations to async-event.h.
5349 * event-loop.c: Don't include ser-event.h or top.h. Move some
5350 code to async-event.c.
5351 * async-event.h: New file.
5352 * async-event.c: New file.
5353 * Makefile.in (COMMON_SFILES): Add async-event.c.
5354 (HFILES_NO_SRCDIR): Add async-event.h.
5355
5356 2020-04-13 Tom Tromey <tom@tromey.com>
5357
5358 * utils.c (flush_streams): New function.
5359 * event-loop.c (gdb_wait_for_event): Call flush_streams.
5360
5361 2020-04-13 Tom Tromey <tom@tromey.com>
5362
5363 * event-loop.c (handle_file_event): Use warning, not
5364 printf_unfiltered.
5365
5366 2020-04-13 Tom Tromey <tom@tromey.com>
5367
5368 * event-loop.c: Include <chrono>.
5369
5370 2020-04-13 Tom Tromey <tom@tromey.com>
5371
5372 * gdb_select.h: Move to ../gdbsupport/.
5373 * event-loop.c: Update include path.
5374 * top.c: Update include path.
5375 * ser-base.c: Update include path.
5376 * ui-file.c: Update include path.
5377 * ser-tcp.c: Update include path.
5378 * guile/scm-ports.c: Update include path.
5379 * posix-hdep.c: Update include path.
5380 * ser-unix.c: Update include path.
5381 * gdb_usleep.c: Update include path.
5382 * mingw-hdep.c: Update include path.
5383 * inflow.c: Update include path.
5384 * infrun.c: Update include path.
5385 * event-top.c: Update include path.
5386
5387 2020-04-13 Tom Tromey <tom@tromey.com>
5388
5389 * configure: Rebuild.
5390 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
5391
5392 2020-04-13 Tom Tromey <tom@tromey.com>
5393
5394 * event-loop.h (start_event_loop): Don't declare.
5395 * event-loop.c (start_event_loop): Move...
5396 * main.c (start_event_loop): ...here. Now static.
5397
5398 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
5399
5400 * MAINTAINERS: Update my email address.
5401
5402 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5403
5404 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
5405 IP_ALL.
5406
5407 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5408
5409 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
5410 (nbsd_nat_target::info_proc): Add do_cmdline.
5411
5412 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5413
5414 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
5415 (nbsd_nat_target::info_proc): Add do_cwd.
5416
5417 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5418
5419 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
5420
5421 2020-04-11 Kamil Rytarowski <n54@gmx.com>
5422
5423 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
5424 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
5425 (nbsd_nat_target::info_proc): New functions.
5426 * nbsd-nat.c (kinfo_get_vmmap): New function.
5427 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
5428 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
5429 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
5430 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
5431 functions.
5432 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
5433 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
5434 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
5435 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
5436 (KINFO_VME_FLAG_GROWS_DOWN): New.
5437
5438 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
5439
5440 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
5441 bit shift.
5442
5443 2020-04-10 Tom Tromey <tromey@adacore.com>
5444
5445 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
5446
5447 2020-04-10 Tom Tromey <tromey@adacore.com>
5448
5449 * symtab.c (get_symbol_address, get_msymbol_address): Skip
5450 separate debug files.
5451
5452 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
5453
5454 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5455 Move to...
5456 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5457 ... here.
5458 * windows-nat.c (windows_nat_target::get_windows_debug_event):
5459 Check for STATUS_WX86_BREAKPOINT.
5460 (windows_nat_target::wait): Same.
5461
5462 2020-04-10 Tom de Vries <tdevries@suse.de>
5463
5464 PR cli/25808
5465 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
5466
5467 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5468
5469 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
5470 (Write After Approval): Remove Tom de Vries.
5471
5472 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
5473
5474 revert partially:
5475 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5476
5477 * buildsym.c (record_line): Fix undefined behavior and preserve
5478 lines at eof.
5479
5480 2020-04-09 Kamil Rytarowski <n54@gmx.com>
5481
5482 * auxv.h (svr4_auxv_parse): New.
5483 * auxv.c (default_auxv_parse): Split into default_auxv_parse
5484 and generic_auxv_parse.
5485 (svr4_auxv_parse): Add.
5486 * obsd-tdep.c: Include "auxv.h".
5487 (obsd_auxv_parse): Remove.
5488 (obsd_init_abi): Remove comment.
5489 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
5490 from `obsd_auxv_parse' to `svr4_auxv_parse'.
5491 * nbsd-tdep.c: Include "auxv.h".
5492 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
5493
5494 2020-04-08 Tom Tromey <tromey@adacore.com>
5495
5496 * nat/windows-nat.h (last_wait_event): Don't declare.
5497 (wait_for_debug_event): Update comment.
5498 * nat/windows-nat.c (last_wait_event): Now static.
5499
5500 2020-04-08 Tom Tromey <tromey@adacore.com>
5501
5502 * windows-nat.c (wait_for_debug_event): Move to
5503 nat/windows-nat.c.
5504 * nat/windows-nat.h (wait_for_debug_event): Declare.
5505 * nat/windows-nat.c (wait_for_debug_event): Move from
5506 windows-nat.c. No longer static.
5507
5508 2020-04-08 Tom Tromey <tromey@adacore.com>
5509
5510 * windows-nat.c (get_windows_debug_event): Use
5511 fetch_pending_stop.
5512 * nat/windows-nat.h (fetch_pending_stop): Declare.
5513 * nat/windows-nat.c (fetch_pending_stop): New function.
5514
5515 2020-04-08 Tom Tromey <tromey@adacore.com>
5516
5517 * windows-nat.c (windows_continue): Use matching_pending_stop and
5518 continue_last_debug_event.
5519 * nat/windows-nat.h (matching_pending_stop)
5520 (continue_last_debug_event): Declare.
5521 * nat/windows-nat.c (DEBUG_EVENTS): New define.
5522 (matching_pending_stop, continue_last_debug_event): New
5523 functions.
5524
5525 2020-04-08 Tom Tromey <tromey@adacore.com>
5526
5527 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
5528 (handle_exception_result): Move to nat/windows-nat.h.
5529 (DEBUG_EXCEPTION_SIMPLE): Remove.
5530 (windows_nat::handle_ms_vc_exception): New function.
5531 (handle_exception): Move to nat/windows-nat.c.
5532 (get_windows_debug_event): Update.
5533 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
5534 nat/windows-nat.c.
5535 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
5536 (handle_exception_result): Move from windows-nat.c.
5537 (handle_exception): Declare.
5538 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
5539 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
5540 windows-nat.c.
5541
5542 2020-04-08 Tom Tromey <tromey@adacore.com>
5543
5544 * windows-nat.c (exception_count, event_count): Remove.
5545 (handle_exception, get_windows_debug_event)
5546 (do_initial_windows_stuff): Update.
5547
5548 2020-04-08 Tom Tromey <tromey@adacore.com>
5549
5550 * windows-nat.c (windows_nat::handle_load_dll)
5551 (windows_nat::handle_unload_dll): Rename. No longer static.
5552 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
5553 Declare.
5554
5555 2020-04-08 Tom Tromey <tromey@adacore.com>
5556
5557 * complaints.h (stop_whining): Declare at top-level.
5558 (complaint): Don't declare stop_whining.
5559
5560 2020-04-08 Tom Tromey <tromey@adacore.com>
5561
5562 * windows-nat.c (windows_nat::handle_output_debug_string):
5563 Rename. No longer static.
5564 * nat/windows-nat.h (handle_output_debug_string): Declare.
5565
5566 2020-04-08 Tom Tromey <tromey@adacore.com>
5567
5568 * windows-nat.c (current_process_handle, current_process_id)
5569 (main_thread_id, last_sig, current_event, last_wait_event)
5570 (current_windows_thread, desired_stop_thread_id, pending_stops)
5571 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
5572 (display_selectors, fake_create_process)
5573 (get_windows_debug_event): Update.
5574 * nat/windows-nat.h (current_process_handle, current_process_id)
5575 (main_thread_id, last_sig, current_event, last_wait_event)
5576 (current_windows_thread, desired_stop_thread_id, pending_stops)
5577 (struct pending_stop, siginfo_er): Move from windows-nat.c.
5578 * nat/windows-nat.c (current_process_handle, current_process_id)
5579 (main_thread_id, last_sig, current_event, last_wait_event)
5580 (current_windows_thread, desired_stop_thread_id, pending_stops)
5581 (siginfo_er): New globals. Move from windows-nat.c.
5582
5583 2020-04-08 Tom Tromey <tromey@adacore.com>
5584
5585 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
5586 (handle_load_dll): Update.
5587 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
5588
5589 2020-04-08 Tom Tromey <tromey@adacore.com>
5590
5591 * windows-nat.c (enum thread_disposition_type): Move to
5592 nat/windows-nat.h.
5593 (windows_nat::thread_rec): Rename from thread_rec. No longer
5594 static.
5595 (windows_add_thread, windows_nat_target::fetch_registers)
5596 (windows_nat_target::store_registers, handle_exception)
5597 (windows_nat_target::resume, get_windows_debug_event)
5598 (windows_nat_target::get_tib_address)
5599 (windows_nat_target::thread_name)
5600 (windows_nat_target::thread_alive): Update.
5601 * nat/windows-nat.h (enum thread_disposition_type): Move from
5602 windows-nat.c.
5603 (thread_rec): Declare.
5604
5605 2020-04-08 Tom Tromey <tromey@adacore.com>
5606
5607 * windows-nat.c: Add "using namespace".
5608 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
5609 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
5610
5611 2020-04-08 Tom Tromey <tromey@adacore.com>
5612
5613 * nat/windows-nat.h (struct windows_thread_info): Declare
5614 destructor.
5615 * nat/windows-nat.c (~windows_thread_info): New.
5616
5617 2020-04-08 Tom Tromey <tromey@adacore.com>
5618
5619 PR gdb/22992
5620 * windows-nat.c (current_event): Update comment.
5621 (last_wait_event, desired_stop_thread_id): New globals.
5622 (struct pending_stop): New.
5623 (pending_stops): New global.
5624 (windows_nat_target) <stopped_by_sw_breakpoint>
5625 <supports_stopped_by_sw_breakpoint>: New methods.
5626 (windows_fetch_one_register): Add assertions. Adjust PC.
5627 (windows_continue): Handle pending stops. Suspend other threads
5628 when stepping. Use last_wait_event
5629 (wait_for_debug_event): New function.
5630 (get_windows_debug_event): Use wait_for_debug_event. Handle
5631 pending stops. Queue spurious stops.
5632 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
5633 (windows_nat_target::kill): Use wait_for_debug_event.
5634 * nat/windows-nat.h (struct windows_thread_info)
5635 <stopped_at_software_breakpoint>: New field.
5636 * nat/windows-nat.c (windows_thread_info::resume): Clear
5637 stopped_at_software_breakpoint.
5638
5639 2020-04-08 Tom Tromey <tromey@adacore.com>
5640
5641 * windows-nat.c (enum thread_disposition_type): New.
5642 (thread_rec): Replace "get_context" parameter with "disposition";
5643 change type.
5644 (windows_add_thread, windows_nat_target::fetch_registers)
5645 (windows_nat_target::store_registers, handle_exception)
5646 (windows_nat_target::resume, get_windows_debug_event)
5647 (windows_nat_target::get_tib_address)
5648 (windows_nat_target::thread_name)
5649 (windows_nat_target::thread_alive): Update.
5650
5651 2020-04-08 Tom Tromey <tromey@adacore.com>
5652
5653 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
5654 (windows_continue): Use windows_continue::resume.
5655 * nat/windows-nat.h (struct windows_thread_info) <suspend,
5656 resume>: Declare new methods.
5657 * nat/windows-nat.c: New file.
5658 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
5659
5660 2020-04-08 Tom Tromey <tromey@adacore.com>
5661
5662 * windows-nat.c (windows_add_thread, windows_delete_thread)
5663 (windows_nat_target::fetch_registers)
5664 (windows_nat_target::store_registers, fake_create_process)
5665 (windows_nat_target::resume, windows_nat_target::resume)
5666 (get_windows_debug_event, windows_nat_target::wait)
5667 (windows_nat_target::pid_to_str)
5668 (windows_nat_target::get_tib_address)
5669 (windows_nat_target::get_ada_task_ptid)
5670 (windows_nat_target::thread_name)
5671 (windows_nat_target::thread_alive): Use lwp, not tid.
5672
5673 2020-04-08 Tom Tromey <tromey@adacore.com>
5674
5675 * windows-nat.c (handle_exception)
5676 (windows_nat_target::thread_name): Update.
5677 * nat/windows-nat.h (windows_thread_info): Remove destructor.
5678 <name>: Now unique_xmalloc_ptr.
5679
5680 2020-04-08 Tom Tromey <tromey@adacore.com>
5681
5682 * windows-nat.c (thread_rec)
5683 (windows_nat_target::fetch_registers): Update.
5684 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
5685 Update comment.
5686 <debug_registers_changed, reload_context>: Now bool.
5687
5688 2020-04-08 Tom Tromey <tromey@adacore.com>
5689
5690 * windows-nat.c (windows_add_thread): Use new.
5691 (windows_init_thread_list, windows_delete_thread): Use delete.
5692 (get_windows_debug_event): Update.
5693 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
5694 destructor, and initializers.
5695
5696 2020-04-08 Tom Tromey <tromey@adacore.com>
5697
5698 * windows-nat.c (struct windows_thread_info): Remove.
5699 * nat/windows-nat.h: New file.
5700
5701 2020-04-08 Tom Tromey <tromey@adacore.com>
5702
5703 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
5704 (thread_rec, windows_add_thread, windows_delete_thread)
5705 (windows_continue): Update.
5706
5707 2020-04-08 Tom Tromey <tromey@adacore.com>
5708
5709 * windows-nat.c (struct windows_thread_info): Remove typedef.
5710 (thread_head): Remove.
5711 (thread_list): New global.
5712 (thread_rec, windows_add_thread, windows_init_thread_list)
5713 (windows_delete_thread, windows_continue): Update.
5714
5715 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
5716
5717 * windows-tdep.h (windows_init_abi): Add comment.
5718 (cygwin_init_abi): New declaration.
5719 * windows-tdep.c: Split signal enumeration in two, one for
5720 Windows and one for Cygwin.
5721 (windows_gdb_signal_to_target): Only deal with signal of the
5722 Windows OS ABI.
5723 (cygwin_gdb_signal_to_target): New function.
5724 (windows_init_abi): Rename to windows_init_abi_common, don't set
5725 gdb_signal_to_target gdbarch method. Add new new function with
5726 this name.
5727 (cygwin_init_abi): New function.
5728 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
5729 comment. Don't call windows_init_abi.
5730 (amd64_windows_init_abi): Add comment, call windows_init_abi.
5731 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
5732 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
5733 i386_windows_init_abi_common, don't call windows_init_abi. Add
5734 a new function of this name.
5735 (i386_cygwin_init_abi): New function.
5736 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
5737 OS ABI Cygwin.
5738
5739 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
5740
5741 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
5742 parameter.c.
5743 (dwarf2_read_gdb_index): Update.
5744
5745 2020-04-07 Kamil Rytarowski <n54@gmx.com>
5746
5747 * nbsd-tdep.c: Include "objfiles.h".
5748 (nbsd_skip_solib_resolver): New.
5749 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
5750
5751 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5752
5753 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
5754 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
5755 with DW_LLE_base_addressx are being emitted in DWARFv5.
5756 Add the newly added kind DW_LOC_OFFSET_PAIR also.
5757 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
5758 unsigned integer.
5759
5760 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5761
5762 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
5763 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
5764 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
5765 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
5766 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
5767 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
5768 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
5769
5770
5771 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5772
5773 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
5774 (read_loclist_index): New function definition.
5775 (lookup_loclist_base): New function definition.
5776 (read_loclist_header): New function definition.
5777 (dwarf2_cu): Add loclist_base and loclist_header field.
5778 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
5779 (read_full_die_1): Read the value of DW_AT_loclists_base.
5780 (read_attribute_reprocess): Handle DW_FORM_loclistx.
5781 (read_attribute_value): Handle DW_FORM_loclistx.
5782 (skip_one_die): Handle DW_FORM_loclistx.
5783 (loclist_header): New structure declaration.
5784 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
5785
5786 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5787
5788 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
5789 constructor. Remove `addr` parameter from other constructor and
5790 add `per_cu` parameter.
5791 * dwarf2/read.c (create_partial_symtab): Update.
5792
5793 2020-04-07 Tom de Vries <tdevries@suse.de>
5794
5795 PR symtab/25796
5796 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
5797 (partial_die_info::fixup): Inherit has_const_value.
5798
5799 2020-04-07 Tom de Vries <tdevries@suse.de>
5800
5801 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
5802 symbols without address.
5803
5804 2020-04-06 Kamil Rytarowski <n54@gmx.com>
5805
5806 * nbsd-nat.h (struct thread_info): Add forward declaration.
5807 (nbsd_nat_target::thread_alive): Add.
5808 (nbsd_nat_target::thread_name): Likewise.
5809 (nbsd_nat_target::update_thread_list): Likewise.
5810 (update_thread_list::post_attach): Likewise.
5811 (post_attach::pid_to_str): Likewise.
5812 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
5813 (nbsd_thread_lister): Add.
5814 (nbsd_nat_target::thread_alive): Likewise.
5815 (nbsd_nat_target::thread_name): Likewise.
5816 (nbsd_add_threads): Likewise.
5817 (update_thread_list::post_attach): Likewise.
5818 (nbsd_nat_target::update_thread_list): Likewise.
5819 (post_attach::pid_to_str): Likewise.
5820
5821 2020-04-06 Tom Tromey <tromey@adacore.com>
5822
5823 * ada-valprint.c (print_variant_part): Extract the variant field.
5824 (print_field_values): Use the field as the outer value when
5825 recursing.
5826
5827 2020-04-06 Tom Tromey <tromey@adacore.com>
5828
5829 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
5830 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
5831 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
5832 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
5833 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
5834
5835 2020-04-06 Tom Tromey <tromey@adacore.com>
5836
5837 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
5838 TYPE_CODE_ERROR.
5839
5840 2020-04-06 Kamil Rytarowski <n54@gmx.com>
5841
5842 * nbsd-tdep.c: Include "gdbarch.h".
5843 Define enum with NetBSD signal numbers.
5844 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
5845 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
5846 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5847 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
5848 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
5849 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
5850 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
5851 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
5852 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
5853 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
5854 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
5855 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
5856
5857 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
5858
5859 PR gdb/25325
5860 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
5861
5862 2020-04-03 Tom Tromey <tromey@adacore.com>
5863
5864 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
5865 Read constant block.
5866
5867 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
5868
5869 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
5870 (gdb_bfd_get_full_section_contents): New declaration.
5871 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
5872 * windows-tdep.c (is_linked_with_cygwin_dll): Use
5873 gdb_bfd_get_full_section_contents.
5874
5875 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
5876
5877 * exec.c (build_section_table): Replace internal_error with
5878 gdb_assert.
5879 (section_table_xfer_memory_partial): Likewise.
5880 * mdebugread.c (parse_partial_symbols): Likewise.
5881 * psymtab.c (lookup_partial_symbol): Likewise.
5882 * utils.c (wrap_here): Likewise.
5883
5884 2020-04-02 Tom Tromey <tromey@adacore.com>
5885
5886 * f-lang.c (build_fortran_types): Use arch_type to initialize
5887 builtin_complex_s32 in the TYPE_CODE_ERROR case.
5888
5889 2020-04-02 Tom Tromey <tromey@adacore.com>
5890
5891 * dwarf2/read.c (partial_die_info::read): Do not create a vector
5892 of attributes.
5893
5894 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
5895 Bernd Edlinger <bernd.edlinger@hotmail.de>
5896 Tom Tromey <tromey@adacore.com>
5897
5898 * buildsym.c (buildsym_compunit::record_line): Remove
5899 deduplication code.
5900
5901 2020-04-02 Tom de Vries <tdevries@suse.de>
5902
5903 PR ada/24671
5904 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
5905
5906 2020-04-02 Tom de Vries <tdevries@suse.de>
5907
5908 * dwarf2/read.c (dwarf2_gdb_index_functions,
5909 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
5910 NULL.
5911 * psymtab.c (psym_lookup_global_symbol_language): New function.
5912 (psym_functions): Init psym_lookup_global_symbol_language with
5913 psym_lookup_global_symbol_language.
5914 * symfile-debug.c (debug_sym_quick_functions): Init
5915 lookup_global_symbol_language with NULL.
5916 * symfile.c (set_initial_language): Remove fixme comment.
5917 * symfile.h (struct quick_symbol_functions): Add
5918 lookup_global_symbol_language.
5919 * symtab.c (find_quick_global_symbol_language): New function.
5920 (find_main_name): Use find_quick_global_symbol_language.
5921
5922 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5923
5924 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
5925
5926 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5927
5928 * buildsym.c (record_line): Fix undefined behavior and preserve
5929 lines at eof.
5930
5931 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5932
5933 * buildsym.c (record_line): Fix the resizing condition.
5934
5935 2020-04-01 Tom Tromey <tom@tromey.com>
5936
5937 * value.h (value_literal_complex): Add comment.
5938 * valops.c (value_literal_complex): Refer to value.h.
5939
5940 2020-04-01 Tom Tromey <tom@tromey.com>
5941
5942 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
5943 (scalar_type): New rule, from typebase.
5944 (typebase): Use scalar_type. Recognize complex types.
5945 (field_name): Handle FLOAT_KEYWORD.
5946 (ident_tokens): Add _Complex and __complex__.
5947
5948 2020-04-01 Tom Tromey <tom@tromey.com>
5949
5950 PR exp/25299:
5951 * valarith.c (promotion_type, complex_binop): New functions.
5952 (scalar_binop): Handle complex numbers. Use promotion_type.
5953 (value_pos, value_neg, value_complement): Handle complex numbers.
5954
5955 2020-04-01 Tom Tromey <tom@tromey.com>
5956
5957 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
5958 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
5959 (parse_number): Handle complex numbers.
5960
5961 2020-04-01 Tom Tromey <tom@tromey.com>
5962
5963 * c-valprint.c (c_decorations): Change complex suffix to "i".
5964
5965 2020-04-01 Tom Tromey <tom@tromey.com>
5966
5967 * valprint.c (generic_value_print_complex): Use accessors.
5968 * value.h (value_real_part, value_imaginary_part): Declare.
5969 * valops.c (value_real_part, value_imaginary_part): New
5970 functions.
5971 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
5972
5973 2020-04-01 Tom Tromey <tom@tromey.com>
5974
5975 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
5976 (read_range_type): Update.
5977 * mdebugread.c (basic_type): Update.
5978 * go-lang.c (build_go_types): Use init_complex_type.
5979 * gdbtypes.h (struct main_type) <complex_type>: New member.
5980 (init_complex_type): Update.
5981 (arch_complex_type): Don't declare.
5982 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
5983 Make name if none given. Use alloc_type_copy. Look for cached
5984 complex type.
5985 (arch_complex_type): Remove.
5986 (gdbtypes_post_init): Use init_complex_type.
5987 * f-lang.c (build_fortran_types): Use init_complex_type.
5988 * dwarf2/read.c (read_base_type): Update.
5989 * d-lang.c (build_d_types): Use init_complex_type.
5990 * ctfread.c (read_base_type): Update.
5991
5992 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5993
5994 * infrun.c (stop_all_threads): Update assertion, plus when
5995 stopping threads, take into account that we might be trying
5996 to stop an all-stop target.
5997 (stop_waiting): Call 'stop_all_threads' if there exists a
5998 non-stop target.
5999
6000 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6001
6002 * target.h (exists_non_stop_target): New function declaration.
6003 * target.c (exists_non_stop_target): New function.
6004
6005 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
6006
6007 PR gdb/24789
6008 * eval.c (is_integral_or_integral_reference): New function.
6009 (evaluate_subexp_standard): Allow integer references in
6010 pointer arithmetic.
6011
6012 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6013
6014 * remote.c (remote_target::remote_parse_stop_reply): Remove the
6015 check for no ptid in the stop reply when the target is non-stop.
6016
6017 2020-04-01 Tom Tromey <tromey@adacore.com>
6018
6019 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
6020 "name" parameter to rvalue reference. Initialize m_name_holder.
6021 <lookup_name_info>: New overloads.
6022 <name>: Return gdb::string_view.
6023 <c_str>: New method.
6024 <make_ignore_params>: Update.
6025 <search_name_hash>: Update.
6026 <language_lookup_name>: Return const char *.
6027 <m_name>: Change type.
6028 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
6029 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
6030 (lookup_name_info::match_any): Update.
6031 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
6032 Update.
6033 * minsyms.c (linkage_name_str): Update.
6034 * language.c (default_symbol_name_matcher): Update.
6035 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
6036 Update.
6037 * ada-lang.c (ada_fold_name): Change parameter to string_view.
6038 (ada_lookup_name_info::ada_lookup_name_info): Update.
6039 (literal_symbol_name_matcher): Update.
6040
6041 2020-04-01 Tom Tromey <tromey@adacore.com>
6042
6043 * psymtab.c (psymtab_search_name): Remove function.
6044 (psym_lookup_symbol): Create search name and lookup name here.
6045 (lookup_partial_symbol): Remove "name" parameter; add
6046 lookup_name.
6047 (psym_expand_symtabs_for_function): Update.
6048
6049 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
6050
6051 PR tui/25597:
6052 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
6053
6054 2020-03-31 Tom Tromey <tromey@adacore.com>
6055
6056 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
6057 memcpy.
6058
6059 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
6060
6061 * features/riscv/32bit-csr.xml: Regenerated.
6062 * features/riscv/64bit-csr.xml: Regenerated.
6063
6064 2020-03-30 Tom Tromey <tromey@adacore.com>
6065
6066 * ada-valprint.c (print_variant_part): Update.
6067 * ada-lang.h (ada_which_variant_applies): Update.
6068 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
6069 outer_valaddr parameters; replace with "outer" value parameter.
6070 (to_fixed_variant_branch_type): Update.
6071
6072 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6073
6074 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
6075 <list>. Remove inclusion of observable.h.
6076 (PPC_DEBUG_CURRENT_VERSION): Move up define.
6077 (struct arch_lwp_info): New struct.
6078 (class ppc_linux_dreg_interface): New class.
6079 (struct ppc_linux_process_info): New struct.
6080 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
6081 <low_new_clone, low_forget_process, low_prepare_to_resume>
6082 <copy_thread_dreg_state, mark_thread_stale>
6083 <mark_debug_registers_changed, register_hw_breakpoint>
6084 <clear_hw_breakpoint, register_wp, clear_wp>
6085 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
6086 <num_memory_accesses, get_trigger_type>
6087 <create_watchpoint_request, hwdebug_point_cmp>
6088 <init_arch_lwp_info, get_arch_lwp_info>
6089 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
6090 methods.
6091 <struct ptid_hash>: New inner struct.
6092 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
6093 members.
6094 (saved_dabr_value, hwdebug_info, max_slots_number)
6095 (struct hw_break_tuple, struct thread_points, ppc_threads)
6096 (have_ptrace_hwdebug_interface)
6097 (hwdebug_find_thread_points_by_tid)
6098 (hwdebug_insert_point, hwdebug_remove_point): Remove.
6099 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
6100 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
6101 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
6102 use m_dreg_interface.
6103 (hwdebug_point_cmp): Change to...
6104 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
6105 reference arguments instead of pointers.
6106 (ppc_linux_nat_target::ranged_break_num_registers): Use
6107 m_dreg_interface.
6108 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
6109 m_dreg_interface. Call register_hw_breakpoint.
6110 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
6111 m_dreg_interface. Call clear_hw_breakpoint.
6112 (get_trigger_type): Change to...
6113 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
6114 comment.
6115 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
6116 use m_dreg_interface. Call register_hw_breakpoint.
6117 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
6118 use m_dreg_interface. Call clear_hw_breakpoint.
6119 (can_use_watchpoint_cond_accel): Change to...
6120 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
6121 method. Update comment, use m_dreg_interface and
6122 m_process_info.
6123 (calculate_dvc): Change to...
6124 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
6125 m_dreg_interface.
6126 (num_memory_accesses): Change to...
6127 (ppc_linux_nat_target::num_memory_accesses): ...this method.
6128 (check_condition): Change to...
6129 (ppc_linux_nat_target::check_condition): ...this method.
6130 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
6131 comment, use m_dreg_interface.
6132 (create_watchpoint_request): Change to...
6133 (ppc_linux_nat_target::create_watchpoint_request): ...this
6134 method. Use m_dreg_interface.
6135 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
6136 m_dreg_interface. Call register_hw_breakpoint or register_wp.
6137 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
6138 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
6139 (ppc_linux_nat_target::low_forget_process)
6140 (ppc_linux_nat_target::low_new_fork)
6141 (ppc_linux_nat_target::low_new_clone)
6142 (ppc_linux_nat_target::low_delete_thread)
6143 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
6144 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
6145 only call mark_thread_stale.
6146 (ppc_linux_thread_exit): Remove.
6147 (ppc_linux_nat_target::stopped_data_address): Change to...
6148 (ppc_linux_nat_target::low_stopped_data_address): This. Add
6149 comment, use m_dreg_interface and m_thread_hw_breakpoints.
6150 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
6151 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
6152 comment. Call low_stopped_data_address.
6153 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
6154 m_dreg_interface.
6155 (ppc_linux_nat_target::masked_watch_num_registers): Use
6156 m_dreg_interface.
6157 (ppc_linux_nat_target::copy_thread_dreg_state)
6158 (ppc_linux_nat_target::mark_thread_stale)
6159 (ppc_linux_nat_target::mark_debug_registers_changed)
6160 (ppc_linux_nat_target::register_hw_breakpoint)
6161 (ppc_linux_nat_target::clear_hw_breakpoint)
6162 (ppc_linux_nat_target::register_wp)
6163 (ppc_linux_nat_target::clear_wp)
6164 (ppc_linux_nat_target::init_arch_lwp_info)
6165 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
6166 (_initialize_ppc_linux_nat): Remove observer callback.
6167
6168 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6169
6170 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
6171 (ppc_linux_nat_target::auxv_parse)
6172 (ppc_linux_nat_target::read_description)
6173 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
6174 Move up.
6175
6176 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6177
6178 * linux-nat.h (low_new_clone): New method.
6179 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
6180
6181 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6182
6183 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
6184 (dbx_expand_psymtab): ... this.
6185 (start_psymtab): Update.
6186 * mdebugread.c (psymtab_to_symtab_1): Rename to...
6187 (mdebug_expand_psymtab): ... this.
6188 (parse_partial_symbols): Update.
6189 (new_psymtab): Update.
6190 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
6191 (xcoff_expand_psymtab): ... this.
6192 (xcoff_start_psymtab): Update.
6193
6194 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6195
6196 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
6197 <expand_dependencies>: ... this.
6198 * psymtab.c (partial_symtab::read_dependencies): Rename to...
6199 (partial_symtab::expand_dependencies): ... this.
6200 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
6201 Update.
6202 (dwarf2_psymtab::expand_psymtab): Update.
6203 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
6204 * mdebugread.c (psymtab_to_symtab_1): Update.
6205 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6206
6207 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6208
6209 * psympriv.h (discard_psymtab): Remove.
6210 * dbxread.c (dbx_end_psymtab): Update.
6211 * xcoffread.c (xcoff_end_psymtab): Update.
6212
6213 2020-03-28 Tom Tromey <tom@tromey.com>
6214
6215 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
6216 comment.
6217
6218 2020-03-28 Tom Tromey <tom@tromey.com>
6219
6220 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
6221
6222 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
6223
6224 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6225
6226 2020-03-26 John Baldwin <jhb@FreeBSD.org>
6227
6228 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
6229
6230 2020-03-26 Tom Tromey <tom@tromey.com>
6231
6232 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
6233 (mark_common_block_symbol_computed, read_tag_string_type)
6234 (attr_to_dynamic_prop, read_subrange_type): Update.
6235 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
6236 to be methods on struct attribute.
6237 (skip_one_die, process_imported_unit_die, read_namespace_alias)
6238 (read_call_site_scope, partial_die_info::read)
6239 (partial_die_info::read, lookup_die_type, follow_die_ref):
6240 Update.
6241 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
6242 from dwarf2_get_ref_die_offset.
6243 (attribute::constant_value): New method, from
6244 dwarf2_get_attr_constant_value.
6245 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
6246 Declare method.
6247 <constant_value>: New method.
6248
6249 2020-03-26 Tom Tromey <tom@tromey.com>
6250
6251 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
6252 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
6253 (dwarf_type_encoding_name): Move to stringify.c.
6254 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
6255 * dwarf2/stringify.c: New file.
6256 * dwarf2/stringify.h: New file.
6257
6258 2020-03-26 Tom Tromey <tom@tromey.com>
6259
6260 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
6261 Rewrite.
6262
6263 2020-03-26 Tom Tromey <tom@tromey.com>
6264
6265 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
6266 methods.
6267 * dwarf2/read.c (lookup_addr_base): Move to die.h.
6268 (lookup_ranges_base): Likewise.
6269 (read_cutu_die_from_dwo, read_full_die_1): Update.
6270
6271 2020-03-26 Tom Tromey <tom@tromey.com>
6272
6273 * dwarf2/read.c (read_import_statement, read_file_scope)
6274 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
6275 (read_lexical_block_scope, read_call_site_scope)
6276 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
6277 (handle_struct_member_die, process_structure_scope)
6278 (update_enumeration_type_from_children)
6279 (process_enumeration_scope, read_array_type, read_common_block)
6280 (read_namespace, read_module, read_subroutine_type): Update.
6281 (sibling_die): Remove.
6282
6283 2020-03-26 Tom Tromey <tom@tromey.com>
6284
6285 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
6286 (build_type_psymtabs_reader, read_structure_type)
6287 (read_enumeration_type, read_full_die_1): Update.
6288 (dwarf2_attr_no_follow): Move to die.h.
6289 * dwarf2/die.h (struct die_info) <attr>: New method.
6290
6291 2020-03-26 Tom Tromey <tom@tromey.com>
6292
6293 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
6294 <base_address>: Now an optional.
6295 (dwarf2_find_base_address, dwarf2_rnglists_process)
6296 (dwarf2_ranges_process, fill_in_loclist_baton)
6297 (dwarf2_symbol_mark_computed): Update.
6298
6299 2020-03-26 Tom Tromey <tom@tromey.com>
6300
6301 * dwarf2/read.c (struct die_info): Move to die.h.
6302 * dwarf2/die.h: New file.
6303
6304 2020-03-26 Tom Tromey <tom@tromey.com>
6305
6306 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
6307 * dwarf2/read.c
6308 (dwarf2_statement_list_fits_in_line_number_section_complaint):
6309 Move to line-header.c.
6310 (read_checked_initial_length_and_offset, read_formatted_entries):
6311 Likewise.
6312 (dwarf_decode_line_header): Split into two.
6313 * dwarf2/line-header.c
6314 (dwarf2_statement_list_fits_in_line_number_section_complaint):
6315 Move from read.c.
6316 (read_checked_initial_length_and_offset, read_formatted_entries):
6317 Likewise.
6318 (dwarf_decode_line_header): New function, split from read.c.
6319
6320 2020-03-26 Tom Tromey <tom@tromey.com>
6321
6322 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
6323 Declare method.
6324 * dwarf2/read.c (read_attribute_value): Update.
6325 (dwarf2_per_objfile::read_line_string): Rename from
6326 read_indirect_line_string.
6327 (read_formatted_entries): Update.
6328
6329 2020-03-26 Tom Tromey <tom@tromey.com>
6330
6331 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
6332 variable.
6333
6334 2020-03-26 Tom Tromey <tom@tromey.com>
6335
6336 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
6337 const.
6338 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
6339 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
6340 parameter const.
6341
6342 2020-03-26 Tom Tromey <tom@tromey.com>
6343
6344 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
6345 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
6346 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
6347 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
6348
6349 2020-03-26 Tom Tromey <tom@tromey.com>
6350
6351 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
6352 file_names_size, file_full_name, file_file_name>: Use const.
6353 <file_name_at, file_names>: Add const overload.
6354 * dwarf2/line-header.c (line_header::file_file_name)
6355 (line_header::file_full_name): Update.
6356
6357 2020-03-26 Tom Tromey <tom@tromey.com>
6358
6359 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
6360 (macro_start_file, consume_improper_spaces)
6361 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
6362 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
6363 (dwarf_decode_macros): Move to macro.c.
6364 * dwarf2/macro.c: New file.
6365 * dwarf2/macro.h: New file.
6366 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
6367
6368 2020-03-26 Tom Tromey <tom@tromey.com>
6369
6370 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
6371 method.
6372 * dwarf2/section.c: New method. From
6373 read_indirect_string_at_offset_from.
6374 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
6375 (read_indirect_string_at_offset_from): Move to section.c.
6376 (read_indirect_string_at_offset): Rewrite.
6377 (read_indirect_line_string_at_offset): Remove.
6378 (read_indirect_string, read_indirect_line_string)
6379 (dwarf_decode_macro_bytes): Update.
6380
6381 2020-03-26 Tom Tromey <tom@tromey.com>
6382
6383 * dwarf2/section.h (struct dwarf2_section_info)
6384 <overload_complaint>: Declare.
6385 (dwarf2_section_buffer_overflow_complaint): Don't declare.
6386 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
6387 Rename from dwarf2_section_buffer_overflow_complaint.
6388 * dwarf2/read.c (skip_one_die, partial_die_info::read)
6389 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
6390
6391 2020-03-26 Tom Tromey <tom@tromey.com>
6392
6393 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
6394 Declare.
6395 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
6396 Move from read.c.
6397 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
6398 to section.c.
6399
6400 2020-03-26 Tom Tromey <tom@tromey.com>
6401
6402 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
6403
6404 2020-03-26 Tom Tromey <tom@tromey.com>
6405
6406 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
6407 "builder".
6408 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
6409 parameter.
6410 (dwarf_decode_macros): Update.
6411
6412 2020-03-26 Tom Tromey <tom@tromey.com>
6413
6414 * dwarf2/read.c (read_attribute_value): Update.
6415 (read_indirect_string_from_dwz): Move to dwz.c; change into
6416 method.
6417 (dwarf_decode_macro_bytes): Update.
6418 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
6419 * dwarf2/dwz.c: New file.
6420 * Makefile.in (COMMON_SFILES): Add dwz.c.
6421
6422 2020-03-26 Tom Tromey <tom@tromey.com>
6423
6424 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
6425 * dwarf2/read.c: Add include.
6426 * dwarf2/index-write.c: Add include.
6427 * dwarf2/index-cache.c: Add include.
6428 * dwarf2/dwz.h: New file.
6429
6430 2020-03-25 Tom Tromey <tom@tromey.com>
6431
6432 * compile/compile-object-load.c (get_out_value_type): Mention
6433 correct symbol name in error message.
6434
6435 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
6436
6437 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6438
6439 2020-03-25 Tom de Vries <tdevries@suse.de>
6440
6441 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
6442 * symmisc.c (dump_symtab_1): Print user and includes fields.
6443 (maintenance_info_symtabs): Same.
6444
6445 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
6446
6447 PR gdb/25534
6448 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
6449 (riscv_regcache_cooked_write): New function.
6450 (riscv_push_dummy_call): Use new function.
6451 (riscv_return_value): Likewise.
6452
6453 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
6454
6455 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
6456 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
6457 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
6458 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
6459 * infrun.c (follow_fork): Likewise.
6460 (follow_fork_inferior): Likewise.
6461 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
6462 * linux-nat.h (class linux_nat_target): Likewise.
6463 * remote.c (class remote_target) <follow_fork>: Likewise.
6464 (remote_target::follow_fork): Likewise.
6465 * target-delegates.c: Re-generate.
6466 * target.c (default_follow_fork): Likewise.
6467 (target_follow_fork): Likewise.
6468 * target.h (struct target_ops) <follow_fork>: Likewise.
6469 (target_follow_fork): Likewise.
6470
6471 2020-03-24 Tom de Vries <tdevries@suse.de>
6472
6473 * psymtab.c (maintenance_info_psymtabs): Print user field.
6474
6475 2020-03-20 Tom Tromey <tromey@adacore.com>
6476
6477 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
6478 const.
6479 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
6480 const.
6481
6482 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
6483
6484 * ptrace.m4: Don't check for ptrace declaration.
6485 * config.in: Re-generate.
6486 * configure: Re-generate.
6487 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
6488 not defined.
6489
6490 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6491
6492 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
6493 `PTRACE_TYPE_RET'.
6494 * i386-bsd-nat.c (gdb_ptrace): Likewise.
6495 * sparc-nat.c (gdb_ptrace): Likewise.
6496 * x86-bsd-nat.c (gdb_ptrace): Likewise.
6497
6498 2020-03-20 Tom Tromey <tromey@adacore.com>
6499
6500 * c-exp.y (lex_one_token): Fix assert.
6501
6502 2020-03-20 Tom Tromey <tromey@adacore.com>
6503
6504 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
6505 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
6506 strncpy call.
6507
6508 2020-03-20 Tom Tromey <tromey@adacore.com>
6509
6510 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
6511
6512 2020-03-20 Tom Tromey <tromey@adacore.com>
6513
6514 * ada-valprint.c (print_variant_part): Remove parameters; switch
6515 to value-based API.
6516 (print_field_values): Likewise.
6517 (ada_val_print_struct_union): Likewise.
6518 (ada_value_print_1): Update.
6519
6520 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6521
6522 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
6523 nbsd_nat_target instead of inf_ptrace_target.
6524 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6525 nbsd_nat_target.
6526
6527 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6528
6529 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
6530 it to the ptrace call.
6531 * (store_registers): Likewise.
6532
6533 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6534
6535 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
6536 it to the ptrace call.
6537 * (store_registers): Likewise.
6538
6539 2020-03-19 Luis Machado <luis.machado@linaro.org>
6540
6541 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
6542 valid, fetch vg value from ptrace.
6543
6544 2020-03-19 Kamil Rytarowski <n54@gmx.com>
6545 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
6546 * inf-ptrace.c: Likewise.
6547 * (gdb_ptrace): Add.
6548 * (inf_ptrace_target::resume): Update.
6549 * (inf_ptrace_target::xfer_partial): Likewise.
6550 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
6551 * (inf_ptrace_peek_poke): Update.
6552
6553 2020-03-19 Kamil Rytarowski <n54@gmx.com>
6554
6555 * x86-bsd-nat.c (gdb_ptrace): New.
6556 * (x86bsd_dr_set): Add new argument `ptid'.
6557 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
6558 x86bsd_dr_set_addr): Update.
6559
6560 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6561
6562 * remote.c (remote_target::process_stop_reply): Handle events for
6563 all threads differently.
6564
6565 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6566
6567 * completer.c (completion_tracker::remove_completion): Define new
6568 function.
6569 * completer.h (completion_tracker::remove_completion): Declare new
6570 function.
6571 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
6572 when adding a C++ function symbol.
6573
6574 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6575
6576 * completer.c (completion_tracker::completion_hash_entry): Define
6577 new class.
6578 (advance_to_filename_complete_word_point): Call
6579 recompute_lowest_common_denominator.
6580 (completion_tracker::completion_tracker): Call discard_completions
6581 to setup the hash table.
6582 (completion_tracker::discard_completions): Allow for being called
6583 from the constructor, pass new equal function, and element deleter
6584 when constructing the hash table. Initialise new class member
6585 variables.
6586 (completion_tracker::maybe_add_completion): Remove use of
6587 m_entries_vec, and store more information into m_entries_hash.
6588 (completion_tracker::recompute_lcd_visitor): New function, most
6589 content taken from...
6590 (completion_tracker::recompute_lowest_common_denominator):
6591 ...here, this now just visits each item in the hash calling the
6592 above visitor.
6593 (completion_tracker::build_completion_result): Remove use of
6594 m_entries_vec, call recompute_lowest_common_denominator.
6595 * completer.h (completion_tracker::have_completions): Remove use
6596 of m_entries_vec.
6597 (completion_tracker::completion_hash_entry): Declare new class.
6598 (completion_tracker::recompute_lowest_common_denominator): Change
6599 function signature.
6600 (completion_tracker::recompute_lcd_visitor): Declare new function.
6601 (completion_tracker::m_entries_vec): Delete.
6602 (completion_tracker::m_entries_hash): Initialize to NULL.
6603 (completion_tracker::m_lowest_common_denominator_valid): New
6604 member variable.
6605 (completion_tracker::m_lowest_common_denominator_max_length): New
6606 member variable.
6607
6608 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6609
6610 * regformats/regdef.h: Put reg in gdb namespace.
6611
6612 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6613
6614 * i386-bsd-nat.c (gdb_ptrace): New.
6615 * (i386bsd_fetch_inferior_registers,
6616 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
6617 * (i386bsd_fetch_inferior_registers,
6618 i386bsd_store_inferior_registers) Use gdb_ptrace.
6619
6620 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6621
6622 * amd64-bsd-nat.c (gdb_ptrace): New.
6623 * (amd64bsd_fetch_inferior_registers,
6624 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
6625 * (amd64bsd_fetch_inferior_registers,
6626 amd64bsd_store_inferior_registers) Use gdb_ptrace.
6627
6628 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6629
6630 * user-regs.c (user_reg::read): Rename to...
6631 (user_reg::xread): ...this.
6632 * (append_user_reg): Rename argument `read' to `xread'.
6633 * (user_reg_add_builtin): Likewise.
6634 * (user_reg_add): Likewise.
6635 * (value_of_user_reg): Likewise.
6636
6637 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6638
6639 * sparc-nat.c (gdb_ptrace): New.
6640 * sparc-nat.c (sparc_fetch_inferior_registers)
6641 (sparc_store_inferior_registers) Remove obsolete comment.
6642 * sparc-nat.c (sparc_fetch_inferior_registers)
6643 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
6644 * sparc-nat.c (sparc_fetch_inferior_registers)
6645 (sparc_store_inferior_registers) Use gdb_ptrace.
6646
6647 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6648
6649 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
6650 it to the ptrace call.
6651 * sh-nbsd-nat.c (store_registers): Likewise.
6652
6653 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6654
6655 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
6656 nbsd_nat_target instead of inf_ptrace_target.
6657 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6658 nbsd_nat_target.
6659
6660 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6661
6662 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
6663
6664 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6665
6666 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
6667 <sys/sysctl.h>.
6668 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
6669
6670 2020-03-17 Tom de Vries <tdevries@suse.de>
6671
6672 PR gdb/23710
6673 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
6674 fields.
6675 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
6676 fields.
6677 (process_imported_unit_die): Skip import of c++ CUs.
6678
6679 2020-03-16 Tom Tromey <tom@tromey.com>
6680
6681 * p-valprint.c (pascal_object_print_value): Initialize
6682 base_value.
6683
6684 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
6685 Shahab Vahedi <shahab@synopsys.com>
6686
6687 * Makefile.in: Add arch/arc.o
6688 * configure.tgt: Likewise.
6689 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
6690 (_initialize_arc_tdep): Don't initialize old target descriptions.
6691 (arc_read_description): New function to cache target descriptions.
6692 * arc-tdep.h (arc_read_description): Add proto type.
6693 * arch/arc.c: New file.
6694 * arch/arc.h: Likewise.
6695 * features/Makefile: Replace old target descriptions with new.
6696 * features/arc-arcompact.c: Remove.
6697 * features/arc-arcompact.xml: Likewise.
6698 * features/arc-v2.c: Likewise
6699 * features/arc-v2.xml: Likewise
6700 * features/arc/aux-arcompact.xml: New file.
6701 * features/arc/aux-v2.xml: Likewise.
6702 * features/arc/core-arcompact.xml: Likewise.
6703 * features/arc/core-v2.xml: Likewise.
6704 * features/arc/aux-arcompact.c: Generate.
6705 * features/arc/aux-v2.c: Likewise.
6706 * features/arc/core-arcompact.c: Likewise.
6707 * features/arc/core-v2.c: Likewise.
6708 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
6709
6710 2020-03-16 Tom Tromey <tromey@adacore.com>
6711
6712 PR gdb/25663:
6713 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
6714 putting value into bcache.
6715
6716 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6717
6718 PR gdb/21500
6719 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
6720 to...
6721 (amd64_windows_init_abi_common): ... this. Don't set size of
6722 long type.
6723 (amd64_windows_init_abi): New function.
6724 (amd64_cygwin_init_abi): New function.
6725 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
6726 the Cygwin OS ABI.
6727 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
6728 comment.
6729
6730 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6731
6732 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
6733 * windows-tdep.c (CYGWIN_DLL_NAME): New.
6734 (pe_import_directory_entry): New struct type.
6735 (is_linked_with_cygwin_dll): New function.
6736 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
6737 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
6738 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
6739
6740 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6741
6742 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
6743 i386_cygwin_core_osabi_sniffer.
6744
6745 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6746
6747 * i386-cygwin-tdep.c: Rename to...
6748 * i386-windows-tdep.c: ... this.
6749 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
6750 i386-windows-tdep.c.
6751 * configure.tgt: Likewise.
6752
6753 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6754
6755 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
6756 * osabi.c (gdb_osabi_names): Add "Windows".
6757 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
6758 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
6759 (i386_cygwin_core_osabi_sniffer): New function, extracted from
6760 i386_cygwin_osabi_sniffer.
6761 (_initialize_i386_cygwin_tdep): Register OS ABI
6762 GDB_OSABI_WINDOWS for i386.
6763 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
6764 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
6765 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
6766 for x86-64.
6767 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
6768 when the target matches '*-*-mingw*'.
6769
6770 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6771
6772 * defs.h (enum gdb_osabi): Move to...
6773 * osabi.h (enum gdb_osabi): ... here.
6774 * gdbarch.sh: Include osabi.h in gdbarch.h.
6775 * gdbarch.h: Re-generate.
6776
6777 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6778
6779 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
6780 function.
6781 (_initialize_amd64_windows_tdep): Register osabi sniffer.
6782
6783 2020-03-14 Tom Tromey <tom@tromey.com>
6784
6785 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
6786 for C++.
6787 (c_type_print_modifier): Likewise. Add "language" parameter.
6788 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
6789 (c_type_print_base_1): Update.
6790 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
6791 constants.
6792 * type-stack.c (type_stack::insert): Handle tp_atomic and
6793 tp_restrict.
6794 (type_stack::follow_type_instance_flags): Likewise.
6795 (type_stack::follow_types): Likewise. Merge type-following code.
6796 * c-exp.y (RESTRICT, ATOMIC): New tokens.
6797 (space_identifier, cv_with_space_id)
6798 (const_or_volatile_or_space_identifier_noopt)
6799 (const_or_volatile_or_space_identifier): Remove.
6800 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
6801 rules.
6802 (ptr_operator, typebase): Update.
6803 (enum token_flag) <FLAG_C>: New constant.
6804 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
6805 "_Atomic".
6806 (lex_one_token): Handle FLAG_C.
6807
6808 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6809
6810 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
6811 it to the ptrace call.
6812 * m68k-bsd-nat.c (store_registers): Likewise.
6813
6814 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6815
6816 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
6817 gdb_byte *.
6818 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
6819 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
6820 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
6821
6822 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6823
6824 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
6825 nbsd_nat_target instead of inf_ptrace_target.
6826 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6827 nbsd_nat_target.
6828
6829 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6830
6831 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
6832 register_t.
6833
6834 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6835
6836 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
6837 it to the ptrace call.
6838 * alpha-bsd-nat.c (store_registers): Likewise.
6839
6840 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6841
6842 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
6843 includes.
6844 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
6845 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
6846 fill_fpregset): Likewise.
6847
6848 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6849
6850 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
6851 nbsd_nat_target instead of inf_ptrace_target.
6852 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6853 nbsd_nat_target.
6854
6855 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6856
6857 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
6858 register_t.
6859
6860 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6861
6862 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
6863 it to the ptrace call.
6864 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
6865 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
6866 * arm-nbsd-nat.c (store_register): Likewise.
6867 * arm-nbsd-nat.c (store_regs): Likewise.
6868 * arm-nbsd-nat.c (store_fp_register): Likewise.
6869 * arm-nbsd-nat.c (store_fp_regs): Likewise.
6870
6871 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6872
6873 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
6874 nbsd_nat_target instead of inf_ptrace_target.
6875 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6876 nbsd_nat_target.
6877
6878 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6879
6880 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
6881 it to the ptrace call.
6882 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
6883
6884 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6885
6886 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
6887 it to the ptrace call.
6888 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
6889
6890 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6891
6892 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
6893 gdb_byte *.
6894 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
6895
6896 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6897
6898 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
6899 instead of inf_ptrace_target.
6900 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6901 nbsd_nat_target.
6902
6903 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6904
6905 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6906 register_t.
6907
6908 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6909
6910 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6911 register_t.
6912
6913 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6914
6915 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
6916 register_t.
6917
6918 2020-03-13 Tom Tromey <tom@tromey.com>
6919
6920 * value.h (val_print): Don't declare.
6921 * valprint.h (val_print_array_elements)
6922 (val_print_scalar_formatted, generic_val_print): Don't declare.
6923 * valprint.c (generic_val_print_array): Take a struct value.
6924 (generic_val_print_ptr, generic_val_print_memberptr)
6925 (generic_val_print_bool, generic_val_print_int)
6926 (generic_val_print_char, generic_val_print_complex)
6927 (generic_val_print): Remove.
6928 (generic_value_print): Update.
6929 (do_val_print): Remove unused parameters. Don't call
6930 la_val_print.
6931 (val_print): Remove.
6932 (common_val_print): Update. Don't call value_check_printable.
6933 (val_print_scalar_formatted, val_print_array_elements): Remove.
6934 * rust-lang.c (rust_val_print): Remove.
6935 (rust_language_defn): Update.
6936 * p-valprint.c (pascal_val_print): Remove.
6937 (pascal_value_print_inner): Update.
6938 (pascal_object_print_val_fields, pascal_object_print_val):
6939 Remove.
6940 (pascal_object_print_static_field): Update.
6941 * p-lang.h (pascal_val_print): Don't declare.
6942 * p-lang.c (pascal_language_defn): Update.
6943 * opencl-lang.c (opencl_language_defn): Update.
6944 * objc-lang.c (objc_language_defn): Update.
6945 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
6946 * m2-lang.h (m2_val_print): Don't declare.
6947 * m2-lang.c (m2_language_defn): Update.
6948 * language.h (struct language_defn) <la_val_print>: Remove.
6949 * language.c (unk_lang_value_print_inner): Rename. Change
6950 argument types.
6951 (unknown_language_defn, auto_language_defn): Update.
6952 * go-valprint.c (go_val_print): Remove.
6953 * go-lang.h (go_val_print): Don't declare.
6954 * go-lang.c (go_language_defn): Update.
6955 * f-valprint.c (f_val_print): Remove.
6956 * f-lang.h (f_value_print): Don't declare.
6957 * f-lang.c (f_language_defn): Update.
6958 * d-valprint.c (d_val_print): Remove.
6959 * d-lang.h (d_value_print): Don't declare.
6960 * d-lang.c (d_language_defn): Update.
6961 * cp-valprint.c (cp_print_value_fields)
6962 (cp_print_value_fields_rtti, cp_print_value): Remove.
6963 (cp_print_static_field): Update.
6964 * c-valprint.c (c_val_print_array, c_val_print_ptr)
6965 (c_val_print_struct, c_val_print_union, c_val_print_int)
6966 (c_val_print_memberptr, c_val_print): Remove.
6967 * c-lang.h (c_val_print_array, cp_print_value_fields)
6968 (cp_print_value_fields_rtti): Don't declare.
6969 * c-lang.c (c_language_defn, cplus_language_defn)
6970 (asm_language_defn, minimal_language_defn): Update.
6971 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
6972 (ada_val_print_enum): Take a struct value.
6973 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
6974 (ada_val_print): Remove.
6975 (ada_value_print_1): Update.
6976 (printable_val_type): Remove.
6977 * ada-lang.h (ada_val_print): Don't declare.
6978 * ada-lang.c (ada_language_defn): Update.
6979
6980 2020-03-13 Tom Tromey <tom@tromey.com>
6981
6982 * valprint.c (do_val_print): Update.
6983 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
6984 a struct value.
6985 (value_to_value_object_no_release): Declare.
6986 * python/py-value.c (value_to_value_object_no_release): New
6987 function.
6988 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
6989 struct value.
6990 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
6991 function.
6992 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
6993 a struct value.
6994 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
6995 Declare.
6996 (gdbscm_apply_val_pretty_printer): Take a struct value.
6997 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
6998 value.
6999 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
7000 value.
7001 * extension-priv.h (struct extension_language_ops)
7002 <apply_val_pretty_printer>: Take a struct value.
7003 * cp-valprint.c (cp_print_value): Create a struct value.
7004 (cp_print_value): Update.
7005
7006 2020-03-13 Tom Tromey <tom@tromey.com>
7007
7008 * ada-valprint.c (print_field_values): Call common_val_print.
7009
7010 2020-03-13 Tom Tromey <tom@tromey.com>
7011
7012 * ada-valprint.c (val_print_packed_array_elements): Remove
7013 bitoffset and val parameters. Call common_val_print.
7014 (ada_val_print_string): Remove offset, address, and original_value
7015 parameters.
7016 (ada_val_print_array): Update.
7017 (ada_value_print_array): New function.
7018 (ada_value_print_1): Call it.
7019
7020 2020-03-13 Tom Tromey <tom@tromey.com>
7021
7022 * ada-valprint.c (ada_value_print): Use common_val_print.
7023
7024 2020-03-13 Tom Tromey <tom@tromey.com>
7025
7026 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
7027
7028 2020-03-13 Tom Tromey <tom@tromey.com>
7029
7030 * ada-valprint.c (ada_value_print_num): New function.
7031 (ada_value_print_1): Use it.
7032
7033 2020-03-13 Tom Tromey <tom@tromey.com>
7034
7035 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
7036
7037 2020-03-13 Tom Tromey <tom@tromey.com>
7038
7039 * ada-valprint.c (ada_value_print_ptr): New function.
7040 (ada_value_print_1): Use it.
7041
7042 2020-03-13 Tom Tromey <tom@tromey.com>
7043
7044 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
7045 call common_val_print.
7046 (ada_val_print_1): Update.
7047 (ada_value_print_1): New function.
7048 (ada_value_print_inner): Rewrite.
7049
7050 2020-03-13 Tom Tromey <tom@tromey.com>
7051
7052 * cp-valprint.c (cp_print_value_fields): Update.
7053 (cp_print_value): New function.
7054
7055 2020-03-13 Tom Tromey <tom@tromey.com>
7056
7057 * m2-valprint.c (m2_value_print_inner): Use
7058 cp_print_value_fields.
7059 * cp-valprint.c (cp_print_value_fields): New function.
7060 * c-valprint.c (c_value_print_struct): New function.
7061 (c_value_print_inner): Use c_value_print_struct.
7062 * c-lang.h (cp_print_value_fields): Declare.
7063
7064 2020-03-13 Tom Tromey <tom@tromey.com>
7065
7066 * c-valprint.c (c_value_print_array): New function.
7067 (c_value_print_inner): Use it.
7068
7069 2020-03-13 Tom Tromey <tom@tromey.com>
7070
7071 * c-valprint.c (c_value_print_memberptr): New function.
7072 (c_value_print_inner): Use it.
7073
7074 2020-03-13 Tom Tromey <tom@tromey.com>
7075
7076 * c-valprint.c (c_value_print_int): New function.
7077 (c_value_print_inner): Use it.
7078
7079 2020-03-13 Tom Tromey <tom@tromey.com>
7080
7081 * c-valprint.c (c_value_print_ptr): New function.
7082 (c_value_print_inner): Use it.
7083
7084 2020-03-13 Tom Tromey <tom@tromey.com>
7085
7086 * c-valprint.c (c_value_print_inner): Rewrite.
7087
7088 2020-03-13 Tom Tromey <tom@tromey.com>
7089
7090 * valprint.c (generic_value_print_complex): New function.
7091 (generic_value_print): Use it.
7092
7093 2020-03-13 Tom Tromey <tom@tromey.com>
7094
7095 * valprint.c (generic_val_print_float): Don't call
7096 val_print_scalar_formatted.
7097 (generic_val_print, generic_value_print): Update.
7098
7099 2020-03-13 Tom Tromey <tom@tromey.com>
7100
7101 * valprint.c (generic_value_print_char): New function
7102 (generic_value_print): Use it.
7103
7104 2020-03-13 Tom Tromey <tom@tromey.com>
7105
7106 * valprint.c (generic_value_print_int): New function.
7107 (generic_value_print): Use it.
7108
7109 2020-03-13 Tom Tromey <tom@tromey.com>
7110
7111 * valprint.c (generic_value_print_bool): New function.
7112 (generic_value_print): Use it.
7113
7114 2020-03-13 Tom Tromey <tom@tromey.com>
7115
7116 * valprint.c (generic_val_print_func): Simplify.
7117 (generic_val_print, generic_value_print): Update.
7118
7119 2020-03-13 Tom Tromey <tom@tromey.com>
7120
7121 * valprint.c (generic_val_print_flags): Remove.
7122 (generic_val_print, generic_value_print): Update.
7123 (val_print_type_code_flags): Add original_value parameter.
7124
7125 2020-03-13 Tom Tromey <tom@tromey.com>
7126
7127 * valprint.c (generic_val_print): Update.
7128 (generic_value_print): Update.
7129 * valprint.c (generic_val_print_enum): Don't call
7130 val_print_scalar_formatted.
7131
7132 2020-03-13 Tom Tromey <tom@tromey.com>
7133
7134 * valprint.c (generic_value_print): Call generic_value_print_ptr.
7135 * valprint.c (generic_value_print_ptr): New function.
7136
7137 2020-03-13 Tom Tromey <tom@tromey.com>
7138
7139 * valprint.c (generic_value_print): Rewrite.
7140
7141 2020-03-13 Tom Tromey <tom@tromey.com>
7142
7143 * p-valprint.c (pascal_object_print_value_fields)
7144 (pascal_object_print_value): New functions.
7145
7146 2020-03-13 Tom Tromey <tom@tromey.com>
7147
7148 * p-valprint.c (pascal_value_print_inner): Rewrite.
7149
7150 2020-03-13 Tom Tromey <tom@tromey.com>
7151
7152 * f-valprint.c (f_value_print_innner): Rewrite.
7153
7154 2020-03-13 Tom Tromey <tom@tromey.com>
7155
7156 * m2-valprint.c (m2_print_unbounded_array): New overload.
7157 (m2_print_unbounded_array): Update.
7158 (m2_print_array_contents): Take a struct value.
7159 (m2_value_print_inner): Rewrite.
7160
7161 2020-03-13 Tom Tromey <tom@tromey.com>
7162
7163 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
7164 (d_value_print_inner): New function.
7165 * d-lang.h (d_value_print_inner): Declare.
7166 * d-lang.c (d_language_defn): Use d_value_print_inner.
7167
7168 2020-03-13 Tom Tromey <tom@tromey.com>
7169
7170 * go-valprint.c (go_value_print_inner): New function.
7171 * go-lang.h (go_value_print_inner): Declare.
7172 * go-lang.c (go_language_defn): Use go_value_print_inner.
7173
7174 2020-03-13 Tom Tromey <tom@tromey.com>
7175
7176 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
7177 API.
7178 (rust_val_print): Rewrite.
7179 (rust_value_print_inner): New function, from rust_val_print.
7180 (rust_language_defn): Use rust_value_print_inner.
7181
7182 2020-03-13 Tom Tromey <tom@tromey.com>
7183
7184 * ada-valprint.c (ada_value_print_inner): New function.
7185 * ada-lang.h (ada_value_print_inner): Declare.
7186 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
7187
7188 2020-03-13 Tom Tromey <tom@tromey.com>
7189
7190 * f-valprint.c (f_value_print_innner): New function.
7191 * f-lang.h (f_value_print_innner): Declare.
7192 * f-lang.c (f_language_defn): Use f_value_print_innner.
7193
7194 2020-03-13 Tom Tromey <tom@tromey.com>
7195
7196 * p-valprint.c (pascal_value_print_inner): New function.
7197 * p-lang.h (pascal_value_print_inner): Declare.
7198 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
7199
7200 2020-03-13 Tom Tromey <tom@tromey.com>
7201
7202 * m2-valprint.c (m2_value_print_inner): New function.
7203 * m2-lang.h (m2_value_print_inner): Declare.
7204 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
7205
7206 2020-03-13 Tom Tromey <tom@tromey.com>
7207
7208 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
7209 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
7210 * c-valprint.c (c_value_print_inner): New function.
7211 * c-lang.h (c_value_print_inner): Declare.
7212 * c-lang.c (c_language_defn, cplus_language_defn)
7213 (asm_language_defn, minimal_language_defn): Use
7214 c_value_print_inner.
7215
7216 2020-03-13 Tom Tromey <tom@tromey.com>
7217
7218 * p-valprint.c (pascal_object_print_value_fields): Now static.
7219 * p-lang.h (pascal_object_print_value_fields): Don't declare.
7220
7221 2020-03-13 Tom Tromey <tom@tromey.com>
7222
7223 * c-valprint.c (c_val_print_array): Simplify.
7224
7225 2020-03-13 Tom Tromey <tom@tromey.com>
7226
7227 * valprint.c (value_print_array_elements): New function.
7228 * valprint.h (value_print_array_elements): Declare.
7229
7230 2020-03-13 Tom Tromey <tom@tromey.com>
7231
7232 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
7233 * mips-tdep.c (mips_print_register): Use
7234 value_print_scalar_formatted.
7235
7236 2020-03-13 Tom Tromey <tom@tromey.com>
7237
7238 * valprint.h (value_print_scalar_formatted): Declare.
7239 * valprint.c (value_print_scalar_formatted): New function.
7240
7241 2020-03-13 Tom Tromey <tom@tromey.com>
7242
7243 * valprint.h (generic_value_print): Declare.
7244 * valprint.c (generic_value_print): New function.
7245
7246 2020-03-13 Tom Tromey <tom@tromey.com>
7247
7248 * valprint.c (do_val_print): Call la_value_print_inner, if
7249 available.
7250 * rust-lang.c (rust_language_defn): Update.
7251 * p-lang.c (pascal_language_defn): Update.
7252 * opencl-lang.c (opencl_language_defn): Update.
7253 * objc-lang.c (objc_language_defn): Update.
7254 * m2-lang.c (m2_language_defn): Update.
7255 * language.h (struct language_defn) <la_value_print_inner>: New
7256 member.
7257 * language.c (unknown_language_defn, auto_language_defn): Update.
7258 * go-lang.c (go_language_defn): Update.
7259 * f-lang.c (f_language_defn): Update.
7260 * d-lang.c (d_language_defn): Update.
7261 * c-lang.c (c_language_defn, cplus_language_defn)
7262 (asm_language_defn, minimal_language_defn): Update.
7263 * ada-lang.c (ada_language_defn): Update.
7264
7265 2020-03-13 Tom Tromey <tom@tromey.com>
7266
7267 * c-valprint.c (c_value_print): Use common_val_print.
7268
7269 2020-03-13 Tom Tromey <tom@tromey.com>
7270
7271 * cp-valprint.c (cp_print_static_field): Use common_val_print.
7272
7273 2020-03-13 Tom Tromey <tom@tromey.com>
7274
7275 * f-valprint.c (f77_print_array_1, f_val_print): Use
7276 common_val_print.
7277
7278 2020-03-13 Tom Tromey <tom@tromey.com>
7279
7280 * riscv-tdep.c (riscv_print_one_register_info): Use
7281 common_val_print.
7282
7283 2020-03-13 Tom Tromey <tom@tromey.com>
7284
7285 * mi/mi-main.c (output_register): Use common_val_print.
7286
7287 2020-03-13 Tom Tromey <tom@tromey.com>
7288
7289 * infcmd.c (default_print_one_register_info): Use
7290 common_val_print.
7291
7292 2020-03-13 Tom Tromey <tom@tromey.com>
7293
7294 * valprint.h (common_val_print_checked): Declare.
7295 * valprint.c (common_val_print_checked): New function.
7296 * stack.c (print_frame_arg): Use common_val_print_checked.
7297
7298 2020-03-13 Tom Tromey <tom@tromey.com>
7299
7300 * valprint.c (do_val_print): New function, from val_print.
7301 (val_print): Use do_val_print.
7302 (common_val_print): Use do_val_print.
7303
7304 2020-03-13 Tom Tromey <tom@tromey.com>
7305
7306 * valprint.c (value_print): Use scoped_value_mark.
7307
7308 2020-03-13 Tom de Vries <tdevries@suse.de>
7309
7310 PR symtab/25646
7311 * psymtab.c (partial_symtab::partial_symtab): Don't set
7312 globals_offset and statics_offset. Push element onto
7313 current_global_psymbols and current_static_psymbols stacks.
7314 (concat): New function.
7315 (end_psymtab_common): Set globals_offset and statics_offset. Pop
7316 element from current_global_psymbols and current_static_psymbols
7317 stacks. Concat popped elements to global_psymbols and
7318 static_symbols.
7319 (add_psymbol_to_list): Use current_global_psymbols and
7320 current_static_psymbols stacks.
7321 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
7322 current_static_psymbols fields.
7323
7324 2020-03-12 Christian Biesinger <cbiesinger@google.com>
7325
7326 * corelow.c (sniff_core_bfd): Remove.
7327 (class core_target) <m_core_vec>: Remove.
7328 (core_target::core_target): Update.
7329 (core_file_fns): Remove.
7330 (deprecated_add_core_fns): Remove.
7331 (default_core_sniffer): Remove.
7332 (sniff_core_bfd): Remove.
7333 (default_check_format): Remove.
7334 (gdb_check_format): Remove.
7335 (core_target_open): Update.
7336 (core_target::get_core_register_section): Update.
7337 (get_core_registers_cb): Update.
7338 (core_target::fetch_registers): Update.
7339 * gdbcore.h (struct core_fns): Remove.
7340 (deprecated_add_core_fns): Remove.
7341 (default_core_sniffer): Remove.
7342 (default_check_format): Remove.
7343
7344 2020-03-12 Tom Tromey <tom@tromey.com>
7345
7346 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
7347 CORE_ADDR.
7348 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
7349
7350 2020-03-12 Tom Tromey <tom@tromey.com>
7351
7352 * remote.c (remote_target::download_tracepoint)
7353 (remote_target::enable_tracepoint)
7354 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
7355 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
7356 sprintf_vma.
7357
7358 2020-03-12 Tom Tromey <tom@tromey.com>
7359
7360 * symfile-mem.c: Update CORE_ADDR size assert.
7361
7362 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7363
7364 * selftest.m4: Move to gdbsupport/.
7365 * acinclude.m4: Update path to selftest.m4.
7366
7367 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7368
7369 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
7370 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
7371 gdbarch-selfselftests.c and selftest-arch.c.
7372 (SUBDIR_UNITTESTS_OBS): Rename to...
7373 (SELFTESTS_OBS): ... this.
7374 (COMMON_SFILES): Remove disasm-selftests.c and
7375 gdbarch-selftests.c.
7376 * configure.ac: Don't add selftest-arch.{c,o} to
7377 CONFIG_{SRCS,OBS}.
7378 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
7379 preprocessor conditions.
7380
7381 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7382
7383 * configure.ac: Don't source bfd/development.sh.
7384 * selftest.m4: Modify comment.
7385 * configure: Re-generate.
7386
7387 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7388
7389 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
7390 not "true" or "false".
7391 * configure: Re-generate.
7392
7393 2020-03-12 Christian Biesinger <cbiesinger@google.com>
7394
7395 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
7396 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
7397 renamed to arm_nbsd_supply_gregset.
7398 (fetch_register): Update to call arm_nbsd_supply_gregset.
7399 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
7400 (arm_netbsd_nat_target::fetch_registers): Update.
7401 (fetch_elfcore_registers): Removed.
7402 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
7403 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
7404 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
7405 not require NetBSD system headers.
7406 (arm_nbsd_regset): New struct.
7407 (arm_nbsd_iterate_over_regset_sections): New function.
7408 (arm_netbsd_init_abi_common): Updated to call
7409 set_gdbarch_iterate_over_regset_sections.
7410 * arm-nbsd-tdep.h: New file.
7411
7412 2020-03-11 Kevin Buettner <kevinb@redhat.com>
7413
7414 * symtab.c (find_pc_sect_line): Add check which prevents infinite
7415 recursion.
7416
7417 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
7418
7419 * configure: Re-generate.
7420
7421 2020-03-11 Tom Tromey <tromey@adacore.com>
7422
7423 * ada-typeprint.c (print_choices): Fix comment.
7424
7425 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
7426
7427 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
7428 previous item in the list, when the list has no items.
7429
7430 2020-03-11 Tom de Vries <tdevries@suse.de>
7431
7432 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
7433 PROP_LOCLIST handling code.
7434
7435 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
7436
7437 * buildsym-legacy.c (record_line): Pass extra parameter to
7438 record_line.
7439 * buildsym.c (buildsym_compunit::record_line): Take an extra
7440 parameter, reduce duplication in the line table, and record the
7441 is_stmt flag in the line table.
7442 * buildsym.h (buildsym_compunit::record_line): Add extra
7443 parameter.
7444 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
7445 non-statement lines.
7446 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
7447 this to the symtab builder.
7448 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
7449 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
7450 through to dwarf_record_line_1.
7451 * infrun.c (process_event_stop_test): When stepping, don't stop at
7452 a non-statement instruction, and only refresh the step info when
7453 we land in the middle of a line's range. Also add an extra
7454 comment.
7455 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
7456 field.
7457 * record-btrace.c (btrace_find_line_range): Only record lines
7458 marked as is-statement.
7459 * stack.c (frame_show_address): Show the frame address if we are
7460 in a non-statement sal.
7461 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
7462 (maintenance_print_one_line_table): Print a header for the is_stmt
7463 column, and include is_stmt information in the output.
7464 * symtab.c (find_pc_sect_line): Find lines marked as statements in
7465 preference to non-statements.
7466 (find_pcs_for_symtab_line): Prefer is-statement entries.
7467 (find_line_common): Likewise.
7468 * symtab.h (struct linetable_entry): Add is_stmt field.
7469 (struct symtab_and_line): Likewise.
7470 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
7471 arranging the line table.
7472
7473 2020-03-07 Tom de Vries <tdevries@suse.de>
7474
7475 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
7476 DIE.
7477
7478 2020-03-07 Tom Tromey <tom@tromey.com>
7479
7480 * valops.c (value_literal_complex): Remove obsolete comment.
7481 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
7482 comment.
7483
7484 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7485
7486 * infrun.h: Forward-declare thread_info.
7487 (set_step_info): Add thread_info parameter, add doc.
7488 * infrun.c (set_step_info): Add thread_info parameter, move doc
7489 to header.
7490 * infrun.c (process_event_stop_test): Pass thread to
7491 set_step_info call.
7492 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
7493 set_step_info.
7494 (prepare_one_step): Add thread_info parameter, pass it to
7495 set_step_frame and prepare_one_step (recursive) call.
7496 (step_1): Pass thread to prepare_one_step call.
7497 (step_command_fsm::should_stop): Pass thread to
7498 prepare_one_step.
7499 (until_next_fsm): Pass thread to set_step_frame call.
7500 (finish_command): Pass thread to set_step_info call.
7501
7502 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
7503
7504 * windows-tdep.c (windows_solib_create_inferior_hook):
7505 Check if inferior is running.
7506
7507 2020-03-06 Tom de Vries <tdevries@suse.de>
7508
7509 * NEWS: Fix "the the".
7510 * ctfread.c: Same.
7511
7512 2020-03-06 Tom de Vries <tdevries@suse.de>
7513
7514 * psymtab.c (psymtab_to_symtab): Don't print "done.".
7515
7516 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7517
7518 * .dir-locals.el: Add a comment referencing the other copies of
7519 this file.
7520
7521 2020-03-05 John Baldwin <jhb@FreeBSD.org>
7522
7523 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
7524 psargs.
7525
7526 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7527
7528 * .gitattributes: New file.
7529
7530 2020-03-04 Tom Tromey <tom@tromey.com>
7531
7532 * symmisc.c (print_symbol_bcache_statistics)
7533 (print_objfile_statistics): Update.
7534 * symfile.c (allocate_symtab): Use intern.
7535 * psymtab.c (partial_symtab::partial_symtab): Use intern.
7536 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
7537 macro_cache>: Remove.
7538 <string_cache>: New member.
7539 (struct objfile) <intern>: New methods.
7540 * elfread.c (elf_symtab_read): Use intern.
7541 * dwarf2/read.c (fixup_go_packaging): Intern package name.
7542 (dwarf2_compute_name, dwarf2_physname)
7543 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
7544 names.
7545 (guess_partial_die_structure_name): Update.
7546 (partial_die_info::fixup): Intern name.
7547 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
7548 name.
7549 (dwarf2_name): Intern name. Update.
7550 * buildsym.c (buildsym_compunit::get_macro_table): Use
7551 string_cache.
7552
7553 2020-03-04 Tom Tromey <tom@tromey.com>
7554
7555 * jit.c (bfd_open_from_target_memory): Make "target" const.
7556 * corefile.c (gnutarget): Now const.
7557 * gdbcore.h (gnutarget): Now const.
7558
7559 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
7560
7561 * NEWS: Mention support for WOW64 processes.
7562 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
7563 (amd64_windows_segment_register_p): Remove static.
7564 (_initialize_amd64_windows_nat): Update.
7565 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
7566 * i386-windows-nat.c (context_offset): Update.
7567 (i386_mappings): Rename and remove static.
7568 (i386_windows_segment_register_p): Remove static.
7569 (_initialize_i386_windows_nat): Update.
7570 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
7571 (STATUS_WX86_SINGLE_STEP): New macro.
7572 (EnumProcessModulesEx): New macro.
7573 (Wow64SuspendThread): New macro.
7574 (Wow64GetThreadContext): New macro.
7575 (Wow64SetThreadContext): New macro.
7576 (Wow64GetThreadSelectorEntry): New macro.
7577 (windows_set_context_register_offsets): Add static.
7578 (windows_set_segment_register_p): Likewise.
7579 (windows_add_thread): Adapt for WOW64 processes.
7580 (windows_fetch_one_register): Likewise.
7581 (windows_nat_target::fetch_registers): Likewise.
7582 (windows_store_one_register): Likewise.
7583 (display_selector): Likewise.
7584 (display_selectors): Likewise.
7585 (handle_exception): Likewise.
7586 (windows_continue): Likewise.
7587 (windows_nat_target::resume): Likewise.
7588 (windows_add_all_dlls): Likewise.
7589 (do_initial_windows_stuff): Likewise.
7590 (windows_nat_target::attach): Likewise.
7591 (windows_get_exec_module_filename): Likewise.
7592 (windows_nat_target::create_inferior): Likewise.
7593 (windows_xfer_siginfo): Likewise.
7594 (_initialize_loadable): Initialize Wow64SuspendThread,
7595 Wow64GetThreadContext, Wow64SetThreadContext,
7596 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
7597 * windows-nat.h (windows_set_context_register_offsets):
7598 Remove declaration.
7599 (windows_set_segment_register_p): Likewise.
7600 (i386_windows_segment_register_p): Add declaration.
7601 (amd64_windows_segment_register_p): Likewise.
7602
7603 2020-03-04 Luis Machado <luis.machado@linaro.org>
7604
7605 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
7606 in "info registers" for AArch64/ARM.
7607
7608 The change caused "info registers" to not print GPR's.
7609
7610 gdb/ChangeLog:
7611
7612 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
7613
7614 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
7615 when reg->group is empty and reggroup is not.
7616
7617 2020-03-03 Tom Tromey <tromey@adacore.com>
7618
7619 * dwarf2/frame.c (struct dwarf2_frame_cache)
7620 <checked_tailcall_bottom, entry_cfa_sp_offset,
7621 entry_cfa_sp_offset_p>: Remove members.
7622 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
7623 (dwarf2_frame_prev_register): Don't call
7624 dwarf2_tailcall_sniffer_first.
7625 (dwarf2_append_unwinders): Don't append tailcall unwinder.
7626 * frame-unwind.c (add_unwinder): New fuction.
7627 (frame_unwind_init): Use it. Add tailcall unwinder.
7628
7629 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
7630 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
7631
7632 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
7633 value should be printed as true.
7634
7635 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
7636
7637 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
7638 (windows_init_abi): Set and use windows_so_ops.
7639
7640 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
7641
7642 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
7643 when verifying if dealing with a convenience variable.
7644
7645 2020-03-03 Luis Machado <luis.machado@linaro.org>
7646
7647 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
7648
7649 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7650
7651 * infrun.c (gdbarch_supports_displaced_stepping): New.
7652 (use_displaced_stepping): Break up conditions in smaller pieces.
7653 Use gdbarch_supports_displaced_stepping.
7654 (displaced_step_prepare_throw): Use
7655 gdbarch_supports_displaced_stepping.
7656
7657 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
7658
7659 * NEWS: Mention new behaviour of the history filename.
7660 * top.c (write_history_p): Add comment.
7661 (show_write_history_p): Add header comment, give a different
7662 message when history writing is on, but the history filename is
7663 empty.
7664 (history_filename): Add comment.
7665 (history_filename_empty): New function.
7666 (show_history_filename): Add header comment, give a different
7667 message when the filename is empty.
7668 (init_history): Compare history_filename against nullptr, and only
7669 read history if the filename is not empty.
7670 (set_history_filename): Add header comment, and only make
7671 non-empty filenames absolute.
7672 (init_main): Make the filename argument to 'set history filename'
7673 optional.
7674
7675 2020-03-02 Christian Biesinger <cbiesinger@google.com>
7676
7677 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
7678 (arm_supply_vfpregset): ...this, and update to use VFP registers.
7679 (fetch_fp_register): Update.
7680 (fetch_fp_regs): Update.
7681 (store_fp_register): Update.
7682 (store_fp_regs): Update.
7683 (arm_netbsd_nat_target::read_description): New function.
7684 (fetch_elfcore_registers): Update.
7685
7686 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
7687
7688 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
7689 general_thread if the stop reply is missing a thread-id.
7690 (remote_target::process_stop_reply): Use the first non-exited
7691 thread if the target didn't pass a thread-id.
7692 * infrun.c (do_target_wait): Move call to
7693 switch_to_inferior_no_thread to ....
7694 (do_target_wait_1): ... here.
7695
7696 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
7697
7698 * debuginfod-support.c: Include defs.h first.
7699
7700 2020-02-28 Tom de Vries <tdevries@suse.de>
7701
7702 * symfile.c (set_initial_language): Use default language for lookup.
7703
7704 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
7705
7706 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
7707 reader variable, pass `this` to read_cutu_die_from_dwo.
7708
7709 2020-02-27 Aaron Merey <amerey@redhat.com>
7710
7711 * source.c (open_source_file): Check for nullptr when computing
7712 srcpath.
7713
7714 2020-02-27 Tom Tromey <tromey@adacore.com>
7715
7716 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
7717 member.
7718 (dwarf2_add_field): Don't update nfields.
7719 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
7720
7721 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
7722
7723 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
7724 abs.
7725
7726 2020-02-26 Tom Tromey <tom@tromey.com>
7727
7728 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
7729 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
7730 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
7731 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
7732 per_cu_data.
7733
7734 2020-02-26 Tom Tromey <tom@tromey.com>
7735
7736 * dwarf2/index-write.c (psym_index_map): Change type.
7737 (add_address_entry_worker, write_one_signatured_type)
7738 (recursively_count_psymbols, recursively_write_psymbols)
7739 (class debug_names, psyms_seen_size, write_gdbindex)
7740 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
7741
7742 2020-02-26 Aaron Merey <amerey@redhat.com>
7743
7744 * Makefile.in: Handle optional debuginfod support.
7745 * NEWS: Update.
7746 * README: Add --with-debuginfod summary.
7747 * config.in: Regenerate.
7748 * configure: Regenerate.
7749 * configure.ac: Handle optional debuginfod support.
7750 * debuginfod-support.c: debuginfod helper functions.
7751 * debuginfod-support.h: Ditto.
7752 * doc/gdb.texinfo: Add --with-debuginfod to configure options
7753 summary.
7754 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
7755 when a dwz file cannot be found.
7756 * elfread.c (elf_symfile_read): Query debuginfod servers when a
7757 debuginfo file cannot be found.
7758 * source.c (open_source_file): Query debuginfod servers when a
7759 source file cannot be found.
7760 * top.c (print_gdb_configuration): Include
7761 --{with,without}-debuginfod in the output.
7762
7763 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
7764
7765 * thread.c (thr_try_catch_cmd): Print thread name.
7766
7767 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
7768
7769 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
7770 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7771 dwarf2_fetch_die_type_sect_off): Move to...
7772 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
7773 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7774 dwarf2_fetch_die_type_sect_off): ... here.
7775 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
7776 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7777 dwarf2_fetch_die_type_sect_off): Move doc to header file.
7778
7779 2020-02-26 Tom de Vries <tdevries@suse.de>
7780
7781 PR gdb/25603
7782 * symfile.c (set_initial_language): Exit-early if
7783 language_mode == language_mode_manual.
7784
7785 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
7786
7787 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
7788 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
7789 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
7790
7791 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
7792
7793 * gdbtypes.c (create_array_type_with_stride): Handle negative
7794 array strides.
7795 * valarith.c (value_subscripted_rvalue): Likewise.
7796
7797 2020-02-25 Luis Machado <luis.machado@linaro.org>
7798
7799 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
7800
7801 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
7802
7803 * loc.h (dwarf2_get_die_type): Move to...
7804 * read.h (dwarf2_get_die_type): ... here.
7805 * read.c (dwarf2_get_die_type): Move doc to header.
7806
7807 2020-02-25 Joel Brobecker <brobecker@adacore.com>
7808
7809 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
7810 'gnulib/Makefile.in' to the list.
7811
7812 2020-02-24 Tom Tromey <tom@tromey.com>
7813
7814 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
7815 Remove.
7816 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
7817 XOBNEWVEC.
7818
7819 2020-02-24 Tom Tromey <tom@tromey.com>
7820
7821 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
7822 New method.
7823 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
7824 (dw2_do_instantiate_symtab, dw2_get_file_names)
7825 (build_type_psymtab_dependencies, load_full_type_unit): Update.
7826
7827 2020-02-24 Tom Tromey <tom@tromey.com>
7828
7829 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
7830 make_scoped_restore.
7831 (dwarf2_psymtab::read_symtab): Don't clear
7832 reading_partial_symbols.
7833
7834 2020-02-24 Tom de Vries <tdevries@suse.de>
7835
7836 PR gdb/25592
7837 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
7838
7839 2020-02-24 Tom de Vries <tdevries@suse.de>
7840
7841 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
7842 commands layout next/prev/regs.
7843
7844 2020-02-22 Tom Tromey <tom@tromey.com>
7845
7846 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
7847 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
7848
7849 2020-02-22 Tom Tromey <tom@tromey.com>
7850
7851 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
7852
7853 2020-02-22 Tom Tromey <tom@tromey.com>
7854
7855 * tui/tui-win.c (_initialize_tui_win): Add usage text.
7856 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
7857 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
7858 * tui/tui.c (_initialize_tui): Add usage text.
7859
7860 2020-02-22 Tom Tromey <tom@tromey.com>
7861
7862 * tui/tui-win.c (tui_set_focus_command)
7863 (tui_set_win_height_command): Use error_no_arg.
7864 (_initialize_tui_win): Update help text.
7865 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
7866
7867 2020-02-22 Tom Tromey <tom@tromey.com>
7868
7869 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
7870 * tui/tui-disasm.h (struct tui_disasm_window)
7871 <display_start_addr>: Declare.
7872 * tui/tui-source.h (struct tui_source_window)
7873 <display_start_addr>: Declare.
7874 * tui/tui-winsource.h (struct tui_source_window_base)
7875 <show_source_line, display_start_addr>: New methods.
7876 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
7877 Rename and move to protected section.
7878 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
7879 (tui_source_window_base::do_erase_source_content): Update.
7880 (tui_source_window_base::show_source_line): Now a method.
7881 (tui_source_window_base::show_source_content)
7882 (tui_source_window_base::tui_source_window_base)
7883 (tui_source_window_base::rerender)
7884 (tui_source_window_base::refill)
7885 (tui_source_window_base::do_scroll_horizontal)
7886 (tui_source_window_base::set_is_exec_point_at)
7887 (tui_source_window_base::update_breakpoint_info)
7888 (tui_source_window_base::update_exec_info): Update.
7889 * tui/tui-source.c (tui_source_window::set_contents)
7890 (tui_source_window::showing_source_p)
7891 (tui_source_window::do_scroll_vertical)
7892 (tui_source_window::location_matches_p)
7893 (tui_source_window::line_is_displayed): Update.
7894 (tui_source_window::display_start_addr): New method.
7895 * tui/tui-disasm.c (tui_disasm_window::set_contents)
7896 (tui_disasm_window::do_scroll_vertical)
7897 (tui_disasm_window::location_matches_p): Update.
7898 (tui_disasm_window::display_start_addr): New method.
7899
7900 2020-02-22 Tom Tromey <tom@tromey.com>
7901
7902 * NEWS: Add entry for gdb.register_window_type.
7903 * tui/tui-layout.h (window_factory): New typedef.
7904 (tui_register_window): Declare.
7905 * tui/tui-layout.c (saved_tui_windows): New global.
7906 (tui_apply_current_layout): Use it.
7907 (tui_register_window): New function.
7908 * python/python.c (do_start_initialization): Call
7909 gdbpy_initialize_tui.
7910 (python_GdbMethods): Add "register_window_type" function.
7911 * python/python-internal.h (gdbpy_register_tui_window)
7912 (gdbpy_initialize_tui): Declare.
7913 * python/py-tui.c: New file.
7914 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
7915
7916 2020-02-22 Tom Tromey <tom@tromey.com>
7917
7918 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
7919
7920 2020-02-22 Tom Tromey <tom@tromey.com>
7921
7922 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
7923 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
7924 * tui/tui-data.c (tui_set_win_with_focus): Remove.
7925 (tui_set_win_focus_to): Move from tui-win.c.
7926
7927 2020-02-22 Tom Tromey <tom@tromey.com>
7928
7929 * tui/tui-layout.c (make_standard_window, get_locator_window): New
7930 functions.
7931 (known_window_types): New global.
7932 (tui_get_window_by_name): Reimplement.
7933 (initialize_known_windows): New function.
7934 (validate_window_name): Rewrite.
7935 (_initialize_tui_layout): Call initialize_known_windows.
7936
7937 2020-02-22 Tom Tromey <tom@tromey.com>
7938
7939 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
7940 Remove constants.
7941 * tui/tui-winsource.h (struct tui_source_window_base)
7942 <tui_source_window_base>: Remove parameter.
7943 * tui/tui-winsource.c
7944 (tui_source_window_base::tui_source_window_base): Remove
7945 parameter.
7946 (tui_source_window_base::refill): Update.
7947 * tui/tui-stack.h (struct tui_locator_window)
7948 <tui_locator_window>: Update.
7949 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
7950 Default the constructor.
7951 * tui/tui-regs.h (struct tui_data_item_window)
7952 <tui_data_item_window>: Default the constructor.
7953 (struct tui_data_window) <tui_data_window>: Likewise.
7954 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
7955 Default the constructor.
7956 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
7957 Default the constructor.
7958 <type>: Remove.
7959 (struct tui_win_info) <tui_win_info>: Default the constructor.
7960 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
7961 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
7962 Default the constructor.
7963
7964 2020-02-22 Tom Tromey <tom@tromey.com>
7965
7966 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
7967 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
7968 * tui/tui-win.c (tui_resize_all): Don't call
7969 tui_delete_invisible_windows.
7970 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
7971 done.
7972 (tui_set_layout): Update.
7973 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
7974 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
7975 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
7976
7977 2020-02-22 Tom Tromey <tom@tromey.com>
7978
7979 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
7980 correctly.
7981
7982 2020-02-22 Tom Tromey <tom@tromey.com>
7983
7984 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
7985
7986 2020-02-22 Tom Tromey <tom@tromey.com>
7987
7988 * tui/tui-winsource.h (struct tui_source_window_iterator)
7989 <inner_iterator>: New etytypedef.
7990 <tui_source_window_iterator>: Take "end" parameter.
7991 <tui_source_window_iterator>: Take iterator.
7992 <operator*, advance>: Update.
7993 <m_iter>: Change type.
7994 <m_end>: New field.
7995 (struct tui_source_windows) <begin, end>: Update.
7996 * tui/tui-layout.c (tui_windows): New global.
7997 (tui_apply_current_layout): Clear tui_windows.
7998 (tui_layout_window::apply): Update tui_windows.
7999 * tui/tui-data.h (tui_windows): Declare.
8000 (all_tui_windows): Now inline function.
8001 (class tui_window_iterator, struct all_tui_windows): Remove.
8002
8003 2020-02-22 Tom Tromey <tom@tromey.com>
8004
8005 PR tui/17850:
8006 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
8007 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
8008 "height" argument.
8009 (class tui_layout_window) <get_sizes>: Likewise.
8010 (class tui_layout_split) <tui_layout_split>: Add "vertical"
8011 argument.
8012 <get_sizes>: Add "height" argument.
8013 <m_vertical>: New field.
8014 * tui/tui-layout.c (tui_layout_split::clone): Update.
8015 (tui_layout_split::get_sizes): Add "height" argument.
8016 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
8017 (tui_new_layout_command): Parse "-horizontal".
8018 (_initialize_tui_layout): Update help string.
8019 (tui_layout_split::specification): Add "-horizontal" when needed.
8020 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
8021 argument.
8022 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
8023 New methods.
8024
8025 2020-02-22 Tom Tromey <tom@tromey.com>
8026
8027 * tui/tui-layout.h (enum tui_adjust_result): New.
8028 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
8029 (class tui_layout_window) <adjust_size>: Return
8030 tui_adjust_result. Rewrite.
8031 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
8032 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
8033
8034 2020-02-22 Tom Tromey <tom@tromey.com>
8035
8036 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
8037 parameter and return types.
8038 (class tui_layout_base) <specification>: Add "depth".
8039 (class tui_layout_window) <specification>: Add "depth".
8040 (class tui_layout_split) <specification>: Add "depth".
8041 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
8042 and return types.
8043 (tui_new_layout_command): Parse sub-layouts.
8044 (_initialize_tui_layout): Update help string.
8045 (tui_layout_window::specification): Add "depth".
8046 (add_layout_command): Update.
8047
8048 2020-02-22 Tom Tromey <tom@tromey.com>
8049
8050 * NEWS: Add "tui new-layout" item.
8051 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
8052 Add new-layout command to help text.
8053 (validate_window_name): New function.
8054 (tui_new_layout_command): New function.
8055 (_initialize_tui_layout): Register "new-layout".
8056 (tui_layout_window::specification): New method.
8057 (tui_layout_window::specification): New method.
8058 * tui/tui-layout.h (class tui_layout_base) <specification>: New
8059 method.
8060 (class tui_layout_window) <specification>: New method.
8061 (class tui_layout_split) <specification>: New method.
8062
8063 2020-02-22 Tom Tromey <tom@tromey.com>
8064
8065 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
8066 * tui/tui-win.c (window_name_completer): Update comment.
8067 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
8068 Declare method.
8069 (class tui_layout_window) <replace_window>: Likewise.
8070 (class tui_layout_split) <replace_window>: Likewise.
8071 (tui_set_layout): Don't declare.
8072 (tui_set_initial_layout): Declare function.
8073 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
8074 (asm_regs_layout): New globals.
8075 (tui_current_layout, show_layout): Remove.
8076 (tui_set_layout, tui_add_win_to_layout): Rewrite.
8077 (find_layout, tui_apply_layout): New function.
8078 (layout_completer): Remove.
8079 (tui_next_layout): Reimplement.
8080 (tui_next_layout_command): New function.
8081 (tui_set_initial_layout, tui_prev_layout_command): New functions.
8082 (tui_regs_layout): Reimplement.
8083 (tui_regs_layout_command): New function.
8084 (extract_display_start_addr): Rewrite.
8085 (next_layout, prev_layout): Remove.
8086 (tui_layout_window::replace_window): New method.
8087 (tui_layout_split::replace_window): New method.
8088 (destroy_layout): New function.
8089 (layout_list): New global.
8090 (add_layout_command): New function.
8091 (initialize_layouts): Update.
8092 (tui_layout_command): New function.
8093 (_initialize_tui_layout): Install "layout" commands.
8094 * tui/tui-data.h (enum tui_layout_type): Remove.
8095 (tui_current_layout): Don't declare.
8096
8097 2020-02-22 Tom Tromey <tom@tromey.com>
8098
8099 * tui/tui-regs.c (tui_reg_layout): Remove.
8100 (tui_reg_command): Use tui_regs_layout.
8101 * tui/tui-layout.h (tui_reg_command): Declare.
8102 * tui/tui-layout.c (tui_reg_command): New function.
8103
8104 2020-02-22 Tom Tromey <tom@tromey.com>
8105
8106 * tui/tui.c (tui_rl_delete_other_windows): Call
8107 tui_remove_some_windows.
8108 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
8109 Declare method.
8110 (class tui_layout_window) <remove_windows>: New method.
8111 (class tui_layout_split) <remove_windows>: Declare.
8112 (tui_remove_some_windows): Declare.
8113 * tui/tui-layout.c (tui_remove_some_windows): New function.
8114 (tui_layout_split::remove_windows): New method.
8115
8116 2020-02-22 Tom Tromey <tom@tromey.com>
8117
8118 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
8119 * tui/tui-layout.h (tui_next_layout): Declare.
8120 * tui/tui-layout.c (tui_next_layout): New function.
8121
8122 2020-02-22 Tom Tromey <tom@tromey.com>
8123
8124 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
8125 correct coordinates.
8126
8127 2020-02-22 Tom Tromey <tom@tromey.com>
8128
8129 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
8130 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
8131 DATA_WIN case.
8132
8133 2020-02-22 Tom Tromey <tom@tromey.com>
8134
8135 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
8136 TUI_DISASM_WIN, not tui_win_list.
8137
8138 2020-02-22 Tom Tromey <tom@tromey.com>
8139
8140 * valprint.c (generic_val_print_enum_1)
8141 (val_print_type_code_flags): Style member names.
8142 * rust-lang.c (val_print_struct, rust_print_enum)
8143 (rust_print_struct_def, rust_internal_print_type): Style member
8144 names.
8145 * p-valprint.c (pascal_object_print_value_fields): Style member
8146 names. Only call fprintf_symbol_filtered for static members.
8147 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
8148 * f-valprint.c (f_val_print): Style member names.
8149 * f-typeprint.c (f_type_print_base): Style member names.
8150 * cp-valprint.c (cp_print_value_fields): Style member names. Only
8151 call fprintf_symbol_filtered for static members.
8152 (cp_print_class_member): Style member names.
8153 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
8154 member names.
8155 * ada-valprint.c (ada_print_scalar): Style enum names.
8156 (ada_val_print_enum): Likewise.
8157 * ada-typeprint.c (print_enum_type): Style enum names.
8158
8159 2020-02-21 Tom Tromey <tom@tromey.com>
8160
8161 * psympriv.h (struct partial_symtab): Update comment.
8162
8163 2020-02-21 Tom Tromey <tromey@adacore.com>
8164
8165 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
8166 type is CORE_ADDR.
8167
8168 2020-02-21 Tom de Vries <tdevries@suse.de>
8169
8170 PR gdb/25534
8171 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
8172 if dependencies[i]->user != NULL.
8173
8174 2020-02-21 Ali Tamur <tamur@google.com>
8175
8176 * dwarf2/read.c (dwarf2_name): Add null check.
8177
8178 2020-02-20 Tom Tromey <tom@tromey.com>
8179
8180 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
8181 ">=", in binary search.
8182 (dwarf2_find_containing_comp_unit): New overload.
8183 (run_test): New self-test.
8184 (_initialize_dwarf2_read): Register new test.
8185
8186 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
8187
8188 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
8189 * riscv-tdep.h: Likewise.
8190 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
8191 rv32-only CSR.
8192 * features/riscv/64bit-csr.xml: Regenerated.
8193
8194 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
8195 Tom Tromey <tom@tromey.com>
8196
8197 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
8198 of 'fputc_unfiltered'.
8199 (putchar_unfiltered): Call 'fputc_unfiltered'.
8200 (fputc_unfiltered): Call 'fputs_unfiltered'.
8201
8202 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
8203
8204 * config.in: Regenerate.
8205 * configure: Regenerate.
8206 * configure.ac: Add --with-python-libdir option.
8207 * main.c: Use WITH_PYTHON_LIBDIR.
8208
8209 2020-02-19 Tom Tromey <tom@tromey.com>
8210
8211 * symtab.c (general_symbol_info::compute_and_set_names): Use
8212 obstack_strndup. Simplify call to symbol_set_demangled_name.
8213
8214 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
8215
8216 * dwarf2/read.c (allocate_signatured_type_table,
8217 allocate_dwo_unit_table, allocate_type_unit_groups_table,
8218 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
8219 Remove objfile parameter, update all callers.
8220
8221 2020-02-19 Doug Evans <dje@google.com>
8222
8223 PR rust/25535
8224 * rust-lang.c (rust_print_enum): Apply embedded_offset to
8225 rust_enum_variant calculation.
8226
8227 2020-02-19 Tom Tromey <tromey@adacore.com>
8228
8229 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
8230
8231 2020-02-19 Tom Tromey <tromey@adacore.com>
8232
8233 * ada-lang.c (cache_symbol): Use obstack_strdup.
8234
8235 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
8236
8237 * configure: Regenerate.
8238
8239 2020-02-19 Tom Tromey <tromey@adacore.com>
8240
8241 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
8242 NULL check.
8243
8244 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
8245
8246 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
8247
8248 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
8249
8250 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
8251 if GDBSERVER is not defined.
8252 (riscv_tdesc_cache): Likewise, also store const target_desc.
8253 (STATIC_IN_GDB): Define.
8254 (riscv_create_target_description): Update declaration with
8255 STATIC_IN_GDB.
8256 (riscv_lookup_target_description): New function, only define if
8257 GDBSERVER is not defined.
8258 * arch/riscv.h (riscv_create_target_description): Declare only
8259 when GDBSERVER is defined.
8260 (riscv_lookup_target_description): New declaration when GDBSERVER
8261 is not defined.
8262 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
8263 (riscv_linux_read_features): ...this, and return
8264 riscv_gdbarch_features instead of target_desc.
8265 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
8266 (riscv_linux_read_description): Rename to...
8267 (riscv_linux_read_features): ...this.
8268 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
8269 Update to use riscv_gdbarch_features and
8270 riscv_lookup_target_description.
8271 * riscv-tdep.c (riscv_find_default_target_description): Use
8272 riscv_lookup_target_description instead of
8273 riscv_create_target_description.
8274
8275 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8276
8277 * valprint.c (generic_val_print_enum_1): When printing a flag
8278 enum with value 0 and there is no enumerator with value 0, print
8279 just "0" instead of "(unknown: 0x0)".
8280
8281 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8282
8283 * valprint.c (generic_val_print_enum_1): Print unknown part of
8284 flag enum in hex.
8285
8286 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8287
8288 * dwarf2/read.c (update_enumeration_type_from_children): Allow
8289 flag enums to contain duplicate enumerators.
8290 * valprint.c (generic_val_print_enum_1): Update comment.
8291
8292 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8293
8294 * dwarf2/read.c: Include "count-one-bits.h".
8295 (update_enumeration_type_from_children): If an enumerator has
8296 multiple bits set, don't treat the enumeration as a "flag enum".
8297 * valprint.c (generic_val_print_enum_1): Assert that enumerators
8298 of flag enums have 0 or 1 bit set.
8299
8300 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
8301
8302 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
8303 conversion.
8304 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8305 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
8306 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8307 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
8308 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8309
8310 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8311
8312 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
8313
8314 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8315
8316 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
8317 displaced_step_closure_up.
8318 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
8319 (struct displaced_step_closure_up):
8320 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8321 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
8322 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
8323 Likewise.
8324 * gdbarch.sh (displaced_step_copy_insn): Likewise.
8325 * gdbarch.c, gdbarch.h: Re-generate.
8326 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
8327 displaced_step_closure_up.
8328 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8329 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
8330 * infrun.h (displaced_step_closure_up): New type alias.
8331 (struct displaced_step_inferior_state) <step_closure>: Change
8332 type to displaced_step_closure_up.
8333 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
8334 displaced_step_closure_up.
8335 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8336
8337 2020-02-14 Tom Tromey <tom@tromey.com>
8338
8339 * minidebug.c (gnu_debug_key): New global.
8340 (find_separate_debug_file_in_section): Use it.
8341
8342 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8343
8344 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
8345 std::unique_ptr.
8346 * gdbarch.c: Re-generate.
8347 * gdbarch.h: Re-generate.
8348 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
8349 change.
8350 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
8351 type to std::unique_ptr.
8352 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
8353 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8354 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
8355 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
8356 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
8357 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8358 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
8359 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
8360 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8361
8362 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8363
8364 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
8365 std::unique_ptr.
8366 (displaced_step_clear): Rename to...
8367 (displaced_step_reset): ... this. Just call displaced->reset ().
8368 (displaced_step_clear_cleanup): Rename to...
8369 (displaced_step_reset_cleanup): ... this.
8370 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
8371 (displaced_step_fixup): Likewise.
8372 (resume_1): Likewise.
8373 (handle_inferior_event): Restore child's memory before calling
8374 displaced_step_fixup on the parent.
8375 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
8376 to std::unique_ptr.
8377 <step_closure>: Change type to std::unique_ptr.
8378
8379 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8380
8381 * arm-tdep.c: Include count-one-bits.h.
8382 (cleanup_block_store_pc): Use count_one_bits.
8383 (cleanup_block_load_pc): Use count_one_bits.
8384 (arm_copy_block_xfer): Use count_one_bits.
8385 (thumb2_copy_block_xfer): Use count_one_bits.
8386 (thumb_copy_pop_pc_16bit): Use count_one_bits.
8387 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
8388 (thumb_get_next_pcs_raw): Use count_one_bits.
8389 (arm_get_next_pcs_raw): Use count_one_bits_l.
8390 * arch/arm.c (bitcount): Remove.
8391 * arch/arm.h (bitcount): Remove.
8392
8393 2020-02-14 Tom Tromey <tromey@adacore.com>
8394
8395 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
8396 Update.
8397 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
8398 * dwarf2/loc.c (call_site_find_chain_1): Return
8399 unique_xmalloc_ptr.
8400 (call_site_find_chain): Likewise.
8401
8402 2020-02-14 Richard Biener <rguenther@suse.de>
8403
8404 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
8405 on expression with division operators.
8406
8407 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8408
8409 * MAINTAINERS (Write After Approval): Adding myself.
8410
8411 2020-02-12 Tom Tromey <tom@tromey.com>
8412
8413 * event-loop.c (event_data, gdb_event, event_handler_func):
8414 Remove.
8415
8416 2020-02-12 Tom Tromey <tom@tromey.com>
8417
8418 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
8419 (dwarf2_frame_objfile_data): Add comment.
8420 (find_comp_unit, set_comp_unit): New functions.
8421 (dwarf2_frame_find_fde): Use find_comp_unit.
8422 (dwarf2_build_frame_info): Use set_comp_unit.
8423
8424 2020-02-12 Tom Tromey <tom@tromey.com>
8425
8426 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
8427 (comp_unit): Don't initialize objfile.
8428 (execute_cfa_program): Add text_offset parameter.
8429 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
8430 (dwarf2_frame_cache): Update.
8431 (dwarf2_build_frame_info): Don't set "objfile" member.
8432
8433 2020-02-12 Tom Tromey <tom@tromey.com>
8434
8435 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
8436 (decode_frame_entry): Likewise.
8437 (dwarf2_build_frame_info): Update.
8438
8439 2020-02-12 Tom Tromey <tom@tromey.com>
8440
8441 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
8442 (decode_frame_entry_1): Use the comp_unit obstack.
8443
8444 2020-02-12 Tom Tromey <tom@tromey.com>
8445
8446 * dwarf2/frame.c (struct comp_unit): Add initializers and
8447 constructor.
8448 (dwarf2_frame_objfile_data): Store a comp_unit.
8449 (dwarf2_frame_find_fde): Update.
8450 (dwarf2_build_frame_info): Use "new".
8451
8452 2020-02-12 Tom Tromey <tom@tromey.com>
8453
8454 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
8455 (dwarf2_fde_table): Typedef for std::vector.
8456 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
8457 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
8458 (decode_frame_entry): Update.
8459 (dwarf2_build_frame_info): Use "new".
8460
8461 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8462
8463 * arm-tdep.c (arm_gdbarch_init): Update.
8464 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
8465 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
8466 have_neon, is_m>: Change to bool.
8467
8468 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8469
8470 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
8471
8472 2020-02-12 Tom Tromey <tom@tromey.com>
8473
8474 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
8475
8476 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
8477
8478 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
8479 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
8480
8481 2020-02-11 Tom Tromey <tom@tromey.com>
8482
8483 * psymtab.h: Update comment.
8484
8485 2020-02-11 Tom Tromey <tom@tromey.com>
8486
8487 * gdb_obstack.h (struct auto_obstack): Use
8488 DISABLE_COPY_AND_ASSIGN.
8489
8490 2020-02-11 Tom Tromey <tom@tromey.com>
8491
8492 * dwarf2/frame.h (struct objfile): Don't forward declare.
8493
8494 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8495
8496 * cris-tdep.c (cris_supply_gregset): Change signature to match
8497 what struct regset expects.
8498 (cris_regset): New struct.
8499 (fetch_core_registers): Remove.
8500 (cris_iterate_over_regset_sections): New function.
8501 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
8502 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
8503
8504 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8505
8506 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
8507 registers.
8508
8509 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8510
8511 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
8512
8513 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8514
8515 * configure: Re-generate.
8516
8517 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8518
8519 * configure: Re-generate.
8520
8521 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8522
8523 * acinclude: Update warning.m4 path.
8524 * warning.m4: Move to gdbsupport.
8525
8526 2020-02-11 Tom Tromey <tromey@adacore.com>
8527
8528 * remote.c (remote_console_output): Update.
8529 * printcmd.c (printf_command): Update.
8530 * event-loop.c (gdb_wait_for_event): Update.
8531 * linux-nat.c (sigchld_handler): Update.
8532 * remote-sim.c (gdb_os_write_stdout): Update.
8533 (gdb_os_flush_stdout): Update.
8534 (gdb_os_flush_stderr): Update.
8535 (gdb_os_write_stderr): Update.
8536 * exceptions.c (print_exception): Update.
8537 * remote-fileio.c (remote_fileio_func_read): Update.
8538 (remote_fileio_func_write): Update.
8539 * tui/tui.c (tui_enable): Update.
8540 * tui/tui-interp.c (tui_interp::init): Update.
8541 * utils.c (init_page_info): Update.
8542 (putchar_unfiltered, fputc_unfiltered): Update.
8543 (gdb_flush): Update.
8544 (emit_style_escape): Update.
8545 (flush_wrap_buffer, fputs_maybe_filtered): Update.
8546 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
8547 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
8548 (stderr_file::write): Update.
8549 (stderr_file::puts): Update.
8550 * ui-file.h (ui_file_isatty, ui_file_write)
8551 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
8552 (ui_file_puts): Don't declare.
8553
8554 2020-02-10 Tom de Vries <tdevries@suse.de>
8555
8556 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
8557 sentinel to char *.
8558
8559 2020-02-09 Tom de Vries <tdevries@suse.de>
8560
8561 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
8562 filename if it matches "<artificial>".
8563
8564 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
8565
8566 * windows-tdep.c (struct enum_value_name): New struct.
8567 (create_enum): New function.
8568 (windows_get_siginfo_type): Create and use enum types.
8569
8570 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
8571
8572 * NEWS: Mention $_siginfo support for Windows.
8573 * windows-nat.c (handle_exception): Set siginfo_er.
8574 (windows_nat_target::mourn_inferior): Reset siginfo_er.
8575 (windows_xfer_siginfo): New function.
8576 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
8577 * windows-tdep.c (struct windows_gdbarch_data): New struct.
8578 (init_windows_gdbarch_data): New function.
8579 (get_windows_gdbarch_data): New function.
8580 (windows_get_siginfo_type): New function.
8581 (windows_init_abi): Register windows_get_siginfo_type.
8582 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
8583
8584 2020-02-08 Tom Tromey <tom@tromey.com>
8585
8586 * dwarf2/read.c (class cutu_reader) <cutu_reader,
8587 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
8588 <keep>: Declare method.
8589 <m_keep>: Remove member.
8590 <~cutu_reader>: Remove.
8591 (cutu_reader::init_tu_and_read_dwo_dies): Update.
8592 (cutu_reader::cutu_reader): Update.
8593 (cutu_reader::keep): Rename from ~cutu_reader.
8594 (process_psymtab_comp_unit, build_type_psymtabs_1)
8595 (process_skeletonless_type_unit, load_partial_comp_unit)
8596 (load_full_comp_unit, dwarf2_read_addr_index)
8597 (read_signatured_type): Update.
8598
8599 2020-02-08 Tom Tromey <tom@tromey.com>
8600
8601 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
8602 "want_partial_unit" parameter.
8603 (process_psymtab_comp_unit): Change want_partial_unit to bool.
8604 Inline check for DW_TAG_partial_unit.
8605 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
8606
8607 2020-02-08 Tom Tromey <tom@tromey.com>
8608
8609 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
8610 read.c.
8611 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
8612 read.c.
8613
8614 2020-02-08 Tom Tromey <tom@tromey.com>
8615
8616 * dwarf2/read.c (read_address): Move to comp-unit.c.
8617 (dwarf2_rnglists_process, dwarf2_ranges_process)
8618 (read_attribute_value, dwarf_decode_lines_1)
8619 (var_decode_location, decode_locdesc): Update.
8620 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
8621 read.c. Remove "cu" parameter.
8622 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
8623 method.
8624
8625 2020-02-08 Tom Tromey <tom@tromey.com>
8626
8627 * dwarf2/read.c (read_attribute_value, read_indirect_string)
8628 (read_indirect_line_string): Update.
8629 * dwarf2/comp-unit.c (read_offset): Remove.
8630 (read_comp_unit_head): Update.
8631 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
8632 method.
8633 (read_offset): Don't declare.
8634
8635 2020-02-08 Tom Tromey <tom@tromey.com>
8636
8637 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
8638 * dwarf2/read.c (struct comp_unit_head): Move to
8639 dwarf2/comp-unit.h.
8640 (enum class rcuh_kind): Move to comp-unit.h.
8641 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
8642 (read_comp_unit_head, error_check_comp_unit_head)
8643 (read_and_check_comp_unit_head): Move to comp-unit.c.
8644 (read_offset, dwarf_unit_type_name): Likewise.
8645 (create_debug_type_hash_table, read_cutu_die_from_dwo)
8646 (cutu_reader::cutu_reader, read_call_site_scope)
8647 (find_partial_die, follow_die_offset): Update.
8648 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
8649
8650 2020-02-08 Tom Tromey <tom@tromey.com>
8651
8652 * dwarf2/read.c (read_offset_1): Move to leb.c.
8653 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
8654 (dwarf_decode_macro_bytes): Update.
8655 * dwarf2/leb.c (read_offset): Rename; move from read.c.
8656 * dwarf2/leb.h (read_offset): Declare.
8657
8658 2020-02-08 Tom Tromey <tom@tromey.com>
8659
8660 * dwarf2/read.c (dwarf2_section_size): Remove.
8661 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
8662 Update.
8663 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
8664
8665 2020-02-08 Tom Tromey <tom@tromey.com>
8666
8667 * dwarf2/read.c (read_initial_length): Move to leb.c.
8668 * dwarf2/leb.h (read_initial_length): Declare.
8669 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
8670 handle_nonstd parameter.
8671 * dwarf2/frame.c (read_initial_length): Remove.
8672 (decode_frame_entry_1): Update.
8673
8674 2020-02-08 Tom Tromey <tom@tromey.com>
8675
8676 * dwarf2/loc.c (dwarf2_find_location_expression)
8677 (dwarf_evaluate_loc_desc::get_tls_address)
8678 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
8679 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
8680 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
8681 (dwarf2_compile_property_to_c)
8682 (dwarf2_loc_desc_get_symbol_read_needs)
8683 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
8684 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
8685 (loclist_describe_location, loclist_tracepoint_var_ref)
8686 (loclist_generate_c_location): Update.
8687 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
8688 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
8689 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
8690 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
8691 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
8692 (dwarf2_per_cu_data::addr_size)
8693 (dwarf2_per_cu_data::ref_addr_size)
8694 (dwarf2_per_cu_data::text_offset)
8695 (dwarf2_per_cu_data::addr_type): Now methods.
8696 (per_cu_header_read_in): Make per_cu "const".
8697 (dwarf2_version): Remove.
8698 (dwarf2_per_cu_data::int_type): Now a method.
8699 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
8700 (set_die_type, read_array_type, read_subrange_index_type)
8701 (read_tag_string_type, read_subrange_type): Update.
8702 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
8703 offset_size, ref_addr_size, text_offset, addr_type, version,
8704 objfile, int_type, addr_sized_int_type>: Declare methods.
8705
8706 2020-02-08 Tom Tromey <tom@tromey.com>
8707
8708 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
8709 Move earlier.
8710
8711 2020-02-08 Tom Tromey <tom@tromey.com>
8712
8713 * dwarf2/read.h (dwarf_line_debug): Declare.
8714 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
8715 * dwarf2/read.c: Move line_header code to new files.
8716 (dwarf_line_debug): No longer static.
8717 * dwarf2/line-header.c: New file.
8718 * dwarf2/line-header.h: New file.
8719
8720 2020-02-08 Tom Tromey <tom@tromey.com>
8721
8722 * dwarf2/read.c (struct line_header) <file_full_name,
8723 file_file_name>: Return unique_xmalloc_ptr.
8724 (line_header::file_file_name): Update.
8725 (line_header::file_full_name): Update.
8726 (dw2_get_file_names_reader): Update.
8727 (macro_start_file): Update.
8728
8729 2020-02-08 Tom Tromey <tom@tromey.com>
8730
8731 * dwarf2/read.c (struct line_header) <file_full_name,
8732 file_file_name>: Declare methods.
8733 (dw2_get_file_names_reader): Update.
8734 (file_file_name): Now a method.
8735 (file_full_name): Likewise.
8736 (macro_start_file): Update.
8737
8738 2020-02-08 Tom Tromey <tom@tromey.com>
8739
8740 * dwarf2/read.c (dwarf_always_disassemble)
8741 (show_dwarf_always_disassemble): Move to loc.c.
8742 (_initialize_dwarf2_read): Move "always-disassemble" registration
8743 to loc.c.
8744 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
8745 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
8746 static.
8747 (show_dwarf_always_disassemble): Move from read.c.
8748 (_initialize_dwarf2loc): Move always-disassemble from read.c.
8749
8750 2020-02-08 Tom Tromey <tom@tromey.com>
8751
8752 * dwarf2/read.c (~dwarf2_per_objfile): Update.
8753 (create_quick_file_names_table): Return htab_up.
8754 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
8755 Update.
8756 * dwarf2/read.h (struct dwarf2_per_objfile)
8757 <quick_file_names_table>: Now htab_up.
8758
8759 2020-02-08 Tom Tromey <tom@tromey.com>
8760
8761 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
8762
8763 2020-02-08 Tom Tromey <tom@tromey.com>
8764
8765 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
8766 Rewrite.
8767 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
8768 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
8769 (abbrev_table::abbrev_table): No longer inline.
8770 (ABBREV_HASH_SIZE): Remove.
8771 (abbrev_table::m_abbrevs): Now an htab_up.
8772
8773 2020-02-08 Tom Tromey <tom@tromey.com>
8774
8775 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
8776 (cutu_reader): Update.
8777 (build_type_psymtabs_1): Update.
8778 * dwarf2/abbrev.c (abbrev_table::read): Rename.
8779 (abbrev_table::alloc_abbrev): Update.
8780 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
8781 (abbrev_table::read): New static method, renamed from
8782 abbrev_table_read_table.
8783 (abbrev_table::alloc_abbrev)
8784 (abbrev_table::add_abbrev): Now private.
8785 (abbrev_table::abbrev_table): Now private.
8786 (abbrev_table::m_abbrev_obstack): Now private. Rename.
8787
8788 2020-02-08 Tom Tromey <tom@tromey.com>
8789
8790 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
8791 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
8792 htab_up.
8793
8794 2020-02-08 Tom Tromey <tom@tromey.com>
8795
8796 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
8797 htab_up.
8798 (lookup_dwo_unit_in_dwp): Update.
8799 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
8800 on obstack.
8801
8802 2020-02-08 Tom Tromey <tom@tromey.com>
8803
8804 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
8805 obstack.
8806
8807 2020-02-08 Tom Tromey <tom@tromey.com>
8808
8809 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
8810 line_header_hash.
8811 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
8812 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
8813 Change type to htab_up.
8814
8815 2020-02-08 Tom Tromey <tom@tromey.com>
8816
8817 * dwarf2/read.c (allocate_type_unit_groups_table): Return
8818 htab_up. Don't allocate on obstack.
8819 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
8820 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
8821 Change type to htab_up.
8822
8823 2020-02-08 Tom Tromey <tom@tromey.com>
8824
8825 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
8826 Change type to htab_up.
8827 * dwarf2/read.c (create_signatured_type_table_from_index)
8828 (create_signatured_type_table_from_debug_names)
8829 (create_all_type_units, add_type_unit)
8830 (lookup_dwo_signatured_type, lookup_signatured_type)
8831 (process_skeletonless_type_unit): Update.
8832 (create_debug_type_hash_table, create_debug_types_hash_table):
8833 Change type of types_htab.
8834 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
8835 htab_up. Don't allocate on obstack.
8836 (create_cus_hash_table): Change type of cus_htab parameter.
8837 (struct dwo_file) <cus, tus>: Now htab_up.
8838 (lookup_dwo_signatured_type, lookup_dwo_cutu)
8839 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
8840 (queue_and_load_all_dwo_tus): Update.
8841 * dwarf2/index-write.c (write_gdbindex): Update.
8842 (write_debug_names): Update.
8843
8844 2020-02-08 Tom Tromey <tom@tromey.com>
8845
8846 * dwarf2/read.h (struct dwarf2_queue_item): Move from
8847 dwarf2/read.c. Remove "next" member. Add constructor ntad
8848 destructor.
8849 (struct dwarf2_per_objfile) <queue>: New member.
8850 * dwarf2/read.c (struct dwarf2_queue_item): Move to
8851 dwarf2/read.h.
8852 (dwarf2_queue, dwarf2_queue_tail): Remove.
8853 (class dwarf2_queue_guard): Add parameter to constructor. Use
8854 DISABLE_COPY_AND_ASSIGN.
8855 <m_per_objfile>: New member.
8856 <~dwarf2_queue_guard>: Rewrite.
8857 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
8858 Update.
8859 (~dwarf2_queue_item): New.
8860
8861 2020-02-08 Tom Tromey <tom@tromey.com>
8862
8863 * dwarf2/read.c (struct die_info) <has_children>: New member.
8864 (dw2_get_file_names_reader): Remove has_children.
8865 (dw2_get_file_names): Update.
8866 (read_cutu_die_from_dwo): Remove has_children.
8867 (cutu_reader::init_tu_and_read_dwo_dies)
8868 (cutu_reader::cutu_reader): Update.
8869 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
8870 Remove has_children.
8871 (build_type_psymtabs_1, process_skeletonless_type_unit)
8872 (load_partial_comp_unit, load_full_comp_unit): Update.
8873 (create_dwo_cu_reader): Remove has_children.
8874 (create_cus_hash_table, read_die_and_children): Update.
8875 (read_full_die_1,read_full_die): Remove has_children.
8876 (read_signatured_type): Update.
8877 (class cutu_reader) <has_children>: Remove.
8878
8879 2020-02-08 Tom Tromey <tom@tromey.com>
8880
8881 * dwarf2/expr.c: Rename from dwarf2expr.c.
8882 * dwarf2/expr.h: Rename from dwarf2expr.h.
8883 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
8884 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
8885 * dwarf2/frame.c: Rename from dwarf2-frame.c.
8886 * dwarf2/frame.h: Rename from dwarf2-frame.h.
8887 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
8888 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
8889 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
8890 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
8891 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
8892 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
8893 * dwarf2/loc.c: Rename from dwarf2loc.c.
8894 * dwarf2/loc.h: Rename from dwarf2loc.h.
8895 * dwarf2/read.c: Rename from dwarf2read.c.
8896 * dwarf2/read.h: Rename from dwarf2read.h.
8897 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
8898 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
8899 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
8900 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
8901 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
8902 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
8903 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
8904 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
8905 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
8906 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
8907 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
8908 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
8909 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
8910 Update.
8911 * Makefile.in (COMMON_SFILES): Update.
8912 (HFILES_NO_SRCDIR): Update.
8913
8914 2020-02-08 Tom Tromey <tom@tromey.com>
8915
8916 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
8917 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
8918
8919 2020-02-08 Tom Tromey <tom@tromey.com>
8920
8921 * dwarf2read.h (struct die_info): Don't declare.
8922
8923 2020-02-08 Tom Tromey <tom@tromey.com>
8924
8925 * dwarf2read.h (die_info_ptr): Remove typedef.
8926
8927 2020-02-08 Tom Tromey <tom@tromey.com>
8928
8929 * dwarf2read.c (read_call_site_scope)
8930 (handle_data_member_location, dwarf2_add_member_fn)
8931 (mark_common_block_symbol_computed, read_common_block)
8932 (attr_to_dynamic_prop, partial_die_info::read)
8933 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
8934 (dwarf2_symbol_mark_computed, set_die_type): Update.
8935 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
8936 method.
8937 (attr_form_is_block): Don't declare.
8938 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
8939
8940 2020-02-08 Tom Tromey <tom@tromey.com>
8941
8942 * dwarf2read.c (dwarf2_find_base_address, )
8943 (read_call_site_scope, rust_containing_type)
8944 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
8945 (handle_data_member_location, dwarf2_add_member_fn)
8946 (get_alignment, read_structure_type, process_structure_scope)
8947 (mark_common_block_symbol_computed, read_common_block)
8948 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
8949 (partial_die_info::read, read_attribute_value, new_symbol)
8950 (lookup_die_type, dwarf2_get_ref_die_offset)
8951 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
8952 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
8953 (dwarf2_symbol_mark_computed): Update.
8954 * dwarf2/attribute.h (struct attribute) <value_as_address,
8955 form_is_section_offset, form_is_constant, form_is_ref>: Declare
8956 methods.
8957 (value_as_address, attr_form_is_section_offset)
8958 (attr_form_is_constant, attr_form_is_ref): Don't declare.
8959 * dwarf2/attribute.c (attribute::value_as_address)
8960 (attribute::form_is_section_offset, attribute::form_is_constant)
8961 (attribute::form_is_ref): Now methods.
8962
8963 2020-02-08 Tom Tromey <tom@tromey.com>
8964
8965 * dwarf2read.c (struct attribute, DW_STRING)
8966 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
8967 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
8968 (attr_form_is_block, attr_form_is_section_offset)
8969 (attr_form_is_constant, attr_form_is_ref): Move.
8970 * dwarf2/attribute.h: New file.
8971 * dwarf2/attribute.c: New file, from dwarf2read.c.
8972 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
8973
8974 2020-02-08 Tom Tromey <tom@tromey.com>
8975
8976 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
8977 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
8978 Move.
8979 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
8980 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
8981 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
8982 abbrev.c.
8983 * dwarf2/abbrev.h: New file.
8984 * dwarf2/abbrev.c: New file, from dwarf2read.c.
8985 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
8986
8987 2020-02-08 Tom Tromey <tom@tromey.com>
8988
8989 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
8990 (dwarf2_section_size, dwarf2_get_section_info)
8991 (create_signatured_type_table_from_debug_names)
8992 (create_addrmap_from_aranges, read_debug_names_from_section)
8993 (get_gdb_index_contents_from_section, read_comp_unit_head)
8994 (error_check_comp_unit_head, read_abbrev_offset)
8995 (create_debug_type_hash_table, init_cu_die_reader)
8996 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
8997 (read_comp_units_from_section, create_cus_hash_table)
8998 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
8999 (create_dwp_v2_section, dwarf2_rnglists_process)
9000 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
9001 (abbrev_table_read_table, read_indirect_string_at_offset_from)
9002 (read_indirect_string_from_dwz, read_addr_index_1)
9003 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
9004 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9005 (fill_in_loclist_baton): Update.
9006 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
9007 get_containing_section, get_bfd_owner, get_bfd_section,
9008 get_file_name, get_id, get_flags, empty, read>: Declare methods.
9009 (dwarf2_read_section, get_section_name, get_section_file_name)
9010 (get_containing_section, get_section_bfd_owner)
9011 (get_section_bfd_section, get_section_name, get_section_file_name)
9012 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
9013 declare.
9014 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
9015 (dwarf2_section_info::get_bfd_owner)
9016 (dwarf2_section_info::get_bfd_section)
9017 (dwarf2_section_info::get_name)
9018 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
9019 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
9020 (dwarf2_section_info::read): Now methods.
9021 * dwarf-index-write.c (class debug_names): Update.
9022
9023 2020-02-08 Tom Tromey <tom@tromey.com>
9024
9025 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
9026 Move to dwarf2/section.h.
9027 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
9028 (get_section_bfd_section, get_section_name)
9029 (get_section_file_name, get_section_id, get_section_flags)
9030 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
9031 dwarf2/section.c.
9032 * dwarf2/section.h: New file.
9033 * dwarf2/section.c: New file, from dwarf2read.c.
9034 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
9035
9036 2020-02-08 Tom Tromey <tom@tromey.com>
9037
9038 * dwarf2read.h (read_unsigned_leb128): Don't declare.
9039 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
9040 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
9041 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
9042 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
9043 * dwarf2/leb.h: New file, from dwarf2read.c.
9044 * dwarf2/leb.c: New file, from dwarf2read.c.
9045 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
9046 Remove.
9047 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
9048 (COMMON_SFILES): Add dwarf2/leb.c.
9049
9050 2020-02-08 Joel Brobecker <brobecker@adacore.com>
9051
9052 GDB 9.1 released.
9053
9054 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
9055
9056 PR gdb/25190:
9057 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
9058 * gdb/remote.c (remote_console_output): Update.
9059 * gdb/ui-file.c (fputs_unfiltered): Rename to...
9060 (ui_file_puts): ...this.
9061 * gdb/ui-file.h (ui_file_puts): Add declaration.
9062 * gdb/utils.c (emit_style_escape): Update.
9063 (flush_wrap_buffer): Update.
9064 (fputs_maybe_filtered): Update.
9065 (fputs_unfiltered): Add function.
9066
9067 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
9068
9069 * gdb/event-loop.c (gdb_wait_for_event): Update.
9070 * gdb/printcmd.c (printf_command): Update.
9071 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
9072 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
9073 (gdb_os_flush_stderr): Update.
9074 * gdb/remote.c (remote_console_output): Update.
9075 * gdb/ui-file.c (gdb_flush): Rename to...
9076 (ui_file_flush): ...this.
9077 (stderr_file::write): Update.
9078 (stderr_file::puts): Update.
9079 * gdb/ui-file.h (gdb_flush): Rename to...
9080 (ui_file_flush): ...this.
9081 * gdb/utils.c (gdb_flush): Add function.
9082 * gdb/utils.h (gdb_flush): Add declaration.
9083
9084 2020-02-07 Tom Tromey <tromey@adacore.com>
9085
9086 PR breakpoints/24915:
9087 * source.c (find_and_open_source): Do not check basenames_may_differ.
9088
9089 2020-02-07 Tom Tromey <tom@tromey.com>
9090
9091 * README: Update gdbserver documentation.
9092 * gdbserver: Move to top level.
9093 * configure.tgt (build_gdbserver): Remove.
9094 * configure.ac: Remove --enable-gdbserver.
9095 * configure: Rebuild.
9096 * Makefile.in (distclean): Don't mention gdbserver.
9097
9098 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
9099
9100 * source-cache.c (source_cache::ensure): Surround
9101 get_plain_source_lines with a try/catch.
9102 (source_cache::get_line_charpos): Get rid of try/catch
9103 and only check for the return value of "ensure".
9104 * tui/tui-source.c (tui_source_window::set_contents):
9105 Simplify "nlines" calculation.
9106
9107 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
9108
9109 * MAINTAINERS (Write After Approval): Add myself.
9110
9111 2020-02-05 Christian Biesinger <cbiesinger@google.com>
9112
9113 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
9114 function call.
9115
9116 2020-02-05 Christian Biesinger <cbiesinger@google.com>
9117
9118 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
9119
9120 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
9121
9122 * nat/riscv-linux-tdesc.h: New file.
9123 * nat/riscv-linux-tdesc.c: New file, taking code from...
9124 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
9125 ... here.
9126 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
9127 NATDEPFILES.
9128
9129 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
9130
9131 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
9132 we don't set the fake simulator ptid to the null_ptid.
9133
9134 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
9135
9136 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
9137 * gdbthread.h (class thread_info) <resumed>: Likewise.
9138 * infrun.c (resume_1): Likewise.
9139 (proceed): Likewise.
9140 (infrun_thread_stop_requested): Likewise.
9141 (stop_all_threads): Likewise.
9142 (handle_inferior_event): Likewise.
9143 (restart_threads): Likewise.
9144 (finish_step_over): Likewise.
9145 (keep_going_stepped_thread): Likewise.
9146 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
9147 (linux_handle_extended_wait): Likewise.
9148 * record-btrace.c (get_thread_current_frame_id): Likewise.
9149 * record-full.c (record_full_wait_1): Likewise.
9150 * remote.c (remote_target::process_initial_stop_replies): Likewise.
9151 * target.c (target_resume): Likewise.
9152 * thread.c (set_running_thread): Likewise.
9153
9154 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
9155
9156 * f-valprint.c (f77_print_array_1): Changed datatype of index
9157 variable to LONGEST from int to enable it to contain bound
9158 values correctly.
9159
9160 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
9161
9162 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
9163 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
9164 offsets according to FLEN determined.
9165 (riscv_linux_nat_target::read_description): Determine FLEN
9166 dynamically.
9167 (riscv_linux_nat_target::fetch_registers): Size regset buffer
9168 according to FLEN determined.
9169 (riscv_linux_nat_target::store_registers): Likewise.
9170
9171 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
9172
9173 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
9174 when reg->group is empty and reggroup is not.
9175
9176 2020-01-31 Tom Tromey <tromey@adacore.com>
9177
9178 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
9179 Call beneath target's mourn_inferior after unpushing.
9180
9181 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
9182
9183 PR tui/9765
9184 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
9185 have enough lines to fill the screen, still return the lowest
9186 address we found.
9187
9188 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
9189
9190 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
9191 '-', '<', and '>' commands.
9192
9193 2020-01-29 Pedro Alves <palves@redhat.com>
9194 Sergio Durigan Junior <sergiodj@redhat.com>
9195
9196 * infcmd.c (construct_inferior_arguments): Assert that
9197 'argc' is greater than 0.
9198
9199 2020-01-29 Luis Machado <luis.machado@linaro.org>
9200
9201 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
9202 (BRK_INSN_MASK): Define to 0xd4200000.
9203 (aarch64_program_breakpoint_here_p): New function.
9204 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
9205 * arch-utils.c (default_program_breakpoint_here_p): Moved from
9206 breakpoint.c.
9207 * arch-utils.h (default_program_breakpoint_here_p): Moved from
9208 breakpoint.h
9209 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
9210 call gdbarch_program_breakpoint_here_p.
9211 (program_breakpoint_here): Moved to arch-utils.c, renamed to
9212 default_program_breakpoint_here_p, changed return type to bool and
9213 simplified.
9214 * breakpoint.h (program_breakpoint_here): Moved prototype to
9215 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
9216 return type to bool.
9217 * gdbarch.c: Regenerate.
9218 * gdbarch.h: Regenerate.
9219 * gdbarch.sh (program_breakpoint_here_p): New method.
9220 * infrun.c (handle_signal_stop): Call
9221 gdbarch_program_breakpoint_here_p.
9222
9223 2020-01-26 Tom Tromey <tom@tromey.com>
9224
9225 * ctfread.c (struct ctf_fp_info): Reindent.
9226 (_initialize_ctfread): Remove.
9227
9228 2020-01-26 Tom Tromey <tom@tromey.com>
9229
9230 * psymtab.c (partial_map_expand_apply)
9231 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
9232 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
9233 (psym_print_stats, psym_expand_symtabs_for_function)
9234 (psym_map_symbol_filenames, psym_map_matching_symbols)
9235 (psym_expand_symtabs_matching)
9236 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
9237 (maintenance_check_psymtabs): Use new methods.
9238 * psympriv.h (struct partial_symtab) <readin_p,
9239 get_compunit_symtab>: New methods.
9240 <readin, compunit_symtab>: Remove members.
9241 (struct standard_psymtab): New.
9242 (struct legacy_psymtab): Derive from standard_psymtab.
9243 * dwarf2read.h (struct dwarf2_psymtab): Derive from
9244 standard_psymtab.
9245 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
9246
9247 2020-01-26 Tom Tromey <tom@tromey.com>
9248
9249 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
9250 read_dependencies. Add assert.
9251 * psymtab.c (partial_symtab::read_dependencies): New method.
9252 * psympriv.h (struct partial_symtab) <read_dependencies>: New
9253 method.
9254 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
9255 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
9256 read_dependencies.
9257 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
9258 Add assert.
9259
9260 2020-01-26 Tom Tromey <tom@tromey.com>
9261
9262 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
9263 Call expand_psymtab.
9264 (xcoff_read_symtab): Call expand_psymtab.
9265 (xcoff_start_psymtab, xcoff_end_psymtab): Set
9266 legacy_expand_psymtab.
9267 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
9268 method.
9269 (struct legacy_psymtab) <expand_psymtab>: Implement.
9270 <legacy_expand_psymtab>: New member.
9271 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
9272 (parse_partial_symbols): Set legacy_expand_psymtab.
9273 (psymtab_to_symtab_1): Change argument order. Call
9274 expand_psymtab.
9275 (new_psymtab): Set legacy_expand_psymtab.
9276 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
9277 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
9278 expand_psymtab.
9279 (dwarf2_psymtab::expand_psymtab): Rename from
9280 psymtab_to_symtab_1. Call expand_psymtab.
9281 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
9282 (dbx_end_psymtab): Likewise.
9283 (dbx_psymtab_to_symtab_1): Change argument order. Call
9284 expand_psymtab.
9285 (dbx_read_symtab): Call expand_psymtab.
9286 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
9287 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
9288 (ctf_psymtab::read_symtab): Call expand_psymtab.
9289
9290 2020-01-26 Tom Tromey <tom@tromey.com>
9291
9292 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
9293 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
9294 messages.
9295 * mdebugread.c (mdebug_read_symtab): Remove prints.
9296 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
9297 assert.
9298 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
9299
9300 2020-01-26 Tom Tromey <tom@tromey.com>
9301
9302 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
9303 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
9304 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
9305 legacy_symtab.
9306 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
9307 * psymtab.c (psymtab_to_symtab): Call method.
9308 (dump_psymtab): Update.
9309 * psympriv.h (struct partial_symtab): Add virtual destructor.
9310 <read_symtab>: New method.
9311 (struct legacy_symtab): New.
9312 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
9313 (struct pst_map) <pst>: Now a legacy_psymtab.
9314 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
9315 (new_psymtab): Use legacy_psymtab.
9316 * dwarf2read.h (struct dwarf2_psymtab): New.
9317 (struct dwarf2_per_cu_data) <psymtab>: Use it.
9318 * dwarf2read.c (dwarf2_create_include_psymtab)
9319 (dwarf2_build_include_psymtabs, create_type_unit_group)
9320 (create_partial_symtab, process_psymtab_comp_unit_reader)
9321 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
9322 (set_partial_user): Use dwarf2_psymtab.
9323 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
9324 (psymtab_to_symtab_1, process_full_comp_unit)
9325 (process_full_type_unit, dwarf2_ranges_read)
9326 (dwarf2_get_pc_bounds, psymtab_include_file_name)
9327 (dwarf_decode_lines): Use dwarf2_psymtab.
9328 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
9329 (add_address_entry_worker, write_one_signatured_type)
9330 (recursively_count_psymbols, recursively_write_psymbols)
9331 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
9332 (write_debug_names): Likewise.
9333 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
9334 <pst>: Now a legacy_psymtab.
9335 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
9336 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
9337 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
9338 * ctfread.c (struct ctf_psymtab): New.
9339 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
9340 ctf_psymtab.
9341 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
9342 (create_partial_symtab): Return a ctf_psymtab.
9343 (scan_partial_symbols): Update.
9344
9345 2020-01-26 Tom Tromey <tom@tromey.com>
9346
9347 * xcoffread.c (xcoff_start_psymtab): Use new.
9348 * psymtab.c (partial_symtab::partial_symtab): New constructor,
9349 renamed from start_psymtab_common.
9350 * psympriv.h (struct partial_symtab): Add new constructor.
9351 (start_psymtab_common): Don't declare.
9352 * mdebugread.c (parse_partial_symbols): Use new.
9353 * dwarf2read.c (create_partial_symtab): Use new.
9354 * dbxread.c (start_psymtab): Use new.
9355 * ctfread.c (create_partial_symtab): Use new.
9356
9357 2020-01-26 Tom Tromey <tom@tromey.com>
9358
9359 * xcoffread.c (xcoff_end_psymtab): Use new.
9360 * psymtab.c (start_psymtab_common): Use new.
9361 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
9362 Update.
9363 * psympriv.h (struct partial_symtab): Add parameters to
9364 constructor. Don't inline.
9365 (allocate_psymtab): Don't declare.
9366 * mdebugread.c (new_psymtab): Use new.
9367 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
9368 * dbxread.c (dbx_end_psymtab): Use new.
9369
9370 2020-01-26 Tom Tromey <tom@tromey.com>
9371
9372 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
9373 allocate_psymtab. Update documentation.
9374 * psymtab.c (psymtab_storage::install_psymtab): Rename from
9375 allocate_psymtab. Do not use new.
9376 (allocate_psymtab): Use new. Update.
9377
9378 2020-01-26 Tom Tromey <tom@tromey.com>
9379
9380 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
9381 * psymtab.c (psym_print_stats): Update.
9382 * psympriv.h (struct partial_symtab) <readin,
9383 psymtabs_addrmap_supported, anonymous>: Now bool.
9384 * mdebugread.c (psymtab_to_symtab_1): Update.
9385 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
9386 (build_type_psymtabs_reader, psymtab_to_symtab_1)
9387 (process_full_comp_unit, process_full_type_unit): Update.
9388 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
9389 * ctfread.c (psymtab_to_symtab): Update.
9390
9391 2020-01-26 Tom Tromey <tom@tromey.com>
9392
9393 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
9394 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
9395 * psymtab.c (psymtab_storage): Delete psymtabs.
9396 (psymtab_storage::allocate_psymtab): Use new.
9397 (psymtab_storage::discard_psymtab): Use delete.
9398 * psympriv.h (struct partial_symtab): Add constructor and
9399 initializers.
9400
9401 2020-01-26 Tom Tromey <tom@tromey.com>
9402
9403 * machoread.c: Do not include psympriv.h.
9404
9405 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9406
9407 * NEWS: Mention the new option and the set/show commands.
9408
9409 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9410
9411 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
9412 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
9413 (validate_exec_file): New variables, enums, functions.
9414 (exec_file_locate_attach, print_section_info): Style the filenames.
9415 (_initialize_exec): Install show_exec_file_mismatch_command and
9416 set_exec_file_mismatch_command.
9417 * gdbcore.h (validate_exec_file): Declare.
9418 * infcmd.c (attach_command): Call validate_exec_file.
9419 * remote.c ( remote_target::remote_add_inferior): Likewise.
9420
9421 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9422
9423 * frame.c (find_frame_sal): Move call to get_next_frame into more
9424 inner scope.
9425 * inline-frame.c (inilne_state) <inline_state>: Update argument
9426 types.
9427 (inilne_state) <skipped_symbol>: Rename to...
9428 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
9429 (skip_inline_frames): Build vector of skipped symbols and use this
9430 to reate the inline_state.
9431 (inline_skipped_symbol): Add a comment and some assertions, fetch
9432 skipped symbol from the list.
9433
9434 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9435
9436 * buildsym.c (lte_is_less_than): Delete.
9437 (buildsym_compunit::end_symtab_with_blockvector): Create local
9438 lambda function to sort line table entries, and use
9439 std::stable_sort instead of std::sort.
9440 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
9441 markers when looking for a previous line.
9442
9443 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9444
9445 * dwarf2read.c (lnp_state_machine::record_line): Include
9446 end_sequence parameter in debug print out. Record the line if we
9447 are at an end_sequence marker even if it's not the start of a
9448 statement.
9449 * symmisc.c (maintenance_print_one_line_table): Print end of
9450 sequence markers with 'END' not '0'.
9451
9452 2020-01-24 Pedro Alves <palves@redhat.com>
9453
9454 PR gdb/25410
9455 * thread.c (scoped_restore_current_thread::restore): Use
9456 switch_to_inferior_no_thread.
9457 * exec.c: Include "progspace-and-thread.h".
9458 (add_target_sections, remove_target_sections):
9459 scoped_restore_current_pspace_and_thread instead of
9460 scoped_restore_current_thread.
9461 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
9462 and aspace to the inferior before calling clone_program_space.
9463 Remove stale comment.
9464
9465 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9466
9467 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
9468 (arm_netbsd_nat_target::fetch_registers): ...this.
9469 (arm_nbsd_nat_target::store_registers): Rename to...
9470 (arm_netbsd_nat_target::store_registers): ...this.
9471
9472 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9473
9474 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
9475 register_t.
9476
9477 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9478
9479 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
9480 Update comment.
9481 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
9482 Likewise.
9483 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
9484 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
9485 the correct replacement (iterate_over_regset_sections).
9486 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
9487 Update comment.
9488
9489 2020-01-24 Graham Markall <graham.markall@embecosm.com>
9490
9491 PR gdb/23718
9492 * gdb/python/python.c (execute_gdb_command): Call
9493 async_enable_stdin in catch block.
9494
9495 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9496
9497 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
9498 SWITCH_THRU_ALL_UIS.
9499
9500 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9501
9502 PR tui/9765
9503 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
9504 comment, add extra parameter, and update to store previous symbol
9505 when appropriate.
9506 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
9507 add extra parameter.
9508 * tui/tui-disasm.c (tui_disassemble): Update header comment,
9509 remove unneeded parameter, add try/catch around gdb_print_insn,
9510 rewrite to add items to asm_lines vector.
9511 (tui_find_backward_disassembly_start_address): New function.
9512 (tui_find_disassembly_address): Updated throughout.
9513 (tui_disasm_window::set_contents): Update for changes to
9514 tui_disassemble.
9515 (tui_disasm_window::do_scroll_vertical): No need to adjust the
9516 number of lines to scroll.
9517
9518 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
9519
9520 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
9521 (SECT_OFF_DATA): Likewise.
9522 (SECT_OFF_RODATA): Likewise.
9523 (SECT_OFF_TEXT): Likewise.
9524 (SECT_OFF_BSS): Likewise.
9525 (struct objfile) <text_section_offset, data_section_offset>: New
9526 methods.
9527 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
9528 objfile::text_section_offset.
9529 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
9530 * coffread.c (coff_symtab_read): Likewise.
9531 (enter_linenos): Likewise.
9532 (process_coff_symbol): Likewise.
9533 * ctfread.c (get_objfile_text_range): Likewise.
9534 * dtrace-probe.c (dtrace_probe::get_relocated_address):
9535 Use objfile::data_section_offset.
9536 * dwarf2-frame.c (execute_cfa_program): Use
9537 objfile::text_section_offset.
9538 (dwarf2_frame_find_fde): Likewise.
9539 * dwarf2read.c (create_addrmap_from_index): Likewise.
9540 (create_addrmap_from_aranges): Likewise.
9541 (dw2_find_pc_sect_compunit_symtab): Likewise.
9542 (process_psymtab_comp_unit_reader): Likewise.
9543 (add_partial_symbol): Likewise.
9544 (add_partial_subprogram): Likewise.
9545 (process_full_comp_unit): Likewise.
9546 (read_file_scope): Likewise.
9547 (read_func_scope): Likewise.
9548 (read_lexical_block_scope): Likewise.
9549 (read_call_site_scope): Likewise.
9550 (dwarf2_rnglists_process): Likewise.
9551 (dwarf2_ranges_process): Likewise.
9552 (dwarf2_ranges_read): Likewise.
9553 (dwarf_decode_lines_1): Likewise.
9554 (new_symbol): Likewise.
9555 (dwarf2_fetch_die_loc_sect_off): Likewise.
9556 (dwarf2_per_cu_text_offset): Likewise.
9557 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
9558 * hppa-tdep.c (read_unwind_info): Likewise.
9559 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
9560 * psympriv.h (struct partial_symtab): Likewise.
9561 * psymtab.c (find_pc_sect_psymtab): Likewise.
9562 * solib-svr4.c (enable_break): Likewise.
9563 * stap-probe.c (relocate_address): Use
9564 objfile::data_section_offset.
9565 * xcoffread.c (enter_line_range): Use
9566 objfile::text_section_offset.
9567 (read_xcoff_symtab): Likewise.
9568
9569 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
9570
9571 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
9572 declaration to narrower scopes.
9573
9574 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
9575
9576 * darwin-nat.h (struct darwin_exception_msg, enum
9577 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
9578 Move up.
9579 (class darwin_nat_target) <wait_1, check_new_threads,
9580 decode_exception_message, decode_message, stop_inferior,
9581 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
9582 * darwin-nat.c (darwin_check_new_threads): Rename to...
9583 (darwin_nat_target::check_new_threads): ... this.
9584 (darwin_suspend_inferior_it): Remove.
9585 (darwin_decode_exception_message): Rename to...
9586 (darwin_nat_target::decode_exception_message): ... this.
9587 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
9588 (darwin_decode_message): Rename to...
9589 (darwin_nat_target::decode_message): ... this.
9590 (cancel_breakpoint): Rename to...
9591 (darwin_nat_target::cancel_breakpoint): ... this.
9592 (darwin_wait): Rename to...
9593 (darwin_nat_target::wait_1): ... this. Use range-based for loop
9594 instead of iterate_over_inferiors.
9595 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
9596 (darwin_stop_inferior): Rename to...
9597 (darwin_nat_target::stop_inferior): ... this.
9598 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
9599 (darwin_init_thread_list): Rename to...
9600 (darwin_nat_target::init_thread_list): ... this.
9601 (darwin_ptrace_him): Rename to...
9602 (darwin_nat_target::ptrace_him): ... this.
9603 (darwin_nat_target::create_inferior): Pass lambda function to
9604 fork_inferior.
9605 (darwin_nat_target::detach): Call stop_inferior instead of
9606 darwin_stop_inferior.
9607 * fork-inferior.h (fork_inferior): Change init_trace_fun
9608 parameter to gdb::function_view.
9609 * fork-inferior.c (fork_inferior): Likewise.
9610
9611 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
9612
9613 * i386-cygwin-tdep.c (core_process_module_section): Update.
9614 * windows-nat.c (struct lm_info_windows): Add text_offset.
9615 (windows_xfer_shared_libraries): Update.
9616 * windows-tdep.c (windows_xfer_shared_library):
9617 Add text_offset_cached argument.
9618 * windows-tdep.h (windows_xfer_shared_library): Update.
9619
9620 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9621
9622 * gdbarch.sh: Add declaration for _initialize_gdbarch.
9623
9624 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9625
9626 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
9627 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
9628 replace with range-based for.
9629 (gdbsim_interrupt_inferior): Remove.
9630 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
9631 with a range-based for. Inline code from
9632 gdbsim_interrupt_inferior.
9633
9634 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9635
9636 * infrun.c (proceed): Fix indentation.
9637
9638 2020-01-21 Tom Tromey <tromey@adacore.com>
9639
9640 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
9641 * python/python.c (python_extension_ops): Update.
9642 (gdbpy_colorize): New function.
9643 * python/lib/gdb/__init__.py (colorize): New function.
9644 * extension.h (ext_lang_colorize): Declare.
9645 * extension.c (ext_lang_colorize): New function.
9646 * extension-priv.h (struct extension_language_ops) <colorize>: New
9647 member.
9648 * cli/cli-style.c (_initialize_cli_style): Update help text.
9649
9650 2020-01-21 Luis Machado <luis.machado@linaro.org>
9651
9652 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
9653 <cond>: Change type to bool.
9654 (aarch64_displaced_step_b_cond): Update cond to use bool type.
9655 (aarch64_displaced_step_cb): Likewise.
9656 (aarch64_displaced_step_tb): Likewise.
9657
9658 2020-01-21 Luis Machado <luis.machado@linaro.org>
9659
9660 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
9661 output.
9662
9663 2020-01-21 Luis Machado <luis.machado@linaro.org>
9664
9665 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
9666 <pc_adjust>: Adjust the documentation.
9667 (aarch64_displaced_step_fixup): Check if PC really moved before
9668 adjusting it.
9669
9670 2020-01-19 Tom Tromey <tom@tromey.com>
9671
9672 * disasm.c (~gdb_disassembler): New destructor.
9673 (gdb_buffered_insn_length): Call disassemble_free_target.
9674 * disasm.h (class gdb_disassembler): Declare destructor. Use
9675 DISABLE_COPY_AND_ASSIGN.
9676
9677 2020-01-19 Tom Tromey <tom@tromey.com>
9678
9679 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
9680 (die_reader_func_ftype): Remove.
9681 (cutu_reader): New class.
9682 (dw2_get_file_names_reader): Remove "data" parameter.
9683 (dw2_get_file_names): Use cutu_reader.
9684 (create_debug_type_hash_table): Update.
9685 (read_cutu_die_from_dwo): Update comment.
9686 (lookup_dwo_unit): Add dwo_name parameter.
9687 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
9688 die_reader_func_ftype and data parameters.
9689 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
9690 Remove die_reader_func_ftype and data parameters.
9691 (~cutu_reader): New; from init_cutu_and_read_dies.
9692 (cutu_reader::cutu_reader): Rename from
9693 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
9694 and data parameters.
9695 (init_cutu_and_read_dies_simple): Remove.
9696 (struct process_psymtab_comp_unit_data): Remove.
9697 (process_psymtab_comp_unit_reader): Remove data parameter; add
9698 want_partial_unit and pretend_language parameters.
9699 (process_psymtab_comp_unit): Use cutu_reader.
9700 (build_type_psymtabs_reader): Remove data parameter.
9701 (build_type_psymtabs_1): Use cutu_reader.
9702 (process_skeletonless_type_unit): Likewise.
9703 (load_partial_comp_unit_reader): Remove.
9704 (load_partial_comp_unit): Use cutu_reader.
9705 (load_full_comp_unit_reader): Remove.
9706 (load_full_comp_unit): Use cutu_reader.
9707 (struct create_dwo_cu_data): Remove.
9708 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
9709 dwo_unit parameters.
9710 (create_cus_hash_table): Use cutu_reader.
9711 (struct dwarf2_read_addr_index_data): Remove.
9712 (dwarf2_read_addr_index_reader): Remove.
9713 (dwarf2_read_addr_index): Use cutu_reader.
9714 (read_signatured_type_reader): Remove.
9715 (read_signatured_type): Use cutu_reader.
9716
9717 2020-01-19 Tom Tromey <tom@tromey.com>
9718
9719 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
9720 * tui/tui-wingeneral.h (class tui_suppress_output): New.
9721 (tui_wrefresh): Declare.
9722 * tui/tui-wingeneral.c (suppress_output): New global.
9723 (tui_suppress_output, ~tui_suppress_output): New constructor and
9724 destructor.
9725 (tui_wrefresh): New function.
9726 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
9727 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
9728 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
9729 method.
9730 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
9731 tui_wrefresh.
9732 (tui_data_window::no_refresh): New method.
9733 (tui_data_item_window::refresh_window): Call tui_wrefresh.
9734 (tui_reg_command): Use tui_suppress_output
9735 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
9736 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
9737 method.
9738 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
9739
9740 2020-01-19 Tom Tromey <tom@tromey.com>
9741
9742 * tui/tui-winsource.c (tui_update_source_windows_with_line):
9743 Handle case where symtab is null.
9744
9745 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
9746
9747 * linux-fork.c (one_fork_p): Simplify.
9748
9749 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9750
9751 * top.c (struct qt_args): Remove.
9752 (kill_or_detach): Change return type to void, replace `void *`
9753 parameter with a proper one.
9754 (print_inferior_quit_action): Likewise.
9755 (quit_confirm): Use range-based for loop to iterate over inferiors.
9756 (quit_force): Likewise.
9757
9758 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9759
9760 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
9761 `void *` parameter with proper parameters.
9762 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
9763 (print_one_inferior): Change return type to void, replace `void *`
9764 parameter with proper parameters.
9765 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
9766 inferiors.
9767 (get_other_inferior): Remove.
9768 (mi_cmd_remove_inferior): Use range-based loop to iterate over
9769 inferiors.
9770
9771 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9772
9773 * mi/mi-interp.c (report_initial_inferior): Remove.
9774 (mi_interp::init): Use range-based for to iterate over inferiors.
9775
9776 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9777
9778 * python/py-inferior.c (build_inferior_list): Remove.
9779 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
9780
9781 2020-01-16 Christian Biesinger <cbiesinger@google.com>
9782
9783 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
9784 (btrace_stitch_trace): Likewise.
9785 * charset.c (intermediate_encoding): Likewise (vaild).
9786 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
9787 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
9788 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
9789
9790 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
9791
9792 * windows-tdep.c (windows_get_tlb_type):
9793 Add rtl_user_process_parameters type.
9794
9795 2020-01-16 Pedro Alves <palves@redhat.com>
9796 Norbert Lange <nolange79@gmail.com>
9797
9798 PR build/24805
9799 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
9800 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
9801 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
9802 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
9803 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
9804 (ps_plog): Redeclare exported functions with default visibility.
9805
9806 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
9807
9808 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
9809 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
9810
9811 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
9812
9813 * infcmd.c (post_create_inferior): Use get_thread_regcache
9814 instead of get_current_regcache.
9815
9816 2020-01-14 Tom Tromey <tom@tromey.com>
9817
9818 PR symtab/12535:
9819 * python/python.c (gdbpy_decode_line): Treat empty string the same
9820 as no argument.
9821
9822 2020-01-14 Tom Tromey <tom@tromey.com>
9823
9824 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
9825
9826 2020-01-14 Tom Tromey <tom@tromey.com>
9827
9828 * nat/linux-btrace.c: Don't include <config.h>.
9829 * nat/linux-ptrace.c: Don't include <config.h>.
9830 * nat/x86-linux-dregs.c: Don't include <config.h>.
9831
9832 2020-01-14 Tom Tromey <tom@tromey.com>
9833
9834 * configure: Rebuild.
9835 * configure.ac: Move many checks to ../gdbsupport/common.m4.
9836
9837 2020-01-14 Tom Tromey <tom@tromey.com>
9838
9839 * nat/x86-linux-dregs.c: Include configh.h.
9840 * nat/linux-ptrace.c: Include configh.h.
9841 * nat/linux-btrace.c: Include configh.h.
9842 * defs.h: Include config.h, bfd.h.
9843 * configure.ac: Don't source common.host.
9844 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
9845 * configure: Rebuild.
9846 * acinclude.m4: Update path.
9847 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
9848 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
9849 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
9850 (CLIBS): Add LIBSUPPORT.
9851 (CDEPS): Likewise.
9852 (COMMON_SFILES): Remove gdbsupport files.
9853 (HFILES_NO_SRCDIR): Likewise.
9854 (stamp-version): Update path to create-version.sh.
9855 (ALLDEPFILES): Remove gdbsupport files.
9856
9857 2020-01-14 Tom Tromey <tom@tromey.com>
9858
9859 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
9860 USE_WIN32API when needed.
9861 * configure.ac (USE_WIN32API): Don't define.
9862 (WIN32LIBS): Use WIN32APILIBS.
9863 * configure: Rebuild.
9864
9865 2020-01-14 Tom Tromey <tom@tromey.com>
9866
9867 * configure: Rebuild.
9868 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
9869
9870 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
9871
9872 * skip.c (skip_function_command): Make skip w/o arguments use the
9873 name of the inlined function if pc is inside any inlined function.
9874
9875 2020-01-14 Luis Machado <luis.machado@linaro.org>
9876
9877 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
9878 * infrun.c (resume_1): Likewise.
9879 (handle_inferior_event): Remove stale comment.
9880 * linux-nat.c (linux_nat_target::resume): Update comments.
9881 (save_stop_reason): Likewise.
9882 (linux_nat_filter_event): Likewise.
9883 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
9884
9885 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9886
9887 * elfread.c (record_minimal_symbol): Set section index to 0 for
9888 non-allocatable sections.
9889
9890
9891 2020-01-13 Ali Tamur <tamur@google.com>
9892
9893 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
9894 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
9895 to gdb::optional. Update comments.
9896 (dwo_file): Update comments.
9897 (read_attribute): Update API to take an additional out parameter,
9898 need_reprocess. This is used to mark attributes that need other
9899 attributes (e.g. str_offsets_base) for correct computation which may not
9900 have been read yet.
9901 (read_attribute_reprocess): New function declaration.
9902 (read_addr_index): Likewise.
9903 (read_dwo_str_index): Likewise.
9904 (read_stub_str_index): Likewise.
9905 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
9906 (lookup_addr_base): New function definition.
9907 (lookup_ranges_base): Likewise.
9908 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
9909 lookup_ranges_base.
9910 (init_cutu_and_read_dies): Update comments.
9911 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
9912 unit. This is used to inherit parent's str_offsets_base and addr_base.
9913 Update comments.
9914 (init_cutu_and_read_dies_simple): Reflect API changes.
9915 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
9916 (create_cus_hash_table): Change API to take parent compile unit.
9917 Reflect API changes.
9918 (open_and_init_dwo_file): Reflect API changes.
9919 (dwarf2_get_pc_bounds): Update comments.
9920 (dwarf2_record_block_ranges): Likewise.
9921 (read_full_die_1): Change implementation to reprocess attributes that
9922 need str_offsets_base and addr_base.
9923 (partial_die_info::read): Likewise.
9924 (read_attribute_reprocess): New function definition.
9925 (read_attribute_value): Change API to take an additional out parameter,
9926 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
9927 when a non-dwo compile unit has index based attributes.
9928 (read_attribute): Reflect API changes.
9929 (read_addr_index_1): Reflect API changes. Update comments.
9930 (dwarf2_read_addr_index_data): Reflect API changes.
9931 (dwarf2_read_addr_index): Likewise.
9932 (read_str_index): Change API and implementation. This becomes a helper
9933 to be used by the new string index related methods. Update error
9934 message and comments.
9935 (read_dwo_str_index): New function definition.
9936 (read_stub_str_index): Likewise.
9937 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
9938 * symfile.h (dwarf2_debug_sections): Likewise.
9939 * xcoffread.c (dwarf2_debug_sections): Likewise.
9940
9941 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9942
9943 * gdbcore.h (struct core_fns) <core_read_registers>: Change
9944 core_reg_sect type to gdb_byte *.
9945 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
9946 * cris-tdep.c (fetch_core_registers): Likewise.
9947 * corelow.c (core_target::get_core_register_section): Change
9948 type of `contents` to gdb::byte_vector.
9949
9950 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9951
9952 * tui/tui-wingeneral.c (box_win): Position the title in the center
9953 of the border.
9954
9955 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9956
9957 * corelow.c (core_target::get_core_register_section): Use
9958 std::vector instead of alloca.
9959
9960 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9961
9962 * warning.m4: Add -Wmissing-declarations to build_warnings.
9963 * configure: Re-generate.
9964
9965 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9966
9967 * python/python.c (init__gdb_module): Add declaration.
9968
9969 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9970
9971 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
9972 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
9973 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
9974 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
9975 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
9976 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
9977 * ada-exp.y (_initialize_ada_exp): Add declaration.
9978 * ada-lang.c (_initialize_ada_language): Add declaration.
9979 * ada-tasks.c (_initialize_tasks): Add declaration.
9980 * agent.c (_initialize_agent): Add declaration.
9981 * aix-thread.c (_initialize_aix_thread): Add declaration.
9982 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
9983 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
9984 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
9985 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
9986 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
9987 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
9988 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
9989 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
9990 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
9991 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
9992 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
9993 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
9994 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
9995 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
9996 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
9997 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
9998 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
9999 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
10000 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
10001 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
10002 * annotate.c (_initialize_annotate): Add declaration.
10003 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
10004 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
10005 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
10006 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
10007 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
10008 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
10009 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
10010 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
10011 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
10012 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
10013 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
10014 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
10015 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
10016 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
10017 * auto-load.c (_initialize_auto_load): Add declaration.
10018 * auxv.c (_initialize_auxv): Add declaration.
10019 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
10020 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
10021 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
10022 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
10023 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
10024 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
10025 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
10026 * breakpoint.c (_initialize_breakpoint): Add declaration.
10027 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
10028 * btrace.c (_initialize_btrace): Add declaration.
10029 * charset.c (_initialize_charset): Add declaration.
10030 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
10031 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
10032 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
10033 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
10034 * cli/cli-script.c (_initialize_cli_script): Add declaration.
10035 * cli/cli-style.c (_initialize_cli_style): Add declaration.
10036 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
10037 * coffread.c (_initialize_coffread): Add declaration.
10038 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
10039 * compile/compile.c (_initialize_compile): Add declaration.
10040 * complaints.c (_initialize_complaints): Add declaration.
10041 * completer.c (_initialize_completer): Add declaration.
10042 * copying.c (_initialize_copying): Add declaration.
10043 * corefile.c (_initialize_core): Add declaration.
10044 * corelow.c (_initialize_corelow): Add declaration.
10045 * cp-abi.c (_initialize_cp_abi): Add declaration.
10046 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
10047 * cp-support.c (_initialize_cp_support): Add declaration.
10048 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
10049 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
10050 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
10051 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
10052 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
10053 * ctfread.c (_initialize_ctfread): Add declaration.
10054 * d-lang.c (_initialize_d_language): Add declaration.
10055 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
10056 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
10057 * dbxread.c (_initialize_dbxread): Add declaration.
10058 * dcache.c (_initialize_dcache): Add declaration.
10059 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
10060 * disasm.c (_initialize_disasm): Add declaration.
10061 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
10062 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
10063 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
10064 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
10065 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
10066 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
10067 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
10068 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
10069 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
10070 * elfread.c (_initialize_elfread): Add declaration.
10071 * exec.c (_initialize_exec): Add declaration.
10072 * extension.c (_initialize_extension): Add declaration.
10073 * f-lang.c (_initialize_f_language): Add declaration.
10074 * f-valprint.c (_initialize_f_valprint): Add declaration.
10075 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
10076 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
10077 * filesystem.c (_initialize_filesystem): Add declaration.
10078 * findcmd.c (_initialize_mem_search): Add declaration.
10079 * findvar.c (_initialize_findvar): Add declaration.
10080 * fork-child.c (_initialize_fork_child): Add declaration.
10081 * frame-base.c (_initialize_frame_base): Add declaration.
10082 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
10083 * frame.c (_initialize_frame): Add declaration.
10084 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
10085 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
10086 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
10087 * gcore.c (_initialize_gcore): Add declaration.
10088 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
10089 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
10090 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
10091 * gdbarch.c (_initialize_gdbarch): Add declaration.
10092 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
10093 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
10094 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
10095 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
10096 * go-lang.c (_initialize_go_language): Add declaration.
10097 * go32-nat.c (_initialize_go32_nat): Add declaration.
10098 * guile/guile.c (_initialize_guile): Add declaration.
10099 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
10100 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
10101 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
10102 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
10103 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
10104 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
10105 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
10106 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
10107 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
10108 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
10109 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
10110 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
10111 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
10112 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
10113 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
10114 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
10115 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
10116 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
10117 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
10118 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
10119 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
10120 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
10121 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
10122 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
10123 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
10124 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
10125 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
10126 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
10127 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
10128 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
10129 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
10130 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
10131 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
10132 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
10133 * infcall.c (_initialize_infcall): Add declaration.
10134 * infcmd.c (_initialize_infcmd): Add declaration.
10135 * inflow.c (_initialize_inflow): Add declaration.
10136 * infrun.c (_initialize_infrun): Add declaration.
10137 * interps.c (_initialize_interpreter): Add declaration.
10138 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
10139 * jit.c (_initialize_jit): Add declaration.
10140 * language.c (_initialize_language): Add declaration.
10141 * linux-fork.c (_initialize_linux_fork): Add declaration.
10142 * linux-nat.c (_initialize_linux_nat): Add declaration.
10143 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
10144 * linux-thread-db.c (_initialize_thread_db): Add declaration.
10145 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
10146 * m2-lang.c (_initialize_m2_language): Add declaration.
10147 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
10148 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
10149 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
10150 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
10151 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
10152 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
10153 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
10154 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
10155 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
10156 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
10157 * machoread.c (_initialize_machoread): Add declaration.
10158 * macrocmd.c (_initialize_macrocmd): Add declaration.
10159 * macroscope.c (_initialize_macroscope): Add declaration.
10160 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
10161 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
10162 * maint.c (_initialize_maint_cmds): Add declaration.
10163 * mdebugread.c (_initialize_mdebugread): Add declaration.
10164 * memattr.c (_initialize_mem): Add declaration.
10165 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
10166 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
10167 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
10168 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
10169 * mi/mi-main.c (_initialize_mi_main): Add declaration.
10170 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
10171 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
10172 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
10173 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
10174 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
10175 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
10176 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
10177 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
10178 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
10179 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
10180 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
10181 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
10182 * mipsread.c (_initialize_mipsread): Add declaration.
10183 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
10184 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
10185 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
10186 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
10187 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
10188 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
10189 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
10190 * nto-procfs.c (_initialize_procfs): Add declaration.
10191 * objc-lang.c (_initialize_objc_language): Add declaration.
10192 * observable.c (_initialize_observer): Add declaration.
10193 * opencl-lang.c (_initialize_opencl_language): Add declaration.
10194 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
10195 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
10196 * osabi.c (_initialize_gdb_osabi): Add declaration.
10197 * osdata.c (_initialize_osdata): Add declaration.
10198 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
10199 * parse.c (_initialize_parse): Add declaration.
10200 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
10201 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
10202 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
10203 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
10204 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
10205 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
10206 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
10207 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
10208 * printcmd.c (_initialize_printcmd): Add declaration.
10209 * probe.c (_initialize_probe): Add declaration.
10210 * proc-api.c (_initialize_proc_api): Add declaration.
10211 * proc-events.c (_initialize_proc_events): Add declaration.
10212 * proc-service.c (_initialize_proc_service): Add declaration.
10213 * procfs.c (_initialize_procfs): Add declaration.
10214 * producer.c (_initialize_producer): Add declaration.
10215 * psymtab.c (_initialize_psymtab): Add declaration.
10216 * python/python.c (_initialize_python): Add declaration.
10217 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
10218 * record-btrace.c (_initialize_record_btrace): Add declaration.
10219 * record-full.c (_initialize_record_full): Add declaration.
10220 * record.c (_initialize_record): Add declaration.
10221 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
10222 * regcache.c (_initialize_regcache): Add declaration.
10223 * reggroups.c (_initialize_reggroup): Add declaration.
10224 * remote-notif.c (_initialize_notif): Add declaration.
10225 * remote-sim.c (_initialize_remote_sim): Add declaration.
10226 * remote.c (_initialize_remote): Add declaration.
10227 * reverse.c (_initialize_reverse): Add declaration.
10228 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
10229 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
10230 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
10231 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
10232 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
10233 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
10234 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
10235 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
10236 Add declaration.
10237 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
10238 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
10239 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
10240 * rust-exp.y (_initialize_rust_exp): Add declaration.
10241 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
10242 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
10243 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
10244 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
10245 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
10246 * score-tdep.c (_initialize_score_tdep): Add declaration.
10247 * ser-go32.c (_initialize_ser_dos): Add declaration.
10248 * ser-mingw.c (_initialize_ser_windows): Add declaration.
10249 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
10250 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
10251 * ser-uds.c (_initialize_ser_socket): Add declaration.
10252 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
10253 * serial.c (_initialize_serial): Add declaration.
10254 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
10255 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
10256 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
10257 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
10258 * skip.c (_initialize_step_skip): Add declaration.
10259 * sol-thread.c (_initialize_sol_thread): Add declaration.
10260 * solib-aix.c (_initialize_solib_aix): Add declaration.
10261 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
10262 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
10263 * solib-frv.c (_initialize_frv_solib): Add declaration.
10264 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
10265 * solib-target.c (_initialize_solib_target): Add declaration.
10266 * solib.c (_initialize_solib): Add declaration.
10267 * source-cache.c (_initialize_source_cache): Add declaration.
10268 * source.c (_initialize_source): Add declaration.
10269 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
10270 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
10271 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
10272 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
10273 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
10274 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
10275 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
10276 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
10277 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
10278 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
10279 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
10280 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
10281 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
10282 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
10283 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
10284 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
10285 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
10286 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
10287 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
10288 * stabsread.c (_initialize_stabsread): Add declaration.
10289 * stack.c (_initialize_stack): Add declaration.
10290 * stap-probe.c (_initialize_stap_probe): Add declaration.
10291 * std-regs.c (_initialize_frame_reg): Add declaration.
10292 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
10293 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
10294 * symfile.c (_initialize_symfile): Add declaration.
10295 * symmisc.c (_initialize_symmisc): Add declaration.
10296 * symtab.c (_initialize_symtab): Add declaration.
10297 * target.c (_initialize_target): Add declaration.
10298 * target-connection.c (_initialize_target_connection): Add
10299 declaration.
10300 * target-dcache.c (_initialize_target_dcache): Add declaration.
10301 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
10302 * thread.c (_initialize_thread): Add declaration.
10303 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
10304 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
10305 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
10306 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
10307 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
10308 * tracectf.c (_initialize_ctf): Add declaration.
10309 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
10310 * tracefile.c (_initialize_tracefile): Add declaration.
10311 * tracepoint.c (_initialize_tracepoint): Add declaration.
10312 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
10313 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
10314 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
10315 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
10316 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
10317 * tui/tui-win.c (_initialize_tui_win): Add declaration.
10318 * tui/tui.c (_initialize_tui): Add declaration.
10319 * typeprint.c (_initialize_typeprint): Add declaration.
10320 * ui-style.c (_initialize_ui_style): Add declaration.
10321 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
10322 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
10323 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
10324 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
10325 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
10326 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
10327 * unittests/filtered_iterator-selftests.c
10328 (_initialize_filtered_iterator_selftests): Add declaration.
10329 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
10330 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
10331 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
10332 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
10333 * unittests/main-thread-selftests.c
10334 (_initialize_main_thread_selftests): Add declaration.
10335 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
10336 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
10337 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
10338 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
10339 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
10340 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
10341 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
10342 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
10343 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
10344 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
10345 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
10346 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
10347 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
10348 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
10349 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
10350 declaration.
10351 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
10352 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
10353 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
10354 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
10355 * user-regs.c (_initialize_user_regs): Add declaration.
10356 * utils.c (_initialize_utils): Add declaration.
10357 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
10358 * valops.c (_initialize_valops): Add declaration.
10359 * valprint.c (_initialize_valprint): Add declaration.
10360 * value.c (_initialize_values): Add declaration.
10361 * varobj.c (_initialize_varobj): Add declaration.
10362 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
10363 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
10364 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
10365 * windows-nat.c (_initialize_windows_nat): Add declaration.
10366 (_initialize_check_for_gdb_ini): Add declaration.
10367 (_initialize_loadable): Add declaration.
10368 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
10369 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
10370 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
10371 * xcoffread.c (_initialize_xcoffread): Add declaration.
10372 * xml-support.c (_initialize_xml_support): Add declaration.
10373 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
10374 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
10375 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
10376 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
10377
10378 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10379
10380 * regformats/regdat.sh: Generate declaration for init function.
10381
10382 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10383
10384 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
10385 up.
10386 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
10387 close_one_inferior>: New methods.
10388 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
10389 pass down target to find_inferior_pid.
10390 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
10391 Pass down target to find_inferior_ptid.
10392 (gdbsim_target::create_inferior): Pass down target to
10393 add_thread_silent.
10394 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
10395 target down to find_inferior_ptid and switch_to_thread.
10396 (gdbsim_target::close): Update to call close_one_inferior.
10397 (struct resume_data): Remove.
10398 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
10399 directly, rather than through a void pointer.
10400 (gdbsim_target::resume): Update to call resume_one_inferior.
10401
10402 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
10403
10404 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
10405
10406 2020-01-12 Pedro Alves <palves@redhat.com>
10407
10408 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
10409 directly for the current inferior instead of
10410 discard_all_inferiors.
10411 (discard_all_inferiors): Delete.
10412
10413 2020-01-11 Tom Tromey <tom@tromey.com>
10414
10415 * tui/tui-wingeneral.c (box_win): Check cli_styling.
10416 * tui/tui-winsource.c (tui_source_window_base::refill): Use
10417 deprecated_safe_get_selected_frame.
10418
10419 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10420
10421 * inferior.c (print_inferior): Switch inferior before printing it.
10422
10423 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
10424 Pedro Alves <palves@redhat.com>
10425
10426 * progspace-and-thread.c (switch_to_program_space_and_thread):
10427 Assert there's an inferior for PSPACE. Use
10428 switch_to_inferior_no_thread to switch the inferior too.
10429 * progspace.c (program_space::~program_space): Call
10430 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
10431 (program_space::free_all_objfiles): Don't call clear_symtab_users
10432 here.
10433 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
10434
10435 2020-01-10 Pedro Alves <palves@redhat.com>
10436
10437 * NEWS: Mention multi-target debugging, "info connections", and
10438 "add-inferior -no-connection".
10439
10440 2020-01-10 Pedro Alves <palves@redhat.com>
10441
10442 * infrun.c: Include "target-connection.h".
10443 (check_multi_target_resumption): New.
10444 (proceed): Call it.
10445 * target-connection.c (make_target_connection_string): Make
10446 extern.
10447 * target-connection.h (make_target_connection_string): Declare.
10448
10449 2020-01-10 Pedro Alves <palves@redhat.com>
10450
10451 * Makefile.in (COMMON_SFILES): Add target-connection.c.
10452 * inferior.c (uiout_field_connection): New function.
10453 (print_inferior): Add new "connection-id" column.
10454 (add_inferior_command): Show connection number/string of added
10455 inferior.
10456 * process-stratum-target.h
10457 (process_stratum_target::connection_string): New virtual method.
10458 (process_stratum_target::connection_number): New field.
10459 * remote.c (remote_target::connection_string): New override.
10460 * target-connection.c: New file.
10461 * target-connection.h: New file.
10462 * target.c (decref_target): Remove process_stratum targets from
10463 the connection list.
10464 (target_stack::push): Add process_stratum targets to the
10465 connection list.
10466
10467 2020-01-10 Pedro Alves <palves@redhat.com>
10468
10469 Revert:
10470 2016-04-12 Pedro Alves <palves@redhat.com>
10471 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
10472 Remove references to name.
10473 * serial.h (struct serial) <name>: Delete.
10474
10475 2020-01-10 Pedro Alves <palves@redhat.com>
10476
10477 * gdbarch-selftests.c (register_to_value_test): Remove "target
10478 already pushed" check.
10479
10480 2020-01-10 Pedro Alves <palves@redhat.com>
10481 John Baldwin <jhb@FreeBSD.org>
10482
10483 * aarch64-linux-nat.c
10484 (aarch64_linux_nat_target::thread_architecture): Adjust.
10485 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
10486 (task_command_1): Likewise.
10487 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
10488 (aix_thread_target::wait, aix_thread_target::fetch_registers)
10489 (aix_thread_target::store_registers)
10490 (aix_thread_target::thread_alive): Adjust.
10491 * amd64-fbsd-tdep.c: Include "inferior.h".
10492 (amd64fbsd_get_thread_local_address): Pass down target.
10493 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
10494 thread's gdbarch instead of target_gdbarch.
10495 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
10496 get_last_target_status.
10497 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
10498 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
10499 inferiors.
10500 (update_inserted_breakpoint_locations): Skip if inferiors with no
10501 execution.
10502 (update_global_location_list): When handling moribund locations,
10503 find representative inferior for location's pspace, and use thread
10504 count of its process_stratum target.
10505 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
10506 * bsd-uthread.c (bsd_uthread_target::wait): Use
10507 as_process_stratum_target and adjust thread_change_ptid and
10508 add_thread calls.
10509 (bsd_uthread_target::update_thread_list): Use
10510 as_process_stratum_target and adjust find_thread_ptid,
10511 thread_change_ptid and add_thread calls.
10512 * btrace.c (maint_btrace_packet_history_cmd): Adjust
10513 find_thread_ptid call.
10514 * corelow.c (add_to_thread_list): Adjust add_thread call.
10515 (core_target_open): Adjust add_thread_silent and thread_count
10516 calls.
10517 (core_target::pid_to_str): Adjust find_inferior_ptid call.
10518 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
10519 * event-top.c (async_disconnect): Pop targets from all inferiors.
10520 * exec.c (add_target_sections): Push exec target on all inferiors
10521 sharing the program space.
10522 (remove_target_sections): Remove the exec target from all
10523 inferiors sharing the program space.
10524 (exec_on_vfork): New.
10525 * exec.h (exec_on_vfork): Declare.
10526 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
10527 Pass it down.
10528 (fbsd_nat_target::update_thread_list): Adjust.
10529 (fbsd_nat_target::resume): Adjust.
10530 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
10531 down.
10532 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
10533 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
10534 get_thread_arch_regcache call.
10535 * fork-child.c (gdb_startup_inferior): Pass target down to
10536 startup_inferior and set_executing.
10537 * gdbthread.h (struct process_stratum_target): Forward declare.
10538 (add_thread, add_thread_silent, add_thread_with_info)
10539 (in_thread_list): Add process_stratum_target parameter.
10540 (find_thread_ptid(inferior*, ptid_t)): New overload.
10541 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
10542 parameter.
10543 (all_threads()): Delete overload.
10544 (all_threads, all_non_exited_threads): Add process_stratum_target
10545 parameter.
10546 (all_threads_safe): Use brace initialization.
10547 (thread_count): Add process_stratum_target parameter.
10548 (set_resumed, set_running, set_stop_requested, set_executing)
10549 (threads_are_executing, finish_thread_state): Add
10550 process_stratum_target parameter.
10551 (switch_to_thread): Use is_current_thread.
10552 * i386-fbsd-tdep.c: Include "inferior.h".
10553 (i386fbsd_get_thread_local_address): Pass down target.
10554 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
10555 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
10556 have_inferiors check.
10557 * inf-ptrace.c (inf_ptrace_target::create_inferior)
10558 (inf_ptrace_target::attach): Adjust.
10559 * infcall.c (run_inferior_call): Adjust.
10560 * infcmd.c (run_command_1): Pass target to
10561 scoped_finish_thread_state.
10562 (proceed_thread_callback): Skip inferiors with no execution.
10563 (continue_command): Rename 'all_threads' local to avoid hiding
10564 'all_threads' function. Adjust get_last_target_status call.
10565 (prepare_one_step): Adjust set_running call.
10566 (signal_command): Use user_visible_resume_target. Compare thread
10567 pointers instead of inferior_ptid.
10568 (info_program_command): Adjust to pass down target.
10569 (attach_command): Mark target's 'thread_executing' flag.
10570 (stop_current_target_threads_ns): New, factored out from ...
10571 (interrupt_target_1): ... this. Switch inferior before making
10572 target calls.
10573 * inferior-iter.h
10574 (struct all_inferiors_iterator, struct all_inferiors_range)
10575 (struct all_inferiors_safe_range)
10576 (struct all_non_exited_inferiors_range): Filter on
10577 process_stratum_target too. Remove explicit.
10578 * inferior.c (inferior::inferior): Push dummy target on target
10579 stack.
10580 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
10581 Add process_stratum_target parameter, and pass it down.
10582 (have_live_inferiors): Adjust.
10583 (switch_to_inferior_and_push_target): New.
10584 (add_inferior_command, clone_inferior_command): Handle
10585 "-no-connection" parameter. Use
10586 switch_to_inferior_and_push_target.
10587 (_initialize_inferior): Mention "-no-connection" option in
10588 the help of "add-inferior" and "clone-inferior" commands.
10589 * inferior.h: Include "process-stratum-target.h".
10590 (interrupt_target_1): Use bool.
10591 (struct inferior) <push_target, unpush_target, target_is_pushed,
10592 find_target_beneath, top_target, process_target, target_at,
10593 m_stack>: New.
10594 (discard_all_inferiors): Delete.
10595 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
10596 (all_inferiors, all_non_exited_inferiors): Add
10597 process_stratum_target parameter.
10598 * infrun.c: Include "gdb_select.h" and <unordered_map>.
10599 (target_last_proc_target): New global.
10600 (follow_fork_inferior): Push target on new inferior. Pass target
10601 to add_thread_silent. Call exec_on_vfork. Handle target's
10602 reference count.
10603 (follow_fork): Adjust get_last_target_status call. Also consider
10604 target.
10605 (follow_exec): Push target on new inferior.
10606 (struct execution_control_state) <target>: New field.
10607 (user_visible_resume_target): New.
10608 (do_target_resume): Call target_async.
10609 (resume_1): Set target's threads_executing flag. Consider resume
10610 target.
10611 (commit_resume_all_targets): New.
10612 (proceed): Also consider resume target. Skip threads of inferiors
10613 with no execution. Commit resumtion in all targets.
10614 (start_remote): Pass current inferior to wait_for_inferior.
10615 (infrun_thread_stop_requested): Consider target as well. Pass
10616 thread_info pointer to clear_inline_frame_state instead of ptid.
10617 (infrun_thread_thread_exit): Consider target as well.
10618 (random_pending_event_thread): New inferior parameter. Use it.
10619 (do_target_wait): Rename to ...
10620 (do_target_wait_1): ... this. Add inferior parameter, and pass it
10621 down.
10622 (threads_are_resumed_pending_p, do_target_wait): New.
10623 (prepare_for_detach): Adjust calls.
10624 (wait_for_inferior): New inferior parameter. Handle it. Use
10625 do_target_wait_1 instead of do_target_wait.
10626 (fetch_inferior_event): Adjust. Switch to representative
10627 inferior. Pass target down.
10628 (set_last_target_status): Add process_stratum_target parameter.
10629 Save target in global.
10630 (get_last_target_status): Add process_stratum_target parameter and
10631 handle it.
10632 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
10633 (context_switch): Check inferior_ptid == null_ptid before calling
10634 inferior_thread().
10635 (get_inferior_stop_soon): Pass down target.
10636 (wait_one): Rename to ...
10637 (poll_one_curr_target): ... this.
10638 (struct wait_one_event): New.
10639 (wait_one): New.
10640 (stop_all_threads): Adjust.
10641 (handle_no_resumed, handle_inferior_event): Adjust to consider the
10642 event's target.
10643 (switch_back_to_stepped_thread): Also consider target.
10644 (print_stop_event): Update.
10645 (normal_stop): Update. Also consider the resume target.
10646 * infrun.h (wait_for_inferior): Remove declaration.
10647 (user_visible_resume_target): New declaration.
10648 (get_last_target_status, set_last_target_status): New
10649 process_stratum_target parameter.
10650 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
10651 process_stratum_target parameter, and use it.
10652 (clear_inline_frame_state (thread_info*)): New.
10653 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
10654 process_stratum_target parameter.
10655 (clear_inline_frame_state (thread_info*)): Declare.
10656 * linux-fork.c (delete_checkpoint_command): Pass target down to
10657 find_thread_ptid.
10658 (checkpoint_command): Adjust.
10659 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
10660 instead of just tweaking inferior_ptid.
10661 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
10662 (exit_lwp): Pass target down to find_thread_ptid.
10663 (attach_proc_task_lwp_callback): Pass target down to
10664 add_thread/set_running/set_executing.
10665 (linux_nat_target::attach): Pass target down to
10666 thread_change_ptid.
10667 (get_detach_signal): Pass target down to find_thread_ptid.
10668 Consider last target status's target.
10669 (linux_resume_one_lwp_throw, resume_lwp)
10670 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
10671 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
10672 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
10673 (linux_nat_target::async_wait_fd): New.
10674 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
10675 target down.
10676 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
10677 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
10678 * linux-thread-db.c (struct thread_db_info::process_target): New
10679 field.
10680 (add_thread_db_info): Save target.
10681 (get_thread_db_info): New process_stratum_target parameter. Also
10682 match target.
10683 (delete_thread_db_info): New process_stratum_target parameter.
10684 Also match target.
10685 (thread_from_lwp): Adjust to pass down target.
10686 (thread_db_notice_clone): Pass down target.
10687 (check_thread_db_callback): Pass down target.
10688 (try_thread_db_load_1): Always push the thread_db target.
10689 (try_thread_db_load, record_thread): Pass target down.
10690 (thread_db_target::detach): Pass target down. Always unpush the
10691 thread_db target.
10692 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
10693 target down. Always unpush the thread_db target.
10694 (find_new_threads_callback, thread_db_find_new_threads_2)
10695 (thread_db_target::update_thread_list): Pass target down.
10696 (thread_db_target::pid_to_str): Pass current inferior down.
10697 (thread_db_target::get_thread_local_address): Pass target down.
10698 (thread_db_target::resume, maintenance_check_libthread_db): Pass
10699 target down.
10700 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
10701 * procfs.c (procfs_target::procfs_init_inferior): Declare.
10702 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
10703 (procfs_init_inferior): Rename to ...
10704 (procfs_target::procfs_init_inferior): ... this and adjust.
10705 (procfs_target::create_inferior, procfs_notice_thread)
10706 (procfs_do_thread_registers): Adjust.
10707 * ppc-fbsd-tdep.c: Include "inferior.h".
10708 (ppcfbsd_get_thread_local_address): Pass down target.
10709 * proc-service.c (ps_xfer_memory): Switch current inferior and
10710 program space as well.
10711 (get_ps_regcache): Pass target down.
10712 * process-stratum-target.c
10713 (process_stratum_target::thread_address_space)
10714 (process_stratum_target::thread_architecture): Pass target down.
10715 * process-stratum-target.h
10716 (process_stratum_target::threads_executing): New field.
10717 (as_process_stratum_target): New.
10718 * ravenscar-thread.c
10719 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
10720 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
10721 down.
10722 * record-btrace.c (record_btrace_target::info_record): Adjust.
10723 (record_btrace_target::record_method)
10724 (record_btrace_target::record_is_replaying)
10725 (record_btrace_target::fetch_registers)
10726 (get_thread_current_frame_id, record_btrace_target::resume)
10727 (record_btrace_target::wait, record_btrace_target::stop): Pass
10728 target down.
10729 * record-full.c (record_full_wait_1): Switch to event thread.
10730 Pass target down.
10731 * regcache.c (regcache::regcache)
10732 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
10733 process_stratum_target parameter and handle it.
10734 (current_thread_target): New global.
10735 (get_thread_regcache): Add process_stratum_target parameter and
10736 handle it. Switch inferior before calling target method.
10737 (get_thread_regcache): Pass target down.
10738 (get_thread_regcache_for_ptid): Pass target down.
10739 (registers_changed_ptid): Add process_stratum_target parameter and
10740 handle it.
10741 (registers_changed_thread, registers_changed): Pass target down.
10742 (test_get_thread_arch_aspace_regcache): New.
10743 (current_regcache_test): Define a couple local test_target_ops
10744 instances and use them for testing.
10745 (readwrite_regcache): Pass process_stratum_target parameter.
10746 (cooked_read_test, cooked_write_test): Pass mock_target down.
10747 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
10748 (get_thread_arch_aspace_regcache): Add process_stratum_target
10749 parameter.
10750 (regcache::target): New method.
10751 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
10752 (regcache::registers_changed_ptid): Add process_stratum_target
10753 parameter.
10754 (regcache::m_target): New field.
10755 (registers_changed_ptid): Add process_stratum_target parameter.
10756 * remote.c (remote_state::supports_vCont_probed): New field.
10757 (remote_target::async_wait_fd): New method.
10758 (remote_unpush_and_throw): Add remote_target parameter.
10759 (get_current_remote_target): Adjust.
10760 (remote_target::remote_add_inferior): Push target.
10761 (remote_target::remote_add_thread)
10762 (remote_target::remote_notice_new_inferior)
10763 (get_remote_thread_info): Pass target down.
10764 (remote_target::update_thread_list): Skip threads of inferiors
10765 bound to other targets. (remote_target::close): Don't discard
10766 inferiors. (remote_target::add_current_inferior_and_thread)
10767 (remote_target::process_initial_stop_replies)
10768 (remote_target::start_remote)
10769 (remote_target::remote_serial_quit_handler): Pass down target.
10770 (remote_target::remote_unpush_target): New remote_target
10771 parameter. Unpush the target from all inferiors.
10772 (remote_target::remote_unpush_and_throw): New remote_target
10773 parameter. Pass it down.
10774 (remote_target::open_1): Check whether the current inferior has
10775 execution instead of checking whether any inferior is live. Pass
10776 target down.
10777 (remote_target::remote_detach_1): Pass down target. Use
10778 remote_unpush_target.
10779 (extended_remote_target::attach): Pass down target.
10780 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
10781 (remote_target::append_resumption): Pass down target.
10782 (remote_target::append_pending_thread_resumptions)
10783 (remote_target::remote_resume_with_hc, remote_target::resume)
10784 (remote_target::commit_resume): Pass down target.
10785 (remote_target::remote_stop_ns): Check supports_vCont_probed.
10786 (remote_target::interrupt_query)
10787 (remote_target::remove_new_fork_children)
10788 (remote_target::check_pending_events_prevent_wildcard_vcont)
10789 (remote_target::remote_parse_stop_reply)
10790 (remote_target::process_stop_reply): Pass down target.
10791 (first_remote_resumed_thread): New remote_target parameter. Pass
10792 it down.
10793 (remote_target::wait_as): Pass down target.
10794 (unpush_and_perror): New remote_target parameter. Pass it down.
10795 (remote_target::readchar, remote_target::remote_serial_write)
10796 (remote_target::getpkt_or_notif_sane_1)
10797 (remote_target::kill_new_fork_children, remote_target::kill): Pass
10798 down target.
10799 (remote_target::mourn_inferior): Pass down target. Use
10800 remote_unpush_target.
10801 (remote_target::core_of_thread)
10802 (remote_target::remote_btrace_maybe_reopen): Pass down target.
10803 (remote_target::pid_to_exec_file)
10804 (remote_target::thread_handle_to_thread_info): Pass down target.
10805 (remote_target::async_wait_fd): New.
10806 * riscv-fbsd-tdep.c: Include "inferior.h".
10807 (riscv_fbsd_get_thread_local_address): Pass down target.
10808 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
10809 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
10810 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
10811 Adjust.
10812 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
10813 * solib-svr4.c (enable_break): Pass down target.
10814 * spu-multiarch.c (parse_spufs_run): Pass down target.
10815 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
10816 * target-delegates.c: Regenerate.
10817 * target.c (g_target_stack): Delete.
10818 (current_top_target): Return the current inferior's top target.
10819 (target_has_execution_1): Refer to the passed-in inferior's top
10820 target.
10821 (target_supports_terminal_ours): Check whether the initial
10822 inferior was already created.
10823 (decref_target): New.
10824 (target_stack::push): Incref/decref the target.
10825 (push_target, push_target, unpush_target): Adjust.
10826 (target_stack::unpush): Defref target.
10827 (target_is_pushed): Return bool. Adjust to refer to the current
10828 inferior's target stack.
10829 (dispose_inferior): Delete, and inline parts ...
10830 (target_preopen): ... here. Only dispose of the current inferior.
10831 (target_detach): Hold strong target reference while detaching.
10832 Pass target down.
10833 (target_thread_name): Add assertion.
10834 (target_resume): Pass down target.
10835 (target_ops::beneath, find_target_at): Adjust to refer to the
10836 current inferior's target stack.
10837 (get_dummy_target): New.
10838 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
10839 has a thread running.
10840 (initialize_targets): Rename to ...
10841 (_initialize_target): ... this.
10842 * target.h: Include "gdbsupport/refcounted-object.h".
10843 (struct target_ops): Inherit refcounted_object.
10844 (target_ops::shortname, target_ops::longname): Make const.
10845 (target_ops::async_wait_fd): New method.
10846 (decref_target): Declare.
10847 (struct target_ops_ref_policy): New.
10848 (target_ops_ref): New typedef.
10849 (get_dummy_target): Declare function.
10850 (target_is_pushed): Return bool.
10851 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
10852 (all_matching_threads_iterator::all_matching_threads_iterator):
10853 Handle filter target.
10854 * thread-iter.h (struct all_matching_threads_iterator, struct
10855 all_matching_threads_range, class all_non_exited_threads_range):
10856 Filter by target too. Remove explicit.
10857 * thread.c (threads_executing): Delete.
10858 (inferior_thread): Pass down current inferior.
10859 (clear_thread_inferior_resources): Pass down thread pointer
10860 instead of ptid_t.
10861 (add_thread_silent, add_thread_with_info, add_thread): Add
10862 process_stratum_target parameter. Use it for thread and inferior
10863 searches.
10864 (is_current_thread): New.
10865 (thread_info::deletable): Use it.
10866 (find_thread_ptid, thread_count, in_thread_list)
10867 (thread_change_ptid, set_resumed, set_running): New
10868 process_stratum_target parameter. Pass it down.
10869 (set_executing): New process_stratum_target parameter. Pass it
10870 down. Adjust reference to 'threads_executing'.
10871 (threads_are_executing): New process_stratum_target parameter.
10872 Adjust reference to 'threads_executing'.
10873 (set_stop_requested, finish_thread_state): New
10874 process_stratum_target parameter. Pass it down.
10875 (switch_to_thread): Also match inferior.
10876 (switch_to_thread): New process_stratum_target parameter. Pass it
10877 down.
10878 (update_threads_executing): Reimplement.
10879 * top.c (quit_force): Pop targets from all inferior.
10880 (gdb_init): Don't call initialize_targets.
10881 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
10882 Declare.
10883 (windows_add_thread, windows_delete_thread): Adjust.
10884 (get_windows_debug_event): Rename to ...
10885 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
10886 * tracefile-tfile.c (tfile_target_open): Pass down target.
10887 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
10888 Forward declare.
10889 (switch_to_thread): Add process_stratum_target parameter.
10890 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
10891 parameter. Use it.
10892 (mi_on_resume): Pass target down.
10893 * nat/fork-inferior.c (startup_inferior): Add
10894 process_stratum_target parameter. Pass it down.
10895 * nat/fork-inferior.h (startup_inferior): Add
10896 process_stratum_target parameter.
10897 * python/py-threadevent.c (py_get_event_thread): Pass target down.
10898
10899 2020-01-10 Pedro Alves <palves@redhat.com>
10900
10901 * remote.c (remote_target::start_remote): Don't set inferior_ptid
10902 directly. Instead find the first thread in the thread list and
10903 use switch_to_thread.
10904
10905 2020-01-10 Pedro Alves <palves@redhat.com>
10906
10907 * remote.c (remote_target::remote_add_inferior): Don't bind a
10908 process to the current inferior if the current inferior is already
10909 bound to a process.
10910
10911 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10912 Pedro Alves <palves@redhat.com>
10913
10914 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
10915 If no process is specified, return null_ptid instead of
10916 inferior_ptid.
10917 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
10918 TARGET_WAITKIND_SIGNALLED with no pid.
10919
10920 2020-01-10 Pedro Alves <palves@redhat.com>
10921
10922 * remote.c (first_remote_resumed_thread): New.
10923 (remote_target::wait_as): Use it as default event_ptid instead of
10924 inferior_ptid.
10925
10926 2020-01-10 Pedro Alves <palves@redhat.com>
10927
10928 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
10929
10930 2020-01-10 Pedro Alves <palves@redhat.com>
10931
10932 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
10933 not -1.
10934
10935 2020-01-10 Pedro Alves <palves@redhat.com>
10936
10937 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
10938 ptid to get_last_target_status.
10939 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
10940 ptid to get_last_target_status.
10941 * infcmd.c (continue_command): Don't pass a target_waitstatus to
10942 get_last_target_status.
10943 (info_program_command): Don't pass a target_waitstatus to
10944 get_last_target_status.
10945 * infrun.c (init_wait_for_inferior): Use
10946 nullify_last_target_wait_ptid.
10947 (get_last_target_status): Handle nullptr arguments.
10948 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
10949 (print_stop_event): Don't pass a ptid to get_last_target_status.
10950 (normal_stop): Don't pass a ptid to get_last_target_status.
10951 * infrun.h (get_last_target_status, set_last_target_status): Move
10952 comments here and update.
10953 (nullify_last_target_wait_ptid): Declare.
10954 * linux-fork.c (fork_load_infrun_state): Remove local extern
10955 declaration of nullify_last_target_wait_ptid.
10956 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
10957 to get_last_target_status.
10958
10959 2020-01-10 Pedro Alves <palves@redhat.com>
10960
10961 * gdbthread.h (scoped_restore_current_thread)
10962 <dont_restore, restore, m_dont_restore>: Declare.
10963 * thread.c (thread_alive): Add assertion. Return bool.
10964 (switch_to_thread_if_alive): New.
10965 (prune_threads): Switch inferior/thread.
10966 (print_thread_info_1): Switch thread before calling target methods.
10967 (scoped_restore_current_thread::restore): New, factored out from
10968 ...
10969 (scoped_restore_current_thread::~scoped_restore_current_thread):
10970 ... this.
10971 (scoped_restore_current_thread::scoped_restore_current_thread):
10972 Add assertion.
10973 (thread_apply_all_command, thread_select): Use
10974 switch_to_thread_if_alive.
10975 * infrun.c (proceed, restart_threads, handle_signal_stop)
10976 (switch_back_to_stepped_thread): Switch current thread before
10977 calling target methods.
10978
10979 2020-01-10 Pedro Alves <palves@redhat.com>
10980
10981 * inferior.c (switch_to_inferior_no_thread): New function,
10982 factored out from ...
10983 (inferior_command): ... here.
10984 * inferior.h (switch_to_inferior_no_thread): Declare.
10985 * mi/mi-main.c (run_one_inferior): Use
10986 switch_to_inferior_no_thread.
10987
10988 2020-01-10 Pedro Alves <palves@redhat.com>
10989
10990 * infcmd.c (kill_command): Remove dead code.
10991
10992 2020-01-10 Pedro Alves <palves@redhat.com>
10993
10994 * remote.c (remote_target::mourn_inferior): No longer check
10995 whether the target is running.
10996
10997 2020-01-10 Pedro Alves <palves@redhat.com>
10998
10999 * corelow.c (core_target::has_execution): Change parameter type to
11000 inferior pointer.
11001 * inferior.c (number_of_live_inferiors): Use
11002 inferior::has_execution instead of target_has_execution_1.
11003 * inferior.h (inferior::has_execution): New.
11004 * linux-thread-db.c (thread_db_target::update_thread_list): Use
11005 inferior::has_execution instead of target_has_execution_1.
11006 * process-stratum-target.c
11007 (process_stratum_target::has_execution): Change parameter type to
11008 inferior pointer. Check the inferior's PID instead of
11009 inferior_ptid.
11010 * process-stratum-target.h
11011 (process_stratum_target::has_execution): Change parameter type to
11012 inferior pointer.
11013 * record-full.c (record_full_core_target::has_execution): Change
11014 parameter type to inferior pointer.
11015 * target.c (target_has_execution_1): Change parameter type to
11016 inferior pointer.
11017 (target_has_execution_current): Adjust.
11018 * target.h (target_ops::has_execution): Change parameter type to
11019 inferior pointer.
11020 (target_has_execution_1): Change parameter type to inferior
11021 pointer. Change return type to bool.
11022 * tracefile.h (tracefile_target::has_execution): Change parameter
11023 type to inferior pointer.
11024
11025 2020-01-10 Pedro Alves <palves@redhat.com>
11026
11027 * exceptions.c (print_flush): Remove current_top_target() check.
11028
11029 2020-01-10 Pedro Alves <palves@redhat.com>
11030
11031 * remote.c (show_remote_exec_file): Show the current inferior's
11032 exec-file instead of the command variable's value.
11033
11034 2020-01-10 Pedro Alves <palves@redhat.com>
11035
11036 * record-full.c (record_full_resume_ptid): New global.
11037 (record_full_target::resume): Set it.
11038 (record_full_wait_1): Use record_full_resume_ptid instead of
11039 inferior_ptid.
11040
11041 2020-01-10 Pedro Alves <palves@redhat.com>
11042
11043 * gdbthread.h (scoped_restore_current_thread)
11044 <dont_restore, restore, m_dont_restore>: Declare.
11045 * thread.c (thread_alive): Add assertion. Return bool.
11046 (switch_to_thread_if_alive): New.
11047 (prune_threads): Switch inferior/thread.
11048 (print_thread_info_1): Switch thread before calling target methods.
11049 (scoped_restore_current_thread::restore): New, factored out from
11050 ...
11051 (scoped_restore_current_thread::~scoped_restore_current_thread):
11052 ... this.
11053 (scoped_restore_current_thread::scoped_restore_current_thread):
11054 Add assertion.
11055 (thread_apply_all_command, thread_select): Use
11056 switch_to_thread_if_alive.
11057
11058 2020-01-10 George Barrett <bob@bob131.so>
11059
11060 * stap-probe.c (stap_modify_semaphore): Don't check for null
11061 semaphores.
11062 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
11063 for null semaphores.
11064
11065 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
11066
11067 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
11068 all source windows, and maintain horizontal scroll status while
11069 doing so.
11070
11071 2020-01-09 Tom Tromey <tom@tromey.com>
11072
11073 PR tui/18932:
11074 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
11075 update_source_window, not print_source_lines.
11076
11077 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
11078
11079 * tui/tui.c (tui_enable): Register tui hooks after calling
11080 tui_display_main.
11081
11082 2020-01-09 Christian Biesinger <cbiesinger@google.com>
11083
11084 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
11085
11086 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
11087
11088 * thread.c (print_thread_info_1): Fix indentation.
11089
11090 2020-01-09 Christian Biesinger <cbiesinger@google.com>
11091
11092 * symtab.c (general_symbol_info::compute_and_set_names): Move the
11093 unique_xmalloc_ptr outside the if to always free the demangled name.
11094
11095 2020-01-08 Tom Tromey <tromey@adacore.com>
11096
11097 * xcoffread.c (enter_line_range, read_xcoff_symtab)
11098 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
11099 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
11100 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
11101 Remove.
11102 (section_offsets): New typedef.
11103 * symtab.c (fixup_section, get_msymbol_address): Update.
11104 * symmisc.c (dump_msymbols): Update.
11105 * symfile.h (relative_addr_info_to_section_offsets)
11106 (symfile_map_offsets_to_segments): Update.
11107 * symfile.c (build_section_addr_info_from_objfile)
11108 (init_objfile_sect_indices): Update.
11109 (struct place_section_arg): Change type of "offsets".
11110 (place_section): Update.
11111 (relative_addr_info_to_section_offsets): Change type of
11112 "section_offsets". Remove "num_sections" parameter.
11113 (default_symfile_offsets, syms_from_objfile_1)
11114 (set_objfile_default_section_offset): Update.
11115 (reread_symbols): No need to preserve section offsets by hand.
11116 (symfile_map_offsets_to_segments): Change type of "offsets".
11117 * stap-probe.c (relocate_address): Update.
11118 * stabsread.h (process_one_symbol): Update.
11119 * solib-target.c (struct lm_info_target) <offsets>: Change type.
11120 (solib_target_relocate_section_addresses): Update.
11121 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
11122 Update.
11123 * solib-frv.c (frv_relocate_main_executable): Update.
11124 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
11125 * solib-aix.c (solib_aix_get_section_offsets): Change return
11126 type.
11127 (solib_aix_solib_create_inferior_hook): Update.
11128 * remote.c (remote_target::get_offsets): Update.
11129 * psymtab.c (find_pc_sect_psymtab): Update.
11130 * psympriv.h (struct partial_symbol) <address, text_low,
11131 text_high>: Update.
11132 * objfiles.h (obj_section_offset): Update.
11133 (struct objfile) <section_offsets>: Change type.
11134 <num_sections>: Remove.
11135 (objfile_relocate): Update.
11136 * objfiles.c (entry_point_address_query): Update
11137 (relocate_one_symbol): Change type of "section_offsets".
11138 (objfile_relocate1, objfile_relocate1): Change type of
11139 "new_offsets".
11140 (objfile_rebase1): Update.
11141 * mipsread.c (mipscoff_symfile_read): Update.
11142 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
11143 parameter.
11144 * mdebugread.c (parse_symbol): Change type of "section_offsets".
11145 (parse_external, psymtab_to_symtab_1): Update.
11146 * machoread.c (macho_symfile_offsets): Update.
11147 * ia64-tdep.c (ia64_find_unwind_table): Update.
11148 * hppa-tdep.c (read_unwind_info): Update.
11149 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
11150 * dwarf2read.c (create_addrmap_from_index)
11151 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
11152 (process_psymtab_comp_unit_reader, add_partial_symbol)
11153 (add_partial_subprogram, process_full_comp_unit)
11154 (read_file_scope, read_func_scope, read_lexical_block_scope)
11155 (read_call_site_scope, dwarf2_rnglists_process)
11156 (dwarf2_ranges_process, dwarf2_ranges_read)
11157 (dwarf_decode_lines_1, var_decode_location, new_symbol)
11158 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
11159 Update.
11160 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
11161 Update.
11162 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
11163 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
11164 (process_one_symbol): Change type of "section_offsets".
11165 * ctfread.c (get_objfile_text_range): Update.
11166 * coffread.c (coff_symtab_read, enter_linenos)
11167 (process_coff_symbol): Update.
11168 * coff-pe-read.c (add_pe_forwarded_sym): Update.
11169 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
11170
11171 2020-01-08 Tom Tromey <tromey@adacore.com>
11172
11173 * dwarf2read.c (parse_macro_definition): Use std::string.
11174 (parse_macro_definition): Likewise.
11175
11176 2020-01-08 Tom Tromey <tromey@adacore.com>
11177
11178 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
11179 (ATTR_ALLOC_CHUNK): Remove.
11180
11181 2020-01-08 Tom Tromey <tromey@adacore.com>
11182
11183 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
11184
11185 2020-01-08 Tom Tromey <tromey@adacore.com>
11186
11187 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
11188 (dwarf2_compute_name, open_dwo_file): Likewise.
11189 (process_enumeration_scope): Use std::vector.
11190 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
11191 (partial_die_info::fixup, dwarf2_start_subfile)
11192 (guess_full_die_structure_name, dwarf2_name): Likewise.
11193 (determine_prefix): Update.
11194 (guess_full_die_structure_name): Make return type const.
11195 (partial_die_full_name): Return unique_xmalloc_ptr.
11196 (DW_FIELD_ALLOC_CHUNK): Remove.
11197
11198 2020-01-07 Tom Tromey <tromey@adacore.com>
11199
11200 PR build/24937:
11201 * stap-probe.c (class stap_static_probe_ops): Add constructor.
11202
11203 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
11204
11205 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
11206
11207 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
11208
11209 * stack.c (print_frame_info): Move disassemble_next_line code
11210 inside source_print block.
11211
11212 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11213
11214 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
11215 gdb/signals.h, as we are now using native signal symbols.
11216
11217 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
11218
11219 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
11220 overflow by an early check of content vs threshold.
11221 * tui/tui-source.c (tui_source_window::line_is_displayed):
11222 Likewise.
11223
11224 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11225
11226 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
11227
11228 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
11229
11230 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
11231 export table if no section contains it's RVA.
11232
11233 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11234
11235 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
11236
11237 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
11238
11239 * source.c (print_source_lines_base): Set last_line_listed.
11240
11241 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
11242
11243 * tui/tui-disasm.c: Remove trailing spaces.
11244
11245 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11246 Pedro Alves <palves@redhat.com>
11247
11248 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
11249 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
11250 (windows_gdb_signal_to_target): New function, uses the above
11251 enumeration to convert GDB internal signal codes to equivalent
11252 Windows codes.
11253 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
11254 * windows-nat.c: Include "gdb_wait.h".
11255 (get_windows_debug_event): Extract the fatal exception from the
11256 exit status and convert to the equivalent Posix signal number.
11257 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
11258 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
11259 * gdbsupport/gdb_wait.c: New file, implements
11260 windows_status_to_termsig.
11261 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
11262 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
11263
11264 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
11265
11266 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
11267 show_layout.
11268
11269 2020-01-05 Luis Machado <luis.machado@linaro.org>
11270
11271 * aarch64-linux-nat.c
11272 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
11273 and bfd_mach_aarch64.
11274
11275 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
11276
11277 * ui-file.c (stdio_file::can_emit_style_escape)
11278 (tee_file::can_emit_style_escape): Ensure style is used also on
11279 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
11280 to gdb_stdout.
11281 * main.c (set_gdb_data_directory): Use file style to output the
11282 warning that the given pathname is not a directory.
11283 * top.c (show_history_filename, gdb_safe_append_history)
11284 (show_gdb_datadir): Use file style.
11285
11286 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
11287
11288 * solib-target.c (struct lm_info_target):
11289 Change offsets to be a unique_xmalloc_ptr.
11290 (solib_target_relocate_section_addresses): Update.
11291
11292 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
11293
11294 * windows-nat.c (windows_clear_solib): Free so_list linked list.
11295
11296 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
11297
11298 * MAINTAINERS (Write After Approval): Add myself.
11299
11300 2020-01-02 Luis Machado <luis.machado@linaro.org>
11301
11302 * proc-service.c (get_ps_regcache): Remove reference to obsolete
11303 Cell BE architecture.
11304 * target.h (struct target_ops) <thread_architecture>: Likewise.
11305
11306 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
11307
11308 * Makefile.in: Use INSTALL_PROGRAM_ENV.
11309
11310 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
11311
11312 * MAINTAINERS (Write After Approval): Add myself.
11313
11314 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11315
11316 * gdbarch.sh: Update copyright year range of generated files.
11317
11318 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11319
11320 Update copyright year range in all GDB files.
11321
11322 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11323
11324 * copyright.py: Convert to Python 3.
11325
11326 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11327
11328 * copyright.py: Adapt after move of gnulib directory from gdb
11329 directory to toplevel directory.
11330
11331 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11332
11333 * copyright.py (main): Exit if run from the wrong directory.
11334
11335 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11336
11337 * top.c (print_gdb_version): Change copyright year to 2020.
11338
11339 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11340
11341 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
11342
11343 For older changes see ChangeLog-2019.
11344 \f
11345 Local Variables:
11346 mode: change-log
11347 left-margin: 8
11348 fill-column: 74
11349 version-control: never
11350 coding: utf-8
11351 End: