7d52e228b4649fb3e6a7f2949703f22d8326e3d9
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2
3 * jit.h: Forward-declare `struct objfile`.
4 (jit_event_handler): Add a second parameter, the JITer objfile.
5 * jit.c (jit_read_descriptor): Change the signature to take the
6 JITer objfile as an argument instead of the jit_program_space_data.
7 (jit_inferior_init): Update the call to jit_read_descriptor.
8 (jit_event_handler): Use the new JITer objfile argument when calling
9 jit_read_descriptor.
10 * breakpoint.c (handle_jit_event): Update the call to
11 jit_event_handler to pass the JITer objfile.
12
13 2020-07-21 John Baldwin <jhb@FreeBSD.org>
14
15 * gdbarch.c: Regenerate.
16 * gdbarch.h: Regenerate.
17 * gdbarch.sh (handle_segmentation_fault): Remove method.
18 * infrun.c (handle_segmentation_fault): Remove.
19 (print_signal_received_reason): Remove call to
20 handle_segmentation_fault.
21
22 2020-07-21 John Baldwin <jhb@FreeBSD.org>
23
24 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
25 Rename to sparc64_linux_report_signal_info and add siggnal
26 argument.
27 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
28 instead of sparc64_linux_handle_segmentation_fault.
29
30 2020-07-21 John Baldwin <jhb@FreeBSD.org>
31
32 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
33 i386_linux_report_signal_info instead of
34 i386_linux_handle_segmentation_fault.
35 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
36 to i386_linux_report_signal_info and add siggnal argument.
37 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
38 of i386_linux_handle_segmentation_fault.
39 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
40 to i386_linux_report_signal_info and add siggnal argument.
41
42 2020-07-21 John Baldwin <jhb@FreeBSD.org>
43
44 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
45 hook if present.
46
47 2020-07-21 John Baldwin <jhb@FreeBSD.org>
48
49 * gdbarch.c: Regenerate.
50 * gdbarch.h: Regenerate.
51 * gdbarch.sh (report_signal_info): New method.
52 * infrun.c (print_signal_received_reason): Invoke gdbarch
53 report_signal_info hook if present.
54
55 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
56
57 * python/py-registers.c : Add 'unordered_map' include.
58 (gdbpy_new_reggroup): Renamed to...
59 (gdbpy_get_reggroup): ...this. Update to only create register
60 group descriptors when needed.
61 (gdbpy_reggroup_iter_next): Update.
62
63 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
64
65 * python/py-registers.c (gdbpy_register_object_data): New static
66 global.
67 (gdbpy_register_object_data_init): New function.
68 (gdbpy_new_register_descriptor): Renamed to...
69 (gdbpy_get_register_descriptor): ...this, and update to reuse
70 existing register descriptors where possible.
71 (gdbpy_register_descriptor_iter_next): Update.
72 (gdbpy_initialize_registers): Register new gdbarch data.
73
74 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
75
76 * linux-nat.c (stopped_pids): Make static.
77
78 2020-07-21 Simon Marchi <simon.marchi@polymtl.ca>
79
80 PR ada/26235
81 * gdbtypes.c (ada_discrete_type_low_bound,
82 ada_discrete_type_high_bound): Handle undefined bounds.
83
84 2020-07-21 Kamil Rytarowski <n54@gmx.com>
85
86 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
87 declaration.
88 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
89 function.
90
91 2020-07-20 John Baldwin <jhb@FreeBSD.org>
92
93 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
94 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
95 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
96 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
97 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
98 method.
99
100 2020-07-20 Ludovic Courtès <ludo@gnu.org>
101
102 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
103 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
104 which are deprecated in Guile 3.0.
105 * configure.ac (try_guile_versions): Add "guile-3.0".
106 * configure (try_guile_versions): Regenerate.
107 * NEWS: Update entry.
108
109 2020-07-20 Ludovic Courtès <ludo@gnu.org>
110 Doug Evans <dje@google.com>
111
112 PR gdb/21104
113 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
114 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
115 USING_GUILE_BEFORE_2_2.
116 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
117 Change type to 'scm_t_port_type *'.
118 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
119 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
120 parameter and honor it. Update callers.
121 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
122 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
123 functions.
124 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
125 USING_GUILE_BEFORE_2_2.
126 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
127 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
128 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
129 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
130 and 'SCM_PORT_TYPE'.
131 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
132 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
133 (gdbscm_memory_port_read, gdbscm_memory_port_write)
134 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
135 [!USING_GUILE_BEFORE_2_2]: New functions.
136 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
137 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
138 'gdbscm_memory_port_read'.
139 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
140 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
141 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
142 function.
143 (ioscm_init_memory_port): Remove.
144 (ioscm_init_memory_port_stream): New function
145 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
146 function.
147 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
148 Return scm_from_uint (0).
149 (gdbscm_set_memory_port_read_buffer_size_x)
150 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
151 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
152 Return scm_from_uint (0).
153 (gdbscm_set_memory_port_write_buffer_size_x)
154 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
155 * configure.ac (try_guile_versions): Add "guile-2.2".
156 * configure: Regenerate.
157 * NEWS: Add entry.
158
159 2020-07-18 Tom Tromey <tom@tromey.com>
160
161 * linux-nat.c (linux_multi_process): Remove.
162 (linux_nat_target::supports_multi_process): Return true.
163
164 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
165
166 * arch/riscv.c (riscv_tdesc_cache): Change map type.
167 (riscv_lookup_target_description): Return pointer out of
168 unique_ptr.
169 * target-descriptions.c (allocate_target_description): Add
170 comment.
171 (target_desc_deleter::operator()): Likewise.
172 * target-descriptions.h (struct target_desc_deleter): Moved to
173 gdbsupport/tdesc.h.
174 (target_desc_up): Likewise.
175
176 2020-07-17 Tom Tromey <tromey@adacore.com>
177
178 * linux-nat.c (linux_nat_target::supports_non_stop)
179 (linux_nat_target::always_non_stop_p): Use "true".
180 (linux_nat_target::supports_disable_randomization): Use "true" and
181 "false".
182
183 2020-07-16 Caroline Tice <cmtice@google.com>
184
185 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
186 (RNGLIST_HEADER_SIZE64): New constant definition.
187 (struct dwop_section_names): Add rnglists_dwo.
188 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
189 (struct loclist_header): Rename to 'loclists_rnglists_header'.
190 (struct dwo_sections): Add rnglists field.
191 (read_attribut_reprocess): Add tag parameter.
192 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
193 (cu_debug_rnglists_section): New function (decl & definition).
194 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
195 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
196 die whose range is being checked; get rnglist section from
197 cu_debug_rnglists_section, to get from either objfile or dwo file as
198 appropriate. Add cases for DW_RLE_base_addressx,
199 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
200 the base address to DW_RLE_offset_pairs (not to all ranges), moving
201 test inside if-condition and updating complaint message.
202 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
203 dwarf2_rnglists_process.
204 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
205 dwarf2_ranges_process.
206 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
207 need_ranges_base and update comment appropriately. Also pass die tag
208 to dwarf2_ranges_read.
209 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
210 need_ranges_base and update comment appropriately. Also pass die tag
211 to dwarf2_ranges_process.
212 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
213 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
214 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
215 need_ranges_base and update comment appropriately. Also pass die tag
216 to read_attribute_reprocess and dwarf2_ranges_read.
217 (read_loclist_header): Rename function to read_loclists_rnglists_header,
218 and update function comment appropriately.
219 (read_loclist_index): Call read_loclists_rnglists_header instead of
220 read_loclist_header.
221 (read_rnglist_index): New function.
222 (read_attribute_reprocess): Add tag parameter. Add code for
223 DW_FORM_rnglistx, passing tag to read_rnglist_index.
224 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
225
226 2020-07-15 Andrew Burgess <andrew.burgess@embecosm.com>
227
228 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
229 being resolved.
230
231 2020-07-14 Andrew Burgess <andrew.burgess@embecosm.com>
232
233 * arch-utils.c (show_architecture): Update formatting of messages.
234
235 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
236
237 * gdbtypes.h (struct type) <bounds>: Handle array and string
238 types.
239 * ada-lang.c (assign_aggregate): Use type::bounds on
240 array/string type.
241 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
242 * c-varobj.c (c_number_of_children): Likewise.
243 (c_describe_child): Likewise.
244 * eval.c (evaluate_subexp_for_sizeof): Likewise.
245 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
246 (f_type_print_base): Likewise.
247 * f-valprint.c (f77_array_offset_tbl): Likewise.
248 (f77_get_upperbound): Likewise.
249 (f77_print_array_1): Likewise.
250 * guile/scm-type.c (gdbscm_type_range): Likewise.
251 * m2-typeprint.c (m2_array): Likewise.
252 (m2_is_long_set_of_type): Likewise.
253 * m2-valprint.c (get_long_set_bounds): Likewise.
254 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
255 * python/py-type.c (typy_range): Likewise.
256 * rust-lang.c (rust_internal_print_type): Likewise.
257 * type-stack.c (type_stack::follow_types): Likewise.
258 * valarith.c (value_subscripted_rvalue): Likewise.
259 * valops.c (value_cast): Likewise.
260
261 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
262
263 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
264 callers to use the equivalent accessor methods.
265
266 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
267
268 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
269 (struct type) <bit_stride>: New method.
270 (TYPE_BIT_STRIDE): Remove.
271 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
272
273 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
274
275 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
276 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
277 callers to use the equivalent accessor methods instead.
278
279 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
280
281 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
282 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
283 callers to use the equivalent accessor methods instead.
284
285 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
286
287 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
288 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
289 to use dynamic_prop::kind.
290
291 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
292
293 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
294 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
295 to get the bound property's kind and check against
296 PROP_UNDEFINED.
297
298 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
299
300 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
301 all callers to use type::range_bounds followed by
302 dynamic_prop::{low,high}.
303
304 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
305
306 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
307 const_val, set_const_val, baton, set_locexpr, set_loclist,
308 set_addr_offset, variant_parts, set_variant_parts,
309 original_type, set_original_type>: New methods.
310 <kind>: Rename to...
311 <m_kind>: ... this. Update all users to use the new methods
312 instead.
313 <data>: Rename to...
314 <m_data>: ... this. Update all users to use the new methods
315 instead.
316
317 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
318
319 * gdbtypes.c (get_discrete_bounds): Return failure if
320 the range type's bounds are not both defined and constant
321 values.
322 (get_array_bounds): Update comment. Remove undefined bound check.
323
324 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
325
326 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
327 the type::bounds method directly.
328
329 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
330
331 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
332 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
333 are used to set the range type's bounds to use set_bounds.
334
335 2020-07-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
336
337 * exec.c (_initialize_exec): Update exec-file-mismatch help.
338
339 2020-07-10 Pedro Alves <pedro@palves.net>
340
341 * gdbthread.h (inferior_ref): Define.
342 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
343 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
344 * thread.c
345 (scoped_restore_current_thread::restore):
346 Adjust to gdb::ref_ptr.
347 (scoped_restore_current_thread::~scoped_restore_current_thread):
348 Remove manual decref handling.
349 (scoped_restore_current_thread::scoped_restore_current_thread):
350 Adjust to use
351 inferior_ref::new_reference/thread_info_ref::new_reference.
352 Incref the thread before calling get_frame_id instead of after.
353 Let TARGET_CLOSE_ERROR propagate.
354
355 2020-07-10 Pedro Alves <pedro@palves.net>
356
357 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
358 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
359 NOT_AVAILABLE_ERROR.
360 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
361 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
362
363 2020-07-10 Simon Marchi <simon.marchi@polymtl.ca>
364 Pedro Alves <pedro@palves.net>
365
366 PR gdb/26199
367 * infrun.c (threads_are_resumed_pending_p): Delete.
368 (do_target_wait): Remove threads_are_executing and
369 threads_are_resumed_pending_p checks from the inferior_matches
370 lambda. Update comments.
371
372 2020-07-10 Pedro Alves <pedro@palves.net>
373
374 PR gdb/26199
375 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
376 executing threads.
377
378 2020-07-10 Pedro Alves <pedro@palves.net>
379
380 PR gdb/26199
381 * infrun.c (handle_no_resumed): Handle multiple targets.
382
383 2020-07-10 Pedro Alves <pedro@palves.net>
384
385 PR gdb/26199
386 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
387 target_is_async_p.
388
389 2020-07-10 Pedro Alves <pedro@palves.net>
390
391 PR gdb/26199
392 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
393 threads, not all threads.
394
395 2020-07-10 Pedro Alves <pedro@palves.net>
396
397 PR gdb/26199
398 * remote.c (remote_target::open_1): Pass remote target pointer as
399 data to create_async_event_handler.
400 (remote_async_inferior_event_handler): Mark async event handler
401 before returning if the remote target still has either pending
402 events or unacknowledged notifications.
403
404 2020-07-10 John Baldwin <jhb@FreeBSD.org>
405
406 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
407 declaration.
408 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
409 function.
410
411 2020-07-09 John Baldwin <jhb@FreeBSD.org>
412
413 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
414 inferior_ptid.
415
416 2020-07-09 John Baldwin <jhb@FreeBSD.org>
417
418 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
419 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
420 AT_FREEBSD_PS_STRINGS.
421
422 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
423
424 * auto-load.c (auto_load_objfile_script_1): Convert drive part
425 of debugfile path on Windows.
426
427 2020-07-08 John Baldwin <jhb@FreeBSD.org>
428
429 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
430 argument to 'data'.
431
432 2020-07-08 Tom Tromey <tromey@adacore.com>
433
434 * ada-lang.c (ada_exception_message_1): Use read_memory.
435
436 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
437
438 PR python/22748
439 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
440 special handling for inline frames.
441 * findvar.c (value_of_register_lazy): Skip inline frames when
442 creating lazy register values.
443 * frame.c (frame_id_computed_p): Delete definition.
444 * frame.h (frame_id_computed_p): Delete declaration.
445
446 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
447
448 * NEWS: Mention additions to Python API.
449 * python/py-arch.c (archpy_register_groups): New function.
450 (arch_object_methods): Add 'register_groups' method.
451 * python/py-registers.c (reggroup_iterator_object): New struct.
452 (reggroup_object): New struct.
453 (gdbpy_new_reggroup): New function.
454 (gdbpy_reggroup_to_string): New function.
455 (gdbpy_reggroup_name): New function.
456 (gdbpy_reggroup_iter): New function.
457 (gdbpy_reggroup_iter_next): New function.
458 (gdbpy_new_reggroup_iterator): New function
459 (gdbpy_initialize_registers): Register new types.
460 (reggroup_iterator_object_type): Define new Python type.
461 (gdbpy_reggroup_getset): New static global.
462 (reggroup_object_type): Define new Python type.
463 * python/python-internal.h
464
465 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
466
467 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
468 * python/py-arch.c (archpy_registers): New function.
469 (arch_object_methods): Add 'registers' method.
470 * python/py-registers.c: New file.
471 * python/python-internal.h
472 (gdbpy_new_register_descriptor_iterator): Declare.
473 (gdbpy_initialize_registers): Declare.
474 * python/python.c (do_start_initialization): Call
475 gdbpy_initialize_registers.
476 * NEWS: Mention additions to the Python API.
477
478 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
479
480 * NEWS: Mention new Python API method.
481 * python/py-unwind.c (pending_framepy_architecture): New function.
482 (pending_frame_object_methods): Add architecture method.
483
484 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
485
486 * gdbarch.c: Regenerate.
487 * gdbarch.h: Regenerate.
488 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
489 (gdbarch_data): Use internal_error for the case where
490 deprecated_set_gdbarch_data was originally needed.
491 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
492 and use passed in obstack.
493 (libunwind_frame_set_descr): Should no longer get back NULL from
494 gdbarch_data.
495 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
496 type.
497 * user-regs.c (user_regs_init): Update parameters, and use passed
498 in obstack.
499 (user_reg_add): Should no longer get back NULL from gdbarch_data.
500 (_initialize_user_regs): Register as a pre-init gdbarch data type.
501
502 2020-07-06 Tom de Vries <tdevries@suse.de>
503
504 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
505 End-Of-Sequence in lte_is_less_than.
506 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
507 "gdb: Don't reorder line table entries too much when sorting".
508
509 2020-07-06 Tom de Vries <tdevries@suse.de>
510
511 PR tui/26205
512 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
513
514 2020-07-05 Tom de Vries <tdevries@suse.de>
515
516 PR build/26187
517 * inferior.h (struct infcall_suspend_state_deleter): If available, use
518 std::uncaught_exceptions instead of deprecated
519 std::uncaught_exception.
520
521 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
522
523 * macroexp.h (macro_stringify): Return
524 gdb::unique_xmalloc_ptr<char>.
525 * macroexp.c (macro_stringify): Likewise.
526 * macrotab.c (fixup_definition): Update.
527
528 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
529
530 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
531 (lex_one_token): Update.
532 * macroexp.c (struct macro_buffer) <release>: Return
533 gdb::unique_xmalloc_ptr<char>.
534 (macro_stringify): Update.
535 (macro_expand): Update.
536 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
537 * macroexp.h (macro_expand_next): Likewise.
538
539 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
540
541 * macroexp.h (macro_lookup_ftype): Remove.
542 (macro_expand, macro_expand_once, macro_expand_next): Remove
543 lookup function parameters, add scope parameter.
544 * macroexp.c (scan, substitute_args, expand, maybe_expand,
545 macro_expand, macro_expand_once, macro_expand_next): Likewise.
546 * macroscope.h (standard_macro_lookup): Change parameter type
547 to macro_scope.
548 * macroscope.c (standard_macro_lookup): Likewise.
549 * c-exp.y (lex_one_token): Update.
550 * macrocmd.c (macro_expand_command): Likewise.
551 (macro_expand_once_command): Likewise.
552
553 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
554
555 * inf-loop.c (inferior_event_handler): Remove client_data param.
556 * inf-loop.h (inferior_event_handler): Likewise.
557 * infcmd.c (step_1): Adjust.
558 * infrun.c (proceed): Adjust.
559 (fetch_inferior_event): Remove client_data param.
560 (infrun_async_inferior_event_handler): Adjust.
561 * infrun.h (fetch_inferior_event): Remove `void *` param.
562 * linux-nat.c (handle_target_event): Adjust.
563 * record-btrace.c (record_btrace_handle_async_inferior_event):
564 Adjust.
565 * record-full.c (record_full_async_inferior_event_handler):
566 Adjust.
567 * remote.c (remote_async_inferior_event_handler): Adjust.
568
569 2020-07-01 Tom Tromey <tom@tromey.com>
570
571 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
572 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
573
574 2020-07-01 Tom Tromey <tom@tromey.com>
575
576 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
577 tui_gen_win_info.
578 (tui_win_info::make_window): Merge with
579 tui_gen_win_info::make_window.
580 (tui_win_info::make_visible): Move from tui_gen_win_info.
581 * tui/tui-win.c (tui_win_info::max_width): Move from
582 tui_gen_win_info.
583 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
584 type.
585 <window_factory>: Likewise.
586 * tui/tui-layout.c (tui_win_info::resize): Move from
587 tui_gen_win_info.
588 (make_standard_window): Change return type.
589 (get_locator_window, tui_get_window_by_name): Likewise.
590 (tui_layout_window::apply): Remove a cast.
591 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
592 (struct tui_win_info): Merge with tui_gen_win_info.
593 (struct tui_gen_win_info): Remove.
594
595 2020-07-01 Tom Tromey <tom@tromey.com>
596
597 * tui/tui-stack.h (struct tui_locator_window): Derive from
598 tui_win_info.
599 <do_scroll_horizontal, do_scroll_vertical>: New methods.
600 <can_box>: New method.
601
602 2020-07-01 Tom Tromey <tom@tromey.com>
603
604 * tui/tui-stack.h (struct tui_locator_window): Remove body.
605
606 2020-07-01 Tom Tromey <tom@tromey.com>
607
608 * tui/tui-regs.c (tui_data_window::display_registers_from)
609 (tui_data_window::display_registers_from)
610 (tui_data_window::first_data_item_displayed)
611 (tui_data_window::delete_data_content_windows): Update.
612 (tui_data_window::refresh_window, tui_data_window::no_refresh):
613 Remove.
614 (tui_data_window::check_register_values): Update.
615 (tui_data_item_window::rerender): Add parameters. Update.
616 (tui_data_item_window::refresh_window): Remove.
617 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
618 virtual.
619 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
620 tui_gen_win_info.
621 <refresh_window, max_height, min_height>: Remove.
622 <rerender>: Add parameters.
623 <x, y, visible>: New members.
624 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
625 <m_item_width>: New member.
626
627 2020-07-01 Tom Tromey <tom@tromey.com>
628
629 * tui/tui-regs.c (tui_data_window::show_register_group)
630 (tui_data_window::check_register_values): Update.
631 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
632 from item_no.
633
634 2020-07-01 Tom Tromey <tom@tromey.com>
635
636 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
637 useless "if".
638
639 2020-07-01 Tom Tromey <tom@tromey.com>
640
641 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
642 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
643
644 2020-07-01 Tom Tromey <tom@tromey.com>
645
646 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
647 * tui/tui-winsource.h (enum tui_line_or_address_kind)
648 (struct tui_line_or_address): Move from tui-data.h.
649 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
650 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
651 (tui_cmd_window, tui_source_window_base, tui_source_window)
652 (tui_disasm_window): Don't declare.
653 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
654 to tui-winsource.h.
655 (SINGLE_KEY): Move to tui-stack.c.
656
657 2020-07-01 Tom Tromey <tom@tromey.com>
658
659 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
660 std::string.
661 * tui/tui-regs.c (class tab_expansion_file): New.
662 (tab_expansion_file::write): New method.
663 (tui_register_format): Change return type. Use
664 tab_expansion_file.
665 (tui_get_register, tui_data_window::display_registers_from)
666 (tui_data_item_window::rerender): Update.
667 * tui/tui-io.h (tui_expand_tabs): Don't declare.
668 * tui/tui-io.c (tui_expand_tabs): Remove.
669
670 2020-07-01 Tom Tromey <tom@tromey.com>
671
672 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
673
674 2020-07-01 Fangrui Song <maskray@google.com>
675
676 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
677
678 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
679
680 * dwarf2/read.c (set_die_type): Removed conditions to restrict
681 forms for DW_AT_associated and DW_AT_allocated attributes,
682 which is already checked in function attr_to_dynamic_prop.
683
684 2020-06-30 Tom Tromey <tromey@adacore.com>
685
686 * dwarf2/read.c (quirk_rust_enum): Correctly call
687 alloc_rust_variant for default-less enum.
688
689 2020-06-30 Tom Tromey <tromey@adacore.com>
690
691 PR build/26183:
692 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
693 gdb::to_string.
694
695 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
696
697 * gdbarch.sh (displaced_step_copy_insn): Update doc.
698 * gdbarch.h: Re-generate.
699
700 2020-06-28 Tom Tromey <tom@tromey.com>
701
702 * command.h (cmd_types): Remove.
703 (cmd_type): Don't declare.
704 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
705 typedef.
706 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
707 * cli/cli-decode.c (cmd_type): Remove.
708
709 2020-06-27 Pedro Alves <palves@redhat.com>
710
711 * fork-child.c (prefork_hook): Adjust.
712 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
713 Delete.
714 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
715 * inferior.c (inferior::set_tty, inferior::tty): New methods.
716 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
717 Remove declarations.
718 (struct inferior) <set_tty, tty>: New methods.
719 (struct inferior) <terminal>: Rename to ...
720 (struct inferior) <m_terminal>: ... this and make private.
721 * main.c (captured_main_1): Adjust.
722 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
723 (mi_cmd_inferior_tty_show): Adjust.
724 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
725 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
726
727 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
728
729 * configure.ac: Add --enable-libctf: handle --disable-static
730 properly.
731 * acinclude.m4: sinclude ../config/enable.m4.
732 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
733 (LIBCTF): Substitute in.
734 (CTF_DEPS): New, likewise.
735 (CLIBS): libctf needs symbols from libbfd: move earlier.
736 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
737 flags.
738 * ctfread.c: Surround in ENABLE_LIBCTF.
739 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
740 * configure: Regenerate.
741 * config.in: Likewise.
742
743 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
744
745 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
746
747 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
748
749 * inferior.h (struct inferior) <terminal>: Change type to
750 gdb::unique_xmalloc_ptr<char>.
751 * inferior.c (inferior::~inferior): Don't free inf->terminal.
752 * infcmd.c (set_inferior_io_terminal): Don't free terminal
753 field, adjust to unique pointer.
754 (get_inferior_io_terminal): Adjust to unique pointer.
755
756 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
757
758 * riscv-tdep.c (riscv_print_registers_info): Loop over all
759 registers, not just the known core set of registers.
760
761 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
762
763 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
764 fflags, frm, and fcsr registers.
765 (riscv_register_reggroup_p): Remove unknown CSRs from save and
766 restore groups.
767 (riscv_tdesc_unknown_reg): New function.
768 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
769 tdesc_use_registers.
770 * riscv-tdep.h (struct gdbarch_tdep): Add
771 unknown_csrs_first_regnum, unknown_csrs_count,
772 duplicate_fflags_regnum, duplicate_frm_regnum, and
773 duplicate_fcsr_regnum fields.
774
775 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
776
777 * target-descriptions.c (tdesc_use_registers): Add new parameter a
778 callback, use the callback (when not null) to help number unknown
779 registers.
780 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
781 (tdesc_use_registers): Add extra parameter to declaration.
782
783 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
784
785 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
786 in the file.
787 (class riscv_pending_register_alias): Likewise.
788 (riscv_register_feature::register_info): Change 'required_p' field
789 to 'required', and change its type. Add 'check' member function.
790 (riscv_register_feature::register_info::check): Define new member
791 function.
792 (riscv_xreg_feature): Change initialisation of 'required' field.
793 (riscv_freg_feature): Likewise.
794 (riscv_virtual_feature): Likewise.
795 (riscv_csr_feature): Likewise.
796 (riscv_check_tdesc_feature): Take extra parameter, the csr
797 tdesc_feature, rewrite the function to use the new
798 riscv_register_feature::register_info::check function.
799 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
800
801 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
802
803 * features/Makefile: Remove all references to the deleted files
804 below.
805 * features/riscv/32bit-csr.c: Deleted.
806 * features/riscv/32bit-csr.xml: Deleted.
807 * features/riscv/64bit-csr.c: Deleted.
808 * features/riscv/64bit-csr.xml: Deleted.
809 * features/riscv/rebuild-csr-xml.sh: Deleted.
810
811 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
812
813 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
814 whitespace error for declaration of names member variable.
815 (struct riscv_register_feature): Add new prefer_first_name member
816 variable, and fix whitespace error in declaration of registers.
817 (riscv_xreg_feature): Initialize prefer_first_name field.
818 (riscv_freg_feature): Likewise.
819 (riscv_virtual_feature): Likewise.
820 (riscv_csr_feature): Likewise.
821 (riscv_register_name): Expand on comments. Remove register name
822 modifications for CSR and virtual registers.
823
824 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
825
826 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
827 errors.
828
829 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
830
831 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
832 riscv-opc.h.
833 (class riscv_pending_register_alias): New class.
834 (riscv_check_tdesc_feature): Take vector of pending aliases and
835 populate it as appropriate.
836 (riscv_setup_register_aliases): Delete.
837 (riscv_gdbarch_init): Create vector of pending aliases and pass it
838 to riscv_check_tdesc_feature in all cases. Use the vector to
839 create the register aliases.
840
841 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
842
843 * sol2-tdep.c (sol2_static_transform_name): Remove.
844 (sol2_init_abi): Don't register it.
845 * gdbarch.sh (static_transform_name): Remove.
846 * gdbarch.c, gdbarch.h: Regenerate.
847
848 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
849 gdbarch_static_transform_name.
850 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
851 * stabsread.c (define_symbol) <'X'>: Remove.
852 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
853 handling.
854 <'V'>: Likewise.
855 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
856 <'S'>: Remove call to gdbarch_static_transform_name.
857
858 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
859
860 * procfs.c (procfs_pre_trace): New function.
861 (procfs_target::create_inferior): Pass it to fork_inferior.
862
863 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
864
865 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
866 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
867 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
868 sol2-tdep.o, sparc-sol2-tdep.o.
869 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
870 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
871 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
872 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
873
874 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
875
876 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
877 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
878 Call sol2_init_abi.
879 Remove calls to set_gdbarch_skip_solib_resolver,
880 set_gdbarch_core_pid_to_str.
881 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
882 (i386_sol2_static_transform_name): Remove.
883 (i386_sol2_init_abi): Call sol2_init_abi.
884 Remove calls to set_gdbarch_sofun_address_maybe_missing,
885 set_gdbarch_static_transform_name,
886 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
887 Use sol2_sigtramp_p.
888 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
889 (sol2_sigtramp_p): New function.
890 (sol2_static_transform_name): New function.
891 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
892 (sol2_init_abi): New function.
893 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
894 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
895 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
896 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
897 (sparc_sol2_static_transform_name): Remove.
898 (sparc32_sol2_init_abi): Call sol2_init_abi.
899 Remove calls to set_gdbarch_sofun_address_maybe_missing,
900 set_gdbarch_static_transform_name,
901 set_gdbarch_skip_solib_resolver,
902 set_gdbarch_core_pid_to_str.
903 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
904 (sparc_sol2_static_transform_name): Remove
905 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
906 call sol2_sigtramp_p.
907 (sparc64_sol2_init_abi): Call sol2_init_abi.
908 Remove calls to set_gdbarch_sofun_address_maybe_missing,
909 set_gdbarch_static_transform_name,
910 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
911
912 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
913
914 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
915 * exec.c (validate_exec_file): If from_tty, set both
916 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
917 * symfile.c (symbol_file_add_with_addrs): if always_confirm
918 and from_tty, unconditionally ask a confirmation.
919
920 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
921
922 * target-descriptions.c (tdesc_architecture_name): Protect against
923 NULL pointer dereference.
924 (maint_print_xml_tdesc_cmd): New function.
925 (_initialize_target_descriptions): Register new 'maint print
926 xml-tdesc' command and give it the filename completer.
927 * NEWS: Mention new 'maint print xml-tdesc' command.
928
929 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
930
931 * target-descriptions.c (class tdesc_compatible_info): New class.
932 (struct target_desc): Change type of compatible vector.
933 (tdesc_compatible_p): Update for change in type of
934 target_desc::compatible.
935 (tdesc_compatible_info_list): New function.
936 (tdesc_compatible_info_arch_name): New function.
937 (tdesc_add_compatible): Update for change in type of
938 target_desc::compatible.
939 (print_c_tdesc::visit_pre): Likewise.
940
941 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
942
943 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
944 whitespace to underscore.
945 (maint_print_c_tdesc_cmd): Use fake filename for target
946 descriptions that came from the target.
947 (_initialize_target_descriptions): Add filename command completion
948 for 'maint print c-tdesc'.
949
950 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
951
952 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
953 lines.
954
955 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
956
957 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
958 lines.
959 (dwarf2_find_location_expression): Likewise.
960 (call_site_parameter_matches): Likewise.
961 (dwarf2_compile_expr_to_ax): Likewise.
962 (disassemble_dwarf_expression): Likewise.
963 (loclist_describe_location): Likewise.
964
965 2020-06-23 Pedro Alves <palves@redhat.com>
966
967 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
968 progspace-and-thread.h. Include scoped-mock-context.h instead.
969 (register_to_value_test): Use scoped_mock_context.
970 * regcache.c: Include "scoped-mock-context.h".
971 (cooked_read_test): Don't error out if a target is already pushed.
972 Use scoped_mock_context. Adjust.
973 * scoped-mock-context.h: New file.
974
975 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
976
977 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
978 initializer.
979 (ada_language::is_string_type_p): New member function.
980 * c-lang.c (c_language_data): Delete la_is_string_type_p
981 initializer.
982 (cplus_language_data): Likewise.
983 (asm_language_data): Likewise.
984 (minimal_language_data): Likewise.
985 * d-lang.c (d_language_data): Likewise.
986 * f-lang.c (f_is_string_type_p): Delete function, implementation
987 moved to f_language::is_string_type_p.
988 (f_language_data): Delete la_is_string_type_p initializer.
989 (f_language::is_string_type_p): New member function,
990 implementation from f_is_string_type_p.
991 * go-lang.c (go_is_string_type_p): Delete function, implementation
992 moved to go_language::is_string_type_p.
993 (go_language_data): Delete la_is_string_type_p initializer.
994 (go_language::is_string_type_p): New member function,
995 implementation from go_is_string_type_p.
996 * language.c (language_defn::is_string_type_p): Define new member
997 function.
998 (default_is_string_type_p): Make static, add comment copied from
999 header file.
1000 (unknown_language_data): Delete la_is_string_type_p initializer.
1001 (unknown_language::is_string_type_p): New member function.
1002 (auto_language_data): Delete la_is_string_type_p initializer.
1003 (auto_language::is_string_type_p): New member function.
1004 * language.h (language_data): Delete la_is_string_type_p field.
1005 (language_defn::is_string_type_p): Declare new function.
1006 (default_is_string_type_p): Delete desclaration, move comment to
1007 definition.
1008 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
1009 moved to m2_language::is_string_type_p.
1010 (m2_language_data): Delete la_is_string_type_p initializer.
1011 (m2_language::is_string_type_p): New member function,
1012 implementation from m2_is_string_type_p.
1013 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
1014 initializer.
1015 * opencl-lang.c (opencl_language_data): Likewise.
1016 * p-lang.c (pascal_is_string_type_p): Delete function,
1017 implementation moved to pascal_language::is_string_type_p.
1018 (pascal_language_data): Delete la_is_string_type_p initializer.
1019 (pascal_language::is_string_type_p): New member function,
1020 implementation from pascal_is_string_type_p.
1021 * rust-lang.c (rust_is_string_type_p): Delete function,
1022 implementation moved to rust_language::is_string_type_p.
1023 (rust_language_data): Delete la_is_string_type_p initializer.
1024 (rust_language::is_string_type_p): New member function,
1025 implementation from rust_is_string_type_p.
1026 * valprint.c (val_print_scalar_or_string_type_p): Update call to
1027 is_string_type_p.
1028
1029 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1030
1031 * ada-lang.c (ada_language_data): Delete la_print_typedef
1032 initializer.
1033 (ada_language::print_typedef): New member function.
1034 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
1035 (cplus_language_data): Likewise.
1036 (asm_language_data): Likewise.
1037 (minimal_language_data): Likewise.
1038 * d-lang.c (d_language_data): Likewise.
1039 * f-lang.c (f_language_data): Likewise.
1040 (f_language::print_typedef): New member function.
1041 * go-lang.c (go_language_data): Delete la_print_typedef
1042 initializer.
1043 * language.c (language_defn::print_typedef): Define member
1044 function.
1045 (unknown_language_data): Delete la_print_typedef initializer.
1046 (unknown_language::print_typedef): New member function.
1047 (auto_language_data): Delete la_print_typedef initializer.
1048 (auto_language::print_typedef): New member function.
1049 * language.h (language_data): Delete la_print_typedef field.
1050 (language_defn::print_typedef): Declare new member function.
1051 (LA_PRINT_TYPEDEF): Update call to print_typedef.
1052 (default_print_typedef): Delete declaration.
1053 * m2-lang.c (m2_language_data): Delete la_print_typedef
1054 initializer.
1055 (m2_language::print_typedef): New member function.
1056 * objc-lang.c (objc_language_data): Delete la_print_typedef
1057 initializer.
1058 * opencl-lang.c (opencl_language_data): Likewise.
1059 * p-lang.c (pascal_language_data): Likewise.
1060 (pascal_language::print_typedef): New member function.
1061 * rust-lang.c (rust_print_typedef): Delete function,
1062 implementation moved to rust_language::print_typedef.
1063 (rust_language): Delete la_print_typedef initializer.
1064 (rust_language::print_typedef): New member function,
1065 implementation from rust_print_typedef.
1066 * typeprint.c (default_print_typedef): Delete.
1067
1068 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1069
1070 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
1071 (ada_language::printstr): New member function.
1072 * c-lang.c (c_language_data): Delete la_printstr initializer.
1073 (cplus_language_data): Likewise.
1074 (asm_language_data): Likewise.
1075 (minimal_language_data): Likewise.
1076 * d-lang.c (d_language_data): Likewise.
1077 * f-lang.c (f_printstr): Rename to f_language::printstr.
1078 (f_language_data): Delete la_printstr initializer.
1079 (f_language::printstr): New member function, implementation from
1080 f_printstr.
1081 * go-lang.c (go_language_data): Delete la_printstr initializer.
1082 * language.c (language_defn::printstr): Define new member
1083 function.
1084 (unk_lang_printstr): Delete.
1085 (unknown_language_data): Delete la_printstr initializer.
1086 (unknown_language::printstr): New member function.
1087 (auto_language_data): Delete la_printstr initializer.
1088 (auto_language::printstr): New member function.
1089 * language.h (language_data): Delete la_printstr field.
1090 (language_defn::printstr): Declare new member function.
1091 (LA_PRINT_STRING): Update call to printstr.
1092 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
1093 (m2_language_data): Delete la_printstr initializer.
1094 (m2_language::printstr): New member function, implementation from
1095 m2_printstr.
1096 * objc-lang.c (objc_language_data): Delete la_printstr
1097 initializer.
1098 * opencl-lang.c (opencl_language_data): Likewise.
1099 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
1100 (pascal_language_data): Delete la_printstr initializer.
1101 (pascal_language::printstr): New member function, implementation
1102 from pascal_printstr.
1103 * p-lang.h (pascal_printstr): Delete declaration.
1104 * rust-lang.c (rust_printstr): Update header comment.
1105 (rust_language_data): Delete la_printstr initializer.
1106 (rust_language::printstr): New member function.
1107
1108 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1109
1110 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
1111 (ada_language::printchar): New member function.
1112 * c-lang.c (c_language_data): Delete la_printchar initializer.
1113 (cplus_language_data): Likewise.
1114 (asm_language_data): Likewise.
1115 (minimal_language_data): Likewise.
1116 * d-lang.c (d_language_data): Likewise.
1117 * f-lang.c (f_printchar): Rename to f_language::printchar.
1118 (f_language_data): Delete la_printchar initializer.
1119 (f_language::printchar): New member function, implementation from
1120 f_printchar.
1121 * go-lang.c (go_language_data): Delete la_printchar initializer.
1122 * language.c (unk_lang_printchar): Delete.
1123 (language_defn::printchar): Define new member function.
1124 (unknown_language_data): Delete la_printchar initializer.
1125 (unknown_language::printchar): New member function.
1126 (auto_language_data): Delete la_printchar initializer.
1127 (auto_language::printchar): New member function.
1128 * language.h (language_data): Delete la_printchar field.
1129 (language_defn::printchar): Declare new member function.
1130 (LA_PRINT_CHAR): Update call to printchar.
1131 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
1132 (m2_language::printchar): New member function.
1133 * objc-lang.c (objc_language_data): Delete la_printchar
1134 initializer.
1135 * opencl-lang.c (opencl_language_data): Likewise.
1136 * p-lang.c (pascal_language_data): Delete la_printchar
1137 initializer.
1138 (pascal_language::printchar): New member function.
1139 * rust-lang.c (rust_printchar): Rename to
1140 rust_language::printchar.
1141 (rust_language_data): Delete la_printchar initializer.
1142 (rust_language::printchar): New member function, implementation
1143 from rust_printchar.
1144
1145 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1146
1147 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
1148 (ada_language_data): Delete la_emitchar initializer.
1149 (ada_language::emitchar): New member function, implementation from
1150 emit_char.
1151 * c-lang.c (c_language_data): Delete la_emitchar initializer.
1152 (cplus_language_data): Likewise.
1153 (asm_language_data): Likewise.
1154 (minimal_language_data): Likewise.
1155 * d-lang.c (d_language_data): Likewise.
1156 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
1157 (f_language_data): Delete la_emitchar initializer.
1158 (f_language::emitchar): New member function, implementation from
1159 f_emit_char.
1160 * go-lang.c (go_language_data): Delete la_emitchar initializer.
1161 * language.c (unk_lang_emit_char): Delete.
1162 (language_defn::emitchar): New member function definition.
1163 (unknown_language_data): Delete la_emitchar initializer.
1164 (unknown_language::emitchar): New member function.
1165 (auto_language_data): Delete la_emitchar initializer.
1166 (auto_language::emitchar): New member function.
1167 * language.h (language_data): Delete la_emitchar field.
1168 (language_defn::emitchar): New member field declaration.
1169 (LA_EMIT_CHAR): Update call to emitchar.
1170 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
1171 (m2_language_data): Delete la_emitchar initializer.
1172 (m2_language::emitchar): New member function, implementation from
1173 m2_emit_char.
1174 * objc-lang.c (objc_language_data): Delete la_emitchar
1175 initializer.
1176 * opencl-lang.c (opencl_language_data): Likewise.
1177 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
1178 (pascal_language_data): Delete la_emitchar initializer.
1179 (pascal_language::emitchar): New member function, implementation
1180 from pascal_emit_char.
1181 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
1182 (rust_language_data): Delete la_emitchar initializer.
1183 (rust_language::emitchar): New member function, implementation
1184 from rust_emitchar.
1185
1186 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1187
1188 * ada-lang.c (resolve): Rename to ada_language::post_parser.
1189 (ada_language_data): Delete la_post_parser initializer.
1190 (ada_language::post_parser): New member function.
1191 * c-lang.c (c_language_data): Delete la_post_parser initializer.
1192 (cplus_language_data): Likewise.
1193 (asm_language_data): Likewise.
1194 (minimal_language_data): Likewise.
1195 * d-lang.c (d_language_data): Likewise.
1196 * f-lang.c (f_language_data): Likewise.
1197 * go-lang.c (go_language_data): Likewise.
1198 * language.c (unknown_language_data): Likewise.
1199 (auto_language_data): Likewise.
1200 * language.h (language_data): Delete la_post_parser field.
1201 (language_defn::post_parser): New member function.
1202 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
1203 * objc-lang.c (objc_language_data): Likewise.
1204 * opencl-lang.c (opencl_language_data): Likewise.
1205 * p-lang.c (pascal_language_data): Likewise.
1206 * parse.c (parse_exp_in_context): Update call to post_parser.
1207 (null_post_parser): Delete definition.
1208 * parser-defs.h (null_post_parser): Delete declaration.
1209 * rust-lang.c (rust_language_data): Delete la_post_parser
1210 initializer.
1211
1212 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1213
1214 * ada-lang.c (parse): Rename to ada_language::parser.
1215 (ada_language_data): Delete la_parser initializer.
1216 (ada_language::parser): New member function, implementation from
1217 parse.
1218 * c-lang.c (c_language_data): Delete la_parser initializer.
1219 (cplus_language_data): Likewise.
1220 (asm_language_data): Likewise.
1221 (minimal_language_data): Likewise.
1222 * d-lang.c (d_language_data): Likewise.
1223 (d_language::parser): New member function.
1224 * f-lang.c (f_language_data): Delete la_parser initializer.
1225 (f_language::parser): New member function.
1226 * go-lang.c (go_language_data): Delete la_parser initializer.
1227 (go_language::parser): New member function.
1228 * language.c (unk_lang_parser): Delete.
1229 (language_defn::parser): Define new member function.
1230 (unknown_language_data): Delete la_parser initializer.
1231 (unknown_language::parser): New member function.
1232 (auto_language_data): Delete la_parser initializer.
1233 (auto_language::parser): New member function.
1234 * language.h (language_data): Delete la_parser field.
1235 (language_defn::parser): Declare new member function.
1236 * m2-lang.c (m2_language_data): Delete la_parser initializer.
1237 (m2_language::parser): New member function.
1238 * objc-lang.c (objc_language_data): Delete la_parser initializer.
1239 * opencl-lang.c (opencl_language_data): Likewise.
1240 * p-lang.c (pascal_language_data): Likewise.
1241 (pascal_language::parser): New member function.
1242 * parse.c (parse_exp_in_context): Update call to parser.
1243 * rust-lang.c (rust_language_data): Delete la_parser initializer.
1244 (rust_language::parser): New member function.
1245
1246 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1247
1248 * top.c (print_gdb_configuration): Print --with-python-libdir
1249 configuration value.
1250
1251 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1252
1253 * NEWS: Mention change to the alias command.
1254
1255 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1256
1257 * cli/cli-cmds.c (lookup_cmd_for_default_args)
1258 (alias_command_completer)
1259 (make_alias_options_def_group): New functions.
1260 (alias_opts, alias_option_defs): New struct and array.
1261 (alias_usage_error): Update usage.
1262 (alias_command): Handles optional DEFAULT-ARGS... arguments.
1263 Use option framework.
1264 (_initialize_cli_cmds): Update alias command help.
1265 Update aliases command help.
1266 (show_user):
1267 Add NULL for new default_args lookup_cmd argument.
1268 (valid_command_p): Rename to validate_aliased_command.
1269 Add NULL for new default_args lookup_cmd argument. Verify that the
1270 aliased_command has no default args.
1271 * cli/cli-decode.c (help_cmd): Show aliases definitions.
1272 (lookup_cmd_1, lookup_cmd): New argument default_args.
1273 (add_alias_cmd):
1274 Add NULL for new default_args lookup_cmd argument.
1275 (print_help_for_command): Show default args under the layout
1276 alias some_alias = some_aliased_cmd some_alias_default_arg.
1277 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
1278 xfree default_args in destructor.
1279 * cli/cli-script.c (process_next_line, do_define_command):
1280 Add NULL for new default_args lookup_cmd argument.
1281 * command.h: Declare new default_args argument in lookup_cmd
1282 and lookup_cmd_1.
1283 * completer.c (complete_line_internal_1):
1284 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1285 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
1286 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
1287 Likewise.
1288 * infcmd.c (_initialize_infcmd): Likewise.
1289 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
1290 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
1291 * python/py-param.c (add_setshow_generic): Likewise.
1292 * remote.c (_initialize_remote): Likewise.
1293 * top.c (execute_command): Prepend default_args if command has some.
1294 (set_verbose):
1295 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1296 * tracepoint.c (validate_actionline, encode_actions_1):
1297 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
1298
1299 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1300
1301 * jit.c (jit_read_descriptor): Use bool as the return type.
1302 (jit_breakpoint_re_set_internal): Use bool as the return type.
1303 Invert the return value logic; return true if the jit breakpoint
1304 has been successfully initialized.
1305 (jit_inferior_init): Update the call to
1306 jit_breakpoint_re_set_internal.
1307
1308 2020-06-22 Pedro Alves <palves@redhat.com>
1309
1310 PR gdb/25939
1311 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
1312 Use the current inferior instead. Don't return
1313 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
1314 wait again.
1315 * sol-thread.c (sol_thread_target::wait): Don't reference
1316 inferior_ptid.
1317 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
1318 (sol_update_thread_list_callback): Use the current inferior's pid
1319 instead of inferior_ptid.
1320
1321 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1322
1323 * procfs.c: Cleanup many comments.
1324
1325 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
1326 (AFTER_WATCHFLAG): Replace by value.
1327
1328 (MAIN_PROC_NAME_FORMAT): Inline ...
1329 (create_procinfo): ... here.
1330
1331 (procfs_debug_inferior): Remove SYS_exec handling.
1332 (syscall_is_exec): Likewise.
1333 (procfs_set_exec_trap): Likewise.
1334
1335 (syscall_is_lwp_exit): Inline in callers.
1336 (syscall_is_exit): Likewise.
1337 (syscall_is_exec): Likewise.
1338 (syscall_is_lwp_create): Likewise.
1339
1340 (invalidate_cache): Remove #if 0 code.
1341
1342 (make_signal_thread_runnable): Remove.
1343 (procfs_target::resume): Remove #if 0 code.
1344
1345 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1346
1347 PR gdb/25939
1348 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
1349 call ...
1350 (procfs_target::create_inferior): ... here.
1351
1352 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1353
1354 * exec.c (validate_exec_file): Ensure the build-id is up to
1355 date by calling reopen_exec_file (that checks file timestamp
1356 to decide to re-read the file).
1357
1358 2020-06-18 Pedro Alves <palves@redhat.com>
1359
1360 PR gdb/25412
1361 * gdbthread.h (delete_thread, delete_thread_silent)
1362 (find_thread_ptid): Update comments.
1363 * thread.c (current_thread_): New global.
1364 (is_current_thread): Move higher, and reimplement.
1365 (inferior_thread): Reimplement.
1366 (set_thread_exited): Use bool. Add assertions.
1367 (add_thread_silent): Simplify thread-reuse handling by always
1368 calling delete_thread.
1369 (delete_thread): Remove intro comment.
1370 (find_thread_ptid): Skip exited threads.
1371 (switch_to_thread_no_regs): Write to current_thread_.
1372 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
1373 INFERIOR_PTID. Clear current_thread_.
1374
1375 2020-06-18 Pedro Alves <palves@redhat.com>
1376
1377 * aix-thread.c (pd_update): Use switch_to_thread.
1378
1379 2020-06-18 Pedro Alves <palves@redhat.com>
1380
1381 * ravenscar-thread.c (ravenscar_thread_target): Update.
1382 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
1383 (ravenscar_thread_target::add_active_thread): ... this. Don't
1384 set m_base_ptid here. Update to avoid referencing inferior_ptid.
1385 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
1386
1387 2020-06-18 Pedro Alves <palves@redhat.com>
1388
1389 * nat/windows-nat.c (current_windows_thread): Remove.
1390 * nat/windows-nat.h (current_windows_thread): Remove.
1391 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
1392 Adjust.
1393 (display_selectors): Adjust to fetch the current
1394 windows_thread_info based on inferior_ptid.
1395 (fake_create_process): No longer write to current_windows_thread.
1396 (windows_nat_target::get_windows_debug_event):
1397 Don't set inferior_ptid or current_windows_thread.
1398 (windows_nat_target::wait): Adjust to not rely on
1399 current_windows_thread.
1400 (do_initial_windows_stuff): Now a method of windows_nat_target.
1401 Switch to the last_ptid thread.
1402 (windows_nat_target::attach): Adjust.
1403 (windows_nat_target::detach): Use switch_to_no_thread instead of
1404 writing to inferior_ptid directly.
1405 (windows_nat_target::create_inferior): Adjust.
1406
1407 2020-06-18 Pedro Alves <palves@redhat.com>
1408
1409 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
1410
1411 2020-06-18 Pedro Alves <palves@redhat.com>
1412
1413 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
1414 after creating it, instead of writing to inferior_ptid. Don't
1415 write to inferior_ptid.
1416
1417 2020-06-18 Pedro Alves <palves@redhat.com>
1418
1419 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
1420
1421 2020-06-18 Pedro Alves <palves@redhat.com>
1422
1423 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
1424 it, instead of writing to inferior_ptid.
1425
1426 2020-06-18 Pedro Alves <palves@redhat.com>
1427
1428 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
1429 to inferior_ptid.
1430
1431 2020-06-18 Pedro Alves <palves@redhat.com>
1432
1433 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
1434 instead of writing to inferior_ptid directly.
1435
1436 2020-06-18 Pedro Alves <palves@redhat.com>
1437
1438 * corelow.c (core_target::close): Use switch_to_no_thread instead
1439 of writing to inferior_ptid directly.
1440 (add_to_thread_list, core_target_open): Use switch_to_thread
1441 instead of writing to inferior_ptid directly.
1442
1443 2020-06-18 Pedro Alves <palves@redhat.com>
1444
1445 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
1446 inferior_ptid.
1447 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
1448 inferior_ptid.
1449 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
1450 inferior_ptid directly.
1451 (darwin_nat_target::init_thread_list): Switch to thread, instead
1452 of writing to inferior_ptid.
1453 (darwin_nat_target::attach): Don't write to inferior_ptid.
1454 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
1455
1456 2020-06-18 Pedro Alves <palves@redhat.com>
1457
1458 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
1459 thread.
1460 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
1461 Instead use switch_to_thread.
1462 (gnu_nat_target::detach): Use switch_to_no_thread
1463 instead of writing to inferior_ptid directly. Used passed-in
1464 inferior instead of looking up the inferior by pid.
1465
1466 2020-06-18 Pedro Alves <palves@redhat.com>
1467
1468 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
1469 inferior_ptid.
1470
1471 2020-06-18 Pedro Alves <palves@redhat.com>
1472
1473 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
1474 inferior_ptid.
1475 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
1476 thread.
1477 (nto_procfs_target::detach): Avoid referencing
1478 inferior_ptid. Use switch_to_no_thread instead of writing to
1479 inferior_ptid directly.
1480 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
1481 instead of writing to inferior_ptid directly.
1482 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
1483 to thread.
1484
1485 2020-06-18 Pedro Alves <palves@redhat.com>
1486
1487 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
1488 after creating it, instead of writing to inferior_ptid.
1489 (gdbsim_target_open): Use switch_to_no_thread instead of writing
1490 to inferior_ptid directly.
1491 (gdbsim_target::wait): Don't write to inferior_ptid.
1492
1493 2020-06-18 Pedro Alves <palves@redhat.com>
1494
1495 * remote.c (remote_target::remote_notice_new_inferior): Use
1496 switch_to_thread instead of writing to inferior_ptid directly.
1497 (remote_target::add_current_inferior_and_thread): Use
1498 switch_to_no_thread instead of writing to inferior_ptid directly.
1499 (extended_remote_target::attach): Use switch_to_inferior_no_thread
1500 and switch_to_thread instead of using set_current_inferior or
1501 writing to inferior_ptid directly.
1502
1503 2020-06-18 Pedro Alves <palves@redhat.com>
1504
1505 * tracectf.c (ctf_target_open): Switch to added thread instead of
1506 writing to inferior_ptid directly.
1507 (ctf_target::close): Use switch_to_no_thread instead of writing to
1508 inferior_ptid directly.
1509
1510 2020-06-18 Pedro Alves <palves@redhat.com>
1511
1512 * tracefile-tfile.c (tfile_target_open): Don't write to
1513 inferior_ptid directly, instead switch to added thread.
1514 (tfile_target::close): Use switch_to_no_thread instead of writing
1515 to inferior_ptid directly.
1516
1517 2020-06-18 Pedro Alves <palves@redhat.com>
1518
1519 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
1520 (procfs_target::detach): Use switch_to_no_thread
1521 instead of writing to inferior_ptid directly.
1522 (do_attach): Change return type to void. Switch to the added
1523 thread.
1524 (procfs_target::create_inferior): Switch to the added thread.
1525 (procfs_do_thread_registers): Don't write to inferior_ptid.
1526
1527 2020-06-18 Pedro Alves <palves@redhat.com>
1528
1529 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
1530 of writing to inferior_ptid.
1531 (scoped_restore_exited_inferior): Delete.
1532 (handle_vfork_child_exec_or_exit): Simplify using
1533 scoped_restore_current_pspace_and_thread. Use switch_to_thread
1534 instead of writing to inferior_ptid.
1535 (THREAD_STOPPED_BY): Delete.
1536 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
1537 (thread_stopped_by_hw_breakpoint): Delete.
1538 (save_waitstatus): Use
1539 scoped_restore_current_thread+switch_to_thread, and call
1540 target_stopped_by_watchpoint instead of
1541 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
1542 instead of thread_stopped_by_sw_breakpoint, and
1543 target_stopped_by_hw_breakpoint instead of
1544 thread_stopped_by_hw_breakpoint.
1545 (handle_inferior_event)
1546 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
1547 inferior_ptid directly, nor
1548 set_current_inferior/set_current_program_space. Use
1549 switch_to_thread / switch_to_inferior_no_thread instead.
1550
1551 2020-06-18 Pedro Alves <palves@redhat.com>
1552
1553 * target.c (generic_mourn_inferior): Use switch_to_no_thread
1554 instead of writing to inferior_ptid.
1555
1556 2020-06-18 Pedro Alves <palves@redhat.com>
1557
1558 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
1559 added thread.
1560 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
1561 to the added thread.
1562 (inf_ptrace_target::detach_success): Use switch_to_no_thread
1563 instead of writing to inferior_ptid.
1564
1565 2020-06-18 Pedro Alves <palves@redhat.com>
1566
1567 * gdbarch-selftests.c: Include "progspace-and-thread.h".
1568 (register_to_value_test): Mock a program_space too. Heap-allocate
1569 the address space. Don't write to inferior_ptid. Use
1570 switch_to_thread instead.
1571
1572 2020-06-18 Pedro Alves <palves@redhat.com>
1573
1574 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
1575 Delete.
1576 (find_signalled_thread()): New, factored out from
1577 linux_make_corefile_notes and adjusted to handle exited threads.
1578 (linux_make_corefile_notes): Adjust to use the new
1579 find_signalled_thread.
1580
1581 2020-06-18 Pedro Alves <palves@redhat.com>
1582
1583 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
1584 of saving/restoring inferior_ptid.
1585
1586 2020-06-17 Tom Tromey <tom@tromey.com>
1587
1588 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
1589 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
1590 declare.
1591 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
1592
1593 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
1594
1595 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
1596 of partial symtabs.
1597
1598 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1599
1600 * regformats/reg-arm.dat: Remove.
1601 * regformats/reg-bfin.dat: Remove.
1602 * regformats/reg-cris.dat: Remove.
1603 * regformats/reg-crisv32.dat: Remove.
1604 * regformats/reg-m32r.dat: Remove.
1605 * regformats/reg-tilegx.dat: Remove.
1606 * regformats/reg-tilegx32.dat: Remove.
1607
1608 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1609
1610 * features/Makefile (WHICH): Remove arm files.
1611 * regformats/arm/arm-with-iwmmxt.dat: Remove.
1612 * regformats/arm/arm-with-neon.dat: Remove.
1613 * regformats/arm/arm-with-vfpv2.dat: Remove.
1614 * regformats/arm/arm-with-vfpv3.dat: Remove.
1615
1616 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
1617
1618 * features/Makefile (XMLTOC): Remove rx.xml.
1619
1620 2020-06-17 Pedro Alves <palves@redhat.com>
1621
1622 * gdbthread.h (thread_control_state) <trap_expected> Update
1623 comments.
1624
1625 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1626
1627 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
1628 ada_language::lookup_symbol_nonlocal.
1629 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
1630 (ada_language::lookup_symbol_nonlocal): New member function,
1631 implementation from ada_lookup_symbol_nonlocal.
1632 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
1633 initializer.
1634 (cplus_language_data): Delete la_lookup_symbol_nonlocal
1635 initializer.
1636 (cplus_language::lookup_symbol_nonlocal): New member function.
1637 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
1638 (minimal_language_data) Likewise.
1639 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
1640 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
1641 initializer.
1642 (d_language::lookup_symbol_nonlocal): New member function.
1643 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
1644 initializer.
1645 (f_language::lookup_symbol_nonlocal): New member function.
1646 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
1647 initializer.
1648 * language.c (unknown_language_data): Likewise.
1649 (auto_language_data): Likewise.
1650 * language.h (language_data): Delete la_lookup_symbol_nonlocal
1651 field.
1652 (language_defn::lookup_symbol_nonlocal): New member function.
1653 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
1654 initializer.
1655 * objc-lang.c (objc_language_data): Likewise.
1656 * opencl-lang.c (opencl_language_data): Likewise.
1657 * p-lang.c (pascal_language_data): Likewise.
1658 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
1659 rust_language::lookup_symbol_nonlocal.
1660 (rust_language_data): Delete la_lookup_symbol_nonlocal
1661 initializer.
1662 (rust_language::lookup_symbol_nonlocal): New member function,
1663 implementation from rust_lookup_symbol_nonlocal.
1664 * symtab.c (lookup_symbol_aux): Update call to
1665 lookup_symbol_nonlocal.
1666 (basic_lookup_symbol_nonlocal): Rename to...
1667 (language_defn::lookup_symbol_nonlocal): ...this, and update
1668 header comment. Remove language_defn parameter, and replace with
1669 uses of `this'.
1670 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
1671
1672 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1673
1674 * ada-lang.c (ada_language_data): Delete la_value_print_inner
1675 initializer.
1676 (ada_language::value_print_inner): New member function.
1677 * c-lang.c (c_language_data): Delete la_value_print_inner
1678 initializer.
1679 (cplus_language_data): Likewise.
1680 (asm_language_data): Likewise.
1681 (minimal_language_data): Likewise.
1682 * d-lang.c (d_language_data): Likewise.
1683 (d_language::value_print_inner): New member function.
1684 * f-lang.c (f_language_data): Delete la_value_print_inner
1685 initializer.
1686 (f_language::value_print_inner): New member function.
1687 * f-lang.h (f_value_print_innner): Rename to...
1688 (f_value_print_inner): ...this (note spelling of 'inner').
1689 * f-valprint.c (f_value_print_innner): Rename to...
1690 (f_value_print_inner): ...this (note spelling of 'inner').
1691 * go-lang.c (go_language_data): Delete la_value_print_inner
1692 initializer.
1693 (go_language::value_print_inner): New member function.
1694 * language.c (language_defn::value_print_inner): Define new member
1695 function.
1696 (unk_lang_value_print_inner): Delete.
1697 (unknown_language_data): Delete la_value_print_inner initializer.
1698 (unknown_language::value_print_inner): New member function.
1699 (auto_language_data): Delete la_value_print_inner initializer.
1700 (auto_language::value_print_inner): New member function.
1701 * language.h (language_data): Delete la_value_print_inner field.
1702 (language_defn::value_print_inner): Delcare new member function.
1703 * m2-lang.c (m2_language_data): Delete la_value_print_inner
1704 initializer.
1705 (m2_language::value_print_inner): New member function.
1706 * objc-lang.c (objc_language_data): Delete la_value_print_inner
1707 initializer.
1708 * opencl-lang.c (opencl_language_data): Likewise.
1709 * p-lang.c (pascal_language_data): Likewise.
1710 (pascal_language::value_print_inner): New member function.
1711 * rust-lang.c (rust_language_data): Delete la_value_print_inner
1712 initializer.
1713 (rust_language::value_print_inner): New member function.
1714 * valprint.c (do_val_print): Update call to value_print_inner.
1715
1716 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1717
1718 * ada-lang.c (ada_language_data): Delete la_value_print
1719 initializer.
1720 (ada_language::value_print): New member function.
1721 * c-lang.c (c_language_data): Delete la_value_print initializer.
1722 (cplus_language_data): Likewise.
1723 (asm_language_data): Likewise.
1724 (minimal_language_data): Likewise.
1725 * d-lang.c (d_language_data): Likewise.
1726 * f-lang.c (f_language_data): Likewise.
1727 * go-lang.c (go_language_data): Likewise.
1728 * language.c (unk_lang_value_print): Delete.
1729 (language_defn::value_print): Define new member function.
1730 (unknown_language_data): Delete la_value_print initializer.
1731 (unknown_language::value_print): New member function.
1732 (auto_language_data): Delete la_value_print initializer.
1733 (auto_language::value_print): New member function.
1734 * language.h (language_data): Delete la_value_print field.
1735 (language_defn::value_print): Declare new member function.
1736 (LA_VALUE_PRINT): Update call to value_print.
1737 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
1738 * objc-lang.c (objc_language_data): Likewise.
1739 * opencl-lang.c (opencl_language_data): Likewise.
1740 * p-lang.c (pascal_language_data): Likewise.
1741 (pascal_language::value_print): New member function.
1742 * rust-lang.c (rust_language_data): Delete la_value_print
1743 initializer.
1744
1745 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1746
1747 * ada-lang.c (ada_watch_location_expression): Rename to
1748 ada_language::watch_location_expression.
1749 (ada_language_data): Delete la_watch_location_expression
1750 initializer.
1751 (ada_language::watch_location_expression): New member function,
1752 implementation from ada_watch_location_expression.
1753 * breakpoint.c (watch_command_1): Update call to
1754 watch_location_expression.
1755 * c-lang.c (c_watch_location_expression): Rename to
1756 language_defn::watch_location_expression.
1757 (c_language_data): Delete la_watch_location_expression
1758 initializer.
1759 (cplus_language_data): Likewise.
1760 (asm_language_data): Likewise.
1761 (minimal_language_data): Likewise.
1762 * c-lang.h (c_watch_location_expression): Delete declaration.
1763 * d-lang.c (d_language_data): Delete la_watch_location_expression
1764 initializer.
1765 * f-lang.c (f_language_data): Likewise.
1766 * go-lang.c (go_language_data): Likewise.
1767 * language.c (language_defn::watch_location_expression): Member
1768 function implementation from c_watch_location_expression.
1769 (unknown_language_data): Delete la_watch_location_expression
1770 initializer.
1771 (auto_language_data): Likewise.
1772 * language.h (language_data): Delete la_watch_location_expression
1773 field.
1774 (language_defn::watch_location_expression): Declare new member
1775 function.
1776 * m2-lang.c (m2_language_data): Delete
1777 la_watch_location_expression initializer.
1778 * objc-lang.c (objc_language_data): Likewise.
1779 * opencl-lang.c (opencl_language_data): Likewise.
1780 * p-lang.c (pascal_language_data): Likewise.
1781 * rust-lang.c (rust_watch_location_expression): Rename to
1782 rust_language::watch_location_expression.
1783 (rust_language_data): Delete la_watch_location_expression
1784 initializer.
1785 (rust_language::watch_location_expression): New member function,
1786 implementation from rust_watch_location_expression.
1787
1788 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1789
1790 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
1791 ada_language::collect_symbol_completion_matches.
1792 (ada_language_data): Delete la_collect_symbol_completion_matches
1793 initializer.
1794 (ada_language::collect_symbol_completion_matches): New member
1795 function, implementation from
1796 ada_collect_symbol_completion_matches.
1797 * c-lang.c (c_language_data): Delete
1798 la_collect_symbol_completion_matches initializer.
1799 (cplus_language_data): Likewise.
1800 (asm_language_data): Likewise.
1801 (minimal_language_data): Likewise.
1802 * d-lang.c (d_language_data): Likewise.
1803 * f-lang.c (f_collect_symbol_completion_matches): Rename to
1804 f_language::collect_symbol_completion_matches.
1805 (f_language_data): Delete la_collect_symbol_completion_matches
1806 initializer.
1807 (f_language::collect_symbol_completion_matches) New member
1808 function, implementation from f_collect_symbol_completion_matches.
1809 * go-lang.c (go_language_data): Delete
1810 la_collect_symbol_completion_matches initializer.
1811 * language.c (unknown_language_data): Likewise.
1812 (auto_language_data): Likewise.
1813 * language.h (language_data): Delete
1814 la_collect_symbol_completion_matches field.
1815 (language_defn::collect_symbol_completion_matches): New member
1816 function.
1817 * m2-lang.c (m2_language_data): Delete
1818 la_collect_symbol_completion_matches initializer.
1819 * objc-lang.c (objc_language_data): Likewise.
1820 * opencl-lang.c (opencl_language_data): Likewise.
1821 * p-lang.c (pascal_language_data): Likewise.
1822 * rust-lang.c (rust_language_data): Likewise.
1823 * symtab.c (default_collect_symbol_completion_matches): Delete.
1824 (collect_symbol_completion_matches): Update call to
1825 collect_symbol_completion_matches.
1826 (collect_symbol_completion_matches_type): Likewise.
1827 * symtab.h (default_collect_symbol_completion_matches): Delete
1828 declaration.
1829
1830 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1831
1832 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
1833 (ada_language_data): Delete la_word_break_characters initializer.
1834 (ada_language::word_break_characters): New member function.
1835 * c-lang.c (c_language_data): Delete la_word_break_characters
1836 initializer.
1837 (cplus_language_data): Likewise.
1838 (asm_language_data): Likewise.
1839 (minimal_language_data): Likewise.
1840 * completer.c: Update global comment.
1841 (advance_to_expression_complete_word_point): Update call to
1842 word_break_characters.
1843 (complete_files_symbols): Likewise.
1844 (complete_line_internal_1): Likewise.
1845 (default_completer_handle_brkchars): Likewise.
1846 (skip_quoted_chars): Likewise.
1847 * d-lang.c (d_language_data): Delete la_word_break_characters
1848 initializer.
1849 * f-lang.c (f_word_break_characters): Delete.
1850 (f_language_data): Delete la_word_break_characters initializer.
1851 (f_language::word_break_characters): New member function.
1852 * go-lang.c (go_language_data): Delete la_word_break_characters
1853 initializer.
1854 * language.c (unknown_language_data): Likewise.
1855 (auto_language_data): Likewise.
1856 * language.h (default_word_break_characters): Move declaration to
1857 earlier in the file.
1858 (language_data): Delete la_word_break_characters field.
1859 (language_defn::word_break_characters): New member function.
1860 * m2-lang.c (m2_language_data): Delete la_word_break_characters
1861 initializer.
1862 * objc-lang.c (objc_language_data): Likewise.
1863 * opencl-lang.c (opencl_language_data): Likewise.
1864 * p-lang.c (pascal_language_data): Likewise.
1865 * rust-lang.c (rust_language_data): Likewise.
1866
1867 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1868
1869 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
1870 (ada_language_data): Delete la_get_symbol_name_matcher
1871 initializer.
1872 (language_defn::get_symbol_name_matcher_inner): New member
1873 function.
1874 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
1875 initializer.
1876 (cplus_language_data): Likewise.
1877 (cplus_language::get_symbol_name_matcher_inner): New member
1878 function.
1879 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
1880 (minimal_language_data): Likewise.
1881 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
1882 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
1883 initializer.
1884 * dictionary.c (iter_match_first_hashed): Update call to
1885 get_symbol_name_matcher.
1886 (iter_match_next_hashed): Likewise.
1887 (iter_match_next_linear): Likewise.
1888 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
1889 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
1890 initializer.
1891 (f_language::get_symbol_name_matcher_inner): New member function.
1892 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
1893 initializer.
1894 * language.c (default_symbol_name_matcher): Update header comment,
1895 make static.
1896 (language_defn::get_symbol_name_matcher): New definition.
1897 (language_defn::get_symbol_name_matcher_inner): Likewise.
1898 (get_symbol_name_matcher): Delete.
1899 (unknown_language_data): Delete la_get_symbol_name_matcher
1900 initializer.
1901 (auto_language_data): Likewise.
1902 * language.h (language_data): Delete la_get_symbol_name_matcher
1903 field.
1904 (language_defn::get_symbol_name_matcher): New member function.
1905 (language_defn::get_symbol_name_matcher_inner): Likewise.
1906 (default_symbol_name_matcher): Delete declaration.
1907 * linespec.c (find_methods): Update call to
1908 get_symbol_name_matcher.
1909 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
1910 initializer.
1911 * minsyms.c (lookup_minimal_symbol): Update call to
1912 get_symbol_name_matcher.
1913 (iterate_over_minimal_symbols): Likewise.
1914 * objc-lang.c (objc_language_data): Delete
1915 la_get_symbol_name_matcher initializer.
1916 * opencl-lang.c (opencl_language_data): Likewise.
1917 * p-lang.c (pascal_language_data): Likewise.
1918 * psymtab.c (psymbol_name_matches): Update call to
1919 get_symbol_name_matcher.
1920 * rust-lang.c (rust_language_data): Delete
1921 la_get_symbol_name_matcher initializer.
1922 * symtab.c (symbol_matches_search_name): Update call to
1923 get_symbol_name_matcher.
1924 (compare_symbol_name): Likewise.
1925
1926 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1927
1928 * ada-lang.c (ada_language_data): Delete la_compute_program
1929 initializer.
1930 * c-lang.c (c_language_data): Likewise.
1931 (c_language::compute_program): New member function.
1932 (cplus_language_data): Delete la_compute_program initializer.
1933 (cplus_language::compute_program): New member function.
1934 (asm_language_data): Delete la_compute_program initializer.
1935 (minimal_language_data): Likewise.
1936 * c-lang.h (c_compute_program): Update comment.
1937 (cplus_compute_program): Likewise.
1938 * compile/compile-c-support.c (c_compute_program): Likewise.
1939 (cplus_compute_program): Likewise.
1940 * compile/compile.c (compile_to_object): Update call to
1941 la_compute_program.
1942 * d-lang.c (d_language_data): Delete la_compute_program
1943 initializer.
1944 * f-lang.c (f_language_data): Likewise.
1945 * go-lang.c (go_language_data): Likewise.
1946 * language.c (unknown_language_data): Likewise.
1947 (auto_language_data): Likewise.
1948 * language.h (language_data): Delete la_compute_program field.
1949 (language_defn::compute_program): New member function.
1950 * m2-lang.c (m2_language_data): Delete la_compute_program
1951 initializer.
1952 * objc-lang.c (objc_language_data): Likewise.
1953 * opencl-lang.c (opencl_language_data): Likewise.
1954 * p-lang.c (pascal_language_data): Likewise.
1955 * rust-lang.c (rust_language_data): Likewise.
1956
1957 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
1958
1959 * ada-lang.c (ada_language_data) Delete
1960 la_class_name_from_physname initializer.
1961 * c-lang.c (c_language_data): Likewise.
1962 (cplus_language_data): Likewise.
1963 (cplus_language::class_name_from_physname): New member function.
1964 (asm_language_data): Delete la_class_name_from_physname
1965 initializer.
1966 (minimal_language_data): Likewise.
1967 * d-lang.c (d_language_data): Likewise.
1968 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
1969 method on language_defn class.
1970 (guess_full_die_structure_name): Likewise.
1971 * f-lang.c (f_language_data): Delete la_class_name_from_physname
1972 initializer.
1973 * go-lang.c (go_language_data): Likewise.
1974 * language.c (language_class_name_from_physname): Delete.
1975 (unk_lang_class_name): Delete.
1976 (unknown_language_data): Delete la_class_name_from_physname
1977 initializer.
1978 (auto_language_data): Likewise.
1979 * language.h (language_data): Delete la_class_name_from_physname
1980 field.
1981 (language_defn::class_name_from_physname): New function.
1982 (language_class_name_from_physname): Delete declaration.
1983 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
1984 initializer.
1985 * objc-lang.c (objc_language_data): Likewise.
1986 * opencl-lang.c (opencl_language_data): Likewise.
1987 * p-lang.c (pascal_language_data): Likewise.
1988 * rust-lang.c (rust_language_data): Likewise.
1989
1990 2020-06-16 Tom Tromey <tom@tromey.com>
1991
1992 * tui/tui-data.h (STATUS_NAME): New macro.
1993 * tui/tui-layout.c (tui_remove_some_windows)
1994 (initialize_known_windows, tui_register_window)
1995 (tui_layout_split::remove_windows, initialize_layouts)
1996 (tui_new_layout_command): Don't use hard-coded window names.
1997
1998 2020-06-16 Tom Tromey <tom@tromey.com>
1999
2000 PR tui/25348:
2001 * tui/tui.c (tui_ensure_readline_initialized): Rename from
2002 tui_initialize_readline. Only run once. Call rl_initialize.
2003 * tui/tui.h (tui_ensure_readline_initialized): Rename from
2004 tui_initialize_readline.
2005 * tui/tui-io.c (tui_setup_io): Call
2006 tui_ensure_readline_initialized.
2007 * tui/tui-interp.c (tui_interp::init): Update.
2008
2009 2020-06-16 Tom Tromey <tom@tromey.com>
2010
2011 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
2012 Also preserve the status window.
2013
2014 2020-06-16 Tom Tromey <tom@tromey.com>
2015
2016 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
2017 where m_window==nullptr.
2018
2019 2020-06-15 Tom Tromey <tromey@adacore.com>
2020
2021 * windows-nat.c (windows_nat::handle_output_debug_string):
2022 Update.
2023 (windows_nat::handle_ms_vc_exception): Update.
2024 * target.h (target_read_string): Change API.
2025 * target.c (target_read_string): Change API.
2026 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
2027 Update.
2028 * solib-frv.c (frv_current_sos): Update.
2029 * solib-dsbt.c (dsbt_current_sos): Update.
2030 * solib-darwin.c (darwin_current_sos): Update.
2031 * linux-thread-db.c (inferior_has_bug): Update.
2032 * expprint.c (print_subexp_standard): Update.
2033 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
2034 (ada_exception_message_1): Update.
2035
2036 2020-06-15 Tom Tromey <tromey@adacore.com>
2037
2038 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
2039
2040 2020-06-15 Tom Tromey <tromey@adacore.com>
2041
2042 * valprint.c (read_string): Update comment.
2043 * target.c (MIN): Remove.
2044 (target_read_string): Rewrite.
2045
2046 2020-06-15 Tom Tromey <tromey@adacore.com>
2047
2048 * corefile.c (read_memory_string): Remove.
2049 * ada-valprint.c (ada_value_print_ptr): Update.
2050 * ada-lang.h (ada_tag_name): Change return type.
2051 * ada-lang.c (type_from_tag): Update.
2052 (ada_tag_name_from_tsd): Change return type. Use
2053 target_read_string.
2054 (ada_tag_name): Likewise.
2055 * gdbcore.h (read_memory_string): Don't declare.
2056
2057 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
2058
2059 * symtab.c (rbreak_command): Ignore Windows drive colon.
2060
2061 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
2062
2063 * NEWS: Mention removed GDBserver host support.
2064
2065 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
2066
2067 * features/riscv/rebuild-csr-xml.sh: Updated.
2068
2069 2020-06-11 Tom Tromey <tom@tromey.com>
2070
2071 PR gdb/18318:
2072 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
2073
2074 2020-06-09 Jonny Grant <jg@jguk.org>
2075 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
2076
2077 * main.c (captured_main_1): Don't print new line after help.
2078 (print_gdb_help): add mailing list and IRC channel information
2079 to --help. Add new lines between items in the footer. Remove
2080 quotes around bug url.
2081
2082 2020-06-11 Keith Seitz <keiths@redhat.com>
2083
2084 PR gdb/21356
2085 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
2086 Resolve typedefs for type length calculations.
2087
2088 2020-06-10 Tom de Vries <tdevries@suse.de>
2089
2090 PR ada/24713
2091 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
2092 (write_psymbols): Enable .gdb_index for ada.
2093 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
2094 ada.
2095
2096 2020-06-10 Tom de Vries <tdevries@suse.de>
2097
2098 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
2099 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
2100 namei" instead of "const char *name" argument.
2101 (dw2_map_matching_symbols): Use "offset_type namei" variant of
2102 dw2_symtab_iter_init.
2103
2104 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2105
2106 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
2107 to use type::field and field::type instead.
2108
2109 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2110
2111 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
2112 to use field::type instead.
2113
2114 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2115
2116 * gdbtypes.h (struct field) <type, set_type>: New methods.
2117 Rename `type` field to...
2118 <m_type>: ... this. Change references throughout to use type or
2119 set_type methods.
2120 (FIELD_TYPE): Use field::type. Change call sites that modify
2121 the field's type to use field::set_type instead.
2122
2123 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2124
2125 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
2126 to use type::index_type instead.
2127
2128 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
2129
2130 * gdbtypes.h (struct type) <index_type, set_index_type>: New
2131 methods.
2132 (TYPE_INDEX_TYPE): Use type::index_type.
2133 * gdbtypes.c (create_array_type_with_stride): Likewise.
2134
2135 2020-06-07 Tom Tromey <tom@tromey.com>
2136
2137 * valprint.c (generic_val_print_float): Remove "embedded_offset"
2138 parameter.
2139 (generic_value_print): Update.
2140
2141 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
2142
2143 Revert commit 982a38f60b0.
2144 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
2145
2146 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
2147
2148 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
2149 avoid use after free.
2150
2151 2020-06-05 Tom de Vries <tdevries@suse.de>
2152
2153 * NEWS: Fix typos.
2154
2155 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
2156
2157 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
2158 the per_bfd object.
2159 (dwarf2_read_debug_names): Likewise.
2160 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
2161 object when re-using a per_bfd object with an index.
2162
2163 2020-06-03 Tom de Vries <tdevries@suse.de>
2164
2165 PR symtab/26046
2166 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
2167 children for C++.
2168 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
2169 DW_TAG_subprogram.
2170
2171 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2172
2173 * ada-lang.c (ada_language_data): Delete skip_trampoline
2174 initializer.
2175 * c-lang.c (c_language_data): Likewise.
2176 (cplus_language_data): Likewise.
2177 (cplus_language::skip_trampoline): New member function.
2178 (asm_language_data): Delete skip_trampoline initializer.
2179 (minimal_language_data): Likewise.
2180 * d-lang.c (d_language_data): Likewise.
2181 * f-lang.c (f_language_data): Likewise.
2182 * go-lang.c (go_language_data): Likewise.
2183 * language.c (unk_lang_trampoline): Delete function.
2184 (skip_language_trampoline): Update.
2185 (unknown_language_data): Delete skip_trampoline initializer.
2186 (auto_language_data): Likewise.
2187 * language.h (language_data): Delete skip_trampoline field.
2188 (language_defn::skip_trampoline): New function.
2189 * m2-lang.c (m2_language_data): Delete skip_trampoline
2190 initializer.
2191 * objc-lang.c (objc_skip_trampoline): Delete function, move
2192 implementation to objc_language::skip_trampoline.
2193 (objc_language_data): Delete skip_trampoline initializer.
2194 (objc_language::skip_trampoline): New member function with
2195 implementation from objc_skip_trampoline.
2196 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
2197 initializer.
2198 * p-lang.c (pascal_language_data): Likewise.
2199 * rust-lang.c (rust_language_data): Likewise.
2200
2201 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2202
2203 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
2204 (ada_language::demangle): New member function.
2205 * c-lang.c (c_language_data): Delete la_demangle initializer.
2206 (cplus_language_data): Delete la_demangle initializer.
2207 (cplus_language::demangle): New member function.
2208 (asm_language_data): Delete la_demangle initializer.
2209 (minimal_language_data): Delete la_demangle initializer.
2210 * d-lang.c (d_language_data): Delete la_demangle initializer.
2211 (d_language::demangle): New member function.
2212 * f-lang.c (f_language_data): Delete la_demangle initializer.
2213 (f_language::demangle): New member function.
2214 * go-lang.c (go_language_data): Delete la_demangle initializer.
2215 (go_language::demangle): New member function.
2216 * language.c (language_demangle): Update.
2217 (unk_lang_demangle): Delete.
2218 (unknown_language_data): Delete la_demangle initializer.
2219 (unknown_language::demangle): New member function.
2220 (auto_language_data): Delete la_demangle initializer.
2221 (auto_language::demangle): New member function.
2222 * language.h (language_data): Delete la_demangle field.
2223 (language_defn::demangle): New function.
2224 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
2225 * objc-lang.c (objc_language_data): Delete la_demangle
2226 initializer.
2227 (objc_language::demangle): New member function.
2228 * opencl-lang.c (opencl_language_data): Delete la_demangle
2229 initializer.
2230 * p-lang.c (pascal_language_data): Likewise.
2231 * rust-lang.c (rust_language_data): Likewise.
2232 (rust_language::demangle): New member function.
2233
2234 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2235
2236 * ada-lang.c (ada_language_data): Delete la_print_type
2237 initializer.
2238 (ada_language::print_type): New member function.
2239 * c-lang.c (c_language_data): Delete la_print_type initializer.
2240 (c_language::print_type): New member function.
2241 (cplus_language_data): Delete la_print_type initializer.
2242 (cplus_language::print_type): New member function.
2243 (asm_language_data): Delete la_print_type initializer.
2244 (asm_language::print_type): New member function.
2245 (minimal_language_data): Delete la_print_type initializer.
2246 (minimal_language::print_type): New member function.
2247 * d-lang.c (d_language_data): Delete la_print_type initializer.
2248 (d_language::print_type): New member function.
2249 * f-lang.c (f_language_data): Delete la_print_type initializer.
2250 (f_language::print_type): New member function.
2251 * go-lang.c (go_language_data): Delete la_print_type initializer.
2252 (go_language::print_type): New member function.
2253 * language.c (unk_lang_print_type): Delete.
2254 (unknown_language_data): Delete la_print_type initializer.
2255 (unknown_language::print_type): New member function.
2256 (auto_language_data): Delete la_print_type initializer.
2257 (auto_language::print_type): New member function.
2258 * language.h (language_data): Delete la_print_type field.
2259 (language_defn::print_type): New function.
2260 (LA_PRINT_TYPE): Update.
2261 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
2262 (m2_language::print_type): New member function.
2263 * objc-lang.c (objc_language_data): Delete la_print_type
2264 initializer.
2265 (objc_language::print_type): New member function.
2266 * opencl-lang.c (opencl_print_type): Delete, implementation moved
2267 to opencl_language::print_type.
2268 (opencl_language_data): Delete la_print_type initializer.
2269 (opencl_language::print_type): New member function, implementation
2270 from opencl_print_type.
2271 * p-lang.c (pascal_language_data): Delete la_print_type
2272 initializer.
2273 (pascal_language::print_type): New member function.
2274 * rust-lang.c (rust_print_type): Delete, implementation moved to
2275 rust_language::print_type.
2276 (rust_language_data): Delete la_print_type initializer.
2277 (rust_language::print_type): New member function, implementation
2278 from rust_print_type.
2279
2280 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2281
2282 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
2283 implementation moves to...
2284 (ada_language::sniff_from_mangled_name): ...here. Update return
2285 type.
2286 (ada_language_data): Delete la_sniff_from_mangled_name
2287 initializer.
2288 * c-lang.c (c_language_data): Likewise.
2289 (cplus_language_data): Likewise.
2290 (cplus_language::sniff_from_mangled_name): New member function,
2291 implementation taken from gdb_sniff_from_mangled_name.
2292 (asm_language_data): Delete la_sniff_from_mangled_name
2293 initializer.
2294 (minimal_language_data): Likewise.
2295 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
2296 implementation moves to cplus_language::sniff_from_mangled_name.
2297 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
2298 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
2299 moves to...
2300 (d_language::sniff_from_mangled_name): ...here.
2301 (d_language_data): Delete la_sniff_from_mangled_name initializer.
2302 * f-lang.c (f_language_data): Likewise.
2303 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
2304 moves to...
2305 (go_language::sniff_from_mangled_name): ...here.
2306 (go_language_data): Delete la_sniff_from_mangled_name initializer.
2307 * language.c (language_sniff_from_mangled_name): Delete.
2308 (unknown_language_data): Delete la_sniff_from_mangled_name
2309 initializer.
2310 (auto_language_data): Likewise.
2311 * language.h (language_data): Delete la_sniff_from_mangled_name
2312 field.
2313 (language_defn::sniff_from_mangled_name): New function.
2314 (language_sniff_from_mangled_name): Delete declaration.
2315 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
2316 field.
2317 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
2318 implementation moves to...
2319 (objc_language::sniff_from_mangled_name): ...here.
2320 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
2321 * opencl-lang.c (opencl_language_data): Likewise.
2322 * p-lang.c (pascal_language_data): Likewise.
2323 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
2324 implementation moves to...
2325 (rust_language::sniff_from_mangled_name): ...here.
2326 (rust_language_data): Delete la_sniff_from_mangled_name
2327 initializer.
2328 * symtab.c (symbol_find_demangled_name): Call
2329 sniff_from_mangled_name member function.
2330
2331 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2332
2333 * ada-lang.c (ada_language_data): Delete la_search_name_hash
2334 initializer.
2335 * c-lang.c (c_language_data): Likewise.
2336 (cplus_language_data): Likewise.
2337 (cplus_language::search_name_hash): New member function.
2338 (asm_language_data): Delete la_search_name_hash initializer.
2339 (minimal_language_data): Likewise.
2340 * d-lang.c (d_language_data): Likewise.
2341 * dictionary.c (default_search_name_hash): Rename to...
2342 (language_defn::search_name_hash): ...this.
2343 * f-lang.c (f_language_data): Likewise.
2344 (f_language::search_name_hash): New member function.
2345 * go-lang.c (go_language_data): Delete la_search_name_hash
2346 initializer.
2347 * language.c (unknown_language_data): Likewise.
2348 (auto_language_data): Likewise.
2349 * language.h (struct language_data): Delete la_search_name_hash
2350 field.
2351 (language_defn::search_name_hash): Declare new member function.
2352 (default_search_name_hash): Delete declaration.
2353 * m2-lang.c (m2_language_data): Delete la_search_name_hash
2354 initializer.
2355 * objc-lang.c (objc_language_data): Likewise.
2356 * opencl-lang.c (opencl_language_data): Likewise.
2357 * p-lang.c (pascal_language_data): Likewise.
2358 * rust-lang.c (rust_language_data): Likewise.
2359 * symtab.c (search_name_hash): Update call.
2360
2361 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2362
2363 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
2364 initializer.
2365 * c-lang.c (class compile_instance): Declare.
2366 (c_language_data): Delete la_get_compile_instance initializer.
2367 (c_language::get_compile_instance): New member function.
2368 (cplus_language_data): Delete la_get_compile_instance initializer.
2369 (cplus_language::get_compile_instance): New member function.
2370 (asm_language_data): Delete la_get_compile_instance initializer.
2371 (minimal_language_data): Likewise.
2372 * c-lang.h (c_get_compile_context): Update comment.
2373 (cplus_get_compile_context): Update comment.
2374 * compile/compile.c (compile_to_object): Update calls, don't rely
2375 on function pointer being NULL.
2376 * d-lang.c (d_language_data): Delete la_get_compile_instance
2377 initializer.
2378 * f-lang.c (f_language_data): Likewise.
2379 * go-lang.c (go_language_data): Likewise.
2380 * language.c (unknown_language_data): Likewise.
2381 (auto_language_data): Likewise.
2382 * language.h (language_data): Delete la_get_compile_instance field.
2383 (language_defn::get_compile_instance): New member function.
2384 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
2385 initializer.
2386 * objc-lang.c (objc_language_data): Likewise.
2387 * opencl-lang.c (opencl_language_data): Likewise.
2388 * p-lang.c (pascal_language_data): Likewise.
2389 * rust-lang.c (rust_language_data): Likewise.
2390
2391 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2392
2393 * ada-lang.c (ada_add_all_symbols): Update comment.
2394 (ada_iterate_over_symbols): Delete, move implementation to...
2395 (ada_language::iterate_over_symbols): ...here, a new member
2396 function, rewrite to use range based for loop.
2397 (ada_language_data): Delete la_iterate_over_symbols initializer.
2398 * c-lang.c (c_language_data): Likewise.
2399 (cplus_language_data): Likewise.
2400 (asm_language_data): Likewise.
2401 (minimal_language_data): Likewise.
2402 * d-lang.c (d_language_data): Likewise.
2403 * f-lang.c (f_language_data): Likewise.
2404 * go-lang.c (go_language_data): Likewise.
2405 * language.c (unknown_language_data): Likewise.
2406 (auto_language_data): Likewise.
2407 * language.h (language_data): Delete la_iterate_over_symbols field.
2408 (language_defn::iterate_over_symbols): New member function.
2409 (LA_ITERATE_OVER_SYMBOLS): Update.
2410 * linespec.c (iterate_over_all_matching_symtabs): Update.
2411 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
2412 initializer.
2413 * objc-lang.c (objc_language_data): Likewise.
2414 * opencl-lang.c (opencl_language_data): Likewise.
2415 * p-lang.c (pascal_language_data): Likewise.
2416 * rust-lang.c (rust_language_data): Likewise.
2417
2418 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2419
2420 * ada-lang.c (ada_language_data): Delete
2421 la_lookup_transparent_type initializer.
2422 * c-lang.c (c_language_data): Likewise.
2423 (cplus_language_data): Likewise.
2424 (cplus_language::lookup_transparent_type): New member function.
2425 (asm_language_data): Delete la_lookup_transparent_type
2426 initializer.
2427 (minimal_language_data): Likewise.
2428 * d-lang.c (d_language_data): Likewise.
2429 * f-lang.c (f_language_data): Likewise.
2430 * go-lang.c (go_language_data): Likewise.
2431 * language.c (unknown_language_data): Likewise.
2432 (auto_language_data): Likewise.
2433 * language.h (struct language_data): Delete
2434 la_lookup_transparent_type field.
2435 (language_defn::lookup_transparent_type): New member function.
2436 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
2437 initializer.
2438 * objc-lang.c (objc_language_data): Likewise.
2439 * opencl-lang.c (opencl_language_data): Likewise.
2440 * p-lang.c (pascal_language_data): Likewise.
2441 * rust-lang.c (rust_language_data): Likewise.
2442 * symtab.c (symbol_matches_domain): Update call.
2443
2444 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2445
2446 * ada-lang.c (ada_language_arch_info): Delete function, move
2447 implementation to...
2448 (ada_language::language_arch_info): ...here, a new member
2449 function.
2450 (ada_language_data): Delete la_language_arch_info.
2451 * c-lang.c (c_language_data): Likewise.
2452 (c_language::language_arch_info): New member function.
2453 (cplus_language_arch_info): Delete function, move
2454 implementation to...
2455 (cplus_language::language_arch_info): ...here, a new member
2456 function.
2457 (cplus_language_data): Delete la_language_arch_info.
2458 (asm_language_data): Likewise.
2459 (asm_language::language_arch_info): New member function.
2460 (minimal_language_data): Delete la_language_arch_info.
2461 (minimal_language::language_arch_info): New member function.
2462 * d-lang.c (d_language_arch_info): Delete function, move
2463 implementation to...
2464 (d_language::language_arch_info): ...here, a new member
2465 function.
2466 (d_language_data): Delete la_language_arch_info.
2467 * f-lang.c (f_language_arch_info): Delete function, move
2468 implementation to...
2469 (f_language::language_arch_info): ...here, a new member
2470 function.
2471 (f_language_data): Delete la_language_arch_info.
2472 * go-lang.c (go_language_arch_info): Delete function, move
2473 implementation to...
2474 (go_language::language_arch_info): ...here, a new member
2475 function.
2476 (go_language_data): Delete la_language_arch_info.
2477 * language.c (unknown_language_data): Likewise.
2478 (unknown_language::language_arch_info): New member function.
2479 (auto_language_data): Delete la_language_arch_info.
2480 (auto_language::language_arch_info): New member function.
2481 (language_gdbarch_post_init): Update call to
2482 la_language_arch_info.
2483 * language.h (language_data): Delete la_language_arch_info
2484 function pointer.
2485 (language_defn::language_arch_info): New function.
2486 * m2-lang.c (m2_language_arch_info): Delete function, move
2487 implementation to...
2488 (m2_language::language_arch_info): ...here, a new member
2489 function.
2490 (m2_language_data): Delete la_language_arch_info.
2491 * objc-lang.c (objc_language_arch_info): Delete function, move
2492 implementation to...
2493 (objc_language::language_arch_info): ...here, a new member
2494 function.
2495 (objc_language_data): Delete la_language_arch_info.
2496 * opencl-lang.c (opencl_language_arch_info): Delete function, move
2497 implementation to...
2498 (opencl_language::language_arch_info): ...here, a new member
2499 function.
2500 (opencl_language_data): Delete la_language_arch_info.
2501 * p-lang.c (pascal_language_arch_info): Delete function, move
2502 implementation to...
2503 (pascal_language::language_arch_info): ...here, a new member
2504 function.
2505 (pascal_language_data): Delete la_language_arch_info.
2506 * rust-lang.c (rust_language_arch_info): Delete function, move
2507 implementation to...
2508 (rust_language::language_arch_info): ...here, a new member
2509 function.
2510 (rust_language_data): Delete la_language_arch_info.
2511
2512 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2513
2514 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
2515 initializer.
2516 * c-lang.c (c_language_data): Likewise.
2517 (cplus_language_data): Likewise.
2518 (cplus_language::pass_by_reference_info): New method.
2519 (asm_language_data): Delete la_pass_by_reference initializer.
2520 (minimal_language_data): Likewise.
2521 * cp-abi.c (cp_pass_by_reference): Remove use of
2522 default_pass_by_reference.
2523 * d-lang.c (d_language_data): Likewise.
2524 * f-lang.c (f_language_data): Likewise.
2525 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
2526 default_pass_by_reference.
2527 * go-lang.c (go_language_data): Likewise.
2528 * language.c (language_pass_by_reference): Update.
2529 (default_pass_by_reference): Delete.
2530 (unknown_language_data): Delete la_pass_by_reference
2531 initializer.
2532 (auto_language_data): Likewise.
2533 * language.h (struct language_data): Delete la_pass_by_reference
2534 field.
2535 (language_defn::pass_by_reference_info): New member function.
2536 (default_pass_by_reference): Delete declaration.
2537 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
2538 initializer.
2539 * objc-lang.c (objc_language_data): Likewise.
2540 * opencl-lang.c (opencl_language_data): Likewise.
2541 * p-lang.c (pascal_language_data): Likewise.
2542 * rust-lang.c (rust_language_data): Likewise.
2543
2544 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2545
2546 * ada-lang.c (ada_read_var_value): Delete function, move
2547 implementation to...
2548 (ada_language::read_var_value): ...here.
2549 (ada_language_data): Delete la_read_var_value initializer.
2550 * c-lang.c (c_language_data): Likewise.
2551 (cplus_language_data): Likewise.
2552 (minimal_language_data): Likewise.
2553 * d-lang.c (d_language_data): Likewise.
2554 * f-lang.c (f_language_data): Likewise.
2555 * findvar.c (default_read_var_value): Rename to...
2556 (language_defn::read_var_value): ...this.
2557 * findvar.c (read_var_value): Update header comment, and change to
2558 call member function instead of function pointer.
2559 * go-lang.c (go_language_data): Likewise.
2560 * language.c (unknown_language_data): Delete la_read_var_value
2561 initializer.
2562 (auto_language_data): Likewise.
2563 * language.h (struct language_data): Delete la_read_var_value
2564 field.
2565 (language_defn::read_var_value): New member function.
2566 (default_read_var_value): Delete declaration.
2567 * m2-lang.c (m2_language_data): Delete la_read_var_value
2568 initializer.
2569 * objc-lang.c (objc_language_data): Likewise.
2570 * opencl-lang.c (opencl_language_data): Likewise.
2571 * p-lang.c (pascal_language_data): Likewise.
2572 * rust-lang.c (rust_language_data): Likewise.
2573 * value.h (default_read_var_value): Delete declaration.
2574
2575 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2576
2577 * ada-lang.c (ada_print_array_index): Delete function, move
2578 implementation to...
2579 (ada_language::print_array_index): ...here.
2580 (ada_language_data): Delete la_print_array_index initializer.
2581 * c-lang.c (c_language_data): Likewise.
2582 (cplus_language_data): Likewise.
2583 (minimal_language_data): Likewise.
2584 * d-lang.c (d_language_data): Likewise.
2585 * f-lang.c (f_language_data): Likewise.
2586 * go-lang.c (go_language_data): Likewise.
2587 * language.c (default_print_array_index): Delete function, move
2588 implementation to...
2589 (language_defn::print_array_index): ...here.
2590 (unknown_language_data): Delete la_print_array_index initializer.
2591 (auto_language_data): Likewise.
2592 * language.h (struct language_data): Delete la_print_array_index
2593 field.
2594 (language_defn::print_array_index): New member function.
2595 (LA_PRINT_ARRAY_INDEX): Update.
2596 (default_print_array_index): Delete declaration.
2597 * m2-lang.c (m2_language_data): Delete la_print_array_index
2598 initializer.
2599 * objc-lang.c (objc_language_data): Likewise.
2600 * opencl-lang.c (opencl_language_data): Likewise.
2601 * p-lang.c (pascal_language_data): Likewise.
2602 * rust-lang.c (rust_language_data): Likewise.
2603
2604 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
2605
2606 * gdb/ada-lang.c (ada_language_defn): Convert to...
2607 (ada_language_data): ...this.
2608 (class ada_language): New class.
2609 (ada_language_defn): New static global.
2610 * gdb/c-lang.c (c_language_defn): Convert to...
2611 (c_language_data): ...this.
2612 (class c_language): New class.
2613 (c_language_defn): New static global.
2614 (cplus_language_defn): Convert to...
2615 (cplus_language_data): ...this.
2616 (class cplus_language): New class.
2617 (cplus_language_defn): New static global.
2618 (asm_language_defn): Convert to...
2619 (asm_language_data): ...this.
2620 (class asm_language): New class.
2621 (asm_language_defn): New static global.
2622 (minimal_language_defn): Convert to...
2623 (minimal_language_data): ...this.
2624 (class minimal_language): New class.
2625 (minimal_language_defn): New static global.
2626 * gdb/d-lang.c (d_language_defn): Convert to...
2627 (d_language_data): ...this.
2628 (class d_language): New class.
2629 (d_language_defn): New static global.
2630 * gdb/f-lang.c (f_language_defn): Convert to...
2631 (f_language_data): ...this.
2632 (class f_language): New class.
2633 (f_language_defn): New static global.
2634 * gdb/go-lang.c (go_language_defn): Convert to...
2635 (go_language_data): ...this.
2636 (class go_language): New class.
2637 (go_language_defn): New static global.
2638 * gdb/language.c (unknown_language_defn): Remove declaration.
2639 (current_language): Initialize to nullptr, real initialization is
2640 moved to _initialize_language.
2641 (languages): Delete global.
2642 (language_defn::languages): Define.
2643 (set_language_command): Use language_defn::languages.
2644 (set_language): Likewise.
2645 (range_error): Likewise.
2646 (language_enum): Likewise.
2647 (language_def): Likewise.
2648 (add_set_language_command): Use language_def::languages for the
2649 language list, and language_def to lookup language pointers.
2650 (skip_language_trampoline): Use language_defn::languages.
2651 (unknown_language_defn): Convert to...
2652 (unknown_language_data): ...this.
2653 (class unknown_language): New class.
2654 (unknown_language_defn): New static global.
2655 (auto_language_defn): Convert to...
2656 (auto_language_data): ...this.
2657 (class auto_language): New class.
2658 (auto_language_defn): New static global.
2659 (language_gdbarch_post_init): Use language_defn::languages.
2660 (_initialize_language): Initialize current_language.
2661 * gdb/language.h (struct language_defn): Rename to...
2662 (struct language_data): ...this.
2663 (struct language_defn): New.
2664 (auto_language_defn): Delete.
2665 (unknown_language_defn): Delete.
2666 (minimal_language_defn): Delete.
2667 (ada_language_defn): Delete.
2668 (asm_language_defn): Delete.
2669 (c_language_defn): Delete.
2670 (cplus_language_defn): Delete.
2671 (d_language_defn): Delete.
2672 (f_language_defn): Delete.
2673 (go_language_defn): Delete.
2674 (m2_language_defn): Delete.
2675 (objc_language_defn): Delete.
2676 (opencl_language_defn): Delete.
2677 (pascal_language_defn): Delete.
2678 (rust_language_defn): Delete.
2679 * gdb/m2-lang.c (m2_language_defn): Convert to...
2680 (m2_language_data): ...this.
2681 (class m2_language): New class.
2682 (m2_language_defn): New static global.
2683 * gdb/objc-lang.c (objc_language_defn): Convert to...
2684 (objc_language_data): ...this.
2685 (class objc_language): New class.
2686 (objc_language_defn): New static global.
2687 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
2688 (opencl_language_data): ...this.
2689 (class opencl_language): New class.
2690 (opencl_language_defn): New static global.
2691 * gdb/p-lang.c (pascal_language_defn): Convert to...
2692 (pascal_language_data): ...this.
2693 (class pascal_language): New class.
2694 (pascal_language_defn): New static global.
2695 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
2696 language pointer, update comment format.
2697 * gdb/rust-lang.c (rust_language_defn): Convert to...
2698 (rust_language_data): ...this.
2699 (class rust_language): New class.
2700 (rust_language_defn): New static global.
2701
2702 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
2703
2704 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
2705 member variable.
2706 <m_stmt_at_address>: New member variable.
2707 (lnp_state_machine::record_line): Don't record some lines, update
2708 tracking of is_stmt at the same address.
2709 (lnp_state_machine::lnp_state_machine): Initialise new member
2710 variables.
2711
2712 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
2713
2714 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
2715 "-include gnu-nat-mig.h".
2716 * gnu-nat-mig.h: New file.
2717 * gnu-nat.c: Include "gnu-nat-mig.h".
2718 (exc_server, msg_reply_server, notify_server,
2719 process_reply_server): Remove declarations.
2720
2721 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2722
2723 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
2724 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
2725 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
2726 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
2727 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
2728 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
2729 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
2730 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
2731 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
2732 to gnu_nat_target class.
2733 * gnu-nat.c: Likewise.
2734 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
2735 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
2736 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
2737 object.
2738 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
2739 instead of `gnu_target'.
2740
2741 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2742
2743 * i386-gnu-tdep.c: Include "gdbcore.h"
2744 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
2745 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
2746 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
2747 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
2748 i386_gnu_sigcontext_addr): New functions
2749 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
2750 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
2751 tdep.
2752
2753 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2754
2755 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
2756 before fork_inferior call. Avoid calling it if target_is_pushed returns
2757 true.
2758
2759 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2760
2761 * gnu-nat.h (gnu_target): New variable declaration.
2762 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
2763 gnu_target.
2764 * gnu-nat.c (gnu_target): New variable.
2765 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
2766 add_thread_silent, and add_thread calls.
2767 (gnu_nat_target::create_inferior): Pass gnu_target to
2768 add_thread_silent, thread_change_ptid call.
2769 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
2770 call.
2771
2772 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2773
2774 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
2775 (gnu_nat_target::find_memory_regions): Remove unused
2776 `old_address' variable.
2777
2778 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2779
2780 * gnu-nat.c: Include "gdbarch.h".
2781
2782 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2783
2784 * reply_mig_hack.awk (Error return): Cast function through
2785 void *, to bypass compiler function call check.
2786
2787 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2788
2789 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
2790 $(srcdir)/reply_mig_hack.awk.
2791
2792 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
2793
2794 * gnu-nat.h (gnu_debug_flag): Set type to bool.
2795
2796 2020-05-30 Jonny Grant <jg@jguk.org>
2797
2798 * configure.ac (ACX_BUGURL): change bug URL to https.
2799
2800 2020-05-30 Pedro Alves <palves@redhat.com>
2801
2802 * cp-support.c (replace_typedefs_template): New.
2803 (replace_typedefs_qualified_name): Handle
2804 DEMANGLE_COMPONENT_TEMPLATE.
2805
2806 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
2807
2808 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
2809 dwarf2/index-cache.h, dwarf2/index-write.c,
2810 dwarf2/index-write.h, dwarf2/line-header.c,
2811 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
2812 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
2813 variables and fields from `dwarf2_per_objfile` to just
2814 `per_objfile` throughout.
2815
2816 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
2817
2818 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2819 <push_dwarf_reg_entry_value>: Add comment.
2820
2821 2020-05-28 Kevin Buettner <kevinb@redhat.com>
2822 Keith Seitz <keiths@redhat.com>
2823
2824 * python/python.c (do_start_initialization): Call PyEval_SaveThread
2825 instead of PyEval_ReleaseLock.
2826 (class gdbpy_gil): Move to earlier in file.
2827 (finalize_python): Set gdb_python_initialized.
2828 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
2829 when not initialized.
2830
2831 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
2832
2833 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
2834 <push_dwarf_reg_entry_value>: Remove assert. Override
2835 per_objfile with caller_per_objfile.
2836
2837 2020-05-28 Tom de Vries <tdevries@suse.de>
2838
2839 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
2840 PR gold/15646 workaround to symbol kind "type".
2841
2842 2020-05-27 Tom Tromey <tromey@adacore.com>
2843
2844 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
2845
2846 2020-05-27 Tom Tromey <tromey@adacore.com>
2847
2848 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
2849 Use htab_find_with_hash.
2850 <add_abbrev>: Remove "abbrev_number" parameter.
2851 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
2852 "abbrev_number" parameter. Use htab_find_slot_with_hash.
2853 (hash_abbrev): Add comment.
2854 (abbrev_table::lookup_abbrev): Move to header file.
2855 (abbrev_table::read): Update.
2856
2857 2020-05-27 Tom Tromey <tromey@adacore.com>
2858
2859 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
2860 method.
2861 <canonical_name>: New member.
2862 <raw_name>: Rename from "name".
2863 (partial_die_info): Initialize canonical_name.
2864 (scan_partial_symbols): Check raw_name.
2865 (partial_die_parent_scope, partial_die_full_name)
2866 (add_partial_symbol, add_partial_subprogram)
2867 (add_partial_enumeration, load_partial_dies): Use "name" method.
2868 (partial_die_info::name): New method.
2869 (partial_die_info::read, guess_partial_die_structure_name)
2870 (partial_die_info::fixup): Update.
2871
2872 2020-05-27 Tom Tromey <tromey@adacore.com>
2873
2874 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
2875 <get_ref_die_offset>: Inline.
2876 <get_ref_die_offset_complaint>: New method.
2877 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
2878 (attribute::get_ref_die_offset_complaint): Rename from
2879 get_ref_die_offset. Just issue complaint.
2880
2881 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2882
2883 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
2884
2885 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2886
2887 * exec.c (exec_file_attach): Use errno value of first openp failure.
2888
2889 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
2890
2891 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
2892 Don't close thread handle.
2893
2894 2020-05-27 Tom Tromey <tom@tromey.com>
2895 Simon Marchi <simon.marchi@efficios.com>
2896
2897 * objfiles.h (struct objfile) <partial_symtabs>: Now a
2898 shared_ptr.
2899 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
2900 member.
2901 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
2902 dwarf2_per_bfd_objfile_data_key>: New globals.
2903 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
2904 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
2905 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
2906 shared.
2907 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
2908 short-circuit when sharing.
2909 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
2910 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
2911
2912 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2913
2914 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
2915 to...
2916 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
2917 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
2918
2919 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2920
2921 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
2922 build_name_components, find_name_components_bounds>:
2923 Add per_objfile parameter.
2924 (struct mapped_index) <symbol_name_at>: Likewise.
2925 (struct mapped_debug_names): Remove constructor.
2926 <dwarf2_per_objfile>: Remove field.
2927 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
2928 (mapped_index_base::find_name_components_bounds,
2929 mapped_index_base::build_name_components,
2930 dw2_expand_symtabs_matching_symbol): Likewise.
2931 (class mock_mapped_index) <symbol_name_at>: Likewise.
2932 (check_match): Likewise.
2933 (check_find_bounds_finds): Likewise.
2934 (test_mapped_index_find_name_component_bounds): Update.
2935 (CHECK_MATCH): Update.
2936 (dw2_expand_symtabs_matching): Update.
2937 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
2938 per_objfile parameter.
2939 <find_vec_in_debug_names>: Likewise.
2940 <m_per_objfile>: New field.
2941 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
2942 parameter.
2943 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
2944 (dw2_debug_names_iterator::next): Update.
2945 (dw2_debug_names_lookup_symbol): Update.
2946 (dw2_debug_names_expand_symtabs_for_function): Update.
2947 (dw2_debug_names_map_matching_symbols): Update.
2948 (dw2_debug_names_expand_symtabs_matching): Update.
2949 (dwarf2_read_debug_names): Update.
2950
2951 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
2952
2953 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
2954 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
2955 move to dwarf2_per_objfile.
2956 <read_in_chain>: Remove.
2957 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
2958 remove_all_cus, age_comp_units>: New methods.
2959 <m_dwarf2_cus>: New member.
2960 (struct dwarf2_per_cu_data) <cu>: Remove.
2961 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
2962 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
2963 moved to methods of dwarf2_per_objfile.
2964 (dwarf2_clear_marks): Remove.
2965 (dwarf2_queue_item::~dwarf2_queue_item): Update.
2966 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
2967 (dwarf2_per_bfd::free_cached_comp_units): Remove.
2968 (dwarf2_per_objfile::remove_all_cus): New.
2969 (class free_cached_comp_units) <~free_cached_comp_units>:
2970 Update.
2971 (load_cu): Update.
2972 (dw2_do_instantiate_symtab): Adjust.
2973 (fill_in_sig_entry_from_dwo_entry): Adjust.
2974 (cutu_reader::init_tu_and_read_dwo_dies): Update.
2975 (cutu_reader::cutu_reader): Likewise.
2976 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
2977 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
2978 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
2979 and dwarf2_per_objfile::age_comp_units.
2980 (load_partial_comp_unit): Update.
2981 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
2982 (process_queue): Likewise.
2983 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
2984 backlink.
2985 (dwarf2_read_addr_index): Likewise.
2986 (follow_die_offset): Likewise.
2987 (dwarf2_fetch_die_loc_sect_off): Likewise.
2988 (dwarf2_fetch_constant_bytes): Likewise.
2989 (dwarf2_fetch_die_type_sect_off): Likewise.
2990 (follow_die_sig_1): Likewise.
2991 (load_full_type_unit): Likewise.
2992 (read_signatured_type): Likewise.
2993 (dwarf2_cu::dwarf2_cu): Don't set cu field.
2994 (dwarf2_cu::~dwarf2_cu): Remove.
2995 (dwarf2_per_objfile::get_cu): New.
2996 (dwarf2_per_objfile::set_cu): New.
2997 (age_cached_comp_units): Rename to...
2998 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
2999 to std::unordered_map.
3000 (free_one_cached_comp_unit): Rename to...
3001 (dwarf2_per_objfile::remove_cu): ... this. Adjust
3002 to std::unordered_map.
3003 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
3004 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
3005 a dwarf2_per_objfile in data.
3006 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
3007 (dwarf2_clear_marks): Remove.
3008
3009 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3010
3011 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
3012 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
3013 (init_tu_and_read_dwo_dies): Likewise.
3014 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
3015 (cutu_reader::cutu_reader): Likewise.
3016 (load_partial_comp_unit): Likewise.
3017 (process_psymtab_comp_unit): Update.
3018 (build_type_psymtabs_1): Update.
3019 (process_skeletonless_type_unit): Update.
3020 (load_full_comp_unit): Update.
3021 (find_partial_die): Update.
3022 (dwarf2_read_addr_index): Update.
3023 (read_signatured_type): Update.
3024
3025 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3026
3027 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
3028 m_header_read_in>: New fields.
3029 <get_header>: New method.
3030 * dwarf2/read.c (per_cu_header_read_in): Remove.
3031 (dwarf2_per_cu_data::get_header): New.
3032 (dwarf2_per_cu_data::addr_size): Update.
3033 (dwarf2_per_cu_data::offset_size): Update.
3034 (dwarf2_per_cu_data::ref_addr_size): Update.
3035
3036 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3037
3038 * dwarf2/read.c (load_cu): Return dwarf2_cu.
3039 (dw2_do_instantiate_symtab): Update.
3040 (queue_and_load_all_dwo_tus): Change parameter from
3041 dwarf2_per_cu_data to dwarf2_cu.
3042 (dwarf2_fetch_die_loc_sect_off): Update.
3043 (dwarf2_fetch_constant_bytes): Update.
3044 (dwarf2_fetch_die_type_sect_off): Update.
3045
3046 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3047
3048 * dwarf2/read.c (process_full_comp_unit,
3049 process_full_type_unit): Remove per_cu, per_objfile paramters.
3050 Add dwarf2_cu parameter.
3051 (process_queue): Update.
3052
3053 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3054
3055 * dwarf2/read.c (create_cu_from_index_list): Replace
3056 dwarf2_per_objfile parameter with dwarf2_per_bfd.
3057 (create_cus_from_index_list): Likewise.
3058 (create_cus_from_index): Likewise.
3059 (create_signatured_type_table_from_index): Likewise.
3060 (create_cus_from_debug_names_list): Likewise.
3061 (create_cus_from_debug_names): Likewise.
3062 (dwarf2_read_gdb_index): Update.
3063 (dwarf2_read_debug_names): Update.
3064
3065 2020-05-27 Tom Tromey <tom@tromey.com>
3066 Simon Marchi <simon.marchi@efficios.com>
3067
3068 * dwarf2/read.h (struct dwarf2_per_objfile)
3069 <get_type_for_signatured_type, set_type_for_signatured_type>:
3070 New methods.
3071 <m_type_map>: New member.
3072 (struct signatured_type) <type>: Remove.
3073 * dwarf2/read.c
3074 (dwarf2_per_objfile::get_type_for_signatured_type,
3075 dwarf2_per_objfile::set_type_for_signatured_type): New.
3076 (get_signatured_type): Use new methods.
3077
3078 2020-05-27 Tom Tromey <tom@tromey.com>
3079 Simon Marchi <simon.marchi@efficios.com>
3080
3081 * dwarf2/read.h (struct type_unit_group_unshareable): New.
3082 (struct dwarf2_per_objfile) <type_units>: New member.
3083 <get_type_unit_group_unshareable>: New method.
3084 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
3085 num_symtabs, symtabs>: Remove; move to
3086 type_unit_group_unshareable.
3087 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
3088 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
3089 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
3090
3091 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3092
3093 * dwarf2/read.h (struct dwarf2_per_cu_data):
3094 <dwarf2_per_objfile>: Remove.
3095 * dwarf2/read.c (create_cu_from_index_list): Don't assign
3096 dwarf2_per_objfile.
3097 (create_signatured_type_table_from_index): Likewise.
3098 (create_signatured_type_table_from_debug_names): Likewise.
3099 (create_debug_type_hash_table): Likewise.
3100 (fill_in_sig_entry_from_dwo_entry): Likewise.
3101 (create_type_unit_group): Likewise.
3102 (read_comp_units_from_section): Likewise.
3103 (create_cus_hash_table): Likewise.
3104
3105 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3106
3107 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
3108 dwarf2_per_cu_data::dwarf2_per_objfile.
3109 (compute_compunit_symtab_includes): Likewise.
3110 (dwarf2_cu::start_symtab): Likewise.
3111
3112 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3113
3114 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
3115 parameter.
3116 * dwarf2/read.c (get_die_type_at_offset): Likewise.
3117 (read_namespace_alias): Update.
3118 (lookup_die_type): Update.
3119 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
3120 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
3121 Update.
3122 (disassemble_dwarf_expression): Update.
3123
3124 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3125
3126 * dwarf2/read.h (struct dwarf2_queue_item): Add
3127 dwarf2_per_objfile parameter, assign new parameter.
3128 <per_objfile>: New field.
3129 * dwarf2/read.c (free_one_cached_comp_unit): Add
3130 dwarf2_per_objfile parameter.
3131 (queue_comp_unit): Likewise.
3132 (dw2_do_instantiate_symtab): Update.
3133 (process_psymtab_comp_unit): Update.
3134 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
3135 (process_imported_unit_die): Update.
3136 (queue_and_load_dwo_tu): Update.
3137 (follow_die_offset): Update.
3138 (follow_die_sig_1): Update.
3139
3140 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3141
3142 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
3143 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
3144 (read_call_site_scope): Assign per_objfile.
3145 (dwarf2_per_cu_data::objfile): Remove.
3146 * gdbtypes.h (struct call_site) <per_objfile>: New member.
3147 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
3148 dwarf2_per_objfile parameter.
3149 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
3150 dwarf2_per_objfile parameter.
3151 (dwarf_expr_reg_to_entry_parameter): Add output
3152 dwarf2_per_objfile parameter.
3153 (locexpr_get_frame_base): Update.
3154 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
3155 <push_dwarf_reg_entry_value>: Update.
3156 <call_site_to_target_addr>: Update.
3157 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
3158 parameter.
3159 (value_of_dwarf_reg_entry): Update.
3160 (rw_pieced_value): Update.
3161 (indirect_synthetic_pointer): Update.
3162 (dwarf2_evaluate_property): Update.
3163 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
3164 parameter.
3165 (locexpr_read_variable): Update.
3166 (locexpr_get_symbol_read_needs): Update.
3167 (loclist_read_variable): Update.
3168
3169 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3170
3171 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
3172 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
3173 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
3174 parameter.
3175 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
3176 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
3177 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
3178 parameter.
3179 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
3180 sect_variable_value): Add dwarf2_per_objfile parameter.
3181 (class dwarf_evaluate_loc_desc) <dwarf_call,
3182 dwarf_variable_value>: Update.
3183 (fetch_const_value_from_synthetic_pointer): Add
3184 dwarf2_per_objfile parameter.
3185 (fetch_const_value_from_synthetic_pointer): Update.
3186 (coerced_pieced_ref): Update.
3187 (class symbol_needs_eval_context) <dwarf_call,
3188 dwarf_variable_value>: Update.
3189 (dwarf2_compile_expr_to_ax): Update.
3190
3191 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3192
3193 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
3194 parameter.
3195 (dwarf2_evaluate_loc_desc_full): Update.
3196
3197 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3198
3199 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
3200 parameter.
3201 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
3202 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
3203 dwarf2_per_objfile parameter.
3204 (decode_debug_loc_dwo_addresses): Likewise.
3205 (dwarf2_find_location_expression): Update.
3206 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
3207 (locexpr_describe_location_piece): Add dwarf2_per_objfile
3208 parameter.
3209 (disassemble_dwarf_expression): Add dwarf2_per_objfile
3210 parameter.
3211 (locexpr_describe_location_1): Likewise.
3212 (locexpr_describe_location): Update.
3213
3214 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3215
3216 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
3217 Remove.
3218 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
3219 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
3220 (dwarf2_compile_property_to_c): Update.
3221 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
3222 use text offset from objfile.
3223 (locexpr_tracepoint_var_ref): Update.
3224 (locexpr_generate_c_location): Update.
3225 (loclist_describe_location): Update.
3226 (loclist_tracepoint_var_ref): Update.
3227 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
3228 dwarf2_per_objfile parameter.
3229 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
3230 use text offset from objfile.
3231 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
3232
3233 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3234
3235 * dwarf2/expr.h (struct dwarf_expr_context)
3236 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
3237 <offset>: Remove.
3238 <per_objfile>: New member.
3239 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
3240 dwarf2_per_objfile parameter. Don't set offset, set
3241 per_objfile.
3242 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
3243 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
3244 a dwarf2_per_objfile object instead of an offset.
3245 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
3246 constructor.
3247 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
3248 to dwarf2_expr_executor constructor. Don't set offset.
3249 (dwarf2_fetch_cfa_info): Update.
3250 (struct dwarf2_frame_cache) <text_offset>: Remove.
3251 <per_objfile>: New field.
3252 (dwarf2_frame_cache): Update.
3253 (dwarf2_frame_prev_register): Update.
3254 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3255 <dwarf_evaluate_loc_desc>: Add constructor.
3256 (dwarf2_evaluate_loc_desc_full): Update.
3257 (dwarf2_locexpr_baton_eval): Update.
3258 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
3259 Add constructor.
3260 (dwarf2_loc_desc_get_symbol_read_needs): Update.
3261
3262 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3263
3264 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
3265 addr_sized_int_type>: Move to dwarf2_cu.
3266 <int_type>: Move to dwarf2_per_objfile.
3267 (struct dwarf2_per_objfile) <int_type>: Move here.
3268 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
3269 addr_sized_int_type>: Move here.
3270 (read_func_scope): Update.
3271 (read_array_type): Update.
3272 (read_tag_string_type): Update.
3273 (attr_to_dynamic_prop): Update.
3274 (dwarf2_per_cu_data::int_type): Rename to...
3275 (dwarf2_per_objfile::int_type): ... this.
3276 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
3277 (dwarf2_cu::addr_sized_int_type): ... this.
3278 (read_subrange_type): Update.
3279 (dwarf2_per_cu_data::addr_type): Rename to...
3280 (dwarf2_cu::addr_type): ... this.
3281 (set_die_type): Update.
3282
3283 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3284
3285 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
3286 data through per_cu->cu.
3287
3288 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3289
3290 * dwarf2/read.c (lookup_dwo_comp_unit): Change
3291 dwarf2_per_cu_data parameter fo dwarf2_cu.
3292 (lookup_dwo_type_unit): Likewise.
3293 (read_cutu_die_from_dwo): Likewise.
3294 (lookup_dwo_unit): Likewise.
3295 (open_and_init_dwo_file): Likewise.
3296 (lookup_dwo_cutu): Likewise.
3297 (lookup_dwo_comp_unit): Likewise.
3298 (lookup_dwo_type_unit): Likewise.
3299 (cutu_reader::init_tu_and_read_dwo_dies): Update.
3300 (cutu_reader::cutu_reader): Update.
3301
3302 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3303
3304 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
3305 parameter.
3306 (process_full_type_unit): Likewise.
3307 (process_queue): Update.
3308
3309 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3310
3311 * dwarf2/read.c (recursively_compute_inclusions): Add
3312 dwarf2_per_objfile parameter.
3313 (compute_compunit_symtab_includes): Likewise.
3314 (process_cu_includes): Update.
3315
3316 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3317
3318 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
3319 parameter.
3320 (create_type_unit_group): Update.
3321 (process_psymtab_comp_unit_reader): Update.
3322 (build_type_psymtabs_reader): Update.
3323
3324 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3325
3326 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
3327 object through m_this_cu->cu.
3328
3329 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3330
3331 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
3332 the info parameter.
3333 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
3334
3335 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3336
3337 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
3338 per_objfile parameter.
3339 (load_full_type_unit): Add per_objfile parameter.
3340 (read_signatured_type): Likewise.
3341 (load_full_comp_unit): Likewise.
3342 (load_cu): Likewise.
3343 (dw2_do_instantiate_symtab): Likewise.
3344 (dw2_get_file_names): Likewise.
3345 (dw2_map_symtabs_matching_filename): Update.
3346 (dw_expand_symtabs_matching_file_matcher): Update.
3347 (dw2_map_symbol_filenames): Update.
3348 (process_psymtab_comp_unit): Add per_objfile parameter.
3349 (build_type_psymtabs_1): Update.
3350 (process_skeletonless_type_unit): Update.
3351 (dwarf2_build_psymtabs_hard): Update.
3352 (load_partial_comp_unit): Add per_objfile parameter.
3353 (scan_partial_symbols): Update.
3354 (load_full_comp_unit): Add per_objfile parameter.
3355 (process_imported_unit_die): Update.
3356 (create_cus_hash_table): Update.
3357 (find_partial_die): Update.
3358 (dwarf2_read_addr_index): Update.
3359 (follow_die_offset): Update.
3360 (dwarf2_fetch_die_loc_sect_off): Update.
3361 (dwarf2_fetch_constant_bytes): Update.
3362 (dwarf2_fetch_die_type_sect_off): Update.
3363 (follow_die_sig_1): Update.
3364 (load_full_type_unit): Add per_objfile parameter.
3365 (read_signatured_type): Likewise.
3366
3367 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3368
3369 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
3370 of objfile_name.
3371
3372 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3373
3374 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
3375 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
3376 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
3377 field.
3378 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
3379 (create_cus_from_index): Update.
3380 (dwarf2_read_gdb_index): Update.
3381 (create_cus_from_debug_names): Update.
3382 (dwarf2_read_debug_names): Update.
3383 (get_abbrev_section_for_cu): Update.
3384 (create_all_comp_units): Update.
3385 (read_attribute_value): Update.
3386 (get_debug_line_section): Update.
3387 * dwarf2/index-cache.c (index_cache::store): Update.
3388 * dwarf2/index-write.c (save_gdb_index_command): Update.
3389 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
3390
3391 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3392
3393 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
3394 member.
3395 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
3396 dwarf2_per_cu_data::per_bfd.
3397 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
3398 (create_type_unit_group): Likewise.
3399 (queue_comp_unit): Remove reference to
3400 per_cu->dwarf2_per_objfile.
3401 (maybe_queue_comp_unit): Likewise.
3402 (fill_in_sig_entry_from_dwo_entry): Assign new field.
3403 (create_cus_hash_table): Assign new field.
3404
3405 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3406
3407 * dwarf2/read.c: Replace
3408 dwarf2_cu->per_cu->dwarf2_per_objfile references with
3409 dwarf2_cu->per_objfile throughout.
3410
3411 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3412
3413 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
3414 parameter, don't use per_cu->dwarf2_per_objfile.
3415 (dw2_instantiate_symtab): Likewise.
3416 (dw2_find_last_source_symtab): Update.
3417 (dw2_map_expand_apply): Update.
3418 (dw2_lookup_symbol): Update.
3419 (dw2_expand_symtabs_for_function): Update.
3420 (dw2_expand_all_symtabs): Update.
3421 (dw2_expand_symtabs_with_fullname): Update.
3422 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
3423 don't use per_cu->dwarf2_per_objfile.
3424 (dw2_expand_marked_cus): Update.
3425 (dw2_find_pc_sect_compunit_symtab): Update.
3426 (dw2_debug_names_lookup_symbol): Update.
3427 (dw2_debug_names_expand_symtabs_for_function): Update.
3428 (dw2_debug_names_map_matching_symbols): Update.
3429 (dwarf2_psymtab::expand_psymtab): Update.
3430
3431 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3432
3433 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
3434 <per_objfile>: New member.
3435 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
3436 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
3437 call to dwarf2_cu.
3438 (cutu_reader::cutu_reader): Update.
3439 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
3440
3441 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3442
3443 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
3444 struct dwarf2_per_objfile.
3445 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
3446 dwarf2_per_bfd.
3447 * dwarf2/read.c (set_die_type): Update.
3448 (get_die_type_at_offset): Update.
3449
3450 2020-05-27 Tom Tromey <tom@tromey.com>
3451 Simon Marchi <simon.marchi@efficios.com>
3452
3453 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
3454 method.
3455 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
3456 get_symtab, set_symtab>: New methods.
3457 <m_symtabs>: New field.
3458 (struct dwarf2_psymtab): Derive from partial_symtab.
3459 <readin_p, get_compunit_symtab>: Declare methods.
3460 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
3461 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
3462 New methods.
3463 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
3464 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
3465 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
3466 (dw2_symtab_iter_next, dw2_print_stats)
3467 (dw2_expand_symtabs_with_fullname)
3468 (dw2_expand_symtabs_matching_one)
3469 (dw_expand_symtabs_matching_file_matcher)
3470 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
3471 (dw2_debug_names_iterator::next)
3472 (dw2_debug_names_map_matching_symbols)
3473 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
3474 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
3475 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
3476 New methods.
3477 (get_compunit_symtab, process_full_comp_unit)
3478 (process_full_type_unit): Update.
3479 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
3480
3481 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
3482
3483 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
3484 then introduce a new dwarf2_per_objfile type.
3485 <read_line_string>: Move to the new dwarf2_per_objfile type.
3486 <objfile>: Likewise.
3487 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
3488 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
3489 dwarf2_per_objfile->per_bfd.
3490 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
3491 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
3492 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
3493 (dwarf2_per_bfd::free_cached_comp_units): ... this.
3494 (dwarf2_has_info): Allocate dwarf2_per_bfd.
3495 (dwarf2_per_objfile::locate_sections): Rename to...
3496 (dwarf2_per_bfd::locate_sections): ... this.
3497 (dwarf2_per_objfile::get_cutu): Rename to...
3498 (dwarf2_per_bfd::get_cutu): ... this.
3499 (dwarf2_per_objfile::get_cu): Rename to...
3500 (dwarf2_per_bfd::get_cu): ... this.
3501 (dwarf2_per_objfile::get_tu): Rename to...
3502 (dwarf2_per_bfd::get_tu): ... this.
3503 (dwarf2_per_objfile::allocate_per_cu): Rename to...
3504 (dwarf2_per_bfd::allocate_per_cu): ... this.
3505 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
3506 (dwarf2_per_bfd::allocate_signatured_type): ... this.
3507 (get_gdb_index_contents_ftype): Change parameter from
3508 dwarf2_per_objfile to dwarf2_per_bfd.
3509 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
3510 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
3511
3512 2020-05-27 Tom Tromey <tom@tromey.com>
3513 Simon Marchi <simon.marchi@efficios.com>
3514
3515 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
3516 (allocate_piece_closure): Set "per_objfile" member.
3517 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
3518 (locexpr_describe_location, loclist_describe_location): Use new
3519 member.
3520 * dwarf2/read.c (read_call_site_scope)
3521 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
3522 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
3523 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
3524 handle_data_member_location): Set per_objfile member.
3525 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
3526 member.
3527 (struct dwarf2_loclist_baton) <per_objfile>: New member.
3528
3529 2020-05-27 Tom Tromey <tom@tromey.com>
3530
3531 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
3532 allocate_signatured_type>: Declare new methods.
3533 <m_num_psymtabs>: New member.
3534 (struct dwarf2_per_cu_data) <index>: New member.
3535 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
3536 (dwarf2_per_objfile::allocate_signatured_type): New methods.
3537 (create_cu_from_index_list): Use allocate_per_cu.
3538 (create_signatured_type_table_from_index)
3539 (create_signatured_type_table_from_debug_names)
3540 (create_debug_type_hash_table, add_type_unit)
3541 (read_comp_units_from_section): Use allocate_signatured_type.
3542
3543 2020-05-27 Tom Tromey <tom@tromey.com>
3544
3545 * psymtab.c (partial_map_expand_apply)
3546 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
3547 (psym_lookup_global_symbol_language)
3548 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
3549 (psym_print_stats, psym_expand_symtabs_for_function)
3550 (psym_map_symbol_filenames, psym_map_matching_symbols)
3551 (psym_expand_symtabs_matching)
3552 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
3553 (maintenance_check_psymtabs): Update.
3554 * psympriv.h (struct partial_symtab) <readin_p,
3555 get_compunit_symtab>: Add objfile parameter.
3556 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
3557 Likewise.
3558 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
3559 get_compunit_symtab>: Likewise.
3560 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
3561
3562 2020-05-27 Tom Tromey <tom@tromey.com>
3563
3564 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
3565 member.
3566 * dwarf2/read.c (delete_file_name_entry): Fix comment.
3567 (create_cu_from_index_list)
3568 (create_signatured_type_table_from_index)
3569 (create_signatured_type_table_from_debug_names)
3570 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
3571 (dwarf2_create_include_psymtab)
3572 (create_debug_type_hash_table, add_type_unit)
3573 (create_type_unit_group, read_comp_units_from_section)
3574 (dwarf2_compute_name, create_cus_hash_table)
3575 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
3576 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
3577 obstack.
3578 (dw2_get_real_path): Likewise. Change argument to
3579 dwarf2_per_objfile.
3580
3581 2020-05-27 Luis Machado <luis.machado@linaro.org>
3582
3583 PR tdep/26000
3584 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
3585 for ldrd (immediate).
3586
3587 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3588
3589 * command.h: Add comment giving the name of class_tui.
3590 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
3591 create the fake command for the help for class_tui.
3592
3593 2020-05-26 Tom Tromey <tromey@adacore.com>
3594
3595 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
3596 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
3597 (val_atr): New function.
3598 (value_val_atr): Use it.
3599 * ada-valprint.c (print_optional_low_bound): Change low bound
3600 handling for enums.
3601 (val_print_packed_array_elements): Don't call discrete_position.
3602 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
3603 discrete_position for enum types.
3604 * language.c (default_print_array_index): Change type.
3605 * language.h (struct language_defn) <la_print_array_index>: Add
3606 index_type parameter, change type of index_value.
3607 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
3608 (default_print_array_index): Update.
3609 * valprint.c (maybe_print_array_index): Don't call
3610 value_from_longest. Update.
3611 (value_print_array_elements): Don't call discrete_position.
3612
3613 2020-05-26 Tom Tromey <tromey@adacore.com>
3614
3615 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
3616 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
3617
3618 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
3619
3620 PR gdb/13519
3621 * avr-tdep.c (avr_integer_to_address): Return data or code
3622 address accordingly to the second 'type' argument of the
3623 function.
3624
3625 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
3626
3627 * infcmd.c, inferior.h: (construct_inferior_arguments):
3628 Moved function from here to gdbsupport/common-inferior.{h,cc}
3629
3630 2020-05-23 Tom Tromey <tom@tromey.com>
3631
3632 Revert commit eca1f90c:
3633 * NEWS: Remove entry for completion styling.
3634 * completer.c (_rl_completion_prefix_display_length): Move
3635 declaration later.
3636 (gdb_fnprint): Revert.
3637 (gdb_display_match_list_1): Likewise.
3638 * cli/cli-style.c (completion_prefix_style)
3639 (completion_difference_style, completion_suffix_style): Remove.
3640 (_initialize_cli_style): Revert.
3641 * cli/cli-style.h (completion_prefix_style)
3642 (completion_difference_style, completion_suffix_style): Don't
3643 declare.
3644
3645 2020-05-24 Pedro Alves <palves@redhat.com>
3646
3647 * symtab.c (completion_list_add_name): Return boolean indication
3648 of whether the symbol matched.
3649 (completion_list_add_symbol): Don't try to remove C++ aliases if
3650 the symbol didn't match in the first place.
3651 * symtab.h (completion_list_add_name): Return bool.
3652
3653 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
3654
3655 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
3656 type::field.
3657
3658 2020-05-23 Joel Brobecker <brobecker@adacore.com>
3659
3660 GDB 9.2 released.
3661
3662 2020-05-23 Tom Tromey <tom@tromey.com>
3663
3664 * NEWS: Add entry for completion styling.
3665 * completer.c (_rl_completion_prefix_display_length): Move
3666 declaration earlier.
3667 (gdb_fnprint): Use completion_style.
3668 (gdb_display_match_list_1): Likewise.
3669 * cli/cli-style.c (completion_prefix_style)
3670 (completion_difference_style, completion_suffix_style): New
3671 globals.
3672 (_initialize_cli_style): Register new globals.
3673 * cli/cli-style.h (completion_prefix_style)
3674 (completion_difference_style, completion_suffix_style): Declare.
3675
3676 2020-05-23 Pedro Alves <palves@redhat.com>
3677
3678 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
3679 (parse_escape): Use ISDIGIT instead of isdigit.
3680 (puts_debug): Use gdb_isprint instead of isprint.
3681 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
3682 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
3683 ISSPACE instead of isspace.
3684 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
3685 instead of isspace.
3686 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
3687 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
3688 instead of isxdigit and ISDIGIT instead of isdigit.
3689
3690 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3691
3692 * gdbtypes.h (struct type) <field>: New method.
3693 (TYPE_FIELDS): Remove, replace all uses with either type::fields
3694 or type::field.
3695
3696 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3697
3698 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
3699 (TYPE_FIELDS): Use type::fields. Change all call sites that
3700 modify the propery to use type::set_fields instead.
3701
3702 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3703
3704 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
3705 type::num_fields instead.
3706
3707 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
3708
3709 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
3710 methods.
3711 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
3712 that modify the number of fields to use type::set_num_fields
3713 instead.
3714
3715 2020-05-22 Tom Tromey <tromey@adacore.com>
3716
3717 * compile/compile-object-load.h (munmap_list_free): Don't
3718 declare.
3719
3720 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
3721
3722 * annotate.c (annotate_source_line): Update return type, add call
3723 to update current symtab and line.
3724 * annotate.h (annotate_source_line): Update return type, and
3725 extend header comment.
3726 * source.c (info_line_command): Check annotation_level before
3727 calling annotate_source_line.
3728 * stack.c (print_frame_info): If calling annotate_source_line
3729 returns true, then don't print any other source line information.
3730
3731 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
3732
3733 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
3734
3735 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
3736
3737 * coffread.c (patch_type): Remove NULL check before xfree.
3738 * corefile.c (set_gnutarget): Likewise.
3739 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
3740 * exec.c (build_section_table): Likewise.
3741 * remote.c (remote_target::pass_signals): Likewise.
3742 * utils.c (n_spaces): Likewise.
3743 * cli/cli-script.c (document_command): Likewise.
3744 * i386-windows-tdep.c (core_process_module_section): Likewise.
3745 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
3746
3747 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
3748
3749 * symfile.c (reread_symbols): Clear objfile's section_offsets
3750 vector and section indices, re-compute them by calling
3751 sym_offsets.
3752
3753 2020-05-20 Tom Tromey <tromey@adacore.com>
3754
3755 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
3756 (desc_one_bound, desc_index_type): Compute field name.
3757
3758 2020-05-20 Tom de Vries <tdevries@suse.de>
3759
3760 PR symtab/25833
3761 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
3762
3763 2020-05-20 Alan Modra <amodra@gmail.com>
3764
3765 PR 25993
3766 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
3767 bfd_set_filename.
3768 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
3769 passed to bfd_set_filename.
3770 * symfile-mem.c (add_vsyscall_page): Likewise for string
3771 passed to symbol_file_add_from_memory.
3772 (symbol_file_add_from_memory): Make name param a const char* and
3773 don't strdup.
3774
3775 2020-05-20 Alan Modra <amodra@gmail.com>
3776
3777 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
3778 rather than accessing bfd->filename directly.
3779 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
3780 and use bfd_section_name.
3781 * dwarf2/frame.c (decode_frame_entry): Likewise.
3782 * exec.c (exec_set_section_address): Likewise.
3783 * solib-aix.c (solib_aix_bfd_open): Likewise.
3784 * stap-probe.c (get_stap_base_address): Likewise.
3785 * symfile.c (reread_symbols): Likewise.
3786
3787 2020-05-19 Tom Tromey <tromey@adacore.com>
3788
3789 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
3790
3791 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3792
3793 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
3794
3795 2020-05-19 Pedro Alves <palves@redhat.com>
3796
3797 * NEWS (set exec-file-mismatch): Adjust entry.
3798 * exec.c: Include "build-id.h".
3799 (validate_exec_file): Try to match build IDs instead of filenames.
3800 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
3801 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
3802 and pass down 'warn_if_slow'.
3803 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
3804 gdb_bfd_open_closure to pass it down.
3805 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
3806
3807 2020-05-19 Pedro Alves <palves@redhat.com>
3808
3809 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
3810 * target.c (target_fileio_open_1): Rename to target_fileio_open
3811 and make extern. Use bool.
3812 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
3813 (target_fileio_read_alloc_1): Adjust.
3814 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
3815 (target_fileio_open_warn_if_slow): Delete declaration.
3816
3817 2020-05-19 Pedro Alves <palves@redhat.com>
3818
3819 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
3820 Adjust all callers.
3821
3822 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
3823
3824 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
3825 whether disp is negative.
3826
3827 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3828
3829 * symfile.h (struct symfile_segment_data)
3830 <~symfile_segment_data>: Remove.
3831 <segment_info>: Change to std::vector.
3832 * symfile.c (default_symfile_segments): Update.
3833 * elfread.c (elf_symfile_segments): Update.
3834
3835 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3836
3837 * symfile.h (struct symfile_segment_data) <struct segment>: New.
3838 <segments>: New.
3839 <segment_bases, segment_sizes>: Remove.
3840 * symfile.c (default_symfile_segments): Update.
3841 * elfread.c (elf_symfile_segments): Update.
3842 * remote.c (remote_target::get_offsets): Update.
3843 * solib-target.c (solib_target_relocate_section_addresses):
3844 Update.
3845
3846 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
3847
3848 * symfile.h (struct symfile_segment_data): Initialize fields.
3849 <~symfile_segment_data>: Add.
3850 (symfile_segment_data_up): New.
3851 (struct sym_fns) <sym_segments>: Return a
3852 symfile_segment_data_up.
3853 (default_symfile_segments): Return a symfile_segment_data_up.
3854 (free_symfile_segment_data): Remove.
3855 (get_symfile_segment_data): Return a symfile_segment_data_up.
3856 * symfile.c (default_symfile_segments): Likewise.
3857 (get_symfile_segment_data): Likewise.
3858 (free_symfile_segment_data): Remove.
3859 (symfile_find_segment_sections): Update.
3860 * elfread.c (elf_symfile_segments): Return a
3861 symfile_segment_data_up.
3862 * remote.c (remote_target::get_offsets): Update.
3863 * solib-target.c (solib_target_relocate_section_addresses):
3864 Update.
3865 * symfile-debug.c (debug_sym_segments): Return a
3866 symfile_segment_data_up.
3867
3868 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3869
3870 PR build/25981
3871 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
3872 Hardcode register numbers.
3873
3874 PR build/25981
3875 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
3876 procfs_find_LDT_entry): Remove.
3877 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
3878 procfs_find_LDT_entry): Remove.
3879 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
3880 Remove.
3881
3882 2020-05-17 Pedro Alves <palves@redhat.com>
3883 Andrew Burgess <andrew.burgess@embecosm.com>
3884 Keno Fischer <keno@juliacomputing.com>
3885
3886 PR gdb/25741
3887 * breakpoint.c (build_target_condition_list): Update comments.
3888 (build_target_command_list): Update comments and skip matching
3889 locations.
3890 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
3891 a separate function. Simplify "set breakpoint auto-hw off"
3892 handling.
3893 (insert_breakpoints): Update comment.
3894 (tracepoint_locations_match): New parameter. For breakpoints,
3895 compare location types too, if the caller wants to.
3896 (handle_automatic_hardware_breakpoints): New functions.
3897 (bp_location_is_less_than): Also sort by location type and
3898 hardware breakpoint length.
3899 (update_global_location_list): Handle "set breakpoint auto-hw on"
3900 here.
3901 (update_breakpoint_locations): Ask breakpoint_locations_match to
3902 ignore location types.
3903
3904 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3905
3906 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
3907 type::name instead.
3908
3909 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3910
3911 * gdbtypes.h (struct type) <name, set_name>: New methods.
3912 (TYPE_CODE): Use type::name. Change all call sites used to set
3913 the name to use type::set_name instead.
3914
3915 2020-05-16 Tom Tromey <tom@tromey.com>
3916
3917 * top.c (quit_force): Update.
3918 * infrun.c (handle_no_resumed): Update.
3919 * top.h (all_uis): New function.
3920 (ALL_UIS): Remove.
3921
3922 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
3923
3924 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
3925
3926 2020-05-16 Pedro Alves <palves@redhat.com>
3927
3928 * ia64-linux-nat.c
3929 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
3930 Declare method.
3931 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
3932
3933 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
3934
3935 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
3936 (sparc64_adi_info): Likewise.
3937
3938 2020-05-15 Tom Tromey <tom@tromey.com>
3939
3940 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
3941 block_objfile.
3942 (lookup_objfile_from_block): Remove.
3943 (lookup_symbol_in_block, lookup_symbol_in_static_block)
3944 (lookup_global_symbol): Use block_objfile.
3945 * symtab.h (lookup_objfile_from_block): Don't declare.
3946 * printcmd.c (clear_dangling_display_expressions): Use
3947 block_objfile.
3948 * parse.c (operator_check_standard): Use block_objfile.
3949
3950 2020-05-15 Tom Tromey <tom@tromey.com>
3951
3952 * language.c (language_alloc_type_symbol): Set
3953 SYMBOL_SECTION.
3954 * symtab.c (initialize_objfile_symbol): Remove.
3955 (allocate_symbol): Remove.
3956 (allocate_template_symbol): Remove.
3957 * dwarf2/read.c (fixup_go_packaging): Use "new".
3958 (new_symbol): Use "new".
3959 (read_variable): Don't call initialize_objfile_symbol. Use
3960 "new".
3961 (read_func_scope): Use "new".
3962 * xcoffread.c (process_xcoff_symbol): Don't call
3963 initialize_objfile_symbol.
3964 (SYMBOL_DUP): Remove.
3965 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
3966 "new".
3967 * symtab.h (allocate_symbol, initialize_objfile_symbol)
3968 (allocate_template_symbol): Don't declare.
3969 (struct symbol): Add copy constructor. Change defaults.
3970 * jit.c (finalize_symtab): Use "new".
3971 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
3972 Use "new".
3973 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
3974 (common_block_end): Use "new".
3975 * mdebugread.c (parse_symbol): Use "new".
3976 (new_symbol): Likewise.
3977
3978 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3979
3980 * NEWS: Mention changes to help and apropos.
3981
3982 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3983
3984 * command.h (enum command_class): Improve comments, document
3985 that class_alias is for user-defined aliases, give the class
3986 name for each class, remove unused class_xdb.
3987 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
3988 * breakpoint.c (_initialize_breakpoint): Replace class_alias
3989 by a precise class.
3990 * infcmd.c (_initialize_infcmd): Likewise.
3991 * reverse.c (_initialize_reverse): Likewise.
3992 * stack.c (_initialize_stack): Likewise.
3993 * symfile.c (_initialize_symfile): Likewise.
3994 * tracepoint.c (_initialize_tracepoint): Likewise.
3995
3996 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3997
3998 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
3999 when their aliased command is traversed.
4000 (help_cmd): Add fput_command_names_styled call to
4001 output command name and aliases when command has an alias.
4002
4003 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4004
4005 * cli/cli-decode.h (help_cmd_list): Remove declaration.
4006 * cli/cli-decode.c (help_cmd_list): Declare as static,
4007 remove prefix argument, use bool for recurse arg, rework to show the aliases of
4008 a command together with the command.
4009 (fput_command_name_styled, fput_command_names_styled): New functions.
4010 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
4011 fput_command_name_styled.
4012 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
4013 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
4014
4015 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4016
4017 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
4018 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
4019 * command.h (cmd_show_list): Likewise.
4020 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
4021 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
4022
4023 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4024
4025 * unittests/command-def-selftests.c (traverse_command_structure):
4026 Verify all commands of a list have the same prefix command and
4027 that only the top cmdlist commands have a null prefix.
4028
4029 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4030
4031 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
4032 as prefix, not one of its aliases.
4033 (set_cmd_prefix): Remove.
4034 (do_add_cmd): Centralize the setting of the prefix of a command, when
4035 command is defined after its full chain of prefix commands.
4036 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
4037 (add_setshow_cmd_full): Likewise.
4038 (update_prefix_field_of_prefixed_commands): New function.
4039 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
4040 update_prefix_field_of_prefixed_commands.
4041 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
4042 addresses of remote_set_cmdlist and remote_show_cmdlist given
4043 as argument, not the address of an argument.
4044 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
4045 * gdb/remote.c (_initialize_remote): Likewise.
4046
4047 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4048
4049 * cli/cli-cmds.c (alias_command): Check for an existing alias
4050 using lookup_cmd_composition, as valid_command_p is too strict
4051 and forbids aliases that are the prefix of an existing alias
4052 or command.
4053 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
4054 command is properly recognised as a valid command.
4055
4056 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4057
4058 * unittests/help-doc-selftests.c: Rename to
4059 unittests/command-def-selftests.c
4060 * unittests/command-def-selftests.c (help_doc_tests): Update some
4061 comments.
4062 (command_structure_tests, traverse_command_structure): New namespace
4063 and function.
4064 (command_structure_invariants_tests): New function.
4065 (_initialize_command_def_selftests) Renamed from
4066 _initialize_help_doc_selftests, register command_structure_invariants
4067 selftest.
4068
4069 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4070
4071 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
4072 an alias of 'show'.
4073
4074 2020-05-15 Joel Brobecker <brobecker@adacore.com>
4075
4076 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
4077 ada_is_fixed_point_type. Update all callers.
4078 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
4079 all callers.
4080 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
4081 Update all callers.
4082 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
4083 print_fixed_point_type. Update all callers.
4084 * ada-valprint.c (ada_value_print_num): Replace call to
4085 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
4086
4087 2020-05-14 Kevin Buettner <kevinb@redhat.com>
4088
4089 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
4090 processors.
4091 (cpu_supports_bts): Add CV_AMD case.
4092
4093 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
4094 Simon Marchi <simon.marchi@efficios.com>
4095
4096 * infrun.c (stop_all_threads): Collect multiple wait events at
4097 each pass.
4098
4099 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
4100
4101 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
4102 type::code instead.
4103
4104 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
4105
4106 * gdbtypes.h (struct type) <code, set_code>: New methods.
4107 (TYPE_CODE): Use type::code. Change all call sites used to set
4108 the code to use type::set_code instead.
4109
4110 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4111 Tom de Vries <tdevries@suse.de>
4112 Pedro Alves <palves@redhat.com>
4113
4114 PR threads/25478
4115 * infrun.c (stop_all_threads): Do NOT ignore
4116 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
4117 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
4118 received.
4119 (handle_no_resumed): Remove code handling a live inferior with no
4120 threads.
4121 * remote.c (has_single_non_exited_thread): New.
4122 (remote_target::update_thread_list): Do not delete a thread if is
4123 the last thread of the process.
4124 * thread.c (thread_select): Call delete_exited_threads instead of
4125 prune_threads.
4126
4127 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4128
4129 * infrun.c (stop_all_threads): Enable/disable thread events of all
4130 targets. Move a debug message denoting the end of the function
4131 into the SCOPED_EXIT block.
4132
4133 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4134
4135 * process-stratum-target.h: Include <set>.
4136 (all_non_exited_process_targets, switch_to_target_no_thread): New
4137 function declarations.
4138 * process-stratum-target.c (all_non_exited_process_targets)
4139 (switch_to_target_no_thread): New function implementations.
4140
4141 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4142
4143 * infrun.c (handle_inferior_event): Extract out a piece of code
4144 into...
4145 (mark_non_executing_threads): ...this new function.
4146
4147 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4148
4149 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
4150 use.
4151
4152 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4153
4154 * regcache.c (regcache_read_pc_protected): New function
4155 implementation that returns 0 if the PC cannot read via
4156 'regcache_read_pc'.
4157 * infrun.c (proceed): Call 'regcache_read_pc_protected'
4158 instead of 'regcache_read_pc'.
4159 (keep_going_pass_signal): Ditto.
4160
4161 2020-05-13 Tom Tromey <tromey@adacore.com>
4162
4163 * ada-lang.c (align_value): Remove.
4164 (ada_template_to_fixed_record_type_1): Use align_up.
4165
4166 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4167
4168 * async-event.c: Update the copyright year.
4169 * async-event.h: Update the copyright year.
4170
4171 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
4172
4173 * objfiles.h (is_addr_in_objfile,
4174 shared_objfile_contains_address_p): Return bool.
4175 * objfile.c (is_addr_in_objfile,
4176 shared_objfile_contains_address_p): Return bool.
4177
4178 2020-05-11 Tom Tromey <tromey@adacore.com>
4179
4180 * cli/cli-cmds.c (info_command): Restore.
4181 (_initialize_cli_cmds): Use add_prefix_command for "info".
4182 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
4183
4184 2020-05-11 Tom Tromey <tromey@adacore.com>
4185
4186 * ada-lang.c (ada_value_primitive_field): Now public.
4187 * ada-lang.h (ada_value_primitive_field): Declare.
4188 * ada-valprint.c (print_field_values): Use
4189 ada_value_primitive_field for wrapper fields.
4190
4191 2020-05-11 Tom de Vries <tdevries@suse.de>
4192
4193 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
4194 MODULE_DOMAIN.
4195
4196 2020-05-11 Tom de Vries <tdevries@suse.de>
4197
4198 PR symtab/25941
4199 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
4200 with length 0, if not gdb-produced.
4201 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
4202
4203 2020-05-09 Tom de Vries <tdevries@suse.de>
4204
4205 PR gdb/25955
4206 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
4207 calculation.
4208
4209 2020-05-09 Tom Tromey <tom@tromey.com>
4210
4211 * top.c (server_command): Now bool.
4212 * top.h (server_command): Now bool.
4213
4214 2020-05-08 Tom Tromey <tromey@adacore.com>
4215
4216 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
4217 already being processed.
4218
4219 2020-05-08 Tom Tromey <tom@tromey.com>
4220
4221 * printcmd.c (struct display) <next>: Remove.
4222 <display>: New constructor.
4223 <exp_string>: Now a std::string.
4224 <enabled_p>: Now a bool.
4225 (display_number): Move definition earlier.
4226 (displays): Rename from display_chain. Now a std::vector.
4227 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
4228 (display_command): Update.
4229 (do_one_display, disable_display)
4230 (enable_disable_display_command, do_enable_disable_display):
4231 Update.
4232 (free_display): Remove.
4233 (clear_displays): Rewrite.
4234 (delete_display): Update.
4235 (map_display_numbers): Use function_view. Remove "data"
4236 parameter. Update.
4237 (do_delete_display): Remove.
4238 (undisplay_command): Update.
4239 (do_one_display, do_displays, disable_display)
4240 (info_display_command): Update.
4241 (do_enable_disable_display): Remove.
4242 (enable_disable_display_command)
4243 (clear_dangling_display_expressions): Update.
4244
4245 2020-05-08 Tom Tromey <tom@tromey.com>
4246
4247 * symtab.c (set_symbol_cache_size)
4248 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
4249 (maintenance_print_symbol_cache_statistics): Update.
4250 * symmisc.c (print_symbol_bcache_statistics)
4251 (print_objfile_statistics, maintenance_print_objfiles)
4252 (maintenance_info_symtabs, maintenance_check_symtabs)
4253 (maintenance_expand_symtabs, maintenance_info_line_tables):
4254 Update.
4255 * symfile-debug.c (set_debug_symfile): Update.
4256 * source.c (forget_cached_source_info): Update.
4257 * python/python.c (gdbpy_progspaces): Update.
4258 * psymtab.c (maintenance_info_psymtabs): Update.
4259 * probe.c (parse_probes): Update.
4260 * linespec.c (iterate_over_all_matching_symtabs)
4261 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
4262 * guile/scm-progspace.c (gdbscm_progspaces): Update.
4263 * exec.c (exec_target::close): Update.
4264 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
4265 * breakpoint.c (print_one_breakpoint_location)
4266 (create_longjmp_master_breakpoint)
4267 (create_std_terminate_master_breakpoint): Update.
4268 * progspace.c (program_spaces): Now a std::vector.
4269 (maybe_new_address_space): Update.
4270 (add_program_space): Remove.
4271 (program_space::program_space): Update.
4272 (remove_program_space): Update.
4273 (number_of_program_spaces): Remove.
4274 (print_program_space, update_address_spaces): Update.
4275 * progspace.h (program_spaces): Change type.
4276 (ALL_PSPACES): Remove.
4277 (number_of_program_spaces): Don't declare.
4278 (struct program_space) <next>: Remove.
4279
4280 2020-05-08 Tom Tromey <tom@tromey.com>
4281
4282 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
4283 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
4284 (enable_break): Update.
4285 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
4286 (frv_fdpic_find_canonical_descriptor): Update.
4287 (frv_fetch_objfile_link_map): Update.
4288 * progspace.c (program_space::free_all_objfiles): Update.
4289 (program_space::solibs): New method.
4290 * progspace.h (struct program_space) <solibs>: New method.
4291 * solist.h (master_so_list): Don't declare.
4292 (ALL_SO_LIBS): Remove.
4293 * solib.h (so_list_head): Remove.
4294 (update_solib_list): Update comment.
4295 * solib.c (master_so_list): Remove.
4296 (solib_used, update_solib_list, solib_add)
4297 (info_sharedlibrary_command, clear_solib)
4298 (reload_shared_libraries_1, remove_user_added_objfile): Update.
4299
4300 2020-05-08 Tom Tromey <tom@tromey.com>
4301
4302 * extension.c (extension_languages): Now a std::array.
4303 (ALL_EXTENSION_LANGUAGES): Remove.
4304 (get_ext_lang_defn, get_ext_lang_of_file)
4305 (eval_ext_lang_from_control_command): Update.
4306 (finish_ext_lang_initialization)
4307 (auto_load_ext_lang_scripts_for_objfile)
4308 (ext_lang_type_printers::ext_lang_type_printers)
4309 (apply_ext_lang_type_printers)
4310 (ext_lang_type_printers::~ext_lang_type_printers)
4311 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
4312 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
4313 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
4314 (get_matching_xmethod_workers, ext_lang_colorize)
4315 (ext_lang_before_prompt): Update.
4316 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
4317
4318 2020-05-08 Tom Tromey <tom@tromey.com>
4319
4320 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
4321 overload.
4322 <swap_string, m_string>: Remove.
4323 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
4324 Update.
4325 * stabsread.c (define_symbol, read_type): Update.
4326 * linespec.c (find_linespec_symbols): Update.
4327 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
4328 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
4329 * dbxread.c (read_dbx_symtab): Update.
4330 * cp-support.h (cp_canonicalize_string_full)
4331 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
4332 Return unique_xmalloc_ptr.
4333 * cp-support.c (inspect_type): Update.
4334 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
4335 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
4336 Likewise.
4337 * c-typeprint.c (print_name_maybe_canonical): Update.
4338 * break-catch-throw.c (check_status_exception_catchpoint):
4339 Update.
4340
4341 2020-05-08 Tom de Vries <tdevries@suse.de>
4342
4343 * infrun.c (follow_fork): Copy current_line and current_symtab to
4344 child thread.
4345
4346 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4347
4348 * async-event.c (struct async_signal_handler, struct
4349 async_event_handler): Reformat, remove typedef.
4350
4351 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4352
4353 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
4354 access thistype->main_type->dyn_prop_list directly.
4355
4356 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4357
4358 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
4359 (remove_dyn_prop): Remove. Update all users to use
4360 type::remove_dyn_prop.
4361 * gdbtypes.c (remove_dyn_prop): Rename to...
4362 (type::remove_dyn_prop): ... this.
4363
4364 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
4365
4366 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
4367 (add_dyn_prop): Remove. Update all users to use
4368 type::add_dyn_prop.
4369 * gdbtypes.c (add_dyn_prop): Rename to...
4370 (type::add_dyn_prop): ... this.
4371
4372 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
4373
4374 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
4375 (get_dyn_prop): Remove. Update all users to use
4376 type::dyn_prop.
4377 * gdbtypes.c (get_dyn_prop): Rename to...
4378 (type::dyn_prop): ... this.
4379
4380 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
4381
4382 * gdbtypes.h (struct main_type) <flag_static>: Remove.
4383
4384 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
4385
4386 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
4387 instruction, skip it if it's there.
4388
4389 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
4390
4391 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
4392
4393 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
4394
4395 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
4396 * gdbtypes.c (recursive_dump_type): Remove use of
4397 TYPE_INCOMPLETE.
4398
4399 2020-05-03 Tom Tromey <tom@tromey.com>
4400
4401 * breakpoint.c (catch_command, tcatch_command): Remove.
4402 (_initialize_breakpoint): Use add_basic_prefix_cmd,
4403 add_show_prefix_cmd.
4404 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
4405 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4406 Remove.
4407 (add_internal_problem_command): Use add_basic_prefix_cmd,
4408 add_show_prefix_cmd.
4409 * mips-tdep.c (set_mipsfpu_command): Remove.
4410 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
4411 * dwarf2/index-cache.c (set_index_cache_command): Remove.
4412 (_initialize_index_cache): Use add_basic_prefix_cmd.
4413 * memattr.c (dummy_cmd): Remove.
4414 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
4415 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
4416 (_initialize_tui_win): Use add_basic_prefix_cmd,
4417 add_show_prefix_cmd.
4418 * cli/cli-logging.c (set_logging_command): Remove.
4419 (_initialize_cli_logging): Use add_basic_prefix_cmd,
4420 add_show_prefix_cmd.
4421 (show_logging_command): Remove.
4422 * target.c (target_command): Remove.
4423 (add_target): Use add_basic_prefix_cmd.
4424
4425 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
4426
4427 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
4428
4429 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4430
4431 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
4432 info_command.
4433
4434 2020-04-30 Kamil Rytarowski <n54@gmx.com>
4435
4436 * nbsd-nat.c (nbsd_enable_proc_events)
4437 (nbsd_nat_target::post_startup_inferior): Add.
4438 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
4439 (nbsd_nat_target::update_thread_list): Rewrite.
4440 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
4441 "PTRACE_LWP_CREATE".
4442 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
4443
4444 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4445
4446 * stack.c (_initialize_stack): Remove duplicated creation
4447 of "frame" command and "f" alias.
4448
4449 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4450
4451 PR gdb/18706
4452 * gdbtypes.c (check_typedef): Calculate size of array of
4453 stubbed type.
4454
4455 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
4456
4457 PR gdb/15559
4458 * i386-tdep.c (i386_push_dummy_call): Call
4459 i386_thiscall_push_dummy_call.
4460 (i386_thiscall_push_dummy_call): New function.
4461 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
4462 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
4463 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
4464
4465 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4466
4467 * gdbarch.sh (do_read): Add shellcheck disable directive for
4468 warning SC2162.
4469
4470 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4471
4472 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
4473 "referenced but not assigned" warning.
4474
4475 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4476
4477 * gdbarch.sh: Remove code that sets fallbackdefault.
4478
4479 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4480
4481 * gdbarch.sh: Use shell operators && and || instead of
4482 -a and -o.
4483
4484 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4485
4486 * gdbarch.sh: Use $(...) instead of `...`.
4487
4488 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4489
4490 * gdbarch.sh: Use double quotes around variables.
4491
4492 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
4493
4494 * gdbarch.sh: Use %s with printf, instead of variables in the
4495 format string.
4496
4497 2020-04-29 Tom Tromey <tromey@adacore.com>
4498
4499 PR ada/25875:
4500 * dwarf2/read.c (update_enumeration_type_from_children): Compute
4501 type fields here.
4502 (read_enumeration_type): Call
4503 update_enumeration_type_from_children later. Update comments.
4504 (process_enumeration_scope): Don't create type fields.
4505
4506 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4507
4508 * nbsd-tdep.c: Include "xml-syscall.h".
4509 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
4510
4511 2020-04-29 Kamil Rytarowski <n54@gmx.com>
4512
4513 * nbsd-nat.c: Include "sys/wait.h".
4514 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
4515 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
4516 (nbsd_nat_target::remove_exec_catchpoint)
4517 (nbsd_nat_target::set_syscall_catchpoint): Add.
4518 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
4519 (nbsd_nat_target::insert_exec_catchpoint)
4520 (nbsd_nat_target::remove_exec_catchpoint)
4521 (nbsd_nat_target::set_syscall_catchpoint): Add.
4522 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
4523 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
4524 `nbsd_get_syscall_number'.
4525
4526 2020-04-29 Tom Tromey <tom@tromey.com>
4527
4528 * stack.c (print_block_frame_labels): Remove.
4529
4530 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
4531
4532 PR gdb/17320
4533 * ada-valprint.c (val_print_packed_array_elements): Move array
4534 end bracket to new line.
4535 (ada_val_print_string): Remove extra spaces before first array
4536 element.
4537 * c-valprint.c (c_value_print_array): Likewise.
4538 * m2-valprint.c (m2_print_array_contents): Likewise.
4539 (m2_value_print_inner): Likewise.
4540 * p-valprint.c (pascal_value_print_inner): Likewise.
4541 * valprint.c (generic_val_print_array): Likewise.
4542 (value_print_array_elements): Move first array element and array
4543 end bracket to new line.
4544
4545 2020-04-29 Tom de Vries <tdevries@suse.de>
4546
4547 PR symtab/25889
4548 * linespec.c (find_method): Fix ix calculation.
4549
4550 2020-04-28 Kamil Rytarowski <n54@gmx.com>
4551
4552 * syscalls/update-netbsd.sh: New file.
4553 * syscalls/netbsd.xml: Regenerate.
4554 * data-directory/Makefile.in: Register `netbsd.xml' in
4555 `SYSCALLS_FILES'.
4556
4557 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
4558
4559 * syscalls/update-freebsd.sh: Add double quotes.
4560
4561 2020-04-28 Tom Tromey <tom@tromey.com>
4562
4563 * NEWS: Update.
4564 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
4565 (cmdpy_init): Allow class_tui.
4566
4567 2020-04-28 Mark Williams <mark@myosotissp.com>
4568
4569 PR gdb/24480
4570 * dwarf2read.c: Add missing assingments to list_in_scope when
4571 start_symtab was already called.
4572
4573 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
4574
4575 PR gdb/25881
4576 * dwarf2/read.c (offset_map_type): Use
4577 gdb:hash_enum<sect_offset> as hash function.
4578
4579 2020-04-28 Tom de Vries <tdevries@suse.de>
4580
4581 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
4582 with DW_AT_signature.
4583
4584 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
4585
4586 * configure.ac: Remove check for fs_base/gs_base in
4587 user_regs_struct.
4588 * configure: Re-generate.
4589 * config.in: Re-generate.
4590 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
4591 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
4592 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
4593
4594 2020-04-27 Luis Machado <luis.machado@linaro.org>
4595
4596 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
4597 problematic inline frame unwinding situation.
4598 * frame.c (frame_id_computed_p): New function.
4599 * frame.h (frame_id_computed_p): New prototype.
4600
4601 2020-04-26 Tom Tromey <tom@tromey.com>
4602
4603 * command.h (enum command_class) <class_pseudo>: Remove.
4604
4605 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4606
4607 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
4608 and whitespace.
4609
4610 2020-04-25 Kamil Rytarowski <n54@gmx.com>
4611
4612 * inf-ptrace.c (inf_ptrace_target::wait): Remove
4613 `PT_GET_PROCESS_STATE' block.
4614
4615 2020-04-24 Tom Tromey <tom@tromey.com>
4616
4617 * symtab.h (symbol_get_demangled_name): Don't declare.
4618 * symtab.c (symbol_get_demangled_name): Remove.
4619 (general_symbol_info::natural_name)
4620 (general_symbol_info::demangled_name): Update.
4621
4622 2020-04-24 Tom Tromey <tom@tromey.com>
4623
4624 PR rust/25025:
4625 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
4626
4627 2020-04-24 Tom Tromey <tom@tromey.com>
4628
4629 PR symtab/12707:
4630 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
4631 exists.
4632 (new_symbol): Likewise.
4633 * compile/compile-object-load.c (get_out_value_type): Use
4634 symbol_matches_search_name.
4635
4636 2020-04-24 Tom Tromey <tom@tromey.com>
4637
4638 * dwarf2/read.c (add_partial_symbol): Do not call
4639 compute_and_set_names.
4640
4641 2020-04-24 Tom Tromey <tom@tromey.com>
4642
4643 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
4644 overload.
4645
4646 2020-04-24 Tom Tromey <tom@tromey.com>
4647
4648 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
4649 (add_psymbol_to_list): New overload. Make old overload call new
4650 one.
4651 * psympriv.h (add_psymbol_to_list): New overload.
4652
4653 2020-04-24 Tom Tromey <tom@tromey.com>
4654
4655 * dwarf2/read.c (partial_die_info::read) <case
4656 DW_AT_linkage_name>: Use value_as_string.
4657 (dwarf2_string_attr): Use value_as_string.
4658 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
4659 method.
4660 * dwarf2/attribute.c (attribute::value_as_string): New method.
4661
4662 2020-04-24 Tom Tromey <tom@tromey.com>
4663
4664 * symtab.c (general_symbol_info::natural_name)
4665 (general_symbol_info::demangled_name): Check for language_rust.
4666
4667 2020-04-24 Tom Tromey <tom@tromey.com>
4668
4669 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
4670 (dwarf2_physname): ... from here.
4671 (partial_die_info::read): Add Rust "{" hack.
4672
4673 2020-04-24 Tom Tromey <tom@tromey.com>
4674
4675 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
4676 method.
4677 (symbol_set_demangled_name): Don't declare.
4678 * symtab.c (general_symbol_info::set_demangled_name): Rename from
4679 symbol_set_demangled_name.
4680 (general_symbol_info::set_language)
4681 (general_symbol_info::compute_and_set_names): Update.
4682 * minsyms.c (minimal_symbol_reader::install): Update.
4683 * dwarf2/read.c (new_symbol): Update.
4684
4685 2020-04-24 Tom Tromey <tromey@adacore.com>
4686
4687 PR python/23662:
4688 * python/py-type.c (convert_field): Handle
4689 FIELD_LOC_KIND_DWARF_BLOCK.
4690 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
4691 (typy_get_dynamic): Nw function.
4692 (type_object_getset): Add "dynamic".
4693 * NEWS: Add entry.
4694
4695 2020-04-24 Tom Tromey <tromey@adacore.com>
4696
4697 * ada-typeprint.c (print_choices, print_variant_part)
4698 (print_record_field_types_dynamic): New functions.
4699 (print_record_field_types): Use print_record_field_types_dynamic.
4700
4701 2020-04-24 Tom Tromey <tromey@adacore.com>
4702
4703 * dwarf2/read.c (handle_data_member_location): New overload.
4704 (dwarf2_add_field): Use it.
4705 (decode_locdesc): Add "computed" parameter. Update comment.
4706 * gdbtypes.c (is_dynamic_type_internal): Also look for
4707 FIELD_LOC_KIND_DWARF_BLOCK.
4708 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
4709 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
4710 virtual base classes.
4711 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
4712 FIELD_LOC_KIND_DWARF_BLOCK.
4713
4714 2020-04-24 Tom Tromey <tromey@adacore.com>
4715
4716 * dwarf2/read.c (read_structure_type): Handle dynamic length.
4717 * gdbtypes.c (is_dynamic_type_internal): Check
4718 TYPE_HAS_DYNAMIC_LENGTH.
4719 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
4720 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
4721 New macros.
4722 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
4723 constant.
4724
4725 2020-04-24 Tom Tromey <tromey@adacore.com>
4726
4727 * dwarf2/read.c (struct variant_field): Rewrite.
4728 (struct variant_part_builder): New.
4729 (struct nextfield): Remove "variant" field. Add "offset".
4730 (struct field_info): Add "current_variant_part" and
4731 "variant_parts".
4732 (alloc_discriminant_info): Remove.
4733 (alloc_rust_variant): New function.
4734 (quirk_rust_enum): Update.
4735 (dwarf2_add_field): Set "offset" member. Don't handle
4736 DW_TAG_variant_part.
4737 (offset_map_type): New typedef.
4738 (convert_variant_range, create_one_variant)
4739 (create_one_variant_part, create_variant_parts)
4740 (add_variant_property): New functions.
4741 (dwarf2_attach_fields_to_type): Call add_variant_property.
4742 (read_structure_type): Don't handle DW_TAG_variant_part.
4743 (handle_variant_part, handle_variant): New functions.
4744 (handle_struct_member_die): Use them.
4745 (process_structure_scope): Don't handle variant parts.
4746 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
4747 (struct discriminant_info): Remove.
4748 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
4749 (struct main_type) <flag_discriminated_union>: Remove.
4750 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
4751 (rust_enum_variant): Return int. Remove "contents". Rewrite.
4752 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
4753 Update.
4754 * valops.c (value_union_variant): Remove.
4755 * value.h (value_union_variant): Don't declare.
4756
4757 2020-04-24 Tom Tromey <tromey@adacore.com>
4758
4759 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
4760 (ada_value_primitive_packed_val): Update.
4761 * ada-valprint.c (ada_value_print_1): Update.
4762 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
4763 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
4764 just an address. Use evaluate_for_locexpr_baton.
4765 (dwarf2_evaluate_property): Update.
4766 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
4767 array_view.
4768 * findvar.c (default_read_var_value): Update.
4769 * gdbtypes.c (compute_variant_fields_inner)
4770 (resolve_dynamic_type_internal): Update.
4771 (resolve_dynamic_type): Change type of valaddr parameter.
4772 * gdbtypes.h (resolve_dynamic_type): Update.
4773 * valarith.c (value_subscripted_rvalue): Update.
4774 * value.c (value_from_contents_and_address): Update.
4775
4776 2020-04-24 Tom Tromey <tromey@adacore.com>
4777
4778 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
4779 "push_initial_value" parameter.
4780 (dwarf2_evaluate_property): Likewise.
4781 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
4782
4783 2020-04-24 Tom Tromey <tromey@adacore.com>
4784
4785 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
4786 (variant::matches, compute_variant_fields_recurse)
4787 (compute_variant_fields_inner, compute_variant_fields): New
4788 functions.
4789 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
4790 Use resolved_type after type is made.
4791 (operator==): Add new cases.
4792 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
4793 (struct discriminant_range, struct variant, struct variant_part):
4794 New.
4795 (union dynamic_prop_data) <variant_parts, original_type>: New
4796 members.
4797 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
4798 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
4799 constants.
4800 * value.c (unpack_bits_as_long): Now public.
4801 * value.h (unpack_bits_as_long): Declare.
4802
4803 2020-04-24 Tom Tromey <tromey@adacore.com>
4804
4805 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
4806 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
4807
4808 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
4809
4810 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
4811
4812 2020-04-24 Kamil Rytarowski <n54@gmx.com>
4813
4814 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
4815 (remove_fork_catchpoint, post_startup_inferior)
4816 (post_attach): Move...
4817 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
4818 (remove_fork_catchpoint, post_startup_inferior)
4819 (post_attach): ...here.
4820 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
4821 (remove_fork_catchpoint, post_startup_inferior)
4822 (post_attach): Move...
4823 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
4824 (remove_fork_catchpoint, post_startup_inferior)
4825 (post_attach): ...here.
4826
4827 2020-04-24 Tom Tromey <tromey@adacore.com>
4828
4829 * nat/windows-nat.h (struct windows_thread_info)
4830 <pc_adjusted>: New member.
4831 * windows-nat.c (windows_fetch_one_register): Check
4832 pc_adjusted.
4833 (windows_nat_target::get_windows_debug_event)
4834 (windows_nat_target::wait): Set pc_adjusted.
4835
4836 2020-04-24 Tom de Vries <tdevries@suse.de>
4837
4838 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
4839 Run gdb-add-index inside temp dir.
4840
4841 2020-04-23 Tom Tromey <tromey@adacore.com>
4842
4843 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
4844 in loop.
4845
4846 2020-04-23 Luis Machado <luis.machado@linaro.org>
4847
4848 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
4849 get_frame_register instead of gdbarch_unwind_pc.
4850
4851 2020-04-23 Tom de Vries <tdevries@suse.de>
4852
4853 * symtab.c (lookup_global_symbol): Prefer def over decl.
4854
4855 2020-04-23 Tom de Vries <tdevries@suse.de>
4856
4857 PR symtab/25807
4858 * block.c (best_symbol, better_symbol): Promote to external.
4859 * block.h (best_symbol, better_symbol): Declare.
4860 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
4861 decl.
4862
4863 2020-04-23 Tom Tromey <tromey@adacore.com>
4864
4865 PR ada/25837:
4866 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
4867 "const char *", not a "const std::string &".
4868 <name_and_matcher::operator==>: Update.
4869 * unittests/lookup_name_info-selftests.c: Change type of
4870 "result".
4871
4872 2020-04-23 Tom Tromey <tom@tromey.com>
4873
4874 * inferior.h (iterate_over_inferiors): Don't declare.
4875 * inferior.c (iterate_over_inferiors): Remove.
4876 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
4877 Remove.
4878 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
4879 use iterate_over_inferiors.
4880 (darwin_resume_inferior_it)
4881 (struct resume_inferior_threads_param)
4882 (darwin_resume_inferior_threads_it): Remove.
4883 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
4884
4885 2020-04-23 Tom de Vries <tdevries@suse.de>
4886
4887 * blockframe.c (find_pc_partial_function): Use
4888 find_pc_sect_compunit_symtab rather than
4889 objfile->sf->qf->find_pc_sect_compunit_symtab.
4890
4891 2020-04-22 Tom de Vries <tdevries@suse.de>
4892
4893 PR symtab/25764
4894 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
4895 in psymtabs.
4896
4897 2020-04-22 Tom de Vries <tdevries@suse.de>
4898
4899 PR symtab/25801
4900 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
4901 symtabs.
4902
4903 2020-04-22 Tom de Vries <tdevries@suse.de>
4904
4905 PR symtab/25700
4906 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
4907 CU if already created.
4908
4909 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
4910
4911 * infrun.c (displaced_step_fixup): Switch to the event_thread
4912 before calling displaced_step_restore, not after.
4913
4914 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4915
4916 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
4917 its inferior is not recorded by us.
4918 (record_btrace_target_open): Replace call to
4919 all_non_exited_threads () with call to current_inferior
4920 ()->non_exited_threads ().
4921 (record_btrace_target::stop_recording): Likewise.
4922 (record_btrace_target::close): Likewise.
4923 (record_btrace_target::wait): Likewise.
4924 (record_btrace_target::record_stop_replaying): Likewise.
4925
4926 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4927
4928 * btrace.c (btrace_enable): Throw an error on double enables and
4929 when enabling recording fails.
4930 (btrace_disable): Throw an error if the thread is not recorded.
4931
4932 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
4933
4934 * record-btrace.c (record_btrace_target::fetch_registers): Forward
4935 request if we do not have a thread_info.
4936
4937 2020-04-21 Tom de Vries <tdevries@suse.de>
4938
4939 PR gdb/25471
4940 * thread.c
4941 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
4942 exception in get_frame_id.
4943
4944 2020-04-20 Tom Tromey <tromey@adacore.com>
4945
4946 * python/python.c (struct gdbpy_event): Mark move constructor as
4947 noexcept.
4948 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
4949 constructor as noexcept.
4950 * completer.h (struct completion_result): Mark move constructor as
4951 noexcept.
4952 * completer.c (completion_result::completion_result): Use
4953 initialization style. Don't call reset_match_list.
4954
4955 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
4956
4957 * MAINTAINERS (Write After Approval): Add myself.
4958
4959 2020-04-18 Tom Tromey <tom@tromey.com>
4960
4961 * windows-tdep.c (init_w32_command_list)
4962 (w32_prefix_command_valid): Restore.
4963 (_initialize_windows_tdep): Call init_w32_command_list.
4964
4965 2020-04-18 Tom Tromey <tom@tromey.com>
4966
4967 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
4968 * value.c (value_fn_field): Update.
4969 * valops.c (find_function_in_inferior)
4970 (value_allocate_space_in_inferior): Update.
4971 * tui/tui-winsource.c (tui_update_source_windows_with_line):
4972 Update.
4973 * tui/tui-source.c (tui_source_window::set_contents): Update.
4974 * symtab.c (lookup_global_or_static_symbol)
4975 (find_function_start_sal_1, skip_prologue_sal)
4976 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
4977 * symmisc.c (dump_msymbols, dump_symtab_1)
4978 (maintenance_print_one_line_table): Update.
4979 * symfile.c (init_entry_point_info, section_is_mapped)
4980 (list_overlays_command, simple_read_overlay_table)
4981 (simple_overlay_update_1): Update.
4982 * stap-probe.c (handle_stap_probe): Update.
4983 * stabsread.c (dbx_init_float_type, define_symbol)
4984 (read_one_struct_field, read_enum_type, read_range_type): Update.
4985 * source.c (info_line_command): Update.
4986 * python/python.c (gdbpy_source_objfile_script)
4987 (gdbpy_execute_objfile_script): Update.
4988 * python/py-type.c (save_objfile_types): Update.
4989 * python/py-objfile.c (py_free_objfile): Update.
4990 * python/py-inferior.c (python_new_objfile): Update.
4991 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
4992 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
4993 (maintenance_check_psymtabs): Update.
4994 * printcmd.c (info_address_command): Update.
4995 * objfiles.h (struct objfile) <arch>: New method, from
4996 get_objfile_arch.
4997 (get_objfile_arch): Don't declare.
4998 * objfiles.c (get_objfile_arch): Remove.
4999 (filter_overlapping_sections): Update.
5000 * minsyms.c (msymbol_is_function): Update.
5001 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
5002 (output_nondebug_symbol): Update.
5003 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
5004 (mdebug_expand_psymtab): Update.
5005 * machoread.c (macho_add_oso_symfile): Update.
5006 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
5007 Update.
5008 * linux-fork.c (checkpoint_command): Update.
5009 * linespec.c (convert_linespec_to_sals): Update.
5010 * jit.c (finalize_symtab): Update.
5011 * infrun.c (insert_exception_resume_from_probe): Update.
5012 * ia64-tdep.c (ia64_find_unwind_table): Update.
5013 * hppa-tdep.c (internalize_unwinds): Update.
5014 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
5015 Update.
5016 * gcore.c (call_target_sbrk): Update.
5017 * elfread.c (record_minimal_symbol, elf_symtab_read)
5018 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
5019 (elf_gnu_ifunc_resolve_by_got): Update.
5020 * dwarf2/read.c (create_addrmap_from_index)
5021 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
5022 (read_debug_names_from_section)
5023 (process_psymtab_comp_unit_reader, add_partial_symbol)
5024 (add_partial_subprogram, process_full_comp_unit)
5025 (read_file_scope, read_func_scope, read_lexical_block_scope)
5026 (read_call_site_scope, dwarf2_ranges_read)
5027 (dwarf2_record_block_ranges, dwarf2_add_field)
5028 (mark_common_block_symbol_computed, read_tag_pointer_type)
5029 (read_tag_string_type, dwarf2_init_float_type)
5030 (dwarf2_init_complex_target_type, read_base_type)
5031 (partial_die_info::read, partial_die_info::read)
5032 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
5033 (dwarf2_fetch_die_loc_sect_off): Update.
5034 * dwarf2/loc.c (dwarf2_find_location_expression)
5035 (class dwarf_evaluate_loc_desc, rw_pieced_value)
5036 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
5037 (dwarf2_loc_desc_get_symbol_read_needs)
5038 (locexpr_describe_location_piece, locexpr_describe_location_1)
5039 (loclist_describe_location): Update.
5040 * dwarf2/index-write.c (write_debug_names): Update.
5041 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
5042 * dtrace-probe.c (dtrace_process_dof): Update.
5043 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
5044 (process_one_symbol): Update.
5045 * ctfread.c (ctf_init_float_type, read_base_type): Update.
5046 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
5047 (coff_read_enum_type): Update.
5048 * cli/cli-cmds.c (edit_command, list_command): Update.
5049 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
5050 * breakpoint.c (create_overlay_event_breakpoint)
5051 (create_longjmp_master_breakpoint)
5052 (create_std_terminate_master_breakpoint)
5053 (create_exception_master_breakpoint, get_sal_arch): Update.
5054 * block.c (block_gdbarch): Update.
5055 * annotate.c (annotate_source_line): Update.
5056
5057 2020-04-17 Tom Tromey <tromey@adacore.com>
5058
5059 * auto-load.c (show_auto_load_cmd): Remove.
5060 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
5061 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
5062 (maintenance_print_arc_command): Remove.
5063 * tui/tui-win.c (tui_command): Remove.
5064 (tui_get_cmd_list): Use add_basic_prefix_cmd.
5065 * tui/tui-layout.c (tui_layout_command): Remove.
5066 (_initialize_tui_layout): Use add_basic_prefix_cmd.
5067 * python/python.c (user_set_python, user_show_python): Remove.
5068 (_initialize_python): Use add_basic_prefix_cmd,
5069 add_show_prefix_cmd.
5070 * guile/guile.c (set_guile_command, show_guile_command): Remove.
5071 (install_gdb_commands): Use add_basic_prefix_cmd,
5072 add_show_prefix_cmd.
5073 (info_guile_command): Remove.
5074 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
5075 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
5076 add_show_prefix_cmd.
5077 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
5078 Remove do_set and do_show parameters.
5079 * cli/cli-style.c (set_style, show_style): Remove.
5080 (_initialize_cli_style): Use add_basic_prefix_cmd,
5081 add_show_prefix_cmd.
5082 (cli_style_option::add_setshow_commands): Remove do_set and
5083 do_show parameters.
5084 (cli_style_option::add_setshow_commands): Use
5085 add_basic_prefix_cmd, add_show_prefix_cmd.
5086 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
5087 (set_style_name): Remove.
5088 * cli/cli-dump.c (dump_command, append_command): Remove.
5089 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5090 (tekhex_dump_command, binary_dump_command)
5091 (binary_append_command): Remove.
5092 (_initialize_cli_dump): Use add_basic_prefix_cmd.
5093 * windows-tdep.c (w32_prefix_command_valid): Remove global.
5094 (init_w32_command_list): Remove; move into ...
5095 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
5096 * valprint.c (set_print, show_print, set_print_raw)
5097 (show_print_raw): Remove.
5098 (_initialize_valprint): Use add_basic_prefix_cmd,
5099 add_show_prefix_cmd.
5100 * typeprint.c (set_print_type, show_print_type): Remove.
5101 (_initialize_typeprint): Use add_basic_prefix_cmd,
5102 add_show_prefix_cmd.
5103 * record.c (set_record_command, show_record_command): Remove.
5104 (_initialize_record): Use add_basic_prefix_cmd,
5105 add_show_prefix_cmd.
5106 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
5107 add_show_prefix_cmd.
5108 (info_command, show_command, set_debug, show_debug): Remove.
5109 * top.h (set_history, show_history): Don't declare.
5110 * top.c (set_history, show_history): Remove.
5111 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5112 (unset_tdesc_cmd): Remove.
5113 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
5114 add_show_prefix_cmd.
5115 * symtab.c (info_module_command): Remove.
5116 (_initialize_symtab): Use add_basic_prefix_cmd.
5117 * symfile.c (overlay_command): Remove.
5118 (_initialize_symfile): Use add_basic_prefix_cmd.
5119 * sparc64-tdep.c (info_adi_command): Remove.
5120 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
5121 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
5122 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
5123 add_show_prefix_cmd.
5124 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
5125 (_initialize_serial): Use add_basic_prefix_cmd,
5126 add_show_prefix_cmd.
5127 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
5128 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
5129 add_show_prefix_cmd.
5130 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
5131 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
5132 add_show_prefix_cmd.
5133 * riscv-tdep.c (show_riscv_command, set_riscv_command)
5134 (show_debug_riscv_command, set_debug_riscv_command): Remove.
5135 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
5136 add_show_prefix_cmd.
5137 * remote.c (remote_command, set_remote_cmd): Remove.
5138 (_initialize_remote): Use add_basic_prefix_cmd.
5139 * record-full.c (set_record_full_command)
5140 (show_record_full_command): Remove.
5141 (_initialize_record_full): Use add_basic_prefix_cmd,
5142 add_show_prefix_cmd.
5143 * record-btrace.c (cmd_set_record_btrace)
5144 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
5145 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
5146 (cmd_show_record_btrace_pt): Remove.
5147 (_initialize_record_btrace): Use add_basic_prefix_cmd,
5148 add_show_prefix_cmd.
5149 * ravenscar-thread.c (set_ravenscar_command)
5150 (show_ravenscar_command): Remove.
5151 (_initialize_ravenscar): Use add_basic_prefix_cmd,
5152 add_show_prefix_cmd.
5153 * mips-tdep.c (show_mips_command, set_mips_command)
5154 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
5155 add_show_prefix_cmd.
5156 * maint.c (maintenance_command, maintenance_info_command)
5157 (maintenance_check_command, maintenance_print_command)
5158 (maintenance_set_cmd, maintenance_show_cmd): Remove.
5159 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
5160 add_show_prefix_cmd.
5161 (show_per_command_cmd): Remove.
5162 * maint-test-settings.c (maintenance_set_test_settings_cmd):
5163 Remove.
5164 (maintenance_show_test_settings_cmd): Remove.
5165 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
5166 add_show_prefix_cmd.
5167 * maint-test-options.c (maintenance_test_options_command):
5168 Remove.
5169 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
5170 * macrocmd.c (macro_command): Remove
5171 (_initialize_macrocmd): Use add_basic_prefix_cmd.
5172 * language.c (set_check, show_check): Remove.
5173 (_initialize_language): Use add_basic_prefix_cmd,
5174 add_show_prefix_cmd.
5175 * infcmd.c (unset_command): Remove.
5176 (_initialize_infcmd): Use add_basic_prefix_cmd.
5177 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
5178 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
5179 add_show_prefix_cmd.
5180 * go32-nat.c (go32_info_dos_command): Remove.
5181 (_initialize_go32_nat): Use add_basic_prefix_cmd.
5182 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
5183 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
5184 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
5185 (_initialize_frame): Use add_basic_prefix_cmd,
5186 add_show_prefix_cmd.
5187 * dcache.c (set_dcache_command, show_dcache_command): Remove.
5188 (_initialize_dcache): Use add_basic_prefix_cmd,
5189 add_show_prefix_cmd.
5190 * cp-support.c (maint_cplus_command): Remove.
5191 (_initialize_cp_support): Use add_basic_prefix_cmd.
5192 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5193 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5194 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
5195 add_basic_prefix_cmd, add_show_prefix_cmd.
5196 * breakpoint.c (save_command): Remove.
5197 (_initialize_breakpoint): Use add_basic_prefix_cmd.
5198 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
5199 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
5200 add_show_prefix_cmd.
5201 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
5202 (set_ada_command, show_ada_command): Remove.
5203 (_initialize_ada_language): Use add_basic_prefix_cmd,
5204 add_show_prefix_cmd.
5205 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
5206
5207 2020-04-16 Kamil Rytarowski <n54@gmx.com>
5208
5209 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
5210 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
5211
5212 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
5213
5214 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
5215 warning messages.
5216
5217 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
5218
5219 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
5220 import table is not at beginning of .idata section.
5221
5222 2020-04-16 Pedro Alves <palves@redhat.com>
5223
5224 * inferior.c (delete_inferior): Use delete operator directly
5225 instead of delete_program_space.
5226 * progspace.c (add_program_space): New, factored out from
5227 program_space::program_space.
5228 (remove_program_space): New, factored out from
5229 delete_program_space.
5230 (program_space::program_space): Remove intro comment. Rewrite.
5231 (program_space::~program_space): Remove intro comment. Call
5232 remove_program_space.
5233 (delete_program_space): Delete.
5234 * progspace.h (program_space::program_space): Make explicit. Move
5235 intro comment here, adjusted.
5236 (program_space::~program_space): Move intro comment here,
5237 adjusted.
5238 (delete_program_space): Remove.
5239
5240 2020-04-16 Tom Tromey <tromey@adacore.com>
5241
5242 * windows-nat.c (windows_nat::handle_access_violation): New
5243 function.
5244 * nat/windows-nat.h (handle_access_violation): Declare.
5245 * nat/windows-nat.c (handle_exception): Move Cygwin code to
5246 windows-nat.c. Call handle_access_violation.
5247
5248 2020-04-16 Tom de Vries <tdevries@suse.de>
5249
5250 PR symtab/25791
5251 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
5252 CUs without psymtab.
5253
5254 2020-04-16 Kevin Buettner <kevinb@redhat.com>
5255
5256 * python/python.c (do_start_initialization): Don't call
5257 PyEval_InitThreads for Python 3.9 and beyond.
5258
5259 2020-04-15 Kamil Rytarowski <n54@gmx.com>
5260
5261 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
5262 thread functions.
5263 (obsd_nat_target::wait): Likewise.
5264
5265 2020-04-15 Tom Tromey <tromey@adacore.com>
5266
5267 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
5268 (DEBUG_EXCEPT): Use debug_printf.
5269
5270 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
5271
5272 * completer.c (class completion_tracker::completion_hash_entry)
5273 <hash_name>: New member function.
5274 (completion_tracker::discard_completions): New callback to hash a
5275 completion_hash_entry, pass this to htab_create_alloc.
5276
5277 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
5278
5279 * windows-nat.c (windows_make_so): Warn rather than stopping with
5280 an error if realpath() fails.
5281
5282 2020-04-14 Kamil Rytarowski <n54@gmx.com>
5283
5284 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
5285 (nbsd_nat_target::info_proc): Add do_status.
5286
5287 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
5288 Tom de Vries <tdevries@suse.de>
5289
5290 PR symtab/25718
5291 * psympriv.h (struct partial_symtab::read_symtab)
5292 (struct partial_symtab::expand_psymtab)
5293 (struct partial_symtab::read_dependencies): Update comments.
5294 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
5295 read_symtab for includer.
5296 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
5297 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
5298 (struct dwarf2_include_psymtab::m_readin): Remove.
5299 (struct dwarf2_include_psymtab::includer): New member function.
5300 (dwarf2_psymtab::expand_psymtab): Assert !readin.
5301
5302 2020-04-14 Tom de Vries <tdevries@suse.de>
5303
5304 PR symtab/25720
5305 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
5306 with NULL symbol_matcher and lookup_name.
5307 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
5308 and lookup_name.
5309 * dwarf2/read.c (dw2_expand_symtabs_matching)
5310 (dw2_debug_names_expand_symtabs_matching): Same.
5311 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
5312 Make lookup_name a pointer. Update comment.
5313 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
5314 lookup_name being a pointer.
5315 * symfile.c (expand_symtabs_matching): Same.
5316 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
5317 * linespec.c (iterate_over_all_matching_symtabs): Same.
5318
5319 2020-04-13 Tom Tromey <tom@tromey.com>
5320
5321 * run-on-main-thread.c: Update include.
5322 * unittests/main-thread-selftests.c: Update include.
5323 * tui/tui-win.c: Update include.
5324 * tui/tui-io.c: Update include.
5325 * tui/tui-interp.c: Update include.
5326 * tui/tui-hooks.c: Update include.
5327 * top.h: Update include.
5328 * top.c: Update include.
5329 * ser-base.c: Update include.
5330 * remote.c: Update include.
5331 * remote-notif.c: Update include.
5332 * remote-fileio.c: Update include.
5333 * record-full.c: Update include.
5334 * record-btrace.c: Update include.
5335 * python/python.c: Update include.
5336 * posix-hdep.c: Update include.
5337 * mingw-hdep.c: Update include.
5338 * mi/mi-main.c: Update include.
5339 * mi/mi-interp.c: Update include.
5340 * main.c: Update include.
5341 * linux-nat.c: Update include.
5342 * interps.c: Update include.
5343 * infrun.c: Update include.
5344 * inf-loop.c: Update include.
5345 * event-top.c: Update include.
5346 * event-loop.c: Move to ../gdbsupport/.
5347 * event-loop.h: Move to ../gdbsupport/.
5348 * async-event.h: Update include.
5349 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
5350
5351 2020-04-13 Tom Tromey <tom@tromey.com>
5352
5353 * tui/tui-win.c: Include async-event.h.
5354 * remote.c: Include async-event.h.
5355 * remote-notif.c: Include async-event.h.
5356 * record-full.c: Include async-event.h.
5357 * record-btrace.c: Include async-event.h.
5358 * infrun.c: Include async-event.h.
5359 * event-top.c: Include async-event.h.
5360 * event-loop.h: Move some declarations to async-event.h.
5361 * event-loop.c: Don't include ser-event.h or top.h. Move some
5362 code to async-event.c.
5363 * async-event.h: New file.
5364 * async-event.c: New file.
5365 * Makefile.in (COMMON_SFILES): Add async-event.c.
5366 (HFILES_NO_SRCDIR): Add async-event.h.
5367
5368 2020-04-13 Tom Tromey <tom@tromey.com>
5369
5370 * utils.c (flush_streams): New function.
5371 * event-loop.c (gdb_wait_for_event): Call flush_streams.
5372
5373 2020-04-13 Tom Tromey <tom@tromey.com>
5374
5375 * event-loop.c (handle_file_event): Use warning, not
5376 printf_unfiltered.
5377
5378 2020-04-13 Tom Tromey <tom@tromey.com>
5379
5380 * event-loop.c: Include <chrono>.
5381
5382 2020-04-13 Tom Tromey <tom@tromey.com>
5383
5384 * gdb_select.h: Move to ../gdbsupport/.
5385 * event-loop.c: Update include path.
5386 * top.c: Update include path.
5387 * ser-base.c: Update include path.
5388 * ui-file.c: Update include path.
5389 * ser-tcp.c: Update include path.
5390 * guile/scm-ports.c: Update include path.
5391 * posix-hdep.c: Update include path.
5392 * ser-unix.c: Update include path.
5393 * gdb_usleep.c: Update include path.
5394 * mingw-hdep.c: Update include path.
5395 * inflow.c: Update include path.
5396 * infrun.c: Update include path.
5397 * event-top.c: Update include path.
5398
5399 2020-04-13 Tom Tromey <tom@tromey.com>
5400
5401 * configure: Rebuild.
5402 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
5403
5404 2020-04-13 Tom Tromey <tom@tromey.com>
5405
5406 * event-loop.h (start_event_loop): Don't declare.
5407 * event-loop.c (start_event_loop): Move...
5408 * main.c (start_event_loop): ...here. Now static.
5409
5410 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
5411
5412 * MAINTAINERS: Update my email address.
5413
5414 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5415
5416 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
5417 IP_ALL.
5418
5419 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5420
5421 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
5422 (nbsd_nat_target::info_proc): Add do_cmdline.
5423
5424 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5425
5426 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
5427 (nbsd_nat_target::info_proc): Add do_cwd.
5428
5429 2020-04-12 Kamil Rytarowski <n54@gmx.com>
5430
5431 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
5432
5433 2020-04-11 Kamil Rytarowski <n54@gmx.com>
5434
5435 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
5436 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
5437 (nbsd_nat_target::info_proc): New functions.
5438 * nbsd-nat.c (kinfo_get_vmmap): New function.
5439 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
5440 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
5441 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
5442 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
5443 functions.
5444 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
5445 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
5446 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
5447 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
5448 (KINFO_VME_FLAG_GROWS_DOWN): New.
5449
5450 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
5451
5452 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
5453 bit shift.
5454
5455 2020-04-10 Tom Tromey <tromey@adacore.com>
5456
5457 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
5458
5459 2020-04-10 Tom Tromey <tromey@adacore.com>
5460
5461 * symtab.c (get_symbol_address, get_msymbol_address): Skip
5462 separate debug files.
5463
5464 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
5465
5466 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5467 Move to...
5468 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
5469 ... here.
5470 * windows-nat.c (windows_nat_target::get_windows_debug_event):
5471 Check for STATUS_WX86_BREAKPOINT.
5472 (windows_nat_target::wait): Same.
5473
5474 2020-04-10 Tom de Vries <tdevries@suse.de>
5475
5476 PR cli/25808
5477 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
5478
5479 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
5480
5481 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
5482 (Write After Approval): Remove Tom de Vries.
5483
5484 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
5485
5486 revert partially:
5487 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5488
5489 * buildsym.c (record_line): Fix undefined behavior and preserve
5490 lines at eof.
5491
5492 2020-04-09 Kamil Rytarowski <n54@gmx.com>
5493
5494 * auxv.h (svr4_auxv_parse): New.
5495 * auxv.c (default_auxv_parse): Split into default_auxv_parse
5496 and generic_auxv_parse.
5497 (svr4_auxv_parse): Add.
5498 * obsd-tdep.c: Include "auxv.h".
5499 (obsd_auxv_parse): Remove.
5500 (obsd_init_abi): Remove comment.
5501 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
5502 from `obsd_auxv_parse' to `svr4_auxv_parse'.
5503 * nbsd-tdep.c: Include "auxv.h".
5504 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
5505
5506 2020-04-08 Tom Tromey <tromey@adacore.com>
5507
5508 * nat/windows-nat.h (last_wait_event): Don't declare.
5509 (wait_for_debug_event): Update comment.
5510 * nat/windows-nat.c (last_wait_event): Now static.
5511
5512 2020-04-08 Tom Tromey <tromey@adacore.com>
5513
5514 * windows-nat.c (wait_for_debug_event): Move to
5515 nat/windows-nat.c.
5516 * nat/windows-nat.h (wait_for_debug_event): Declare.
5517 * nat/windows-nat.c (wait_for_debug_event): Move from
5518 windows-nat.c. No longer static.
5519
5520 2020-04-08 Tom Tromey <tromey@adacore.com>
5521
5522 * windows-nat.c (get_windows_debug_event): Use
5523 fetch_pending_stop.
5524 * nat/windows-nat.h (fetch_pending_stop): Declare.
5525 * nat/windows-nat.c (fetch_pending_stop): New function.
5526
5527 2020-04-08 Tom Tromey <tromey@adacore.com>
5528
5529 * windows-nat.c (windows_continue): Use matching_pending_stop and
5530 continue_last_debug_event.
5531 * nat/windows-nat.h (matching_pending_stop)
5532 (continue_last_debug_event): Declare.
5533 * nat/windows-nat.c (DEBUG_EVENTS): New define.
5534 (matching_pending_stop, continue_last_debug_event): New
5535 functions.
5536
5537 2020-04-08 Tom Tromey <tromey@adacore.com>
5538
5539 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
5540 (handle_exception_result): Move to nat/windows-nat.h.
5541 (DEBUG_EXCEPTION_SIMPLE): Remove.
5542 (windows_nat::handle_ms_vc_exception): New function.
5543 (handle_exception): Move to nat/windows-nat.c.
5544 (get_windows_debug_event): Update.
5545 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
5546 nat/windows-nat.c.
5547 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
5548 (handle_exception_result): Move from windows-nat.c.
5549 (handle_exception): Declare.
5550 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
5551 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
5552 windows-nat.c.
5553
5554 2020-04-08 Tom Tromey <tromey@adacore.com>
5555
5556 * windows-nat.c (exception_count, event_count): Remove.
5557 (handle_exception, get_windows_debug_event)
5558 (do_initial_windows_stuff): Update.
5559
5560 2020-04-08 Tom Tromey <tromey@adacore.com>
5561
5562 * windows-nat.c (windows_nat::handle_load_dll)
5563 (windows_nat::handle_unload_dll): Rename. No longer static.
5564 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
5565 Declare.
5566
5567 2020-04-08 Tom Tromey <tromey@adacore.com>
5568
5569 * complaints.h (stop_whining): Declare at top-level.
5570 (complaint): Don't declare stop_whining.
5571
5572 2020-04-08 Tom Tromey <tromey@adacore.com>
5573
5574 * windows-nat.c (windows_nat::handle_output_debug_string):
5575 Rename. No longer static.
5576 * nat/windows-nat.h (handle_output_debug_string): Declare.
5577
5578 2020-04-08 Tom Tromey <tromey@adacore.com>
5579
5580 * windows-nat.c (current_process_handle, current_process_id)
5581 (main_thread_id, last_sig, current_event, last_wait_event)
5582 (current_windows_thread, desired_stop_thread_id, pending_stops)
5583 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
5584 (display_selectors, fake_create_process)
5585 (get_windows_debug_event): Update.
5586 * nat/windows-nat.h (current_process_handle, current_process_id)
5587 (main_thread_id, last_sig, current_event, last_wait_event)
5588 (current_windows_thread, desired_stop_thread_id, pending_stops)
5589 (struct pending_stop, siginfo_er): Move from windows-nat.c.
5590 * nat/windows-nat.c (current_process_handle, current_process_id)
5591 (main_thread_id, last_sig, current_event, last_wait_event)
5592 (current_windows_thread, desired_stop_thread_id, pending_stops)
5593 (siginfo_er): New globals. Move from windows-nat.c.
5594
5595 2020-04-08 Tom Tromey <tromey@adacore.com>
5596
5597 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
5598 (handle_load_dll): Update.
5599 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
5600
5601 2020-04-08 Tom Tromey <tromey@adacore.com>
5602
5603 * windows-nat.c (enum thread_disposition_type): Move to
5604 nat/windows-nat.h.
5605 (windows_nat::thread_rec): Rename from thread_rec. No longer
5606 static.
5607 (windows_add_thread, windows_nat_target::fetch_registers)
5608 (windows_nat_target::store_registers, handle_exception)
5609 (windows_nat_target::resume, get_windows_debug_event)
5610 (windows_nat_target::get_tib_address)
5611 (windows_nat_target::thread_name)
5612 (windows_nat_target::thread_alive): Update.
5613 * nat/windows-nat.h (enum thread_disposition_type): Move from
5614 windows-nat.c.
5615 (thread_rec): Declare.
5616
5617 2020-04-08 Tom Tromey <tromey@adacore.com>
5618
5619 * windows-nat.c: Add "using namespace".
5620 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
5621 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
5622
5623 2020-04-08 Tom Tromey <tromey@adacore.com>
5624
5625 * nat/windows-nat.h (struct windows_thread_info): Declare
5626 destructor.
5627 * nat/windows-nat.c (~windows_thread_info): New.
5628
5629 2020-04-08 Tom Tromey <tromey@adacore.com>
5630
5631 PR gdb/22992
5632 * windows-nat.c (current_event): Update comment.
5633 (last_wait_event, desired_stop_thread_id): New globals.
5634 (struct pending_stop): New.
5635 (pending_stops): New global.
5636 (windows_nat_target) <stopped_by_sw_breakpoint>
5637 <supports_stopped_by_sw_breakpoint>: New methods.
5638 (windows_fetch_one_register): Add assertions. Adjust PC.
5639 (windows_continue): Handle pending stops. Suspend other threads
5640 when stepping. Use last_wait_event
5641 (wait_for_debug_event): New function.
5642 (get_windows_debug_event): Use wait_for_debug_event. Handle
5643 pending stops. Queue spurious stops.
5644 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
5645 (windows_nat_target::kill): Use wait_for_debug_event.
5646 * nat/windows-nat.h (struct windows_thread_info)
5647 <stopped_at_software_breakpoint>: New field.
5648 * nat/windows-nat.c (windows_thread_info::resume): Clear
5649 stopped_at_software_breakpoint.
5650
5651 2020-04-08 Tom Tromey <tromey@adacore.com>
5652
5653 * windows-nat.c (enum thread_disposition_type): New.
5654 (thread_rec): Replace "get_context" parameter with "disposition";
5655 change type.
5656 (windows_add_thread, windows_nat_target::fetch_registers)
5657 (windows_nat_target::store_registers, handle_exception)
5658 (windows_nat_target::resume, get_windows_debug_event)
5659 (windows_nat_target::get_tib_address)
5660 (windows_nat_target::thread_name)
5661 (windows_nat_target::thread_alive): Update.
5662
5663 2020-04-08 Tom Tromey <tromey@adacore.com>
5664
5665 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
5666 (windows_continue): Use windows_continue::resume.
5667 * nat/windows-nat.h (struct windows_thread_info) <suspend,
5668 resume>: Declare new methods.
5669 * nat/windows-nat.c: New file.
5670 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
5671
5672 2020-04-08 Tom Tromey <tromey@adacore.com>
5673
5674 * windows-nat.c (windows_add_thread, windows_delete_thread)
5675 (windows_nat_target::fetch_registers)
5676 (windows_nat_target::store_registers, fake_create_process)
5677 (windows_nat_target::resume, windows_nat_target::resume)
5678 (get_windows_debug_event, windows_nat_target::wait)
5679 (windows_nat_target::pid_to_str)
5680 (windows_nat_target::get_tib_address)
5681 (windows_nat_target::get_ada_task_ptid)
5682 (windows_nat_target::thread_name)
5683 (windows_nat_target::thread_alive): Use lwp, not tid.
5684
5685 2020-04-08 Tom Tromey <tromey@adacore.com>
5686
5687 * windows-nat.c (handle_exception)
5688 (windows_nat_target::thread_name): Update.
5689 * nat/windows-nat.h (windows_thread_info): Remove destructor.
5690 <name>: Now unique_xmalloc_ptr.
5691
5692 2020-04-08 Tom Tromey <tromey@adacore.com>
5693
5694 * windows-nat.c (thread_rec)
5695 (windows_nat_target::fetch_registers): Update.
5696 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
5697 Update comment.
5698 <debug_registers_changed, reload_context>: Now bool.
5699
5700 2020-04-08 Tom Tromey <tromey@adacore.com>
5701
5702 * windows-nat.c (windows_add_thread): Use new.
5703 (windows_init_thread_list, windows_delete_thread): Use delete.
5704 (get_windows_debug_event): Update.
5705 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
5706 destructor, and initializers.
5707
5708 2020-04-08 Tom Tromey <tromey@adacore.com>
5709
5710 * windows-nat.c (struct windows_thread_info): Remove.
5711 * nat/windows-nat.h: New file.
5712
5713 2020-04-08 Tom Tromey <tromey@adacore.com>
5714
5715 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
5716 (thread_rec, windows_add_thread, windows_delete_thread)
5717 (windows_continue): Update.
5718
5719 2020-04-08 Tom Tromey <tromey@adacore.com>
5720
5721 * windows-nat.c (struct windows_thread_info): Remove typedef.
5722 (thread_head): Remove.
5723 (thread_list): New global.
5724 (thread_rec, windows_add_thread, windows_init_thread_list)
5725 (windows_delete_thread, windows_continue): Update.
5726
5727 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
5728
5729 * windows-tdep.h (windows_init_abi): Add comment.
5730 (cygwin_init_abi): New declaration.
5731 * windows-tdep.c: Split signal enumeration in two, one for
5732 Windows and one for Cygwin.
5733 (windows_gdb_signal_to_target): Only deal with signal of the
5734 Windows OS ABI.
5735 (cygwin_gdb_signal_to_target): New function.
5736 (windows_init_abi): Rename to windows_init_abi_common, don't set
5737 gdb_signal_to_target gdbarch method. Add new new function with
5738 this name.
5739 (cygwin_init_abi): New function.
5740 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
5741 comment. Don't call windows_init_abi.
5742 (amd64_windows_init_abi): Add comment, call windows_init_abi.
5743 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
5744 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
5745 i386_windows_init_abi_common, don't call windows_init_abi. Add
5746 a new function of this name.
5747 (i386_cygwin_init_abi): New function.
5748 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
5749 OS ABI Cygwin.
5750
5751 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
5752
5753 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
5754 parameter.c.
5755 (dwarf2_read_gdb_index): Update.
5756
5757 2020-04-07 Kamil Rytarowski <n54@gmx.com>
5758
5759 * nbsd-tdep.c: Include "objfiles.h".
5760 (nbsd_skip_solib_resolver): New.
5761 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
5762
5763 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5764
5765 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
5766 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
5767 with DW_LLE_base_addressx are being emitted in DWARFv5.
5768 Add the newly added kind DW_LOC_OFFSET_PAIR also.
5769 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
5770 unsigned integer.
5771
5772 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5773
5774 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
5775 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
5776 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
5777 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
5778 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
5779 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
5780 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
5781
5782
5783 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
5784
5785 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
5786 (read_loclist_index): New function definition.
5787 (lookup_loclist_base): New function definition.
5788 (read_loclist_header): New function definition.
5789 (dwarf2_cu): Add loclist_base and loclist_header field.
5790 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
5791 (read_full_die_1): Read the value of DW_AT_loclists_base.
5792 (read_attribute_reprocess): Handle DW_FORM_loclistx.
5793 (read_attribute_value): Handle DW_FORM_loclistx.
5794 (skip_one_die): Handle DW_FORM_loclistx.
5795 (loclist_header): New structure declaration.
5796 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
5797
5798 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
5799
5800 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
5801 constructor. Remove `addr` parameter from other constructor and
5802 add `per_cu` parameter.
5803 * dwarf2/read.c (create_partial_symtab): Update.
5804
5805 2020-04-07 Tom de Vries <tdevries@suse.de>
5806
5807 PR symtab/25796
5808 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
5809 (partial_die_info::fixup): Inherit has_const_value.
5810
5811 2020-04-07 Tom de Vries <tdevries@suse.de>
5812
5813 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
5814 symbols without address.
5815
5816 2020-04-06 Kamil Rytarowski <n54@gmx.com>
5817
5818 * nbsd-nat.h (struct thread_info): Add forward declaration.
5819 (nbsd_nat_target::thread_alive): Add.
5820 (nbsd_nat_target::thread_name): Likewise.
5821 (nbsd_nat_target::update_thread_list): Likewise.
5822 (update_thread_list::post_attach): Likewise.
5823 (post_attach::pid_to_str): Likewise.
5824 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
5825 (nbsd_thread_lister): Add.
5826 (nbsd_nat_target::thread_alive): Likewise.
5827 (nbsd_nat_target::thread_name): Likewise.
5828 (nbsd_add_threads): Likewise.
5829 (update_thread_list::post_attach): Likewise.
5830 (nbsd_nat_target::update_thread_list): Likewise.
5831 (post_attach::pid_to_str): Likewise.
5832
5833 2020-04-06 Tom Tromey <tromey@adacore.com>
5834
5835 * ada-valprint.c (print_variant_part): Extract the variant field.
5836 (print_field_values): Use the field as the outer value when
5837 recursing.
5838
5839 2020-04-06 Tom Tromey <tromey@adacore.com>
5840
5841 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
5842 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
5843 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
5844 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
5845 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
5846
5847 2020-04-06 Tom Tromey <tromey@adacore.com>
5848
5849 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
5850 TYPE_CODE_ERROR.
5851
5852 2020-04-06 Kamil Rytarowski <n54@gmx.com>
5853
5854 * nbsd-tdep.c: Include "gdbarch.h".
5855 Define enum with NetBSD signal numbers.
5856 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
5857 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
5858 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5859 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
5860 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
5861 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
5862 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
5863 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
5864 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
5865 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
5866 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
5867 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
5868
5869 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
5870
5871 PR gdb/25325
5872 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
5873
5874 2020-04-03 Tom Tromey <tromey@adacore.com>
5875
5876 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
5877 Read constant block.
5878
5879 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
5880
5881 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
5882 (gdb_bfd_get_full_section_contents): New declaration.
5883 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
5884 * windows-tdep.c (is_linked_with_cygwin_dll): Use
5885 gdb_bfd_get_full_section_contents.
5886
5887 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
5888
5889 * exec.c (build_section_table): Replace internal_error with
5890 gdb_assert.
5891 (section_table_xfer_memory_partial): Likewise.
5892 * mdebugread.c (parse_partial_symbols): Likewise.
5893 * psymtab.c (lookup_partial_symbol): Likewise.
5894 * utils.c (wrap_here): Likewise.
5895
5896 2020-04-02 Tom Tromey <tromey@adacore.com>
5897
5898 * f-lang.c (build_fortran_types): Use arch_type to initialize
5899 builtin_complex_s32 in the TYPE_CODE_ERROR case.
5900
5901 2020-04-02 Tom Tromey <tromey@adacore.com>
5902
5903 * dwarf2/read.c (partial_die_info::read): Do not create a vector
5904 of attributes.
5905
5906 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
5907 Bernd Edlinger <bernd.edlinger@hotmail.de>
5908 Tom Tromey <tromey@adacore.com>
5909
5910 * buildsym.c (buildsym_compunit::record_line): Remove
5911 deduplication code.
5912
5913 2020-04-02 Tom de Vries <tdevries@suse.de>
5914
5915 PR ada/24671
5916 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
5917
5918 2020-04-02 Tom de Vries <tdevries@suse.de>
5919
5920 * dwarf2/read.c (dwarf2_gdb_index_functions,
5921 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
5922 NULL.
5923 * psymtab.c (psym_lookup_global_symbol_language): New function.
5924 (psym_functions): Init psym_lookup_global_symbol_language with
5925 psym_lookup_global_symbol_language.
5926 * symfile-debug.c (debug_sym_quick_functions): Init
5927 lookup_global_symbol_language with NULL.
5928 * symfile.c (set_initial_language): Remove fixme comment.
5929 * symfile.h (struct quick_symbol_functions): Add
5930 lookup_global_symbol_language.
5931 * symtab.c (find_quick_global_symbol_language): New function.
5932 (find_main_name): Use find_quick_global_symbol_language.
5933
5934 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5935
5936 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
5937
5938 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5939
5940 * buildsym.c (record_line): Fix undefined behavior and preserve
5941 lines at eof.
5942
5943 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
5944
5945 * buildsym.c (record_line): Fix the resizing condition.
5946
5947 2020-04-01 Tom Tromey <tom@tromey.com>
5948
5949 * value.h (value_literal_complex): Add comment.
5950 * valops.c (value_literal_complex): Refer to value.h.
5951
5952 2020-04-01 Tom Tromey <tom@tromey.com>
5953
5954 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
5955 (scalar_type): New rule, from typebase.
5956 (typebase): Use scalar_type. Recognize complex types.
5957 (field_name): Handle FLOAT_KEYWORD.
5958 (ident_tokens): Add _Complex and __complex__.
5959
5960 2020-04-01 Tom Tromey <tom@tromey.com>
5961
5962 PR exp/25299:
5963 * valarith.c (promotion_type, complex_binop): New functions.
5964 (scalar_binop): Handle complex numbers. Use promotion_type.
5965 (value_pos, value_neg, value_complement): Handle complex numbers.
5966
5967 2020-04-01 Tom Tromey <tom@tromey.com>
5968
5969 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
5970 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
5971 (parse_number): Handle complex numbers.
5972
5973 2020-04-01 Tom Tromey <tom@tromey.com>
5974
5975 * c-valprint.c (c_decorations): Change complex suffix to "i".
5976
5977 2020-04-01 Tom Tromey <tom@tromey.com>
5978
5979 * valprint.c (generic_value_print_complex): Use accessors.
5980 * value.h (value_real_part, value_imaginary_part): Declare.
5981 * valops.c (value_real_part, value_imaginary_part): New
5982 functions.
5983 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
5984
5985 2020-04-01 Tom Tromey <tom@tromey.com>
5986
5987 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
5988 (read_range_type): Update.
5989 * mdebugread.c (basic_type): Update.
5990 * go-lang.c (build_go_types): Use init_complex_type.
5991 * gdbtypes.h (struct main_type) <complex_type>: New member.
5992 (init_complex_type): Update.
5993 (arch_complex_type): Don't declare.
5994 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
5995 Make name if none given. Use alloc_type_copy. Look for cached
5996 complex type.
5997 (arch_complex_type): Remove.
5998 (gdbtypes_post_init): Use init_complex_type.
5999 * f-lang.c (build_fortran_types): Use init_complex_type.
6000 * dwarf2/read.c (read_base_type): Update.
6001 * d-lang.c (build_d_types): Use init_complex_type.
6002 * ctfread.c (read_base_type): Update.
6003
6004 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6005
6006 * infrun.c (stop_all_threads): Update assertion, plus when
6007 stopping threads, take into account that we might be trying
6008 to stop an all-stop target.
6009 (stop_waiting): Call 'stop_all_threads' if there exists a
6010 non-stop target.
6011
6012 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6013
6014 * target.h (exists_non_stop_target): New function declaration.
6015 * target.c (exists_non_stop_target): New function.
6016
6017 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
6018
6019 PR gdb/24789
6020 * eval.c (is_integral_or_integral_reference): New function.
6021 (evaluate_subexp_standard): Allow integer references in
6022 pointer arithmetic.
6023
6024 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
6025
6026 * remote.c (remote_target::remote_parse_stop_reply): Remove the
6027 check for no ptid in the stop reply when the target is non-stop.
6028
6029 2020-04-01 Tom Tromey <tromey@adacore.com>
6030
6031 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
6032 "name" parameter to rvalue reference. Initialize m_name_holder.
6033 <lookup_name_info>: New overloads.
6034 <name>: Return gdb::string_view.
6035 <c_str>: New method.
6036 <make_ignore_params>: Update.
6037 <search_name_hash>: Update.
6038 <language_lookup_name>: Return const char *.
6039 <m_name>: Change type.
6040 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
6041 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
6042 (lookup_name_info::match_any): Update.
6043 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
6044 Update.
6045 * minsyms.c (linkage_name_str): Update.
6046 * language.c (default_symbol_name_matcher): Update.
6047 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
6048 Update.
6049 * ada-lang.c (ada_fold_name): Change parameter to string_view.
6050 (ada_lookup_name_info::ada_lookup_name_info): Update.
6051 (literal_symbol_name_matcher): Update.
6052
6053 2020-04-01 Tom Tromey <tromey@adacore.com>
6054
6055 * psymtab.c (psymtab_search_name): Remove function.
6056 (psym_lookup_symbol): Create search name and lookup name here.
6057 (lookup_partial_symbol): Remove "name" parameter; add
6058 lookup_name.
6059 (psym_expand_symtabs_for_function): Update.
6060
6061 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
6062
6063 PR tui/25597:
6064 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
6065
6066 2020-03-31 Tom Tromey <tromey@adacore.com>
6067
6068 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
6069 memcpy.
6070
6071 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
6072
6073 * features/riscv/32bit-csr.xml: Regenerated.
6074 * features/riscv/64bit-csr.xml: Regenerated.
6075
6076 2020-03-30 Tom Tromey <tromey@adacore.com>
6077
6078 * ada-valprint.c (print_variant_part): Update.
6079 * ada-lang.h (ada_which_variant_applies): Update.
6080 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
6081 outer_valaddr parameters; replace with "outer" value parameter.
6082 (to_fixed_variant_branch_type): Update.
6083
6084 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6085
6086 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
6087 <list>. Remove inclusion of observable.h.
6088 (PPC_DEBUG_CURRENT_VERSION): Move up define.
6089 (struct arch_lwp_info): New struct.
6090 (class ppc_linux_dreg_interface): New class.
6091 (struct ppc_linux_process_info): New struct.
6092 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
6093 <low_new_clone, low_forget_process, low_prepare_to_resume>
6094 <copy_thread_dreg_state, mark_thread_stale>
6095 <mark_debug_registers_changed, register_hw_breakpoint>
6096 <clear_hw_breakpoint, register_wp, clear_wp>
6097 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
6098 <num_memory_accesses, get_trigger_type>
6099 <create_watchpoint_request, hwdebug_point_cmp>
6100 <init_arch_lwp_info, get_arch_lwp_info>
6101 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
6102 methods.
6103 <struct ptid_hash>: New inner struct.
6104 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
6105 members.
6106 (saved_dabr_value, hwdebug_info, max_slots_number)
6107 (struct hw_break_tuple, struct thread_points, ppc_threads)
6108 (have_ptrace_hwdebug_interface)
6109 (hwdebug_find_thread_points_by_tid)
6110 (hwdebug_insert_point, hwdebug_remove_point): Remove.
6111 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
6112 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
6113 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
6114 use m_dreg_interface.
6115 (hwdebug_point_cmp): Change to...
6116 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
6117 reference arguments instead of pointers.
6118 (ppc_linux_nat_target::ranged_break_num_registers): Use
6119 m_dreg_interface.
6120 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
6121 m_dreg_interface. Call register_hw_breakpoint.
6122 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
6123 m_dreg_interface. Call clear_hw_breakpoint.
6124 (get_trigger_type): Change to...
6125 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
6126 comment.
6127 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
6128 use m_dreg_interface. Call register_hw_breakpoint.
6129 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
6130 use m_dreg_interface. Call clear_hw_breakpoint.
6131 (can_use_watchpoint_cond_accel): Change to...
6132 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
6133 method. Update comment, use m_dreg_interface and
6134 m_process_info.
6135 (calculate_dvc): Change to...
6136 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
6137 m_dreg_interface.
6138 (num_memory_accesses): Change to...
6139 (ppc_linux_nat_target::num_memory_accesses): ...this method.
6140 (check_condition): Change to...
6141 (ppc_linux_nat_target::check_condition): ...this method.
6142 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
6143 comment, use m_dreg_interface.
6144 (create_watchpoint_request): Change to...
6145 (ppc_linux_nat_target::create_watchpoint_request): ...this
6146 method. Use m_dreg_interface.
6147 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
6148 m_dreg_interface. Call register_hw_breakpoint or register_wp.
6149 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
6150 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
6151 (ppc_linux_nat_target::low_forget_process)
6152 (ppc_linux_nat_target::low_new_fork)
6153 (ppc_linux_nat_target::low_new_clone)
6154 (ppc_linux_nat_target::low_delete_thread)
6155 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
6156 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
6157 only call mark_thread_stale.
6158 (ppc_linux_thread_exit): Remove.
6159 (ppc_linux_nat_target::stopped_data_address): Change to...
6160 (ppc_linux_nat_target::low_stopped_data_address): This. Add
6161 comment, use m_dreg_interface and m_thread_hw_breakpoints.
6162 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
6163 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
6164 comment. Call low_stopped_data_address.
6165 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
6166 m_dreg_interface.
6167 (ppc_linux_nat_target::masked_watch_num_registers): Use
6168 m_dreg_interface.
6169 (ppc_linux_nat_target::copy_thread_dreg_state)
6170 (ppc_linux_nat_target::mark_thread_stale)
6171 (ppc_linux_nat_target::mark_debug_registers_changed)
6172 (ppc_linux_nat_target::register_hw_breakpoint)
6173 (ppc_linux_nat_target::clear_hw_breakpoint)
6174 (ppc_linux_nat_target::register_wp)
6175 (ppc_linux_nat_target::clear_wp)
6176 (ppc_linux_nat_target::init_arch_lwp_info)
6177 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
6178 (_initialize_ppc_linux_nat): Remove observer callback.
6179
6180 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6181
6182 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
6183 (ppc_linux_nat_target::auxv_parse)
6184 (ppc_linux_nat_target::read_description)
6185 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
6186 Move up.
6187
6188 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
6189
6190 * linux-nat.h (low_new_clone): New method.
6191 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
6192
6193 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6194
6195 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
6196 (dbx_expand_psymtab): ... this.
6197 (start_psymtab): Update.
6198 * mdebugread.c (psymtab_to_symtab_1): Rename to...
6199 (mdebug_expand_psymtab): ... this.
6200 (parse_partial_symbols): Update.
6201 (new_psymtab): Update.
6202 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
6203 (xcoff_expand_psymtab): ... this.
6204 (xcoff_start_psymtab): Update.
6205
6206 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6207
6208 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
6209 <expand_dependencies>: ... this.
6210 * psymtab.c (partial_symtab::read_dependencies): Rename to...
6211 (partial_symtab::expand_dependencies): ... this.
6212 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
6213 Update.
6214 (dwarf2_psymtab::expand_psymtab): Update.
6215 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
6216 * mdebugread.c (psymtab_to_symtab_1): Update.
6217 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
6218
6219 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
6220
6221 * psympriv.h (discard_psymtab): Remove.
6222 * dbxread.c (dbx_end_psymtab): Update.
6223 * xcoffread.c (xcoff_end_psymtab): Update.
6224
6225 2020-03-28 Tom Tromey <tom@tromey.com>
6226
6227 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
6228 comment.
6229
6230 2020-03-28 Tom Tromey <tom@tromey.com>
6231
6232 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
6233
6234 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
6235
6236 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6237
6238 2020-03-26 John Baldwin <jhb@FreeBSD.org>
6239
6240 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
6241
6242 2020-03-26 Tom Tromey <tom@tromey.com>
6243
6244 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
6245 (mark_common_block_symbol_computed, read_tag_string_type)
6246 (attr_to_dynamic_prop, read_subrange_type): Update.
6247 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
6248 to be methods on struct attribute.
6249 (skip_one_die, process_imported_unit_die, read_namespace_alias)
6250 (read_call_site_scope, partial_die_info::read)
6251 (partial_die_info::read, lookup_die_type, follow_die_ref):
6252 Update.
6253 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
6254 from dwarf2_get_ref_die_offset.
6255 (attribute::constant_value): New method, from
6256 dwarf2_get_attr_constant_value.
6257 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
6258 Declare method.
6259 <constant_value>: New method.
6260
6261 2020-03-26 Tom Tromey <tom@tromey.com>
6262
6263 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
6264 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
6265 (dwarf_type_encoding_name): Move to stringify.c.
6266 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
6267 * dwarf2/stringify.c: New file.
6268 * dwarf2/stringify.h: New file.
6269
6270 2020-03-26 Tom Tromey <tom@tromey.com>
6271
6272 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
6273 Rewrite.
6274
6275 2020-03-26 Tom Tromey <tom@tromey.com>
6276
6277 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
6278 methods.
6279 * dwarf2/read.c (lookup_addr_base): Move to die.h.
6280 (lookup_ranges_base): Likewise.
6281 (read_cutu_die_from_dwo, read_full_die_1): Update.
6282
6283 2020-03-26 Tom Tromey <tom@tromey.com>
6284
6285 * dwarf2/read.c (read_import_statement, read_file_scope)
6286 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
6287 (read_lexical_block_scope, read_call_site_scope)
6288 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
6289 (handle_struct_member_die, process_structure_scope)
6290 (update_enumeration_type_from_children)
6291 (process_enumeration_scope, read_array_type, read_common_block)
6292 (read_namespace, read_module, read_subroutine_type): Update.
6293 (sibling_die): Remove.
6294
6295 2020-03-26 Tom Tromey <tom@tromey.com>
6296
6297 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
6298 (build_type_psymtabs_reader, read_structure_type)
6299 (read_enumeration_type, read_full_die_1): Update.
6300 (dwarf2_attr_no_follow): Move to die.h.
6301 * dwarf2/die.h (struct die_info) <attr>: New method.
6302
6303 2020-03-26 Tom Tromey <tom@tromey.com>
6304
6305 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
6306 <base_address>: Now an optional.
6307 (dwarf2_find_base_address, dwarf2_rnglists_process)
6308 (dwarf2_ranges_process, fill_in_loclist_baton)
6309 (dwarf2_symbol_mark_computed): Update.
6310
6311 2020-03-26 Tom Tromey <tom@tromey.com>
6312
6313 * dwarf2/read.c (struct die_info): Move to die.h.
6314 * dwarf2/die.h: New file.
6315
6316 2020-03-26 Tom Tromey <tom@tromey.com>
6317
6318 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
6319 * dwarf2/read.c
6320 (dwarf2_statement_list_fits_in_line_number_section_complaint):
6321 Move to line-header.c.
6322 (read_checked_initial_length_and_offset, read_formatted_entries):
6323 Likewise.
6324 (dwarf_decode_line_header): Split into two.
6325 * dwarf2/line-header.c
6326 (dwarf2_statement_list_fits_in_line_number_section_complaint):
6327 Move from read.c.
6328 (read_checked_initial_length_and_offset, read_formatted_entries):
6329 Likewise.
6330 (dwarf_decode_line_header): New function, split from read.c.
6331
6332 2020-03-26 Tom Tromey <tom@tromey.com>
6333
6334 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
6335 Declare method.
6336 * dwarf2/read.c (read_attribute_value): Update.
6337 (dwarf2_per_objfile::read_line_string): Rename from
6338 read_indirect_line_string.
6339 (read_formatted_entries): Update.
6340
6341 2020-03-26 Tom Tromey <tom@tromey.com>
6342
6343 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
6344 variable.
6345
6346 2020-03-26 Tom Tromey <tom@tromey.com>
6347
6348 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
6349 const.
6350 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
6351 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
6352 parameter const.
6353
6354 2020-03-26 Tom Tromey <tom@tromey.com>
6355
6356 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
6357 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
6358 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
6359 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
6360
6361 2020-03-26 Tom Tromey <tom@tromey.com>
6362
6363 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
6364 file_names_size, file_full_name, file_file_name>: Use const.
6365 <file_name_at, file_names>: Add const overload.
6366 * dwarf2/line-header.c (line_header::file_file_name)
6367 (line_header::file_full_name): Update.
6368
6369 2020-03-26 Tom Tromey <tom@tromey.com>
6370
6371 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
6372 (macro_start_file, consume_improper_spaces)
6373 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
6374 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
6375 (dwarf_decode_macros): Move to macro.c.
6376 * dwarf2/macro.c: New file.
6377 * dwarf2/macro.h: New file.
6378 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
6379
6380 2020-03-26 Tom Tromey <tom@tromey.com>
6381
6382 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
6383 method.
6384 * dwarf2/section.c: New method. From
6385 read_indirect_string_at_offset_from.
6386 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
6387 (read_indirect_string_at_offset_from): Move to section.c.
6388 (read_indirect_string_at_offset): Rewrite.
6389 (read_indirect_line_string_at_offset): Remove.
6390 (read_indirect_string, read_indirect_line_string)
6391 (dwarf_decode_macro_bytes): Update.
6392
6393 2020-03-26 Tom Tromey <tom@tromey.com>
6394
6395 * dwarf2/section.h (struct dwarf2_section_info)
6396 <overload_complaint>: Declare.
6397 (dwarf2_section_buffer_overflow_complaint): Don't declare.
6398 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
6399 Rename from dwarf2_section_buffer_overflow_complaint.
6400 * dwarf2/read.c (skip_one_die, partial_die_info::read)
6401 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
6402
6403 2020-03-26 Tom Tromey <tom@tromey.com>
6404
6405 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
6406 Declare.
6407 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
6408 Move from read.c.
6409 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
6410 to section.c.
6411
6412 2020-03-26 Tom Tromey <tom@tromey.com>
6413
6414 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
6415
6416 2020-03-26 Tom Tromey <tom@tromey.com>
6417
6418 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
6419 "builder".
6420 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
6421 parameter.
6422 (dwarf_decode_macros): Update.
6423
6424 2020-03-26 Tom Tromey <tom@tromey.com>
6425
6426 * dwarf2/read.c (read_attribute_value): Update.
6427 (read_indirect_string_from_dwz): Move to dwz.c; change into
6428 method.
6429 (dwarf_decode_macro_bytes): Update.
6430 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
6431 * dwarf2/dwz.c: New file.
6432 * Makefile.in (COMMON_SFILES): Add dwz.c.
6433
6434 2020-03-26 Tom Tromey <tom@tromey.com>
6435
6436 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
6437 * dwarf2/read.c: Add include.
6438 * dwarf2/index-write.c: Add include.
6439 * dwarf2/index-cache.c: Add include.
6440 * dwarf2/dwz.h: New file.
6441
6442 2020-03-25 Tom Tromey <tom@tromey.com>
6443
6444 * compile/compile-object-load.c (get_out_value_type): Mention
6445 correct symbol name in error message.
6446
6447 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
6448
6449 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
6450
6451 2020-03-25 Tom de Vries <tdevries@suse.de>
6452
6453 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
6454 * symmisc.c (dump_symtab_1): Print user and includes fields.
6455 (maintenance_info_symtabs): Same.
6456
6457 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
6458
6459 PR gdb/25534
6460 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
6461 (riscv_regcache_cooked_write): New function.
6462 (riscv_push_dummy_call): Use new function.
6463 (riscv_return_value): Likewise.
6464
6465 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
6466
6467 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
6468 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
6469 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
6470 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
6471 * infrun.c (follow_fork): Likewise.
6472 (follow_fork_inferior): Likewise.
6473 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
6474 * linux-nat.h (class linux_nat_target): Likewise.
6475 * remote.c (class remote_target) <follow_fork>: Likewise.
6476 (remote_target::follow_fork): Likewise.
6477 * target-delegates.c: Re-generate.
6478 * target.c (default_follow_fork): Likewise.
6479 (target_follow_fork): Likewise.
6480 * target.h (struct target_ops) <follow_fork>: Likewise.
6481 (target_follow_fork): Likewise.
6482
6483 2020-03-24 Tom de Vries <tdevries@suse.de>
6484
6485 * psymtab.c (maintenance_info_psymtabs): Print user field.
6486
6487 2020-03-20 Tom Tromey <tromey@adacore.com>
6488
6489 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
6490 const.
6491 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
6492 const.
6493
6494 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
6495
6496 * ptrace.m4: Don't check for ptrace declaration.
6497 * config.in: Re-generate.
6498 * configure: Re-generate.
6499 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
6500 not defined.
6501
6502 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6503
6504 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
6505 `PTRACE_TYPE_RET'.
6506 * i386-bsd-nat.c (gdb_ptrace): Likewise.
6507 * sparc-nat.c (gdb_ptrace): Likewise.
6508 * x86-bsd-nat.c (gdb_ptrace): Likewise.
6509
6510 2020-03-20 Tom Tromey <tromey@adacore.com>
6511
6512 * c-exp.y (lex_one_token): Fix assert.
6513
6514 2020-03-20 Tom Tromey <tromey@adacore.com>
6515
6516 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
6517 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
6518 strncpy call.
6519
6520 2020-03-20 Tom Tromey <tromey@adacore.com>
6521
6522 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
6523
6524 2020-03-20 Tom Tromey <tromey@adacore.com>
6525
6526 * ada-valprint.c (print_variant_part): Remove parameters; switch
6527 to value-based API.
6528 (print_field_values): Likewise.
6529 (ada_val_print_struct_union): Likewise.
6530 (ada_value_print_1): Update.
6531
6532 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6533
6534 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
6535 nbsd_nat_target instead of inf_ptrace_target.
6536 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6537 nbsd_nat_target.
6538
6539 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6540
6541 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
6542 it to the ptrace call.
6543 * (store_registers): Likewise.
6544
6545 2020-03-20 Kamil Rytarowski <n54@gmx.com>
6546
6547 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
6548 it to the ptrace call.
6549 * (store_registers): Likewise.
6550
6551 2020-03-19 Luis Machado <luis.machado@linaro.org>
6552
6553 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
6554 valid, fetch vg value from ptrace.
6555
6556 2020-03-19 Kamil Rytarowski <n54@gmx.com>
6557 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
6558 * inf-ptrace.c: Likewise.
6559 * (gdb_ptrace): Add.
6560 * (inf_ptrace_target::resume): Update.
6561 * (inf_ptrace_target::xfer_partial): Likewise.
6562 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
6563 * (inf_ptrace_peek_poke): Update.
6564
6565 2020-03-19 Kamil Rytarowski <n54@gmx.com>
6566
6567 * x86-bsd-nat.c (gdb_ptrace): New.
6568 * (x86bsd_dr_set): Add new argument `ptid'.
6569 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
6570 x86bsd_dr_set_addr): Update.
6571
6572 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6573
6574 * remote.c (remote_target::process_stop_reply): Handle events for
6575 all threads differently.
6576
6577 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6578
6579 * completer.c (completion_tracker::remove_completion): Define new
6580 function.
6581 * completer.h (completion_tracker::remove_completion): Declare new
6582 function.
6583 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
6584 when adding a C++ function symbol.
6585
6586 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
6587
6588 * completer.c (completion_tracker::completion_hash_entry): Define
6589 new class.
6590 (advance_to_filename_complete_word_point): Call
6591 recompute_lowest_common_denominator.
6592 (completion_tracker::completion_tracker): Call discard_completions
6593 to setup the hash table.
6594 (completion_tracker::discard_completions): Allow for being called
6595 from the constructor, pass new equal function, and element deleter
6596 when constructing the hash table. Initialise new class member
6597 variables.
6598 (completion_tracker::maybe_add_completion): Remove use of
6599 m_entries_vec, and store more information into m_entries_hash.
6600 (completion_tracker::recompute_lcd_visitor): New function, most
6601 content taken from...
6602 (completion_tracker::recompute_lowest_common_denominator):
6603 ...here, this now just visits each item in the hash calling the
6604 above visitor.
6605 (completion_tracker::build_completion_result): Remove use of
6606 m_entries_vec, call recompute_lowest_common_denominator.
6607 * completer.h (completion_tracker::have_completions): Remove use
6608 of m_entries_vec.
6609 (completion_tracker::completion_hash_entry): Declare new class.
6610 (completion_tracker::recompute_lowest_common_denominator): Change
6611 function signature.
6612 (completion_tracker::recompute_lcd_visitor): Declare new function.
6613 (completion_tracker::m_entries_vec): Delete.
6614 (completion_tracker::m_entries_hash): Initialize to NULL.
6615 (completion_tracker::m_lowest_common_denominator_valid): New
6616 member variable.
6617 (completion_tracker::m_lowest_common_denominator_max_length): New
6618 member variable.
6619
6620 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6621
6622 * regformats/regdef.h: Put reg in gdb namespace.
6623
6624 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6625
6626 * i386-bsd-nat.c (gdb_ptrace): New.
6627 * (i386bsd_fetch_inferior_registers,
6628 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
6629 * (i386bsd_fetch_inferior_registers,
6630 i386bsd_store_inferior_registers) Use gdb_ptrace.
6631
6632 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6633
6634 * amd64-bsd-nat.c (gdb_ptrace): New.
6635 * (amd64bsd_fetch_inferior_registers,
6636 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
6637 * (amd64bsd_fetch_inferior_registers,
6638 amd64bsd_store_inferior_registers) Use gdb_ptrace.
6639
6640 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6641
6642 * user-regs.c (user_reg::read): Rename to...
6643 (user_reg::xread): ...this.
6644 * (append_user_reg): Rename argument `read' to `xread'.
6645 * (user_reg_add_builtin): Likewise.
6646 * (user_reg_add): Likewise.
6647 * (value_of_user_reg): Likewise.
6648
6649 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6650
6651 * sparc-nat.c (gdb_ptrace): New.
6652 * sparc-nat.c (sparc_fetch_inferior_registers)
6653 (sparc_store_inferior_registers) Remove obsolete comment.
6654 * sparc-nat.c (sparc_fetch_inferior_registers)
6655 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
6656 * sparc-nat.c (sparc_fetch_inferior_registers)
6657 (sparc_store_inferior_registers) Use gdb_ptrace.
6658
6659 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6660
6661 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
6662 it to the ptrace call.
6663 * sh-nbsd-nat.c (store_registers): Likewise.
6664
6665 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6666
6667 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
6668 nbsd_nat_target instead of inf_ptrace_target.
6669 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6670 nbsd_nat_target.
6671
6672 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6673
6674 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
6675
6676 2020-03-17 Kamil Rytarowski <n54@gmx.com>
6677
6678 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
6679 <sys/sysctl.h>.
6680 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
6681
6682 2020-03-17 Tom de Vries <tdevries@suse.de>
6683
6684 PR gdb/23710
6685 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
6686 fields.
6687 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
6688 fields.
6689 (process_imported_unit_die): Skip import of c++ CUs.
6690
6691 2020-03-16 Tom Tromey <tom@tromey.com>
6692
6693 * p-valprint.c (pascal_object_print_value): Initialize
6694 base_value.
6695
6696 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
6697 Shahab Vahedi <shahab@synopsys.com>
6698
6699 * Makefile.in: Add arch/arc.o
6700 * configure.tgt: Likewise.
6701 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
6702 (_initialize_arc_tdep): Don't initialize old target descriptions.
6703 (arc_read_description): New function to cache target descriptions.
6704 * arc-tdep.h (arc_read_description): Add proto type.
6705 * arch/arc.c: New file.
6706 * arch/arc.h: Likewise.
6707 * features/Makefile: Replace old target descriptions with new.
6708 * features/arc-arcompact.c: Remove.
6709 * features/arc-arcompact.xml: Likewise.
6710 * features/arc-v2.c: Likewise
6711 * features/arc-v2.xml: Likewise
6712 * features/arc/aux-arcompact.xml: New file.
6713 * features/arc/aux-v2.xml: Likewise.
6714 * features/arc/core-arcompact.xml: Likewise.
6715 * features/arc/core-v2.xml: Likewise.
6716 * features/arc/aux-arcompact.c: Generate.
6717 * features/arc/aux-v2.c: Likewise.
6718 * features/arc/core-arcompact.c: Likewise.
6719 * features/arc/core-v2.c: Likewise.
6720 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
6721
6722 2020-03-16 Tom Tromey <tromey@adacore.com>
6723
6724 PR gdb/25663:
6725 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
6726 putting value into bcache.
6727
6728 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6729
6730 PR gdb/21500
6731 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
6732 to...
6733 (amd64_windows_init_abi_common): ... this. Don't set size of
6734 long type.
6735 (amd64_windows_init_abi): New function.
6736 (amd64_cygwin_init_abi): New function.
6737 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
6738 the Cygwin OS ABI.
6739 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
6740 comment.
6741
6742 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6743
6744 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
6745 * windows-tdep.c (CYGWIN_DLL_NAME): New.
6746 (pe_import_directory_entry): New struct type.
6747 (is_linked_with_cygwin_dll): New function.
6748 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
6749 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
6750 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
6751
6752 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6753
6754 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
6755 i386_cygwin_core_osabi_sniffer.
6756
6757 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6758
6759 * i386-cygwin-tdep.c: Rename to...
6760 * i386-windows-tdep.c: ... this.
6761 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
6762 i386-windows-tdep.c.
6763 * configure.tgt: Likewise.
6764
6765 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6766
6767 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
6768 * osabi.c (gdb_osabi_names): Add "Windows".
6769 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
6770 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
6771 (i386_cygwin_core_osabi_sniffer): New function, extracted from
6772 i386_cygwin_osabi_sniffer.
6773 (_initialize_i386_cygwin_tdep): Register OS ABI
6774 GDB_OSABI_WINDOWS for i386.
6775 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
6776 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
6777 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
6778 for x86-64.
6779 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
6780 when the target matches '*-*-mingw*'.
6781
6782 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6783
6784 * defs.h (enum gdb_osabi): Move to...
6785 * osabi.h (enum gdb_osabi): ... here.
6786 * gdbarch.sh: Include osabi.h in gdbarch.h.
6787 * gdbarch.h: Re-generate.
6788
6789 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
6790
6791 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
6792 function.
6793 (_initialize_amd64_windows_tdep): Register osabi sniffer.
6794
6795 2020-03-14 Tom Tromey <tom@tromey.com>
6796
6797 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
6798 for C++.
6799 (c_type_print_modifier): Likewise. Add "language" parameter.
6800 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
6801 (c_type_print_base_1): Update.
6802 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
6803 constants.
6804 * type-stack.c (type_stack::insert): Handle tp_atomic and
6805 tp_restrict.
6806 (type_stack::follow_type_instance_flags): Likewise.
6807 (type_stack::follow_types): Likewise. Merge type-following code.
6808 * c-exp.y (RESTRICT, ATOMIC): New tokens.
6809 (space_identifier, cv_with_space_id)
6810 (const_or_volatile_or_space_identifier_noopt)
6811 (const_or_volatile_or_space_identifier): Remove.
6812 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
6813 rules.
6814 (ptr_operator, typebase): Update.
6815 (enum token_flag) <FLAG_C>: New constant.
6816 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
6817 "_Atomic".
6818 (lex_one_token): Handle FLAG_C.
6819
6820 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6821
6822 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
6823 it to the ptrace call.
6824 * m68k-bsd-nat.c (store_registers): Likewise.
6825
6826 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6827
6828 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
6829 gdb_byte *.
6830 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
6831 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
6832 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
6833
6834 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6835
6836 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
6837 nbsd_nat_target instead of inf_ptrace_target.
6838 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6839 nbsd_nat_target.
6840
6841 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6842
6843 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
6844 register_t.
6845
6846 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6847
6848 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
6849 it to the ptrace call.
6850 * alpha-bsd-nat.c (store_registers): Likewise.
6851
6852 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6853
6854 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
6855 includes.
6856 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
6857 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
6858 fill_fpregset): Likewise.
6859
6860 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6861
6862 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
6863 nbsd_nat_target instead of inf_ptrace_target.
6864 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6865 nbsd_nat_target.
6866
6867 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6868
6869 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
6870 register_t.
6871
6872 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6873
6874 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
6875 it to the ptrace call.
6876 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
6877 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
6878 * arm-nbsd-nat.c (store_register): Likewise.
6879 * arm-nbsd-nat.c (store_regs): Likewise.
6880 * arm-nbsd-nat.c (store_fp_register): Likewise.
6881 * arm-nbsd-nat.c (store_fp_regs): Likewise.
6882
6883 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6884
6885 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
6886 nbsd_nat_target instead of inf_ptrace_target.
6887 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
6888 nbsd_nat_target.
6889
6890 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6891
6892 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
6893 it to the ptrace call.
6894 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
6895
6896 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6897
6898 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
6899 it to the ptrace call.
6900 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
6901
6902 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6903
6904 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
6905 gdb_byte *.
6906 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
6907
6908 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6909
6910 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
6911 instead of inf_ptrace_target.
6912 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
6913 nbsd_nat_target.
6914
6915 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6916
6917 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6918 register_t.
6919
6920 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6921
6922 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
6923 register_t.
6924
6925 2020-03-14 Kamil Rytarowski <n54@gmx.com>
6926
6927 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
6928 register_t.
6929
6930 2020-03-13 Tom Tromey <tom@tromey.com>
6931
6932 * value.h (val_print): Don't declare.
6933 * valprint.h (val_print_array_elements)
6934 (val_print_scalar_formatted, generic_val_print): Don't declare.
6935 * valprint.c (generic_val_print_array): Take a struct value.
6936 (generic_val_print_ptr, generic_val_print_memberptr)
6937 (generic_val_print_bool, generic_val_print_int)
6938 (generic_val_print_char, generic_val_print_complex)
6939 (generic_val_print): Remove.
6940 (generic_value_print): Update.
6941 (do_val_print): Remove unused parameters. Don't call
6942 la_val_print.
6943 (val_print): Remove.
6944 (common_val_print): Update. Don't call value_check_printable.
6945 (val_print_scalar_formatted, val_print_array_elements): Remove.
6946 * rust-lang.c (rust_val_print): Remove.
6947 (rust_language_defn): Update.
6948 * p-valprint.c (pascal_val_print): Remove.
6949 (pascal_value_print_inner): Update.
6950 (pascal_object_print_val_fields, pascal_object_print_val):
6951 Remove.
6952 (pascal_object_print_static_field): Update.
6953 * p-lang.h (pascal_val_print): Don't declare.
6954 * p-lang.c (pascal_language_defn): Update.
6955 * opencl-lang.c (opencl_language_defn): Update.
6956 * objc-lang.c (objc_language_defn): Update.
6957 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
6958 * m2-lang.h (m2_val_print): Don't declare.
6959 * m2-lang.c (m2_language_defn): Update.
6960 * language.h (struct language_defn) <la_val_print>: Remove.
6961 * language.c (unk_lang_value_print_inner): Rename. Change
6962 argument types.
6963 (unknown_language_defn, auto_language_defn): Update.
6964 * go-valprint.c (go_val_print): Remove.
6965 * go-lang.h (go_val_print): Don't declare.
6966 * go-lang.c (go_language_defn): Update.
6967 * f-valprint.c (f_val_print): Remove.
6968 * f-lang.h (f_value_print): Don't declare.
6969 * f-lang.c (f_language_defn): Update.
6970 * d-valprint.c (d_val_print): Remove.
6971 * d-lang.h (d_value_print): Don't declare.
6972 * d-lang.c (d_language_defn): Update.
6973 * cp-valprint.c (cp_print_value_fields)
6974 (cp_print_value_fields_rtti, cp_print_value): Remove.
6975 (cp_print_static_field): Update.
6976 * c-valprint.c (c_val_print_array, c_val_print_ptr)
6977 (c_val_print_struct, c_val_print_union, c_val_print_int)
6978 (c_val_print_memberptr, c_val_print): Remove.
6979 * c-lang.h (c_val_print_array, cp_print_value_fields)
6980 (cp_print_value_fields_rtti): Don't declare.
6981 * c-lang.c (c_language_defn, cplus_language_defn)
6982 (asm_language_defn, minimal_language_defn): Update.
6983 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
6984 (ada_val_print_enum): Take a struct value.
6985 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
6986 (ada_val_print): Remove.
6987 (ada_value_print_1): Update.
6988 (printable_val_type): Remove.
6989 * ada-lang.h (ada_val_print): Don't declare.
6990 * ada-lang.c (ada_language_defn): Update.
6991
6992 2020-03-13 Tom Tromey <tom@tromey.com>
6993
6994 * valprint.c (do_val_print): Update.
6995 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
6996 a struct value.
6997 (value_to_value_object_no_release): Declare.
6998 * python/py-value.c (value_to_value_object_no_release): New
6999 function.
7000 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
7001 struct value.
7002 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
7003 function.
7004 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
7005 a struct value.
7006 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
7007 Declare.
7008 (gdbscm_apply_val_pretty_printer): Take a struct value.
7009 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
7010 value.
7011 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
7012 value.
7013 * extension-priv.h (struct extension_language_ops)
7014 <apply_val_pretty_printer>: Take a struct value.
7015 * cp-valprint.c (cp_print_value): Create a struct value.
7016 (cp_print_value): Update.
7017
7018 2020-03-13 Tom Tromey <tom@tromey.com>
7019
7020 * ada-valprint.c (print_field_values): Call common_val_print.
7021
7022 2020-03-13 Tom Tromey <tom@tromey.com>
7023
7024 * ada-valprint.c (val_print_packed_array_elements): Remove
7025 bitoffset and val parameters. Call common_val_print.
7026 (ada_val_print_string): Remove offset, address, and original_value
7027 parameters.
7028 (ada_val_print_array): Update.
7029 (ada_value_print_array): New function.
7030 (ada_value_print_1): Call it.
7031
7032 2020-03-13 Tom Tromey <tom@tromey.com>
7033
7034 * ada-valprint.c (ada_value_print): Use common_val_print.
7035
7036 2020-03-13 Tom Tromey <tom@tromey.com>
7037
7038 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
7039
7040 2020-03-13 Tom Tromey <tom@tromey.com>
7041
7042 * ada-valprint.c (ada_value_print_num): New function.
7043 (ada_value_print_1): Use it.
7044
7045 2020-03-13 Tom Tromey <tom@tromey.com>
7046
7047 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
7048
7049 2020-03-13 Tom Tromey <tom@tromey.com>
7050
7051 * ada-valprint.c (ada_value_print_ptr): New function.
7052 (ada_value_print_1): Use it.
7053
7054 2020-03-13 Tom Tromey <tom@tromey.com>
7055
7056 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
7057 call common_val_print.
7058 (ada_val_print_1): Update.
7059 (ada_value_print_1): New function.
7060 (ada_value_print_inner): Rewrite.
7061
7062 2020-03-13 Tom Tromey <tom@tromey.com>
7063
7064 * cp-valprint.c (cp_print_value_fields): Update.
7065 (cp_print_value): New function.
7066
7067 2020-03-13 Tom Tromey <tom@tromey.com>
7068
7069 * m2-valprint.c (m2_value_print_inner): Use
7070 cp_print_value_fields.
7071 * cp-valprint.c (cp_print_value_fields): New function.
7072 * c-valprint.c (c_value_print_struct): New function.
7073 (c_value_print_inner): Use c_value_print_struct.
7074 * c-lang.h (cp_print_value_fields): Declare.
7075
7076 2020-03-13 Tom Tromey <tom@tromey.com>
7077
7078 * c-valprint.c (c_value_print_array): New function.
7079 (c_value_print_inner): Use it.
7080
7081 2020-03-13 Tom Tromey <tom@tromey.com>
7082
7083 * c-valprint.c (c_value_print_memberptr): New function.
7084 (c_value_print_inner): Use it.
7085
7086 2020-03-13 Tom Tromey <tom@tromey.com>
7087
7088 * c-valprint.c (c_value_print_int): New function.
7089 (c_value_print_inner): Use it.
7090
7091 2020-03-13 Tom Tromey <tom@tromey.com>
7092
7093 * c-valprint.c (c_value_print_ptr): New function.
7094 (c_value_print_inner): Use it.
7095
7096 2020-03-13 Tom Tromey <tom@tromey.com>
7097
7098 * c-valprint.c (c_value_print_inner): Rewrite.
7099
7100 2020-03-13 Tom Tromey <tom@tromey.com>
7101
7102 * valprint.c (generic_value_print_complex): New function.
7103 (generic_value_print): Use it.
7104
7105 2020-03-13 Tom Tromey <tom@tromey.com>
7106
7107 * valprint.c (generic_val_print_float): Don't call
7108 val_print_scalar_formatted.
7109 (generic_val_print, generic_value_print): Update.
7110
7111 2020-03-13 Tom Tromey <tom@tromey.com>
7112
7113 * valprint.c (generic_value_print_char): New function
7114 (generic_value_print): Use it.
7115
7116 2020-03-13 Tom Tromey <tom@tromey.com>
7117
7118 * valprint.c (generic_value_print_int): New function.
7119 (generic_value_print): Use it.
7120
7121 2020-03-13 Tom Tromey <tom@tromey.com>
7122
7123 * valprint.c (generic_value_print_bool): New function.
7124 (generic_value_print): Use it.
7125
7126 2020-03-13 Tom Tromey <tom@tromey.com>
7127
7128 * valprint.c (generic_val_print_func): Simplify.
7129 (generic_val_print, generic_value_print): Update.
7130
7131 2020-03-13 Tom Tromey <tom@tromey.com>
7132
7133 * valprint.c (generic_val_print_flags): Remove.
7134 (generic_val_print, generic_value_print): Update.
7135 (val_print_type_code_flags): Add original_value parameter.
7136
7137 2020-03-13 Tom Tromey <tom@tromey.com>
7138
7139 * valprint.c (generic_val_print): Update.
7140 (generic_value_print): Update.
7141 * valprint.c (generic_val_print_enum): Don't call
7142 val_print_scalar_formatted.
7143
7144 2020-03-13 Tom Tromey <tom@tromey.com>
7145
7146 * valprint.c (generic_value_print): Call generic_value_print_ptr.
7147 * valprint.c (generic_value_print_ptr): New function.
7148
7149 2020-03-13 Tom Tromey <tom@tromey.com>
7150
7151 * valprint.c (generic_value_print): Rewrite.
7152
7153 2020-03-13 Tom Tromey <tom@tromey.com>
7154
7155 * p-valprint.c (pascal_object_print_value_fields)
7156 (pascal_object_print_value): New functions.
7157
7158 2020-03-13 Tom Tromey <tom@tromey.com>
7159
7160 * p-valprint.c (pascal_value_print_inner): Rewrite.
7161
7162 2020-03-13 Tom Tromey <tom@tromey.com>
7163
7164 * f-valprint.c (f_value_print_innner): Rewrite.
7165
7166 2020-03-13 Tom Tromey <tom@tromey.com>
7167
7168 * m2-valprint.c (m2_print_unbounded_array): New overload.
7169 (m2_print_unbounded_array): Update.
7170 (m2_print_array_contents): Take a struct value.
7171 (m2_value_print_inner): Rewrite.
7172
7173 2020-03-13 Tom Tromey <tom@tromey.com>
7174
7175 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
7176 (d_value_print_inner): New function.
7177 * d-lang.h (d_value_print_inner): Declare.
7178 * d-lang.c (d_language_defn): Use d_value_print_inner.
7179
7180 2020-03-13 Tom Tromey <tom@tromey.com>
7181
7182 * go-valprint.c (go_value_print_inner): New function.
7183 * go-lang.h (go_value_print_inner): Declare.
7184 * go-lang.c (go_language_defn): Use go_value_print_inner.
7185
7186 2020-03-13 Tom Tromey <tom@tromey.com>
7187
7188 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
7189 API.
7190 (rust_val_print): Rewrite.
7191 (rust_value_print_inner): New function, from rust_val_print.
7192 (rust_language_defn): Use rust_value_print_inner.
7193
7194 2020-03-13 Tom Tromey <tom@tromey.com>
7195
7196 * ada-valprint.c (ada_value_print_inner): New function.
7197 * ada-lang.h (ada_value_print_inner): Declare.
7198 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
7199
7200 2020-03-13 Tom Tromey <tom@tromey.com>
7201
7202 * f-valprint.c (f_value_print_innner): New function.
7203 * f-lang.h (f_value_print_innner): Declare.
7204 * f-lang.c (f_language_defn): Use f_value_print_innner.
7205
7206 2020-03-13 Tom Tromey <tom@tromey.com>
7207
7208 * p-valprint.c (pascal_value_print_inner): New function.
7209 * p-lang.h (pascal_value_print_inner): Declare.
7210 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
7211
7212 2020-03-13 Tom Tromey <tom@tromey.com>
7213
7214 * m2-valprint.c (m2_value_print_inner): New function.
7215 * m2-lang.h (m2_value_print_inner): Declare.
7216 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
7217
7218 2020-03-13 Tom Tromey <tom@tromey.com>
7219
7220 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
7221 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
7222 * c-valprint.c (c_value_print_inner): New function.
7223 * c-lang.h (c_value_print_inner): Declare.
7224 * c-lang.c (c_language_defn, cplus_language_defn)
7225 (asm_language_defn, minimal_language_defn): Use
7226 c_value_print_inner.
7227
7228 2020-03-13 Tom Tromey <tom@tromey.com>
7229
7230 * p-valprint.c (pascal_object_print_value_fields): Now static.
7231 * p-lang.h (pascal_object_print_value_fields): Don't declare.
7232
7233 2020-03-13 Tom Tromey <tom@tromey.com>
7234
7235 * c-valprint.c (c_val_print_array): Simplify.
7236
7237 2020-03-13 Tom Tromey <tom@tromey.com>
7238
7239 * valprint.c (value_print_array_elements): New function.
7240 * valprint.h (value_print_array_elements): Declare.
7241
7242 2020-03-13 Tom Tromey <tom@tromey.com>
7243
7244 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
7245 * mips-tdep.c (mips_print_register): Use
7246 value_print_scalar_formatted.
7247
7248 2020-03-13 Tom Tromey <tom@tromey.com>
7249
7250 * valprint.h (value_print_scalar_formatted): Declare.
7251 * valprint.c (value_print_scalar_formatted): New function.
7252
7253 2020-03-13 Tom Tromey <tom@tromey.com>
7254
7255 * valprint.h (generic_value_print): Declare.
7256 * valprint.c (generic_value_print): New function.
7257
7258 2020-03-13 Tom Tromey <tom@tromey.com>
7259
7260 * valprint.c (do_val_print): Call la_value_print_inner, if
7261 available.
7262 * rust-lang.c (rust_language_defn): Update.
7263 * p-lang.c (pascal_language_defn): Update.
7264 * opencl-lang.c (opencl_language_defn): Update.
7265 * objc-lang.c (objc_language_defn): Update.
7266 * m2-lang.c (m2_language_defn): Update.
7267 * language.h (struct language_defn) <la_value_print_inner>: New
7268 member.
7269 * language.c (unknown_language_defn, auto_language_defn): Update.
7270 * go-lang.c (go_language_defn): Update.
7271 * f-lang.c (f_language_defn): Update.
7272 * d-lang.c (d_language_defn): Update.
7273 * c-lang.c (c_language_defn, cplus_language_defn)
7274 (asm_language_defn, minimal_language_defn): Update.
7275 * ada-lang.c (ada_language_defn): Update.
7276
7277 2020-03-13 Tom Tromey <tom@tromey.com>
7278
7279 * c-valprint.c (c_value_print): Use common_val_print.
7280
7281 2020-03-13 Tom Tromey <tom@tromey.com>
7282
7283 * cp-valprint.c (cp_print_static_field): Use common_val_print.
7284
7285 2020-03-13 Tom Tromey <tom@tromey.com>
7286
7287 * f-valprint.c (f77_print_array_1, f_val_print): Use
7288 common_val_print.
7289
7290 2020-03-13 Tom Tromey <tom@tromey.com>
7291
7292 * riscv-tdep.c (riscv_print_one_register_info): Use
7293 common_val_print.
7294
7295 2020-03-13 Tom Tromey <tom@tromey.com>
7296
7297 * mi/mi-main.c (output_register): Use common_val_print.
7298
7299 2020-03-13 Tom Tromey <tom@tromey.com>
7300
7301 * infcmd.c (default_print_one_register_info): Use
7302 common_val_print.
7303
7304 2020-03-13 Tom Tromey <tom@tromey.com>
7305
7306 * valprint.h (common_val_print_checked): Declare.
7307 * valprint.c (common_val_print_checked): New function.
7308 * stack.c (print_frame_arg): Use common_val_print_checked.
7309
7310 2020-03-13 Tom Tromey <tom@tromey.com>
7311
7312 * valprint.c (do_val_print): New function, from val_print.
7313 (val_print): Use do_val_print.
7314 (common_val_print): Use do_val_print.
7315
7316 2020-03-13 Tom Tromey <tom@tromey.com>
7317
7318 * valprint.c (value_print): Use scoped_value_mark.
7319
7320 2020-03-13 Tom de Vries <tdevries@suse.de>
7321
7322 PR symtab/25646
7323 * psymtab.c (partial_symtab::partial_symtab): Don't set
7324 globals_offset and statics_offset. Push element onto
7325 current_global_psymbols and current_static_psymbols stacks.
7326 (concat): New function.
7327 (end_psymtab_common): Set globals_offset and statics_offset. Pop
7328 element from current_global_psymbols and current_static_psymbols
7329 stacks. Concat popped elements to global_psymbols and
7330 static_symbols.
7331 (add_psymbol_to_list): Use current_global_psymbols and
7332 current_static_psymbols stacks.
7333 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
7334 current_static_psymbols fields.
7335
7336 2020-03-12 Christian Biesinger <cbiesinger@google.com>
7337
7338 * corelow.c (sniff_core_bfd): Remove.
7339 (class core_target) <m_core_vec>: Remove.
7340 (core_target::core_target): Update.
7341 (core_file_fns): Remove.
7342 (deprecated_add_core_fns): Remove.
7343 (default_core_sniffer): Remove.
7344 (sniff_core_bfd): Remove.
7345 (default_check_format): Remove.
7346 (gdb_check_format): Remove.
7347 (core_target_open): Update.
7348 (core_target::get_core_register_section): Update.
7349 (get_core_registers_cb): Update.
7350 (core_target::fetch_registers): Update.
7351 * gdbcore.h (struct core_fns): Remove.
7352 (deprecated_add_core_fns): Remove.
7353 (default_core_sniffer): Remove.
7354 (default_check_format): Remove.
7355
7356 2020-03-12 Tom Tromey <tom@tromey.com>
7357
7358 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
7359 CORE_ADDR.
7360 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
7361
7362 2020-03-12 Tom Tromey <tom@tromey.com>
7363
7364 * remote.c (remote_target::download_tracepoint)
7365 (remote_target::enable_tracepoint)
7366 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
7367 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
7368 sprintf_vma.
7369
7370 2020-03-12 Tom Tromey <tom@tromey.com>
7371
7372 * symfile-mem.c: Update CORE_ADDR size assert.
7373
7374 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7375
7376 * selftest.m4: Move to gdbsupport/.
7377 * acinclude.m4: Update path to selftest.m4.
7378
7379 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7380
7381 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
7382 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
7383 gdbarch-selfselftests.c and selftest-arch.c.
7384 (SUBDIR_UNITTESTS_OBS): Rename to...
7385 (SELFTESTS_OBS): ... this.
7386 (COMMON_SFILES): Remove disasm-selftests.c and
7387 gdbarch-selftests.c.
7388 * configure.ac: Don't add selftest-arch.{c,o} to
7389 CONFIG_{SRCS,OBS}.
7390 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
7391 preprocessor conditions.
7392
7393 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7394
7395 * configure.ac: Don't source bfd/development.sh.
7396 * selftest.m4: Modify comment.
7397 * configure: Re-generate.
7398
7399 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
7400
7401 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
7402 not "true" or "false".
7403 * configure: Re-generate.
7404
7405 2020-03-12 Christian Biesinger <cbiesinger@google.com>
7406
7407 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
7408 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
7409 renamed to arm_nbsd_supply_gregset.
7410 (fetch_register): Update to call arm_nbsd_supply_gregset.
7411 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
7412 (arm_netbsd_nat_target::fetch_registers): Update.
7413 (fetch_elfcore_registers): Removed.
7414 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
7415 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
7416 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
7417 not require NetBSD system headers.
7418 (arm_nbsd_regset): New struct.
7419 (arm_nbsd_iterate_over_regset_sections): New function.
7420 (arm_netbsd_init_abi_common): Updated to call
7421 set_gdbarch_iterate_over_regset_sections.
7422 * arm-nbsd-tdep.h: New file.
7423
7424 2020-03-11 Kevin Buettner <kevinb@redhat.com>
7425
7426 * symtab.c (find_pc_sect_line): Add check which prevents infinite
7427 recursion.
7428
7429 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
7430
7431 * configure: Re-generate.
7432
7433 2020-03-11 Tom Tromey <tromey@adacore.com>
7434
7435 * ada-typeprint.c (print_choices): Fix comment.
7436
7437 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
7438
7439 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
7440 previous item in the list, when the list has no items.
7441
7442 2020-03-11 Tom de Vries <tdevries@suse.de>
7443
7444 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
7445 PROP_LOCLIST handling code.
7446
7447 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
7448
7449 * buildsym-legacy.c (record_line): Pass extra parameter to
7450 record_line.
7451 * buildsym.c (buildsym_compunit::record_line): Take an extra
7452 parameter, reduce duplication in the line table, and record the
7453 is_stmt flag in the line table.
7454 * buildsym.h (buildsym_compunit::record_line): Add extra
7455 parameter.
7456 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
7457 non-statement lines.
7458 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
7459 this to the symtab builder.
7460 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
7461 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
7462 through to dwarf_record_line_1.
7463 * infrun.c (process_event_stop_test): When stepping, don't stop at
7464 a non-statement instruction, and only refresh the step info when
7465 we land in the middle of a line's range. Also add an extra
7466 comment.
7467 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
7468 field.
7469 * record-btrace.c (btrace_find_line_range): Only record lines
7470 marked as is-statement.
7471 * stack.c (frame_show_address): Show the frame address if we are
7472 in a non-statement sal.
7473 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
7474 (maintenance_print_one_line_table): Print a header for the is_stmt
7475 column, and include is_stmt information in the output.
7476 * symtab.c (find_pc_sect_line): Find lines marked as statements in
7477 preference to non-statements.
7478 (find_pcs_for_symtab_line): Prefer is-statement entries.
7479 (find_line_common): Likewise.
7480 * symtab.h (struct linetable_entry): Add is_stmt field.
7481 (struct symtab_and_line): Likewise.
7482 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
7483 arranging the line table.
7484
7485 2020-03-07 Tom de Vries <tdevries@suse.de>
7486
7487 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
7488 DIE.
7489
7490 2020-03-07 Tom Tromey <tom@tromey.com>
7491
7492 * valops.c (value_literal_complex): Remove obsolete comment.
7493 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
7494 comment.
7495
7496 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
7497
7498 * infrun.h: Forward-declare thread_info.
7499 (set_step_info): Add thread_info parameter, add doc.
7500 * infrun.c (set_step_info): Add thread_info parameter, move doc
7501 to header.
7502 * infrun.c (process_event_stop_test): Pass thread to
7503 set_step_info call.
7504 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
7505 set_step_info.
7506 (prepare_one_step): Add thread_info parameter, pass it to
7507 set_step_frame and prepare_one_step (recursive) call.
7508 (step_1): Pass thread to prepare_one_step call.
7509 (step_command_fsm::should_stop): Pass thread to
7510 prepare_one_step.
7511 (until_next_fsm): Pass thread to set_step_frame call.
7512 (finish_command): Pass thread to set_step_info call.
7513
7514 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
7515
7516 * windows-tdep.c (windows_solib_create_inferior_hook):
7517 Check if inferior is running.
7518
7519 2020-03-06 Tom de Vries <tdevries@suse.de>
7520
7521 * NEWS: Fix "the the".
7522 * ctfread.c: Same.
7523
7524 2020-03-06 Tom de Vries <tdevries@suse.de>
7525
7526 * psymtab.c (psymtab_to_symtab): Don't print "done.".
7527
7528 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
7529
7530 * .dir-locals.el: Add a comment referencing the other copies of
7531 this file.
7532
7533 2020-03-05 John Baldwin <jhb@FreeBSD.org>
7534
7535 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
7536 psargs.
7537
7538 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7539
7540 * .gitattributes: New file.
7541
7542 2020-03-04 Tom Tromey <tom@tromey.com>
7543
7544 * symmisc.c (print_symbol_bcache_statistics)
7545 (print_objfile_statistics): Update.
7546 * symfile.c (allocate_symtab): Use intern.
7547 * psymtab.c (partial_symtab::partial_symtab): Use intern.
7548 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
7549 macro_cache>: Remove.
7550 <string_cache>: New member.
7551 (struct objfile) <intern>: New methods.
7552 * elfread.c (elf_symtab_read): Use intern.
7553 * dwarf2/read.c (fixup_go_packaging): Intern package name.
7554 (dwarf2_compute_name, dwarf2_physname)
7555 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
7556 names.
7557 (guess_partial_die_structure_name): Update.
7558 (partial_die_info::fixup): Intern name.
7559 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
7560 name.
7561 (dwarf2_name): Intern name. Update.
7562 * buildsym.c (buildsym_compunit::get_macro_table): Use
7563 string_cache.
7564
7565 2020-03-04 Tom Tromey <tom@tromey.com>
7566
7567 * jit.c (bfd_open_from_target_memory): Make "target" const.
7568 * corefile.c (gnutarget): Now const.
7569 * gdbcore.h (gnutarget): Now const.
7570
7571 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
7572
7573 * NEWS: Mention support for WOW64 processes.
7574 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
7575 (amd64_windows_segment_register_p): Remove static.
7576 (_initialize_amd64_windows_nat): Update.
7577 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
7578 * i386-windows-nat.c (context_offset): Update.
7579 (i386_mappings): Rename and remove static.
7580 (i386_windows_segment_register_p): Remove static.
7581 (_initialize_i386_windows_nat): Update.
7582 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
7583 (STATUS_WX86_SINGLE_STEP): New macro.
7584 (EnumProcessModulesEx): New macro.
7585 (Wow64SuspendThread): New macro.
7586 (Wow64GetThreadContext): New macro.
7587 (Wow64SetThreadContext): New macro.
7588 (Wow64GetThreadSelectorEntry): New macro.
7589 (windows_set_context_register_offsets): Add static.
7590 (windows_set_segment_register_p): Likewise.
7591 (windows_add_thread): Adapt for WOW64 processes.
7592 (windows_fetch_one_register): Likewise.
7593 (windows_nat_target::fetch_registers): Likewise.
7594 (windows_store_one_register): Likewise.
7595 (display_selector): Likewise.
7596 (display_selectors): Likewise.
7597 (handle_exception): Likewise.
7598 (windows_continue): Likewise.
7599 (windows_nat_target::resume): Likewise.
7600 (windows_add_all_dlls): Likewise.
7601 (do_initial_windows_stuff): Likewise.
7602 (windows_nat_target::attach): Likewise.
7603 (windows_get_exec_module_filename): Likewise.
7604 (windows_nat_target::create_inferior): Likewise.
7605 (windows_xfer_siginfo): Likewise.
7606 (_initialize_loadable): Initialize Wow64SuspendThread,
7607 Wow64GetThreadContext, Wow64SetThreadContext,
7608 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
7609 * windows-nat.h (windows_set_context_register_offsets):
7610 Remove declaration.
7611 (windows_set_segment_register_p): Likewise.
7612 (i386_windows_segment_register_p): Add declaration.
7613 (amd64_windows_segment_register_p): Likewise.
7614
7615 2020-03-04 Luis Machado <luis.machado@linaro.org>
7616
7617 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
7618 in "info registers" for AArch64/ARM.
7619
7620 The change caused "info registers" to not print GPR's.
7621
7622 gdb/ChangeLog:
7623
7624 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
7625
7626 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
7627 when reg->group is empty and reggroup is not.
7628
7629 2020-03-03 Tom Tromey <tromey@adacore.com>
7630
7631 * dwarf2/frame.c (struct dwarf2_frame_cache)
7632 <checked_tailcall_bottom, entry_cfa_sp_offset,
7633 entry_cfa_sp_offset_p>: Remove members.
7634 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
7635 (dwarf2_frame_prev_register): Don't call
7636 dwarf2_tailcall_sniffer_first.
7637 (dwarf2_append_unwinders): Don't append tailcall unwinder.
7638 * frame-unwind.c (add_unwinder): New fuction.
7639 (frame_unwind_init): Use it. Add tailcall unwinder.
7640
7641 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
7642 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
7643
7644 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
7645 value should be printed as true.
7646
7647 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
7648
7649 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
7650 (windows_init_abi): Set and use windows_so_ops.
7651
7652 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
7653
7654 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
7655 when verifying if dealing with a convenience variable.
7656
7657 2020-03-03 Luis Machado <luis.machado@linaro.org>
7658
7659 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
7660
7661 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
7662
7663 * infrun.c (gdbarch_supports_displaced_stepping): New.
7664 (use_displaced_stepping): Break up conditions in smaller pieces.
7665 Use gdbarch_supports_displaced_stepping.
7666 (displaced_step_prepare_throw): Use
7667 gdbarch_supports_displaced_stepping.
7668
7669 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
7670
7671 * NEWS: Mention new behaviour of the history filename.
7672 * top.c (write_history_p): Add comment.
7673 (show_write_history_p): Add header comment, give a different
7674 message when history writing is on, but the history filename is
7675 empty.
7676 (history_filename): Add comment.
7677 (history_filename_empty): New function.
7678 (show_history_filename): Add header comment, give a different
7679 message when the filename is empty.
7680 (init_history): Compare history_filename against nullptr, and only
7681 read history if the filename is not empty.
7682 (set_history_filename): Add header comment, and only make
7683 non-empty filenames absolute.
7684 (init_main): Make the filename argument to 'set history filename'
7685 optional.
7686
7687 2020-03-02 Christian Biesinger <cbiesinger@google.com>
7688
7689 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
7690 (arm_supply_vfpregset): ...this, and update to use VFP registers.
7691 (fetch_fp_register): Update.
7692 (fetch_fp_regs): Update.
7693 (store_fp_register): Update.
7694 (store_fp_regs): Update.
7695 (arm_netbsd_nat_target::read_description): New function.
7696 (fetch_elfcore_registers): Update.
7697
7698 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
7699
7700 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
7701 general_thread if the stop reply is missing a thread-id.
7702 (remote_target::process_stop_reply): Use the first non-exited
7703 thread if the target didn't pass a thread-id.
7704 * infrun.c (do_target_wait): Move call to
7705 switch_to_inferior_no_thread to ....
7706 (do_target_wait_1): ... here.
7707
7708 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
7709
7710 * debuginfod-support.c: Include defs.h first.
7711
7712 2020-02-28 Tom de Vries <tdevries@suse.de>
7713
7714 * symfile.c (set_initial_language): Use default language for lookup.
7715
7716 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
7717
7718 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
7719 reader variable, pass `this` to read_cutu_die_from_dwo.
7720
7721 2020-02-27 Aaron Merey <amerey@redhat.com>
7722
7723 * source.c (open_source_file): Check for nullptr when computing
7724 srcpath.
7725
7726 2020-02-27 Tom Tromey <tromey@adacore.com>
7727
7728 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
7729 member.
7730 (dwarf2_add_field): Don't update nfields.
7731 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
7732
7733 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
7734
7735 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
7736 abs.
7737
7738 2020-02-26 Tom Tromey <tom@tromey.com>
7739
7740 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
7741 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
7742 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
7743 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
7744 per_cu_data.
7745
7746 2020-02-26 Tom Tromey <tom@tromey.com>
7747
7748 * dwarf2/index-write.c (psym_index_map): Change type.
7749 (add_address_entry_worker, write_one_signatured_type)
7750 (recursively_count_psymbols, recursively_write_psymbols)
7751 (class debug_names, psyms_seen_size, write_gdbindex)
7752 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
7753
7754 2020-02-26 Aaron Merey <amerey@redhat.com>
7755
7756 * Makefile.in: Handle optional debuginfod support.
7757 * NEWS: Update.
7758 * README: Add --with-debuginfod summary.
7759 * config.in: Regenerate.
7760 * configure: Regenerate.
7761 * configure.ac: Handle optional debuginfod support.
7762 * debuginfod-support.c: debuginfod helper functions.
7763 * debuginfod-support.h: Ditto.
7764 * doc/gdb.texinfo: Add --with-debuginfod to configure options
7765 summary.
7766 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
7767 when a dwz file cannot be found.
7768 * elfread.c (elf_symfile_read): Query debuginfod servers when a
7769 debuginfo file cannot be found.
7770 * source.c (open_source_file): Query debuginfod servers when a
7771 source file cannot be found.
7772 * top.c (print_gdb_configuration): Include
7773 --{with,without}-debuginfod in the output.
7774
7775 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
7776
7777 * thread.c (thr_try_catch_cmd): Print thread name.
7778
7779 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
7780
7781 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
7782 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7783 dwarf2_fetch_die_type_sect_off): Move to...
7784 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
7785 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7786 dwarf2_fetch_die_type_sect_off): ... here.
7787 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
7788 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
7789 dwarf2_fetch_die_type_sect_off): Move doc to header file.
7790
7791 2020-02-26 Tom de Vries <tdevries@suse.de>
7792
7793 PR gdb/25603
7794 * symfile.c (set_initial_language): Exit-early if
7795 language_mode == language_mode_manual.
7796
7797 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
7798
7799 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
7800 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
7801 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
7802
7803 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
7804
7805 * gdbtypes.c (create_array_type_with_stride): Handle negative
7806 array strides.
7807 * valarith.c (value_subscripted_rvalue): Likewise.
7808
7809 2020-02-25 Luis Machado <luis.machado@linaro.org>
7810
7811 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
7812
7813 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
7814
7815 * loc.h (dwarf2_get_die_type): Move to...
7816 * read.h (dwarf2_get_die_type): ... here.
7817 * read.c (dwarf2_get_die_type): Move doc to header.
7818
7819 2020-02-25 Joel Brobecker <brobecker@adacore.com>
7820
7821 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
7822 'gnulib/Makefile.in' to the list.
7823
7824 2020-02-24 Tom Tromey <tom@tromey.com>
7825
7826 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
7827 Remove.
7828 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
7829 XOBNEWVEC.
7830
7831 2020-02-24 Tom Tromey <tom@tromey.com>
7832
7833 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
7834 New method.
7835 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
7836 (dw2_do_instantiate_symtab, dw2_get_file_names)
7837 (build_type_psymtab_dependencies, load_full_type_unit): Update.
7838
7839 2020-02-24 Tom Tromey <tom@tromey.com>
7840
7841 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
7842 make_scoped_restore.
7843 (dwarf2_psymtab::read_symtab): Don't clear
7844 reading_partial_symbols.
7845
7846 2020-02-24 Tom de Vries <tdevries@suse.de>
7847
7848 PR gdb/25592
7849 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
7850
7851 2020-02-24 Tom de Vries <tdevries@suse.de>
7852
7853 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
7854 commands layout next/prev/regs.
7855
7856 2020-02-22 Tom Tromey <tom@tromey.com>
7857
7858 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
7859 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
7860
7861 2020-02-22 Tom Tromey <tom@tromey.com>
7862
7863 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
7864
7865 2020-02-22 Tom Tromey <tom@tromey.com>
7866
7867 * tui/tui-win.c (_initialize_tui_win): Add usage text.
7868 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
7869 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
7870 * tui/tui.c (_initialize_tui): Add usage text.
7871
7872 2020-02-22 Tom Tromey <tom@tromey.com>
7873
7874 * tui/tui-win.c (tui_set_focus_command)
7875 (tui_set_win_height_command): Use error_no_arg.
7876 (_initialize_tui_win): Update help text.
7877 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
7878
7879 2020-02-22 Tom Tromey <tom@tromey.com>
7880
7881 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
7882 * tui/tui-disasm.h (struct tui_disasm_window)
7883 <display_start_addr>: Declare.
7884 * tui/tui-source.h (struct tui_source_window)
7885 <display_start_addr>: Declare.
7886 * tui/tui-winsource.h (struct tui_source_window_base)
7887 <show_source_line, display_start_addr>: New methods.
7888 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
7889 Rename and move to protected section.
7890 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
7891 (tui_source_window_base::do_erase_source_content): Update.
7892 (tui_source_window_base::show_source_line): Now a method.
7893 (tui_source_window_base::show_source_content)
7894 (tui_source_window_base::tui_source_window_base)
7895 (tui_source_window_base::rerender)
7896 (tui_source_window_base::refill)
7897 (tui_source_window_base::do_scroll_horizontal)
7898 (tui_source_window_base::set_is_exec_point_at)
7899 (tui_source_window_base::update_breakpoint_info)
7900 (tui_source_window_base::update_exec_info): Update.
7901 * tui/tui-source.c (tui_source_window::set_contents)
7902 (tui_source_window::showing_source_p)
7903 (tui_source_window::do_scroll_vertical)
7904 (tui_source_window::location_matches_p)
7905 (tui_source_window::line_is_displayed): Update.
7906 (tui_source_window::display_start_addr): New method.
7907 * tui/tui-disasm.c (tui_disasm_window::set_contents)
7908 (tui_disasm_window::do_scroll_vertical)
7909 (tui_disasm_window::location_matches_p): Update.
7910 (tui_disasm_window::display_start_addr): New method.
7911
7912 2020-02-22 Tom Tromey <tom@tromey.com>
7913
7914 * NEWS: Add entry for gdb.register_window_type.
7915 * tui/tui-layout.h (window_factory): New typedef.
7916 (tui_register_window): Declare.
7917 * tui/tui-layout.c (saved_tui_windows): New global.
7918 (tui_apply_current_layout): Use it.
7919 (tui_register_window): New function.
7920 * python/python.c (do_start_initialization): Call
7921 gdbpy_initialize_tui.
7922 (python_GdbMethods): Add "register_window_type" function.
7923 * python/python-internal.h (gdbpy_register_tui_window)
7924 (gdbpy_initialize_tui): Declare.
7925 * python/py-tui.c: New file.
7926 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
7927
7928 2020-02-22 Tom Tromey <tom@tromey.com>
7929
7930 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
7931
7932 2020-02-22 Tom Tromey <tom@tromey.com>
7933
7934 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
7935 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
7936 * tui/tui-data.c (tui_set_win_with_focus): Remove.
7937 (tui_set_win_focus_to): Move from tui-win.c.
7938
7939 2020-02-22 Tom Tromey <tom@tromey.com>
7940
7941 * tui/tui-layout.c (make_standard_window, get_locator_window): New
7942 functions.
7943 (known_window_types): New global.
7944 (tui_get_window_by_name): Reimplement.
7945 (initialize_known_windows): New function.
7946 (validate_window_name): Rewrite.
7947 (_initialize_tui_layout): Call initialize_known_windows.
7948
7949 2020-02-22 Tom Tromey <tom@tromey.com>
7950
7951 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
7952 Remove constants.
7953 * tui/tui-winsource.h (struct tui_source_window_base)
7954 <tui_source_window_base>: Remove parameter.
7955 * tui/tui-winsource.c
7956 (tui_source_window_base::tui_source_window_base): Remove
7957 parameter.
7958 (tui_source_window_base::refill): Update.
7959 * tui/tui-stack.h (struct tui_locator_window)
7960 <tui_locator_window>: Update.
7961 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
7962 Default the constructor.
7963 * tui/tui-regs.h (struct tui_data_item_window)
7964 <tui_data_item_window>: Default the constructor.
7965 (struct tui_data_window) <tui_data_window>: Likewise.
7966 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
7967 Default the constructor.
7968 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
7969 Default the constructor.
7970 <type>: Remove.
7971 (struct tui_win_info) <tui_win_info>: Default the constructor.
7972 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
7973 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
7974 Default the constructor.
7975
7976 2020-02-22 Tom Tromey <tom@tromey.com>
7977
7978 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
7979 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
7980 * tui/tui-win.c (tui_resize_all): Don't call
7981 tui_delete_invisible_windows.
7982 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
7983 done.
7984 (tui_set_layout): Update.
7985 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
7986 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
7987 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
7988
7989 2020-02-22 Tom Tromey <tom@tromey.com>
7990
7991 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
7992 correctly.
7993
7994 2020-02-22 Tom Tromey <tom@tromey.com>
7995
7996 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
7997
7998 2020-02-22 Tom Tromey <tom@tromey.com>
7999
8000 * tui/tui-winsource.h (struct tui_source_window_iterator)
8001 <inner_iterator>: New etytypedef.
8002 <tui_source_window_iterator>: Take "end" parameter.
8003 <tui_source_window_iterator>: Take iterator.
8004 <operator*, advance>: Update.
8005 <m_iter>: Change type.
8006 <m_end>: New field.
8007 (struct tui_source_windows) <begin, end>: Update.
8008 * tui/tui-layout.c (tui_windows): New global.
8009 (tui_apply_current_layout): Clear tui_windows.
8010 (tui_layout_window::apply): Update tui_windows.
8011 * tui/tui-data.h (tui_windows): Declare.
8012 (all_tui_windows): Now inline function.
8013 (class tui_window_iterator, struct all_tui_windows): Remove.
8014
8015 2020-02-22 Tom Tromey <tom@tromey.com>
8016
8017 PR tui/17850:
8018 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
8019 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
8020 "height" argument.
8021 (class tui_layout_window) <get_sizes>: Likewise.
8022 (class tui_layout_split) <tui_layout_split>: Add "vertical"
8023 argument.
8024 <get_sizes>: Add "height" argument.
8025 <m_vertical>: New field.
8026 * tui/tui-layout.c (tui_layout_split::clone): Update.
8027 (tui_layout_split::get_sizes): Add "height" argument.
8028 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
8029 (tui_new_layout_command): Parse "-horizontal".
8030 (_initialize_tui_layout): Update help string.
8031 (tui_layout_split::specification): Add "-horizontal" when needed.
8032 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
8033 argument.
8034 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
8035 New methods.
8036
8037 2020-02-22 Tom Tromey <tom@tromey.com>
8038
8039 * tui/tui-layout.h (enum tui_adjust_result): New.
8040 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
8041 (class tui_layout_window) <adjust_size>: Return
8042 tui_adjust_result. Rewrite.
8043 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
8044 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
8045
8046 2020-02-22 Tom Tromey <tom@tromey.com>
8047
8048 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
8049 parameter and return types.
8050 (class tui_layout_base) <specification>: Add "depth".
8051 (class tui_layout_window) <specification>: Add "depth".
8052 (class tui_layout_split) <specification>: Add "depth".
8053 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
8054 and return types.
8055 (tui_new_layout_command): Parse sub-layouts.
8056 (_initialize_tui_layout): Update help string.
8057 (tui_layout_window::specification): Add "depth".
8058 (add_layout_command): Update.
8059
8060 2020-02-22 Tom Tromey <tom@tromey.com>
8061
8062 * NEWS: Add "tui new-layout" item.
8063 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
8064 Add new-layout command to help text.
8065 (validate_window_name): New function.
8066 (tui_new_layout_command): New function.
8067 (_initialize_tui_layout): Register "new-layout".
8068 (tui_layout_window::specification): New method.
8069 (tui_layout_window::specification): New method.
8070 * tui/tui-layout.h (class tui_layout_base) <specification>: New
8071 method.
8072 (class tui_layout_window) <specification>: New method.
8073 (class tui_layout_split) <specification>: New method.
8074
8075 2020-02-22 Tom Tromey <tom@tromey.com>
8076
8077 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
8078 * tui/tui-win.c (window_name_completer): Update comment.
8079 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
8080 Declare method.
8081 (class tui_layout_window) <replace_window>: Likewise.
8082 (class tui_layout_split) <replace_window>: Likewise.
8083 (tui_set_layout): Don't declare.
8084 (tui_set_initial_layout): Declare function.
8085 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
8086 (asm_regs_layout): New globals.
8087 (tui_current_layout, show_layout): Remove.
8088 (tui_set_layout, tui_add_win_to_layout): Rewrite.
8089 (find_layout, tui_apply_layout): New function.
8090 (layout_completer): Remove.
8091 (tui_next_layout): Reimplement.
8092 (tui_next_layout_command): New function.
8093 (tui_set_initial_layout, tui_prev_layout_command): New functions.
8094 (tui_regs_layout): Reimplement.
8095 (tui_regs_layout_command): New function.
8096 (extract_display_start_addr): Rewrite.
8097 (next_layout, prev_layout): Remove.
8098 (tui_layout_window::replace_window): New method.
8099 (tui_layout_split::replace_window): New method.
8100 (destroy_layout): New function.
8101 (layout_list): New global.
8102 (add_layout_command): New function.
8103 (initialize_layouts): Update.
8104 (tui_layout_command): New function.
8105 (_initialize_tui_layout): Install "layout" commands.
8106 * tui/tui-data.h (enum tui_layout_type): Remove.
8107 (tui_current_layout): Don't declare.
8108
8109 2020-02-22 Tom Tromey <tom@tromey.com>
8110
8111 * tui/tui-regs.c (tui_reg_layout): Remove.
8112 (tui_reg_command): Use tui_regs_layout.
8113 * tui/tui-layout.h (tui_reg_command): Declare.
8114 * tui/tui-layout.c (tui_reg_command): New function.
8115
8116 2020-02-22 Tom Tromey <tom@tromey.com>
8117
8118 * tui/tui.c (tui_rl_delete_other_windows): Call
8119 tui_remove_some_windows.
8120 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
8121 Declare method.
8122 (class tui_layout_window) <remove_windows>: New method.
8123 (class tui_layout_split) <remove_windows>: Declare.
8124 (tui_remove_some_windows): Declare.
8125 * tui/tui-layout.c (tui_remove_some_windows): New function.
8126 (tui_layout_split::remove_windows): New method.
8127
8128 2020-02-22 Tom Tromey <tom@tromey.com>
8129
8130 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
8131 * tui/tui-layout.h (tui_next_layout): Declare.
8132 * tui/tui-layout.c (tui_next_layout): New function.
8133
8134 2020-02-22 Tom Tromey <tom@tromey.com>
8135
8136 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
8137 correct coordinates.
8138
8139 2020-02-22 Tom Tromey <tom@tromey.com>
8140
8141 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
8142 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
8143 DATA_WIN case.
8144
8145 2020-02-22 Tom Tromey <tom@tromey.com>
8146
8147 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
8148 TUI_DISASM_WIN, not tui_win_list.
8149
8150 2020-02-22 Tom Tromey <tom@tromey.com>
8151
8152 * valprint.c (generic_val_print_enum_1)
8153 (val_print_type_code_flags): Style member names.
8154 * rust-lang.c (val_print_struct, rust_print_enum)
8155 (rust_print_struct_def, rust_internal_print_type): Style member
8156 names.
8157 * p-valprint.c (pascal_object_print_value_fields): Style member
8158 names. Only call fprintf_symbol_filtered for static members.
8159 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
8160 * f-valprint.c (f_val_print): Style member names.
8161 * f-typeprint.c (f_type_print_base): Style member names.
8162 * cp-valprint.c (cp_print_value_fields): Style member names. Only
8163 call fprintf_symbol_filtered for static members.
8164 (cp_print_class_member): Style member names.
8165 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
8166 member names.
8167 * ada-valprint.c (ada_print_scalar): Style enum names.
8168 (ada_val_print_enum): Likewise.
8169 * ada-typeprint.c (print_enum_type): Style enum names.
8170
8171 2020-02-21 Tom Tromey <tom@tromey.com>
8172
8173 * psympriv.h (struct partial_symtab): Update comment.
8174
8175 2020-02-21 Tom Tromey <tromey@adacore.com>
8176
8177 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
8178 type is CORE_ADDR.
8179
8180 2020-02-21 Tom de Vries <tdevries@suse.de>
8181
8182 PR gdb/25534
8183 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
8184 if dependencies[i]->user != NULL.
8185
8186 2020-02-21 Ali Tamur <tamur@google.com>
8187
8188 * dwarf2/read.c (dwarf2_name): Add null check.
8189
8190 2020-02-20 Tom Tromey <tom@tromey.com>
8191
8192 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
8193 ">=", in binary search.
8194 (dwarf2_find_containing_comp_unit): New overload.
8195 (run_test): New self-test.
8196 (_initialize_dwarf2_read): Register new test.
8197
8198 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
8199
8200 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
8201 * riscv-tdep.h: Likewise.
8202 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
8203 rv32-only CSR.
8204 * features/riscv/64bit-csr.xml: Regenerated.
8205
8206 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
8207 Tom Tromey <tom@tromey.com>
8208
8209 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
8210 of 'fputc_unfiltered'.
8211 (putchar_unfiltered): Call 'fputc_unfiltered'.
8212 (fputc_unfiltered): Call 'fputs_unfiltered'.
8213
8214 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
8215
8216 * config.in: Regenerate.
8217 * configure: Regenerate.
8218 * configure.ac: Add --with-python-libdir option.
8219 * main.c: Use WITH_PYTHON_LIBDIR.
8220
8221 2020-02-19 Tom Tromey <tom@tromey.com>
8222
8223 * symtab.c (general_symbol_info::compute_and_set_names): Use
8224 obstack_strndup. Simplify call to symbol_set_demangled_name.
8225
8226 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
8227
8228 * dwarf2/read.c (allocate_signatured_type_table,
8229 allocate_dwo_unit_table, allocate_type_unit_groups_table,
8230 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
8231 Remove objfile parameter, update all callers.
8232
8233 2020-02-19 Doug Evans <dje@google.com>
8234
8235 PR rust/25535
8236 * rust-lang.c (rust_print_enum): Apply embedded_offset to
8237 rust_enum_variant calculation.
8238
8239 2020-02-19 Tom Tromey <tromey@adacore.com>
8240
8241 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
8242
8243 2020-02-19 Tom Tromey <tromey@adacore.com>
8244
8245 * ada-lang.c (cache_symbol): Use obstack_strdup.
8246
8247 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
8248
8249 * configure: Regenerate.
8250
8251 2020-02-19 Tom Tromey <tromey@adacore.com>
8252
8253 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
8254 NULL check.
8255
8256 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
8257
8258 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
8259
8260 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
8261
8262 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
8263 if GDBSERVER is not defined.
8264 (riscv_tdesc_cache): Likewise, also store const target_desc.
8265 (STATIC_IN_GDB): Define.
8266 (riscv_create_target_description): Update declaration with
8267 STATIC_IN_GDB.
8268 (riscv_lookup_target_description): New function, only define if
8269 GDBSERVER is not defined.
8270 * arch/riscv.h (riscv_create_target_description): Declare only
8271 when GDBSERVER is defined.
8272 (riscv_lookup_target_description): New declaration when GDBSERVER
8273 is not defined.
8274 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
8275 (riscv_linux_read_features): ...this, and return
8276 riscv_gdbarch_features instead of target_desc.
8277 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
8278 (riscv_linux_read_description): Rename to...
8279 (riscv_linux_read_features): ...this.
8280 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
8281 Update to use riscv_gdbarch_features and
8282 riscv_lookup_target_description.
8283 * riscv-tdep.c (riscv_find_default_target_description): Use
8284 riscv_lookup_target_description instead of
8285 riscv_create_target_description.
8286
8287 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8288
8289 * valprint.c (generic_val_print_enum_1): When printing a flag
8290 enum with value 0 and there is no enumerator with value 0, print
8291 just "0" instead of "(unknown: 0x0)".
8292
8293 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8294
8295 * valprint.c (generic_val_print_enum_1): Print unknown part of
8296 flag enum in hex.
8297
8298 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8299
8300 * dwarf2/read.c (update_enumeration_type_from_children): Allow
8301 flag enums to contain duplicate enumerators.
8302 * valprint.c (generic_val_print_enum_1): Update comment.
8303
8304 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8305
8306 * dwarf2/read.c: Include "count-one-bits.h".
8307 (update_enumeration_type_from_children): If an enumerator has
8308 multiple bits set, don't treat the enumeration as a "flag enum".
8309 * valprint.c (generic_val_print_enum_1): Assert that enumerators
8310 of flag enums have 0 or 1 bit set.
8311
8312 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
8313
8314 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
8315 conversion.
8316 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8317 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
8318 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8319 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
8320 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8321
8322 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
8323
8324 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
8325
8326 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8327
8328 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
8329 displaced_step_closure_up.
8330 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
8331 (struct displaced_step_closure_up):
8332 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8333 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
8334 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
8335 Likewise.
8336 * gdbarch.sh (displaced_step_copy_insn): Likewise.
8337 * gdbarch.c, gdbarch.h: Re-generate.
8338 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
8339 displaced_step_closure_up.
8340 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8341 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
8342 * infrun.h (displaced_step_closure_up): New type alias.
8343 (struct displaced_step_inferior_state) <step_closure>: Change
8344 type to displaced_step_closure_up.
8345 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
8346 displaced_step_closure_up.
8347 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8348
8349 2020-02-14 Tom Tromey <tom@tromey.com>
8350
8351 * minidebug.c (gnu_debug_key): New global.
8352 (find_separate_debug_file_in_section): Use it.
8353
8354 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8355
8356 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
8357 std::unique_ptr.
8358 * gdbarch.c: Re-generate.
8359 * gdbarch.h: Re-generate.
8360 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
8361 change.
8362 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
8363 type to std::unique_ptr.
8364 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
8365 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
8366 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
8367 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
8368 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
8369 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
8370 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
8371 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
8372 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
8373
8374 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8375
8376 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
8377 std::unique_ptr.
8378 (displaced_step_clear): Rename to...
8379 (displaced_step_reset): ... this. Just call displaced->reset ().
8380 (displaced_step_clear_cleanup): Rename to...
8381 (displaced_step_reset_cleanup): ... this.
8382 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
8383 (displaced_step_fixup): Likewise.
8384 (resume_1): Likewise.
8385 (handle_inferior_event): Restore child's memory before calling
8386 displaced_step_fixup on the parent.
8387 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
8388 to std::unique_ptr.
8389 <step_closure>: Change type to std::unique_ptr.
8390
8391 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
8392
8393 * arm-tdep.c: Include count-one-bits.h.
8394 (cleanup_block_store_pc): Use count_one_bits.
8395 (cleanup_block_load_pc): Use count_one_bits.
8396 (arm_copy_block_xfer): Use count_one_bits.
8397 (thumb2_copy_block_xfer): Use count_one_bits.
8398 (thumb_copy_pop_pc_16bit): Use count_one_bits.
8399 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
8400 (thumb_get_next_pcs_raw): Use count_one_bits.
8401 (arm_get_next_pcs_raw): Use count_one_bits_l.
8402 * arch/arm.c (bitcount): Remove.
8403 * arch/arm.h (bitcount): Remove.
8404
8405 2020-02-14 Tom Tromey <tromey@adacore.com>
8406
8407 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
8408 Update.
8409 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
8410 * dwarf2/loc.c (call_site_find_chain_1): Return
8411 unique_xmalloc_ptr.
8412 (call_site_find_chain): Likewise.
8413
8414 2020-02-14 Richard Biener <rguenther@suse.de>
8415
8416 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
8417 on expression with division operators.
8418
8419 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8420
8421 * MAINTAINERS (Write After Approval): Adding myself.
8422
8423 2020-02-12 Tom Tromey <tom@tromey.com>
8424
8425 * event-loop.c (event_data, gdb_event, event_handler_func):
8426 Remove.
8427
8428 2020-02-12 Tom Tromey <tom@tromey.com>
8429
8430 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
8431 (dwarf2_frame_objfile_data): Add comment.
8432 (find_comp_unit, set_comp_unit): New functions.
8433 (dwarf2_frame_find_fde): Use find_comp_unit.
8434 (dwarf2_build_frame_info): Use set_comp_unit.
8435
8436 2020-02-12 Tom Tromey <tom@tromey.com>
8437
8438 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
8439 (comp_unit): Don't initialize objfile.
8440 (execute_cfa_program): Add text_offset parameter.
8441 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
8442 (dwarf2_frame_cache): Update.
8443 (dwarf2_build_frame_info): Don't set "objfile" member.
8444
8445 2020-02-12 Tom Tromey <tom@tromey.com>
8446
8447 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
8448 (decode_frame_entry): Likewise.
8449 (dwarf2_build_frame_info): Update.
8450
8451 2020-02-12 Tom Tromey <tom@tromey.com>
8452
8453 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
8454 (decode_frame_entry_1): Use the comp_unit obstack.
8455
8456 2020-02-12 Tom Tromey <tom@tromey.com>
8457
8458 * dwarf2/frame.c (struct comp_unit): Add initializers and
8459 constructor.
8460 (dwarf2_frame_objfile_data): Store a comp_unit.
8461 (dwarf2_frame_find_fde): Update.
8462 (dwarf2_build_frame_info): Use "new".
8463
8464 2020-02-12 Tom Tromey <tom@tromey.com>
8465
8466 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
8467 (dwarf2_fde_table): Typedef for std::vector.
8468 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
8469 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
8470 (decode_frame_entry): Update.
8471 (dwarf2_build_frame_info): Use "new".
8472
8473 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8474
8475 * arm-tdep.c (arm_gdbarch_init): Update.
8476 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
8477 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
8478 have_neon, is_m>: Change to bool.
8479
8480 2020-02-12 Christian Biesinger <cbiesinger@google.com>
8481
8482 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
8483
8484 2020-02-12 Tom Tromey <tom@tromey.com>
8485
8486 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
8487
8488 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
8489
8490 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
8491 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
8492
8493 2020-02-11 Tom Tromey <tom@tromey.com>
8494
8495 * psymtab.h: Update comment.
8496
8497 2020-02-11 Tom Tromey <tom@tromey.com>
8498
8499 * gdb_obstack.h (struct auto_obstack): Use
8500 DISABLE_COPY_AND_ASSIGN.
8501
8502 2020-02-11 Tom Tromey <tom@tromey.com>
8503
8504 * dwarf2/frame.h (struct objfile): Don't forward declare.
8505
8506 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8507
8508 * cris-tdep.c (cris_supply_gregset): Change signature to match
8509 what struct regset expects.
8510 (cris_regset): New struct.
8511 (fetch_core_registers): Remove.
8512 (cris_iterate_over_regset_sections): New function.
8513 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
8514 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
8515
8516 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8517
8518 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
8519 registers.
8520
8521 2020-02-11 Christian Biesinger <cbiesinger@google.com>
8522
8523 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
8524
8525 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8526
8527 * configure: Re-generate.
8528
8529 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8530
8531 * configure: Re-generate.
8532
8533 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
8534
8535 * acinclude: Update warning.m4 path.
8536 * warning.m4: Move to gdbsupport.
8537
8538 2020-02-11 Tom Tromey <tromey@adacore.com>
8539
8540 * remote.c (remote_console_output): Update.
8541 * printcmd.c (printf_command): Update.
8542 * event-loop.c (gdb_wait_for_event): Update.
8543 * linux-nat.c (sigchld_handler): Update.
8544 * remote-sim.c (gdb_os_write_stdout): Update.
8545 (gdb_os_flush_stdout): Update.
8546 (gdb_os_flush_stderr): Update.
8547 (gdb_os_write_stderr): Update.
8548 * exceptions.c (print_exception): Update.
8549 * remote-fileio.c (remote_fileio_func_read): Update.
8550 (remote_fileio_func_write): Update.
8551 * tui/tui.c (tui_enable): Update.
8552 * tui/tui-interp.c (tui_interp::init): Update.
8553 * utils.c (init_page_info): Update.
8554 (putchar_unfiltered, fputc_unfiltered): Update.
8555 (gdb_flush): Update.
8556 (emit_style_escape): Update.
8557 (flush_wrap_buffer, fputs_maybe_filtered): Update.
8558 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
8559 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
8560 (stderr_file::write): Update.
8561 (stderr_file::puts): Update.
8562 * ui-file.h (ui_file_isatty, ui_file_write)
8563 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
8564 (ui_file_puts): Don't declare.
8565
8566 2020-02-10 Tom de Vries <tdevries@suse.de>
8567
8568 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
8569 sentinel to char *.
8570
8571 2020-02-09 Tom de Vries <tdevries@suse.de>
8572
8573 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
8574 filename if it matches "<artificial>".
8575
8576 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
8577
8578 * windows-tdep.c (struct enum_value_name): New struct.
8579 (create_enum): New function.
8580 (windows_get_siginfo_type): Create and use enum types.
8581
8582 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
8583
8584 * NEWS: Mention $_siginfo support for Windows.
8585 * windows-nat.c (handle_exception): Set siginfo_er.
8586 (windows_nat_target::mourn_inferior): Reset siginfo_er.
8587 (windows_xfer_siginfo): New function.
8588 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
8589 * windows-tdep.c (struct windows_gdbarch_data): New struct.
8590 (init_windows_gdbarch_data): New function.
8591 (get_windows_gdbarch_data): New function.
8592 (windows_get_siginfo_type): New function.
8593 (windows_init_abi): Register windows_get_siginfo_type.
8594 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
8595
8596 2020-02-08 Tom Tromey <tom@tromey.com>
8597
8598 * dwarf2/read.c (class cutu_reader) <cutu_reader,
8599 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
8600 <keep>: Declare method.
8601 <m_keep>: Remove member.
8602 <~cutu_reader>: Remove.
8603 (cutu_reader::init_tu_and_read_dwo_dies): Update.
8604 (cutu_reader::cutu_reader): Update.
8605 (cutu_reader::keep): Rename from ~cutu_reader.
8606 (process_psymtab_comp_unit, build_type_psymtabs_1)
8607 (process_skeletonless_type_unit, load_partial_comp_unit)
8608 (load_full_comp_unit, dwarf2_read_addr_index)
8609 (read_signatured_type): Update.
8610
8611 2020-02-08 Tom Tromey <tom@tromey.com>
8612
8613 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
8614 "want_partial_unit" parameter.
8615 (process_psymtab_comp_unit): Change want_partial_unit to bool.
8616 Inline check for DW_TAG_partial_unit.
8617 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
8618
8619 2020-02-08 Tom Tromey <tom@tromey.com>
8620
8621 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
8622 read.c.
8623 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
8624 read.c.
8625
8626 2020-02-08 Tom Tromey <tom@tromey.com>
8627
8628 * dwarf2/read.c (read_address): Move to comp-unit.c.
8629 (dwarf2_rnglists_process, dwarf2_ranges_process)
8630 (read_attribute_value, dwarf_decode_lines_1)
8631 (var_decode_location, decode_locdesc): Update.
8632 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
8633 read.c. Remove "cu" parameter.
8634 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
8635 method.
8636
8637 2020-02-08 Tom Tromey <tom@tromey.com>
8638
8639 * dwarf2/read.c (read_attribute_value, read_indirect_string)
8640 (read_indirect_line_string): Update.
8641 * dwarf2/comp-unit.c (read_offset): Remove.
8642 (read_comp_unit_head): Update.
8643 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
8644 method.
8645 (read_offset): Don't declare.
8646
8647 2020-02-08 Tom Tromey <tom@tromey.com>
8648
8649 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
8650 * dwarf2/read.c (struct comp_unit_head): Move to
8651 dwarf2/comp-unit.h.
8652 (enum class rcuh_kind): Move to comp-unit.h.
8653 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
8654 (read_comp_unit_head, error_check_comp_unit_head)
8655 (read_and_check_comp_unit_head): Move to comp-unit.c.
8656 (read_offset, dwarf_unit_type_name): Likewise.
8657 (create_debug_type_hash_table, read_cutu_die_from_dwo)
8658 (cutu_reader::cutu_reader, read_call_site_scope)
8659 (find_partial_die, follow_die_offset): Update.
8660 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
8661
8662 2020-02-08 Tom Tromey <tom@tromey.com>
8663
8664 * dwarf2/read.c (read_offset_1): Move to leb.c.
8665 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
8666 (dwarf_decode_macro_bytes): Update.
8667 * dwarf2/leb.c (read_offset): Rename; move from read.c.
8668 * dwarf2/leb.h (read_offset): Declare.
8669
8670 2020-02-08 Tom Tromey <tom@tromey.com>
8671
8672 * dwarf2/read.c (dwarf2_section_size): Remove.
8673 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
8674 Update.
8675 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
8676
8677 2020-02-08 Tom Tromey <tom@tromey.com>
8678
8679 * dwarf2/read.c (read_initial_length): Move to leb.c.
8680 * dwarf2/leb.h (read_initial_length): Declare.
8681 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
8682 handle_nonstd parameter.
8683 * dwarf2/frame.c (read_initial_length): Remove.
8684 (decode_frame_entry_1): Update.
8685
8686 2020-02-08 Tom Tromey <tom@tromey.com>
8687
8688 * dwarf2/loc.c (dwarf2_find_location_expression)
8689 (dwarf_evaluate_loc_desc::get_tls_address)
8690 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
8691 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
8692 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
8693 (dwarf2_compile_property_to_c)
8694 (dwarf2_loc_desc_get_symbol_read_needs)
8695 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
8696 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
8697 (loclist_describe_location, loclist_tracepoint_var_ref)
8698 (loclist_generate_c_location): Update.
8699 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
8700 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
8701 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
8702 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
8703 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
8704 (dwarf2_per_cu_data::addr_size)
8705 (dwarf2_per_cu_data::ref_addr_size)
8706 (dwarf2_per_cu_data::text_offset)
8707 (dwarf2_per_cu_data::addr_type): Now methods.
8708 (per_cu_header_read_in): Make per_cu "const".
8709 (dwarf2_version): Remove.
8710 (dwarf2_per_cu_data::int_type): Now a method.
8711 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
8712 (set_die_type, read_array_type, read_subrange_index_type)
8713 (read_tag_string_type, read_subrange_type): Update.
8714 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
8715 offset_size, ref_addr_size, text_offset, addr_type, version,
8716 objfile, int_type, addr_sized_int_type>: Declare methods.
8717
8718 2020-02-08 Tom Tromey <tom@tromey.com>
8719
8720 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
8721 Move earlier.
8722
8723 2020-02-08 Tom Tromey <tom@tromey.com>
8724
8725 * dwarf2/read.h (dwarf_line_debug): Declare.
8726 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
8727 * dwarf2/read.c: Move line_header code to new files.
8728 (dwarf_line_debug): No longer static.
8729 * dwarf2/line-header.c: New file.
8730 * dwarf2/line-header.h: New file.
8731
8732 2020-02-08 Tom Tromey <tom@tromey.com>
8733
8734 * dwarf2/read.c (struct line_header) <file_full_name,
8735 file_file_name>: Return unique_xmalloc_ptr.
8736 (line_header::file_file_name): Update.
8737 (line_header::file_full_name): Update.
8738 (dw2_get_file_names_reader): Update.
8739 (macro_start_file): Update.
8740
8741 2020-02-08 Tom Tromey <tom@tromey.com>
8742
8743 * dwarf2/read.c (struct line_header) <file_full_name,
8744 file_file_name>: Declare methods.
8745 (dw2_get_file_names_reader): Update.
8746 (file_file_name): Now a method.
8747 (file_full_name): Likewise.
8748 (macro_start_file): Update.
8749
8750 2020-02-08 Tom Tromey <tom@tromey.com>
8751
8752 * dwarf2/read.c (dwarf_always_disassemble)
8753 (show_dwarf_always_disassemble): Move to loc.c.
8754 (_initialize_dwarf2_read): Move "always-disassemble" registration
8755 to loc.c.
8756 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
8757 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
8758 static.
8759 (show_dwarf_always_disassemble): Move from read.c.
8760 (_initialize_dwarf2loc): Move always-disassemble from read.c.
8761
8762 2020-02-08 Tom Tromey <tom@tromey.com>
8763
8764 * dwarf2/read.c (~dwarf2_per_objfile): Update.
8765 (create_quick_file_names_table): Return htab_up.
8766 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
8767 Update.
8768 * dwarf2/read.h (struct dwarf2_per_objfile)
8769 <quick_file_names_table>: Now htab_up.
8770
8771 2020-02-08 Tom Tromey <tom@tromey.com>
8772
8773 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
8774
8775 2020-02-08 Tom Tromey <tom@tromey.com>
8776
8777 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
8778 Rewrite.
8779 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
8780 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
8781 (abbrev_table::abbrev_table): No longer inline.
8782 (ABBREV_HASH_SIZE): Remove.
8783 (abbrev_table::m_abbrevs): Now an htab_up.
8784
8785 2020-02-08 Tom Tromey <tom@tromey.com>
8786
8787 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
8788 (cutu_reader): Update.
8789 (build_type_psymtabs_1): Update.
8790 * dwarf2/abbrev.c (abbrev_table::read): Rename.
8791 (abbrev_table::alloc_abbrev): Update.
8792 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
8793 (abbrev_table::read): New static method, renamed from
8794 abbrev_table_read_table.
8795 (abbrev_table::alloc_abbrev)
8796 (abbrev_table::add_abbrev): Now private.
8797 (abbrev_table::abbrev_table): Now private.
8798 (abbrev_table::m_abbrev_obstack): Now private. Rename.
8799
8800 2020-02-08 Tom Tromey <tom@tromey.com>
8801
8802 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
8803 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
8804 htab_up.
8805
8806 2020-02-08 Tom Tromey <tom@tromey.com>
8807
8808 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
8809 htab_up.
8810 (lookup_dwo_unit_in_dwp): Update.
8811 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
8812 on obstack.
8813
8814 2020-02-08 Tom Tromey <tom@tromey.com>
8815
8816 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
8817 obstack.
8818
8819 2020-02-08 Tom Tromey <tom@tromey.com>
8820
8821 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
8822 line_header_hash.
8823 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
8824 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
8825 Change type to htab_up.
8826
8827 2020-02-08 Tom Tromey <tom@tromey.com>
8828
8829 * dwarf2/read.c (allocate_type_unit_groups_table): Return
8830 htab_up. Don't allocate on obstack.
8831 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
8832 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
8833 Change type to htab_up.
8834
8835 2020-02-08 Tom Tromey <tom@tromey.com>
8836
8837 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
8838 Change type to htab_up.
8839 * dwarf2/read.c (create_signatured_type_table_from_index)
8840 (create_signatured_type_table_from_debug_names)
8841 (create_all_type_units, add_type_unit)
8842 (lookup_dwo_signatured_type, lookup_signatured_type)
8843 (process_skeletonless_type_unit): Update.
8844 (create_debug_type_hash_table, create_debug_types_hash_table):
8845 Change type of types_htab.
8846 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
8847 htab_up. Don't allocate on obstack.
8848 (create_cus_hash_table): Change type of cus_htab parameter.
8849 (struct dwo_file) <cus, tus>: Now htab_up.
8850 (lookup_dwo_signatured_type, lookup_dwo_cutu)
8851 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
8852 (queue_and_load_all_dwo_tus): Update.
8853 * dwarf2/index-write.c (write_gdbindex): Update.
8854 (write_debug_names): Update.
8855
8856 2020-02-08 Tom Tromey <tom@tromey.com>
8857
8858 * dwarf2/read.h (struct dwarf2_queue_item): Move from
8859 dwarf2/read.c. Remove "next" member. Add constructor ntad
8860 destructor.
8861 (struct dwarf2_per_objfile) <queue>: New member.
8862 * dwarf2/read.c (struct dwarf2_queue_item): Move to
8863 dwarf2/read.h.
8864 (dwarf2_queue, dwarf2_queue_tail): Remove.
8865 (class dwarf2_queue_guard): Add parameter to constructor. Use
8866 DISABLE_COPY_AND_ASSIGN.
8867 <m_per_objfile>: New member.
8868 <~dwarf2_queue_guard>: Rewrite.
8869 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
8870 Update.
8871 (~dwarf2_queue_item): New.
8872
8873 2020-02-08 Tom Tromey <tom@tromey.com>
8874
8875 * dwarf2/read.c (struct die_info) <has_children>: New member.
8876 (dw2_get_file_names_reader): Remove has_children.
8877 (dw2_get_file_names): Update.
8878 (read_cutu_die_from_dwo): Remove has_children.
8879 (cutu_reader::init_tu_and_read_dwo_dies)
8880 (cutu_reader::cutu_reader): Update.
8881 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
8882 Remove has_children.
8883 (build_type_psymtabs_1, process_skeletonless_type_unit)
8884 (load_partial_comp_unit, load_full_comp_unit): Update.
8885 (create_dwo_cu_reader): Remove has_children.
8886 (create_cus_hash_table, read_die_and_children): Update.
8887 (read_full_die_1,read_full_die): Remove has_children.
8888 (read_signatured_type): Update.
8889 (class cutu_reader) <has_children>: Remove.
8890
8891 2020-02-08 Tom Tromey <tom@tromey.com>
8892
8893 * dwarf2/expr.c: Rename from dwarf2expr.c.
8894 * dwarf2/expr.h: Rename from dwarf2expr.h.
8895 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
8896 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
8897 * dwarf2/frame.c: Rename from dwarf2-frame.c.
8898 * dwarf2/frame.h: Rename from dwarf2-frame.h.
8899 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
8900 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
8901 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
8902 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
8903 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
8904 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
8905 * dwarf2/loc.c: Rename from dwarf2loc.c.
8906 * dwarf2/loc.h: Rename from dwarf2loc.h.
8907 * dwarf2/read.c: Rename from dwarf2read.c.
8908 * dwarf2/read.h: Rename from dwarf2read.h.
8909 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
8910 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
8911 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
8912 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
8913 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
8914 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
8915 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
8916 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
8917 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
8918 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
8919 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
8920 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
8921 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
8922 Update.
8923 * Makefile.in (COMMON_SFILES): Update.
8924 (HFILES_NO_SRCDIR): Update.
8925
8926 2020-02-08 Tom Tromey <tom@tromey.com>
8927
8928 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
8929 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
8930
8931 2020-02-08 Tom Tromey <tom@tromey.com>
8932
8933 * dwarf2read.h (struct die_info): Don't declare.
8934
8935 2020-02-08 Tom Tromey <tom@tromey.com>
8936
8937 * dwarf2read.h (die_info_ptr): Remove typedef.
8938
8939 2020-02-08 Tom Tromey <tom@tromey.com>
8940
8941 * dwarf2read.c (read_call_site_scope)
8942 (handle_data_member_location, dwarf2_add_member_fn)
8943 (mark_common_block_symbol_computed, read_common_block)
8944 (attr_to_dynamic_prop, partial_die_info::read)
8945 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
8946 (dwarf2_symbol_mark_computed, set_die_type): Update.
8947 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
8948 method.
8949 (attr_form_is_block): Don't declare.
8950 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
8951
8952 2020-02-08 Tom Tromey <tom@tromey.com>
8953
8954 * dwarf2read.c (dwarf2_find_base_address, )
8955 (read_call_site_scope, rust_containing_type)
8956 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
8957 (handle_data_member_location, dwarf2_add_member_fn)
8958 (get_alignment, read_structure_type, process_structure_scope)
8959 (mark_common_block_symbol_computed, read_common_block)
8960 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
8961 (partial_die_info::read, read_attribute_value, new_symbol)
8962 (lookup_die_type, dwarf2_get_ref_die_offset)
8963 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
8964 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
8965 (dwarf2_symbol_mark_computed): Update.
8966 * dwarf2/attribute.h (struct attribute) <value_as_address,
8967 form_is_section_offset, form_is_constant, form_is_ref>: Declare
8968 methods.
8969 (value_as_address, attr_form_is_section_offset)
8970 (attr_form_is_constant, attr_form_is_ref): Don't declare.
8971 * dwarf2/attribute.c (attribute::value_as_address)
8972 (attribute::form_is_section_offset, attribute::form_is_constant)
8973 (attribute::form_is_ref): Now methods.
8974
8975 2020-02-08 Tom Tromey <tom@tromey.com>
8976
8977 * dwarf2read.c (struct attribute, DW_STRING)
8978 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
8979 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
8980 (attr_form_is_block, attr_form_is_section_offset)
8981 (attr_form_is_constant, attr_form_is_ref): Move.
8982 * dwarf2/attribute.h: New file.
8983 * dwarf2/attribute.c: New file, from dwarf2read.c.
8984 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
8985
8986 2020-02-08 Tom Tromey <tom@tromey.com>
8987
8988 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
8989 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
8990 Move.
8991 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
8992 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
8993 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
8994 abbrev.c.
8995 * dwarf2/abbrev.h: New file.
8996 * dwarf2/abbrev.c: New file, from dwarf2read.c.
8997 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
8998
8999 2020-02-08 Tom Tromey <tom@tromey.com>
9000
9001 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
9002 (dwarf2_section_size, dwarf2_get_section_info)
9003 (create_signatured_type_table_from_debug_names)
9004 (create_addrmap_from_aranges, read_debug_names_from_section)
9005 (get_gdb_index_contents_from_section, read_comp_unit_head)
9006 (error_check_comp_unit_head, read_abbrev_offset)
9007 (create_debug_type_hash_table, init_cu_die_reader)
9008 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
9009 (read_comp_units_from_section, create_cus_hash_table)
9010 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
9011 (create_dwp_v2_section, dwarf2_rnglists_process)
9012 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
9013 (abbrev_table_read_table, read_indirect_string_at_offset_from)
9014 (read_indirect_string_from_dwz, read_addr_index_1)
9015 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
9016 (dwarf_decode_macro_bytes, dwarf_decode_macros)
9017 (fill_in_loclist_baton): Update.
9018 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
9019 get_containing_section, get_bfd_owner, get_bfd_section,
9020 get_file_name, get_id, get_flags, empty, read>: Declare methods.
9021 (dwarf2_read_section, get_section_name, get_section_file_name)
9022 (get_containing_section, get_section_bfd_owner)
9023 (get_section_bfd_section, get_section_name, get_section_file_name)
9024 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
9025 declare.
9026 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
9027 (dwarf2_section_info::get_bfd_owner)
9028 (dwarf2_section_info::get_bfd_section)
9029 (dwarf2_section_info::get_name)
9030 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
9031 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
9032 (dwarf2_section_info::read): Now methods.
9033 * dwarf-index-write.c (class debug_names): Update.
9034
9035 2020-02-08 Tom Tromey <tom@tromey.com>
9036
9037 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
9038 Move to dwarf2/section.h.
9039 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
9040 (get_section_bfd_section, get_section_name)
9041 (get_section_file_name, get_section_id, get_section_flags)
9042 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
9043 dwarf2/section.c.
9044 * dwarf2/section.h: New file.
9045 * dwarf2/section.c: New file, from dwarf2read.c.
9046 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
9047
9048 2020-02-08 Tom Tromey <tom@tromey.com>
9049
9050 * dwarf2read.h (read_unsigned_leb128): Don't declare.
9051 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
9052 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
9053 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
9054 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
9055 * dwarf2/leb.h: New file, from dwarf2read.c.
9056 * dwarf2/leb.c: New file, from dwarf2read.c.
9057 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
9058 Remove.
9059 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
9060 (COMMON_SFILES): Add dwarf2/leb.c.
9061
9062 2020-02-08 Joel Brobecker <brobecker@adacore.com>
9063
9064 GDB 9.1 released.
9065
9066 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
9067
9068 PR gdb/25190:
9069 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
9070 * gdb/remote.c (remote_console_output): Update.
9071 * gdb/ui-file.c (fputs_unfiltered): Rename to...
9072 (ui_file_puts): ...this.
9073 * gdb/ui-file.h (ui_file_puts): Add declaration.
9074 * gdb/utils.c (emit_style_escape): Update.
9075 (flush_wrap_buffer): Update.
9076 (fputs_maybe_filtered): Update.
9077 (fputs_unfiltered): Add function.
9078
9079 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
9080
9081 * gdb/event-loop.c (gdb_wait_for_event): Update.
9082 * gdb/printcmd.c (printf_command): Update.
9083 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
9084 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
9085 (gdb_os_flush_stderr): Update.
9086 * gdb/remote.c (remote_console_output): Update.
9087 * gdb/ui-file.c (gdb_flush): Rename to...
9088 (ui_file_flush): ...this.
9089 (stderr_file::write): Update.
9090 (stderr_file::puts): Update.
9091 * gdb/ui-file.h (gdb_flush): Rename to...
9092 (ui_file_flush): ...this.
9093 * gdb/utils.c (gdb_flush): Add function.
9094 * gdb/utils.h (gdb_flush): Add declaration.
9095
9096 2020-02-07 Tom Tromey <tromey@adacore.com>
9097
9098 PR breakpoints/24915:
9099 * source.c (find_and_open_source): Do not check basenames_may_differ.
9100
9101 2020-02-07 Tom Tromey <tom@tromey.com>
9102
9103 * README: Update gdbserver documentation.
9104 * gdbserver: Move to top level.
9105 * configure.tgt (build_gdbserver): Remove.
9106 * configure.ac: Remove --enable-gdbserver.
9107 * configure: Rebuild.
9108 * Makefile.in (distclean): Don't mention gdbserver.
9109
9110 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
9111
9112 * source-cache.c (source_cache::ensure): Surround
9113 get_plain_source_lines with a try/catch.
9114 (source_cache::get_line_charpos): Get rid of try/catch
9115 and only check for the return value of "ensure".
9116 * tui/tui-source.c (tui_source_window::set_contents):
9117 Simplify "nlines" calculation.
9118
9119 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
9120
9121 * MAINTAINERS (Write After Approval): Add myself.
9122
9123 2020-02-05 Christian Biesinger <cbiesinger@google.com>
9124
9125 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
9126 function call.
9127
9128 2020-02-05 Christian Biesinger <cbiesinger@google.com>
9129
9130 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
9131
9132 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
9133
9134 * nat/riscv-linux-tdesc.h: New file.
9135 * nat/riscv-linux-tdesc.c: New file, taking code from...
9136 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
9137 ... here.
9138 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
9139 NATDEPFILES.
9140
9141 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
9142
9143 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
9144 we don't set the fake simulator ptid to the null_ptid.
9145
9146 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
9147
9148 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
9149 * gdbthread.h (class thread_info) <resumed>: Likewise.
9150 * infrun.c (resume_1): Likewise.
9151 (proceed): Likewise.
9152 (infrun_thread_stop_requested): Likewise.
9153 (stop_all_threads): Likewise.
9154 (handle_inferior_event): Likewise.
9155 (restart_threads): Likewise.
9156 (finish_step_over): Likewise.
9157 (keep_going_stepped_thread): Likewise.
9158 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
9159 (linux_handle_extended_wait): Likewise.
9160 * record-btrace.c (get_thread_current_frame_id): Likewise.
9161 * record-full.c (record_full_wait_1): Likewise.
9162 * remote.c (remote_target::process_initial_stop_replies): Likewise.
9163 * target.c (target_resume): Likewise.
9164 * thread.c (set_running_thread): Likewise.
9165
9166 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
9167
9168 * f-valprint.c (f77_print_array_1): Changed datatype of index
9169 variable to LONGEST from int to enable it to contain bound
9170 values correctly.
9171
9172 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
9173
9174 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
9175 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
9176 offsets according to FLEN determined.
9177 (riscv_linux_nat_target::read_description): Determine FLEN
9178 dynamically.
9179 (riscv_linux_nat_target::fetch_registers): Size regset buffer
9180 according to FLEN determined.
9181 (riscv_linux_nat_target::store_registers): Likewise.
9182
9183 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
9184
9185 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
9186 when reg->group is empty and reggroup is not.
9187
9188 2020-01-31 Tom Tromey <tromey@adacore.com>
9189
9190 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
9191 Call beneath target's mourn_inferior after unpushing.
9192
9193 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
9194
9195 PR tui/9765
9196 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
9197 have enough lines to fill the screen, still return the lowest
9198 address we found.
9199
9200 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
9201
9202 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
9203 '-', '<', and '>' commands.
9204
9205 2020-01-29 Pedro Alves <palves@redhat.com>
9206 Sergio Durigan Junior <sergiodj@redhat.com>
9207
9208 * infcmd.c (construct_inferior_arguments): Assert that
9209 'argc' is greater than 0.
9210
9211 2020-01-29 Luis Machado <luis.machado@linaro.org>
9212
9213 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
9214 (BRK_INSN_MASK): Define to 0xd4200000.
9215 (aarch64_program_breakpoint_here_p): New function.
9216 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
9217 * arch-utils.c (default_program_breakpoint_here_p): Moved from
9218 breakpoint.c.
9219 * arch-utils.h (default_program_breakpoint_here_p): Moved from
9220 breakpoint.h
9221 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
9222 call gdbarch_program_breakpoint_here_p.
9223 (program_breakpoint_here): Moved to arch-utils.c, renamed to
9224 default_program_breakpoint_here_p, changed return type to bool and
9225 simplified.
9226 * breakpoint.h (program_breakpoint_here): Moved prototype to
9227 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
9228 return type to bool.
9229 * gdbarch.c: Regenerate.
9230 * gdbarch.h: Regenerate.
9231 * gdbarch.sh (program_breakpoint_here_p): New method.
9232 * infrun.c (handle_signal_stop): Call
9233 gdbarch_program_breakpoint_here_p.
9234
9235 2020-01-26 Tom Tromey <tom@tromey.com>
9236
9237 * ctfread.c (struct ctf_fp_info): Reindent.
9238 (_initialize_ctfread): Remove.
9239
9240 2020-01-26 Tom Tromey <tom@tromey.com>
9241
9242 * psymtab.c (partial_map_expand_apply)
9243 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
9244 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
9245 (psym_print_stats, psym_expand_symtabs_for_function)
9246 (psym_map_symbol_filenames, psym_map_matching_symbols)
9247 (psym_expand_symtabs_matching)
9248 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
9249 (maintenance_check_psymtabs): Use new methods.
9250 * psympriv.h (struct partial_symtab) <readin_p,
9251 get_compunit_symtab>: New methods.
9252 <readin, compunit_symtab>: Remove members.
9253 (struct standard_psymtab): New.
9254 (struct legacy_psymtab): Derive from standard_psymtab.
9255 * dwarf2read.h (struct dwarf2_psymtab): Derive from
9256 standard_psymtab.
9257 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
9258
9259 2020-01-26 Tom Tromey <tom@tromey.com>
9260
9261 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
9262 read_dependencies. Add assert.
9263 * psymtab.c (partial_symtab::read_dependencies): New method.
9264 * psympriv.h (struct partial_symtab) <read_dependencies>: New
9265 method.
9266 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
9267 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
9268 read_dependencies.
9269 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
9270 Add assert.
9271
9272 2020-01-26 Tom Tromey <tom@tromey.com>
9273
9274 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
9275 Call expand_psymtab.
9276 (xcoff_read_symtab): Call expand_psymtab.
9277 (xcoff_start_psymtab, xcoff_end_psymtab): Set
9278 legacy_expand_psymtab.
9279 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
9280 method.
9281 (struct legacy_psymtab) <expand_psymtab>: Implement.
9282 <legacy_expand_psymtab>: New member.
9283 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
9284 (parse_partial_symbols): Set legacy_expand_psymtab.
9285 (psymtab_to_symtab_1): Change argument order. Call
9286 expand_psymtab.
9287 (new_psymtab): Set legacy_expand_psymtab.
9288 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
9289 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
9290 expand_psymtab.
9291 (dwarf2_psymtab::expand_psymtab): Rename from
9292 psymtab_to_symtab_1. Call expand_psymtab.
9293 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
9294 (dbx_end_psymtab): Likewise.
9295 (dbx_psymtab_to_symtab_1): Change argument order. Call
9296 expand_psymtab.
9297 (dbx_read_symtab): Call expand_psymtab.
9298 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
9299 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
9300 (ctf_psymtab::read_symtab): Call expand_psymtab.
9301
9302 2020-01-26 Tom Tromey <tom@tromey.com>
9303
9304 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
9305 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
9306 messages.
9307 * mdebugread.c (mdebug_read_symtab): Remove prints.
9308 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
9309 assert.
9310 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
9311
9312 2020-01-26 Tom Tromey <tom@tromey.com>
9313
9314 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
9315 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
9316 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
9317 legacy_symtab.
9318 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
9319 * psymtab.c (psymtab_to_symtab): Call method.
9320 (dump_psymtab): Update.
9321 * psympriv.h (struct partial_symtab): Add virtual destructor.
9322 <read_symtab>: New method.
9323 (struct legacy_symtab): New.
9324 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
9325 (struct pst_map) <pst>: Now a legacy_psymtab.
9326 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
9327 (new_psymtab): Use legacy_psymtab.
9328 * dwarf2read.h (struct dwarf2_psymtab): New.
9329 (struct dwarf2_per_cu_data) <psymtab>: Use it.
9330 * dwarf2read.c (dwarf2_create_include_psymtab)
9331 (dwarf2_build_include_psymtabs, create_type_unit_group)
9332 (create_partial_symtab, process_psymtab_comp_unit_reader)
9333 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
9334 (set_partial_user): Use dwarf2_psymtab.
9335 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
9336 (psymtab_to_symtab_1, process_full_comp_unit)
9337 (process_full_type_unit, dwarf2_ranges_read)
9338 (dwarf2_get_pc_bounds, psymtab_include_file_name)
9339 (dwarf_decode_lines): Use dwarf2_psymtab.
9340 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
9341 (add_address_entry_worker, write_one_signatured_type)
9342 (recursively_count_psymbols, recursively_write_psymbols)
9343 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
9344 (write_debug_names): Likewise.
9345 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
9346 <pst>: Now a legacy_psymtab.
9347 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
9348 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
9349 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
9350 * ctfread.c (struct ctf_psymtab): New.
9351 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
9352 ctf_psymtab.
9353 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
9354 (create_partial_symtab): Return a ctf_psymtab.
9355 (scan_partial_symbols): Update.
9356
9357 2020-01-26 Tom Tromey <tom@tromey.com>
9358
9359 * xcoffread.c (xcoff_start_psymtab): Use new.
9360 * psymtab.c (partial_symtab::partial_symtab): New constructor,
9361 renamed from start_psymtab_common.
9362 * psympriv.h (struct partial_symtab): Add new constructor.
9363 (start_psymtab_common): Don't declare.
9364 * mdebugread.c (parse_partial_symbols): Use new.
9365 * dwarf2read.c (create_partial_symtab): Use new.
9366 * dbxread.c (start_psymtab): Use new.
9367 * ctfread.c (create_partial_symtab): Use new.
9368
9369 2020-01-26 Tom Tromey <tom@tromey.com>
9370
9371 * xcoffread.c (xcoff_end_psymtab): Use new.
9372 * psymtab.c (start_psymtab_common): Use new.
9373 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
9374 Update.
9375 * psympriv.h (struct partial_symtab): Add parameters to
9376 constructor. Don't inline.
9377 (allocate_psymtab): Don't declare.
9378 * mdebugread.c (new_psymtab): Use new.
9379 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
9380 * dbxread.c (dbx_end_psymtab): Use new.
9381
9382 2020-01-26 Tom Tromey <tom@tromey.com>
9383
9384 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
9385 allocate_psymtab. Update documentation.
9386 * psymtab.c (psymtab_storage::install_psymtab): Rename from
9387 allocate_psymtab. Do not use new.
9388 (allocate_psymtab): Use new. Update.
9389
9390 2020-01-26 Tom Tromey <tom@tromey.com>
9391
9392 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
9393 * psymtab.c (psym_print_stats): Update.
9394 * psympriv.h (struct partial_symtab) <readin,
9395 psymtabs_addrmap_supported, anonymous>: Now bool.
9396 * mdebugread.c (psymtab_to_symtab_1): Update.
9397 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
9398 (build_type_psymtabs_reader, psymtab_to_symtab_1)
9399 (process_full_comp_unit, process_full_type_unit): Update.
9400 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
9401 * ctfread.c (psymtab_to_symtab): Update.
9402
9403 2020-01-26 Tom Tromey <tom@tromey.com>
9404
9405 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
9406 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
9407 * psymtab.c (psymtab_storage): Delete psymtabs.
9408 (psymtab_storage::allocate_psymtab): Use new.
9409 (psymtab_storage::discard_psymtab): Use delete.
9410 * psympriv.h (struct partial_symtab): Add constructor and
9411 initializers.
9412
9413 2020-01-26 Tom Tromey <tom@tromey.com>
9414
9415 * machoread.c: Do not include psympriv.h.
9416
9417 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9418
9419 * NEWS: Mention the new option and the set/show commands.
9420
9421 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
9422
9423 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
9424 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
9425 (validate_exec_file): New variables, enums, functions.
9426 (exec_file_locate_attach, print_section_info): Style the filenames.
9427 (_initialize_exec): Install show_exec_file_mismatch_command and
9428 set_exec_file_mismatch_command.
9429 * gdbcore.h (validate_exec_file): Declare.
9430 * infcmd.c (attach_command): Call validate_exec_file.
9431 * remote.c ( remote_target::remote_add_inferior): Likewise.
9432
9433 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9434
9435 * frame.c (find_frame_sal): Move call to get_next_frame into more
9436 inner scope.
9437 * inline-frame.c (inilne_state) <inline_state>: Update argument
9438 types.
9439 (inilne_state) <skipped_symbol>: Rename to...
9440 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
9441 (skip_inline_frames): Build vector of skipped symbols and use this
9442 to reate the inline_state.
9443 (inline_skipped_symbol): Add a comment and some assertions, fetch
9444 skipped symbol from the list.
9445
9446 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9447
9448 * buildsym.c (lte_is_less_than): Delete.
9449 (buildsym_compunit::end_symtab_with_blockvector): Create local
9450 lambda function to sort line table entries, and use
9451 std::stable_sort instead of std::sort.
9452 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
9453 markers when looking for a previous line.
9454
9455 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9456
9457 * dwarf2read.c (lnp_state_machine::record_line): Include
9458 end_sequence parameter in debug print out. Record the line if we
9459 are at an end_sequence marker even if it's not the start of a
9460 statement.
9461 * symmisc.c (maintenance_print_one_line_table): Print end of
9462 sequence markers with 'END' not '0'.
9463
9464 2020-01-24 Pedro Alves <palves@redhat.com>
9465
9466 PR gdb/25410
9467 * thread.c (scoped_restore_current_thread::restore): Use
9468 switch_to_inferior_no_thread.
9469 * exec.c: Include "progspace-and-thread.h".
9470 (add_target_sections, remove_target_sections):
9471 scoped_restore_current_pspace_and_thread instead of
9472 scoped_restore_current_thread.
9473 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
9474 and aspace to the inferior before calling clone_program_space.
9475 Remove stale comment.
9476
9477 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9478
9479 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
9480 (arm_netbsd_nat_target::fetch_registers): ...this.
9481 (arm_nbsd_nat_target::store_registers): Rename to...
9482 (arm_netbsd_nat_target::store_registers): ...this.
9483
9484 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9485
9486 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
9487 register_t.
9488
9489 2020-01-24 Christian Biesinger <cbiesinger@google.com>
9490
9491 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
9492 Update comment.
9493 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
9494 Likewise.
9495 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
9496 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
9497 the correct replacement (iterate_over_regset_sections).
9498 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
9499 Update comment.
9500
9501 2020-01-24 Graham Markall <graham.markall@embecosm.com>
9502
9503 PR gdb/23718
9504 * gdb/python/python.c (execute_gdb_command): Call
9505 async_enable_stdin in catch block.
9506
9507 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9508
9509 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
9510 SWITCH_THRU_ALL_UIS.
9511
9512 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
9513
9514 PR tui/9765
9515 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
9516 comment, add extra parameter, and update to store previous symbol
9517 when appropriate.
9518 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
9519 add extra parameter.
9520 * tui/tui-disasm.c (tui_disassemble): Update header comment,
9521 remove unneeded parameter, add try/catch around gdb_print_insn,
9522 rewrite to add items to asm_lines vector.
9523 (tui_find_backward_disassembly_start_address): New function.
9524 (tui_find_disassembly_address): Updated throughout.
9525 (tui_disasm_window::set_contents): Update for changes to
9526 tui_disassemble.
9527 (tui_disasm_window::do_scroll_vertical): No need to adjust the
9528 number of lines to scroll.
9529
9530 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
9531
9532 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
9533 (SECT_OFF_DATA): Likewise.
9534 (SECT_OFF_RODATA): Likewise.
9535 (SECT_OFF_TEXT): Likewise.
9536 (SECT_OFF_BSS): Likewise.
9537 (struct objfile) <text_section_offset, data_section_offset>: New
9538 methods.
9539 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
9540 objfile::text_section_offset.
9541 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
9542 * coffread.c (coff_symtab_read): Likewise.
9543 (enter_linenos): Likewise.
9544 (process_coff_symbol): Likewise.
9545 * ctfread.c (get_objfile_text_range): Likewise.
9546 * dtrace-probe.c (dtrace_probe::get_relocated_address):
9547 Use objfile::data_section_offset.
9548 * dwarf2-frame.c (execute_cfa_program): Use
9549 objfile::text_section_offset.
9550 (dwarf2_frame_find_fde): Likewise.
9551 * dwarf2read.c (create_addrmap_from_index): Likewise.
9552 (create_addrmap_from_aranges): Likewise.
9553 (dw2_find_pc_sect_compunit_symtab): Likewise.
9554 (process_psymtab_comp_unit_reader): Likewise.
9555 (add_partial_symbol): Likewise.
9556 (add_partial_subprogram): Likewise.
9557 (process_full_comp_unit): Likewise.
9558 (read_file_scope): Likewise.
9559 (read_func_scope): Likewise.
9560 (read_lexical_block_scope): Likewise.
9561 (read_call_site_scope): Likewise.
9562 (dwarf2_rnglists_process): Likewise.
9563 (dwarf2_ranges_process): Likewise.
9564 (dwarf2_ranges_read): Likewise.
9565 (dwarf_decode_lines_1): Likewise.
9566 (new_symbol): Likewise.
9567 (dwarf2_fetch_die_loc_sect_off): Likewise.
9568 (dwarf2_per_cu_text_offset): Likewise.
9569 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
9570 * hppa-tdep.c (read_unwind_info): Likewise.
9571 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
9572 * psympriv.h (struct partial_symtab): Likewise.
9573 * psymtab.c (find_pc_sect_psymtab): Likewise.
9574 * solib-svr4.c (enable_break): Likewise.
9575 * stap-probe.c (relocate_address): Use
9576 objfile::data_section_offset.
9577 * xcoffread.c (enter_line_range): Use
9578 objfile::text_section_offset.
9579 (read_xcoff_symtab): Likewise.
9580
9581 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
9582
9583 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
9584 declaration to narrower scopes.
9585
9586 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
9587
9588 * darwin-nat.h (struct darwin_exception_msg, enum
9589 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
9590 Move up.
9591 (class darwin_nat_target) <wait_1, check_new_threads,
9592 decode_exception_message, decode_message, stop_inferior,
9593 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
9594 * darwin-nat.c (darwin_check_new_threads): Rename to...
9595 (darwin_nat_target::check_new_threads): ... this.
9596 (darwin_suspend_inferior_it): Remove.
9597 (darwin_decode_exception_message): Rename to...
9598 (darwin_nat_target::decode_exception_message): ... this.
9599 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
9600 (darwin_decode_message): Rename to...
9601 (darwin_nat_target::decode_message): ... this.
9602 (cancel_breakpoint): Rename to...
9603 (darwin_nat_target::cancel_breakpoint): ... this.
9604 (darwin_wait): Rename to...
9605 (darwin_nat_target::wait_1): ... this. Use range-based for loop
9606 instead of iterate_over_inferiors.
9607 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
9608 (darwin_stop_inferior): Rename to...
9609 (darwin_nat_target::stop_inferior): ... this.
9610 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
9611 (darwin_init_thread_list): Rename to...
9612 (darwin_nat_target::init_thread_list): ... this.
9613 (darwin_ptrace_him): Rename to...
9614 (darwin_nat_target::ptrace_him): ... this.
9615 (darwin_nat_target::create_inferior): Pass lambda function to
9616 fork_inferior.
9617 (darwin_nat_target::detach): Call stop_inferior instead of
9618 darwin_stop_inferior.
9619 * fork-inferior.h (fork_inferior): Change init_trace_fun
9620 parameter to gdb::function_view.
9621 * fork-inferior.c (fork_inferior): Likewise.
9622
9623 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
9624
9625 * i386-cygwin-tdep.c (core_process_module_section): Update.
9626 * windows-nat.c (struct lm_info_windows): Add text_offset.
9627 (windows_xfer_shared_libraries): Update.
9628 * windows-tdep.c (windows_xfer_shared_library):
9629 Add text_offset_cached argument.
9630 * windows-tdep.h (windows_xfer_shared_library): Update.
9631
9632 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9633
9634 * gdbarch.sh: Add declaration for _initialize_gdbarch.
9635
9636 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9637
9638 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
9639 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
9640 replace with range-based for.
9641 (gdbsim_interrupt_inferior): Remove.
9642 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
9643 with a range-based for. Inline code from
9644 gdbsim_interrupt_inferior.
9645
9646 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
9647
9648 * infrun.c (proceed): Fix indentation.
9649
9650 2020-01-21 Tom Tromey <tromey@adacore.com>
9651
9652 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
9653 * python/python.c (python_extension_ops): Update.
9654 (gdbpy_colorize): New function.
9655 * python/lib/gdb/__init__.py (colorize): New function.
9656 * extension.h (ext_lang_colorize): Declare.
9657 * extension.c (ext_lang_colorize): New function.
9658 * extension-priv.h (struct extension_language_ops) <colorize>: New
9659 member.
9660 * cli/cli-style.c (_initialize_cli_style): Update help text.
9661
9662 2020-01-21 Luis Machado <luis.machado@linaro.org>
9663
9664 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
9665 <cond>: Change type to bool.
9666 (aarch64_displaced_step_b_cond): Update cond to use bool type.
9667 (aarch64_displaced_step_cb): Likewise.
9668 (aarch64_displaced_step_tb): Likewise.
9669
9670 2020-01-21 Luis Machado <luis.machado@linaro.org>
9671
9672 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
9673 output.
9674
9675 2020-01-21 Luis Machado <luis.machado@linaro.org>
9676
9677 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
9678 <pc_adjust>: Adjust the documentation.
9679 (aarch64_displaced_step_fixup): Check if PC really moved before
9680 adjusting it.
9681
9682 2020-01-19 Tom Tromey <tom@tromey.com>
9683
9684 * disasm.c (~gdb_disassembler): New destructor.
9685 (gdb_buffered_insn_length): Call disassemble_free_target.
9686 * disasm.h (class gdb_disassembler): Declare destructor. Use
9687 DISABLE_COPY_AND_ASSIGN.
9688
9689 2020-01-19 Tom Tromey <tom@tromey.com>
9690
9691 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
9692 (die_reader_func_ftype): Remove.
9693 (cutu_reader): New class.
9694 (dw2_get_file_names_reader): Remove "data" parameter.
9695 (dw2_get_file_names): Use cutu_reader.
9696 (create_debug_type_hash_table): Update.
9697 (read_cutu_die_from_dwo): Update comment.
9698 (lookup_dwo_unit): Add dwo_name parameter.
9699 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
9700 die_reader_func_ftype and data parameters.
9701 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
9702 Remove die_reader_func_ftype and data parameters.
9703 (~cutu_reader): New; from init_cutu_and_read_dies.
9704 (cutu_reader::cutu_reader): Rename from
9705 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
9706 and data parameters.
9707 (init_cutu_and_read_dies_simple): Remove.
9708 (struct process_psymtab_comp_unit_data): Remove.
9709 (process_psymtab_comp_unit_reader): Remove data parameter; add
9710 want_partial_unit and pretend_language parameters.
9711 (process_psymtab_comp_unit): Use cutu_reader.
9712 (build_type_psymtabs_reader): Remove data parameter.
9713 (build_type_psymtabs_1): Use cutu_reader.
9714 (process_skeletonless_type_unit): Likewise.
9715 (load_partial_comp_unit_reader): Remove.
9716 (load_partial_comp_unit): Use cutu_reader.
9717 (load_full_comp_unit_reader): Remove.
9718 (load_full_comp_unit): Use cutu_reader.
9719 (struct create_dwo_cu_data): Remove.
9720 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
9721 dwo_unit parameters.
9722 (create_cus_hash_table): Use cutu_reader.
9723 (struct dwarf2_read_addr_index_data): Remove.
9724 (dwarf2_read_addr_index_reader): Remove.
9725 (dwarf2_read_addr_index): Use cutu_reader.
9726 (read_signatured_type_reader): Remove.
9727 (read_signatured_type): Use cutu_reader.
9728
9729 2020-01-19 Tom Tromey <tom@tromey.com>
9730
9731 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
9732 * tui/tui-wingeneral.h (class tui_suppress_output): New.
9733 (tui_wrefresh): Declare.
9734 * tui/tui-wingeneral.c (suppress_output): New global.
9735 (tui_suppress_output, ~tui_suppress_output): New constructor and
9736 destructor.
9737 (tui_wrefresh): New function.
9738 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
9739 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
9740 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
9741 method.
9742 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
9743 tui_wrefresh.
9744 (tui_data_window::no_refresh): New method.
9745 (tui_data_item_window::refresh_window): Call tui_wrefresh.
9746 (tui_reg_command): Use tui_suppress_output
9747 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
9748 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
9749 method.
9750 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
9751
9752 2020-01-19 Tom Tromey <tom@tromey.com>
9753
9754 * tui/tui-winsource.c (tui_update_source_windows_with_line):
9755 Handle case where symtab is null.
9756
9757 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
9758
9759 * linux-fork.c (one_fork_p): Simplify.
9760
9761 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9762
9763 * top.c (struct qt_args): Remove.
9764 (kill_or_detach): Change return type to void, replace `void *`
9765 parameter with a proper one.
9766 (print_inferior_quit_action): Likewise.
9767 (quit_confirm): Use range-based for loop to iterate over inferiors.
9768 (quit_force): Likewise.
9769
9770 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9771
9772 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
9773 `void *` parameter with proper parameters.
9774 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
9775 (print_one_inferior): Change return type to void, replace `void *`
9776 parameter with proper parameters.
9777 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
9778 inferiors.
9779 (get_other_inferior): Remove.
9780 (mi_cmd_remove_inferior): Use range-based loop to iterate over
9781 inferiors.
9782
9783 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9784
9785 * mi/mi-interp.c (report_initial_inferior): Remove.
9786 (mi_interp::init): Use range-based for to iterate over inferiors.
9787
9788 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
9789
9790 * python/py-inferior.c (build_inferior_list): Remove.
9791 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
9792
9793 2020-01-16 Christian Biesinger <cbiesinger@google.com>
9794
9795 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
9796 (btrace_stitch_trace): Likewise.
9797 * charset.c (intermediate_encoding): Likewise (vaild).
9798 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
9799 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
9800 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
9801
9802 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
9803
9804 * windows-tdep.c (windows_get_tlb_type):
9805 Add rtl_user_process_parameters type.
9806
9807 2020-01-16 Pedro Alves <palves@redhat.com>
9808 Norbert Lange <nolange79@gmail.com>
9809
9810 PR build/24805
9811 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
9812 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
9813 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
9814 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
9815 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
9816 (ps_plog): Redeclare exported functions with default visibility.
9817
9818 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
9819
9820 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
9821 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
9822
9823 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
9824
9825 * infcmd.c (post_create_inferior): Use get_thread_regcache
9826 instead of get_current_regcache.
9827
9828 2020-01-14 Tom Tromey <tom@tromey.com>
9829
9830 PR symtab/12535:
9831 * python/python.c (gdbpy_decode_line): Treat empty string the same
9832 as no argument.
9833
9834 2020-01-14 Tom Tromey <tom@tromey.com>
9835
9836 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
9837
9838 2020-01-14 Tom Tromey <tom@tromey.com>
9839
9840 * nat/linux-btrace.c: Don't include <config.h>.
9841 * nat/linux-ptrace.c: Don't include <config.h>.
9842 * nat/x86-linux-dregs.c: Don't include <config.h>.
9843
9844 2020-01-14 Tom Tromey <tom@tromey.com>
9845
9846 * configure: Rebuild.
9847 * configure.ac: Move many checks to ../gdbsupport/common.m4.
9848
9849 2020-01-14 Tom Tromey <tom@tromey.com>
9850
9851 * nat/x86-linux-dregs.c: Include configh.h.
9852 * nat/linux-ptrace.c: Include configh.h.
9853 * nat/linux-btrace.c: Include configh.h.
9854 * defs.h: Include config.h, bfd.h.
9855 * configure.ac: Don't source common.host.
9856 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
9857 * configure: Rebuild.
9858 * acinclude.m4: Update path.
9859 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
9860 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
9861 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
9862 (CLIBS): Add LIBSUPPORT.
9863 (CDEPS): Likewise.
9864 (COMMON_SFILES): Remove gdbsupport files.
9865 (HFILES_NO_SRCDIR): Likewise.
9866 (stamp-version): Update path to create-version.sh.
9867 (ALLDEPFILES): Remove gdbsupport files.
9868
9869 2020-01-14 Tom Tromey <tom@tromey.com>
9870
9871 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
9872 USE_WIN32API when needed.
9873 * configure.ac (USE_WIN32API): Don't define.
9874 (WIN32LIBS): Use WIN32APILIBS.
9875 * configure: Rebuild.
9876
9877 2020-01-14 Tom Tromey <tom@tromey.com>
9878
9879 * configure: Rebuild.
9880 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
9881
9882 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
9883
9884 * skip.c (skip_function_command): Make skip w/o arguments use the
9885 name of the inlined function if pc is inside any inlined function.
9886
9887 2020-01-14 Luis Machado <luis.machado@linaro.org>
9888
9889 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
9890 * infrun.c (resume_1): Likewise.
9891 (handle_inferior_event): Remove stale comment.
9892 * linux-nat.c (linux_nat_target::resume): Update comments.
9893 (save_stop_reason): Likewise.
9894 (linux_nat_filter_event): Likewise.
9895 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
9896
9897 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9898
9899 * elfread.c (record_minimal_symbol): Set section index to 0 for
9900 non-allocatable sections.
9901
9902
9903 2020-01-13 Ali Tamur <tamur@google.com>
9904
9905 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
9906 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
9907 to gdb::optional. Update comments.
9908 (dwo_file): Update comments.
9909 (read_attribute): Update API to take an additional out parameter,
9910 need_reprocess. This is used to mark attributes that need other
9911 attributes (e.g. str_offsets_base) for correct computation which may not
9912 have been read yet.
9913 (read_attribute_reprocess): New function declaration.
9914 (read_addr_index): Likewise.
9915 (read_dwo_str_index): Likewise.
9916 (read_stub_str_index): Likewise.
9917 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
9918 (lookup_addr_base): New function definition.
9919 (lookup_ranges_base): Likewise.
9920 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
9921 lookup_ranges_base.
9922 (init_cutu_and_read_dies): Update comments.
9923 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
9924 unit. This is used to inherit parent's str_offsets_base and addr_base.
9925 Update comments.
9926 (init_cutu_and_read_dies_simple): Reflect API changes.
9927 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
9928 (create_cus_hash_table): Change API to take parent compile unit.
9929 Reflect API changes.
9930 (open_and_init_dwo_file): Reflect API changes.
9931 (dwarf2_get_pc_bounds): Update comments.
9932 (dwarf2_record_block_ranges): Likewise.
9933 (read_full_die_1): Change implementation to reprocess attributes that
9934 need str_offsets_base and addr_base.
9935 (partial_die_info::read): Likewise.
9936 (read_attribute_reprocess): New function definition.
9937 (read_attribute_value): Change API to take an additional out parameter,
9938 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
9939 when a non-dwo compile unit has index based attributes.
9940 (read_attribute): Reflect API changes.
9941 (read_addr_index_1): Reflect API changes. Update comments.
9942 (dwarf2_read_addr_index_data): Reflect API changes.
9943 (dwarf2_read_addr_index): Likewise.
9944 (read_str_index): Change API and implementation. This becomes a helper
9945 to be used by the new string index related methods. Update error
9946 message and comments.
9947 (read_dwo_str_index): New function definition.
9948 (read_stub_str_index): Likewise.
9949 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
9950 * symfile.h (dwarf2_debug_sections): Likewise.
9951 * xcoffread.c (dwarf2_debug_sections): Likewise.
9952
9953 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9954
9955 * gdbcore.h (struct core_fns) <core_read_registers>: Change
9956 core_reg_sect type to gdb_byte *.
9957 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
9958 * cris-tdep.c (fetch_core_registers): Likewise.
9959 * corelow.c (core_target::get_core_register_section): Change
9960 type of `contents` to gdb::byte_vector.
9961
9962 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
9963
9964 * tui/tui-wingeneral.c (box_win): Position the title in the center
9965 of the border.
9966
9967 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
9968
9969 * corelow.c (core_target::get_core_register_section): Use
9970 std::vector instead of alloca.
9971
9972 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9973
9974 * warning.m4: Add -Wmissing-declarations to build_warnings.
9975 * configure: Re-generate.
9976
9977 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9978
9979 * python/python.c (init__gdb_module): Add declaration.
9980
9981 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
9982
9983 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
9984 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
9985 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
9986 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
9987 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
9988 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
9989 * ada-exp.y (_initialize_ada_exp): Add declaration.
9990 * ada-lang.c (_initialize_ada_language): Add declaration.
9991 * ada-tasks.c (_initialize_tasks): Add declaration.
9992 * agent.c (_initialize_agent): Add declaration.
9993 * aix-thread.c (_initialize_aix_thread): Add declaration.
9994 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
9995 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
9996 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
9997 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
9998 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
9999 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
10000 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
10001 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
10002 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
10003 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
10004 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
10005 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
10006 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
10007 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
10008 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
10009 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
10010 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
10011 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
10012 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
10013 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
10014 * annotate.c (_initialize_annotate): Add declaration.
10015 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
10016 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
10017 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
10018 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
10019 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
10020 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
10021 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
10022 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
10023 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
10024 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
10025 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
10026 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
10027 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
10028 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
10029 * auto-load.c (_initialize_auto_load): Add declaration.
10030 * auxv.c (_initialize_auxv): Add declaration.
10031 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
10032 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
10033 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
10034 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
10035 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
10036 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
10037 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
10038 * breakpoint.c (_initialize_breakpoint): Add declaration.
10039 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
10040 * btrace.c (_initialize_btrace): Add declaration.
10041 * charset.c (_initialize_charset): Add declaration.
10042 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
10043 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
10044 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
10045 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
10046 * cli/cli-script.c (_initialize_cli_script): Add declaration.
10047 * cli/cli-style.c (_initialize_cli_style): Add declaration.
10048 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
10049 * coffread.c (_initialize_coffread): Add declaration.
10050 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
10051 * compile/compile.c (_initialize_compile): Add declaration.
10052 * complaints.c (_initialize_complaints): Add declaration.
10053 * completer.c (_initialize_completer): Add declaration.
10054 * copying.c (_initialize_copying): Add declaration.
10055 * corefile.c (_initialize_core): Add declaration.
10056 * corelow.c (_initialize_corelow): Add declaration.
10057 * cp-abi.c (_initialize_cp_abi): Add declaration.
10058 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
10059 * cp-support.c (_initialize_cp_support): Add declaration.
10060 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
10061 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
10062 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
10063 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
10064 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
10065 * ctfread.c (_initialize_ctfread): Add declaration.
10066 * d-lang.c (_initialize_d_language): Add declaration.
10067 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
10068 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
10069 * dbxread.c (_initialize_dbxread): Add declaration.
10070 * dcache.c (_initialize_dcache): Add declaration.
10071 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
10072 * disasm.c (_initialize_disasm): Add declaration.
10073 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
10074 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
10075 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
10076 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
10077 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
10078 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
10079 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
10080 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
10081 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
10082 * elfread.c (_initialize_elfread): Add declaration.
10083 * exec.c (_initialize_exec): Add declaration.
10084 * extension.c (_initialize_extension): Add declaration.
10085 * f-lang.c (_initialize_f_language): Add declaration.
10086 * f-valprint.c (_initialize_f_valprint): Add declaration.
10087 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
10088 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
10089 * filesystem.c (_initialize_filesystem): Add declaration.
10090 * findcmd.c (_initialize_mem_search): Add declaration.
10091 * findvar.c (_initialize_findvar): Add declaration.
10092 * fork-child.c (_initialize_fork_child): Add declaration.
10093 * frame-base.c (_initialize_frame_base): Add declaration.
10094 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
10095 * frame.c (_initialize_frame): Add declaration.
10096 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
10097 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
10098 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
10099 * gcore.c (_initialize_gcore): Add declaration.
10100 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
10101 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
10102 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
10103 * gdbarch.c (_initialize_gdbarch): Add declaration.
10104 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
10105 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
10106 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
10107 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
10108 * go-lang.c (_initialize_go_language): Add declaration.
10109 * go32-nat.c (_initialize_go32_nat): Add declaration.
10110 * guile/guile.c (_initialize_guile): Add declaration.
10111 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
10112 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
10113 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
10114 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
10115 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
10116 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
10117 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
10118 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
10119 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
10120 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
10121 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
10122 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
10123 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
10124 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
10125 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
10126 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
10127 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
10128 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
10129 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
10130 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
10131 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
10132 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
10133 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
10134 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
10135 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
10136 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
10137 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
10138 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
10139 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
10140 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
10141 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
10142 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
10143 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
10144 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
10145 * infcall.c (_initialize_infcall): Add declaration.
10146 * infcmd.c (_initialize_infcmd): Add declaration.
10147 * inflow.c (_initialize_inflow): Add declaration.
10148 * infrun.c (_initialize_infrun): Add declaration.
10149 * interps.c (_initialize_interpreter): Add declaration.
10150 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
10151 * jit.c (_initialize_jit): Add declaration.
10152 * language.c (_initialize_language): Add declaration.
10153 * linux-fork.c (_initialize_linux_fork): Add declaration.
10154 * linux-nat.c (_initialize_linux_nat): Add declaration.
10155 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
10156 * linux-thread-db.c (_initialize_thread_db): Add declaration.
10157 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
10158 * m2-lang.c (_initialize_m2_language): Add declaration.
10159 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
10160 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
10161 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
10162 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
10163 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
10164 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
10165 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
10166 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
10167 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
10168 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
10169 * machoread.c (_initialize_machoread): Add declaration.
10170 * macrocmd.c (_initialize_macrocmd): Add declaration.
10171 * macroscope.c (_initialize_macroscope): Add declaration.
10172 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
10173 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
10174 * maint.c (_initialize_maint_cmds): Add declaration.
10175 * mdebugread.c (_initialize_mdebugread): Add declaration.
10176 * memattr.c (_initialize_mem): Add declaration.
10177 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
10178 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
10179 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
10180 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
10181 * mi/mi-main.c (_initialize_mi_main): Add declaration.
10182 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
10183 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
10184 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
10185 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
10186 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
10187 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
10188 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
10189 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
10190 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
10191 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
10192 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
10193 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
10194 * mipsread.c (_initialize_mipsread): Add declaration.
10195 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
10196 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
10197 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
10198 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
10199 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
10200 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
10201 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
10202 * nto-procfs.c (_initialize_procfs): Add declaration.
10203 * objc-lang.c (_initialize_objc_language): Add declaration.
10204 * observable.c (_initialize_observer): Add declaration.
10205 * opencl-lang.c (_initialize_opencl_language): Add declaration.
10206 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
10207 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
10208 * osabi.c (_initialize_gdb_osabi): Add declaration.
10209 * osdata.c (_initialize_osdata): Add declaration.
10210 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
10211 * parse.c (_initialize_parse): Add declaration.
10212 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
10213 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
10214 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
10215 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
10216 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
10217 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
10218 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
10219 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
10220 * printcmd.c (_initialize_printcmd): Add declaration.
10221 * probe.c (_initialize_probe): Add declaration.
10222 * proc-api.c (_initialize_proc_api): Add declaration.
10223 * proc-events.c (_initialize_proc_events): Add declaration.
10224 * proc-service.c (_initialize_proc_service): Add declaration.
10225 * procfs.c (_initialize_procfs): Add declaration.
10226 * producer.c (_initialize_producer): Add declaration.
10227 * psymtab.c (_initialize_psymtab): Add declaration.
10228 * python/python.c (_initialize_python): Add declaration.
10229 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
10230 * record-btrace.c (_initialize_record_btrace): Add declaration.
10231 * record-full.c (_initialize_record_full): Add declaration.
10232 * record.c (_initialize_record): Add declaration.
10233 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
10234 * regcache.c (_initialize_regcache): Add declaration.
10235 * reggroups.c (_initialize_reggroup): Add declaration.
10236 * remote-notif.c (_initialize_notif): Add declaration.
10237 * remote-sim.c (_initialize_remote_sim): Add declaration.
10238 * remote.c (_initialize_remote): Add declaration.
10239 * reverse.c (_initialize_reverse): Add declaration.
10240 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
10241 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
10242 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
10243 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
10244 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
10245 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
10246 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
10247 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
10248 Add declaration.
10249 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
10250 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
10251 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
10252 * rust-exp.y (_initialize_rust_exp): Add declaration.
10253 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
10254 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
10255 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
10256 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
10257 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
10258 * score-tdep.c (_initialize_score_tdep): Add declaration.
10259 * ser-go32.c (_initialize_ser_dos): Add declaration.
10260 * ser-mingw.c (_initialize_ser_windows): Add declaration.
10261 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
10262 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
10263 * ser-uds.c (_initialize_ser_socket): Add declaration.
10264 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
10265 * serial.c (_initialize_serial): Add declaration.
10266 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
10267 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
10268 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
10269 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
10270 * skip.c (_initialize_step_skip): Add declaration.
10271 * sol-thread.c (_initialize_sol_thread): Add declaration.
10272 * solib-aix.c (_initialize_solib_aix): Add declaration.
10273 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
10274 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
10275 * solib-frv.c (_initialize_frv_solib): Add declaration.
10276 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
10277 * solib-target.c (_initialize_solib_target): Add declaration.
10278 * solib.c (_initialize_solib): Add declaration.
10279 * source-cache.c (_initialize_source_cache): Add declaration.
10280 * source.c (_initialize_source): Add declaration.
10281 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
10282 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
10283 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
10284 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
10285 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
10286 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
10287 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
10288 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
10289 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
10290 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
10291 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
10292 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
10293 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
10294 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
10295 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
10296 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
10297 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
10298 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
10299 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
10300 * stabsread.c (_initialize_stabsread): Add declaration.
10301 * stack.c (_initialize_stack): Add declaration.
10302 * stap-probe.c (_initialize_stap_probe): Add declaration.
10303 * std-regs.c (_initialize_frame_reg): Add declaration.
10304 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
10305 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
10306 * symfile.c (_initialize_symfile): Add declaration.
10307 * symmisc.c (_initialize_symmisc): Add declaration.
10308 * symtab.c (_initialize_symtab): Add declaration.
10309 * target.c (_initialize_target): Add declaration.
10310 * target-connection.c (_initialize_target_connection): Add
10311 declaration.
10312 * target-dcache.c (_initialize_target_dcache): Add declaration.
10313 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
10314 * thread.c (_initialize_thread): Add declaration.
10315 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
10316 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
10317 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
10318 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
10319 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
10320 * tracectf.c (_initialize_ctf): Add declaration.
10321 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
10322 * tracefile.c (_initialize_tracefile): Add declaration.
10323 * tracepoint.c (_initialize_tracepoint): Add declaration.
10324 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
10325 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
10326 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
10327 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
10328 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
10329 * tui/tui-win.c (_initialize_tui_win): Add declaration.
10330 * tui/tui.c (_initialize_tui): Add declaration.
10331 * typeprint.c (_initialize_typeprint): Add declaration.
10332 * ui-style.c (_initialize_ui_style): Add declaration.
10333 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
10334 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
10335 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
10336 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
10337 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
10338 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
10339 * unittests/filtered_iterator-selftests.c
10340 (_initialize_filtered_iterator_selftests): Add declaration.
10341 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
10342 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
10343 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
10344 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
10345 * unittests/main-thread-selftests.c
10346 (_initialize_main_thread_selftests): Add declaration.
10347 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
10348 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
10349 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
10350 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
10351 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
10352 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
10353 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
10354 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
10355 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
10356 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
10357 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
10358 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
10359 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
10360 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
10361 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
10362 declaration.
10363 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
10364 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
10365 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
10366 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
10367 * user-regs.c (_initialize_user_regs): Add declaration.
10368 * utils.c (_initialize_utils): Add declaration.
10369 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
10370 * valops.c (_initialize_valops): Add declaration.
10371 * valprint.c (_initialize_valprint): Add declaration.
10372 * value.c (_initialize_values): Add declaration.
10373 * varobj.c (_initialize_varobj): Add declaration.
10374 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
10375 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
10376 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
10377 * windows-nat.c (_initialize_windows_nat): Add declaration.
10378 (_initialize_check_for_gdb_ini): Add declaration.
10379 (_initialize_loadable): Add declaration.
10380 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
10381 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
10382 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
10383 * xcoffread.c (_initialize_xcoffread): Add declaration.
10384 * xml-support.c (_initialize_xml_support): Add declaration.
10385 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
10386 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
10387 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
10388 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
10389
10390 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10391
10392 * regformats/regdat.sh: Generate declaration for init function.
10393
10394 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
10395
10396 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
10397 up.
10398 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
10399 close_one_inferior>: New methods.
10400 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
10401 pass down target to find_inferior_pid.
10402 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
10403 Pass down target to find_inferior_ptid.
10404 (gdbsim_target::create_inferior): Pass down target to
10405 add_thread_silent.
10406 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
10407 target down to find_inferior_ptid and switch_to_thread.
10408 (gdbsim_target::close): Update to call close_one_inferior.
10409 (struct resume_data): Remove.
10410 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
10411 directly, rather than through a void pointer.
10412 (gdbsim_target::resume): Update to call resume_one_inferior.
10413
10414 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
10415
10416 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
10417
10418 2020-01-12 Pedro Alves <palves@redhat.com>
10419
10420 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
10421 directly for the current inferior instead of
10422 discard_all_inferiors.
10423 (discard_all_inferiors): Delete.
10424
10425 2020-01-11 Tom Tromey <tom@tromey.com>
10426
10427 * tui/tui-wingeneral.c (box_win): Check cli_styling.
10428 * tui/tui-winsource.c (tui_source_window_base::refill): Use
10429 deprecated_safe_get_selected_frame.
10430
10431 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10432
10433 * inferior.c (print_inferior): Switch inferior before printing it.
10434
10435 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
10436 Pedro Alves <palves@redhat.com>
10437
10438 * progspace-and-thread.c (switch_to_program_space_and_thread):
10439 Assert there's an inferior for PSPACE. Use
10440 switch_to_inferior_no_thread to switch the inferior too.
10441 * progspace.c (program_space::~program_space): Call
10442 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
10443 (program_space::free_all_objfiles): Don't call clear_symtab_users
10444 here.
10445 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
10446
10447 2020-01-10 Pedro Alves <palves@redhat.com>
10448
10449 * NEWS: Mention multi-target debugging, "info connections", and
10450 "add-inferior -no-connection".
10451
10452 2020-01-10 Pedro Alves <palves@redhat.com>
10453
10454 * infrun.c: Include "target-connection.h".
10455 (check_multi_target_resumption): New.
10456 (proceed): Call it.
10457 * target-connection.c (make_target_connection_string): Make
10458 extern.
10459 * target-connection.h (make_target_connection_string): Declare.
10460
10461 2020-01-10 Pedro Alves <palves@redhat.com>
10462
10463 * Makefile.in (COMMON_SFILES): Add target-connection.c.
10464 * inferior.c (uiout_field_connection): New function.
10465 (print_inferior): Add new "connection-id" column.
10466 (add_inferior_command): Show connection number/string of added
10467 inferior.
10468 * process-stratum-target.h
10469 (process_stratum_target::connection_string): New virtual method.
10470 (process_stratum_target::connection_number): New field.
10471 * remote.c (remote_target::connection_string): New override.
10472 * target-connection.c: New file.
10473 * target-connection.h: New file.
10474 * target.c (decref_target): Remove process_stratum targets from
10475 the connection list.
10476 (target_stack::push): Add process_stratum targets to the
10477 connection list.
10478
10479 2020-01-10 Pedro Alves <palves@redhat.com>
10480
10481 Revert:
10482 2016-04-12 Pedro Alves <palves@redhat.com>
10483 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
10484 Remove references to name.
10485 * serial.h (struct serial) <name>: Delete.
10486
10487 2020-01-10 Pedro Alves <palves@redhat.com>
10488
10489 * gdbarch-selftests.c (register_to_value_test): Remove "target
10490 already pushed" check.
10491
10492 2020-01-10 Pedro Alves <palves@redhat.com>
10493 John Baldwin <jhb@FreeBSD.org>
10494
10495 * aarch64-linux-nat.c
10496 (aarch64_linux_nat_target::thread_architecture): Adjust.
10497 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
10498 (task_command_1): Likewise.
10499 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
10500 (aix_thread_target::wait, aix_thread_target::fetch_registers)
10501 (aix_thread_target::store_registers)
10502 (aix_thread_target::thread_alive): Adjust.
10503 * amd64-fbsd-tdep.c: Include "inferior.h".
10504 (amd64fbsd_get_thread_local_address): Pass down target.
10505 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
10506 thread's gdbarch instead of target_gdbarch.
10507 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
10508 get_last_target_status.
10509 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
10510 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
10511 inferiors.
10512 (update_inserted_breakpoint_locations): Skip if inferiors with no
10513 execution.
10514 (update_global_location_list): When handling moribund locations,
10515 find representative inferior for location's pspace, and use thread
10516 count of its process_stratum target.
10517 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
10518 * bsd-uthread.c (bsd_uthread_target::wait): Use
10519 as_process_stratum_target and adjust thread_change_ptid and
10520 add_thread calls.
10521 (bsd_uthread_target::update_thread_list): Use
10522 as_process_stratum_target and adjust find_thread_ptid,
10523 thread_change_ptid and add_thread calls.
10524 * btrace.c (maint_btrace_packet_history_cmd): Adjust
10525 find_thread_ptid call.
10526 * corelow.c (add_to_thread_list): Adjust add_thread call.
10527 (core_target_open): Adjust add_thread_silent and thread_count
10528 calls.
10529 (core_target::pid_to_str): Adjust find_inferior_ptid call.
10530 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
10531 * event-top.c (async_disconnect): Pop targets from all inferiors.
10532 * exec.c (add_target_sections): Push exec target on all inferiors
10533 sharing the program space.
10534 (remove_target_sections): Remove the exec target from all
10535 inferiors sharing the program space.
10536 (exec_on_vfork): New.
10537 * exec.h (exec_on_vfork): Declare.
10538 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
10539 Pass it down.
10540 (fbsd_nat_target::update_thread_list): Adjust.
10541 (fbsd_nat_target::resume): Adjust.
10542 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
10543 down.
10544 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
10545 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
10546 get_thread_arch_regcache call.
10547 * fork-child.c (gdb_startup_inferior): Pass target down to
10548 startup_inferior and set_executing.
10549 * gdbthread.h (struct process_stratum_target): Forward declare.
10550 (add_thread, add_thread_silent, add_thread_with_info)
10551 (in_thread_list): Add process_stratum_target parameter.
10552 (find_thread_ptid(inferior*, ptid_t)): New overload.
10553 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
10554 parameter.
10555 (all_threads()): Delete overload.
10556 (all_threads, all_non_exited_threads): Add process_stratum_target
10557 parameter.
10558 (all_threads_safe): Use brace initialization.
10559 (thread_count): Add process_stratum_target parameter.
10560 (set_resumed, set_running, set_stop_requested, set_executing)
10561 (threads_are_executing, finish_thread_state): Add
10562 process_stratum_target parameter.
10563 (switch_to_thread): Use is_current_thread.
10564 * i386-fbsd-tdep.c: Include "inferior.h".
10565 (i386fbsd_get_thread_local_address): Pass down target.
10566 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
10567 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
10568 have_inferiors check.
10569 * inf-ptrace.c (inf_ptrace_target::create_inferior)
10570 (inf_ptrace_target::attach): Adjust.
10571 * infcall.c (run_inferior_call): Adjust.
10572 * infcmd.c (run_command_1): Pass target to
10573 scoped_finish_thread_state.
10574 (proceed_thread_callback): Skip inferiors with no execution.
10575 (continue_command): Rename 'all_threads' local to avoid hiding
10576 'all_threads' function. Adjust get_last_target_status call.
10577 (prepare_one_step): Adjust set_running call.
10578 (signal_command): Use user_visible_resume_target. Compare thread
10579 pointers instead of inferior_ptid.
10580 (info_program_command): Adjust to pass down target.
10581 (attach_command): Mark target's 'thread_executing' flag.
10582 (stop_current_target_threads_ns): New, factored out from ...
10583 (interrupt_target_1): ... this. Switch inferior before making
10584 target calls.
10585 * inferior-iter.h
10586 (struct all_inferiors_iterator, struct all_inferiors_range)
10587 (struct all_inferiors_safe_range)
10588 (struct all_non_exited_inferiors_range): Filter on
10589 process_stratum_target too. Remove explicit.
10590 * inferior.c (inferior::inferior): Push dummy target on target
10591 stack.
10592 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
10593 Add process_stratum_target parameter, and pass it down.
10594 (have_live_inferiors): Adjust.
10595 (switch_to_inferior_and_push_target): New.
10596 (add_inferior_command, clone_inferior_command): Handle
10597 "-no-connection" parameter. Use
10598 switch_to_inferior_and_push_target.
10599 (_initialize_inferior): Mention "-no-connection" option in
10600 the help of "add-inferior" and "clone-inferior" commands.
10601 * inferior.h: Include "process-stratum-target.h".
10602 (interrupt_target_1): Use bool.
10603 (struct inferior) <push_target, unpush_target, target_is_pushed,
10604 find_target_beneath, top_target, process_target, target_at,
10605 m_stack>: New.
10606 (discard_all_inferiors): Delete.
10607 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
10608 (all_inferiors, all_non_exited_inferiors): Add
10609 process_stratum_target parameter.
10610 * infrun.c: Include "gdb_select.h" and <unordered_map>.
10611 (target_last_proc_target): New global.
10612 (follow_fork_inferior): Push target on new inferior. Pass target
10613 to add_thread_silent. Call exec_on_vfork. Handle target's
10614 reference count.
10615 (follow_fork): Adjust get_last_target_status call. Also consider
10616 target.
10617 (follow_exec): Push target on new inferior.
10618 (struct execution_control_state) <target>: New field.
10619 (user_visible_resume_target): New.
10620 (do_target_resume): Call target_async.
10621 (resume_1): Set target's threads_executing flag. Consider resume
10622 target.
10623 (commit_resume_all_targets): New.
10624 (proceed): Also consider resume target. Skip threads of inferiors
10625 with no execution. Commit resumtion in all targets.
10626 (start_remote): Pass current inferior to wait_for_inferior.
10627 (infrun_thread_stop_requested): Consider target as well. Pass
10628 thread_info pointer to clear_inline_frame_state instead of ptid.
10629 (infrun_thread_thread_exit): Consider target as well.
10630 (random_pending_event_thread): New inferior parameter. Use it.
10631 (do_target_wait): Rename to ...
10632 (do_target_wait_1): ... this. Add inferior parameter, and pass it
10633 down.
10634 (threads_are_resumed_pending_p, do_target_wait): New.
10635 (prepare_for_detach): Adjust calls.
10636 (wait_for_inferior): New inferior parameter. Handle it. Use
10637 do_target_wait_1 instead of do_target_wait.
10638 (fetch_inferior_event): Adjust. Switch to representative
10639 inferior. Pass target down.
10640 (set_last_target_status): Add process_stratum_target parameter.
10641 Save target in global.
10642 (get_last_target_status): Add process_stratum_target parameter and
10643 handle it.
10644 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
10645 (context_switch): Check inferior_ptid == null_ptid before calling
10646 inferior_thread().
10647 (get_inferior_stop_soon): Pass down target.
10648 (wait_one): Rename to ...
10649 (poll_one_curr_target): ... this.
10650 (struct wait_one_event): New.
10651 (wait_one): New.
10652 (stop_all_threads): Adjust.
10653 (handle_no_resumed, handle_inferior_event): Adjust to consider the
10654 event's target.
10655 (switch_back_to_stepped_thread): Also consider target.
10656 (print_stop_event): Update.
10657 (normal_stop): Update. Also consider the resume target.
10658 * infrun.h (wait_for_inferior): Remove declaration.
10659 (user_visible_resume_target): New declaration.
10660 (get_last_target_status, set_last_target_status): New
10661 process_stratum_target parameter.
10662 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
10663 process_stratum_target parameter, and use it.
10664 (clear_inline_frame_state (thread_info*)): New.
10665 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
10666 process_stratum_target parameter.
10667 (clear_inline_frame_state (thread_info*)): Declare.
10668 * linux-fork.c (delete_checkpoint_command): Pass target down to
10669 find_thread_ptid.
10670 (checkpoint_command): Adjust.
10671 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
10672 instead of just tweaking inferior_ptid.
10673 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
10674 (exit_lwp): Pass target down to find_thread_ptid.
10675 (attach_proc_task_lwp_callback): Pass target down to
10676 add_thread/set_running/set_executing.
10677 (linux_nat_target::attach): Pass target down to
10678 thread_change_ptid.
10679 (get_detach_signal): Pass target down to find_thread_ptid.
10680 Consider last target status's target.
10681 (linux_resume_one_lwp_throw, resume_lwp)
10682 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
10683 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
10684 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
10685 (linux_nat_target::async_wait_fd): New.
10686 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
10687 target down.
10688 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
10689 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
10690 * linux-thread-db.c (struct thread_db_info::process_target): New
10691 field.
10692 (add_thread_db_info): Save target.
10693 (get_thread_db_info): New process_stratum_target parameter. Also
10694 match target.
10695 (delete_thread_db_info): New process_stratum_target parameter.
10696 Also match target.
10697 (thread_from_lwp): Adjust to pass down target.
10698 (thread_db_notice_clone): Pass down target.
10699 (check_thread_db_callback): Pass down target.
10700 (try_thread_db_load_1): Always push the thread_db target.
10701 (try_thread_db_load, record_thread): Pass target down.
10702 (thread_db_target::detach): Pass target down. Always unpush the
10703 thread_db target.
10704 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
10705 target down. Always unpush the thread_db target.
10706 (find_new_threads_callback, thread_db_find_new_threads_2)
10707 (thread_db_target::update_thread_list): Pass target down.
10708 (thread_db_target::pid_to_str): Pass current inferior down.
10709 (thread_db_target::get_thread_local_address): Pass target down.
10710 (thread_db_target::resume, maintenance_check_libthread_db): Pass
10711 target down.
10712 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
10713 * procfs.c (procfs_target::procfs_init_inferior): Declare.
10714 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
10715 (procfs_init_inferior): Rename to ...
10716 (procfs_target::procfs_init_inferior): ... this and adjust.
10717 (procfs_target::create_inferior, procfs_notice_thread)
10718 (procfs_do_thread_registers): Adjust.
10719 * ppc-fbsd-tdep.c: Include "inferior.h".
10720 (ppcfbsd_get_thread_local_address): Pass down target.
10721 * proc-service.c (ps_xfer_memory): Switch current inferior and
10722 program space as well.
10723 (get_ps_regcache): Pass target down.
10724 * process-stratum-target.c
10725 (process_stratum_target::thread_address_space)
10726 (process_stratum_target::thread_architecture): Pass target down.
10727 * process-stratum-target.h
10728 (process_stratum_target::threads_executing): New field.
10729 (as_process_stratum_target): New.
10730 * ravenscar-thread.c
10731 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
10732 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
10733 down.
10734 * record-btrace.c (record_btrace_target::info_record): Adjust.
10735 (record_btrace_target::record_method)
10736 (record_btrace_target::record_is_replaying)
10737 (record_btrace_target::fetch_registers)
10738 (get_thread_current_frame_id, record_btrace_target::resume)
10739 (record_btrace_target::wait, record_btrace_target::stop): Pass
10740 target down.
10741 * record-full.c (record_full_wait_1): Switch to event thread.
10742 Pass target down.
10743 * regcache.c (regcache::regcache)
10744 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
10745 process_stratum_target parameter and handle it.
10746 (current_thread_target): New global.
10747 (get_thread_regcache): Add process_stratum_target parameter and
10748 handle it. Switch inferior before calling target method.
10749 (get_thread_regcache): Pass target down.
10750 (get_thread_regcache_for_ptid): Pass target down.
10751 (registers_changed_ptid): Add process_stratum_target parameter and
10752 handle it.
10753 (registers_changed_thread, registers_changed): Pass target down.
10754 (test_get_thread_arch_aspace_regcache): New.
10755 (current_regcache_test): Define a couple local test_target_ops
10756 instances and use them for testing.
10757 (readwrite_regcache): Pass process_stratum_target parameter.
10758 (cooked_read_test, cooked_write_test): Pass mock_target down.
10759 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
10760 (get_thread_arch_aspace_regcache): Add process_stratum_target
10761 parameter.
10762 (regcache::target): New method.
10763 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
10764 (regcache::registers_changed_ptid): Add process_stratum_target
10765 parameter.
10766 (regcache::m_target): New field.
10767 (registers_changed_ptid): Add process_stratum_target parameter.
10768 * remote.c (remote_state::supports_vCont_probed): New field.
10769 (remote_target::async_wait_fd): New method.
10770 (remote_unpush_and_throw): Add remote_target parameter.
10771 (get_current_remote_target): Adjust.
10772 (remote_target::remote_add_inferior): Push target.
10773 (remote_target::remote_add_thread)
10774 (remote_target::remote_notice_new_inferior)
10775 (get_remote_thread_info): Pass target down.
10776 (remote_target::update_thread_list): Skip threads of inferiors
10777 bound to other targets. (remote_target::close): Don't discard
10778 inferiors. (remote_target::add_current_inferior_and_thread)
10779 (remote_target::process_initial_stop_replies)
10780 (remote_target::start_remote)
10781 (remote_target::remote_serial_quit_handler): Pass down target.
10782 (remote_target::remote_unpush_target): New remote_target
10783 parameter. Unpush the target from all inferiors.
10784 (remote_target::remote_unpush_and_throw): New remote_target
10785 parameter. Pass it down.
10786 (remote_target::open_1): Check whether the current inferior has
10787 execution instead of checking whether any inferior is live. Pass
10788 target down.
10789 (remote_target::remote_detach_1): Pass down target. Use
10790 remote_unpush_target.
10791 (extended_remote_target::attach): Pass down target.
10792 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
10793 (remote_target::append_resumption): Pass down target.
10794 (remote_target::append_pending_thread_resumptions)
10795 (remote_target::remote_resume_with_hc, remote_target::resume)
10796 (remote_target::commit_resume): Pass down target.
10797 (remote_target::remote_stop_ns): Check supports_vCont_probed.
10798 (remote_target::interrupt_query)
10799 (remote_target::remove_new_fork_children)
10800 (remote_target::check_pending_events_prevent_wildcard_vcont)
10801 (remote_target::remote_parse_stop_reply)
10802 (remote_target::process_stop_reply): Pass down target.
10803 (first_remote_resumed_thread): New remote_target parameter. Pass
10804 it down.
10805 (remote_target::wait_as): Pass down target.
10806 (unpush_and_perror): New remote_target parameter. Pass it down.
10807 (remote_target::readchar, remote_target::remote_serial_write)
10808 (remote_target::getpkt_or_notif_sane_1)
10809 (remote_target::kill_new_fork_children, remote_target::kill): Pass
10810 down target.
10811 (remote_target::mourn_inferior): Pass down target. Use
10812 remote_unpush_target.
10813 (remote_target::core_of_thread)
10814 (remote_target::remote_btrace_maybe_reopen): Pass down target.
10815 (remote_target::pid_to_exec_file)
10816 (remote_target::thread_handle_to_thread_info): Pass down target.
10817 (remote_target::async_wait_fd): New.
10818 * riscv-fbsd-tdep.c: Include "inferior.h".
10819 (riscv_fbsd_get_thread_local_address): Pass down target.
10820 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
10821 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
10822 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
10823 Adjust.
10824 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
10825 * solib-svr4.c (enable_break): Pass down target.
10826 * spu-multiarch.c (parse_spufs_run): Pass down target.
10827 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
10828 * target-delegates.c: Regenerate.
10829 * target.c (g_target_stack): Delete.
10830 (current_top_target): Return the current inferior's top target.
10831 (target_has_execution_1): Refer to the passed-in inferior's top
10832 target.
10833 (target_supports_terminal_ours): Check whether the initial
10834 inferior was already created.
10835 (decref_target): New.
10836 (target_stack::push): Incref/decref the target.
10837 (push_target, push_target, unpush_target): Adjust.
10838 (target_stack::unpush): Defref target.
10839 (target_is_pushed): Return bool. Adjust to refer to the current
10840 inferior's target stack.
10841 (dispose_inferior): Delete, and inline parts ...
10842 (target_preopen): ... here. Only dispose of the current inferior.
10843 (target_detach): Hold strong target reference while detaching.
10844 Pass target down.
10845 (target_thread_name): Add assertion.
10846 (target_resume): Pass down target.
10847 (target_ops::beneath, find_target_at): Adjust to refer to the
10848 current inferior's target stack.
10849 (get_dummy_target): New.
10850 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
10851 has a thread running.
10852 (initialize_targets): Rename to ...
10853 (_initialize_target): ... this.
10854 * target.h: Include "gdbsupport/refcounted-object.h".
10855 (struct target_ops): Inherit refcounted_object.
10856 (target_ops::shortname, target_ops::longname): Make const.
10857 (target_ops::async_wait_fd): New method.
10858 (decref_target): Declare.
10859 (struct target_ops_ref_policy): New.
10860 (target_ops_ref): New typedef.
10861 (get_dummy_target): Declare function.
10862 (target_is_pushed): Return bool.
10863 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
10864 (all_matching_threads_iterator::all_matching_threads_iterator):
10865 Handle filter target.
10866 * thread-iter.h (struct all_matching_threads_iterator, struct
10867 all_matching_threads_range, class all_non_exited_threads_range):
10868 Filter by target too. Remove explicit.
10869 * thread.c (threads_executing): Delete.
10870 (inferior_thread): Pass down current inferior.
10871 (clear_thread_inferior_resources): Pass down thread pointer
10872 instead of ptid_t.
10873 (add_thread_silent, add_thread_with_info, add_thread): Add
10874 process_stratum_target parameter. Use it for thread and inferior
10875 searches.
10876 (is_current_thread): New.
10877 (thread_info::deletable): Use it.
10878 (find_thread_ptid, thread_count, in_thread_list)
10879 (thread_change_ptid, set_resumed, set_running): New
10880 process_stratum_target parameter. Pass it down.
10881 (set_executing): New process_stratum_target parameter. Pass it
10882 down. Adjust reference to 'threads_executing'.
10883 (threads_are_executing): New process_stratum_target parameter.
10884 Adjust reference to 'threads_executing'.
10885 (set_stop_requested, finish_thread_state): New
10886 process_stratum_target parameter. Pass it down.
10887 (switch_to_thread): Also match inferior.
10888 (switch_to_thread): New process_stratum_target parameter. Pass it
10889 down.
10890 (update_threads_executing): Reimplement.
10891 * top.c (quit_force): Pop targets from all inferior.
10892 (gdb_init): Don't call initialize_targets.
10893 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
10894 Declare.
10895 (windows_add_thread, windows_delete_thread): Adjust.
10896 (get_windows_debug_event): Rename to ...
10897 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
10898 * tracefile-tfile.c (tfile_target_open): Pass down target.
10899 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
10900 Forward declare.
10901 (switch_to_thread): Add process_stratum_target parameter.
10902 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
10903 parameter. Use it.
10904 (mi_on_resume): Pass target down.
10905 * nat/fork-inferior.c (startup_inferior): Add
10906 process_stratum_target parameter. Pass it down.
10907 * nat/fork-inferior.h (startup_inferior): Add
10908 process_stratum_target parameter.
10909 * python/py-threadevent.c (py_get_event_thread): Pass target down.
10910
10911 2020-01-10 Pedro Alves <palves@redhat.com>
10912
10913 * remote.c (remote_target::start_remote): Don't set inferior_ptid
10914 directly. Instead find the first thread in the thread list and
10915 use switch_to_thread.
10916
10917 2020-01-10 Pedro Alves <palves@redhat.com>
10918
10919 * remote.c (remote_target::remote_add_inferior): Don't bind a
10920 process to the current inferior if the current inferior is already
10921 bound to a process.
10922
10923 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
10924 Pedro Alves <palves@redhat.com>
10925
10926 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
10927 If no process is specified, return null_ptid instead of
10928 inferior_ptid.
10929 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
10930 TARGET_WAITKIND_SIGNALLED with no pid.
10931
10932 2020-01-10 Pedro Alves <palves@redhat.com>
10933
10934 * remote.c (first_remote_resumed_thread): New.
10935 (remote_target::wait_as): Use it as default event_ptid instead of
10936 inferior_ptid.
10937
10938 2020-01-10 Pedro Alves <palves@redhat.com>
10939
10940 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
10941
10942 2020-01-10 Pedro Alves <palves@redhat.com>
10943
10944 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
10945 not -1.
10946
10947 2020-01-10 Pedro Alves <palves@redhat.com>
10948
10949 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
10950 ptid to get_last_target_status.
10951 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
10952 ptid to get_last_target_status.
10953 * infcmd.c (continue_command): Don't pass a target_waitstatus to
10954 get_last_target_status.
10955 (info_program_command): Don't pass a target_waitstatus to
10956 get_last_target_status.
10957 * infrun.c (init_wait_for_inferior): Use
10958 nullify_last_target_wait_ptid.
10959 (get_last_target_status): Handle nullptr arguments.
10960 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
10961 (print_stop_event): Don't pass a ptid to get_last_target_status.
10962 (normal_stop): Don't pass a ptid to get_last_target_status.
10963 * infrun.h (get_last_target_status, set_last_target_status): Move
10964 comments here and update.
10965 (nullify_last_target_wait_ptid): Declare.
10966 * linux-fork.c (fork_load_infrun_state): Remove local extern
10967 declaration of nullify_last_target_wait_ptid.
10968 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
10969 to get_last_target_status.
10970
10971 2020-01-10 Pedro Alves <palves@redhat.com>
10972
10973 * gdbthread.h (scoped_restore_current_thread)
10974 <dont_restore, restore, m_dont_restore>: Declare.
10975 * thread.c (thread_alive): Add assertion. Return bool.
10976 (switch_to_thread_if_alive): New.
10977 (prune_threads): Switch inferior/thread.
10978 (print_thread_info_1): Switch thread before calling target methods.
10979 (scoped_restore_current_thread::restore): New, factored out from
10980 ...
10981 (scoped_restore_current_thread::~scoped_restore_current_thread):
10982 ... this.
10983 (scoped_restore_current_thread::scoped_restore_current_thread):
10984 Add assertion.
10985 (thread_apply_all_command, thread_select): Use
10986 switch_to_thread_if_alive.
10987 * infrun.c (proceed, restart_threads, handle_signal_stop)
10988 (switch_back_to_stepped_thread): Switch current thread before
10989 calling target methods.
10990
10991 2020-01-10 Pedro Alves <palves@redhat.com>
10992
10993 * inferior.c (switch_to_inferior_no_thread): New function,
10994 factored out from ...
10995 (inferior_command): ... here.
10996 * inferior.h (switch_to_inferior_no_thread): Declare.
10997 * mi/mi-main.c (run_one_inferior): Use
10998 switch_to_inferior_no_thread.
10999
11000 2020-01-10 Pedro Alves <palves@redhat.com>
11001
11002 * infcmd.c (kill_command): Remove dead code.
11003
11004 2020-01-10 Pedro Alves <palves@redhat.com>
11005
11006 * remote.c (remote_target::mourn_inferior): No longer check
11007 whether the target is running.
11008
11009 2020-01-10 Pedro Alves <palves@redhat.com>
11010
11011 * corelow.c (core_target::has_execution): Change parameter type to
11012 inferior pointer.
11013 * inferior.c (number_of_live_inferiors): Use
11014 inferior::has_execution instead of target_has_execution_1.
11015 * inferior.h (inferior::has_execution): New.
11016 * linux-thread-db.c (thread_db_target::update_thread_list): Use
11017 inferior::has_execution instead of target_has_execution_1.
11018 * process-stratum-target.c
11019 (process_stratum_target::has_execution): Change parameter type to
11020 inferior pointer. Check the inferior's PID instead of
11021 inferior_ptid.
11022 * process-stratum-target.h
11023 (process_stratum_target::has_execution): Change parameter type to
11024 inferior pointer.
11025 * record-full.c (record_full_core_target::has_execution): Change
11026 parameter type to inferior pointer.
11027 * target.c (target_has_execution_1): Change parameter type to
11028 inferior pointer.
11029 (target_has_execution_current): Adjust.
11030 * target.h (target_ops::has_execution): Change parameter type to
11031 inferior pointer.
11032 (target_has_execution_1): Change parameter type to inferior
11033 pointer. Change return type to bool.
11034 * tracefile.h (tracefile_target::has_execution): Change parameter
11035 type to inferior pointer.
11036
11037 2020-01-10 Pedro Alves <palves@redhat.com>
11038
11039 * exceptions.c (print_flush): Remove current_top_target() check.
11040
11041 2020-01-10 Pedro Alves <palves@redhat.com>
11042
11043 * remote.c (show_remote_exec_file): Show the current inferior's
11044 exec-file instead of the command variable's value.
11045
11046 2020-01-10 Pedro Alves <palves@redhat.com>
11047
11048 * record-full.c (record_full_resume_ptid): New global.
11049 (record_full_target::resume): Set it.
11050 (record_full_wait_1): Use record_full_resume_ptid instead of
11051 inferior_ptid.
11052
11053 2020-01-10 Pedro Alves <palves@redhat.com>
11054
11055 * gdbthread.h (scoped_restore_current_thread)
11056 <dont_restore, restore, m_dont_restore>: Declare.
11057 * thread.c (thread_alive): Add assertion. Return bool.
11058 (switch_to_thread_if_alive): New.
11059 (prune_threads): Switch inferior/thread.
11060 (print_thread_info_1): Switch thread before calling target methods.
11061 (scoped_restore_current_thread::restore): New, factored out from
11062 ...
11063 (scoped_restore_current_thread::~scoped_restore_current_thread):
11064 ... this.
11065 (scoped_restore_current_thread::scoped_restore_current_thread):
11066 Add assertion.
11067 (thread_apply_all_command, thread_select): Use
11068 switch_to_thread_if_alive.
11069
11070 2020-01-10 George Barrett <bob@bob131.so>
11071
11072 * stap-probe.c (stap_modify_semaphore): Don't check for null
11073 semaphores.
11074 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
11075 for null semaphores.
11076
11077 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
11078
11079 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
11080 all source windows, and maintain horizontal scroll status while
11081 doing so.
11082
11083 2020-01-09 Tom Tromey <tom@tromey.com>
11084
11085 PR tui/18932:
11086 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
11087 update_source_window, not print_source_lines.
11088
11089 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
11090
11091 * tui/tui.c (tui_enable): Register tui hooks after calling
11092 tui_display_main.
11093
11094 2020-01-09 Christian Biesinger <cbiesinger@google.com>
11095
11096 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
11097
11098 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
11099
11100 * thread.c (print_thread_info_1): Fix indentation.
11101
11102 2020-01-09 Christian Biesinger <cbiesinger@google.com>
11103
11104 * symtab.c (general_symbol_info::compute_and_set_names): Move the
11105 unique_xmalloc_ptr outside the if to always free the demangled name.
11106
11107 2020-01-08 Tom Tromey <tromey@adacore.com>
11108
11109 * xcoffread.c (enter_line_range, read_xcoff_symtab)
11110 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
11111 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
11112 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
11113 Remove.
11114 (section_offsets): New typedef.
11115 * symtab.c (fixup_section, get_msymbol_address): Update.
11116 * symmisc.c (dump_msymbols): Update.
11117 * symfile.h (relative_addr_info_to_section_offsets)
11118 (symfile_map_offsets_to_segments): Update.
11119 * symfile.c (build_section_addr_info_from_objfile)
11120 (init_objfile_sect_indices): Update.
11121 (struct place_section_arg): Change type of "offsets".
11122 (place_section): Update.
11123 (relative_addr_info_to_section_offsets): Change type of
11124 "section_offsets". Remove "num_sections" parameter.
11125 (default_symfile_offsets, syms_from_objfile_1)
11126 (set_objfile_default_section_offset): Update.
11127 (reread_symbols): No need to preserve section offsets by hand.
11128 (symfile_map_offsets_to_segments): Change type of "offsets".
11129 * stap-probe.c (relocate_address): Update.
11130 * stabsread.h (process_one_symbol): Update.
11131 * solib-target.c (struct lm_info_target) <offsets>: Change type.
11132 (solib_target_relocate_section_addresses): Update.
11133 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
11134 Update.
11135 * solib-frv.c (frv_relocate_main_executable): Update.
11136 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
11137 * solib-aix.c (solib_aix_get_section_offsets): Change return
11138 type.
11139 (solib_aix_solib_create_inferior_hook): Update.
11140 * remote.c (remote_target::get_offsets): Update.
11141 * psymtab.c (find_pc_sect_psymtab): Update.
11142 * psympriv.h (struct partial_symbol) <address, text_low,
11143 text_high>: Update.
11144 * objfiles.h (obj_section_offset): Update.
11145 (struct objfile) <section_offsets>: Change type.
11146 <num_sections>: Remove.
11147 (objfile_relocate): Update.
11148 * objfiles.c (entry_point_address_query): Update
11149 (relocate_one_symbol): Change type of "section_offsets".
11150 (objfile_relocate1, objfile_relocate1): Change type of
11151 "new_offsets".
11152 (objfile_rebase1): Update.
11153 * mipsread.c (mipscoff_symfile_read): Update.
11154 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
11155 parameter.
11156 * mdebugread.c (parse_symbol): Change type of "section_offsets".
11157 (parse_external, psymtab_to_symtab_1): Update.
11158 * machoread.c (macho_symfile_offsets): Update.
11159 * ia64-tdep.c (ia64_find_unwind_table): Update.
11160 * hppa-tdep.c (read_unwind_info): Update.
11161 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
11162 * dwarf2read.c (create_addrmap_from_index)
11163 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
11164 (process_psymtab_comp_unit_reader, add_partial_symbol)
11165 (add_partial_subprogram, process_full_comp_unit)
11166 (read_file_scope, read_func_scope, read_lexical_block_scope)
11167 (read_call_site_scope, dwarf2_rnglists_process)
11168 (dwarf2_ranges_process, dwarf2_ranges_read)
11169 (dwarf_decode_lines_1, var_decode_location, new_symbol)
11170 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
11171 Update.
11172 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
11173 Update.
11174 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
11175 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
11176 (process_one_symbol): Change type of "section_offsets".
11177 * ctfread.c (get_objfile_text_range): Update.
11178 * coffread.c (coff_symtab_read, enter_linenos)
11179 (process_coff_symbol): Update.
11180 * coff-pe-read.c (add_pe_forwarded_sym): Update.
11181 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
11182
11183 2020-01-08 Tom Tromey <tromey@adacore.com>
11184
11185 * dwarf2read.c (parse_macro_definition): Use std::string.
11186 (parse_macro_definition): Likewise.
11187
11188 2020-01-08 Tom Tromey <tromey@adacore.com>
11189
11190 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
11191 (ATTR_ALLOC_CHUNK): Remove.
11192
11193 2020-01-08 Tom Tromey <tromey@adacore.com>
11194
11195 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
11196
11197 2020-01-08 Tom Tromey <tromey@adacore.com>
11198
11199 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
11200 (dwarf2_compute_name, open_dwo_file): Likewise.
11201 (process_enumeration_scope): Use std::vector.
11202 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
11203 (partial_die_info::fixup, dwarf2_start_subfile)
11204 (guess_full_die_structure_name, dwarf2_name): Likewise.
11205 (determine_prefix): Update.
11206 (guess_full_die_structure_name): Make return type const.
11207 (partial_die_full_name): Return unique_xmalloc_ptr.
11208 (DW_FIELD_ALLOC_CHUNK): Remove.
11209
11210 2020-01-07 Tom Tromey <tromey@adacore.com>
11211
11212 PR build/24937:
11213 * stap-probe.c (class stap_static_probe_ops): Add constructor.
11214
11215 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
11216
11217 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
11218
11219 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
11220
11221 * stack.c (print_frame_info): Move disassemble_next_line code
11222 inside source_print block.
11223
11224 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11225
11226 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
11227 gdb/signals.h, as we are now using native signal symbols.
11228
11229 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
11230
11231 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
11232 overflow by an early check of content vs threshold.
11233 * tui/tui-source.c (tui_source_window::line_is_displayed):
11234 Likewise.
11235
11236 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11237
11238 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
11239
11240 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
11241
11242 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
11243 export table if no section contains it's RVA.
11244
11245 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11246
11247 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
11248
11249 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
11250
11251 * source.c (print_source_lines_base): Set last_line_listed.
11252
11253 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
11254
11255 * tui/tui-disasm.c: Remove trailing spaces.
11256
11257 2020-01-06 Eli Zaretskii <eliz@gnu.org>
11258 Pedro Alves <palves@redhat.com>
11259
11260 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
11261 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
11262 (windows_gdb_signal_to_target): New function, uses the above
11263 enumeration to convert GDB internal signal codes to equivalent
11264 Windows codes.
11265 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
11266 * windows-nat.c: Include "gdb_wait.h".
11267 (get_windows_debug_event): Extract the fatal exception from the
11268 exit status and convert to the equivalent Posix signal number.
11269 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
11270 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
11271 * gdbsupport/gdb_wait.c: New file, implements
11272 windows_status_to_termsig.
11273 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
11274 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
11275
11276 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
11277
11278 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
11279 show_layout.
11280
11281 2020-01-05 Luis Machado <luis.machado@linaro.org>
11282
11283 * aarch64-linux-nat.c
11284 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
11285 and bfd_mach_aarch64.
11286
11287 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
11288
11289 * ui-file.c (stdio_file::can_emit_style_escape)
11290 (tee_file::can_emit_style_escape): Ensure style is used also on
11291 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
11292 to gdb_stdout.
11293 * main.c (set_gdb_data_directory): Use file style to output the
11294 warning that the given pathname is not a directory.
11295 * top.c (show_history_filename, gdb_safe_append_history)
11296 (show_gdb_datadir): Use file style.
11297
11298 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
11299
11300 * solib-target.c (struct lm_info_target):
11301 Change offsets to be a unique_xmalloc_ptr.
11302 (solib_target_relocate_section_addresses): Update.
11303
11304 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
11305
11306 * windows-nat.c (windows_clear_solib): Free so_list linked list.
11307
11308 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
11309
11310 * MAINTAINERS (Write After Approval): Add myself.
11311
11312 2020-01-02 Luis Machado <luis.machado@linaro.org>
11313
11314 * proc-service.c (get_ps_regcache): Remove reference to obsolete
11315 Cell BE architecture.
11316 * target.h (struct target_ops) <thread_architecture>: Likewise.
11317
11318 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
11319
11320 * Makefile.in: Use INSTALL_PROGRAM_ENV.
11321
11322 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
11323
11324 * MAINTAINERS (Write After Approval): Add myself.
11325
11326 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11327
11328 * gdbarch.sh: Update copyright year range of generated files.
11329
11330 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11331
11332 Update copyright year range in all GDB files.
11333
11334 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11335
11336 * copyright.py: Convert to Python 3.
11337
11338 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11339
11340 * copyright.py: Adapt after move of gnulib directory from gdb
11341 directory to toplevel directory.
11342
11343 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11344
11345 * copyright.py (main): Exit if run from the wrong directory.
11346
11347 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11348
11349 * top.c (print_gdb_version): Change copyright year to 2020.
11350
11351 2020-01-01 Joel Brobecker <brobecker@adacore.com>
11352
11353 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
11354
11355 For older changes see ChangeLog-2019.
11356 \f
11357 Local Variables:
11358 mode: change-log
11359 left-margin: 8
11360 fill-column: 74
11361 version-control: never
11362 coding: utf-8
11363 End:
This page took 0.263227 seconds and 4 git commands to generate.