3a0d371a87cca059ed5c5074c275cba210e53f28
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
2
3 * frame.h (enum frame_id_stack_status) <FID_STACK_OUTER>: New.
4 * frame.c (fprint_frame_id): Handle FID_STACK_OUTER.
5 (outer_frame_id): Use FID_STACK_OUTER instead of
6 FID_STACK_INVALID.
7 (frame_id_p): Don't check for outer_frame_id.
8
9 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
10
11 * frame-unwind.c (frame_unwind_got_optimized): Don't set
12 regnum/frame in value. Call allocate_value_lazy.
13 * frame.c (frame_unwind_register_value): Use
14 val_print_not_saved.
15
16 2020-08-31 Simon Marchi <simon.marchi@efficios.com>
17
18 * gdbtypes.h (NULL_TYPE): Remove, change all uses to nullptr.
19
20 2020-08-29 Pedro Alves <pedro@palves.net>
21
22 * progspace.c (print_program_space): Use all_inferiors. Switch to
23 the inferior before calling target_pid_to_str.
24
25 2020-08-28 Tom Tromey <tom@tromey.com>
26
27 * xcoffread.c (xcoff_end_psymtab): Update comment.
28 * dbxread.c (dbx_end_psymtab): Update comment.
29
30 2020-08-28 Tom de Vries <tdevries@suse.de>
31
32 PR breakpoint/26544
33 * breakpoint.c (parse_breakpoint_sals): Remove const from struct
34 event_location.
35 (create_breakpoint): Same.
36 (base_breakpoint_decode_location): Same.
37 (bkpt_create_sals_from_location): Same.
38 (bkpt_decode_location): Same.
39 (bkpt_probe_create_sals_from_location): Same.
40 (bkpt_probe_decode_location): Same.
41 (tracepoint_create_sals_from_location): Same.
42 (tracepoint_decode_location): Same.
43 (tracepoint_probe_decode_location): Same.
44 (strace_marker_create_sals_from_location): Same.
45 (strace_marker_decode_location): Same.
46 (create_sals_from_location_default): Same.
47 (decode_location_default): Same.
48 * breakpoint.h (struct breakpoint_ops): Same.
49 (create_breakpoint): Same.
50 * linespec.h (decode_line_full): Same.
51 * linespec.c (decode_line_full): Same. Throw error if
52 result.size () == 0.
53
54 2020-08-27 Pedro Alves <pedro@palves.net>
55
56 PR gdb/26524
57 * breakpoint.c (until_break_fsm) <location_breakpoint,
58 caller_breakpoint>: Delete fields.
59 <breakpoints>: New field.
60 <until_break_fsm>: Adjust to save a breakpoint vector instead of
61 two individual breakpoints.
62 (until_break_fsm::should_stop): Loop over breakpoints in the
63 breakpoint vector.
64 (until_break_fsm::clean_up): Adjust to clear the breakpoints
65 vector.
66 (until_break_command): Handle location expanding into multiple
67 sals.
68
69 2020-08-27 Pedro Alves <pedro@palves.net>
70
71 PR gdb/26523
72 * inline-frame.c (stopped_by_user_bp_inline_frame): Also consider
73 bp_until breakpoints user-specified locations. Update intro
74 comment.
75
76 2020-08-27 Simon Marchi <simon.marchi@polymtl.ca>
77
78 * gdb_bfd.h (gdb_bfd_section_iterator, gdb_bfd_section_range,
79 gdb_bfd_sections): New.
80 * maint.c (print_bfd_section_info): Change param type to
81 maint_print_section_data.
82 (print_objfile_section_info): Likewise.
83 (print_bfd_section_info_maybe_relocated): Likewise.
84 (maintenance_info_sections): Use gdb_bfd_sections.
85
86 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
87
88 * MAINTAINERS: Add ARC target and maintainer.
89
90 2020-08-25 Anton Kolesov <anton.kolesov@synopsys.com>
91
92 * configure.tgt: ARC support for GNU/Linux.
93 * Makefile.in (ALL_TARGET_OBJS): Likewise.
94 * arc-linux-tdep.c: New file.
95 * arc-tdep.h (ARC_STATUS32_L_MASK, ARC_STATUS32_DE_MASK): Declare.
96 * arc-tdep.c (arc_write_pc): Use it.
97
98 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
99
100 * arc-tdep.c (arc_check_for_hardware_loop): New.
101 * arc-tdep.h (gdbarch_tdep): New field has_hw_loops.
102
103 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
104
105 * arc-tdep.h: Include "gdbarch.h".
106
107 2020-08-25 Shahab Vahedi <shahab@synopsys.com>
108
109 * arch/arc.h
110 (arc_gdbarch_features): New class to stir the selection of target XML.
111 (arc_create_target_description): Use FEATURES to choose XML target.
112 (arc_lookup_target_description): Use arc_create_target_description
113 to create _new_ target descriptions or return the already created
114 ones if the FEATURES is the same.
115 * arch/arc.c: Implementation of prototypes described above.
116 * gdb/arc-tdep.h (arc_regnum enum): Add more registers.
117 (arc_gdbarch_features_init): Initialize the FEATURES struct.
118 * arc-tdep.c (*_feature_name): Make feature names consistent.
119 (arc_register_feature): A new struct to hold information about
120 registers of a particular target/feature.
121 (arc_check_tdesc_feature): Check if XML provides registers in
122 compliance with ARC_REGISTER_FEATURE structs.
123 (arc_update_acc_reg_names): Add aliases for r58 and r59.
124 (determine_*_reg_feature_set): Which feature name to look for.
125 (arc_gdbarch_features_init): Given MACH and ABFD, initialize FEATURES.
126 (mach_type_to_arc_isa): Convert from a set of binutils machine types
127 to expected ISA enums to be used in arc_gdbarch_features structs.
128 * features/Makefile (FEATURE_XMLFILES): Add new files.
129 * gdb/features/arc/v1-aux.c: New file.
130 * gdb/features/arc/v1-aux.xml: Likewise.
131 * gdb/features/arc/v1-core.c: Likewise.
132 * gdb/features/arc/v1-core.xml: Likewise.
133 * gdb/features/arc/v2-aux.c: Likewise.
134 * gdb/features/arc/v2-aux.xml: Likewise.
135 * gdb/features/arc/v2-core.c: Likewise.
136 * gdb/features/arc/v2-core.xml: Likewise.
137 * NEWS (Changes since GDB 9): Announce obsolence of old feature names.
138
139 2020-08-25 Gaius Mulley <gaiusmod2@gmail.com>
140 Andrew Burgess <andrew.burgess@embecosm.com>
141
142 PR m2/26372
143 * m2-exp.y (exp): Improve comment for non_empty_arglist case, add
144 an assert. Remove single element array indexing pattern as the
145 MULTI_SUBSCRIPT support will handle this case too.
146
147 2020-08-24 Simon Marchi <simon.marchi@polymtl.ca>
148
149 * value.h (valprint_check_validity): Move declaration from
150 here...
151 * valprint.h (valprint_check_validity): ... to here.
152
153 2020-08-24 Simon Marchi <simon.marchi@efficios.com>
154
155 * debug.h: New file.
156 * debug.c (debug_prefixed_vprintf): New function.
157 * infrun.c (infrun_debug_printf_1): Use debug_prefixed_vprintf.
158 * linux-nat.c (linux_nat_debug_printf_1): Likewise.
159
160 2020-08-24 Simon Marchi <simon.marchi@efficios.com>
161
162 * infrun.h (infrun_debug_printf_1): New function declaration.
163 (infrun_debug_printf): New macro.
164 * infrun.c (infrun_debug_printf_1): Use infrun_debug_printf
165 throughout.
166 (infrun_debug_printf): New function.
167 * breakpoint.c (should_be_inserted): Use infrun_debug_printf.
168 (handle_jit_event): Likewise.
169
170 2020-08-21 Mark Wielaard <mark@klomp.org>
171
172 * ada-lex.l: Extend register warnings diagnostics comment for g++.
173
174 2020-08-22 Simon Marchi <simon.marchi@efficios.com>
175
176 * frame.c (enum class frame_id_status): New.
177 (struct frame_info) <this_id::p>: Change type to frame_id_status.
178 (fprintf_frame): Update.
179 (compute_frame_id): Set frame id status to "computing" on entry.
180 Set it back to "not_computed" on failure and to "computed" on
181 success.
182 (get_frame_id): Assert the frame id is not being computed.
183 (create_sentinel_frame): Use frame_id_status::COMPUTED.
184 (create_new_frame): Likewise.
185 (frame_cleanup_after_sniffer): Update assert.
186
187 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
188
189 * regcache.c (pid_ptid_regcache_map): New type.
190 (target_ptid_regcache_map): Remove.
191 (target_pid_ptid_regcache_map): New type.
192 (regcaches): Change type to target_pid_ptid_regcache_map.
193 (get_thread_arch_aspace_regcache): Update.
194 (regcache_thread_ptid_changed): Update, handle pid-like ptid
195 case.
196 (regcaches_size): Update.
197 (regcache_count): Update.
198 (registers_changed_ptid_target_pid_test): New.
199 (_initialize_regcache): Register new test.
200
201 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
202
203 * regcache.c (regcache_count): New.
204 (struct regcache_test_data): New.
205 (regcache_test_data_up): New.
206 (populate_regcaches_for_test): New.
207 (regcaches_test): Remove.
208 (get_thread_arch_aspace_regcache_test): New.
209 (registers_changed_ptid_all_test): New.
210 (registers_changed_ptid_target_test): New.
211 (registers_changed_ptid_target_ptid_test): New.
212 (regcache_thread_ptid_changed): Remove regcache_count lambda.
213 (_initialize_regcache): Register new tests.
214
215 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
216
217 * regcache.c (test_get_thread_arch_aspace_regcache): Rename to...
218 (get_thread_arch_aspace_regcache_and_check): ... this. Remove
219 gdbarch and aspace parameter. Use current inferior's aspace.
220 Validate regcache's arch value.
221 (regcaches_test): Update.
222
223 2020-08-20 Simon Marchi <simon.marchi@polymtl.ca>
224
225 * regcache.c (regcaches_test): Call registers_changed.
226
227 2020-08-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
228
229 * infrun.c (process_event_stop_test): Fix typo "breapoint".
230
231 2020-08-19 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
232
233 * amd64-tdep.c (amd64_skip_prologue): Using symbol table
234 to find the end of prologue for flang compiled binaries.
235 * arm-tdep.c (arm_skip_prologue): Likewise.
236 * i386-tdep.c (i386_skip_prologue): Likewise.
237 * producer.c (producer_is_llvm): New function.
238 (producer_parsing_tests): Added new tests for clang/flang.
239 * producer.h (producer_is_llvm): New declaration.
240
241 2020-08-18 Simon Marchi <simon.marchi@efficios.com>
242
243 * linux-nat.c (linux_nat_debug_printf): New function.
244 (linux_nat_debug_printf_1): New macro. Use throughout the file.
245
246 2020-08-18 Aaron Merey <amerey@redhat.com>
247
248 * Makefile.in (DEBUGINFOD_CFLAGS, DEBUGINFOD_LIBS): New variables.
249 (INTERNAL_CFLAGS_BASE): Add DEBUGINFOD_CFLAGS.
250 (CLIBS): Add DEBUGINFOD_LIBS.
251
252 2020-08-17 Sergei Trofimovich <siarheit@google.com>
253
254 * ia64-linux-nat.c: Include "gdbarch.h" to declare used
255 'gdbarch_num_regs'.
256
257 2020-08-17 Tom Tromey <tromey@adacore.com>
258
259 * ada-varobj.c (ada_varobj_decode_var): Handle case where
260 ada_get_decoded_value returns NULL.
261
262 2020-08-17 Tom Tromey <tromey@adacore.com>
263
264 * python/py-inferior.c (infpy_search_memory): Use
265 gdb_py_object_from_ulongest.
266 * python/py-infevents.c (create_inferior_call_event_object)
267 (create_memory_changed_event_object): Use
268 gdb_py_object_from_ulongest.
269 * python/py-linetable.c (ltpy_entry_get_pc): Use
270 gdb_py_object_from_ulongest.
271
272 2020-08-17 Simon Marchi <simon.marchi@polymtl.ca>
273
274 * loc.c (class symbol_needs_eval_context): Fix indentation.
275
276 2020-08-17 Simon Marchi <simon.marchi@polymtl.ca>
277
278 * dwarf2/loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
279 bool.
280
281 2020-08-17 Tom de Vries <tdevries@suse.de>
282
283 PR gdb/26393
284 * gdbtypes.c (dump_dynamic_prop): New function.
285 (recursive_dump_type): Use dump_dynamic_prop for TYPE_CODE_RANGE.
286
287 2020-08-15 Tom de Vries <tdevries@suse.de>
288
289 PR backtrace/26390
290 * stack.c (print_frame_args): Temporarily set the selected
291 frame to FRAME while printing the frame's arguments.
292
293 2020-08-14 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
294
295 PR breakpoints/26385
296 * ppc-linux-nat.c (ppc_linux_nat_target::low_prepare_to_resume):
297 Always clear watchpoint with PTRACE_SET_DEBUGREG.
298
299 2020-08-14 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
300
301 * ppc-linux-nat.c (ppc_linux_dreg_interface::detect)
302 (ppc_linux_nat_target::low_prepare_to_resume): Use ptrace () < 0
303 and >= to check return value instead of == -1 and != -1.
304
305 2020-08-14 Simon Marchi <simon.marchi@polymtl.ca>
306
307 * utils.h (class gdb_argv) <as_array_view>: New method.
308 * utils.c (gdb_argv_as_array_view_test): New.
309 (_initialize_utils): Register selftest.
310 * maint.c (maintenance_selftest): Use the new method.
311
312 2020-08-13 Kamil Rytarowski <n54@gmx.com>
313
314 * target.h (supports_dumpcore, dumpcore): New
315 function declarations.
316 * target.c (supports_dumpcore, dumpcore): New
317 functions.
318 * target-delegates.c: Rebuild.
319 * gcore.c (gcore_command): Use target_supports_dumpcore ()
320 and target_dumpcore ().
321
322 2020-08-13 Aaron Merey <amerey@redhat.com>
323
324 * debuginfod-support.c: Replace global variables with user_data.
325
326 2020-08-13 Simon Marchi <simon.marchi@polymtl.ca>
327
328 * maint.c (maintenance_selftest): Split args and pass array_view
329 to run_tests.
330
331 2020-08-12 Luis Machado <luis.machado@linaro.org>
332
333 * value.c (check_type_length_before_alloc): Use ULONGEST to store a
334 type's length.
335 Use %s and pulongest to print the length.
336
337 2020-08-12 Pedro Alves <palves@redhat.com>
338
339 * NEWS: Move "Multi-target debugging support" item to the
340 "Changes since GDB 9" section.
341
342 2020-08-12 Pedro Alves <palves@redhat.com>
343
344 PR gdb/26336
345 * progspace.c (program_space::remove_objfile): Invalidate the
346 frame cache.
347
348 2020-08-11 Tom de Vries <tdevries@suse.de>
349
350 * MAINTAINERS: Mark ms1 as deleted.
351
352 2020-08-10 Luis Machado <luis.machado@linaro.org>
353
354 PR gdb/26310
355
356 * aarch64-tdep.c (aarch64_analyze_prologue): Track use of SP/FP and
357 act accordingly.
358 (aarch64_analyze_prologue_test): Add more unit tests to exercise
359 movz/str/stur/stp skipping behavior.
360
361 2020-08-10 Luis Machado <luis.machado@linaro.org>
362
363 * nat/aarch64-sve-linux-sigcontext.h (SVE_PT_REGS_OFFSET): Use
364 struct user_sve_header instead of struct sve_context.
365
366 2020-08-09 Simon Marchi <simon.marchi@polymtl.ca>
367
368 * read.h (dwarf2_fetch_die_loc_sect_off,
369 dwarf2_fetch_die_loc_cu_off): Replace function pointer +
370 `void *` parameter with function_view.
371 * read.c (dwarf2_fetch_die_loc_sect_off,
372 dwarf2_fetch_die_loc_cu_off): Likewise.
373 * loc.c (get_frame_pc_for_per_cu_dwarf_call): Remove.
374 (per_cu_dwarf_call): Adjust.
375 (get_frame_address_in_block_wrapper): Remove.
376 (indirect_synthetic_pointer): Adjust.
377 (get_ax_pc): Remove.
378 (dwarf2_compile_expr_to_ax): Adjust.
379
380 2020-08-08 Tom de Vries <tdevries@suse.de>
381
382 PR build/26344
383 * arch/riscv.c (riscv_lookup_target_description): Use an explicit
384 constructor.
385 * regcache.c (get_thread_arch_aspace_regcache): Same.
386
387 2020-08-07 Tom Tromey <tromey@adacore.com>
388
389 * ravenscar-thread.c
390 (ravenscar_thread_target::set_base_thread_from_ravenscar_task):
391 New method.
392 (ravenscar_thread_target::wait): Check
393 runtime_initialized.
394 (ravenscar_thread_target::prepare_to_store)
395 (ravenscar_thread_target::stopped_by_sw_breakpoint)
396 (ravenscar_thread_target::stopped_by_hw_breakpoint)
397 (ravenscar_thread_target::stopped_by_watchpoint)
398 (ravenscar_thread_target::stopped_data_address)
399 (ravenscar_thread_target::core_of_thread): Use
400 scoped_restore_current_thread and
401 set_base_thread_from_ravenscar_task.
402
403 2020-08-07 Tom Tromey <tromey@adacore.com>
404
405 * ravenscar-thread.c (update_thread_list): Set inferior_ptid.
406
407 2020-08-07 Tom Tromey <tromey@adacore.com>
408
409 * ravenscar-thread.c (ravenscar_thread_target::wait): Call
410 update_inferior_ptid before update_thread_list.
411 (temporarily_change_regcache_ptid): New class.
412 (ravenscar_thread_target::fetch_registers)
413 (ravenscar_thread_target::store_registers)
414 (ravenscar_thread_target::prepare_to_store): Use base thread when
415 forwarding operation.
416
417 2020-08-07 Tom Tromey <tromey@adacore.com>
418
419 * ravenscar-thread.c (ravenscar_thread_target::resume): Handle
420 "is_pid" case.
421
422 2020-08-07 Tom Tromey <tromey@adacore.com>
423
424 * ravenscar-thread.c (xfer_partial, enable_btrace, add_thread):
425 New methods.
426 (ravenscar_thread_target::get_thread_base_cpu): Check m_cpu_map
427 first.
428 (ravenscar_thread_target::add_thread): Rename from
429 ravenscar_add_thread.
430 (ravenscar_thread_target::update_thread_list): Use a lambda.
431 (ravenscar_thread_target::xfer_partial): New method.
432
433 2020-08-07 Tom Tromey <tromey@adacore.com>
434
435 * ada-lang.h (ada_task_list_iterator_ftype): Now a
436 gdb::function_view.
437 (iterate_over_live_ada_tasks): Change type of argument.
438 * ada-tasks.c (iterate_over_live_ada_tasks): Change type
439 of argument.
440
441 2020-08-07 Tom Tromey <tromey@adacore.com>
442
443 * ravenscar-thread.c (ravenscar_thread_target) <extra_thread_info>:
444 Remove.
445 (ravenscar_thread_target::extra_thread_info): Remove.
446 (ravenscar_thread_target::pid_to_str): Mention Ravenscar in result;
447 defer to target beneath for non-Ravenscar threads.
448
449 2020-08-07 Tom Tromey <tromey@adacore.com>
450
451 * ravenscar-thread.c (ravenscar_thread_target) <get_base_cpu,
452 get_base_thread_from_ravenscar_task>: Now methods.
453 <m_cpu_map>: New member.
454 (ravenscar_thread_target::get_thread_base_cpu): Rename from
455 ravenscar_get_thread_base_cpu. Check m_cpu_map.
456 (ravenscar_thread_target::task_is_currently_active): Update.
457 (ravenscar_thread_target::get_base_thread_from_ravenscar_task):
458 Now a method.
459 (ravenscar_thread_target::add_active_thread): Put initial thread
460 into the m_cpu_map.
461
462 2020-08-07 Tom Tromey <tromey@adacore.com>
463
464 * ravenscar-thread.c (ravenscar_thread_target::wait): Return
465 event_ptid.
466
467 2020-08-07 Tom Tromey <tromey@adacore.com>
468
469 * ravenscar-thread.c (ravenscar_thread_target::wait): Check
470 runtime_initialized.
471
472 2020-08-07 Tom Tromey <tromey@adacore.com>
473
474 * ravenscar-thread.c (ravenscar_thread_target): Don't call
475 add_active_thread.
476 (ravenscar_thread_target::add_active_thread): Now public.
477 (ravenscar_inferior_created): Call add_active_thread after pushing
478 the target.
479
480 2020-08-07 Simon Marchi <simon.marchi@polymtl.ca>
481
482 * regcache.c (ptid_regcache_map): New type.
483 (target_ptid_regcache_map): New type.
484 (regcaches): Change type to target_ptid_regcache_map.
485 (get_thread_arch_aspace_regcache): Update to regcaches' new
486 type.
487 (regcache_thread_ptid_changed): Likewise.
488 (registers_changed_ptid): Likewise.
489 (regcaches_size): Likewise.
490 (regcaches_test): Update.
491 (regcache_thread_ptid_changed): Update.
492 * regcache.h (regcache_up): New type.
493 * gdbsupport/ptid.h (hash_ptid): New struct.
494
495 2020-08-07 Simon Marchi <simon.marchi@efficios.com>
496
497 * observable.h (thread_ptid_changed): Add parameter
498 `process_stratum_target *`.
499 * infrun.c (infrun_thread_ptid_changed): Add parameter
500 `process_stratum_target *` and use it.
501 (selftests): New namespace.
502 (infrun_thread_ptid_changed): New function.
503 (_initialize_infrun): Register selftest.
504 * regcache.c (regcache_thread_ptid_changed): Add parameter
505 `process_stratum_target *` and use it.
506 (regcache_thread_ptid_changed): New function.
507 (_initialize_regcache): Register selftest.
508 * thread.c (thread_change_ptid): Pass target to
509 thread_ptid_changed observable.
510
511 2020-08-06 Caroline Tice <cmtice@google.com>
512
513 * dwarf2/read.c (struct dwo_file): Update comment on 'sections' field.
514 (struct dwp_sections): Update field comments. Add loclists and
515 rnglists fields.
516 (struct virtual_v2_dwo_sections): Rename struct to
517 'virtual_v2_or_v5_dwo_sections'; update comments at top of struct; add
518 size & offset fields for loclists and rnglists.
519 (struct dwp_hash_table): Add a 'v5' struct field to the union section.
520 (create_debug_type_hash_table): Add 'DW_UT_split_type' to the check for
521 skipping dummy type units.
522 (create_dwp_hash_table): Update the large comment above the function to
523 discuss Version 5 DWP files as well, with references. Update all the
524 version checks in the function to check for version 5 as well. Add new
525 section at the end to create dwp hash table for version 5.
526 (create_dwp_v2_section): Rename function to
527 'create_dwp_v2_or_v5_section'. Update function comment appropriately.
528 Add V5 to error message text.
529 (create_dwo_unit_in_dwp_v2): Change calls to create_dwp_v2_section
530 into calls to create_dwp_v2_or_v5_section.
531 (create_dwo_unit_in_dwp_v5): New function.
532 (lookup_dwo_unit_in_dwp): Update conditional statement to explicitly
533 check for version2; add else clause to handle version 5.
534 (open_and_init_dwo_file): Add code to check dwarf version & only call
535 create_debug_types_hash_table (with sections.types) if version is not 5;
536 else call create_debug_type_hash_table, with sections.info.
537 (dwarf2_locate_v2_dwp_sections): Update function comment to mention
538 version 5.
539 (dwarf2_locate_v5_dwp_sections): New function.
540 (open_and_init_dwp_file): Add else-if clause for version 5 to call
541 bfd_map_over_sections with dwarf2_locate_v5_dwp_sections.
542
543 2020-08-06 Simon Marchi <simon.marchi@efficios.com>
544
545 * regcache.h (class regcache): Remove friend
546 registers_changed_ptid.
547 <regcache_thread_ptid_changed>: Remove.
548 <regcaches>: Remove.
549 * regcache.c (regcache::regcaches): Rename to...
550 (regcaches): ... this. Make static.
551 (get_thread_arch_aspace_regcache): Update.
552 (regcache::regcache_thread_ptid_changed): Rename to...
553 (regcache_thread_ptid_changed): ... this. Update.
554 (class regcache_access): Remove.
555 (regcaches_test): Update.
556 (_initialize_regcache): Update.
557 * sparc64-tdep.c, dwarf2/index-write.c, record-btrace.c: Include
558 <forward_list>.
559
560 2020-08-06 Simon Marchi <simon.marchi@efficios.com>
561
562 * regcache.h (class regcache) <current_regcache>: Rename to...
563 <regcaches>: ... this. Move doc here.
564 * regcache.c (regcache::current_regcache) Rename to...
565 (regcache::regcaches): ... this. Move doc to header.
566 (get_thread_arch_aspace_regcache): Update.
567 (regcache::regcache_thread_ptid_changed): Update.
568 (registers_changed_ptid): Update.
569 (class regcache_access) <current_regcache_size>: Rename to...
570 <regcaches_size>: ... this.
571 (current_regcache_test): Rename to...
572 (regcaches_test): ... this.
573 (_initialize_regcache): Update.
574
575 2020-08-06 Victor Collod <vcollod@nvidia.com>
576
577 * amd64-tdep.c (amd64_analyze_prologue): Fix incorrect comment.
578
579 2020-08-05 Kevin Buettner <kevinb@redhat.com>
580
581 * corelow.c (core_target::build_file_mappings): Don't output
582 null pathname in warning.
583
584 2020-08-05 Simon Marchi <simon.marchi@polymtl.ca>
585
586 * gdb.dwarf2/clztest.exp, gdb.dwarf2/dw2-common-block.exp,
587 gdb.dwarf2/dw2-dup-frame.exp, gdb.dwarf2/dw2-reg-undefined.exp,
588 gdb.dwarf2/dw2-single-line-discriminators.exp,
589 dw2-undefined-ret-addr.exp: Pass nopie to compilation options.
590
591 2020-08-05 Tom Tromey <tromey@adacore.com>
592
593 PR rust/26197:
594 * dwarf2/read.c (alloc_rust_variant): Handle univariant case.
595 (quirk_rust_enum): Call alloc_rust_variant for univariant case.
596 Fix off-by-one and type size errors in ordinary case.
597
598 2020-08-05 Tom de Vries <tdevries@suse.de>
599
600 * gdbtypes.c (type_not_allocated, type_not_associated): Use
601 "prop->const_val () == 0" instead of "prop->const_val () != 0".
602
603 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
604
605 * frame.h (frame_id_p): Return bool.
606 (frame_id_artificial_p): Return bool.
607 (frame_id_eq): Return bool.
608 (has_stack_frames): Return bool.
609 (get_selected_frame): Fix typo in comment.
610 (get_frame_pc_if_available): Return bool.
611 (get_frame_address_in_block_if_available): Return bool.
612 (get_frame_func_if_available): Return bool.
613 (read_frame_register_unsigned): Return bool.
614 (get_frame_register_bytes): Return bool.
615 (safe_frame_unwind_memory): Return bool.
616 (deprecated_frame_register_read): Return bool.
617 (frame_unwinder_is): Return bool.
618 * frame.c (struct frame_info) <prev_arch::p>: Change type to
619 bool.
620 <this_id::p>: Likewise.
621 <prev_p>: Likewise.
622 (frame_stash_add): Return bool.
623 (get_frame_id): Use bool.
624 (frame_id_build_special) Use bool.
625 (frame_id_build_unavailable_stack): Use bool.
626 (frame_id_build): Use bool.
627 (frame_id_p): Return bool, use true/false instead of 1/0.
628 (frame_id_artificial_p): Likewise.
629 (frame_id_eq): Likewise.
630 (frame_id_inner): Likewise.
631 (get_frame_func_if_available): Likewise.
632 (read_frame_register_unsigned): Likewise.
633 (deprecated_frame_register_read): Likewise.
634 (get_frame_register_bytes): Likewise.
635 (has_stack_frames): Likewise.
636 (inside_main_func): Likewise.
637 (inside_entry_func): Likewise.
638 (get_frame_pc_if_available): Likewise.
639 (get_frame_address_in_block_if_available): Likewise.
640 (frame_unwinder_is): Likewise.
641 (safe_frame_unwind_memory): Likewise.
642 (frame_unwind_arch): Likewise.
643
644 2020-08-04 Simon Marchi <simon.marchi@efficios.com>
645
646 * frame.c (frame_info) <prev_func> <p>: Rename to status, change
647 type to cached_copy_status.
648 (fprintf_frame): Adjust.
649 (get_frame_func_if_available): Adjust.
650 (frame_cleanup_after_sniffer): Adjust.
651
652 2020-08-04 Mark Wielaard <mark@klomp.org>
653
654 * MAINTAINERS (Write After Approval): Update email address.
655
656 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
657
658 * gdbtypes.h (TYPE_DYN_PROP_ADDR): Remove, replace uses with
659 dynamic_prop::const_val.
660
661 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
662
663 * gdbtypes.h (TYPE_DYN_PROP_KIND): Remove, replace uses with
664 dynamic_prop::kind.
665
666 2020-08-04 Simon Marchi <simon.marchi@polymtl.ca>
667
668 * gdbtypes.h (TYPE_DYN_PROP_BATON): Remove.
669
670 2020-08-04 Jose E. Marchesi <jose.marchesi@oracle.com>
671
672 * configure.tgt: Set gdb_sim for bpf-*-* targets.
673
674 2020-08-04 Weimin Pan <weimin.pan@oracle.com>
675 Jose E. Marchesi <jose.marchesi@oracle.com>
676
677 * configure.tgt: Add entry for bpf-*-*.
678 * Makefile.in (ALL_TARGET_OBS): Add bpf-tdep.o
679 (ALLDEPFILES): Add bpf-tdep.c.
680 * bpf-tdep.c: New file.
681 * MAINTAINERS: Add bpf target and maintainer.
682 * NEWS: Mention the support for the new target.
683
684 2020-08-04 Tom de Vries <tdevries@suse.de>
685
686 PR symtab/23270
687 * dwarf2/read.c (find_partial_die): Change internal error into Dwarf
688 Error.
689
690 2020-08-03 John Baldwin <jhb@FreeBSD.org>
691
692 * syscalls/freebsd.xml: Regenerate.
693
694 2020-08-03 John Baldwin <jhb@FreeBSD.org>
695
696 * syscalls/update-freebsd.sh: Fix usage and year range.
697
698 2020-08-03 Tom de Vries <tdevries@suse.de>
699
700 PR symtab/26333
701 * dwarf2/read.c (dwarf_decode_lines_1): Ignore
702 DW_LNE_lo_user/DW_LNE_hi_user range.
703
704 2020-07-30 Simon Marchi <simon.marchi@polymtl.ca>
705
706 PR ada/26318
707 * ada-lang.c (ada_modulus): Return 0 if property is not of const
708 kind.
709
710 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
711
712 * breakpoint.c (set_breakpoint_condition): Do minor refactoring.
713
714 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
715
716 * breakpoint.c (set_breakpoint_condition): Update the condition
717 expressions after checking that the input condition string parses
718 successfully and does not contain junk at the end.
719
720 2020-07-30 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
721
722 * breakpoint.c (set_breakpoint_condition): Update the
723 condition string after parsing the new condition successfully.
724
725 2020-07-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
726
727 * proc-api.c (_STRUCTURED_PROC): Don't define.
728 * proc-events.c: Likewise.
729 * proc-flags.c: Likewise.
730 * proc-why.c: Likewise.
731 * procfs.c: Likewise.
732
733 * Makefile.in (INTERNAL_CPPFLAGS): Add LARGEFILE_CPPFLAGS.
734 * configure, config.in: Regenerate.
735
736 2020-07-30 Tom de Vries <tdevries@suse.de>
737
738 PR build/26320
739 * ui-style.h (struct ui_file_style::color): Wrap m_value and
740 m_red/m_green/m_blue in a union.
741
742 2020-07-29 Tom de Vries <tdevries@suse.de>
743
744 PR tdep/26280
745 * s390-tdep.c (s390_displaced_step_fixup): Fix Wmaybe-uninitialized.
746
747 2020-07-28 Tom Tromey <tromey@adacore.com>
748
749 PR symtab/26270:
750 * symtab.h (find_pc_partial_function_sym): Declare.
751 * cli/cli-cmds.c (disassemble_command): Use
752 find_pc_partial_function_sym. Check asm_demangle.
753 * blockframe.c (cache_pc_function_sym): New global.
754 (cache_pc_function_name): Remove.
755 (clear_pc_function_cache): Update.
756 (find_pc_partial_function_sym): New function, from
757 find_pc_partial_function.
758 (find_pc_partial_function): Rewrite using
759 find_pc_partial_function_sym.
760
761 2020-07-28 Tom Tromey <tromey@adacore.com>
762
763 * cli/cli-cmds.c (_initialize_cli_cmds): Rearrange "disassemble"
764 help. Add usage.
765
766 2020-07-28 Tom Tromey <tromey@adacore.com>
767
768 * dwarf2/expr.c (dwarf_expr_context::execute_stack_op)
769 <DW_OP_GNU_variable_value>: Cast to address type.
770
771 2020-07-28 Kamil Rytarowski <n54@gmx.com>
772
773 * nbsd-nat.h (nbsd_nat_target::xfer_partial): New declaration.
774 * nbsd-nat.c (nbsd_nat_target::xfer_partial): New function.
775 * nbsd-tdep.c (nbsd_gdbarch_data_handle, struct nbsd_gdbarch_data)
776 (init_nbsd_gdbarch_data, get_nbsd_gdbarch_data)
777 (nbsd_get_siginfo_type): New.
778 (nbsd_init_abi): Install gdbarch "get_siginfo_type" method.
779 (_initialize_nbsd_tdep): New.
780
781 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
782
783 PR binutils/26301
784 * configure: Regenerated.
785
786 2020-07-28 H.J. Lu <hongjiu.lu@intel.com>
787
788 PR binutils/26301
789 * configure: Regenerated.
790
791 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
792
793 * python/py-frame.c: Remove 'user-regs.h' include.
794 (frapy_read_register): Rewrite to make use of
795 gdbpy_parse_register_id.
796 * python/py-registers.c (gdbpy_parse_register_id): New function,
797 moved here from python/py-unwind.c. Updated the return type, and
798 also accepts register descriptor objects.
799 * python/py-unwind.c: Remove 'user-regs.h' include.
800 (pyuw_parse_register_id): Moved to python/py-registers.c.
801 (unwind_infopy_add_saved_register): Update to use
802 gdbpy_parse_register_id.
803 (pending_framepy_read_register): Likewise.
804 * python/python-internal.h (gdbpy_parse_register_id): Declare.
805
806 2020-07-28 Andrew Burgess <andrew.burgess@embecosm.com>
807
808 * python/py-registers.c: Add 'user-regs.h' include.
809 (register_descriptor_iter_find): New function.
810 (register_descriptor_iterator_object_methods): New static global
811 methods array.
812 (register_descriptor_iterator_object_type): Add pointer to methods
813 array.
814
815 2020-07-27 John Baldwin <jhb@FreeBSD.org>
816
817 * fbsd-nat.h: Include <osreldate.h>. Define USE_SIGTRAP_SIGINFO
818 for all architectures on FreeBSD 11.3 and later.
819
820 2020-07-27 Tom Tromey <tromey@adacore.com>
821
822 * gcore.h (load_corefile): Don't declare.
823
824 2020-07-27 Tom de Vries <tdevries@suse.de>
825
826 * configure.ac: Fix sys/sockets.h -> sys/socket.h typo.
827 * config.in: Regenerate.
828 * configure: Regenerate.
829
830 2020-07-26 Eli Zaretskii <eliz@gnu.org>
831
832 * configure.ac (AC_CHECK_HEADERS): Check for sys/socket.h and
833 ws2tcpip.h. When checking whether socklen_t type is defined, use
834 ws2tcpip.h if it is available and sys/socket.h isn't.
835 * configure: Regenerate.
836 * config.in: Regenerate.
837
838 2020-07-25 Andrew Burgess <andrew.burgess@embecosm.com>
839
840 PR fortran/23051
841 PR fortran/26139
842 * valops.c (value_ind): Pass address to
843 readjust_indirect_value_type.
844 * value.c (readjust_indirect_value_type): Make parameter
845 non-const, and add extra address parameter. Resolve original type
846 before using it.
847 * value.h (readjust_indirect_value_type): Update function
848 signature and comment.
849
850 2020-07-25 Tom de Vries <tdevries@suse.de>
851
852 PR symtab/26243
853 * dwarf2/read.c (lnp_state_machine::record_line): Ignore zero line
854 entries.
855
856 2020-07-24 Aaron Merey <amerey@redhat.com>
857
858 * Makefile.in: Replace LIBDEBUGINFOD with DEBUGINFOD_LIBS.
859 * configure: Rebuild.
860
861 2020-07-23 Kevin Buettner <kevinb@redhat.com>
862
863 PR corefiles/26294
864 * corelow.c (_initialize_corelow): Add period to help text
865 for "maintenance print core-file-backed-mappings".
866
867 2020-07-23 Pedro Alves <pedro@palves.net>
868
869 * frame-unwind.c (frame_unwind_try_unwinder): On exception, don't
870 touch THIS_CACHE/THIS_FRAME if the frame cache was cleared
871 meanwhile.
872 * frame.c (frame_cache_generation, get_frame_cache_generation):
873 New.
874 (reinit_frame_cache): Increment FRAME_CACHE_GENERATION.
875 (get_prev_frame_if_no_cycle): On exception, don't touch
876 PREV_FRAME/THIS_FRAME if the frame cache was cleared meanwhile.
877 * frame.h (get_frame_cache_generation): Declare.
878
879 2020-07-23 Tom de Vries <tdevries@suse.de>
880
881 PR tui/26282
882 * tui/tui-winsource.h (struct tui_source_windows::tui_source_windows):
883 New default constructor.
884
885 2020-07-23 Andrew Burgess <andrew.burgess@embecosm.com>
886
887 * disasm.c (do_mixed_source_and_assembly_deprecated): Don't
888 exclude non-statement entries.
889
890 2020-07-22 Kevin Buettner <kevinb@redhat.com>
891
892 * NEWS (New commands): Mention new command
893 "maintenance print core-file-backed-mappings".
894
895 2020-07-22 Kevin Buettner <kevinb@redhat.com>
896
897 * corelow.c (gdbcmd.h): Include.
898 (core_target::info_proc_mappings): New method.
899 (get_current_core_target): New function.
900 (maintenance_print_core_file_backed_mappings): New function.
901 (_initialize_corelow): Add core-file-backed-mappings to
902 "maint print" commands.
903
904 2020-07-22 Kevin Buettner <kevinb@redhat.com>
905
906 * linux-tdep.c (dump_note_entry_p): New function.
907 (linux_dump_mapping_p_ftype): New typedef.
908 (linux_find_memory_regions_full): Add new parameter,
909 should_dump_mapping_p.
910 (linux_find_memory_regions): Adjust call to
911 linux_find_memory_regions_full.
912 (linux_make_mappings_core_file_notes): Use dump_note_entry_p in
913 call to linux_find_memory_regions_full.
914
915 2020-07-22 Kevin Buettner <kevinb@redhat.com>
916
917 * corelow.c (solist.h, unordered_map): Include.
918 (class core_target): Add field m_core_file_mappings and
919 method build_file_mappings.
920 (core_target::core_target): Call build_file_mappings.
921 (core_target::~core_target): Free memory associated with
922 m_core_file_mappings.
923 (core_target::build_file_mappings): New method.
924 (core_target::xfer_partial): Use m_core_file_mappings
925 for memory transfers.
926 * linux-tdep.c (linux_read_core_file_mappings): New
927 function.
928 (linux_core_info_proc_mappings): Rewrite to use
929 linux_read_core_file_mappings.
930 (linux_init_abi): Register linux_read_core_file_mappings.
931
932 2020-07-22 Kevin Buettner <kevinb@redhat.com>
933
934 * arch-utils.c (default_read_core_file_mappings): New function.
935 * arch-utils.c (default_read_core_file_mappings): Declare.
936 * gdbarch.sh (read_core_file_mappings): New gdbarch method.
937 * gdbarch.h, gdbarch.c: Regenerate.
938
939 2020-07-22 Kevin Buettner <kevinb@redhat.com>
940
941 PR corefiles/25631
942 * corelow.c (core_target:xfer_partial): Revise
943 TARGET_OBJECT_MEMORY case to consider non-SEC_HAS_CONTENTS
944 case after first checking the stratum beneath the core
945 target.
946 (has_all_memory): Return true.
947 * target.c (raw_memory_xfer_partial): Revise comment
948 regarding use of has_all_memory.
949
950 2020-07-22 Kevin Buettner <kevinb@redhat.com>
951
952 * exec.h (section_table_xfer_memory): Revise declaration,
953 replacing section name parameter with an optional callback
954 predicate.
955 * exec.c (section_table_xfer_memory): Likewise.
956 * bfd-target.c, exec.c, target.c, corelow.c: Adjust all callers
957 of section_table_xfer_memory.
958
959 2020-07-22 Tom Tromey <tromey@adacore.com>
960
961 * mi/mi-cmd-stack.c (list_args_or_locals): Use
962 lookup_symbol_search_name.
963
964 2020-07-22 Andrew Burgess <andrew.burgess@embecosm.com>
965
966 * python/py-registers.c (gdbpy_register_object_data_init): Remove
967 redundant local variable.
968 (gdbpy_get_register_descriptor): Extract descriptor vector as a
969 reference, not pointer, update code accordingly.
970
971 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
972 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
973
974 * objfiles.h (struct objfile) <skip_jit_symbol_lookup>: New field.
975 * jit.c (jit_breakpoint_re_set_internal): Use the
976 `skip_jit_symbol_lookup` field.
977
978 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
979 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
980
981 * jit.c (jit_read_descriptor): Define the descriptor address once,
982 use twice.
983 (jit_breakpoint_deleted): Move the declaration of the loop variable
984 `iter` into the loop header.
985 (jit_breakpoint_re_set_internal): Move the declaration of the local
986 variable `objf_data` to the first point of definition.
987 (jit_event_handler): Move the declaration of local variables
988 `code_entry`, `entry_addr`, and `objf` to their first point of use.
989 Rename `objf` to `jited`.
990
991 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
992
993 * jit.h (struct jiter_objfile_data) <jiter_objfile_data, objfile>:
994 Remove.
995 * jit.c (get_jiter_objfile_data): Update.
996
997 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
998 Simon Marchi <simon.marchi@polymtl.ca>
999
1000 * jit.c (struct jit_program_space_data): Remove.
1001 (jit_program_space_key): Remove.
1002 (jiter_objfile_data::~jiter_objfile_data): Remove program space
1003 stuff.
1004 (get_jit_program_space_data): Remove.
1005 (jit_breakpoint_deleted): Iterate on all of the program space's
1006 objfiles.
1007 (jit_inferior_init): Likewise.
1008 (jit_breakpoint_re_set_internal): Likewise. Also change return
1009 type to void.
1010 (jit_breakpoint_re_set): Pass current_program_space to
1011 jit_breakpoint_re_set_internal.
1012
1013 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1014
1015 * jit.h (struct jiter_objfile_data) <cached_code_address,
1016 jit_breakpoint>: Move to here from ...
1017 * jit.c (jit_program_space_data): ... here.
1018 (jiter_objfile_data::~jiter_objfile_data): Update.
1019 (jit_breakpoint_deleted): Update.
1020 (jit_breakpoint_re_set_internal): Update.
1021
1022 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1023
1024 * jit.c (jiter_objfile_data::~jiter_objfile_data): Remove some
1025 checks.
1026 (jit_read_descriptor): Remove NULL check.
1027 (jit_event_handler): Add an assertion.
1028
1029 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1030
1031 * jit.h (struct jit_objfile_data): Split into...
1032 (struct jiter_objfile_data): ... this ...
1033 (struct jited_objfile_data): ... and this.
1034 * objfiles.h (struct objfile) <jit_data>: Remove.
1035 <jiter_data, jited_data>: New fields.
1036 * jit.c (jit_objfile_data::~jit_objfile_data): Rename to ...
1037 (jiter_objfile_data::~jiter_objfile_data): ... this.
1038 (get_jit_objfile_data): Rename to ...
1039 (get_jiter_objfile_data): ... this.
1040 (add_objfile_entry): Update.
1041 (jit_read_descriptor): Use get_jiter_objfile_data.
1042 (jit_find_objf_with_entry_addr): Use objfile's jited_data field.
1043 (jit_breakpoint_re_set_internal): Use get_jiter_objfile_data.
1044 (jit_inferior_exit_hook): Use objfile's jited_data field.
1045
1046 2020-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1047
1048 * jit.h: Forward-declare `struct minimal_symbol`.
1049 (struct jit_objfile_data): Migrate to here from jit.c; also add a
1050 constructor, destructor, and an objfile* field.
1051 * jit.c (jit_objfile_data): Remove.
1052 (struct jit_objfile_data): Migrate from here to jit.h.
1053 (jit_objfile_data::~jit_objfile_data): New destructor
1054 implementation with code moved from free_objfile_data.
1055 (free_objfile_data): Delete.
1056 (get_jit_objfile_data): Update to use the jit_data field of objfile.
1057 (jit_find_objf_with_entry_addr): Ditto.
1058 (jit_inferior_exit_hook): Ditto.
1059 (_initialize_jit): Remove the call to
1060 register_objfile_data_with_cleanup.
1061 * objfiles.h (struct objfile) <jit_data>: New field.
1062
1063 2020-07-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
1064
1065 * jit.h: Forward-declare `struct objfile`.
1066 (jit_event_handler): Add a second parameter, the JITer objfile.
1067 * jit.c (jit_read_descriptor): Change the signature to take the
1068 JITer objfile as an argument instead of the jit_program_space_data.
1069 (jit_inferior_init): Update the call to jit_read_descriptor.
1070 (jit_event_handler): Use the new JITer objfile argument when calling
1071 jit_read_descriptor.
1072 * breakpoint.c (handle_jit_event): Update the call to
1073 jit_event_handler to pass the JITer objfile.
1074
1075 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1076
1077 * gdbarch.c: Regenerate.
1078 * gdbarch.h: Regenerate.
1079 * gdbarch.sh (handle_segmentation_fault): Remove method.
1080 * infrun.c (handle_segmentation_fault): Remove.
1081 (print_signal_received_reason): Remove call to
1082 handle_segmentation_fault.
1083
1084 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1085
1086 * sparc64-linux-tdep.c (sparc64_linux_handle_segmentation_fault):
1087 Rename to sparc64_linux_report_signal_info and add siggnal
1088 argument.
1089 (sparc64_linux_init_abi): Use sparc64_linux_report_signal_info
1090 instead of sparc64_linux_handle_segmentation_fault.
1091
1092 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1093
1094 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Use
1095 i386_linux_report_signal_info instead of
1096 i386_linux_handle_segmentation_fault.
1097 * i386-linux-tdep.c (i386_linux_handle_segmentation_fault): Rename
1098 to i386_linux_report_signal_info and add siggnal argument.
1099 (i386_linux_init_abi): Use i386_linux_report_signal_info instead
1100 of i386_linux_handle_segmentation_fault.
1101 * i386-linux-tdep.h (i386_linux_handle_segmentation_fault): Rename
1102 to i386_linux_report_signal_info and add siggnal argument.
1103
1104 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1105
1106 * corelow.c (core_target_open): Invoke gdbarch report_signal_info
1107 hook if present.
1108
1109 2020-07-21 John Baldwin <jhb@FreeBSD.org>
1110
1111 * gdbarch.c: Regenerate.
1112 * gdbarch.h: Regenerate.
1113 * gdbarch.sh (report_signal_info): New method.
1114 * infrun.c (print_signal_received_reason): Invoke gdbarch
1115 report_signal_info hook if present.
1116
1117 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
1118
1119 * python/py-registers.c : Add 'unordered_map' include.
1120 (gdbpy_new_reggroup): Renamed to...
1121 (gdbpy_get_reggroup): ...this. Update to only create register
1122 group descriptors when needed.
1123 (gdbpy_reggroup_iter_next): Update.
1124
1125 2020-07-21 Andrew Burgess <andrew.burgess@embecosm.com>
1126
1127 * python/py-registers.c (gdbpy_register_object_data): New static
1128 global.
1129 (gdbpy_register_object_data_init): New function.
1130 (gdbpy_new_register_descriptor): Renamed to...
1131 (gdbpy_get_register_descriptor): ...this, and update to reuse
1132 existing register descriptors where possible.
1133 (gdbpy_register_descriptor_iter_next): Update.
1134 (gdbpy_initialize_registers): Register new gdbarch data.
1135
1136 2020-07-21 Simon Marchi <simon.marchi@efficios.com>
1137
1138 * linux-nat.c (stopped_pids): Make static.
1139
1140 2020-07-21 Simon Marchi <simon.marchi@polymtl.ca>
1141
1142 PR ada/26235
1143 * gdbtypes.c (ada_discrete_type_low_bound,
1144 ada_discrete_type_high_bound): Handle undefined bounds.
1145
1146 2020-07-21 Kamil Rytarowski <n54@gmx.com>
1147
1148 * nbsd-nat.h (nbsd_nat_target::supports_multi_process): New
1149 declaration.
1150 * nbsd-nat.c (nbsd_nat_target::supports_multi_process): New
1151 function.
1152
1153 2020-07-20 John Baldwin <jhb@FreeBSD.org>
1154
1155 * fbsd-tdep.c (fbsd_skip_solib_resolver): New function.
1156 (fbsd_init_abi): Install gdbarch "skip_solib_resolver" method.
1157 * fbsd-tdep.h (fbsd_skip_solib_resolver): New prototype.
1158 * mips-fbsd-tdep.c (mips_fbsd_skip_solib_resolver): New function.
1159 (mips_fbsd_init_abi): Install gdbarch "skip_solib_resolver"
1160 method.
1161
1162 2020-07-20 Ludovic Courtès <ludo@gnu.org>
1163
1164 * guile/scm-math.c (vlscm_integer_fits_p): Use 'uintmax_t'
1165 and 'intmax_t' instead of 'scm_t_uintmax' and 'scm_t_intmax',
1166 which are deprecated in Guile 3.0.
1167 * configure.ac (try_guile_versions): Add "guile-3.0".
1168 * configure (try_guile_versions): Regenerate.
1169 * NEWS: Update entry.
1170
1171 2020-07-20 Ludovic Courtès <ludo@gnu.org>
1172 Doug Evans <dje@google.com>
1173
1174 PR gdb/21104
1175 * guile/scm-ports.c (USING_GUILE_BEFORE_2_2): New macro.
1176 (ioscm_memory_port)[read_buf_size, write_buf_size]: Wrap in #if
1177 USING_GUILE_BEFORE_2_2.
1178 (stdio_port_desc, memory_port_desc) [!USING_GUILE_BEFORE_2_2]:
1179 Change type to 'scm_t_port_type *'.
1180 (natural_buffer_size) [!USING_GUILE_BEFORE_2_2]: New variable.
1181 (ioscm_open_port) [USING_GUILE_BEFORE_2_2]: Add 'stream'
1182 parameter and honor it. Update callers.
1183 (ioscm_open_port) [!USING_GUILE_BEFORE_2_2]: New function.
1184 (ioscm_read_from_port, ioscm_write) [!USING_GUILE_BEFORE_2_2]: New
1185 functions.
1186 (ioscm_fill_input, ioscm_input_waiting, ioscm_flush): Wrap in #if
1187 USING_GUILE_BEFORE_2_2.
1188 (ioscm_init_gdb_stdio_port) [!USING_GUILE_BEFORE_2_2]: Use
1189 'ioscm_read_from_port'. Call 'scm_set_port_read_wait_fd'.
1190 (ioscm_init_stdio_buffers) [!USING_GUILE_BEFORE_2_2]: New function.
1191 (gdbscm_stdio_port_p) [!USING_GUILE_BEFORE_2_2]: Use 'SCM_PORTP'
1192 and 'SCM_PORT_TYPE'.
1193 (gdbscm_memory_port_end_input, gdbscm_memory_port_seek)
1194 (ioscm_reinit_memory_port): Wrap in #if USING_GUILE_BEFORE_2_2.
1195 (gdbscm_memory_port_read, gdbscm_memory_port_write)
1196 (gdbscm_memory_port_seek, gdbscm_memory_port_close)
1197 [!USING_GUILE_BEFORE_2_2]: New functions.
1198 (gdbscm_memory_port_print): Remove use of 'SCM_PTOB_NAME'.
1199 (ioscm_init_memory_port_type) [!USING_GUILE_BEFORE_2_2]: Use
1200 'gdbscm_memory_port_read'.
1201 Wrap 'scm_set_port_end_input', 'scm_set_port_flush', and
1202 'scm_set_port_free' calls in #if USING_GUILE_BEFORE_2_2.
1203 (gdbscm_get_natural_buffer_sizes) [!USING_GUILE_BEFORE_2_2]: New
1204 function.
1205 (ioscm_init_memory_port): Remove.
1206 (ioscm_init_memory_port_stream): New function
1207 (ioscm_init_memory_port_buffers) [USING_GUILE_BEFORE_2_2]: New
1208 function.
1209 (gdbscm_memory_port_read_buffer_size) [!USING_GUILE_BEFORE_2_2]:
1210 Return scm_from_uint (0).
1211 (gdbscm_set_memory_port_read_buffer_size_x)
1212 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
1213 (gdbscm_memory_port_write_buffer_size) [!USING_GUILE_BEFORE_2_2]:
1214 Return scm_from_uint (0).
1215 (gdbscm_set_memory_port_write_buffer_size_x)
1216 [!USING_GUILE_BEFORE_2_2]: Call 'scm_setvbuf'.
1217 * configure.ac (try_guile_versions): Add "guile-2.2".
1218 * configure: Regenerate.
1219 * NEWS: Add entry.
1220
1221 2020-07-18 Tom Tromey <tom@tromey.com>
1222
1223 * linux-nat.c (linux_multi_process): Remove.
1224 (linux_nat_target::supports_multi_process): Return true.
1225
1226 2020-07-17 Andrew Burgess <andrew.burgess@embecosm.com>
1227
1228 * arch/riscv.c (riscv_tdesc_cache): Change map type.
1229 (riscv_lookup_target_description): Return pointer out of
1230 unique_ptr.
1231 * target-descriptions.c (allocate_target_description): Add
1232 comment.
1233 (target_desc_deleter::operator()): Likewise.
1234 * target-descriptions.h (struct target_desc_deleter): Moved to
1235 gdbsupport/tdesc.h.
1236 (target_desc_up): Likewise.
1237
1238 2020-07-17 Tom Tromey <tromey@adacore.com>
1239
1240 * linux-nat.c (linux_nat_target::supports_non_stop)
1241 (linux_nat_target::always_non_stop_p): Use "true".
1242 (linux_nat_target::supports_disable_randomization): Use "true" and
1243 "false".
1244
1245 2020-07-16 Caroline Tice <cmtice@google.com>
1246
1247 * dwarf2/read.c (RNGLIST_HEADER_SIZE32) New constant definition.
1248 (RNGLIST_HEADER_SIZE64): New constant definition.
1249 (struct dwop_section_names): Add rnglists_dwo.
1250 (dwop_section_names): Add .debug_rnglists.dwo, .zdebug_rnglists.dwo.
1251 (struct loclist_header): Rename to 'loclists_rnglists_header'.
1252 (struct dwo_sections): Add rnglists field.
1253 (read_attribut_reprocess): Add tag parameter.
1254 (dwarf2_ranges_read): Add tag parameter & remove forward function decl.
1255 (cu_debug_rnglists_section): New function (decl & definition).
1256 (dwarf2_locate_dwo_sections): Add code to read rnglists_dwo section.
1257 (dwarf2_rnglists_process): Add a dwarf_tag parameter, for the kind of
1258 die whose range is being checked; get rnglist section from
1259 cu_debug_rnglists_section, to get from either objfile or dwo file as
1260 appropriate. Add cases for DW_RLE_base_addressx,
1261 DW_RLE_startx_length, DW_RLE_startx_endx. Also, update to only add
1262 the base address to DW_RLE_offset_pairs (not to all ranges), moving
1263 test inside if-condition and updating complaint message.
1264 (dwarf2_ranges_process): Add dwarf tag parameter and pass it to
1265 dwarf2_rnglists_process.
1266 (dwarf2_ranges_read): Add dwarf tag parameter and pass it to
1267 dwarf2_ranges_process.
1268 (dwarf2_get_pc_bounds): Check for DW_FORM_rnglistx when setting
1269 need_ranges_base and update comment appropriately. Also pass die tag
1270 to dwarf2_ranges_read.
1271 (dwarf2_record_block_ranges): Check for DW_FORM_rnglistx when setting
1272 need_ranges_base and update comment appropriately. Also pass die tag
1273 to dwarf2_ranges_process.
1274 (read_full_die_1): Add code to read DW_AT_rnglists_base and assign to
1275 cu->ranges_base. Also pass die tag to read_attribute_reprocess.
1276 (partial_die_info::read): Check for DW_FORM_rnglistx when setting
1277 need_ranges_base and update comment appropriately. Also pass die tag
1278 to read_attribute_reprocess and dwarf2_ranges_read.
1279 (read_loclist_header): Rename function to read_loclists_rnglists_header,
1280 and update function comment appropriately.
1281 (read_loclist_index): Call read_loclists_rnglists_header instead of
1282 read_loclist_header.
1283 (read_rnglist_index): New function.
1284 (read_attribute_reprocess): Add tag parameter. Add code for
1285 DW_FORM_rnglistx, passing tag to read_rnglist_index.
1286 (read_attribute_value): Mark DW_FORM_rnglistx with need_reprocess.
1287
1288 2020-07-15 Andrew Burgess <andrew.burgess@embecosm.com>
1289
1290 * f-typeprint.c (f_type_print_base): Allow for dynamic types not
1291 being resolved.
1292
1293 2020-07-14 Andrew Burgess <andrew.burgess@embecosm.com>
1294
1295 * arch-utils.c (show_architecture): Update formatting of messages.
1296
1297 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1298
1299 * gdbtypes.h (struct type) <bounds>: Handle array and string
1300 types.
1301 * ada-lang.c (assign_aggregate): Use type::bounds on
1302 array/string type.
1303 * c-typeprint.c (c_type_print_varspec_suffix): Likewise.
1304 * c-varobj.c (c_number_of_children): Likewise.
1305 (c_describe_child): Likewise.
1306 * eval.c (evaluate_subexp_for_sizeof): Likewise.
1307 * f-typeprint.c (f_type_print_varspec_suffix): Likewise.
1308 (f_type_print_base): Likewise.
1309 * f-valprint.c (f77_array_offset_tbl): Likewise.
1310 (f77_get_upperbound): Likewise.
1311 (f77_print_array_1): Likewise.
1312 * guile/scm-type.c (gdbscm_type_range): Likewise.
1313 * m2-typeprint.c (m2_array): Likewise.
1314 (m2_is_long_set_of_type): Likewise.
1315 * m2-valprint.c (get_long_set_bounds): Likewise.
1316 * p-typeprint.c (pascal_type_print_varspec_prefix): Likewise.
1317 * python/py-type.c (typy_range): Likewise.
1318 * rust-lang.c (rust_internal_print_type): Likewise.
1319 * type-stack.c (type_stack::follow_types): Likewise.
1320 * valarith.c (value_subscripted_rvalue): Likewise.
1321 * valops.c (value_cast): Likewise.
1322
1323 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1324
1325 * gdbtypes.c (TYPE_ARRAY_BIT_STRIDE): Remove. Update all
1326 callers to use the equivalent accessor methods.
1327
1328 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1329
1330 * gdbtypes.h (struct range_bounds) <bit_stride>: New method.
1331 (struct type) <bit_stride>: New method.
1332 (TYPE_BIT_STRIDE): Remove.
1333 * gdbtypes.c (update_static_array_size): Use type::bit_stride.
1334
1335 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1336
1337 * gdbtypes.h (TYPE_ARRAY_LOWER_BOUND_VALUE,
1338 TYPE_ARRAY_UPPER_BOUND_VALUE): Remove. Update all
1339 callers to use the equivalent accessor methods instead.
1340
1341 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1342
1343 * gdbtypes.h (TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED,
1344 TYPE_ARRAY_LOWER_BOUND_IS_UNDEFINED): Remove. Update all
1345 callers to use the equivalent accessor methods instead.
1346
1347 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1348
1349 * gdbtypes.h (TYPE_LOW_BOUND_KIND,
1350 TYPE_HIGH_BOUND_KIND): Remove. Update all callers
1351 to use dynamic_prop::kind.
1352
1353 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1354
1355 * gdbtypes.h (TYPE_LOW_BOUND_UNDEFINED,
1356 TYPE_HIGH_BOUND_UNDEFINED): Remove. Update all callers
1357 to get the bound property's kind and check against
1358 PROP_UNDEFINED.
1359
1360 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1361
1362 * gdbtypes.h (TYPE_LOW_BOUND, TYPE_HIGH_BOUND): Remove. Update
1363 all callers to use type::range_bounds followed by
1364 dynamic_prop::{low,high}.
1365
1366 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
1367
1368 * gdbtypes.h (struct dynamic_prop) <kind, set_undefined,
1369 const_val, set_const_val, baton, set_locexpr, set_loclist,
1370 set_addr_offset, variant_parts, set_variant_parts,
1371 original_type, set_original_type>: New methods.
1372 <kind>: Rename to...
1373 <m_kind>: ... this. Update all users to use the new methods
1374 instead.
1375 <data>: Rename to...
1376 <m_data>: ... this. Update all users to use the new methods
1377 instead.
1378
1379 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1380
1381 * gdbtypes.c (get_discrete_bounds): Return failure if
1382 the range type's bounds are not both defined and constant
1383 values.
1384 (get_array_bounds): Update comment. Remove undefined bound check.
1385
1386 2020-07-12 Simon Marchi <simon.marchi@polymtl.ca>
1387
1388 * gdbtypes.h (TYPE_RANGE_DATA): Remove. Update callers to use
1389 the type::bounds method directly.
1390
1391 2020-07-12 Simon Marchi <simon.marchi@efficios.com>
1392
1393 * gdbtypes.h (struct type) <bounds, set_bounds>: New methods.
1394 (TYPE_RANGE_DATA): Use type::bounds. Change all uses that
1395 are used to set the range type's bounds to use set_bounds.
1396
1397 2020-07-11 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1398
1399 * exec.c (_initialize_exec): Update exec-file-mismatch help.
1400
1401 2020-07-10 Pedro Alves <pedro@palves.net>
1402
1403 * gdbthread.h (inferior_ref): Define.
1404 (scoped_restore_current_thread) <m_thread>: Now a thread_info_ref.
1405 (scoped_restore_current_thread) <m_inf>: Now an inferior_ref.
1406 * thread.c
1407 (scoped_restore_current_thread::restore):
1408 Adjust to gdb::ref_ptr.
1409 (scoped_restore_current_thread::~scoped_restore_current_thread):
1410 Remove manual decref handling.
1411 (scoped_restore_current_thread::scoped_restore_current_thread):
1412 Adjust to use
1413 inferior_ref::new_reference/thread_info_ref::new_reference.
1414 Incref the thread before calling get_frame_id instead of after.
1415 Let TARGET_CLOSE_ERROR propagate.
1416
1417 2020-07-10 Pedro Alves <pedro@palves.net>
1418
1419 * frame-tailcall.c (dwarf2_tailcall_sniffer_first): Only swallow
1420 NO_ENTRY_VALUE_ERROR / MEMORY_ERROR / OPTIMIZED_OUT_ERROR /
1421 NOT_AVAILABLE_ERROR.
1422 * value.c (value_optimized_out): Only swallow MEMORY_ERROR /
1423 OPTIMIZED_OUT_ERROR / NOT_AVAILABLE_ERROR.
1424
1425 2020-07-10 Simon Marchi <simon.marchi@polymtl.ca>
1426 Pedro Alves <pedro@palves.net>
1427
1428 PR gdb/26199
1429 * infrun.c (threads_are_resumed_pending_p): Delete.
1430 (do_target_wait): Remove threads_are_executing and
1431 threads_are_resumed_pending_p checks from the inferior_matches
1432 lambda. Update comments.
1433
1434 2020-07-10 Pedro Alves <pedro@palves.net>
1435
1436 PR gdb/26199
1437 * infrun.c (handle_no_resumed): Transfer terminal to inferior with
1438 executing threads.
1439
1440 2020-07-10 Pedro Alves <pedro@palves.net>
1441
1442 PR gdb/26199
1443 * infrun.c (handle_no_resumed): Handle multiple targets.
1444
1445 2020-07-10 Pedro Alves <pedro@palves.net>
1446
1447 PR gdb/26199
1448 * infrun.c (prepare_to_wait): Check target_can_async_p instead of
1449 target_is_async_p.
1450
1451 2020-07-10 Pedro Alves <pedro@palves.net>
1452
1453 PR gdb/26199
1454 * target.c (target_pass_ctrlc): Look at the inferior's non-exited
1455 threads, not all threads.
1456
1457 2020-07-10 Pedro Alves <pedro@palves.net>
1458
1459 PR gdb/26199
1460 * remote.c (remote_target::open_1): Pass remote target pointer as
1461 data to create_async_event_handler.
1462 (remote_async_inferior_event_handler): Mark async event handler
1463 before returning if the remote target still has either pending
1464 events or unacknowledged notifications.
1465
1466 2020-07-10 John Baldwin <jhb@FreeBSD.org>
1467
1468 * fbsd-nat.h (fbsd_nat_target::supports_multi_process): New
1469 declaration.
1470 * fbsd-nat.c (fbsd_nat_target::supports_multi_process): New
1471 function.
1472
1473 2020-07-09 John Baldwin <jhb@FreeBSD.org>
1474
1475 * inf-ptrace.c (inf_ptrace_target::wait): Don't compare against
1476 inferior_ptid.
1477
1478 2020-07-09 John Baldwin <jhb@FreeBSD.org>
1479
1480 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_ARGC,
1481 AT_FREEBSD_ARGV, AT_FREEBSD_ENVC, AT_FREEBSD_ENVV,
1482 AT_FREEBSD_PS_STRINGS.
1483
1484 2020-07-08 Hannes Domani <ssbssa@yahoo.de>
1485
1486 * auto-load.c (auto_load_objfile_script_1): Convert drive part
1487 of debugfile path on Windows.
1488
1489 2020-07-08 John Baldwin <jhb@FreeBSD.org>
1490
1491 * fbsd-nat.c (fbsd_nat_target::find_memory_regions): Rename 'obfd'
1492 argument to 'data'.
1493
1494 2020-07-08 Tom Tromey <tromey@adacore.com>
1495
1496 * ada-lang.c (ada_exception_message_1): Use read_memory.
1497
1498 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1499
1500 PR python/22748
1501 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Remove
1502 special handling for inline frames.
1503 * findvar.c (value_of_register_lazy): Skip inline frames when
1504 creating lazy register values.
1505 * frame.c (frame_id_computed_p): Delete definition.
1506 * frame.h (frame_id_computed_p): Delete declaration.
1507
1508 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1509
1510 * NEWS: Mention additions to Python API.
1511 * python/py-arch.c (archpy_register_groups): New function.
1512 (arch_object_methods): Add 'register_groups' method.
1513 * python/py-registers.c (reggroup_iterator_object): New struct.
1514 (reggroup_object): New struct.
1515 (gdbpy_new_reggroup): New function.
1516 (gdbpy_reggroup_to_string): New function.
1517 (gdbpy_reggroup_name): New function.
1518 (gdbpy_reggroup_iter): New function.
1519 (gdbpy_reggroup_iter_next): New function.
1520 (gdbpy_new_reggroup_iterator): New function
1521 (gdbpy_initialize_registers): Register new types.
1522 (reggroup_iterator_object_type): Define new Python type.
1523 (gdbpy_reggroup_getset): New static global.
1524 (reggroup_object_type): Define new Python type.
1525 * python/python-internal.h
1526
1527 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1528
1529 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-registers.c
1530 * python/py-arch.c (archpy_registers): New function.
1531 (arch_object_methods): Add 'registers' method.
1532 * python/py-registers.c: New file.
1533 * python/python-internal.h
1534 (gdbpy_new_register_descriptor_iterator): Declare.
1535 (gdbpy_initialize_registers): Declare.
1536 * python/python.c (do_start_initialization): Call
1537 gdbpy_initialize_registers.
1538 * NEWS: Mention additions to the Python API.
1539
1540 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1541
1542 * NEWS: Mention new Python API method.
1543 * python/py-unwind.c (pending_framepy_architecture): New function.
1544 (pending_frame_object_methods): Add architecture method.
1545
1546 2020-07-06 Andrew Burgess <andrew.burgess@embecosm.com>
1547
1548 * gdbarch.c: Regenerate.
1549 * gdbarch.h: Regenerate.
1550 * gdbarch.sh (deprecated_set_gdbarch_data): Delete.
1551 (gdbarch_data): Use internal_error for the case where
1552 deprecated_set_gdbarch_data was originally needed.
1553 * ia64-libunwind-tdep.c (libunwind_descr_init): Update parameters,
1554 and use passed in obstack.
1555 (libunwind_frame_set_descr): Should no longer get back NULL from
1556 gdbarch_data.
1557 (_initialize_libunwind_frame): Register as a pre-init gdbarch data
1558 type.
1559 * user-regs.c (user_regs_init): Update parameters, and use passed
1560 in obstack.
1561 (user_reg_add): Should no longer get back NULL from gdbarch_data.
1562 (_initialize_user_regs): Register as a pre-init gdbarch data type.
1563
1564 2020-07-06 Tom de Vries <tdevries@suse.de>
1565
1566 * buildsym.c (buildsym_compunit::end_symtab_with_blockvector): Handle
1567 End-Of-Sequence in lte_is_less_than.
1568 * symtab.c (find_pc_sect_line): Revert change from commit 3d92a3e313
1569 "gdb: Don't reorder line table entries too much when sorting".
1570
1571 2020-07-06 Tom de Vries <tdevries@suse.de>
1572
1573 PR tui/26205
1574 * tui/tui-win.c (tui_partial_win_by_name): Don't test for NULL name.
1575
1576 2020-07-05 Tom de Vries <tdevries@suse.de>
1577
1578 PR build/26187
1579 * inferior.h (struct infcall_suspend_state_deleter): If available, use
1580 std::uncaught_exceptions instead of deprecated
1581 std::uncaught_exception.
1582
1583 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1584
1585 * macroexp.h (macro_stringify): Return
1586 gdb::unique_xmalloc_ptr<char>.
1587 * macroexp.c (macro_stringify): Likewise.
1588 * macrotab.c (fixup_definition): Update.
1589
1590 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1591
1592 * c-exp.y (scan_macro_expansion): Don't free `expansion`.
1593 (lex_one_token): Update.
1594 * macroexp.c (struct macro_buffer) <release>: Return
1595 gdb::unique_xmalloc_ptr<char>.
1596 (macro_stringify): Update.
1597 (macro_expand): Update.
1598 (macro_expand_next): Return gdb::unique_xmalloc_ptr<char>.
1599 * macroexp.h (macro_expand_next): Likewise.
1600
1601 2020-07-02 Simon Marchi <simon.marchi@efficios.com>
1602
1603 * macroexp.h (macro_lookup_ftype): Remove.
1604 (macro_expand, macro_expand_once, macro_expand_next): Remove
1605 lookup function parameters, add scope parameter.
1606 * macroexp.c (scan, substitute_args, expand, maybe_expand,
1607 macro_expand, macro_expand_once, macro_expand_next): Likewise.
1608 * macroscope.h (standard_macro_lookup): Change parameter type
1609 to macro_scope.
1610 * macroscope.c (standard_macro_lookup): Likewise.
1611 * c-exp.y (lex_one_token): Update.
1612 * macrocmd.c (macro_expand_command): Likewise.
1613 (macro_expand_once_command): Likewise.
1614
1615 2020-07-02 Simon Marchi <simon.marchi@polymtl.ca>
1616
1617 * inf-loop.c (inferior_event_handler): Remove client_data param.
1618 * inf-loop.h (inferior_event_handler): Likewise.
1619 * infcmd.c (step_1): Adjust.
1620 * infrun.c (proceed): Adjust.
1621 (fetch_inferior_event): Remove client_data param.
1622 (infrun_async_inferior_event_handler): Adjust.
1623 * infrun.h (fetch_inferior_event): Remove `void *` param.
1624 * linux-nat.c (handle_target_event): Adjust.
1625 * record-btrace.c (record_btrace_handle_async_inferior_event):
1626 Adjust.
1627 * record-full.c (record_full_async_inferior_event_handler):
1628 Adjust.
1629 * remote.c (remote_async_inferior_event_handler): Adjust.
1630
1631 2020-07-01 Tom Tromey <tom@tromey.com>
1632
1633 * tui/tui-data.h (struct tui_win_info) <name>: Now pure virtual.
1634 * tui/tui-stack.h (struct tui_locator_window) <name>: New method.
1635
1636 2020-07-01 Tom Tromey <tom@tromey.com>
1637
1638 * tui/tui-wingeneral.c (tui_win_info::refresh_window): Move from
1639 tui_gen_win_info.
1640 (tui_win_info::make_window): Merge with
1641 tui_gen_win_info::make_window.
1642 (tui_win_info::make_visible): Move from tui_gen_win_info.
1643 * tui/tui-win.c (tui_win_info::max_width): Move from
1644 tui_gen_win_info.
1645 * tui/tui-layout.h (class tui_layout_window) <m_window>: Change
1646 type.
1647 <window_factory>: Likewise.
1648 * tui/tui-layout.c (tui_win_info::resize): Move from
1649 tui_gen_win_info.
1650 (make_standard_window): Change return type.
1651 (get_locator_window, tui_get_window_by_name): Likewise.
1652 (tui_layout_window::apply): Remove a cast.
1653 * tui/tui-data.h (MIN_WIN_HEIGHT): Move earlier.
1654 (struct tui_win_info): Merge with tui_gen_win_info.
1655 (struct tui_gen_win_info): Remove.
1656
1657 2020-07-01 Tom Tromey <tom@tromey.com>
1658
1659 * tui/tui-stack.h (struct tui_locator_window): Derive from
1660 tui_win_info.
1661 <do_scroll_horizontal, do_scroll_vertical>: New methods.
1662 <can_box>: New method.
1663
1664 2020-07-01 Tom Tromey <tom@tromey.com>
1665
1666 * tui/tui-stack.h (struct tui_locator_window): Remove body.
1667
1668 2020-07-01 Tom Tromey <tom@tromey.com>
1669
1670 * tui/tui-regs.c (tui_data_window::display_registers_from)
1671 (tui_data_window::display_registers_from)
1672 (tui_data_window::first_data_item_displayed)
1673 (tui_data_window::delete_data_content_windows): Update.
1674 (tui_data_window::refresh_window, tui_data_window::no_refresh):
1675 Remove.
1676 (tui_data_window::check_register_values): Update.
1677 (tui_data_item_window::rerender): Add parameters. Update.
1678 (tui_data_item_window::refresh_window): Remove.
1679 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: No longer
1680 virtual.
1681 * tui/tui-regs.h (struct tui_data_item_window): Don't derive from
1682 tui_gen_win_info.
1683 <refresh_window, max_height, min_height>: Remove.
1684 <rerender>: Add parameters.
1685 <x, y, visible>: New members.
1686 (struct tui_data_window) <refresh_window, no_refresh>: Remove.
1687 <m_item_width>: New member.
1688
1689 2020-07-01 Tom Tromey <tom@tromey.com>
1690
1691 * tui/tui-regs.c (tui_data_window::show_register_group)
1692 (tui_data_window::check_register_values): Update.
1693 * tui/tui-regs.h (struct tui_data_item_window) <regno>: Rename
1694 from item_no.
1695
1696 2020-07-01 Tom Tromey <tom@tromey.com>
1697
1698 * tui/tui-regs.c (tui_data_window::show_register_group): Remove
1699 useless "if".
1700
1701 2020-07-01 Tom Tromey <tom@tromey.com>
1702
1703 * tui/tui-regs.c (tui_data_window::show_register_group): Update.
1704 * tui/tui-regs.h (struct tui_data_item_window) <name>: Remove.
1705
1706 2020-07-01 Tom Tromey <tom@tromey.com>
1707
1708 * tui/tui-stack.c (SINGLE_KEY): Move from tui-data.h
1709 * tui/tui-winsource.h (enum tui_line_or_address_kind)
1710 (struct tui_line_or_address): Move from tui-data.h.
1711 * tui/tui-win.c (DEFAULT_TAB_LEN): Move from tui-data.h.
1712 * tui/tui-data.h (DEFAULT_TAB_LEN): Move to tui-win.c.
1713 (tui_cmd_window, tui_source_window_base, tui_source_window)
1714 (tui_disasm_window): Don't declare.
1715 (enum tui_line_or_address_kind, struct tui_line_or_address): Move
1716 to tui-winsource.h.
1717 (SINGLE_KEY): Move to tui-stack.c.
1718
1719 2020-07-01 Tom Tromey <tom@tromey.com>
1720
1721 * tui/tui-regs.h (struct tui_data_item_window) <content>: Now a
1722 std::string.
1723 * tui/tui-regs.c (class tab_expansion_file): New.
1724 (tab_expansion_file::write): New method.
1725 (tui_register_format): Change return type. Use
1726 tab_expansion_file.
1727 (tui_get_register, tui_data_window::display_registers_from)
1728 (tui_data_item_window::rerender): Update.
1729 * tui/tui-io.h (tui_expand_tabs): Don't declare.
1730 * tui/tui-io.c (tui_expand_tabs): Remove.
1731
1732 2020-07-01 Tom Tromey <tom@tromey.com>
1733
1734 * tui/tui-regs.c (tui_reggroup_completer): Use complete_on_enum.
1735
1736 2020-07-01 Fangrui Song <maskray@google.com>
1737
1738 * dwarf2/read.c (lnp_state_machine::check_line_address): Test -1.
1739
1740 2020-07-01 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
1741
1742 * dwarf2/read.c (set_die_type): Removed conditions to restrict
1743 forms for DW_AT_associated and DW_AT_allocated attributes,
1744 which is already checked in function attr_to_dynamic_prop.
1745
1746 2020-06-30 Tom Tromey <tromey@adacore.com>
1747
1748 * dwarf2/read.c (quirk_rust_enum): Correctly call
1749 alloc_rust_variant for default-less enum.
1750
1751 2020-06-30 Tom Tromey <tromey@adacore.com>
1752
1753 PR build/26183:
1754 * ada-lang.c (ada_lookup_name_info::ada_lookup_name_info): Use
1755 gdb::to_string.
1756
1757 2020-06-29 Simon Marchi <simon.marchi@efficios.com>
1758
1759 * gdbarch.sh (displaced_step_copy_insn): Update doc.
1760 * gdbarch.h: Re-generate.
1761
1762 2020-06-28 Tom Tromey <tom@tromey.com>
1763
1764 * command.h (cmd_types): Remove.
1765 (cmd_type): Don't declare.
1766 * cli/cli-decode.h (enum cmd_types): Uncomment. No longer a
1767 typedef.
1768 * cli/cli-cmds.c (setting_cmd): Use cmd->type directly.
1769 * cli/cli-decode.c (cmd_type): Remove.
1770
1771 2020-06-27 Pedro Alves <palves@redhat.com>
1772
1773 * fork-child.c (prefork_hook): Adjust.
1774 * infcmd.c (set_inferior_io_terminal, get_inferior_io_terminal):
1775 Delete.
1776 (set_inferior_tty_command, show_inferior_tty_command): Adjust.
1777 * inferior.c (inferior::set_tty, inferior::tty): New methods.
1778 * inferior.h (set_inferior_io_terminal, get_inferior_io_terminal):
1779 Remove declarations.
1780 (struct inferior) <set_tty, tty>: New methods.
1781 (struct inferior) <terminal>: Rename to ...
1782 (struct inferior) <m_terminal>: ... this and make private.
1783 * main.c (captured_main_1): Adjust.
1784 * mi/mi-cmd-env.c (mi_cmd_inferior_tty_set): Adjust.
1785 (mi_cmd_inferior_tty_show): Adjust.
1786 * nto-procfs.c (nto_procfs_target::create_inferior): Adjust.
1787 * windows-nat.c (windows_nat_target::create_inferior): Adjust.
1788
1789 2020-06-26 Nick Alcock <nick.alcock@oracle.com>
1790
1791 * configure.ac: Add --enable-libctf: handle --disable-static
1792 properly.
1793 * acinclude.m4: sinclude ../config/enable.m4.
1794 * Makefile.in (aclocal_m4_deps): Adjust accordingly.
1795 (LIBCTF): Substitute in.
1796 (CTF_DEPS): New, likewise.
1797 (CLIBS): libctf needs symbols from libbfd: move earlier.
1798 (CDEPS): Use CTF_DEPS, not LIBCTF, now LIBCTF can include rpath
1799 flags.
1800 * ctfread.c: Surround in ENABLE_LIBCTF.
1801 (elfctf_build_psymtabs) [!ENABLE_LIBCTF]: New stub.
1802 * configure: Regenerate.
1803 * config.in: Likewise.
1804
1805 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
1806
1807 * infcmd.c (set_inferior_io_terminal): Use make_unique_xstrdup.
1808
1809 2020-06-25 Simon Marchi <simon.marchi@efficios.com>
1810
1811 * inferior.h (struct inferior) <terminal>: Change type to
1812 gdb::unique_xmalloc_ptr<char>.
1813 * inferior.c (inferior::~inferior): Don't free inf->terminal.
1814 * infcmd.c (set_inferior_io_terminal): Don't free terminal
1815 field, adjust to unique pointer.
1816 (get_inferior_io_terminal): Adjust to unique pointer.
1817
1818 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1819
1820 * riscv-tdep.c (riscv_print_registers_info): Loop over all
1821 registers, not just the known core set of registers.
1822
1823 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1824
1825 * riscv-tdep.c (riscv_register_name): Return NULL for duplicate
1826 fflags, frm, and fcsr registers.
1827 (riscv_register_reggroup_p): Remove unknown CSRs from save and
1828 restore groups.
1829 (riscv_tdesc_unknown_reg): New function.
1830 (riscv_gdbarch_init): Pass riscv_tdesc_unknown_reg to
1831 tdesc_use_registers.
1832 * riscv-tdep.h (struct gdbarch_tdep): Add
1833 unknown_csrs_first_regnum, unknown_csrs_count,
1834 duplicate_fflags_regnum, duplicate_frm_regnum, and
1835 duplicate_fcsr_regnum fields.
1836
1837 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1838
1839 * target-descriptions.c (tdesc_use_registers): Add new parameter a
1840 callback, use the callback (when not null) to help number unknown
1841 registers.
1842 * target-descriptions.h (tdesc_unknown_register_ftype): New typedef.
1843 (tdesc_use_registers): Add extra parameter to declaration.
1844
1845 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1846
1847 * riscv-tdep.c (value_of_riscv_user_reg): Moved to here from later
1848 in the file.
1849 (class riscv_pending_register_alias): Likewise.
1850 (riscv_register_feature::register_info): Change 'required_p' field
1851 to 'required', and change its type. Add 'check' member function.
1852 (riscv_register_feature::register_info::check): Define new member
1853 function.
1854 (riscv_xreg_feature): Change initialisation of 'required' field.
1855 (riscv_freg_feature): Likewise.
1856 (riscv_virtual_feature): Likewise.
1857 (riscv_csr_feature): Likewise.
1858 (riscv_check_tdesc_feature): Take extra parameter, the csr
1859 tdesc_feature, rewrite the function to use the new
1860 riscv_register_feature::register_info::check function.
1861 (riscv_gdbarch_init): Pass the csr tdesc_feature where needed.
1862
1863 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1864
1865 * features/Makefile: Remove all references to the deleted files
1866 below.
1867 * features/riscv/32bit-csr.c: Deleted.
1868 * features/riscv/32bit-csr.xml: Deleted.
1869 * features/riscv/64bit-csr.c: Deleted.
1870 * features/riscv/64bit-csr.xml: Deleted.
1871 * features/riscv/rebuild-csr-xml.sh: Deleted.
1872
1873 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1874
1875 * riscv-tdep.c (struct riscv_register_feature::register_info): Fix
1876 whitespace error for declaration of names member variable.
1877 (struct riscv_register_feature): Add new prefer_first_name member
1878 variable, and fix whitespace error in declaration of registers.
1879 (riscv_xreg_feature): Initialize prefer_first_name field.
1880 (riscv_freg_feature): Likewise.
1881 (riscv_virtual_feature): Likewise.
1882 (riscv_csr_feature): Likewise.
1883 (riscv_register_name): Expand on comments. Remove register name
1884 modifications for CSR and virtual registers.
1885
1886 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1887
1888 * riscv-tdep.c (struct riscv_register_feature): Fix whitespace
1889 errors.
1890
1891 2020-06-25 Andrew Burgess <andrew.burgess@embecosm.com>
1892
1893 * riscv-tdep.c (riscv_create_csr_aliases): Handle csr aliases from
1894 riscv-opc.h.
1895 (class riscv_pending_register_alias): New class.
1896 (riscv_check_tdesc_feature): Take vector of pending aliases and
1897 populate it as appropriate.
1898 (riscv_setup_register_aliases): Delete.
1899 (riscv_gdbarch_init): Create vector of pending aliases and pass it
1900 to riscv_check_tdesc_feature in all cases. Use the vector to
1901 create the register aliases.
1902
1903 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1904
1905 * sol2-tdep.c (sol2_static_transform_name): Remove.
1906 (sol2_init_abi): Don't register it.
1907 * gdbarch.sh (static_transform_name): Remove.
1908 * gdbarch.c, gdbarch.h: Regenerate.
1909
1910 * dbxread.c (read_dbx_symtab) <'S'>: Remove call to
1911 gdbarch_static_transform_name.
1912 * mdebugread.c (parse_partial_symbols) <'S'>: Likewise.
1913 * stabsread.c (define_symbol) <'X'>: Remove.
1914 (define_symbol) <'S'>: Remove gdbarch_static_transform_name
1915 handling.
1916 <'V'>: Likewise.
1917 * xcoffread.c (scan_xcoff_symtab): Remove gdbarch.
1918 <'S'>: Remove call to gdbarch_static_transform_name.
1919
1920 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1921
1922 * procfs.c (procfs_pre_trace): New function.
1923 (procfs_target::create_inferior): Pass it to fork_inferior.
1924
1925 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1926
1927 * configure.tgt <sparc-*-linux*> (gdb_target_obs): Remove
1928 sparc-sol2-tdep.o, sol2-tdep.o, sparc64-sol2-tdep.o.
1929 <sparc64-*-linux*> (gdb_target_obs): Remove sparc64-sol2-tdep.o,
1930 sol2-tdep.o, sparc-sol2-tdep.o.
1931 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Make static.
1932 * sparc-tdep.h (sparc32_sol2_init_abi): Remove.
1933 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Make static.
1934 * sparc64-tdep.h (sparc64_sol2_init_abi): Remove.
1935
1936 2020-06-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1937
1938 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Remove.
1939 (amd64_sol2_init_abi): Use sol2_sigtramp_p.
1940 Call sol2_init_abi.
1941 Remove calls to set_gdbarch_skip_solib_resolver,
1942 set_gdbarch_core_pid_to_str.
1943 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Remove.
1944 (i386_sol2_static_transform_name): Remove.
1945 (i386_sol2_init_abi): Call sol2_init_abi.
1946 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1947 set_gdbarch_static_transform_name,
1948 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
1949 Use sol2_sigtramp_p.
1950 * sol2-tdep.c (sol2_pc_in_sigtramp): New function.
1951 (sol2_sigtramp_p): New function.
1952 (sol2_static_transform_name): New function.
1953 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Make static.
1954 (sol2_init_abi): New function.
1955 * sol2-tdep.h (sol2_sigtramp_p, sol2_init_abi): Declare.
1956 (sol2_skip_solib_resolver, sol2_core_pid_to_str): Remove.
1957 * sparc-sol2-tdep.c (sparc_sol2_pc_in_sigtramp): Remove.
1958 (sparc32_sol2_sigtramp_frame_sniffer): Just call sol2_sigtramp_p.
1959 (sparc_sol2_static_transform_name): Remove.
1960 (sparc32_sol2_init_abi): Call sol2_init_abi.
1961 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1962 set_gdbarch_static_transform_name,
1963 set_gdbarch_skip_solib_resolver,
1964 set_gdbarch_core_pid_to_str.
1965 * sparc-tdep.h (sparc_sol2_pc_in_sigtramp)
1966 (sparc_sol2_static_transform_name): Remove
1967 * sparc64-sol2-tdep.c (sparc64_sol2_sigtramp_frame_sniffer): Just
1968 call sol2_sigtramp_p.
1969 (sparc64_sol2_init_abi): Call sol2_init_abi.
1970 Remove calls to set_gdbarch_sofun_address_maybe_missing,
1971 set_gdbarch_static_transform_name,
1972 set_gdbarch_skip_solib_resolver, set_gdbarch_core_pid_to_str.
1973
1974 2020-06-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1975
1976 * symfile-add-flags.h: New flag SYMFILE_ALWAYS_CONFIRM.
1977 * exec.c (validate_exec_file): If from_tty, set both
1978 SYMFILE_VERBOSE (== from_tty) and SYMFILE_ALWAYS_CONFIRM.
1979 * symfile.c (symbol_file_add_with_addrs): if always_confirm
1980 and from_tty, unconditionally ask a confirmation.
1981
1982 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1983
1984 * target-descriptions.c (tdesc_architecture_name): Protect against
1985 NULL pointer dereference.
1986 (maint_print_xml_tdesc_cmd): New function.
1987 (_initialize_target_descriptions): Register new 'maint print
1988 xml-tdesc' command and give it the filename completer.
1989 * NEWS: Mention new 'maint print xml-tdesc' command.
1990
1991 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
1992
1993 * target-descriptions.c (class tdesc_compatible_info): New class.
1994 (struct target_desc): Change type of compatible vector.
1995 (tdesc_compatible_p): Update for change in type of
1996 target_desc::compatible.
1997 (tdesc_compatible_info_list): New function.
1998 (tdesc_compatible_info_arch_name): New function.
1999 (tdesc_add_compatible): Update for change in type of
2000 target_desc::compatible.
2001 (print_c_tdesc::visit_pre): Likewise.
2002
2003 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2004
2005 * target-descriptions.c (print_c_tdesc::print_c_tdesc): Change
2006 whitespace to underscore.
2007 (maint_print_c_tdesc_cmd): Use fake filename for target
2008 descriptions that came from the target.
2009 (_initialize_target_descriptions): Add filename command completion
2010 for 'maint print c-tdesc'.
2011
2012 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
2013
2014 * dwarf2/loc.c (decode_debug_loclists_addresses): Add empty
2015 lines.
2016
2017 2020-06-23 Simon Marchi <simon.marchi@efficios.com>
2018
2019 * dwarf2/loc.c (decode_debug_loc_dwo_addresses): Add empty
2020 lines.
2021 (dwarf2_find_location_expression): Likewise.
2022 (call_site_parameter_matches): Likewise.
2023 (dwarf2_compile_expr_to_ax): Likewise.
2024 (disassemble_dwarf_expression): Likewise.
2025 (loclist_describe_location): Likewise.
2026
2027 2020-06-23 Pedro Alves <palves@redhat.com>
2028
2029 * gdbarch-selftests.c: Don't include inferior.h, gdbthread.h or
2030 progspace-and-thread.h. Include scoped-mock-context.h instead.
2031 (register_to_value_test): Use scoped_mock_context.
2032 * regcache.c: Include "scoped-mock-context.h".
2033 (cooked_read_test): Don't error out if a target is already pushed.
2034 Use scoped_mock_context. Adjust.
2035 * scoped-mock-context.h: New file.
2036
2037 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2038
2039 * ada-lang.c (ada_language_data): Delete la_is_string_type_p
2040 initializer.
2041 (ada_language::is_string_type_p): New member function.
2042 * c-lang.c (c_language_data): Delete la_is_string_type_p
2043 initializer.
2044 (cplus_language_data): Likewise.
2045 (asm_language_data): Likewise.
2046 (minimal_language_data): Likewise.
2047 * d-lang.c (d_language_data): Likewise.
2048 * f-lang.c (f_is_string_type_p): Delete function, implementation
2049 moved to f_language::is_string_type_p.
2050 (f_language_data): Delete la_is_string_type_p initializer.
2051 (f_language::is_string_type_p): New member function,
2052 implementation from f_is_string_type_p.
2053 * go-lang.c (go_is_string_type_p): Delete function, implementation
2054 moved to go_language::is_string_type_p.
2055 (go_language_data): Delete la_is_string_type_p initializer.
2056 (go_language::is_string_type_p): New member function,
2057 implementation from go_is_string_type_p.
2058 * language.c (language_defn::is_string_type_p): Define new member
2059 function.
2060 (default_is_string_type_p): Make static, add comment copied from
2061 header file.
2062 (unknown_language_data): Delete la_is_string_type_p initializer.
2063 (unknown_language::is_string_type_p): New member function.
2064 (auto_language_data): Delete la_is_string_type_p initializer.
2065 (auto_language::is_string_type_p): New member function.
2066 * language.h (language_data): Delete la_is_string_type_p field.
2067 (language_defn::is_string_type_p): Declare new function.
2068 (default_is_string_type_p): Delete desclaration, move comment to
2069 definition.
2070 * m2-lang.c (m2_is_string_type_p): Delete function, implementation
2071 moved to m2_language::is_string_type_p.
2072 (m2_language_data): Delete la_is_string_type_p initializer.
2073 (m2_language::is_string_type_p): New member function,
2074 implementation from m2_is_string_type_p.
2075 * objc-lang.c (objc_language_data): Delete la_is_string_type_p
2076 initializer.
2077 * opencl-lang.c (opencl_language_data): Likewise.
2078 * p-lang.c (pascal_is_string_type_p): Delete function,
2079 implementation moved to pascal_language::is_string_type_p.
2080 (pascal_language_data): Delete la_is_string_type_p initializer.
2081 (pascal_language::is_string_type_p): New member function,
2082 implementation from pascal_is_string_type_p.
2083 * rust-lang.c (rust_is_string_type_p): Delete function,
2084 implementation moved to rust_language::is_string_type_p.
2085 (rust_language_data): Delete la_is_string_type_p initializer.
2086 (rust_language::is_string_type_p): New member function,
2087 implementation from rust_is_string_type_p.
2088 * valprint.c (val_print_scalar_or_string_type_p): Update call to
2089 is_string_type_p.
2090
2091 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2092
2093 * ada-lang.c (ada_language_data): Delete la_print_typedef
2094 initializer.
2095 (ada_language::print_typedef): New member function.
2096 * c-lang.c (c_language_data): Delete la_print_typedef initializer.
2097 (cplus_language_data): Likewise.
2098 (asm_language_data): Likewise.
2099 (minimal_language_data): Likewise.
2100 * d-lang.c (d_language_data): Likewise.
2101 * f-lang.c (f_language_data): Likewise.
2102 (f_language::print_typedef): New member function.
2103 * go-lang.c (go_language_data): Delete la_print_typedef
2104 initializer.
2105 * language.c (language_defn::print_typedef): Define member
2106 function.
2107 (unknown_language_data): Delete la_print_typedef initializer.
2108 (unknown_language::print_typedef): New member function.
2109 (auto_language_data): Delete la_print_typedef initializer.
2110 (auto_language::print_typedef): New member function.
2111 * language.h (language_data): Delete la_print_typedef field.
2112 (language_defn::print_typedef): Declare new member function.
2113 (LA_PRINT_TYPEDEF): Update call to print_typedef.
2114 (default_print_typedef): Delete declaration.
2115 * m2-lang.c (m2_language_data): Delete la_print_typedef
2116 initializer.
2117 (m2_language::print_typedef): New member function.
2118 * objc-lang.c (objc_language_data): Delete la_print_typedef
2119 initializer.
2120 * opencl-lang.c (opencl_language_data): Likewise.
2121 * p-lang.c (pascal_language_data): Likewise.
2122 (pascal_language::print_typedef): New member function.
2123 * rust-lang.c (rust_print_typedef): Delete function,
2124 implementation moved to rust_language::print_typedef.
2125 (rust_language): Delete la_print_typedef initializer.
2126 (rust_language::print_typedef): New member function,
2127 implementation from rust_print_typedef.
2128 * typeprint.c (default_print_typedef): Delete.
2129
2130 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2131
2132 * ada-lang.c (ada_language_data): Delete la_printstr initializer.
2133 (ada_language::printstr): New member function.
2134 * c-lang.c (c_language_data): Delete la_printstr initializer.
2135 (cplus_language_data): Likewise.
2136 (asm_language_data): Likewise.
2137 (minimal_language_data): Likewise.
2138 * d-lang.c (d_language_data): Likewise.
2139 * f-lang.c (f_printstr): Rename to f_language::printstr.
2140 (f_language_data): Delete la_printstr initializer.
2141 (f_language::printstr): New member function, implementation from
2142 f_printstr.
2143 * go-lang.c (go_language_data): Delete la_printstr initializer.
2144 * language.c (language_defn::printstr): Define new member
2145 function.
2146 (unk_lang_printstr): Delete.
2147 (unknown_language_data): Delete la_printstr initializer.
2148 (unknown_language::printstr): New member function.
2149 (auto_language_data): Delete la_printstr initializer.
2150 (auto_language::printstr): New member function.
2151 * language.h (language_data): Delete la_printstr field.
2152 (language_defn::printstr): Declare new member function.
2153 (LA_PRINT_STRING): Update call to printstr.
2154 * m2-lang.c (m2_printstr): Rename to m2_language::printstr.
2155 (m2_language_data): Delete la_printstr initializer.
2156 (m2_language::printstr): New member function, implementation from
2157 m2_printstr.
2158 * objc-lang.c (objc_language_data): Delete la_printstr
2159 initializer.
2160 * opencl-lang.c (opencl_language_data): Likewise.
2161 * p-lang.c (pascal_printstr): Rename to pascal_language::printstr.
2162 (pascal_language_data): Delete la_printstr initializer.
2163 (pascal_language::printstr): New member function, implementation
2164 from pascal_printstr.
2165 * p-lang.h (pascal_printstr): Delete declaration.
2166 * rust-lang.c (rust_printstr): Update header comment.
2167 (rust_language_data): Delete la_printstr initializer.
2168 (rust_language::printstr): New member function.
2169
2170 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2171
2172 * ada-lang.c (ada_language_data): Delete la_printchar initializer.
2173 (ada_language::printchar): New member function.
2174 * c-lang.c (c_language_data): Delete la_printchar initializer.
2175 (cplus_language_data): Likewise.
2176 (asm_language_data): Likewise.
2177 (minimal_language_data): Likewise.
2178 * d-lang.c (d_language_data): Likewise.
2179 * f-lang.c (f_printchar): Rename to f_language::printchar.
2180 (f_language_data): Delete la_printchar initializer.
2181 (f_language::printchar): New member function, implementation from
2182 f_printchar.
2183 * go-lang.c (go_language_data): Delete la_printchar initializer.
2184 * language.c (unk_lang_printchar): Delete.
2185 (language_defn::printchar): Define new member function.
2186 (unknown_language_data): Delete la_printchar initializer.
2187 (unknown_language::printchar): New member function.
2188 (auto_language_data): Delete la_printchar initializer.
2189 (auto_language::printchar): New member function.
2190 * language.h (language_data): Delete la_printchar field.
2191 (language_defn::printchar): Declare new member function.
2192 (LA_PRINT_CHAR): Update call to printchar.
2193 * m2-lang.c (m2_language_data): Delete la_printchar initializer.
2194 (m2_language::printchar): New member function.
2195 * objc-lang.c (objc_language_data): Delete la_printchar
2196 initializer.
2197 * opencl-lang.c (opencl_language_data): Likewise.
2198 * p-lang.c (pascal_language_data): Delete la_printchar
2199 initializer.
2200 (pascal_language::printchar): New member function.
2201 * rust-lang.c (rust_printchar): Rename to
2202 rust_language::printchar.
2203 (rust_language_data): Delete la_printchar initializer.
2204 (rust_language::printchar): New member function, implementation
2205 from rust_printchar.
2206
2207 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2208
2209 * ada-lang.c (emit_char): Renamed to ada_language::emitchar.
2210 (ada_language_data): Delete la_emitchar initializer.
2211 (ada_language::emitchar): New member function, implementation from
2212 emit_char.
2213 * c-lang.c (c_language_data): Delete la_emitchar initializer.
2214 (cplus_language_data): Likewise.
2215 (asm_language_data): Likewise.
2216 (minimal_language_data): Likewise.
2217 * d-lang.c (d_language_data): Likewise.
2218 * f-lang.c (f_emit_char): Rename to f_language::emitchar.
2219 (f_language_data): Delete la_emitchar initializer.
2220 (f_language::emitchar): New member function, implementation from
2221 f_emit_char.
2222 * go-lang.c (go_language_data): Delete la_emitchar initializer.
2223 * language.c (unk_lang_emit_char): Delete.
2224 (language_defn::emitchar): New member function definition.
2225 (unknown_language_data): Delete la_emitchar initializer.
2226 (unknown_language::emitchar): New member function.
2227 (auto_language_data): Delete la_emitchar initializer.
2228 (auto_language::emitchar): New member function.
2229 * language.h (language_data): Delete la_emitchar field.
2230 (language_defn::emitchar): New member field declaration.
2231 (LA_EMIT_CHAR): Update call to emitchar.
2232 * m2-lang.c (m2_emit_char): Rename to m2_language::emitchar.
2233 (m2_language_data): Delete la_emitchar initializer.
2234 (m2_language::emitchar): New member function, implementation from
2235 m2_emit_char.
2236 * objc-lang.c (objc_language_data): Delete la_emitchar
2237 initializer.
2238 * opencl-lang.c (opencl_language_data): Likewise.
2239 * p-lang.c (pascal_emit_char): Rename to pascal_language::emitchar.
2240 (pascal_language_data): Delete la_emitchar initializer.
2241 (pascal_language::emitchar): New member function, implementation
2242 from pascal_emit_char.
2243 * rust-lang.c (rust_emitchar): Rename to rust_language::emitchar.
2244 (rust_language_data): Delete la_emitchar initializer.
2245 (rust_language::emitchar): New member function, implementation
2246 from rust_emitchar.
2247
2248 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2249
2250 * ada-lang.c (resolve): Rename to ada_language::post_parser.
2251 (ada_language_data): Delete la_post_parser initializer.
2252 (ada_language::post_parser): New member function.
2253 * c-lang.c (c_language_data): Delete la_post_parser initializer.
2254 (cplus_language_data): Likewise.
2255 (asm_language_data): Likewise.
2256 (minimal_language_data): Likewise.
2257 * d-lang.c (d_language_data): Likewise.
2258 * f-lang.c (f_language_data): Likewise.
2259 * go-lang.c (go_language_data): Likewise.
2260 * language.c (unknown_language_data): Likewise.
2261 (auto_language_data): Likewise.
2262 * language.h (language_data): Delete la_post_parser field.
2263 (language_defn::post_parser): New member function.
2264 * m2-lang.c (m2_language_data): Delete la_post_parser initializer.
2265 * objc-lang.c (objc_language_data): Likewise.
2266 * opencl-lang.c (opencl_language_data): Likewise.
2267 * p-lang.c (pascal_language_data): Likewise.
2268 * parse.c (parse_exp_in_context): Update call to post_parser.
2269 (null_post_parser): Delete definition.
2270 * parser-defs.h (null_post_parser): Delete declaration.
2271 * rust-lang.c (rust_language_data): Delete la_post_parser
2272 initializer.
2273
2274 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2275
2276 * ada-lang.c (parse): Rename to ada_language::parser.
2277 (ada_language_data): Delete la_parser initializer.
2278 (ada_language::parser): New member function, implementation from
2279 parse.
2280 * c-lang.c (c_language_data): Delete la_parser initializer.
2281 (cplus_language_data): Likewise.
2282 (asm_language_data): Likewise.
2283 (minimal_language_data): Likewise.
2284 * d-lang.c (d_language_data): Likewise.
2285 (d_language::parser): New member function.
2286 * f-lang.c (f_language_data): Delete la_parser initializer.
2287 (f_language::parser): New member function.
2288 * go-lang.c (go_language_data): Delete la_parser initializer.
2289 (go_language::parser): New member function.
2290 * language.c (unk_lang_parser): Delete.
2291 (language_defn::parser): Define new member function.
2292 (unknown_language_data): Delete la_parser initializer.
2293 (unknown_language::parser): New member function.
2294 (auto_language_data): Delete la_parser initializer.
2295 (auto_language::parser): New member function.
2296 * language.h (language_data): Delete la_parser field.
2297 (language_defn::parser): Declare new member function.
2298 * m2-lang.c (m2_language_data): Delete la_parser initializer.
2299 (m2_language::parser): New member function.
2300 * objc-lang.c (objc_language_data): Delete la_parser initializer.
2301 * opencl-lang.c (opencl_language_data): Likewise.
2302 * p-lang.c (pascal_language_data): Likewise.
2303 (pascal_language::parser): New member function.
2304 * parse.c (parse_exp_in_context): Update call to parser.
2305 * rust-lang.c (rust_language_data): Delete la_parser initializer.
2306 (rust_language::parser): New member function.
2307
2308 2020-06-23 Andrew Burgess <andrew.burgess@embecosm.com>
2309
2310 * top.c (print_gdb_configuration): Print --with-python-libdir
2311 configuration value.
2312
2313 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2314
2315 * NEWS: Mention change to the alias command.
2316
2317 2020-06-22 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2318
2319 * cli/cli-cmds.c (lookup_cmd_for_default_args)
2320 (alias_command_completer)
2321 (make_alias_options_def_group): New functions.
2322 (alias_opts, alias_option_defs): New struct and array.
2323 (alias_usage_error): Update usage.
2324 (alias_command): Handles optional DEFAULT-ARGS... arguments.
2325 Use option framework.
2326 (_initialize_cli_cmds): Update alias command help.
2327 Update aliases command help.
2328 (show_user):
2329 Add NULL for new default_args lookup_cmd argument.
2330 (valid_command_p): Rename to validate_aliased_command.
2331 Add NULL for new default_args lookup_cmd argument. Verify that the
2332 aliased_command has no default args.
2333 * cli/cli-decode.c (help_cmd): Show aliases definitions.
2334 (lookup_cmd_1, lookup_cmd): New argument default_args.
2335 (add_alias_cmd):
2336 Add NULL for new default_args lookup_cmd argument.
2337 (print_help_for_command): Show default args under the layout
2338 alias some_alias = some_aliased_cmd some_alias_default_arg.
2339 * cli/cli-decode.h (struct cmd_list_element): New member default_args.
2340 xfree default_args in destructor.
2341 * cli/cli-script.c (process_next_line, do_define_command):
2342 Add NULL for new default_args lookup_cmd argument.
2343 * command.h: Declare new default_args argument in lookup_cmd
2344 and lookup_cmd_1.
2345 * completer.c (complete_line_internal_1):
2346 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
2347 * guile/scm-cmd.c (gdbscm_parse_command_name): Likewise.
2348 * guile/scm-param.c (add_setshow_generic, pascm_parameter_defined_p):
2349 Likewise.
2350 * infcmd.c (_initialize_infcmd): Likewise.
2351 * python/py-auto-load.c (gdbpy_initialize_auto_load): Likewise.
2352 * python/py-cmd.c (gdbpy_parse_command_name): Likewise.
2353 * python/py-param.c (add_setshow_generic): Likewise.
2354 * remote.c (_initialize_remote): Likewise.
2355 * top.c (execute_command): Prepend default_args if command has some.
2356 (set_verbose):
2357 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
2358 * tracepoint.c (validate_actionline, encode_actions_1):
2359 Add NULL for new default_args lookup_cmd or lookup_cmd_1 argument.
2360
2361 2020-06-22 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
2362
2363 * jit.c (jit_read_descriptor): Use bool as the return type.
2364 (jit_breakpoint_re_set_internal): Use bool as the return type.
2365 Invert the return value logic; return true if the jit breakpoint
2366 has been successfully initialized.
2367 (jit_inferior_init): Update the call to
2368 jit_breakpoint_re_set_internal.
2369
2370 2020-06-22 Pedro Alves <palves@redhat.com>
2371
2372 PR gdb/25939
2373 * procfs.c (procfs_target::wait): Don't reference inferior_ptid.
2374 Use the current inferior instead. Don't return
2375 TARGET_WAITKIND_SPURIOUS/inferior_ptid -- instead continue and
2376 wait again.
2377 * sol-thread.c (sol_thread_target::wait): Don't reference
2378 inferior_ptid.
2379 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs)
2380 (sol_update_thread_list_callback): Use the current inferior's pid
2381 instead of inferior_ptid.
2382
2383 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2384
2385 * procfs.c: Cleanup many comments.
2386
2387 (READ_WATCHFLAG, WRITE_WATCHFLAG, EXEC_WATCHFLAG)
2388 (AFTER_WATCHFLAG): Replace by value.
2389
2390 (MAIN_PROC_NAME_FORMAT): Inline ...
2391 (create_procinfo): ... here.
2392
2393 (procfs_debug_inferior): Remove SYS_exec handling.
2394 (syscall_is_exec): Likewise.
2395 (procfs_set_exec_trap): Likewise.
2396
2397 (syscall_is_lwp_exit): Inline in callers.
2398 (syscall_is_exit): Likewise.
2399 (syscall_is_exec): Likewise.
2400 (syscall_is_lwp_create): Likewise.
2401
2402 (invalidate_cache): Remove #if 0 code.
2403
2404 (make_signal_thread_runnable): Remove.
2405 (procfs_target::resume): Remove #if 0 code.
2406
2407 2020-06-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2408
2409 PR gdb/25939
2410 * procfs.c (procfs_target::procfs_init_inferior): Move push_target
2411 call ...
2412 (procfs_target::create_inferior): ... here.
2413
2414 2020-06-21 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2415
2416 * exec.c (validate_exec_file): Ensure the build-id is up to
2417 date by calling reopen_exec_file (that checks file timestamp
2418 to decide to re-read the file).
2419
2420 2020-06-18 Pedro Alves <palves@redhat.com>
2421
2422 PR gdb/25412
2423 * gdbthread.h (delete_thread, delete_thread_silent)
2424 (find_thread_ptid): Update comments.
2425 * thread.c (current_thread_): New global.
2426 (is_current_thread): Move higher, and reimplement.
2427 (inferior_thread): Reimplement.
2428 (set_thread_exited): Use bool. Add assertions.
2429 (add_thread_silent): Simplify thread-reuse handling by always
2430 calling delete_thread.
2431 (delete_thread): Remove intro comment.
2432 (find_thread_ptid): Skip exited threads.
2433 (switch_to_thread_no_regs): Write to current_thread_.
2434 (switch_to_no_thread): Check CURRENT_THREAD_ instead of
2435 INFERIOR_PTID. Clear current_thread_.
2436
2437 2020-06-18 Pedro Alves <palves@redhat.com>
2438
2439 * aix-thread.c (pd_update): Use switch_to_thread.
2440
2441 2020-06-18 Pedro Alves <palves@redhat.com>
2442
2443 * ravenscar-thread.c (ravenscar_thread_target): Update.
2444 (ravenscar_thread_target::update_inferior_ptid): Rename to ...
2445 (ravenscar_thread_target::add_active_thread): ... this. Don't
2446 set m_base_ptid here. Update to avoid referencing inferior_ptid.
2447 (ravenscar_thread_target::wait): Don't write to inferior_ptid.
2448
2449 2020-06-18 Pedro Alves <palves@redhat.com>
2450
2451 * nat/windows-nat.c (current_windows_thread): Remove.
2452 * nat/windows-nat.h (current_windows_thread): Remove.
2453 * windows-nat.c (windows_nat_target::stopped_by_sw_breakpoint):
2454 Adjust.
2455 (display_selectors): Adjust to fetch the current
2456 windows_thread_info based on inferior_ptid.
2457 (fake_create_process): No longer write to current_windows_thread.
2458 (windows_nat_target::get_windows_debug_event):
2459 Don't set inferior_ptid or current_windows_thread.
2460 (windows_nat_target::wait): Adjust to not rely on
2461 current_windows_thread.
2462 (do_initial_windows_stuff): Now a method of windows_nat_target.
2463 Switch to the last_ptid thread.
2464 (windows_nat_target::attach): Adjust.
2465 (windows_nat_target::detach): Use switch_to_no_thread instead of
2466 writing to inferior_ptid directly.
2467 (windows_nat_target::create_inferior): Adjust.
2468
2469 2020-06-18 Pedro Alves <palves@redhat.com>
2470
2471 * windows-nat.c (do_initial_windows_stuff): No longer set inferior_ptid.
2472
2473 2020-06-18 Pedro Alves <palves@redhat.com>
2474
2475 * go32-nat.c (go32_nat_target::create_inferior): Switch to thread
2476 after creating it, instead of writing to inferior_ptid. Don't
2477 write to inferior_ptid.
2478
2479 2020-06-18 Pedro Alves <palves@redhat.com>
2480
2481 * fork-child.c (postfork_hook): Don't write to inferior_ptid.
2482
2483 2020-06-18 Pedro Alves <palves@redhat.com>
2484
2485 * bsd-kvm.c (bsd_kvm_target_open): Switch to thread after adding
2486 it, instead of writing to inferior_ptid.
2487
2488 2020-06-18 Pedro Alves <palves@redhat.com>
2489
2490 * btrace.c (btrace_fetch): Use switch_to_thread instead of writing
2491 to inferior_ptid.
2492
2493 2020-06-18 Pedro Alves <palves@redhat.com>
2494
2495 * bsd-kvm.c (bsd_kvm_target::close): Use switch_to_no_thread
2496 instead of writing to inferior_ptid directly.
2497
2498 2020-06-18 Pedro Alves <palves@redhat.com>
2499
2500 * corelow.c (core_target::close): Use switch_to_no_thread instead
2501 of writing to inferior_ptid directly.
2502 (add_to_thread_list, core_target_open): Use switch_to_thread
2503 instead of writing to inferior_ptid directly.
2504
2505 2020-06-18 Pedro Alves <palves@redhat.com>
2506
2507 * darwin-nat.c (darwin_nat_target::decode_message): Don't write to
2508 inferior_ptid.
2509 (darwin_nat_target::stop_inferior, darwin_nat_target::kill): Avoid
2510 inferior_ptid.
2511 (darwin_attach_pid): Use switch_to_no_thread instead of writing to
2512 inferior_ptid directly.
2513 (darwin_nat_target::init_thread_list): Switch to thread, instead
2514 of writing to inferior_ptid.
2515 (darwin_nat_target::attach): Don't write to inferior_ptid.
2516 (darwin_nat_target::get_ada_task_ptid): Avoid inferior_ptid.
2517
2518 2020-06-18 Pedro Alves <palves@redhat.com>
2519
2520 * gnu-nat.c (gnu_nat_target::create_inferior): Switch to the added
2521 thread.
2522 (gnu_nat_target::attach): Don't write to inferior_ptid directly.
2523 Instead use switch_to_thread.
2524 (gnu_nat_target::detach): Use switch_to_no_thread
2525 instead of writing to inferior_ptid directly. Used passed-in
2526 inferior instead of looking up the inferior by pid.
2527
2528 2020-06-18 Pedro Alves <palves@redhat.com>
2529
2530 * go32-nat.c (go32_nat_target::create_inferior): Don't write to
2531 inferior_ptid.
2532
2533 2020-06-18 Pedro Alves <palves@redhat.com>
2534
2535 * nto-procfs.c (nto_procfs_target::update_thread_list): Avoid
2536 inferior_ptid.
2537 (nto_procfs_target::attach): Avoid inferior_ptid. Switch to
2538 thread.
2539 (nto_procfs_target::detach): Avoid referencing
2540 inferior_ptid. Use switch_to_no_thread instead of writing to
2541 inferior_ptid directly.
2542 (nto_procfs_target::mourn_inferior): Use switch_to_no_thread
2543 instead of writing to inferior_ptid directly.
2544 (nto_procfs_target::create_inferior): Avoid inferior_ptid. Switch
2545 to thread.
2546
2547 2020-06-18 Pedro Alves <palves@redhat.com>
2548
2549 * remote-sim.c (gdbsim_target::create_inferior): Switch to thread
2550 after creating it, instead of writing to inferior_ptid.
2551 (gdbsim_target_open): Use switch_to_no_thread instead of writing
2552 to inferior_ptid directly.
2553 (gdbsim_target::wait): Don't write to inferior_ptid.
2554
2555 2020-06-18 Pedro Alves <palves@redhat.com>
2556
2557 * remote.c (remote_target::remote_notice_new_inferior): Use
2558 switch_to_thread instead of writing to inferior_ptid directly.
2559 (remote_target::add_current_inferior_and_thread): Use
2560 switch_to_no_thread instead of writing to inferior_ptid directly.
2561 (extended_remote_target::attach): Use switch_to_inferior_no_thread
2562 and switch_to_thread instead of using set_current_inferior or
2563 writing to inferior_ptid directly.
2564
2565 2020-06-18 Pedro Alves <palves@redhat.com>
2566
2567 * tracectf.c (ctf_target_open): Switch to added thread instead of
2568 writing to inferior_ptid directly.
2569 (ctf_target::close): Use switch_to_no_thread instead of writing to
2570 inferior_ptid directly.
2571
2572 2020-06-18 Pedro Alves <palves@redhat.com>
2573
2574 * tracefile-tfile.c (tfile_target_open): Don't write to
2575 inferior_ptid directly, instead switch to added thread.
2576 (tfile_target::close): Use switch_to_no_thread instead of writing
2577 to inferior_ptid directly.
2578
2579 2020-06-18 Pedro Alves <palves@redhat.com>
2580
2581 * procfs.c (procfs_target::attach): Don't write to inferior_ptid.
2582 (procfs_target::detach): Use switch_to_no_thread
2583 instead of writing to inferior_ptid directly.
2584 (do_attach): Change return type to void. Switch to the added
2585 thread.
2586 (procfs_target::create_inferior): Switch to the added thread.
2587 (procfs_do_thread_registers): Don't write to inferior_ptid.
2588
2589 2020-06-18 Pedro Alves <palves@redhat.com>
2590
2591 * infrun.c (generic_mourn_inferior): Use switch_to_thread instead
2592 of writing to inferior_ptid.
2593 (scoped_restore_exited_inferior): Delete.
2594 (handle_vfork_child_exec_or_exit): Simplify using
2595 scoped_restore_current_pspace_and_thread. Use switch_to_thread
2596 instead of writing to inferior_ptid.
2597 (THREAD_STOPPED_BY): Delete.
2598 (thread_stopped_by_watchpoint, thread_stopped_by_sw_breakpoint)
2599 (thread_stopped_by_hw_breakpoint): Delete.
2600 (save_waitstatus): Use
2601 scoped_restore_current_thread+switch_to_thread, and call
2602 target_stopped_by_watchpoint instead of
2603 thread_stopped_by_watchpoint, target_stopped_by_sw_breakpoint
2604 instead of thread_stopped_by_sw_breakpoint, and
2605 target_stopped_by_hw_breakpoint instead of
2606 thread_stopped_by_hw_breakpoint.
2607 (handle_inferior_event)
2608 <TARGET_WAITKIND_EXITED/TARGET_WAITKIND_SIGNALLED>: Don't write to
2609 inferior_ptid directly, nor
2610 set_current_inferior/set_current_program_space. Use
2611 switch_to_thread / switch_to_inferior_no_thread instead.
2612
2613 2020-06-18 Pedro Alves <palves@redhat.com>
2614
2615 * target.c (generic_mourn_inferior): Use switch_to_no_thread
2616 instead of writing to inferior_ptid.
2617
2618 2020-06-18 Pedro Alves <palves@redhat.com>
2619
2620 * inf-ptrace.c (inf_ptrace_target::create_inferior): Switch to the
2621 added thread.
2622 (inf_ptrace_target::attach): Don't write to inferior_ptid. Switch
2623 to the added thread.
2624 (inf_ptrace_target::detach_success): Use switch_to_no_thread
2625 instead of writing to inferior_ptid.
2626
2627 2020-06-18 Pedro Alves <palves@redhat.com>
2628
2629 * gdbarch-selftests.c: Include "progspace-and-thread.h".
2630 (register_to_value_test): Mock a program_space too. Heap-allocate
2631 the address space. Don't write to inferior_ptid. Use
2632 switch_to_thread instead.
2633
2634 2020-06-18 Pedro Alves <palves@redhat.com>
2635
2636 * linux-tdep.c (find_signalled_thread(thread_info *,void *)):
2637 Delete.
2638 (find_signalled_thread()): New, factored out from
2639 linux_make_corefile_notes and adjusted to handle exited threads.
2640 (linux_make_corefile_notes): Adjust to use the new
2641 find_signalled_thread.
2642
2643 2020-06-18 Pedro Alves <palves@redhat.com>
2644
2645 * linux-tdep.c (btrace_fetch): Save/restore current thread instead
2646 of saving/restoring inferior_ptid.
2647
2648 2020-06-17 Tom Tromey <tom@tromey.com>
2649
2650 * tui/tui-win.h (tui_scroll_forward, tui_scroll_backward)
2651 (tui_scroll_left, tui_scroll_right, struct tui_win_info): Don't
2652 declare.
2653 * tui/tui-data.h (MIN_CMD_WIN_HEIGHT): Remove.
2654
2655 2020-06-15 Simon Marchi <simon.marchi@efficios.com>
2656
2657 * dwarf2/read.c (dwarf2_initialize_objfile): Check for presence
2658 of partial symtabs.
2659
2660 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2661
2662 * regformats/reg-arm.dat: Remove.
2663 * regformats/reg-bfin.dat: Remove.
2664 * regformats/reg-cris.dat: Remove.
2665 * regformats/reg-crisv32.dat: Remove.
2666 * regformats/reg-m32r.dat: Remove.
2667 * regformats/reg-tilegx.dat: Remove.
2668 * regformats/reg-tilegx32.dat: Remove.
2669
2670 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2671
2672 * features/Makefile (WHICH): Remove arm files.
2673 * regformats/arm/arm-with-iwmmxt.dat: Remove.
2674 * regformats/arm/arm-with-neon.dat: Remove.
2675 * regformats/arm/arm-with-vfpv2.dat: Remove.
2676 * regformats/arm/arm-with-vfpv3.dat: Remove.
2677
2678 2020-06-17 Simon Marchi <simon.marchi@efficios.com>
2679
2680 * features/Makefile (XMLTOC): Remove rx.xml.
2681
2682 2020-06-17 Pedro Alves <palves@redhat.com>
2683
2684 * gdbthread.h (thread_control_state) <trap_expected> Update
2685 comments.
2686
2687 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2688
2689 * ada-lang.c (ada_lookup_symbol_nonlocal): Rename to
2690 ada_language::lookup_symbol_nonlocal.
2691 (ada_language_data): Delete la_lookup_symbol_nonlocal initializer.
2692 (ada_language::lookup_symbol_nonlocal): New member function,
2693 implementation from ada_lookup_symbol_nonlocal.
2694 * c-lang.c (c_language_data): Delete la_lookup_symbol_nonlocal
2695 initializer.
2696 (cplus_language_data): Delete la_lookup_symbol_nonlocal
2697 initializer.
2698 (cplus_language::lookup_symbol_nonlocal): New member function.
2699 (asm_language_data): Delete la_lookup_symbol_nonlocal initializer.
2700 (minimal_language_data) Likewise.
2701 * cp-namespace.c (cp_lookup_nested_symbol): Update comment.
2702 * d-lang.c (d_language_data): Delete la_lookup_symbol_nonlocal
2703 initializer.
2704 (d_language::lookup_symbol_nonlocal): New member function.
2705 * f-lang.c (f_language_data): Delete la_lookup_symbol_nonlocal
2706 initializer.
2707 (f_language::lookup_symbol_nonlocal): New member function.
2708 * go-lang.c (go_language_data): Delete la_lookup_symbol_nonlocal
2709 initializer.
2710 * language.c (unknown_language_data): Likewise.
2711 (auto_language_data): Likewise.
2712 * language.h (language_data): Delete la_lookup_symbol_nonlocal
2713 field.
2714 (language_defn::lookup_symbol_nonlocal): New member function.
2715 * m2-lang.c (m2_language_data): Delete la_lookup_symbol_nonlocal
2716 initializer.
2717 * objc-lang.c (objc_language_data): Likewise.
2718 * opencl-lang.c (opencl_language_data): Likewise.
2719 * p-lang.c (pascal_language_data): Likewise.
2720 * rust-lang.c (rust_lookup_symbol_nonlocal): Rename to
2721 rust_language::lookup_symbol_nonlocal.
2722 (rust_language_data): Delete la_lookup_symbol_nonlocal
2723 initializer.
2724 (rust_language::lookup_symbol_nonlocal): New member function,
2725 implementation from rust_lookup_symbol_nonlocal.
2726 * symtab.c (lookup_symbol_aux): Update call to
2727 lookup_symbol_nonlocal.
2728 (basic_lookup_symbol_nonlocal): Rename to...
2729 (language_defn::lookup_symbol_nonlocal): ...this, and update
2730 header comment. Remove language_defn parameter, and replace with
2731 uses of `this'.
2732 * symtab.h (basic_lookup_symbol_nonlocal): Delete declaration.
2733
2734 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2735
2736 * ada-lang.c (ada_language_data): Delete la_value_print_inner
2737 initializer.
2738 (ada_language::value_print_inner): New member function.
2739 * c-lang.c (c_language_data): Delete la_value_print_inner
2740 initializer.
2741 (cplus_language_data): Likewise.
2742 (asm_language_data): Likewise.
2743 (minimal_language_data): Likewise.
2744 * d-lang.c (d_language_data): Likewise.
2745 (d_language::value_print_inner): New member function.
2746 * f-lang.c (f_language_data): Delete la_value_print_inner
2747 initializer.
2748 (f_language::value_print_inner): New member function.
2749 * f-lang.h (f_value_print_innner): Rename to...
2750 (f_value_print_inner): ...this (note spelling of 'inner').
2751 * f-valprint.c (f_value_print_innner): Rename to...
2752 (f_value_print_inner): ...this (note spelling of 'inner').
2753 * go-lang.c (go_language_data): Delete la_value_print_inner
2754 initializer.
2755 (go_language::value_print_inner): New member function.
2756 * language.c (language_defn::value_print_inner): Define new member
2757 function.
2758 (unk_lang_value_print_inner): Delete.
2759 (unknown_language_data): Delete la_value_print_inner initializer.
2760 (unknown_language::value_print_inner): New member function.
2761 (auto_language_data): Delete la_value_print_inner initializer.
2762 (auto_language::value_print_inner): New member function.
2763 * language.h (language_data): Delete la_value_print_inner field.
2764 (language_defn::value_print_inner): Delcare new member function.
2765 * m2-lang.c (m2_language_data): Delete la_value_print_inner
2766 initializer.
2767 (m2_language::value_print_inner): New member function.
2768 * objc-lang.c (objc_language_data): Delete la_value_print_inner
2769 initializer.
2770 * opencl-lang.c (opencl_language_data): Likewise.
2771 * p-lang.c (pascal_language_data): Likewise.
2772 (pascal_language::value_print_inner): New member function.
2773 * rust-lang.c (rust_language_data): Delete la_value_print_inner
2774 initializer.
2775 (rust_language::value_print_inner): New member function.
2776 * valprint.c (do_val_print): Update call to value_print_inner.
2777
2778 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2779
2780 * ada-lang.c (ada_language_data): Delete la_value_print
2781 initializer.
2782 (ada_language::value_print): New member function.
2783 * c-lang.c (c_language_data): Delete la_value_print initializer.
2784 (cplus_language_data): Likewise.
2785 (asm_language_data): Likewise.
2786 (minimal_language_data): Likewise.
2787 * d-lang.c (d_language_data): Likewise.
2788 * f-lang.c (f_language_data): Likewise.
2789 * go-lang.c (go_language_data): Likewise.
2790 * language.c (unk_lang_value_print): Delete.
2791 (language_defn::value_print): Define new member function.
2792 (unknown_language_data): Delete la_value_print initializer.
2793 (unknown_language::value_print): New member function.
2794 (auto_language_data): Delete la_value_print initializer.
2795 (auto_language::value_print): New member function.
2796 * language.h (language_data): Delete la_value_print field.
2797 (language_defn::value_print): Declare new member function.
2798 (LA_VALUE_PRINT): Update call to value_print.
2799 * m2-lang.c (m2_language_data): Delete la_value_print initializer.
2800 * objc-lang.c (objc_language_data): Likewise.
2801 * opencl-lang.c (opencl_language_data): Likewise.
2802 * p-lang.c (pascal_language_data): Likewise.
2803 (pascal_language::value_print): New member function.
2804 * rust-lang.c (rust_language_data): Delete la_value_print
2805 initializer.
2806
2807 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2808
2809 * ada-lang.c (ada_watch_location_expression): Rename to
2810 ada_language::watch_location_expression.
2811 (ada_language_data): Delete la_watch_location_expression
2812 initializer.
2813 (ada_language::watch_location_expression): New member function,
2814 implementation from ada_watch_location_expression.
2815 * breakpoint.c (watch_command_1): Update call to
2816 watch_location_expression.
2817 * c-lang.c (c_watch_location_expression): Rename to
2818 language_defn::watch_location_expression.
2819 (c_language_data): Delete la_watch_location_expression
2820 initializer.
2821 (cplus_language_data): Likewise.
2822 (asm_language_data): Likewise.
2823 (minimal_language_data): Likewise.
2824 * c-lang.h (c_watch_location_expression): Delete declaration.
2825 * d-lang.c (d_language_data): Delete la_watch_location_expression
2826 initializer.
2827 * f-lang.c (f_language_data): Likewise.
2828 * go-lang.c (go_language_data): Likewise.
2829 * language.c (language_defn::watch_location_expression): Member
2830 function implementation from c_watch_location_expression.
2831 (unknown_language_data): Delete la_watch_location_expression
2832 initializer.
2833 (auto_language_data): Likewise.
2834 * language.h (language_data): Delete la_watch_location_expression
2835 field.
2836 (language_defn::watch_location_expression): Declare new member
2837 function.
2838 * m2-lang.c (m2_language_data): Delete
2839 la_watch_location_expression initializer.
2840 * objc-lang.c (objc_language_data): Likewise.
2841 * opencl-lang.c (opencl_language_data): Likewise.
2842 * p-lang.c (pascal_language_data): Likewise.
2843 * rust-lang.c (rust_watch_location_expression): Rename to
2844 rust_language::watch_location_expression.
2845 (rust_language_data): Delete la_watch_location_expression
2846 initializer.
2847 (rust_language::watch_location_expression): New member function,
2848 implementation from rust_watch_location_expression.
2849
2850 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2851
2852 * ada-lang.c (ada_collect_symbol_completion_matches): Rename to
2853 ada_language::collect_symbol_completion_matches.
2854 (ada_language_data): Delete la_collect_symbol_completion_matches
2855 initializer.
2856 (ada_language::collect_symbol_completion_matches): New member
2857 function, implementation from
2858 ada_collect_symbol_completion_matches.
2859 * c-lang.c (c_language_data): Delete
2860 la_collect_symbol_completion_matches initializer.
2861 (cplus_language_data): Likewise.
2862 (asm_language_data): Likewise.
2863 (minimal_language_data): Likewise.
2864 * d-lang.c (d_language_data): Likewise.
2865 * f-lang.c (f_collect_symbol_completion_matches): Rename to
2866 f_language::collect_symbol_completion_matches.
2867 (f_language_data): Delete la_collect_symbol_completion_matches
2868 initializer.
2869 (f_language::collect_symbol_completion_matches) New member
2870 function, implementation from f_collect_symbol_completion_matches.
2871 * go-lang.c (go_language_data): Delete
2872 la_collect_symbol_completion_matches initializer.
2873 * language.c (unknown_language_data): Likewise.
2874 (auto_language_data): Likewise.
2875 * language.h (language_data): Delete
2876 la_collect_symbol_completion_matches field.
2877 (language_defn::collect_symbol_completion_matches): New member
2878 function.
2879 * m2-lang.c (m2_language_data): Delete
2880 la_collect_symbol_completion_matches initializer.
2881 * objc-lang.c (objc_language_data): Likewise.
2882 * opencl-lang.c (opencl_language_data): Likewise.
2883 * p-lang.c (pascal_language_data): Likewise.
2884 * rust-lang.c (rust_language_data): Likewise.
2885 * symtab.c (default_collect_symbol_completion_matches): Delete.
2886 (collect_symbol_completion_matches): Update call to
2887 collect_symbol_completion_matches.
2888 (collect_symbol_completion_matches_type): Likewise.
2889 * symtab.h (default_collect_symbol_completion_matches): Delete
2890 declaration.
2891
2892 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2893
2894 * ada-lang.c (ada_get_gdb_completer_word_break_characters): Delete.
2895 (ada_language_data): Delete la_word_break_characters initializer.
2896 (ada_language::word_break_characters): New member function.
2897 * c-lang.c (c_language_data): Delete la_word_break_characters
2898 initializer.
2899 (cplus_language_data): Likewise.
2900 (asm_language_data): Likewise.
2901 (minimal_language_data): Likewise.
2902 * completer.c: Update global comment.
2903 (advance_to_expression_complete_word_point): Update call to
2904 word_break_characters.
2905 (complete_files_symbols): Likewise.
2906 (complete_line_internal_1): Likewise.
2907 (default_completer_handle_brkchars): Likewise.
2908 (skip_quoted_chars): Likewise.
2909 * d-lang.c (d_language_data): Delete la_word_break_characters
2910 initializer.
2911 * f-lang.c (f_word_break_characters): Delete.
2912 (f_language_data): Delete la_word_break_characters initializer.
2913 (f_language::word_break_characters): New member function.
2914 * go-lang.c (go_language_data): Delete la_word_break_characters
2915 initializer.
2916 * language.c (unknown_language_data): Likewise.
2917 (auto_language_data): Likewise.
2918 * language.h (default_word_break_characters): Move declaration to
2919 earlier in the file.
2920 (language_data): Delete la_word_break_characters field.
2921 (language_defn::word_break_characters): New member function.
2922 * m2-lang.c (m2_language_data): Delete la_word_break_characters
2923 initializer.
2924 * objc-lang.c (objc_language_data): Likewise.
2925 * opencl-lang.c (opencl_language_data): Likewise.
2926 * p-lang.c (pascal_language_data): Likewise.
2927 * rust-lang.c (rust_language_data): Likewise.
2928
2929 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2930
2931 * ada-lang.c (ada_get_symbol_name_matcher): Update header comment.
2932 (ada_language_data): Delete la_get_symbol_name_matcher
2933 initializer.
2934 (language_defn::get_symbol_name_matcher_inner): New member
2935 function.
2936 * c-lang.c (c_language_data): Delete la_get_symbol_name_matcher
2937 initializer.
2938 (cplus_language_data): Likewise.
2939 (cplus_language::get_symbol_name_matcher_inner): New member
2940 function.
2941 (asm_language_data): Delete la_get_symbol_name_matcher initializer.
2942 (minimal_language_data): Likewise.
2943 * cp-support.h (cp_get_symbol_name_matcher): Update header comment.
2944 * d-lang.c (d_language_data): Delete la_get_symbol_name_matcher
2945 initializer.
2946 * dictionary.c (iter_match_first_hashed): Update call to
2947 get_symbol_name_matcher.
2948 (iter_match_next_hashed): Likewise.
2949 (iter_match_next_linear): Likewise.
2950 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Likewise.
2951 * f-lang.c (f_language_data): Delete la_get_symbol_name_matcher
2952 initializer.
2953 (f_language::get_symbol_name_matcher_inner): New member function.
2954 * go-lang.c (go_language_data): Delete la_get_symbol_name_matcher
2955 initializer.
2956 * language.c (default_symbol_name_matcher): Update header comment,
2957 make static.
2958 (language_defn::get_symbol_name_matcher): New definition.
2959 (language_defn::get_symbol_name_matcher_inner): Likewise.
2960 (get_symbol_name_matcher): Delete.
2961 (unknown_language_data): Delete la_get_symbol_name_matcher
2962 initializer.
2963 (auto_language_data): Likewise.
2964 * language.h (language_data): Delete la_get_symbol_name_matcher
2965 field.
2966 (language_defn::get_symbol_name_matcher): New member function.
2967 (language_defn::get_symbol_name_matcher_inner): Likewise.
2968 (default_symbol_name_matcher): Delete declaration.
2969 * linespec.c (find_methods): Update call to
2970 get_symbol_name_matcher.
2971 * m2-lang.c (m2_language_data): Delete la_get_symbol_name_matcher
2972 initializer.
2973 * minsyms.c (lookup_minimal_symbol): Update call to
2974 get_symbol_name_matcher.
2975 (iterate_over_minimal_symbols): Likewise.
2976 * objc-lang.c (objc_language_data): Delete
2977 la_get_symbol_name_matcher initializer.
2978 * opencl-lang.c (opencl_language_data): Likewise.
2979 * p-lang.c (pascal_language_data): Likewise.
2980 * psymtab.c (psymbol_name_matches): Update call to
2981 get_symbol_name_matcher.
2982 * rust-lang.c (rust_language_data): Delete
2983 la_get_symbol_name_matcher initializer.
2984 * symtab.c (symbol_matches_search_name): Update call to
2985 get_symbol_name_matcher.
2986 (compare_symbol_name): Likewise.
2987
2988 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
2989
2990 * ada-lang.c (ada_language_data): Delete la_compute_program
2991 initializer.
2992 * c-lang.c (c_language_data): Likewise.
2993 (c_language::compute_program): New member function.
2994 (cplus_language_data): Delete la_compute_program initializer.
2995 (cplus_language::compute_program): New member function.
2996 (asm_language_data): Delete la_compute_program initializer.
2997 (minimal_language_data): Likewise.
2998 * c-lang.h (c_compute_program): Update comment.
2999 (cplus_compute_program): Likewise.
3000 * compile/compile-c-support.c (c_compute_program): Likewise.
3001 (cplus_compute_program): Likewise.
3002 * compile/compile.c (compile_to_object): Update call to
3003 la_compute_program.
3004 * d-lang.c (d_language_data): Delete la_compute_program
3005 initializer.
3006 * f-lang.c (f_language_data): Likewise.
3007 * go-lang.c (go_language_data): Likewise.
3008 * language.c (unknown_language_data): Likewise.
3009 (auto_language_data): Likewise.
3010 * language.h (language_data): Delete la_compute_program field.
3011 (language_defn::compute_program): New member function.
3012 * m2-lang.c (m2_language_data): Delete la_compute_program
3013 initializer.
3014 * objc-lang.c (objc_language_data): Likewise.
3015 * opencl-lang.c (opencl_language_data): Likewise.
3016 * p-lang.c (pascal_language_data): Likewise.
3017 * rust-lang.c (rust_language_data): Likewise.
3018
3019 2020-06-17 Andrew Burgess <andrew.burgess@embecosm.com>
3020
3021 * ada-lang.c (ada_language_data) Delete
3022 la_class_name_from_physname initializer.
3023 * c-lang.c (c_language_data): Likewise.
3024 (cplus_language_data): Likewise.
3025 (cplus_language::class_name_from_physname): New member function.
3026 (asm_language_data): Delete la_class_name_from_physname
3027 initializer.
3028 (minimal_language_data): Likewise.
3029 * d-lang.c (d_language_data): Likewise.
3030 * dwarf2/read.c (guess_partial_die_structure_name): Update to call
3031 method on language_defn class.
3032 (guess_full_die_structure_name): Likewise.
3033 * f-lang.c (f_language_data): Delete la_class_name_from_physname
3034 initializer.
3035 * go-lang.c (go_language_data): Likewise.
3036 * language.c (language_class_name_from_physname): Delete.
3037 (unk_lang_class_name): Delete.
3038 (unknown_language_data): Delete la_class_name_from_physname
3039 initializer.
3040 (auto_language_data): Likewise.
3041 * language.h (language_data): Delete la_class_name_from_physname
3042 field.
3043 (language_defn::class_name_from_physname): New function.
3044 (language_class_name_from_physname): Delete declaration.
3045 * m2-lang.c (m2_language_data): Delete la_class_name_from_physname
3046 initializer.
3047 * objc-lang.c (objc_language_data): Likewise.
3048 * opencl-lang.c (opencl_language_data): Likewise.
3049 * p-lang.c (pascal_language_data): Likewise.
3050 * rust-lang.c (rust_language_data): Likewise.
3051
3052 2020-06-16 Tom Tromey <tom@tromey.com>
3053
3054 * tui/tui-data.h (STATUS_NAME): New macro.
3055 * tui/tui-layout.c (tui_remove_some_windows)
3056 (initialize_known_windows, tui_register_window)
3057 (tui_layout_split::remove_windows, initialize_layouts)
3058 (tui_new_layout_command): Don't use hard-coded window names.
3059
3060 2020-06-16 Tom Tromey <tom@tromey.com>
3061
3062 PR tui/25348:
3063 * tui/tui.c (tui_ensure_readline_initialized): Rename from
3064 tui_initialize_readline. Only run once. Call rl_initialize.
3065 * tui/tui.h (tui_ensure_readline_initialized): Rename from
3066 tui_initialize_readline.
3067 * tui/tui-io.c (tui_setup_io): Call
3068 tui_ensure_readline_initialized.
3069 * tui/tui-interp.c (tui_interp::init): Update.
3070
3071 2020-06-16 Tom Tromey <tom@tromey.com>
3072
3073 * tui/tui-layout.c (tui_layout_split::remove_windows): Fix logic.
3074 Also preserve the status window.
3075
3076 2020-06-16 Tom Tromey <tom@tromey.com>
3077
3078 * python/py-tui.c (tui_py_window::~tui_py_window): Handle case
3079 where m_window==nullptr.
3080
3081 2020-06-15 Tom Tromey <tromey@adacore.com>
3082
3083 * windows-nat.c (windows_nat::handle_output_debug_string):
3084 Update.
3085 (windows_nat::handle_ms_vc_exception): Update.
3086 * target.h (target_read_string): Change API.
3087 * target.c (target_read_string): Change API.
3088 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
3089 Update.
3090 * solib-frv.c (frv_current_sos): Update.
3091 * solib-dsbt.c (dsbt_current_sos): Update.
3092 * solib-darwin.c (darwin_current_sos): Update.
3093 * linux-thread-db.c (inferior_has_bug): Update.
3094 * expprint.c (print_subexp_standard): Update.
3095 * ada-lang.c (ada_main_name, ada_tag_name_from_tsd)
3096 (ada_exception_message_1): Update.
3097
3098 2020-06-15 Tom Tromey <tromey@adacore.com>
3099
3100 * linux-tdep.c (dump_mapping_p): Use target_read_memory.
3101
3102 2020-06-15 Tom Tromey <tromey@adacore.com>
3103
3104 * valprint.c (read_string): Update comment.
3105 * target.c (MIN): Remove.
3106 (target_read_string): Rewrite.
3107
3108 2020-06-15 Tom Tromey <tromey@adacore.com>
3109
3110 * corefile.c (read_memory_string): Remove.
3111 * ada-valprint.c (ada_value_print_ptr): Update.
3112 * ada-lang.h (ada_tag_name): Change return type.
3113 * ada-lang.c (type_from_tag): Update.
3114 (ada_tag_name_from_tsd): Change return type. Use
3115 target_read_string.
3116 (ada_tag_name): Likewise.
3117 * gdbcore.h (read_memory_string): Don't declare.
3118
3119 2020-06-14 Hannes Domani <ssbssa@yahoo.de>
3120
3121 * symtab.c (rbreak_command): Ignore Windows drive colon.
3122
3123 2020-06-12 Simon Marchi <simon.marchi@efficios.com>
3124
3125 * NEWS: Mention removed GDBserver host support.
3126
3127 2020-06-12 Nelson Chu <nelson.chu@sifive.com>
3128
3129 * features/riscv/rebuild-csr-xml.sh: Updated.
3130
3131 2020-06-11 Tom Tromey <tom@tromey.com>
3132
3133 PR gdb/18318:
3134 * c-exp.y (lex_one_token): Handle 'p' like 'e'.
3135
3136 2020-06-09 Jonny Grant <jg@jguk.org>
3137 2020-06-09 Simon Marchi <simon.marchi@polymtl.ca>
3138
3139 * main.c (captured_main_1): Don't print new line after help.
3140 (print_gdb_help): add mailing list and IRC channel information
3141 to --help. Add new lines between items in the footer. Remove
3142 quotes around bug url.
3143
3144 2020-06-11 Keith Seitz <keiths@redhat.com>
3145
3146 PR gdb/21356
3147 * gdbtypes.c (resolve_dynamic_union, resolve_dynamic_struct):
3148 Resolve typedefs for type length calculations.
3149
3150 2020-06-10 Tom de Vries <tdevries@suse.de>
3151
3152 PR ada/24713
3153 * dwarf2/index-write.c (struct mapped_symtab): Add m_string_obstack.
3154 (write_psymbols): Enable .gdb_index for ada.
3155 * dwarf2/read.c: Remove comment stating .gdb_index is unsupported for
3156 ada.
3157
3158 2020-06-10 Tom de Vries <tdevries@suse.de>
3159
3160 * dwarf2/read.c (dw2_symtab_iter_init_common): Factor out of ...
3161 (dw2_symtab_iter_init): ... here. Add variant with "offset_type
3162 namei" instead of "const char *name" argument.
3163 (dw2_map_matching_symbols): Use "offset_type namei" variant of
3164 dw2_symtab_iter_init.
3165
3166 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3167
3168 * gdbtypes.h (TYPE_FIELD_TYPE): Remove. Change all call sites
3169 to use type::field and field::type instead.
3170
3171 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3172
3173 * gdbtypes.h (FIELD_TYPE): Remove. Change all call sites
3174 to use field::type instead.
3175
3176 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3177
3178 * gdbtypes.h (struct field) <type, set_type>: New methods.
3179 Rename `type` field to...
3180 <m_type>: ... this. Change references throughout to use type or
3181 set_type methods.
3182 (FIELD_TYPE): Use field::type. Change call sites that modify
3183 the field's type to use field::set_type instead.
3184
3185 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3186
3187 * gdbtypes.h (TYPE_INDEX_TYPE): Remove. Change all call sites
3188 to use type::index_type instead.
3189
3190 2020-06-08 Simon Marchi <simon.marchi@efficios.com>
3191
3192 * gdbtypes.h (struct type) <index_type, set_index_type>: New
3193 methods.
3194 (TYPE_INDEX_TYPE): Use type::index_type.
3195 * gdbtypes.c (create_array_type_with_stride): Likewise.
3196
3197 2020-06-07 Tom Tromey <tom@tromey.com>
3198
3199 * valprint.c (generic_val_print_float): Remove "embedded_offset"
3200 parameter.
3201 (generic_value_print): Update.
3202
3203 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
3204
3205 Revert commit 982a38f60b0.
3206 * python/py-tui.c (gdbpy_tui_set_title): Restore use of get.
3207
3208 2020-06-05 Andrew Burgess <andrew.burgess@embecosm.com>
3209
3210 * python/py-tui.c (gdbpy_tui_set_title): Use release, not get, to
3211 avoid use after free.
3212
3213 2020-06-05 Tom de Vries <tdevries@suse.de>
3214
3215 * NEWS: Fix typos.
3216
3217 2020-06-04 Simon Marchi <simon.marchi@efficios.com>
3218
3219 * dwarf2/read.c (dwarf2_read_gdb_index): Save partial_symtabs in
3220 the per_bfd object.
3221 (dwarf2_read_debug_names): Likewise.
3222 (dwarf2_initialize_objfile): Use partial_symtabs from per_bfd
3223 object when re-using a per_bfd object with an index.
3224
3225 2020-06-03 Tom de Vries <tdevries@suse.de>
3226
3227 PR symtab/26046
3228 * dwarf2/read.c (scan_partial_symbols): Recurse into DW_TAG_subprogram
3229 children for C++.
3230 (load_partial_dies): Don't skip DW_TAG_inlined_subroutine child of
3231 DW_TAG_subprogram.
3232
3233 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3234
3235 * ada-lang.c (ada_language_data): Delete skip_trampoline
3236 initializer.
3237 * c-lang.c (c_language_data): Likewise.
3238 (cplus_language_data): Likewise.
3239 (cplus_language::skip_trampoline): New member function.
3240 (asm_language_data): Delete skip_trampoline initializer.
3241 (minimal_language_data): Likewise.
3242 * d-lang.c (d_language_data): Likewise.
3243 * f-lang.c (f_language_data): Likewise.
3244 * go-lang.c (go_language_data): Likewise.
3245 * language.c (unk_lang_trampoline): Delete function.
3246 (skip_language_trampoline): Update.
3247 (unknown_language_data): Delete skip_trampoline initializer.
3248 (auto_language_data): Likewise.
3249 * language.h (language_data): Delete skip_trampoline field.
3250 (language_defn::skip_trampoline): New function.
3251 * m2-lang.c (m2_language_data): Delete skip_trampoline
3252 initializer.
3253 * objc-lang.c (objc_skip_trampoline): Delete function, move
3254 implementation to objc_language::skip_trampoline.
3255 (objc_language_data): Delete skip_trampoline initializer.
3256 (objc_language::skip_trampoline): New member function with
3257 implementation from objc_skip_trampoline.
3258 * opencl-lang.c (opencl_language_data): Delete skip_trampoline
3259 initializer.
3260 * p-lang.c (pascal_language_data): Likewise.
3261 * rust-lang.c (rust_language_data): Likewise.
3262
3263 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3264
3265 * ada-lang.c (ada_language_data): Delete la_demangle initializer.
3266 (ada_language::demangle): New member function.
3267 * c-lang.c (c_language_data): Delete la_demangle initializer.
3268 (cplus_language_data): Delete la_demangle initializer.
3269 (cplus_language::demangle): New member function.
3270 (asm_language_data): Delete la_demangle initializer.
3271 (minimal_language_data): Delete la_demangle initializer.
3272 * d-lang.c (d_language_data): Delete la_demangle initializer.
3273 (d_language::demangle): New member function.
3274 * f-lang.c (f_language_data): Delete la_demangle initializer.
3275 (f_language::demangle): New member function.
3276 * go-lang.c (go_language_data): Delete la_demangle initializer.
3277 (go_language::demangle): New member function.
3278 * language.c (language_demangle): Update.
3279 (unk_lang_demangle): Delete.
3280 (unknown_language_data): Delete la_demangle initializer.
3281 (unknown_language::demangle): New member function.
3282 (auto_language_data): Delete la_demangle initializer.
3283 (auto_language::demangle): New member function.
3284 * language.h (language_data): Delete la_demangle field.
3285 (language_defn::demangle): New function.
3286 * m2-lang.c (m2_language_data): Delete la_demangle initializer.
3287 * objc-lang.c (objc_language_data): Delete la_demangle
3288 initializer.
3289 (objc_language::demangle): New member function.
3290 * opencl-lang.c (opencl_language_data): Delete la_demangle
3291 initializer.
3292 * p-lang.c (pascal_language_data): Likewise.
3293 * rust-lang.c (rust_language_data): Likewise.
3294 (rust_language::demangle): New member function.
3295
3296 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3297
3298 * ada-lang.c (ada_language_data): Delete la_print_type
3299 initializer.
3300 (ada_language::print_type): New member function.
3301 * c-lang.c (c_language_data): Delete la_print_type initializer.
3302 (c_language::print_type): New member function.
3303 (cplus_language_data): Delete la_print_type initializer.
3304 (cplus_language::print_type): New member function.
3305 (asm_language_data): Delete la_print_type initializer.
3306 (asm_language::print_type): New member function.
3307 (minimal_language_data): Delete la_print_type initializer.
3308 (minimal_language::print_type): New member function.
3309 * d-lang.c (d_language_data): Delete la_print_type initializer.
3310 (d_language::print_type): New member function.
3311 * f-lang.c (f_language_data): Delete la_print_type initializer.
3312 (f_language::print_type): New member function.
3313 * go-lang.c (go_language_data): Delete la_print_type initializer.
3314 (go_language::print_type): New member function.
3315 * language.c (unk_lang_print_type): Delete.
3316 (unknown_language_data): Delete la_print_type initializer.
3317 (unknown_language::print_type): New member function.
3318 (auto_language_data): Delete la_print_type initializer.
3319 (auto_language::print_type): New member function.
3320 * language.h (language_data): Delete la_print_type field.
3321 (language_defn::print_type): New function.
3322 (LA_PRINT_TYPE): Update.
3323 * m2-lang.c (m2_language_data): Delete la_print_type initializer.
3324 (m2_language::print_type): New member function.
3325 * objc-lang.c (objc_language_data): Delete la_print_type
3326 initializer.
3327 (objc_language::print_type): New member function.
3328 * opencl-lang.c (opencl_print_type): Delete, implementation moved
3329 to opencl_language::print_type.
3330 (opencl_language_data): Delete la_print_type initializer.
3331 (opencl_language::print_type): New member function, implementation
3332 from opencl_print_type.
3333 * p-lang.c (pascal_language_data): Delete la_print_type
3334 initializer.
3335 (pascal_language::print_type): New member function.
3336 * rust-lang.c (rust_print_type): Delete, implementation moved to
3337 rust_language::print_type.
3338 (rust_language_data): Delete la_print_type initializer.
3339 (rust_language::print_type): New member function, implementation
3340 from rust_print_type.
3341
3342 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3343
3344 * ada-lang.c (ada_sniff_from_mangled_name): Delete function,
3345 implementation moves to...
3346 (ada_language::sniff_from_mangled_name): ...here. Update return
3347 type.
3348 (ada_language_data): Delete la_sniff_from_mangled_name
3349 initializer.
3350 * c-lang.c (c_language_data): Likewise.
3351 (cplus_language_data): Likewise.
3352 (cplus_language::sniff_from_mangled_name): New member function,
3353 implementation taken from gdb_sniff_from_mangled_name.
3354 (asm_language_data): Delete la_sniff_from_mangled_name
3355 initializer.
3356 (minimal_language_data): Likewise.
3357 * cp-support.c (gdb_sniff_from_mangled_name): Delete,
3358 implementation moves to cplus_language::sniff_from_mangled_name.
3359 * cp-support.h (gdb_sniff_from_mangled_name): Delete declaration.
3360 * d-lang.c (d_sniff_from_mangled_name): Delete, implementation
3361 moves to...
3362 (d_language::sniff_from_mangled_name): ...here.
3363 (d_language_data): Delete la_sniff_from_mangled_name initializer.
3364 * f-lang.c (f_language_data): Likewise.
3365 * go-lang.c (go_sniff_from_mangled_name): Delete, implementation
3366 moves to...
3367 (go_language::sniff_from_mangled_name): ...here.
3368 (go_language_data): Delete la_sniff_from_mangled_name initializer.
3369 * language.c (language_sniff_from_mangled_name): Delete.
3370 (unknown_language_data): Delete la_sniff_from_mangled_name
3371 initializer.
3372 (auto_language_data): Likewise.
3373 * language.h (language_data): Delete la_sniff_from_mangled_name
3374 field.
3375 (language_defn::sniff_from_mangled_name): New function.
3376 (language_sniff_from_mangled_name): Delete declaration.
3377 * m2-lang.c (m2_language_data): Delete la_sniff_from_mangled_name
3378 field.
3379 * objc-lang.c (objc_sniff_from_mangled_name): Delete,
3380 implementation moves to...
3381 (objc_language::sniff_from_mangled_name): ...here.
3382 (objc_language_data): Delete la_sniff_from_mangled_name initializer.
3383 * opencl-lang.c (opencl_language_data): Likewise.
3384 * p-lang.c (pascal_language_data): Likewise.
3385 * rust-lang.c (rust_sniff_from_mangled_name): Delete,
3386 implementation moves to...
3387 (rust_language::sniff_from_mangled_name): ...here.
3388 (rust_language_data): Delete la_sniff_from_mangled_name
3389 initializer.
3390 * symtab.c (symbol_find_demangled_name): Call
3391 sniff_from_mangled_name member function.
3392
3393 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3394
3395 * ada-lang.c (ada_language_data): Delete la_search_name_hash
3396 initializer.
3397 * c-lang.c (c_language_data): Likewise.
3398 (cplus_language_data): Likewise.
3399 (cplus_language::search_name_hash): New member function.
3400 (asm_language_data): Delete la_search_name_hash initializer.
3401 (minimal_language_data): Likewise.
3402 * d-lang.c (d_language_data): Likewise.
3403 * dictionary.c (default_search_name_hash): Rename to...
3404 (language_defn::search_name_hash): ...this.
3405 * f-lang.c (f_language_data): Likewise.
3406 (f_language::search_name_hash): New member function.
3407 * go-lang.c (go_language_data): Delete la_search_name_hash
3408 initializer.
3409 * language.c (unknown_language_data): Likewise.
3410 (auto_language_data): Likewise.
3411 * language.h (struct language_data): Delete la_search_name_hash
3412 field.
3413 (language_defn::search_name_hash): Declare new member function.
3414 (default_search_name_hash): Delete declaration.
3415 * m2-lang.c (m2_language_data): Delete la_search_name_hash
3416 initializer.
3417 * objc-lang.c (objc_language_data): Likewise.
3418 * opencl-lang.c (opencl_language_data): Likewise.
3419 * p-lang.c (pascal_language_data): Likewise.
3420 * rust-lang.c (rust_language_data): Likewise.
3421 * symtab.c (search_name_hash): Update call.
3422
3423 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3424
3425 * ada-lang.c (ada_language_data): Delete la_get_compile_instance
3426 initializer.
3427 * c-lang.c (class compile_instance): Declare.
3428 (c_language_data): Delete la_get_compile_instance initializer.
3429 (c_language::get_compile_instance): New member function.
3430 (cplus_language_data): Delete la_get_compile_instance initializer.
3431 (cplus_language::get_compile_instance): New member function.
3432 (asm_language_data): Delete la_get_compile_instance initializer.
3433 (minimal_language_data): Likewise.
3434 * c-lang.h (c_get_compile_context): Update comment.
3435 (cplus_get_compile_context): Update comment.
3436 * compile/compile.c (compile_to_object): Update calls, don't rely
3437 on function pointer being NULL.
3438 * d-lang.c (d_language_data): Delete la_get_compile_instance
3439 initializer.
3440 * f-lang.c (f_language_data): Likewise.
3441 * go-lang.c (go_language_data): Likewise.
3442 * language.c (unknown_language_data): Likewise.
3443 (auto_language_data): Likewise.
3444 * language.h (language_data): Delete la_get_compile_instance field.
3445 (language_defn::get_compile_instance): New member function.
3446 * m2-lang.c (m2_language_data): Delete la_get_compile_instance
3447 initializer.
3448 * objc-lang.c (objc_language_data): Likewise.
3449 * opencl-lang.c (opencl_language_data): Likewise.
3450 * p-lang.c (pascal_language_data): Likewise.
3451 * rust-lang.c (rust_language_data): Likewise.
3452
3453 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3454
3455 * ada-lang.c (ada_add_all_symbols): Update comment.
3456 (ada_iterate_over_symbols): Delete, move implementation to...
3457 (ada_language::iterate_over_symbols): ...here, a new member
3458 function, rewrite to use range based for loop.
3459 (ada_language_data): Delete la_iterate_over_symbols initializer.
3460 * c-lang.c (c_language_data): Likewise.
3461 (cplus_language_data): Likewise.
3462 (asm_language_data): Likewise.
3463 (minimal_language_data): Likewise.
3464 * d-lang.c (d_language_data): Likewise.
3465 * f-lang.c (f_language_data): Likewise.
3466 * go-lang.c (go_language_data): Likewise.
3467 * language.c (unknown_language_data): Likewise.
3468 (auto_language_data): Likewise.
3469 * language.h (language_data): Delete la_iterate_over_symbols field.
3470 (language_defn::iterate_over_symbols): New member function.
3471 (LA_ITERATE_OVER_SYMBOLS): Update.
3472 * linespec.c (iterate_over_all_matching_symtabs): Update.
3473 * m2-lang.c (m2_language_data): Delete la_iterate_over_symbols
3474 initializer.
3475 * objc-lang.c (objc_language_data): Likewise.
3476 * opencl-lang.c (opencl_language_data): Likewise.
3477 * p-lang.c (pascal_language_data): Likewise.
3478 * rust-lang.c (rust_language_data): Likewise.
3479
3480 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3481
3482 * ada-lang.c (ada_language_data): Delete
3483 la_lookup_transparent_type initializer.
3484 * c-lang.c (c_language_data): Likewise.
3485 (cplus_language_data): Likewise.
3486 (cplus_language::lookup_transparent_type): New member function.
3487 (asm_language_data): Delete la_lookup_transparent_type
3488 initializer.
3489 (minimal_language_data): Likewise.
3490 * d-lang.c (d_language_data): Likewise.
3491 * f-lang.c (f_language_data): Likewise.
3492 * go-lang.c (go_language_data): Likewise.
3493 * language.c (unknown_language_data): Likewise.
3494 (auto_language_data): Likewise.
3495 * language.h (struct language_data): Delete
3496 la_lookup_transparent_type field.
3497 (language_defn::lookup_transparent_type): New member function.
3498 * m2-lang.c (m2_language_data): Delete la_lookup_transparent_type
3499 initializer.
3500 * objc-lang.c (objc_language_data): Likewise.
3501 * opencl-lang.c (opencl_language_data): Likewise.
3502 * p-lang.c (pascal_language_data): Likewise.
3503 * rust-lang.c (rust_language_data): Likewise.
3504 * symtab.c (symbol_matches_domain): Update call.
3505
3506 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3507
3508 * ada-lang.c (ada_language_arch_info): Delete function, move
3509 implementation to...
3510 (ada_language::language_arch_info): ...here, a new member
3511 function.
3512 (ada_language_data): Delete la_language_arch_info.
3513 * c-lang.c (c_language_data): Likewise.
3514 (c_language::language_arch_info): New member function.
3515 (cplus_language_arch_info): Delete function, move
3516 implementation to...
3517 (cplus_language::language_arch_info): ...here, a new member
3518 function.
3519 (cplus_language_data): Delete la_language_arch_info.
3520 (asm_language_data): Likewise.
3521 (asm_language::language_arch_info): New member function.
3522 (minimal_language_data): Delete la_language_arch_info.
3523 (minimal_language::language_arch_info): New member function.
3524 * d-lang.c (d_language_arch_info): Delete function, move
3525 implementation to...
3526 (d_language::language_arch_info): ...here, a new member
3527 function.
3528 (d_language_data): Delete la_language_arch_info.
3529 * f-lang.c (f_language_arch_info): Delete function, move
3530 implementation to...
3531 (f_language::language_arch_info): ...here, a new member
3532 function.
3533 (f_language_data): Delete la_language_arch_info.
3534 * go-lang.c (go_language_arch_info): Delete function, move
3535 implementation to...
3536 (go_language::language_arch_info): ...here, a new member
3537 function.
3538 (go_language_data): Delete la_language_arch_info.
3539 * language.c (unknown_language_data): Likewise.
3540 (unknown_language::language_arch_info): New member function.
3541 (auto_language_data): Delete la_language_arch_info.
3542 (auto_language::language_arch_info): New member function.
3543 (language_gdbarch_post_init): Update call to
3544 la_language_arch_info.
3545 * language.h (language_data): Delete la_language_arch_info
3546 function pointer.
3547 (language_defn::language_arch_info): New function.
3548 * m2-lang.c (m2_language_arch_info): Delete function, move
3549 implementation to...
3550 (m2_language::language_arch_info): ...here, a new member
3551 function.
3552 (m2_language_data): Delete la_language_arch_info.
3553 * objc-lang.c (objc_language_arch_info): Delete function, move
3554 implementation to...
3555 (objc_language::language_arch_info): ...here, a new member
3556 function.
3557 (objc_language_data): Delete la_language_arch_info.
3558 * opencl-lang.c (opencl_language_arch_info): Delete function, move
3559 implementation to...
3560 (opencl_language::language_arch_info): ...here, a new member
3561 function.
3562 (opencl_language_data): Delete la_language_arch_info.
3563 * p-lang.c (pascal_language_arch_info): Delete function, move
3564 implementation to...
3565 (pascal_language::language_arch_info): ...here, a new member
3566 function.
3567 (pascal_language_data): Delete la_language_arch_info.
3568 * rust-lang.c (rust_language_arch_info): Delete function, move
3569 implementation to...
3570 (rust_language::language_arch_info): ...here, a new member
3571 function.
3572 (rust_language_data): Delete la_language_arch_info.
3573
3574 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3575
3576 * ada-lang.c (ada_language_data): Delete la_pass_by_reference
3577 initializer.
3578 * c-lang.c (c_language_data): Likewise.
3579 (cplus_language_data): Likewise.
3580 (cplus_language::pass_by_reference_info): New method.
3581 (asm_language_data): Delete la_pass_by_reference initializer.
3582 (minimal_language_data): Likewise.
3583 * cp-abi.c (cp_pass_by_reference): Remove use of
3584 default_pass_by_reference.
3585 * d-lang.c (d_language_data): Likewise.
3586 * f-lang.c (f_language_data): Likewise.
3587 * gnu-v3-abi.c (gnuv3_pass_by_reference): Remove use of
3588 default_pass_by_reference.
3589 * go-lang.c (go_language_data): Likewise.
3590 * language.c (language_pass_by_reference): Update.
3591 (default_pass_by_reference): Delete.
3592 (unknown_language_data): Delete la_pass_by_reference
3593 initializer.
3594 (auto_language_data): Likewise.
3595 * language.h (struct language_data): Delete la_pass_by_reference
3596 field.
3597 (language_defn::pass_by_reference_info): New member function.
3598 (default_pass_by_reference): Delete declaration.
3599 * m2-lang.c (m2_language_data): Delete la_pass_by_reference
3600 initializer.
3601 * objc-lang.c (objc_language_data): Likewise.
3602 * opencl-lang.c (opencl_language_data): Likewise.
3603 * p-lang.c (pascal_language_data): Likewise.
3604 * rust-lang.c (rust_language_data): Likewise.
3605
3606 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3607
3608 * ada-lang.c (ada_read_var_value): Delete function, move
3609 implementation to...
3610 (ada_language::read_var_value): ...here.
3611 (ada_language_data): Delete la_read_var_value initializer.
3612 * c-lang.c (c_language_data): Likewise.
3613 (cplus_language_data): Likewise.
3614 (minimal_language_data): Likewise.
3615 * d-lang.c (d_language_data): Likewise.
3616 * f-lang.c (f_language_data): Likewise.
3617 * findvar.c (default_read_var_value): Rename to...
3618 (language_defn::read_var_value): ...this.
3619 * findvar.c (read_var_value): Update header comment, and change to
3620 call member function instead of function pointer.
3621 * go-lang.c (go_language_data): Likewise.
3622 * language.c (unknown_language_data): Delete la_read_var_value
3623 initializer.
3624 (auto_language_data): Likewise.
3625 * language.h (struct language_data): Delete la_read_var_value
3626 field.
3627 (language_defn::read_var_value): New member function.
3628 (default_read_var_value): Delete declaration.
3629 * m2-lang.c (m2_language_data): Delete la_read_var_value
3630 initializer.
3631 * objc-lang.c (objc_language_data): Likewise.
3632 * opencl-lang.c (opencl_language_data): Likewise.
3633 * p-lang.c (pascal_language_data): Likewise.
3634 * rust-lang.c (rust_language_data): Likewise.
3635 * value.h (default_read_var_value): Delete declaration.
3636
3637 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3638
3639 * ada-lang.c (ada_print_array_index): Delete function, move
3640 implementation to...
3641 (ada_language::print_array_index): ...here.
3642 (ada_language_data): Delete la_print_array_index initializer.
3643 * c-lang.c (c_language_data): Likewise.
3644 (cplus_language_data): Likewise.
3645 (minimal_language_data): Likewise.
3646 * d-lang.c (d_language_data): Likewise.
3647 * f-lang.c (f_language_data): Likewise.
3648 * go-lang.c (go_language_data): Likewise.
3649 * language.c (default_print_array_index): Delete function, move
3650 implementation to...
3651 (language_defn::print_array_index): ...here.
3652 (unknown_language_data): Delete la_print_array_index initializer.
3653 (auto_language_data): Likewise.
3654 * language.h (struct language_data): Delete la_print_array_index
3655 field.
3656 (language_defn::print_array_index): New member function.
3657 (LA_PRINT_ARRAY_INDEX): Update.
3658 (default_print_array_index): Delete declaration.
3659 * m2-lang.c (m2_language_data): Delete la_print_array_index
3660 initializer.
3661 * objc-lang.c (objc_language_data): Likewise.
3662 * opencl-lang.c (opencl_language_data): Likewise.
3663 * p-lang.c (pascal_language_data): Likewise.
3664 * rust-lang.c (rust_language_data): Likewise.
3665
3666 2020-06-02 Andrew Burgess <andrew.burgess@embecosm.com>
3667
3668 * gdb/ada-lang.c (ada_language_defn): Convert to...
3669 (ada_language_data): ...this.
3670 (class ada_language): New class.
3671 (ada_language_defn): New static global.
3672 * gdb/c-lang.c (c_language_defn): Convert to...
3673 (c_language_data): ...this.
3674 (class c_language): New class.
3675 (c_language_defn): New static global.
3676 (cplus_language_defn): Convert to...
3677 (cplus_language_data): ...this.
3678 (class cplus_language): New class.
3679 (cplus_language_defn): New static global.
3680 (asm_language_defn): Convert to...
3681 (asm_language_data): ...this.
3682 (class asm_language): New class.
3683 (asm_language_defn): New static global.
3684 (minimal_language_defn): Convert to...
3685 (minimal_language_data): ...this.
3686 (class minimal_language): New class.
3687 (minimal_language_defn): New static global.
3688 * gdb/d-lang.c (d_language_defn): Convert to...
3689 (d_language_data): ...this.
3690 (class d_language): New class.
3691 (d_language_defn): New static global.
3692 * gdb/f-lang.c (f_language_defn): Convert to...
3693 (f_language_data): ...this.
3694 (class f_language): New class.
3695 (f_language_defn): New static global.
3696 * gdb/go-lang.c (go_language_defn): Convert to...
3697 (go_language_data): ...this.
3698 (class go_language): New class.
3699 (go_language_defn): New static global.
3700 * gdb/language.c (unknown_language_defn): Remove declaration.
3701 (current_language): Initialize to nullptr, real initialization is
3702 moved to _initialize_language.
3703 (languages): Delete global.
3704 (language_defn::languages): Define.
3705 (set_language_command): Use language_defn::languages.
3706 (set_language): Likewise.
3707 (range_error): Likewise.
3708 (language_enum): Likewise.
3709 (language_def): Likewise.
3710 (add_set_language_command): Use language_def::languages for the
3711 language list, and language_def to lookup language pointers.
3712 (skip_language_trampoline): Use language_defn::languages.
3713 (unknown_language_defn): Convert to...
3714 (unknown_language_data): ...this.
3715 (class unknown_language): New class.
3716 (unknown_language_defn): New static global.
3717 (auto_language_defn): Convert to...
3718 (auto_language_data): ...this.
3719 (class auto_language): New class.
3720 (auto_language_defn): New static global.
3721 (language_gdbarch_post_init): Use language_defn::languages.
3722 (_initialize_language): Initialize current_language.
3723 * gdb/language.h (struct language_defn): Rename to...
3724 (struct language_data): ...this.
3725 (struct language_defn): New.
3726 (auto_language_defn): Delete.
3727 (unknown_language_defn): Delete.
3728 (minimal_language_defn): Delete.
3729 (ada_language_defn): Delete.
3730 (asm_language_defn): Delete.
3731 (c_language_defn): Delete.
3732 (cplus_language_defn): Delete.
3733 (d_language_defn): Delete.
3734 (f_language_defn): Delete.
3735 (go_language_defn): Delete.
3736 (m2_language_defn): Delete.
3737 (objc_language_defn): Delete.
3738 (opencl_language_defn): Delete.
3739 (pascal_language_defn): Delete.
3740 (rust_language_defn): Delete.
3741 * gdb/m2-lang.c (m2_language_defn): Convert to...
3742 (m2_language_data): ...this.
3743 (class m2_language): New class.
3744 (m2_language_defn): New static global.
3745 * gdb/objc-lang.c (objc_language_defn): Convert to...
3746 (objc_language_data): ...this.
3747 (class objc_language): New class.
3748 (objc_language_defn): New static global.
3749 * gdb/opencl-lang.c (opencl_language_defn): Convert to...
3750 (opencl_language_data): ...this.
3751 (class opencl_language): New class.
3752 (opencl_language_defn): New static global.
3753 * gdb/p-lang.c (pascal_language_defn): Convert to...
3754 (pascal_language_data): ...this.
3755 (class pascal_language): New class.
3756 (pascal_language_defn): New static global.
3757 * gdb/rust-exp.y (rust_lex_tests): Use language_def to find
3758 language pointer, update comment format.
3759 * gdb/rust-lang.c (rust_language_defn): Convert to...
3760 (rust_language_data): ...this.
3761 (class rust_language): New class.
3762 (rust_language_defn): New static global.
3763
3764 2020-06-01 Andrew Burgess <andrew.burgess@embecosm.com>
3765
3766 * dwarf2/read.c (class lnp_state_machine) <m_last_address>: New
3767 member variable.
3768 <m_stmt_at_address>: New member variable.
3769 (lnp_state_machine::record_line): Don't record some lines, update
3770 tracking of is_stmt at the same address.
3771 (lnp_state_machine::lnp_state_machine): Initialise new member
3772 variables.
3773
3774 2020-06-01 Samuel Thibault <samuel.thibault@ens-lyon.org>
3775
3776 * config/i386/i386gnu.mn [%_S.o %_U.o] (COMPILE.post): Add
3777 "-include gnu-nat-mig.h".
3778 * gnu-nat-mig.h: New file.
3779 * gnu-nat.c: Include "gnu-nat-mig.h".
3780 (exc_server, msg_reply_server, notify_server,
3781 process_reply_server): Remove declarations.
3782
3783 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3784
3785 * gnu-nat.h (inf_validate_procs, inf_suspend, inf_set_traced,
3786 steal_exc_port, proc_get_state, inf_clear_wait, inf_cleanup,
3787 inf_startup, inf_update_suspends, inf_set_pid, inf_steal_exc_ports,
3788 inf_validate_procinfo, inf_validate_task_sc, inf_restore_exc_ports,
3789 inf_set_threads_resume_sc, inf_set_threads_resume_sc_for_signal_thread,
3790 inf_resume, inf_set_step_thread, inf_detach, inf_attach, inf_signal,
3791 inf_continue, make_proc, proc_abort, _proc_free, proc_update_sc,
3792 proc_get_exception_port, proc_set_exception_port, _proc_get_exc_port,
3793 proc_steal_exc_port, proc_restore_exc_port, proc_trace): Move functions
3794 to gnu_nat_target class.
3795 * gnu-nat.c: Likewise.
3796 (inf_update_procs, S_proc_wait_reply, set_task_pause_cmd,
3797 set_task_exc_port_cmd, set_signals_cmd, set_thread_pause_cmd,
3798 set_thread_exc_port_cmd): Call inf_validate_procs through gnu_target
3799 object.
3800 (gnu_nat_target::create_inferior, gnu_nat_target::detach): Pass `this'
3801 instead of `gnu_target'.
3802
3803 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3804
3805 * i386-gnu-tdep.c: Include "gdbcore.h"
3806 (gnu_sigtramp_code, i386_gnu_sc_reg_offset): New arrays.
3807 (GNU_SIGTRAMP_LEN, GNU_SIGTRAMP_TAIL,
3808 I386_GNU_SIGCONTEXT_THREAD_STATE_OFFSET): New macros
3809 (i386_gnu_sigtramp_start, i386_gnu_sigtramp_p,
3810 i386_gnu_sigcontext_addr): New functions
3811 (i386gnu_init_abi): Register i386_gnu_sigtramp_p,
3812 i386_gnu_sigcontext_addr, and i386_gnu_sc_reg_offset in the gdbarch
3813 tdep.
3814
3815 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3816
3817 * gnu-nat.c (gnu_nat_target::create_inferior): Move push_target call
3818 before fork_inferior call. Avoid calling it if target_is_pushed returns
3819 true.
3820
3821 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3822
3823 * gnu-nat.h (gnu_target): New variable declaration.
3824 * i386-gnu-nat.c (_initialize_i386gnu_nat): Initialize
3825 gnu_target.
3826 * gnu-nat.c (gnu_target): New variable.
3827 (inf_validate_procs): Pass gnu_target to thread_change_ptid,
3828 add_thread_silent, and add_thread calls.
3829 (gnu_nat_target::create_inferior): Pass gnu_target to
3830 add_thread_silent, thread_change_ptid call.
3831 (gnu_nat_target::detach): Pass gnu_target to detach_inferior
3832 call.
3833
3834 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3835
3836 * gnu-nat.c (gnu_xfer_auxv): Remove unused `res' variable.
3837 (gnu_nat_target::find_memory_regions): Remove unused
3838 `old_address' variable.
3839
3840 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3841
3842 * gnu-nat.c: Include "gdbarch.h".
3843
3844 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3845
3846 * reply_mig_hack.awk (Error return): Cast function through
3847 void *, to bypass compiler function call check.
3848
3849 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3850
3851 * config/i386/i386gnu.mn (%_reply_S.c): Add dependency on
3852 $(srcdir)/reply_mig_hack.awk.
3853
3854 2020-05-30 Samuel Thibault <samuel.thibault@ens-lyon.org>
3855
3856 * gnu-nat.h (gnu_debug_flag): Set type to bool.
3857
3858 2020-05-30 Jonny Grant <jg@jguk.org>
3859
3860 * configure.ac (ACX_BUGURL): change bug URL to https.
3861
3862 2020-05-30 Pedro Alves <palves@redhat.com>
3863
3864 * cp-support.c (replace_typedefs_template): New.
3865 (replace_typedefs_qualified_name): Handle
3866 DEMANGLE_COMPONENT_TEMPLATE.
3867
3868 2020-05-29 Simon Marchi <simon.marchi@efficios.com>
3869
3870 * dwarf2/comp-unit.c, dwarf2/comp-unit.h, dwarf2/index-cache.c,
3871 dwarf2/index-cache.h, dwarf2/index-write.c,
3872 dwarf2/index-write.h, dwarf2/line-header.c,
3873 dwarf2/line-header.h, dwarf2/macro.c, dwarf2/macro.h,
3874 dwarf2/read.c, dwarf2/read.h: Rename struct dwarf2_per_objfile
3875 variables and fields from `dwarf2_per_objfile` to just
3876 `per_objfile` throughout.
3877
3878 2020-05-28 Simon Marchi <simon.marchi@polymtl.ca>
3879
3880 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3881 <push_dwarf_reg_entry_value>: Add comment.
3882
3883 2020-05-28 Kevin Buettner <kevinb@redhat.com>
3884 Keith Seitz <keiths@redhat.com>
3885
3886 * python/python.c (do_start_initialization): Call PyEval_SaveThread
3887 instead of PyEval_ReleaseLock.
3888 (class gdbpy_gil): Move to earlier in file.
3889 (finalize_python): Set gdb_python_initialized.
3890 (gdbpy_check_quit_flag): Acquire GIL via gdbpy_gil. Return early
3891 when not initialized.
3892
3893 2020-05-28 Simon Marchi <simon.marchi@efficios.com>
3894
3895 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
3896 <push_dwarf_reg_entry_value>: Remove assert. Override
3897 per_objfile with caller_per_objfile.
3898
3899 2020-05-28 Tom de Vries <tdevries@suse.de>
3900
3901 * dwarf2/read.c (dw2_symtab_iter_next, dw2_expand_marked_cus): Limit
3902 PR gold/15646 workaround to symbol kind "type".
3903
3904 2020-05-27 Tom Tromey <tromey@adacore.com>
3905
3906 * dwarf2/read.c (load_partial_dies): Use add_partial_symbol.
3907
3908 2020-05-27 Tom Tromey <tromey@adacore.com>
3909
3910 * dwarf2/abbrev.h (struct abbrev_table) <lookup_abbrev>: Inline.
3911 Use htab_find_with_hash.
3912 <add_abbrev>: Remove "abbrev_number" parameter.
3913 * dwarf2/abbrev.c (abbrev_table::add_abbrev): Remove
3914 "abbrev_number" parameter. Use htab_find_slot_with_hash.
3915 (hash_abbrev): Add comment.
3916 (abbrev_table::lookup_abbrev): Move to header file.
3917 (abbrev_table::read): Update.
3918
3919 2020-05-27 Tom Tromey <tromey@adacore.com>
3920
3921 * dwarf2/read.c (struct partial_die_info) <name>: Declare new
3922 method.
3923 <canonical_name>: New member.
3924 <raw_name>: Rename from "name".
3925 (partial_die_info): Initialize canonical_name.
3926 (scan_partial_symbols): Check raw_name.
3927 (partial_die_parent_scope, partial_die_full_name)
3928 (add_partial_symbol, add_partial_subprogram)
3929 (add_partial_enumeration, load_partial_dies): Use "name" method.
3930 (partial_die_info::name): New method.
3931 (partial_die_info::read, guess_partial_die_structure_name)
3932 (partial_die_info::fixup): Update.
3933
3934 2020-05-27 Tom Tromey <tromey@adacore.com>
3935
3936 * dwarf2/attribute.h (struct attribute) <form_is_ref>: Inline.
3937 <get_ref_die_offset>: Inline.
3938 <get_ref_die_offset_complaint>: New method.
3939 * dwarf2/attribute.c (attribute::form_is_ref): Move to header.
3940 (attribute::get_ref_die_offset_complaint): Rename from
3941 get_ref_die_offset. Just issue complaint.
3942
3943 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3944
3945 * cli/cli-cmds.c (shell_escape): Move exit_status_set_internal_vars.
3946
3947 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3948
3949 * exec.c (exec_file_attach): Use errno value of first openp failure.
3950
3951 2020-05-27 Hannes Domani <ssbssa@yahoo.de>
3952
3953 * nat/windows-nat.c (windows_thread_info::~windows_thread_info):
3954 Don't close thread handle.
3955
3956 2020-05-27 Tom Tromey <tom@tromey.com>
3957 Simon Marchi <simon.marchi@efficios.com>
3958
3959 * objfiles.h (struct objfile) <partial_symtabs>: Now a
3960 shared_ptr.
3961 * dwarf2/read.h (struct dwarf2_per_objfile) <partial_symtabs>: New
3962 member.
3963 * dwarf2/read.c (dwarf2_per_bfd_bfd_data_key,
3964 dwarf2_per_bfd_objfile_data_key>: New globals.
3965 (dwarf2_has_info): Use shared dwarf2_per_bfd if possible.
3966 (dwarf2_get_section_info): Use get_dwarf2_per_objfile.
3967 (dwarf2_initialize_objfile): Consider cases where per_bfd can be
3968 shared.
3969 (dwarf2_build_psymtabs): Set objfile::partial_symtabs and
3970 short-circuit when sharing.
3971 (dwarf2_build_psymtabs): Set dwarf2_per_objfile::partial_symtabs.
3972 (dwarf2_psymtab::expand_psymtab): Use free_cached_comp_units.
3973
3974 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3975
3976 * dwarf2/read.h (struct dwarf2_per_bfd) <line_header_hash>: Move
3977 to...
3978 (struct dwarf2_per_objfile) <line_header_hash>: ... here.
3979 * dwarf2/read.c (handle_DW_AT_stmt_list): Update.
3980
3981 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
3982
3983 * dwarf2/read.c (struct mapped_index_base) <symbol_name_at,
3984 build_name_components, find_name_components_bounds>:
3985 Add per_objfile parameter.
3986 (struct mapped_index) <symbol_name_at>: Likewise.
3987 (struct mapped_debug_names): Remove constructor.
3988 <dwarf2_per_objfile>: Remove field.
3989 <namei_to_name, symbol_name_at>: Add per_objfile parameter.
3990 (mapped_index_base::find_name_components_bounds,
3991 mapped_index_base::build_name_components,
3992 dw2_expand_symtabs_matching_symbol): Likewise.
3993 (class mock_mapped_index) <symbol_name_at>: Likewise.
3994 (check_match): Likewise.
3995 (check_find_bounds_finds): Likewise.
3996 (test_mapped_index_find_name_component_bounds): Update.
3997 (CHECK_MATCH): Update.
3998 (dw2_expand_symtabs_matching): Update.
3999 (class dw2_debug_names_iterator) <dw2_debug_names_iterator>: Add
4000 per_objfile parameter.
4001 <find_vec_in_debug_names>: Likewise.
4002 <m_per_objfile>: New field.
4003 (mapped_debug_names::namei_to_name): Add dwarf2_per_objfile
4004 parameter.
4005 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
4006 (dw2_debug_names_iterator::next): Update.
4007 (dw2_debug_names_lookup_symbol): Update.
4008 (dw2_debug_names_expand_symtabs_for_function): Update.
4009 (dw2_debug_names_map_matching_symbols): Update.
4010 (dw2_debug_names_expand_symtabs_matching): Update.
4011 (dwarf2_read_debug_names): Update.
4012
4013 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4014
4015 * dwarf2/read.h (struct dwarf2_cu): Forward-declare.
4016 (struct dwarf2_per_bfd) <free_cached_comp_units>: Remove,
4017 move to dwarf2_per_objfile.
4018 <read_in_chain>: Remove.
4019 (struct dwarf2_per_objfile) <get_cu, set_cu, remove_cu,
4020 remove_all_cus, age_comp_units>: New methods.
4021 <m_dwarf2_cus>: New member.
4022 (struct dwarf2_per_cu_data) <cu>: Remove.
4023 * dwarf2/read.c (struct dwarf2_cu) <read_in_chain>: Remove.
4024 (age_cached_comp_units, free_one_cached_comp_unit): Remove,
4025 moved to methods of dwarf2_per_objfile.
4026 (dwarf2_clear_marks): Remove.
4027 (dwarf2_queue_item::~dwarf2_queue_item): Update.
4028 (dwarf2_per_bfd::~dwarf2_per_bfd): Don't free dwarf2_cus.
4029 (dwarf2_per_bfd::free_cached_comp_units): Remove.
4030 (dwarf2_per_objfile::remove_all_cus): New.
4031 (class free_cached_comp_units) <~free_cached_comp_units>:
4032 Update.
4033 (load_cu): Update.
4034 (dw2_do_instantiate_symtab): Adjust.
4035 (fill_in_sig_entry_from_dwo_entry): Adjust.
4036 (cutu_reader::init_tu_and_read_dwo_dies): Update.
4037 (cutu_reader::cutu_reader): Likewise.
4038 (cutu_reader::keep): Use dwarf2_per_objfile::set_cu.
4039 (cutu_reader::cutu_reader): Use dwarf2_per_objfile::get_cu.
4040 (process_psymtab_comp_unit): Use dwarf2_per_objfile::remove_cu
4041 and dwarf2_per_objfile::age_comp_units.
4042 (load_partial_comp_unit): Update.
4043 (maybe_queue_comp_unit): Use dwarf2_per_objfile::get_cu.
4044 (process_queue): Likewise.
4045 (find_partial_die): Use dwarf2_per_objfile::get_cu instead of cu
4046 backlink.
4047 (dwarf2_read_addr_index): Likewise.
4048 (follow_die_offset): Likewise.
4049 (dwarf2_fetch_die_loc_sect_off): Likewise.
4050 (dwarf2_fetch_constant_bytes): Likewise.
4051 (dwarf2_fetch_die_type_sect_off): Likewise.
4052 (follow_die_sig_1): Likewise.
4053 (load_full_type_unit): Likewise.
4054 (read_signatured_type): Likewise.
4055 (dwarf2_cu::dwarf2_cu): Don't set cu field.
4056 (dwarf2_cu::~dwarf2_cu): Remove.
4057 (dwarf2_per_objfile::get_cu): New.
4058 (dwarf2_per_objfile::set_cu): New.
4059 (age_cached_comp_units): Rename to...
4060 (dwarf2_per_objfile::age_comp_units): ... this. Adjust
4061 to std::unordered_map.
4062 (free_one_cached_comp_unit): Rename to...
4063 (dwarf2_per_objfile::remove_cu): ... this. Adjust
4064 to std::unordered_map.
4065 (dwarf2_per_objfile::~dwarf2_per_objfile): New.
4066 (dwarf2_mark_helper): Use dwarf2_per_objfile::get_cu, expect
4067 a dwarf2_per_objfile in data.
4068 (dwarf2_mark): Pass dwarf2_per_objfile in data to htab_traverse.
4069 (dwarf2_clear_marks): Remove.
4070
4071 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4072
4073 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Replace
4074 `int use_existing_cu` parameter with `dwarf2_cu *existing_cu`.
4075 (init_tu_and_read_dwo_dies): Likewise.
4076 (cutu_reader::init_tu_and_read_dwo_dies): Likewise.
4077 (cutu_reader::cutu_reader): Likewise.
4078 (load_partial_comp_unit): Likewise.
4079 (process_psymtab_comp_unit): Update.
4080 (build_type_psymtabs_1): Update.
4081 (process_skeletonless_type_unit): Update.
4082 (load_full_comp_unit): Update.
4083 (find_partial_die): Update.
4084 (dwarf2_read_addr_index): Update.
4085 (read_signatured_type): Update.
4086
4087 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4088
4089 * dwarf2/read.h (struct dwarf2_per_cu_data) <m_header,
4090 m_header_read_in>: New fields.
4091 <get_header>: New method.
4092 * dwarf2/read.c (per_cu_header_read_in): Remove.
4093 (dwarf2_per_cu_data::get_header): New.
4094 (dwarf2_per_cu_data::addr_size): Update.
4095 (dwarf2_per_cu_data::offset_size): Update.
4096 (dwarf2_per_cu_data::ref_addr_size): Update.
4097
4098 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4099
4100 * dwarf2/read.c (load_cu): Return dwarf2_cu.
4101 (dw2_do_instantiate_symtab): Update.
4102 (queue_and_load_all_dwo_tus): Change parameter from
4103 dwarf2_per_cu_data to dwarf2_cu.
4104 (dwarf2_fetch_die_loc_sect_off): Update.
4105 (dwarf2_fetch_constant_bytes): Update.
4106 (dwarf2_fetch_die_type_sect_off): Update.
4107
4108 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4109
4110 * dwarf2/read.c (process_full_comp_unit,
4111 process_full_type_unit): Remove per_cu, per_objfile paramters.
4112 Add dwarf2_cu parameter.
4113 (process_queue): Update.
4114
4115 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4116
4117 * dwarf2/read.c (create_cu_from_index_list): Replace
4118 dwarf2_per_objfile parameter with dwarf2_per_bfd.
4119 (create_cus_from_index_list): Likewise.
4120 (create_cus_from_index): Likewise.
4121 (create_signatured_type_table_from_index): Likewise.
4122 (create_cus_from_debug_names_list): Likewise.
4123 (create_cus_from_debug_names): Likewise.
4124 (dwarf2_read_gdb_index): Update.
4125 (dwarf2_read_debug_names): Update.
4126
4127 2020-05-27 Tom Tromey <tom@tromey.com>
4128 Simon Marchi <simon.marchi@efficios.com>
4129
4130 * dwarf2/read.h (struct dwarf2_per_objfile)
4131 <get_type_for_signatured_type, set_type_for_signatured_type>:
4132 New methods.
4133 <m_type_map>: New member.
4134 (struct signatured_type) <type>: Remove.
4135 * dwarf2/read.c
4136 (dwarf2_per_objfile::get_type_for_signatured_type,
4137 dwarf2_per_objfile::set_type_for_signatured_type): New.
4138 (get_signatured_type): Use new methods.
4139
4140 2020-05-27 Tom Tromey <tom@tromey.com>
4141 Simon Marchi <simon.marchi@efficios.com>
4142
4143 * dwarf2/read.h (struct type_unit_group_unshareable): New.
4144 (struct dwarf2_per_objfile) <type_units>: New member.
4145 <get_type_unit_group_unshareable>: New method.
4146 * dwarf2/read.c (struct type_unit_group) <compunit_symtab,
4147 num_symtabs, symtabs>: Remove; move to
4148 type_unit_group_unshareable.
4149 (dwarf2_per_objfile::get_type_unit_group_unshareable): New.
4150 (process_full_type_unit, dwarf2_cu::setup_type_unit_groups)
4151 (dwarf2_cu::setup_type_unit_groups): Use type_unit_group_unshareable.
4152
4153 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4154
4155 * dwarf2/read.h (struct dwarf2_per_cu_data):
4156 <dwarf2_per_objfile>: Remove.
4157 * dwarf2/read.c (create_cu_from_index_list): Don't assign
4158 dwarf2_per_objfile.
4159 (create_signatured_type_table_from_index): Likewise.
4160 (create_signatured_type_table_from_debug_names): Likewise.
4161 (create_debug_type_hash_table): Likewise.
4162 (fill_in_sig_entry_from_dwo_entry): Likewise.
4163 (create_type_unit_group): Likewise.
4164 (read_comp_units_from_section): Likewise.
4165 (create_cus_hash_table): Likewise.
4166
4167 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4168
4169 * dwarf2/read.c (process_psymtab_comp_unit): Remove reference to
4170 dwarf2_per_cu_data::dwarf2_per_objfile.
4171 (compute_compunit_symtab_includes): Likewise.
4172 (dwarf2_cu::start_symtab): Likewise.
4173
4174 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4175
4176 * dwarf2/read.h (dwarf2_get_die_type): Add dwarf2_per_objfile
4177 parameter.
4178 * dwarf2/read.c (get_die_type_at_offset): Likewise.
4179 (read_namespace_alias): Update.
4180 (lookup_die_type): Update.
4181 (dwarf2_get_die_type): Add dwarf2_per_objfile parameter.
4182 * dwarf2/loc.c (class dwarf_evaluate_loc_desc) <get_base_type>:
4183 Update.
4184 (disassemble_dwarf_expression): Update.
4185
4186 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4187
4188 * dwarf2/read.h (struct dwarf2_queue_item): Add
4189 dwarf2_per_objfile parameter, assign new parameter.
4190 <per_objfile>: New field.
4191 * dwarf2/read.c (free_one_cached_comp_unit): Add
4192 dwarf2_per_objfile parameter.
4193 (queue_comp_unit): Likewise.
4194 (dw2_do_instantiate_symtab): Update.
4195 (process_psymtab_comp_unit): Update.
4196 (maybe_queue_comp_unit): Add dwarf2_per_objfile parameter.
4197 (process_imported_unit_die): Update.
4198 (queue_and_load_dwo_tu): Update.
4199 (follow_die_offset): Update.
4200 (follow_die_sig_1): Update.
4201
4202 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4203
4204 * dwarf2/read.h (struct dwarf2_per_cu_data) <objfile>: Remove.
4205 * dwarf2/read.c (dwarf2_compute_name): Pass per_objfile down.
4206 (read_call_site_scope): Assign per_objfile.
4207 (dwarf2_per_cu_data::objfile): Remove.
4208 * gdbtypes.h (struct call_site) <per_objfile>: New member.
4209 * dwarf2/loc.h (dwarf2_evaluate_loc_desc): Add
4210 dwarf2_per_objfile parameter.
4211 * dwarf2/loc.c (dwarf2_evaluate_loc_desc_full): Add
4212 dwarf2_per_objfile parameter.
4213 (dwarf_expr_reg_to_entry_parameter): Add output
4214 dwarf2_per_objfile parameter.
4215 (locexpr_get_frame_base): Update.
4216 (class dwarf_evaluate_loc_desc) <get_tls_address>: Update.
4217 <push_dwarf_reg_entry_value>: Update.
4218 <call_site_to_target_addr>: Update.
4219 (dwarf_entry_parameter_to_value): Add dwarf2_per_objfile
4220 parameter.
4221 (value_of_dwarf_reg_entry): Update.
4222 (rw_pieced_value): Update.
4223 (indirect_synthetic_pointer): Update.
4224 (dwarf2_evaluate_property): Update.
4225 (dwarf2_loc_desc_get_symbol_read_needs): Add dwarf2_per_objfile
4226 parameter.
4227 (locexpr_read_variable): Update.
4228 (locexpr_get_symbol_read_needs): Update.
4229 (loclist_read_variable): Update.
4230
4231 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4232
4233 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
4234 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
4235 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
4236 parameter.
4237 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
4238 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
4239 dwarf2_fetch_die_type_sect_off): Add dwarf2_per_objfile
4240 parameter.
4241 * dwarf2/loc.c (indirect_synthetic_pointer, per_cu_dwarf_call,
4242 sect_variable_value): Add dwarf2_per_objfile parameter.
4243 (class dwarf_evaluate_loc_desc) <dwarf_call,
4244 dwarf_variable_value>: Update.
4245 (fetch_const_value_from_synthetic_pointer): Add
4246 dwarf2_per_objfile parameter.
4247 (fetch_const_value_from_synthetic_pointer): Update.
4248 (coerced_pieced_ref): Update.
4249 (class symbol_needs_eval_context) <dwarf_call,
4250 dwarf_variable_value>: Update.
4251 (dwarf2_compile_expr_to_ax): Update.
4252
4253 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4254
4255 * dwarf2/loc.c (allocate_piece_closure): Add dwarf2_per_objfile
4256 parameter.
4257 (dwarf2_evaluate_loc_desc_full): Update.
4258
4259 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4260
4261 * dwarf2/read.h (dwarf2_read_addr_index): Add dwarf2_per_objfile
4262 parameter.
4263 * dwarf2/read.c (dwarf2_read_addr_index): Likewise.
4264 * dwarf2/loc.c (decode_debug_loclists_addresses): Add
4265 dwarf2_per_objfile parameter.
4266 (decode_debug_loc_dwo_addresses): Likewise.
4267 (dwarf2_find_location_expression): Update.
4268 (class dwarf_evaluate_loc_desc) <get_addr_index>: Update.
4269 (locexpr_describe_location_piece): Add dwarf2_per_objfile
4270 parameter.
4271 (disassemble_dwarf_expression): Add dwarf2_per_objfile
4272 parameter.
4273 (locexpr_describe_location_1): Likewise.
4274 (locexpr_describe_location): Update.
4275
4276 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4277
4278 * dwarf2/read.h (struct dwarf2_per_cu_data) <text_offset>:
4279 Remove.
4280 * dwarf2/read.c (dwarf2_per_cu_data::text_offset): Remove.
4281 * dwarf2/loc.c (dwarf2_find_location_expression): Update.
4282 (dwarf2_compile_property_to_c): Update.
4283 (dwarf2_compile_expr_to_ax): Add dwarf2_per_objfile parameter,
4284 use text offset from objfile.
4285 (locexpr_tracepoint_var_ref): Update.
4286 (locexpr_generate_c_location): Update.
4287 (loclist_describe_location): Update.
4288 (loclist_tracepoint_var_ref): Update.
4289 * dwarf2/compile.h (compile_dwarf_bounds_to_c): Add
4290 dwarf2_per_objfile parameter.
4291 * dwarf2/loc2c.c (do_compile_dwarf_expr_to_c): Likewise,
4292 use text offset from objfile.
4293 (compile_dwarf_expr_to_c): Add dwarf2_per_objfile parameter.
4294
4295 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4296
4297 * dwarf2/expr.h (struct dwarf_expr_context)
4298 <dwarf_expr_context>: Add dwarf2_per_objfile parameter.
4299 <offset>: Remove.
4300 <per_objfile>: New member.
4301 * dwarf2/expr.c (dwarf_expr_context::dwarf_expr_context): Add
4302 dwarf2_per_objfile parameter. Don't set offset, set
4303 per_objfile.
4304 (dwarf_expr_context::execute_stack_op): Use offset from objfile.
4305 * dwarf2/frame.c (dwarf2_frame_find_fde): Return (by parameter)
4306 a dwarf2_per_objfile object instead of an offset.
4307 (class dwarf_expr_executor) <dwarf_expr_executor>: Add
4308 constructor.
4309 (execute_stack_op): Add dwarf2_per_objfile parameter, pass it
4310 to dwarf2_expr_executor constructor. Don't set offset.
4311 (dwarf2_fetch_cfa_info): Update.
4312 (struct dwarf2_frame_cache) <text_offset>: Remove.
4313 <per_objfile>: New field.
4314 (dwarf2_frame_cache): Update.
4315 (dwarf2_frame_prev_register): Update.
4316 * dwarf2/loc.c (class dwarf_evaluate_loc_desc)
4317 <dwarf_evaluate_loc_desc>: Add constructor.
4318 (dwarf2_evaluate_loc_desc_full): Update.
4319 (dwarf2_locexpr_baton_eval): Update.
4320 (class symbol_needs_eval_context) <symbol_needs_eval_context>:
4321 Add constructor.
4322 (dwarf2_loc_desc_get_symbol_read_needs): Update.
4323
4324 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4325
4326 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_type,
4327 addr_sized_int_type>: Move to dwarf2_cu.
4328 <int_type>: Move to dwarf2_per_objfile.
4329 (struct dwarf2_per_objfile) <int_type>: Move here.
4330 * dwarf2/read.c (struct dwarf2_cu) <addr_type,
4331 addr_sized_int_type>: Move here.
4332 (read_func_scope): Update.
4333 (read_array_type): Update.
4334 (read_tag_string_type): Update.
4335 (attr_to_dynamic_prop): Update.
4336 (dwarf2_per_cu_data::int_type): Rename to...
4337 (dwarf2_per_objfile::int_type): ... this.
4338 (dwarf2_per_cu_data::addr_sized_int_type): Rename to...
4339 (dwarf2_cu::addr_sized_int_type): ... this.
4340 (read_subrange_type): Update.
4341 (dwarf2_per_cu_data::addr_type): Rename to...
4342 (dwarf2_cu::addr_type): ... this.
4343 (set_die_type): Update.
4344
4345 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4346
4347 * dwarf2/read.c (queue_and_load_all_dwo_tus): Access per_objfile
4348 data through per_cu->cu.
4349
4350 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4351
4352 * dwarf2/read.c (lookup_dwo_comp_unit): Change
4353 dwarf2_per_cu_data parameter fo dwarf2_cu.
4354 (lookup_dwo_type_unit): Likewise.
4355 (read_cutu_die_from_dwo): Likewise.
4356 (lookup_dwo_unit): Likewise.
4357 (open_and_init_dwo_file): Likewise.
4358 (lookup_dwo_cutu): Likewise.
4359 (lookup_dwo_comp_unit): Likewise.
4360 (lookup_dwo_type_unit): Likewise.
4361 (cutu_reader::init_tu_and_read_dwo_dies): Update.
4362 (cutu_reader::cutu_reader): Update.
4363
4364 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4365
4366 * dwarf2/read.c (process_full_comp_unit): Add dwarf2_per_objfile
4367 parameter.
4368 (process_full_type_unit): Likewise.
4369 (process_queue): Update.
4370
4371 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4372
4373 * dwarf2/read.c (recursively_compute_inclusions): Add
4374 dwarf2_per_objfile parameter.
4375 (compute_compunit_symtab_includes): Likewise.
4376 (process_cu_includes): Update.
4377
4378 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4379
4380 * dwarf2/read.c (create_partial_symtab): Add dwarf2_per_objfile
4381 parameter.
4382 (create_type_unit_group): Update.
4383 (process_psymtab_comp_unit_reader): Update.
4384 (build_type_psymtabs_reader): Update.
4385
4386 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4387
4388 * dwarf2/read.c (cutu_reader::keep): Access dwarf2_per_objfile
4389 object through m_this_cu->cu.
4390
4391 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4392
4393 * dwarf2/read.c (queue_and_load_dwo_tu): Expect a dwarf2_cu as
4394 the info parameter.
4395 (queue_and_load_all_dwo_tus): Pass per_cu->cu.
4396
4397 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4398
4399 * dwarf2/read.c (class cutu_reader) <cutu_reader>: Add
4400 per_objfile parameter.
4401 (load_full_type_unit): Add per_objfile parameter.
4402 (read_signatured_type): Likewise.
4403 (load_full_comp_unit): Likewise.
4404 (load_cu): Likewise.
4405 (dw2_do_instantiate_symtab): Likewise.
4406 (dw2_get_file_names): Likewise.
4407 (dw2_map_symtabs_matching_filename): Update.
4408 (dw_expand_symtabs_matching_file_matcher): Update.
4409 (dw2_map_symbol_filenames): Update.
4410 (process_psymtab_comp_unit): Add per_objfile parameter.
4411 (build_type_psymtabs_1): Update.
4412 (process_skeletonless_type_unit): Update.
4413 (dwarf2_build_psymtabs_hard): Update.
4414 (load_partial_comp_unit): Add per_objfile parameter.
4415 (scan_partial_symbols): Update.
4416 (load_full_comp_unit): Add per_objfile parameter.
4417 (process_imported_unit_die): Update.
4418 (create_cus_hash_table): Update.
4419 (find_partial_die): Update.
4420 (dwarf2_read_addr_index): Update.
4421 (follow_die_offset): Update.
4422 (dwarf2_fetch_die_loc_sect_off): Update.
4423 (dwarf2_fetch_constant_bytes): Update.
4424 (dwarf2_fetch_die_type_sect_off): Update.
4425 (follow_die_sig_1): Update.
4426 (load_full_type_unit): Add per_objfile parameter.
4427 (read_signatured_type): Likewise.
4428
4429 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4430
4431 * dwarf2/read.c (lookup_dwo_unit): Use bfd_get_filename instead
4432 of objfile_name.
4433
4434 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4435
4436 * dwarf2/read.h (struct dwarf2_per_bfd) <obfd>: New member.
4437 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
4438 * dwarf2/read.c (dwarf2_per_bfd::dwarf2_per_bfd): Assign obfd
4439 field.
4440 (dwarf2_get_dwz_file): Replace parameter with dwarf2_per_bfd.
4441 (create_cus_from_index): Update.
4442 (dwarf2_read_gdb_index): Update.
4443 (create_cus_from_debug_names): Update.
4444 (dwarf2_read_debug_names): Update.
4445 (get_abbrev_section_for_cu): Update.
4446 (create_all_comp_units): Update.
4447 (read_attribute_value): Update.
4448 (get_debug_line_section): Update.
4449 * dwarf2/index-cache.c (index_cache::store): Update.
4450 * dwarf2/index-write.c (save_gdb_index_command): Update.
4451 * dwarf2/macro.c (dwarf_decode_macro_bytes): Update.
4452
4453 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4454
4455 * dwarf2/read.h (struct dwarf2_per_cu_data) <per_bfd>: New
4456 member.
4457 * dwarf2/read.c (dwarf2_per_bfd::allocate_per_cu): Initialize
4458 dwarf2_per_cu_data::per_bfd.
4459 (dwarf2_per_bfd::allocate_signatured_type): Likewise.
4460 (create_type_unit_group): Likewise.
4461 (queue_comp_unit): Remove reference to
4462 per_cu->dwarf2_per_objfile.
4463 (maybe_queue_comp_unit): Likewise.
4464 (fill_in_sig_entry_from_dwo_entry): Assign new field.
4465 (create_cus_hash_table): Assign new field.
4466
4467 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4468
4469 * dwarf2/read.c: Replace
4470 dwarf2_cu->per_cu->dwarf2_per_objfile references with
4471 dwarf2_cu->per_objfile throughout.
4472
4473 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4474
4475 * dwarf2/read.c (dw2_do_instantiate_symtab): Add per_objfile
4476 parameter, don't use per_cu->dwarf2_per_objfile.
4477 (dw2_instantiate_symtab): Likewise.
4478 (dw2_find_last_source_symtab): Update.
4479 (dw2_map_expand_apply): Update.
4480 (dw2_lookup_symbol): Update.
4481 (dw2_expand_symtabs_for_function): Update.
4482 (dw2_expand_all_symtabs): Update.
4483 (dw2_expand_symtabs_with_fullname): Update.
4484 (dw2_expand_symtabs_matching_one): Add per_objfile parameter,
4485 don't use per_cu->dwarf2_per_objfile.
4486 (dw2_expand_marked_cus): Update.
4487 (dw2_find_pc_sect_compunit_symtab): Update.
4488 (dw2_debug_names_lookup_symbol): Update.
4489 (dw2_debug_names_expand_symtabs_for_function): Update.
4490 (dw2_debug_names_map_matching_symbols): Update.
4491 (dwarf2_psymtab::expand_psymtab): Update.
4492
4493 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4494
4495 * dwarf2/read.c (struct dwarf2_cu) <dwarf2_cu>: Add parameter.
4496 <per_objfile>: New member.
4497 (class cutu_reader) <init_tu_and_read_dwo_dies>: Add parameter.
4498 (cutu_reader::init_tu_and_read_dwo_dies): Add parameter, update
4499 call to dwarf2_cu.
4500 (cutu_reader::cutu_reader): Update.
4501 (dwarf2_cu::dwarf2_cu): Add parameter, initialize per_objfile.
4502
4503 2020-05-27 Simon Marchi <simon.marchi@efficios.com>
4504
4505 * dwarf2/read.h (struct dwarf2_per_bfd) <die_type_hash>: Move to
4506 struct dwarf2_per_objfile.
4507 (struct dwarf2_per_objfile) <die_type_hash>: Move from struct
4508 dwarf2_per_bfd.
4509 * dwarf2/read.c (set_die_type): Update.
4510 (get_die_type_at_offset): Update.
4511
4512 2020-05-27 Tom Tromey <tom@tromey.com>
4513 Simon Marchi <simon.marchi@efficios.com>
4514
4515 * dwarf2/read.h (struct dwarf2_per_bfd) <num_psymtabs>: New
4516 method.
4517 (struct dwarf2_per_objfile) <resize_symtabs, symtab_set_p,
4518 get_symtab, set_symtab>: New methods.
4519 <m_symtabs>: New field.
4520 (struct dwarf2_psymtab): Derive from partial_symtab.
4521 <readin_p, get_compunit_symtab>: Declare methods.
4522 * dwarf2/read.c (dwarf2_per_objfile::symtab_set_p,
4523 dwarf2_per_objfile::get_symtab, dwarf2_per_objfile::set_symtab):
4524 New methods.
4525 (struct dwarf2_per_cu_quick_data) <compunit_symtab>: Remove.
4526 (dw2_do_instantiate_symtab, dw2_instantiate_symtab)
4527 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
4528 (dw2_symtab_iter_next, dw2_print_stats)
4529 (dw2_expand_symtabs_with_fullname)
4530 (dw2_expand_symtabs_matching_one)
4531 (dw_expand_symtabs_matching_file_matcher)
4532 (dw2_find_pc_sect_compunit_symtab, dw2_map_symbol_filenames)
4533 (dw2_debug_names_iterator::next)
4534 (dw2_debug_names_map_matching_symbols)
4535 (fill_in_sig_entry_from_dwo_entry, dwarf2_psymtab::read_symtab)
4536 (process_queue, dwarf2_psymtab::expand_psymtab): Update.
4537 (dwarf2_psymtab::readin_p, dwarf2_psymtab::get_compunit_symtab):
4538 New methods.
4539 (get_compunit_symtab, process_full_comp_unit)
4540 (process_full_type_unit): Update.
4541 (dwarf2_build_psymtabs, dwarf2_initialize_objfile, add_type_unit): Call
4542
4543 2020-05-27 Simon Marchi <simon.marchi@polymtl.ca>
4544
4545 * dwarf2/read.h (dwarf2_per_objfile): Rename to dwarf2_per_bfd,
4546 then introduce a new dwarf2_per_objfile type.
4547 <read_line_string>: Move to the new dwarf2_per_objfile type.
4548 <objfile>: Likewise.
4549 (dwarf2_per_bfd): Rename dwarf2_per_objfile to this.
4550 * dwarf2/read.c: Replace references to dwarf2_per_objfile with
4551 dwarf2_per_objfile->per_bfd.
4552 (dwarf2_per_objfile::dwarf2_per_objfile): Rename to...
4553 (dwarf2_per_bfd::dwarf2_per_bfd): ... this.
4554 (dwarf2_per_objfile::free_cached_comp_units): Rename to...
4555 (dwarf2_per_bfd::free_cached_comp_units): ... this.
4556 (dwarf2_has_info): Allocate dwarf2_per_bfd.
4557 (dwarf2_per_objfile::locate_sections): Rename to...
4558 (dwarf2_per_bfd::locate_sections): ... this.
4559 (dwarf2_per_objfile::get_cutu): Rename to...
4560 (dwarf2_per_bfd::get_cutu): ... this.
4561 (dwarf2_per_objfile::get_cu): Rename to...
4562 (dwarf2_per_bfd::get_cu): ... this.
4563 (dwarf2_per_objfile::get_tu): Rename to...
4564 (dwarf2_per_bfd::get_tu): ... this.
4565 (dwarf2_per_objfile::allocate_per_cu): Rename to...
4566 (dwarf2_per_bfd::allocate_per_cu): ... this.
4567 (dwarf2_per_objfile::allocate_signatured_type): Rename to...
4568 (dwarf2_per_bfd::allocate_signatured_type): ... this.
4569 (get_gdb_index_contents_ftype): Change parameter from
4570 dwarf2_per_objfile to dwarf2_per_bfd.
4571 * dwarf2/macro.c, dwarf2/index-write.c: Replace references to
4572 dwarf2_per_objfile with dwarf2_per_objfile->per_bfd.
4573
4574 2020-05-27 Tom Tromey <tom@tromey.com>
4575 Simon Marchi <simon.marchi@efficios.com>
4576
4577 * dwarf2/loc.c (struct piece_closure) <per_objfile>: New member.
4578 (allocate_piece_closure): Set "per_objfile" member.
4579 (dwarf2_find_location_expression, dwarf2_locexpr_baton_eval)
4580 (locexpr_describe_location, loclist_describe_location): Use new
4581 member.
4582 * dwarf2/read.c (read_call_site_scope)
4583 (mark_common_block_symbol_computed, attr_to_dynamic_prop)
4584 (dwarf2_const_value_attr, dwarf2_fetch_die_loc_sect_off)
4585 (fill_in_loclist_baton, dwarf2_symbol_mark_computed,
4586 handle_data_member_location): Set per_objfile member.
4587 * dwarf2/loc.h (struct dwarf2_locexpr_baton) <per_objfile>: New
4588 member.
4589 (struct dwarf2_loclist_baton) <per_objfile>: New member.
4590
4591 2020-05-27 Tom Tromey <tom@tromey.com>
4592
4593 * dwarf2/read.h (struct dwarf2_per_objfile) <allocate_per_cu,
4594 allocate_signatured_type>: Declare new methods.
4595 <m_num_psymtabs>: New member.
4596 (struct dwarf2_per_cu_data) <index>: New member.
4597 * dwarf2/read.c (dwarf2_per_objfile::allocate_per_cu)
4598 (dwarf2_per_objfile::allocate_signatured_type): New methods.
4599 (create_cu_from_index_list): Use allocate_per_cu.
4600 (create_signatured_type_table_from_index)
4601 (create_signatured_type_table_from_debug_names)
4602 (create_debug_type_hash_table, add_type_unit)
4603 (read_comp_units_from_section): Use allocate_signatured_type.
4604
4605 2020-05-27 Tom Tromey <tom@tromey.com>
4606
4607 * psymtab.c (partial_map_expand_apply)
4608 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
4609 (psym_lookup_global_symbol_language)
4610 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
4611 (psym_print_stats, psym_expand_symtabs_for_function)
4612 (psym_map_symbol_filenames, psym_map_matching_symbols)
4613 (psym_expand_symtabs_matching)
4614 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
4615 (maintenance_check_psymtabs): Update.
4616 * psympriv.h (struct partial_symtab) <readin_p,
4617 get_compunit_symtab>: Add objfile parameter.
4618 (struct standard_psymtab) <readin_p, get_compunit_symtab>:
4619 Likewise.
4620 * dwarf2/read.c (struct dwarf2_include_psymtab) <readin_p,
4621 get_compunit_symtab>: Likewise.
4622 (dwarf2_psymtab::expand_psymtab): Pass objfile argument.
4623
4624 2020-05-27 Tom Tromey <tom@tromey.com>
4625
4626 * dwarf2/read.h (struct dwarf2_per_objfile) <obstack>: New
4627 member.
4628 * dwarf2/read.c (delete_file_name_entry): Fix comment.
4629 (create_cu_from_index_list)
4630 (create_signatured_type_table_from_index)
4631 (create_signatured_type_table_from_debug_names)
4632 (dw2_get_file_names_reader, dwarf2_initialize_objfile)
4633 (dwarf2_create_include_psymtab)
4634 (create_debug_type_hash_table, add_type_unit)
4635 (create_type_unit_group, read_comp_units_from_section)
4636 (dwarf2_compute_name, create_cus_hash_table)
4637 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
4638 (create_dwo_unit_in_dwp_v2, open_and_init_dwp_file): Use new
4639 obstack.
4640 (dw2_get_real_path): Likewise. Change argument to
4641 dwarf2_per_objfile.
4642
4643 2020-05-27 Luis Machado <luis.machado@linaro.org>
4644
4645 PR tdep/26000
4646 * arm-tdep.c (thumb_analyze_prologue): Fix instruction matching
4647 for ldrd (immediate).
4648
4649 2020-05-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4650
4651 * command.h: Add comment giving the name of class_tui.
4652 * cli/cli-cmds.c (_initialize_cli_cmds): If TUI defined,
4653 create the fake command for the help for class_tui.
4654
4655 2020-05-26 Tom Tromey <tromey@adacore.com>
4656
4657 * ada-lang.c (ada_print_array_index): Change type. Call val_atr.
4658 (ada_value_ptr_subscript): Don't call pos_atr on the lower bound.
4659 (val_atr): New function.
4660 (value_val_atr): Use it.
4661 * ada-valprint.c (print_optional_low_bound): Change low bound
4662 handling for enums.
4663 (val_print_packed_array_elements): Don't call discrete_position.
4664 * gdbtypes.c (get_discrete_bounds) <TYPE_CODE_RANGE>: Call
4665 discrete_position for enum types.
4666 * language.c (default_print_array_index): Change type.
4667 * language.h (struct language_defn) <la_print_array_index>: Add
4668 index_type parameter, change type of index_value.
4669 (LA_PRINT_ARRAY_INDEX): Add index_type parameter.
4670 (default_print_array_index): Update.
4671 * valprint.c (maybe_print_array_index): Don't call
4672 value_from_longest. Update.
4673 (value_print_array_elements): Don't call discrete_position.
4674
4675 2020-05-26 Tom Tromey <tromey@adacore.com>
4676
4677 * ada-lang.c (value_val_atr): Handle TYPE_CODE_RANGE.
4678 * gdbtypes.c (discrete_position): Handle TYPE_CODE_RANGE.
4679
4680 2020-05-25 Cristiano De Alti <cristiano_dealti@hotmail.com>
4681
4682 PR gdb/13519
4683 * avr-tdep.c (avr_integer_to_address): Return data or code
4684 address accordingly to the second 'type' argument of the
4685 function.
4686
4687 2020-05-25 Michael Weghorn <m.weghorn@posteo.de>
4688
4689 * infcmd.c, inferior.h: (construct_inferior_arguments):
4690 Moved function from here to gdbsupport/common-inferior.{h,cc}
4691
4692 2020-05-23 Tom Tromey <tom@tromey.com>
4693
4694 Revert commit eca1f90c:
4695 * NEWS: Remove entry for completion styling.
4696 * completer.c (_rl_completion_prefix_display_length): Move
4697 declaration later.
4698 (gdb_fnprint): Revert.
4699 (gdb_display_match_list_1): Likewise.
4700 * cli/cli-style.c (completion_prefix_style)
4701 (completion_difference_style, completion_suffix_style): Remove.
4702 (_initialize_cli_style): Revert.
4703 * cli/cli-style.h (completion_prefix_style)
4704 (completion_difference_style, completion_suffix_style): Don't
4705 declare.
4706
4707 2020-05-24 Pedro Alves <palves@redhat.com>
4708
4709 * symtab.c (completion_list_add_name): Return boolean indication
4710 of whether the symbol matched.
4711 (completion_list_add_symbol): Don't try to remove C++ aliases if
4712 the symbol didn't match in the first place.
4713 * symtab.h (completion_list_add_name): Return bool.
4714
4715 2020-05-23 Simon Marchi <simon.marchi@polymtl.ca>
4716
4717 * gdbtypes.h (TYPE_FIELD): Remove. Replace all uses with
4718 type::field.
4719
4720 2020-05-23 Joel Brobecker <brobecker@adacore.com>
4721
4722 GDB 9.2 released.
4723
4724 2020-05-23 Tom Tromey <tom@tromey.com>
4725
4726 * NEWS: Add entry for completion styling.
4727 * completer.c (_rl_completion_prefix_display_length): Move
4728 declaration earlier.
4729 (gdb_fnprint): Use completion_style.
4730 (gdb_display_match_list_1): Likewise.
4731 * cli/cli-style.c (completion_prefix_style)
4732 (completion_difference_style, completion_suffix_style): New
4733 globals.
4734 (_initialize_cli_style): Register new globals.
4735 * cli/cli-style.h (completion_prefix_style)
4736 (completion_difference_style, completion_suffix_style): Declare.
4737
4738 2020-05-23 Pedro Alves <palves@redhat.com>
4739
4740 * utils.c: Include "gdbsupport/gdb-safe-ctype.h".
4741 (parse_escape): Use ISDIGIT instead of isdigit.
4742 (puts_debug): Use gdb_isprint instead of isprint.
4743 (fprintf_symbol_filtered): Use ISALNUM instead of isalnum.
4744 (cp_skip_operator_token, skip_ws, strncmp_iw_with_mode): Use
4745 ISSPACE instead of isspace.
4746 (strncmp_iw_with_mode): Use TOLOWER instead of tolower and ISSPACE
4747 instead of isspace.
4748 (strcmp_iw_ordered): Use ISSPACE instead of isspace.
4749 (string_to_core_addr): Use TOLOWER instead of tolower, ISXDIGIT
4750 instead of isxdigit and ISDIGIT instead of isdigit.
4751
4752 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4753
4754 * gdbtypes.h (struct type) <field>: New method.
4755 (TYPE_FIELDS): Remove, replace all uses with either type::fields
4756 or type::field.
4757
4758 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4759
4760 * gdbtypes.h (struct type) <fields, set_fields>: New methods.
4761 (TYPE_FIELDS): Use type::fields. Change all call sites that
4762 modify the propery to use type::set_fields instead.
4763
4764 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4765
4766 * gdbtypes.h (TYPE_NFIELDS): Remove. Change all cal sites to use
4767 type::num_fields instead.
4768
4769 2020-05-22 Simon Marchi <simon.marchi@efficios.com>
4770
4771 * gdbtypes.h (struct type) <num_fields, set_num_fields>: New
4772 methods.
4773 (TYPE_NFIELDS): Use type::num_fields. Change all call sites
4774 that modify the number of fields to use type::set_num_fields
4775 instead.
4776
4777 2020-05-22 Tom Tromey <tromey@adacore.com>
4778
4779 * compile/compile-object-load.h (munmap_list_free): Don't
4780 declare.
4781
4782 2020-05-22 Andrew Burgess <andrew.burgess@embecosm.com>
4783
4784 * annotate.c (annotate_source_line): Update return type, add call
4785 to update current symtab and line.
4786 * annotate.h (annotate_source_line): Update return type, and
4787 extend header comment.
4788 * source.c (info_line_command): Check annotation_level before
4789 calling annotate_source_line.
4790 * stack.c (print_frame_info): If calling annotate_source_line
4791 returns true, then don't print any other source line information.
4792
4793 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
4794
4795 * lm32-tdep.c (lm32_register_reggroup_p): Fix condition.
4796
4797 2020-05-21 Simon Marchi <simon.marchi@efficios.com>
4798
4799 * coffread.c (patch_type): Remove NULL check before xfree.
4800 * corefile.c (set_gnutarget): Likewise.
4801 * cp-abi.c (set_cp_abi_as_auto_default): Likewise.
4802 * exec.c (build_section_table): Likewise.
4803 * remote.c (remote_target::pass_signals): Likewise.
4804 * utils.c (n_spaces): Likewise.
4805 * cli/cli-script.c (document_command): Likewise.
4806 * i386-windows-tdep.c (core_process_module_section): Likewise.
4807 * linux-fork.c (struct fork_info) <~fork_info>: Likewise.
4808
4809 2020-05-20 Simon Marchi <simon.marchi@efficios.com>
4810
4811 * symfile.c (reread_symbols): Clear objfile's section_offsets
4812 vector and section indices, re-compute them by calling
4813 sym_offsets.
4814
4815 2020-05-20 Tom Tromey <tromey@adacore.com>
4816
4817 * ada-lang.c (bound_name, MAX_ADA_DIMENS): Remove.
4818 (desc_one_bound, desc_index_type): Compute field name.
4819
4820 2020-05-20 Tom de Vries <tdevries@suse.de>
4821
4822 PR symtab/25833
4823 * dwarf2/read.c (dw2_map_matching_symbols): Handle .gdb_index.
4824
4825 2020-05-20 Alan Modra <amodra@gmail.com>
4826
4827 PR 25993
4828 * solib-darwin.c (darwin_bfd_open): Don't strdup pathname for
4829 bfd_set_filename.
4830 * solib-aix.c (solib_aix_bfd_open): Use std::string for name
4831 passed to bfd_set_filename.
4832 * symfile-mem.c (add_vsyscall_page): Likewise for string
4833 passed to symbol_file_add_from_memory.
4834 (symbol_file_add_from_memory): Make name param a const char* and
4835 don't strdup.
4836
4837 2020-05-20 Alan Modra <amodra@gmail.com>
4838
4839 * coff-pe-read.c (read_pe_exported_syms): Use bfd_get_filename
4840 rather than accessing bfd->filename directly.
4841 * dtrace-probe.c (dtrace_static_probe_ops::get_probes): Likewise,
4842 and use bfd_section_name.
4843 * dwarf2/frame.c (decode_frame_entry): Likewise.
4844 * exec.c (exec_set_section_address): Likewise.
4845 * solib-aix.c (solib_aix_bfd_open): Likewise.
4846 * stap-probe.c (get_stap_base_address): Likewise.
4847 * symfile.c (reread_symbols): Likewise.
4848
4849 2020-05-19 Tom Tromey <tromey@adacore.com>
4850
4851 * sparc64-tdep.c (adi_tag_fd): Update call to target_fileio_open.
4852
4853 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4854
4855 * dwarf2/read.c (quirk_rust_enum): Allocate enough fields.
4856
4857 2020-05-19 Pedro Alves <palves@redhat.com>
4858
4859 * NEWS (set exec-file-mismatch): Adjust entry.
4860 * exec.c: Include "build-id.h".
4861 (validate_exec_file): Try to match build IDs instead of filenames.
4862 * gdb_bfd.c (struct gdb_bfd_open_closure): New.
4863 (gdb_bfd_iovec_fileio_open): Adjust to use gdb_bfd_open_closure
4864 and pass down 'warn_if_slow'.
4865 (gdb_bfd_open): Add 'warn_if_slow' parameter. Use
4866 gdb_bfd_open_closure to pass it down.
4867 * gdb_bfd.h (gdb_bfd_open): Add 'warn_if_slow' parameter.
4868
4869 2020-05-19 Pedro Alves <palves@redhat.com>
4870
4871 * gdb_bfd.c (gdb_bfd_iovec_fileio_open): Adjust.
4872 * target.c (target_fileio_open_1): Rename to target_fileio_open
4873 and make extern. Use bool.
4874 (target_fileio_open, target_fileio_open_warn_if_slow): Delete.
4875 (target_fileio_read_alloc_1): Adjust.
4876 * target.h (target_fileio_open): Add 'warn_if_slow' parameter.
4877 (target_fileio_open_warn_if_slow): Delete declaration.
4878
4879 2020-05-19 Pedro Alves <palves@redhat.com>
4880
4881 * gdb_bfd.h: (gdb_bfd_open): Default to 'fd' parameter to -1.
4882 Adjust all callers.
4883
4884 2020-05-19 Yoshinori Sato <ysato@users.sourceforge.jp>
4885
4886 * h8300-tdep.c (h8300_is_argument_spill): Change how we check
4887 whether disp is negative.
4888
4889 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4890
4891 * symfile.h (struct symfile_segment_data)
4892 <~symfile_segment_data>: Remove.
4893 <segment_info>: Change to std::vector.
4894 * symfile.c (default_symfile_segments): Update.
4895 * elfread.c (elf_symfile_segments): Update.
4896
4897 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4898
4899 * symfile.h (struct symfile_segment_data) <struct segment>: New.
4900 <segments>: New.
4901 <segment_bases, segment_sizes>: Remove.
4902 * symfile.c (default_symfile_segments): Update.
4903 * elfread.c (elf_symfile_segments): Update.
4904 * remote.c (remote_target::get_offsets): Update.
4905 * solib-target.c (solib_target_relocate_section_addresses):
4906 Update.
4907
4908 2020-05-19 Simon Marchi <simon.marchi@efficios.com>
4909
4910 * symfile.h (struct symfile_segment_data): Initialize fields.
4911 <~symfile_segment_data>: Add.
4912 (symfile_segment_data_up): New.
4913 (struct sym_fns) <sym_segments>: Return a
4914 symfile_segment_data_up.
4915 (default_symfile_segments): Return a symfile_segment_data_up.
4916 (free_symfile_segment_data): Remove.
4917 (get_symfile_segment_data): Return a symfile_segment_data_up.
4918 * symfile.c (default_symfile_segments): Likewise.
4919 (get_symfile_segment_data): Likewise.
4920 (free_symfile_segment_data): Remove.
4921 (symfile_find_segment_sections): Update.
4922 * elfread.c (elf_symfile_segments): Return a
4923 symfile_segment_data_up.
4924 * remote.c (remote_target::get_offsets): Update.
4925 * solib-target.c (solib_target_relocate_section_addresses):
4926 Update.
4927 * symfile-debug.c (debug_sym_segments): Return a
4928 symfile_segment_data_up.
4929
4930 2020-05-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4931
4932 PR build/25981
4933 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64] (regmap):
4934 Hardcode register numbers.
4935
4936 PR build/25981
4937 * procfs.c [(__i386__ || __x86_64__) && sun] (proc_get_LDT_entry,
4938 procfs_find_LDT_entry): Remove.
4939 * procfs.h [(__i386__ || __x86_64__) && sun] (struct ssd,
4940 procfs_find_LDT_entry): Remove.
4941 * sol-thread.c [(__i386__ || __x86_64__) && sun] (ps_lgetLDT):
4942 Remove.
4943
4944 2020-05-17 Pedro Alves <palves@redhat.com>
4945 Andrew Burgess <andrew.burgess@embecosm.com>
4946 Keno Fischer <keno@juliacomputing.com>
4947
4948 PR gdb/25741
4949 * breakpoint.c (build_target_condition_list): Update comments.
4950 (build_target_command_list): Update comments and skip matching
4951 locations.
4952 (insert_bp_location): Move "set breakpoint auto-hw on" handling to
4953 a separate function. Simplify "set breakpoint auto-hw off"
4954 handling.
4955 (insert_breakpoints): Update comment.
4956 (tracepoint_locations_match): New parameter. For breakpoints,
4957 compare location types too, if the caller wants to.
4958 (handle_automatic_hardware_breakpoints): New functions.
4959 (bp_location_is_less_than): Also sort by location type and
4960 hardware breakpoint length.
4961 (update_global_location_list): Handle "set breakpoint auto-hw on"
4962 here.
4963 (update_breakpoint_locations): Ask breakpoint_locations_match to
4964 ignore location types.
4965
4966 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4967
4968 * gdbtypes.h (TYPE_NAME): Remove. Change all cal sites to use
4969 type::name instead.
4970
4971 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4972
4973 * gdbtypes.h (struct type) <name, set_name>: New methods.
4974 (TYPE_CODE): Use type::name. Change all call sites used to set
4975 the name to use type::set_name instead.
4976
4977 2020-05-16 Tom Tromey <tom@tromey.com>
4978
4979 * top.c (quit_force): Update.
4980 * infrun.c (handle_no_resumed): Update.
4981 * top.h (all_uis): New function.
4982 (ALL_UIS): Remove.
4983
4984 2020-05-16 Simon Marchi <simon.marchi@efficios.com>
4985
4986 * mips-linux-tdep.c (mips_linux_in_dynsym_stub): Fix condition.
4987
4988 2020-05-16 Pedro Alves <palves@redhat.com>
4989
4990 * ia64-linux-nat.c
4991 (ia64_linux_nat_target) <enable_watchpoints_in_psr(ptid_t)>:
4992 Declare method.
4993 (enable_watchpoints_in_psr): Now a method of ia64_linux_nat_target.
4994
4995 2020-05-15 Simon Marchi <simon.marchi@efficios.com>
4996
4997 * sparc64-tdep.c (adi_stat_t): Remove typedef (leaving struct).
4998 (sparc64_adi_info): Likewise.
4999
5000 2020-05-15 Tom Tromey <tom@tromey.com>
5001
5002 * symtab.c (lookup_language_this, lookup_symbol_aux): Use
5003 block_objfile.
5004 (lookup_objfile_from_block): Remove.
5005 (lookup_symbol_in_block, lookup_symbol_in_static_block)
5006 (lookup_global_symbol): Use block_objfile.
5007 * symtab.h (lookup_objfile_from_block): Don't declare.
5008 * printcmd.c (clear_dangling_display_expressions): Use
5009 block_objfile.
5010 * parse.c (operator_check_standard): Use block_objfile.
5011
5012 2020-05-15 Tom Tromey <tom@tromey.com>
5013
5014 * language.c (language_alloc_type_symbol): Set
5015 SYMBOL_SECTION.
5016 * symtab.c (initialize_objfile_symbol): Remove.
5017 (allocate_symbol): Remove.
5018 (allocate_template_symbol): Remove.
5019 * dwarf2/read.c (fixup_go_packaging): Use "new".
5020 (new_symbol): Use "new".
5021 (read_variable): Don't call initialize_objfile_symbol. Use
5022 "new".
5023 (read_func_scope): Use "new".
5024 * xcoffread.c (process_xcoff_symbol): Don't call
5025 initialize_objfile_symbol.
5026 (SYMBOL_DUP): Remove.
5027 * coffread.c (process_coff_symbol, coff_read_enum_type): Use
5028 "new".
5029 * symtab.h (allocate_symbol, initialize_objfile_symbol)
5030 (allocate_template_symbol): Don't declare.
5031 (struct symbol): Add copy constructor. Change defaults.
5032 * jit.c (finalize_symtab): Use "new".
5033 * ctfread.c (ctf_add_enum_member_cb, new_symbol, ctf_add_var_cb):
5034 Use "new".
5035 * stabsread.c (patch_block_stabs, define_symbol, read_enum_type)
5036 (common_block_end): Use "new".
5037 * mdebugread.c (parse_symbol): Use "new".
5038 (new_symbol): Likewise.
5039
5040 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5041
5042 * NEWS: Mention changes to help and apropos.
5043
5044 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5045
5046 * command.h (enum command_class): Improve comments, document
5047 that class_alias is for user-defined aliases, give the class
5048 name for each class, remove unused class_xdb.
5049 * cli/cli-decode.c (add_com_alias): Document THECLASS intended usage.
5050 * breakpoint.c (_initialize_breakpoint): Replace class_alias
5051 by a precise class.
5052 * infcmd.c (_initialize_infcmd): Likewise.
5053 * reverse.c (_initialize_reverse): Likewise.
5054 * stack.c (_initialize_stack): Likewise.
5055 * symfile.c (_initialize_symfile): Likewise.
5056 * tracepoint.c (_initialize_tracepoint): Likewise.
5057
5058 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5059
5060 * cli/cli-decode.c (apropos_cmd): Produce output for aliases
5061 when their aliased command is traversed.
5062 (help_cmd): Add fput_command_names_styled call to
5063 output command name and aliases when command has an alias.
5064
5065 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5066
5067 * cli/cli-decode.h (help_cmd_list): Remove declaration.
5068 * cli/cli-decode.c (help_cmd_list): Declare as static,
5069 remove prefix argument, use bool for recurse arg, rework to show the aliases of
5070 a command together with the command.
5071 (fput_command_name_styled, fput_command_names_styled): New functions.
5072 (print_help_for_command): Remove prefix arg, use bool for recurse arg, use
5073 fput_command_name_styled.
5074 (help_list, help_all): Update callers to remove prefix arg and use bool recurse.
5075 * cli/cli-cmds.c (_initialize_cli_cmds): Update alias_command doc.
5076
5077 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5078
5079 * cli/cli-setshow.h (cmd_show_list): Remove prefix argument.
5080 * cli/cli-decode.c (do_show_prefix_cmd): Likewise.
5081 * command.h (cmd_show_list): Likewise.
5082 * dwarf2/index-cache.c (show_index_cache_command): Likewise.
5083 * cli/cli-setshow.c (cmd_show_list): Use the prefix to produce the output. Skip aliases.
5084
5085 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5086
5087 * unittests/command-def-selftests.c (traverse_command_structure):
5088 Verify all commands of a list have the same prefix command and
5089 that only the top cmdlist commands have a null prefix.
5090
5091 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5092
5093 * cli/cli-decode.c (lookup_cmd_for_prefix): Return the aliased command
5094 as prefix, not one of its aliases.
5095 (set_cmd_prefix): Remove.
5096 (do_add_cmd): Centralize the setting of the prefix of a command, when
5097 command is defined after its full chain of prefix commands.
5098 (add_alias_cmd): Remove call to set_cmd_prefix, as do_add_cmd does it.
5099 (add_setshow_cmd_full): Likewise.
5100 (update_prefix_field_of_prefixed_commands): New function.
5101 (add_prefix_cmd): Replace non working call to set_cmd_prefix by
5102 update_prefix_field_of_prefixed_commands.
5103 * gdb/remote-fileio.c (initialize_remote_fileio): Use the real
5104 addresses of remote_set_cmdlist and remote_show_cmdlist given
5105 as argument, not the address of an argument.
5106 * gdb/remote-fileio.h (initialize_remote_fileio): Likewise.
5107 * gdb/remote.c (_initialize_remote): Likewise.
5108
5109 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5110
5111 * cli/cli-cmds.c (alias_command): Check for an existing alias
5112 using lookup_cmd_composition, as valid_command_p is too strict
5113 and forbids aliases that are the prefix of an existing alias
5114 or command.
5115 * cli/cli-decode.c (lookup_cmd_composition): Ensure a prefix
5116 command is properly recognised as a valid command.
5117
5118 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5119
5120 * unittests/help-doc-selftests.c: Rename to
5121 unittests/command-def-selftests.c
5122 * unittests/command-def-selftests.c (help_doc_tests): Update some
5123 comments.
5124 (command_structure_tests, traverse_command_structure): New namespace
5125 and function.
5126 (command_structure_invariants_tests): New function.
5127 (_initialize_command_def_selftests) Renamed from
5128 _initialize_help_doc_selftests, register command_structure_invariants
5129 selftest.
5130
5131 2020-05-15 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5132
5133 * cli/cli-cmds.c (_initialize_cli_cmds): Define 'info set' as
5134 an alias of 'show'.
5135
5136 2020-05-15 Joel Brobecker <brobecker@adacore.com>
5137
5138 * ada-lang.h: (ada_is_gnat_encoded_fixed_point_type): Renames
5139 ada_is_fixed_point_type. Update all callers.
5140 (gnat_encoded_fixed_point_delta): Renames ada_delta. Update
5141 all callers.
5142 * ada-lang.c (gnat_encoded_fixed_type_info): Renames fixed_type_info.
5143 Update all callers.
5144 * ada-typeprint.c (print_gnat_encoded_fixed_point_type): Renames
5145 print_fixed_point_type. Update all callers.
5146 * ada-valprint.c (ada_value_print_num): Replace call to
5147 ada_is_fixed_point_type by ada_is_gnat_encoded_fixed_point_type.
5148
5149 2020-05-14 Kevin Buettner <kevinb@redhat.com>
5150
5151 * nat/linux-btrace.c (btrace_this_cpu): Add check for AMD
5152 processors.
5153 (cpu_supports_bts): Add CV_AMD case.
5154
5155 2020-05-14 Laurent Morichetti <Laurent.Morichetti@amd.com>
5156 Simon Marchi <simon.marchi@efficios.com>
5157
5158 * infrun.c (stop_all_threads): Collect multiple wait events at
5159 each pass.
5160
5161 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
5162
5163 * gdbtypes.h (TYPE_CODE): Remove. Change all call sites to use
5164 type::code instead.
5165
5166 2020-05-14 Simon Marchi <simon.marchi@efficios.com>
5167
5168 * gdbtypes.h (struct type) <code, set_code>: New methods.
5169 (TYPE_CODE): Use type::code. Change all call sites used to set
5170 the code to use type::set_code instead.
5171
5172 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5173 Tom de Vries <tdevries@suse.de>
5174 Pedro Alves <palves@redhat.com>
5175
5176 PR threads/25478
5177 * infrun.c (stop_all_threads): Do NOT ignore
5178 TARGET_WAITKIND_NO_RESUMED, TARGET_WAITKIND_THREAD_EXITED,
5179 TARGET_WAITKIND_EXITED, TARGET_WAITKIND_SIGNALLED wait statuses
5180 received.
5181 (handle_no_resumed): Remove code handling a live inferior with no
5182 threads.
5183 * remote.c (has_single_non_exited_thread): New.
5184 (remote_target::update_thread_list): Do not delete a thread if is
5185 the last thread of the process.
5186 * thread.c (thread_select): Call delete_exited_threads instead of
5187 prune_threads.
5188
5189 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5190
5191 * infrun.c (stop_all_threads): Enable/disable thread events of all
5192 targets. Move a debug message denoting the end of the function
5193 into the SCOPED_EXIT block.
5194
5195 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5196
5197 * process-stratum-target.h: Include <set>.
5198 (all_non_exited_process_targets, switch_to_target_no_thread): New
5199 function declarations.
5200 * process-stratum-target.c (all_non_exited_process_targets)
5201 (switch_to_target_no_thread): New function implementations.
5202
5203 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5204
5205 * infrun.c (handle_inferior_event): Extract out a piece of code
5206 into...
5207 (mark_non_executing_threads): ...this new function.
5208
5209 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5210
5211 * infrun.c (resume_1): Move a 'regcache_read_pc' call down to first
5212 use.
5213
5214 2020-05-14 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5215
5216 * regcache.c (regcache_read_pc_protected): New function
5217 implementation that returns 0 if the PC cannot read via
5218 'regcache_read_pc'.
5219 * infrun.c (proceed): Call 'regcache_read_pc_protected'
5220 instead of 'regcache_read_pc'.
5221 (keep_going_pass_signal): Ditto.
5222
5223 2020-05-13 Tom Tromey <tromey@adacore.com>
5224
5225 * ada-lang.c (align_value): Remove.
5226 (ada_template_to_fixed_record_type_1): Use align_up.
5227
5228 2020-05-13 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5229
5230 * async-event.c: Update the copyright year.
5231 * async-event.h: Update the copyright year.
5232
5233 2020-05-12 Simon Marchi <simon.marchi@efficios.com>
5234
5235 * objfiles.h (is_addr_in_objfile,
5236 shared_objfile_contains_address_p): Return bool.
5237 * objfile.c (is_addr_in_objfile,
5238 shared_objfile_contains_address_p): Return bool.
5239
5240 2020-05-11 Tom Tromey <tromey@adacore.com>
5241
5242 * cli/cli-cmds.c (info_command): Restore.
5243 (_initialize_cli_cmds): Use add_prefix_command for "info".
5244 * gdb-gdb.gdb.in: Restore breakpoint on info_command.
5245
5246 2020-05-11 Tom Tromey <tromey@adacore.com>
5247
5248 * ada-lang.c (ada_value_primitive_field): Now public.
5249 * ada-lang.h (ada_value_primitive_field): Declare.
5250 * ada-valprint.c (print_field_values): Use
5251 ada_value_primitive_field for wrapper fields.
5252
5253 2020-05-11 Tom de Vries <tdevries@suse.de>
5254
5255 * dwarf2/index-write.c (debug_names::psymbol_tag): Handle
5256 MODULE_DOMAIN.
5257
5258 2020-05-11 Tom de Vries <tdevries@suse.de>
5259
5260 PR symtab/25941
5261 * dwarf2/read.c (create_cus_from_debug_names_list): Initialize CUs
5262 with length 0, if not gdb-produced.
5263 (cutu_reader::cutu_reader): Set CU length to actual length if 0.
5264
5265 2020-05-09 Tom de Vries <tdevries@suse.de>
5266
5267 PR gdb/25955
5268 * break-catch-throw.c (check_status_exception_catchpoint): Fix name
5269 calculation.
5270
5271 2020-05-09 Tom Tromey <tom@tromey.com>
5272
5273 * top.c (server_command): Now bool.
5274 * top.h (server_command): Now bool.
5275
5276 2020-05-08 Tom Tromey <tromey@adacore.com>
5277
5278 * dwarf2/read.c (read_lexical_block_scope): Don't process a DIE
5279 already being processed.
5280
5281 2020-05-08 Tom Tromey <tom@tromey.com>
5282
5283 * printcmd.c (struct display) <next>: Remove.
5284 <display>: New constructor.
5285 <exp_string>: Now a std::string.
5286 <enabled_p>: Now a bool.
5287 (display_number): Move definition earlier.
5288 (displays): Rename from display_chain. Now a std::vector.
5289 (ALL_DISPLAYS, ALL_DISPLAYS_SAFE): Remove.
5290 (display_command): Update.
5291 (do_one_display, disable_display)
5292 (enable_disable_display_command, do_enable_disable_display):
5293 Update.
5294 (free_display): Remove.
5295 (clear_displays): Rewrite.
5296 (delete_display): Update.
5297 (map_display_numbers): Use function_view. Remove "data"
5298 parameter. Update.
5299 (do_delete_display): Remove.
5300 (undisplay_command): Update.
5301 (do_one_display, do_displays, disable_display)
5302 (info_display_command): Update.
5303 (do_enable_disable_display): Remove.
5304 (enable_disable_display_command)
5305 (clear_dangling_display_expressions): Update.
5306
5307 2020-05-08 Tom Tromey <tom@tromey.com>
5308
5309 * symtab.c (set_symbol_cache_size)
5310 (maintenance_print_symbol_cache, maintenance_flush_symbol_cache)
5311 (maintenance_print_symbol_cache_statistics): Update.
5312 * symmisc.c (print_symbol_bcache_statistics)
5313 (print_objfile_statistics, maintenance_print_objfiles)
5314 (maintenance_info_symtabs, maintenance_check_symtabs)
5315 (maintenance_expand_symtabs, maintenance_info_line_tables):
5316 Update.
5317 * symfile-debug.c (set_debug_symfile): Update.
5318 * source.c (forget_cached_source_info): Update.
5319 * python/python.c (gdbpy_progspaces): Update.
5320 * psymtab.c (maintenance_info_psymtabs): Update.
5321 * probe.c (parse_probes): Update.
5322 * linespec.c (iterate_over_all_matching_symtabs)
5323 (collect_symtabs_from_filename, search_minsyms_for_name): Update.
5324 * guile/scm-progspace.c (gdbscm_progspaces): Update.
5325 * exec.c (exec_target::close): Update.
5326 * ada-tasks.c (ada_tasks_new_objfile_observer): Update.
5327 * breakpoint.c (print_one_breakpoint_location)
5328 (create_longjmp_master_breakpoint)
5329 (create_std_terminate_master_breakpoint): Update.
5330 * progspace.c (program_spaces): Now a std::vector.
5331 (maybe_new_address_space): Update.
5332 (add_program_space): Remove.
5333 (program_space::program_space): Update.
5334 (remove_program_space): Update.
5335 (number_of_program_spaces): Remove.
5336 (print_program_space, update_address_spaces): Update.
5337 * progspace.h (program_spaces): Change type.
5338 (ALL_PSPACES): Remove.
5339 (number_of_program_spaces): Don't declare.
5340 (struct program_space) <next>: Remove.
5341
5342 2020-05-08 Tom Tromey <tom@tromey.com>
5343
5344 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Update.
5345 * solib-svr4.c (svr4_fetch_objfile_link_map): Update.
5346 (enable_break): Update.
5347 * solib-frv.c (frv_fdpic_find_global_pointer): Update.
5348 (frv_fdpic_find_canonical_descriptor): Update.
5349 (frv_fetch_objfile_link_map): Update.
5350 * progspace.c (program_space::free_all_objfiles): Update.
5351 (program_space::solibs): New method.
5352 * progspace.h (struct program_space) <solibs>: New method.
5353 * solist.h (master_so_list): Don't declare.
5354 (ALL_SO_LIBS): Remove.
5355 * solib.h (so_list_head): Remove.
5356 (update_solib_list): Update comment.
5357 * solib.c (master_so_list): Remove.
5358 (solib_used, update_solib_list, solib_add)
5359 (info_sharedlibrary_command, clear_solib)
5360 (reload_shared_libraries_1, remove_user_added_objfile): Update.
5361
5362 2020-05-08 Tom Tromey <tom@tromey.com>
5363
5364 * extension.c (extension_languages): Now a std::array.
5365 (ALL_EXTENSION_LANGUAGES): Remove.
5366 (get_ext_lang_defn, get_ext_lang_of_file)
5367 (eval_ext_lang_from_control_command): Update.
5368 (finish_ext_lang_initialization)
5369 (auto_load_ext_lang_scripts_for_objfile)
5370 (ext_lang_type_printers::ext_lang_type_printers)
5371 (apply_ext_lang_type_printers)
5372 (ext_lang_type_printers::~ext_lang_type_printers)
5373 (apply_ext_lang_val_pretty_printer, apply_ext_lang_frame_filter)
5374 (preserve_ext_lang_values, get_breakpoint_cond_ext_lang)
5375 (breakpoint_ext_lang_cond_says_stop, check_quit_flag)
5376 (get_matching_xmethod_workers, ext_lang_colorize)
5377 (ext_lang_before_prompt): Update.
5378 (ALL_ENABLED_EXTENSION_LANGUAGES): Remove.
5379
5380 2020-05-08 Tom Tromey <tom@tromey.com>
5381
5382 * symtab.h (class demangle_result_storage) <set_malloc_ptr>: New
5383 overload.
5384 <swap_string, m_string>: Remove.
5385 * symtab.c (demangle_for_lookup, completion_list_add_symbol):
5386 Update.
5387 * stabsread.c (define_symbol, read_type): Update.
5388 * linespec.c (find_linespec_symbols): Update.
5389 * gnu-v3-abi.c (gnuv3_get_typeid): Update.
5390 * dwarf2/read.c (dwarf2_canonicalize_name): Update.
5391 * dbxread.c (read_dbx_symtab): Update.
5392 * cp-support.h (cp_canonicalize_string_full)
5393 (cp_canonicalize_string, cp_canonicalize_string_no_typedefs):
5394 Return unique_xmalloc_ptr.
5395 * cp-support.c (inspect_type): Update.
5396 (cp_canonicalize_string_full): Return unique_xmalloc_ptr.
5397 (cp_canonicalize_string_no_typedefs, cp_canonicalize_string):
5398 Likewise.
5399 * c-typeprint.c (print_name_maybe_canonical): Update.
5400 * break-catch-throw.c (check_status_exception_catchpoint):
5401 Update.
5402
5403 2020-05-08 Tom de Vries <tdevries@suse.de>
5404
5405 * infrun.c (follow_fork): Copy current_line and current_symtab to
5406 child thread.
5407
5408 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5409
5410 * async-event.c (struct async_signal_handler, struct
5411 async_event_handler): Reformat, remove typedef.
5412
5413 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5414
5415 * gdbtypes.h (TYPE_DYN_PROP_LIST): Remove. Update all users
5416 access thistype->main_type->dyn_prop_list directly.
5417
5418 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5419
5420 * gdbtypes.h (struct type) <remove_dyn_prop>: New method.
5421 (remove_dyn_prop): Remove. Update all users to use
5422 type::remove_dyn_prop.
5423 * gdbtypes.c (remove_dyn_prop): Rename to...
5424 (type::remove_dyn_prop): ... this.
5425
5426 2020-05-07 Simon Marchi via Gdb-patches <gdb-patches@sourceware.org>
5427
5428 * gdbtypes.h (struct type) <add_dyn_prop>: New method.
5429 (add_dyn_prop): Remove. Update all users to use
5430 type::add_dyn_prop.
5431 * gdbtypes.c (add_dyn_prop): Rename to...
5432 (type::add_dyn_prop): ... this.
5433
5434 2020-05-07 Simon Marchi <simon.marchi@efficios.com>
5435
5436 * gdbtypes.h (struct type) <get_dyn_prop>: New method.
5437 (get_dyn_prop): Remove. Update all users to use
5438 type::dyn_prop.
5439 * gdbtypes.c (get_dyn_prop): Rename to...
5440 (type::dyn_prop): ... this.
5441
5442 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
5443
5444 * gdbtypes.h (struct main_type) <flag_static>: Remove.
5445
5446 2020-05-06 Simon Marchi <simon.marchi@efficios.com>
5447
5448 * amd64-tdep.c (amd64_analyze_prologue): Check for `endbr64`
5449 instruction, skip it if it's there.
5450
5451 2020-05-05 Simon Marchi <simon.marchi@efficios.com>
5452
5453 * gdbtypes.h (struct main_type) <flag_incomplete>: Remove.
5454
5455 2020-05-04 Simon Marchi <simon.marchi@efficios.com>
5456
5457 * gdbtypes.h (TYPE_INCOMPLETE): Remove.
5458 * gdbtypes.c (recursive_dump_type): Remove use of
5459 TYPE_INCOMPLETE.
5460
5461 2020-05-03 Tom Tromey <tom@tromey.com>
5462
5463 * breakpoint.c (catch_command, tcatch_command): Remove.
5464 (_initialize_breakpoint): Use add_basic_prefix_cmd,
5465 add_show_prefix_cmd.
5466 (set_breakpoint_cmd, show_breakpoint_cmd): Remove
5467 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5468 Remove.
5469 (add_internal_problem_command): Use add_basic_prefix_cmd,
5470 add_show_prefix_cmd.
5471 * mips-tdep.c (set_mipsfpu_command): Remove.
5472 (_initialize_mips_tdep): Use add_basic_prefix_cmd.
5473 * dwarf2/index-cache.c (set_index_cache_command): Remove.
5474 (_initialize_index_cache): Use add_basic_prefix_cmd.
5475 * memattr.c (dummy_cmd): Remove.
5476 (_initialize_mem): Use add_basic_prefix_cmd, add_show_prefix_cmd.
5477 * tui/tui-win.c (set_tui_cmd, show_tui_cmd): Remove.
5478 (_initialize_tui_win): Use add_basic_prefix_cmd,
5479 add_show_prefix_cmd.
5480 * cli/cli-logging.c (set_logging_command): Remove.
5481 (_initialize_cli_logging): Use add_basic_prefix_cmd,
5482 add_show_prefix_cmd.
5483 (show_logging_command): Remove.
5484 * target.c (target_command): Remove.
5485 (add_target): Use add_basic_prefix_cmd.
5486
5487 2020-05-02 Hannes Domani <ssbssa@yahoo.de>
5488
5489 * gdbtypes.h (enum dynamic_prop_node_kind): Fix typo.
5490
5491 2020-05-01 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5492
5493 * gdb-gdb.gdb-in: Remove breakpoint on disappeared function
5494 info_command.
5495
5496 2020-04-30 Kamil Rytarowski <n54@gmx.com>
5497
5498 * nbsd-nat.c (nbsd_enable_proc_events)
5499 (nbsd_nat_target::post_startup_inferior): Add.
5500 (nbsd_nat_target::post_attach): Call `nbsd_enable_proc_events'.
5501 (nbsd_nat_target::update_thread_list): Rewrite.
5502 (nbsd_nat_target::wait): Handle "PTRACE_LWP_EXIT" and
5503 "PTRACE_LWP_CREATE".
5504 * nbsd-nat.h (nbsd_nat_target::post_startup_inferior): Add.
5505
5506 2020-04-30 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5507
5508 * stack.c (_initialize_stack): Remove duplicated creation
5509 of "frame" command and "f" alias.
5510
5511 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
5512
5513 PR gdb/18706
5514 * gdbtypes.c (check_typedef): Calculate size of array of
5515 stubbed type.
5516
5517 2020-04-30 Hannes Domani <ssbssa@yahoo.de>
5518
5519 PR gdb/15559
5520 * i386-tdep.c (i386_push_dummy_call): Call
5521 i386_thiscall_push_dummy_call.
5522 (i386_thiscall_push_dummy_call): New function.
5523 * i386-tdep.h (i386_thiscall_push_dummy_call): Declare.
5524 * i386-windows-tdep.c (i386_windows_push_dummy_call): New function.
5525 (i386_windows_init_abi): Call set_gdbarch_push_dummy_call.
5526
5527 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5528
5529 * gdbarch.sh (do_read): Add shellcheck disable directive for
5530 warning SC2162.
5531
5532 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5533
5534 * gdbarch.sh: Use ${foo:-} where shellcheck would report a
5535 "referenced but not assigned" warning.
5536
5537 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5538
5539 * gdbarch.sh: Remove code that sets fallbackdefault.
5540
5541 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5542
5543 * gdbarch.sh: Use shell operators && and || instead of
5544 -a and -o.
5545
5546 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5547
5548 * gdbarch.sh: Use $(...) instead of `...`.
5549
5550 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5551
5552 * gdbarch.sh: Use double quotes around variables.
5553
5554 2020-04-29 Simon Marchi <simon.marchi@efficios.com>
5555
5556 * gdbarch.sh: Use %s with printf, instead of variables in the
5557 format string.
5558
5559 2020-04-29 Tom Tromey <tromey@adacore.com>
5560
5561 PR ada/25875:
5562 * dwarf2/read.c (update_enumeration_type_from_children): Compute
5563 type fields here.
5564 (read_enumeration_type): Call
5565 update_enumeration_type_from_children later. Update comments.
5566 (process_enumeration_scope): Don't create type fields.
5567
5568 2020-04-29 Kamil Rytarowski <n54@gmx.com>
5569
5570 * nbsd-tdep.c: Include "xml-syscall.h".
5571 (nbsd_init_abi): Call `set_xml_syscall_file_name'.
5572
5573 2020-04-29 Kamil Rytarowski <n54@gmx.com>
5574
5575 * nbsd-nat.c: Include "sys/wait.h".
5576 (nbsd_resume, nbsd_nat_target::resume, nbsd_wait)
5577 (nbsd_nat_target::wait, nbsd_nat_target::insert_exec_catchpoint)
5578 (nbsd_nat_target::remove_exec_catchpoint)
5579 (nbsd_nat_target::set_syscall_catchpoint): Add.
5580 * nbsd-nat.h (nbsd_nat_target::resume, nbsd_nat_target::wait)
5581 (nbsd_nat_target::insert_exec_catchpoint)
5582 (nbsd_nat_target::remove_exec_catchpoint)
5583 (nbsd_nat_target::set_syscall_catchpoint): Add.
5584 * nbsd-tdep.c (nbsd_get_syscall_number): Add.
5585 (nbsd_init_abi): Call `set_gdbarch_get_syscall_number' and pass
5586 `nbsd_get_syscall_number'.
5587
5588 2020-04-29 Tom Tromey <tom@tromey.com>
5589
5590 * stack.c (print_block_frame_labels): Remove.
5591
5592 2020-04-29 Hannes Domani <ssbssa@yahoo.de>
5593
5594 PR gdb/17320
5595 * ada-valprint.c (val_print_packed_array_elements): Move array
5596 end bracket to new line.
5597 (ada_val_print_string): Remove extra spaces before first array
5598 element.
5599 * c-valprint.c (c_value_print_array): Likewise.
5600 * m2-valprint.c (m2_print_array_contents): Likewise.
5601 (m2_value_print_inner): Likewise.
5602 * p-valprint.c (pascal_value_print_inner): Likewise.
5603 * valprint.c (generic_val_print_array): Likewise.
5604 (value_print_array_elements): Move first array element and array
5605 end bracket to new line.
5606
5607 2020-04-29 Tom de Vries <tdevries@suse.de>
5608
5609 PR symtab/25889
5610 * linespec.c (find_method): Fix ix calculation.
5611
5612 2020-04-28 Kamil Rytarowski <n54@gmx.com>
5613
5614 * syscalls/update-netbsd.sh: New file.
5615 * syscalls/netbsd.xml: Regenerate.
5616 * data-directory/Makefile.in: Register `netbsd.xml' in
5617 `SYSCALLS_FILES'.
5618
5619 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
5620
5621 * syscalls/update-freebsd.sh: Add double quotes.
5622
5623 2020-04-28 Tom Tromey <tom@tromey.com>
5624
5625 * NEWS: Update.
5626 * python/py-cmd.c (gdbpy_initialize_commands): Add COMMAND_TUI.
5627 (cmdpy_init): Allow class_tui.
5628
5629 2020-04-28 Mark Williams <mark@myosotissp.com>
5630
5631 PR gdb/24480
5632 * dwarf2read.c: Add missing assingments to list_in_scope when
5633 start_symtab was already called.
5634
5635 2020-04-28 Simon Marchi <simon.marchi@efficios.com>
5636
5637 PR gdb/25881
5638 * dwarf2/read.c (offset_map_type): Use
5639 gdb:hash_enum<sect_offset> as hash function.
5640
5641 2020-04-28 Tom de Vries <tdevries@suse.de>
5642
5643 * dwarf2/read.c (process_structure_scope): Add symbol for struct decl
5644 with DW_AT_signature.
5645
5646 2020-04-27 Simon Marchi <simon.marchi@efficios.com>
5647
5648 * configure.ac: Remove check for fs_base/gs_base in
5649 user_regs_struct.
5650 * configure: Re-generate.
5651 * config.in: Re-generate.
5652 * amd64-nat.c (amd64_native_gregset_reg_offset): Adjust.
5653 * amd64-linux-nat.c (amd64_linux_nat_target::fetch_registers,
5654 amd64_linux_nat_target::store_registers, ps_get_thread_area, ): Adjust.
5655
5656 2020-04-27 Luis Machado <luis.machado@linaro.org>
5657
5658 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Handle
5659 problematic inline frame unwinding situation.
5660 * frame.c (frame_id_computed_p): New function.
5661 * frame.h (frame_id_computed_p): New prototype.
5662
5663 2020-04-26 Tom Tromey <tom@tromey.com>
5664
5665 * command.h (enum command_class) <class_pseudo>: Remove.
5666
5667 2020-04-26 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5668
5669 * cli/cli-decode.c (lookup_cmd_composition): Fix comments
5670 and whitespace.
5671
5672 2020-04-25 Kamil Rytarowski <n54@gmx.com>
5673
5674 * inf-ptrace.c (inf_ptrace_target::wait): Remove
5675 `PT_GET_PROCESS_STATE' block.
5676
5677 2020-04-24 Tom Tromey <tom@tromey.com>
5678
5679 * symtab.h (symbol_get_demangled_name): Don't declare.
5680 * symtab.c (symbol_get_demangled_name): Remove.
5681 (general_symbol_info::natural_name)
5682 (general_symbol_info::demangled_name): Update.
5683
5684 2020-04-24 Tom Tromey <tom@tromey.com>
5685
5686 PR rust/25025:
5687 * dwarf2/read.c (dwarf2_physname): Do not demangle for Rust.
5688
5689 2020-04-24 Tom Tromey <tom@tromey.com>
5690
5691 PR symtab/12707:
5692 * dwarf2/read.c (add_partial_symbol): Use the linkage name if it
5693 exists.
5694 (new_symbol): Likewise.
5695 * compile/compile-object-load.c (get_out_value_type): Use
5696 symbol_matches_search_name.
5697
5698 2020-04-24 Tom Tromey <tom@tromey.com>
5699
5700 * dwarf2/read.c (add_partial_symbol): Do not call
5701 compute_and_set_names.
5702
5703 2020-04-24 Tom Tromey <tom@tromey.com>
5704
5705 * dwarf2/read.c (add_partial_symbol): Use new add_psymbol_to_list
5706 overload.
5707
5708 2020-04-24 Tom Tromey <tom@tromey.com>
5709
5710 * psymtab.c (add_psymbol_to_bcache): Simplify calling convention.
5711 (add_psymbol_to_list): New overload. Make old overload call new
5712 one.
5713 * psympriv.h (add_psymbol_to_list): New overload.
5714
5715 2020-04-24 Tom Tromey <tom@tromey.com>
5716
5717 * dwarf2/read.c (partial_die_info::read) <case
5718 DW_AT_linkage_name>: Use value_as_string.
5719 (dwarf2_string_attr): Use value_as_string.
5720 * dwarf2/attribute.h (struct attribute) <value_as_string>: Declare
5721 method.
5722 * dwarf2/attribute.c (attribute::value_as_string): New method.
5723
5724 2020-04-24 Tom Tromey <tom@tromey.com>
5725
5726 * symtab.c (general_symbol_info::natural_name)
5727 (general_symbol_info::demangled_name): Check for language_rust.
5728
5729 2020-04-24 Tom Tromey <tom@tromey.com>
5730
5731 * dwarf2/read.c (dw2_linkage_name): Move Rust "{" hack here...
5732 (dwarf2_physname): ... from here.
5733 (partial_die_info::read): Add Rust "{" hack.
5734
5735 2020-04-24 Tom Tromey <tom@tromey.com>
5736
5737 * symtab.h (struct general_symbol_info) <set_demangled_name>: New
5738 method.
5739 (symbol_set_demangled_name): Don't declare.
5740 * symtab.c (general_symbol_info::set_demangled_name): Rename from
5741 symbol_set_demangled_name.
5742 (general_symbol_info::set_language)
5743 (general_symbol_info::compute_and_set_names): Update.
5744 * minsyms.c (minimal_symbol_reader::install): Update.
5745 * dwarf2/read.c (new_symbol): Update.
5746
5747 2020-04-24 Tom Tromey <tromey@adacore.com>
5748
5749 PR python/23662:
5750 * python/py-type.c (convert_field): Handle
5751 FIELD_LOC_KIND_DWARF_BLOCK.
5752 (typy_get_sizeof): Handle TYPE_HAS_DYNAMIC_LENGTH.
5753 (typy_get_dynamic): Nw function.
5754 (type_object_getset): Add "dynamic".
5755 * NEWS: Add entry.
5756
5757 2020-04-24 Tom Tromey <tromey@adacore.com>
5758
5759 * ada-typeprint.c (print_choices, print_variant_part)
5760 (print_record_field_types_dynamic): New functions.
5761 (print_record_field_types): Use print_record_field_types_dynamic.
5762
5763 2020-04-24 Tom Tromey <tromey@adacore.com>
5764
5765 * dwarf2/read.c (handle_data_member_location): New overload.
5766 (dwarf2_add_field): Use it.
5767 (decode_locdesc): Add "computed" parameter. Update comment.
5768 * gdbtypes.c (is_dynamic_type_internal): Also look for
5769 FIELD_LOC_KIND_DWARF_BLOCK.
5770 (resolve_dynamic_struct): Handle FIELD_LOC_KIND_DWARF_BLOCK.
5771 * gdbtypes.c (is_dynamic_type_internal): Add special case for C++
5772 virtual base classes.
5773 * gnu-v3-abi.c (gnuv3_baseclass_offset): Handle
5774 FIELD_LOC_KIND_DWARF_BLOCK.
5775
5776 2020-04-24 Tom Tromey <tromey@adacore.com>
5777
5778 * dwarf2/read.c (read_structure_type): Handle dynamic length.
5779 * gdbtypes.c (is_dynamic_type_internal): Check
5780 TYPE_HAS_DYNAMIC_LENGTH.
5781 (resolve_dynamic_type_internal): Use TYPE_DYNAMIC_LENGTH.
5782 * gdbtypes.h (TYPE_HAS_DYNAMIC_LENGTH, TYPE_DYNAMIC_LENGTH):
5783 New macros.
5784 (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_SIZE>: New
5785 constant.
5786
5787 2020-04-24 Tom Tromey <tromey@adacore.com>
5788
5789 * dwarf2/read.c (struct variant_field): Rewrite.
5790 (struct variant_part_builder): New.
5791 (struct nextfield): Remove "variant" field. Add "offset".
5792 (struct field_info): Add "current_variant_part" and
5793 "variant_parts".
5794 (alloc_discriminant_info): Remove.
5795 (alloc_rust_variant): New function.
5796 (quirk_rust_enum): Update.
5797 (dwarf2_add_field): Set "offset" member. Don't handle
5798 DW_TAG_variant_part.
5799 (offset_map_type): New typedef.
5800 (convert_variant_range, create_one_variant)
5801 (create_one_variant_part, create_variant_parts)
5802 (add_variant_property): New functions.
5803 (dwarf2_attach_fields_to_type): Call add_variant_property.
5804 (read_structure_type): Don't handle DW_TAG_variant_part.
5805 (handle_variant_part, handle_variant): New functions.
5806 (handle_struct_member_die): Use them.
5807 (process_structure_scope): Don't handle variant parts.
5808 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): Remove.
5809 (struct discriminant_info): Remove.
5810 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: Remove.
5811 (struct main_type) <flag_discriminated_union>: Remove.
5812 * rust-lang.c (rust_enum_p, rust_empty_enum_p): Rewrite.
5813 (rust_enum_variant): Return int. Remove "contents". Rewrite.
5814 (rust_print_enum, rust_print_struct_def, rust_evaluate_subexp):
5815 Update.
5816 * valops.c (value_union_variant): Remove.
5817 * value.h (value_union_variant): Don't declare.
5818
5819 2020-04-24 Tom Tromey <tromey@adacore.com>
5820
5821 * ada-lang.c (ada_discrete_type_high_bound, ada_discrete_type_low)
5822 (ada_value_primitive_packed_val): Update.
5823 * ada-valprint.c (ada_value_print_1): Update.
5824 * dwarf2/loc.c (evaluate_for_locexpr_baton): New struct.
5825 (dwarf2_locexpr_baton_eval): Take a property_addr_info rather than
5826 just an address. Use evaluate_for_locexpr_baton.
5827 (dwarf2_evaluate_property): Update.
5828 * dwarf2/loc.h (struct property_addr_info) <valaddr>: Now an
5829 array_view.
5830 * findvar.c (default_read_var_value): Update.
5831 * gdbtypes.c (compute_variant_fields_inner)
5832 (resolve_dynamic_type_internal): Update.
5833 (resolve_dynamic_type): Change type of valaddr parameter.
5834 * gdbtypes.h (resolve_dynamic_type): Update.
5835 * valarith.c (value_subscripted_rvalue): Update.
5836 * value.c (value_from_contents_and_address): Update.
5837
5838 2020-04-24 Tom Tromey <tromey@adacore.com>
5839
5840 * dwarf2/loc.c (dwarf2_locexpr_baton_eval): Add
5841 "push_initial_value" parameter.
5842 (dwarf2_evaluate_property): Likewise.
5843 * dwarf2/loc.h (dwarf2_evaluate_property): Update.
5844
5845 2020-04-24 Tom Tromey <tromey@adacore.com>
5846
5847 * gdbtypes.c (is_dynamic_type_internal): Check for variant parts.
5848 (variant::matches, compute_variant_fields_recurse)
5849 (compute_variant_fields_inner, compute_variant_fields): New
5850 functions.
5851 (resolve_dynamic_struct): Check for DYN_PROP_VARIANT_PARTS.
5852 Use resolved_type after type is made.
5853 (operator==): Add new cases.
5854 * gdbtypes.h (TYPE_HAS_VARIANT_PARTS): New macro.
5855 (struct discriminant_range, struct variant, struct variant_part):
5856 New.
5857 (union dynamic_prop_data) <variant_parts, original_type>: New
5858 members.
5859 (enum dynamic_prop_node_kind) <DYN_PROP_VARIANT_PARTS>: New constant.
5860 (enum dynamic_prop_kind) <PROP_TYPE, PROP_VARIANT_PARTS>: New
5861 constants.
5862 * value.c (unpack_bits_as_long): Now public.
5863 * value.h (unpack_bits_as_long): Declare.
5864
5865 2020-04-24 Tom Tromey <tromey@adacore.com>
5866
5867 * rs6000-tdep.c (struct ppc_variant): Rename from "variant".
5868 (variants, find_variant_by_arch, rs6000_gdbarch_init): Update.
5869
5870 2020-04-24 Hannes Domani <ssbssa@yahoo.de>
5871
5872 * windows-tdep.c (exception_values): Add WOW64 exception numbers.
5873
5874 2020-04-24 Kamil Rytarowski <n54@gmx.com>
5875
5876 * inf-ptrace.h (follow_fork, insert_fork_catchpoint)
5877 (remove_fork_catchpoint, post_startup_inferior)
5878 (post_attach): Move...
5879 * obsd-nat.h (follow_fork, insert_fork_catchpoint)
5880 (remove_fork_catchpoint, post_startup_inferior)
5881 (post_attach): ...here.
5882 * inf-ptrace.c (follow_fork, insert_fork_catchpoint)
5883 (remove_fork_catchpoint, post_startup_inferior)
5884 (post_attach): Move...
5885 * obsd-nat.c (follow_fork, insert_fork_catchpoint)
5886 (remove_fork_catchpoint, post_startup_inferior)
5887 (post_attach): ...here.
5888
5889 2020-04-24 Tom Tromey <tromey@adacore.com>
5890
5891 * nat/windows-nat.h (struct windows_thread_info)
5892 <pc_adjusted>: New member.
5893 * windows-nat.c (windows_fetch_one_register): Check
5894 pc_adjusted.
5895 (windows_nat_target::get_windows_debug_event)
5896 (windows_nat_target::wait): Set pc_adjusted.
5897
5898 2020-04-24 Tom de Vries <tdevries@suse.de>
5899
5900 * contrib/cc-with-tweaks.sh: Remove <exec>.gdb-index file handling.
5901 Run gdb-add-index inside temp dir.
5902
5903 2020-04-23 Tom Tromey <tromey@adacore.com>
5904
5905 * windows-tdep.c (is_linked_with_cygwin_dll): Always update "iter"
5906 in loop.
5907
5908 2020-04-23 Luis Machado <luis.machado@linaro.org>
5909
5910 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first): Use
5911 get_frame_register instead of gdbarch_unwind_pc.
5912
5913 2020-04-23 Tom de Vries <tdevries@suse.de>
5914
5915 * symtab.c (lookup_global_symbol): Prefer def over decl.
5916
5917 2020-04-23 Tom de Vries <tdevries@suse.de>
5918
5919 PR symtab/25807
5920 * block.c (best_symbol, better_symbol): Promote to external.
5921 * block.h (best_symbol, better_symbol): Declare.
5922 * symtab.c (lookup_symbol_in_objfile_symtabs): Prefer def over
5923 decl.
5924
5925 2020-04-23 Tom Tromey <tromey@adacore.com>
5926
5927 PR ada/25837:
5928 * dwarf2/read.c (dw2_expand_symtabs_matching_symbol): Store a
5929 "const char *", not a "const std::string &".
5930 <name_and_matcher::operator==>: Update.
5931 * unittests/lookup_name_info-selftests.c: Change type of
5932 "result".
5933
5934 2020-04-23 Tom Tromey <tom@tromey.com>
5935
5936 * inferior.h (iterate_over_inferiors): Don't declare.
5937 * inferior.c (iterate_over_inferiors): Remove.
5938 * darwin-nat.c (find_inferior_task_it, find_inferior_pid_it):
5939 Remove.
5940 (darwin_find_inferior_by_task, darwin_find_inferior_by_pid): Don't
5941 use iterate_over_inferiors.
5942 (darwin_resume_inferior_it)
5943 (struct resume_inferior_threads_param)
5944 (darwin_resume_inferior_threads_it): Remove.
5945 (darwin_nat_target::resume): Don't use iterate_over_inferiors.
5946
5947 2020-04-23 Tom de Vries <tdevries@suse.de>
5948
5949 * blockframe.c (find_pc_partial_function): Use
5950 find_pc_sect_compunit_symtab rather than
5951 objfile->sf->qf->find_pc_sect_compunit_symtab.
5952
5953 2020-04-22 Tom de Vries <tdevries@suse.de>
5954
5955 PR symtab/25764
5956 * dwarf2/read.c (scan_partial_symbols): Allow external variable decls
5957 in psymtabs.
5958
5959 2020-04-22 Tom de Vries <tdevries@suse.de>
5960
5961 PR symtab/25801
5962 * psymtab.c (psym_map_symtabs_matching_filename): Don't skip shared
5963 symtabs.
5964
5965 2020-04-22 Tom de Vries <tdevries@suse.de>
5966
5967 PR symtab/25700
5968 * dwarf2/read.c (dwarf2_build_psymtabs_hard): Don't create psymtab for
5969 CU if already created.
5970
5971 2020-04-21 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
5972
5973 * infrun.c (displaced_step_fixup): Switch to the event_thread
5974 before calling displaced_step_restore, not after.
5975
5976 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5977
5978 * record-btrace.c (record_btrace_enable_warn): Ignore thread if
5979 its inferior is not recorded by us.
5980 (record_btrace_target_open): Replace call to
5981 all_non_exited_threads () with call to current_inferior
5982 ()->non_exited_threads ().
5983 (record_btrace_target::stop_recording): Likewise.
5984 (record_btrace_target::close): Likewise.
5985 (record_btrace_target::wait): Likewise.
5986 (record_btrace_target::record_stop_replaying): Likewise.
5987
5988 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5989
5990 * btrace.c (btrace_enable): Throw an error on double enables and
5991 when enabling recording fails.
5992 (btrace_disable): Throw an error if the thread is not recorded.
5993
5994 2020-04-21 Markus Metzger <markus.t.metzger@intel.com>
5995
5996 * record-btrace.c (record_btrace_target::fetch_registers): Forward
5997 request if we do not have a thread_info.
5998
5999 2020-04-21 Tom de Vries <tdevries@suse.de>
6000
6001 PR gdb/25471
6002 * thread.c
6003 (scoped_restore_current_thread::scoped_restore_current_thread): Catch
6004 exception in get_frame_id.
6005
6006 2020-04-20 Tom Tromey <tromey@adacore.com>
6007
6008 * python/python.c (struct gdbpy_event): Mark move constructor as
6009 noexcept.
6010 * python/py-tui.c (class gdbpy_tui_window_maker): Mark move
6011 constructor as noexcept.
6012 * completer.h (struct completion_result): Mark move constructor as
6013 noexcept.
6014 * completer.c (completion_result::completion_result): Use
6015 initialization style. Don't call reset_match_list.
6016
6017 2020-04-20 Mihails Strasuns <mihails.strasuns@intel.com>
6018
6019 * MAINTAINERS (Write After Approval): Add myself.
6020
6021 2020-04-18 Tom Tromey <tom@tromey.com>
6022
6023 * windows-tdep.c (init_w32_command_list)
6024 (w32_prefix_command_valid): Restore.
6025 (_initialize_windows_tdep): Call init_w32_command_list.
6026
6027 2020-04-18 Tom Tromey <tom@tromey.com>
6028
6029 * xcoffread.c (enter_line_range, scan_xcoff_symtab): Update.
6030 * value.c (value_fn_field): Update.
6031 * valops.c (find_function_in_inferior)
6032 (value_allocate_space_in_inferior): Update.
6033 * tui/tui-winsource.c (tui_update_source_windows_with_line):
6034 Update.
6035 * tui/tui-source.c (tui_source_window::set_contents): Update.
6036 * symtab.c (lookup_global_or_static_symbol)
6037 (find_function_start_sal_1, skip_prologue_sal)
6038 (print_msymbol_info, find_gnu_ifunc, symbol_arch): Update.
6039 * symmisc.c (dump_msymbols, dump_symtab_1)
6040 (maintenance_print_one_line_table): Update.
6041 * symfile.c (init_entry_point_info, section_is_mapped)
6042 (list_overlays_command, simple_read_overlay_table)
6043 (simple_overlay_update_1): Update.
6044 * stap-probe.c (handle_stap_probe): Update.
6045 * stabsread.c (dbx_init_float_type, define_symbol)
6046 (read_one_struct_field, read_enum_type, read_range_type): Update.
6047 * source.c (info_line_command): Update.
6048 * python/python.c (gdbpy_source_objfile_script)
6049 (gdbpy_execute_objfile_script): Update.
6050 * python/py-type.c (save_objfile_types): Update.
6051 * python/py-objfile.c (py_free_objfile): Update.
6052 * python/py-inferior.c (python_new_objfile): Update.
6053 * psymtab.c (psym_find_pc_sect_compunit_symtab, dump_psymtab)
6054 (dump_psymtab_addrmap_1, maintenance_info_psymtabs)
6055 (maintenance_check_psymtabs): Update.
6056 * printcmd.c (info_address_command): Update.
6057 * objfiles.h (struct objfile) <arch>: New method, from
6058 get_objfile_arch.
6059 (get_objfile_arch): Don't declare.
6060 * objfiles.c (get_objfile_arch): Remove.
6061 (filter_overlapping_sections): Update.
6062 * minsyms.c (msymbol_is_function): Update.
6063 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines)
6064 (output_nondebug_symbol): Update.
6065 * mdebugread.c (parse_symbol, basic_type, parse_partial_symbols)
6066 (mdebug_expand_psymtab): Update.
6067 * machoread.c (macho_add_oso_symfile): Update.
6068 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap):
6069 Update.
6070 * linux-fork.c (checkpoint_command): Update.
6071 * linespec.c (convert_linespec_to_sals): Update.
6072 * jit.c (finalize_symtab): Update.
6073 * infrun.c (insert_exception_resume_from_probe): Update.
6074 * ia64-tdep.c (ia64_find_unwind_table): Update.
6075 * hppa-tdep.c (internalize_unwinds): Update.
6076 * gdbtypes.c (get_type_arch, init_float_type, objfile_type):
6077 Update.
6078 * gcore.c (call_target_sbrk): Update.
6079 * elfread.c (record_minimal_symbol, elf_symtab_read)
6080 (elf_rel_plt_read, elf_gnu_ifunc_record_cache)
6081 (elf_gnu_ifunc_resolve_by_got): Update.
6082 * dwarf2/read.c (create_addrmap_from_index)
6083 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
6084 (read_debug_names_from_section)
6085 (process_psymtab_comp_unit_reader, add_partial_symbol)
6086 (add_partial_subprogram, process_full_comp_unit)
6087 (read_file_scope, read_func_scope, read_lexical_block_scope)
6088 (read_call_site_scope, dwarf2_ranges_read)
6089 (dwarf2_record_block_ranges, dwarf2_add_field)
6090 (mark_common_block_symbol_computed, read_tag_pointer_type)
6091 (read_tag_string_type, dwarf2_init_float_type)
6092 (dwarf2_init_complex_target_type, read_base_type)
6093 (partial_die_info::read, partial_die_info::read)
6094 (read_attribute_value, dwarf_decode_lines_1, new_symbol)
6095 (dwarf2_fetch_die_loc_sect_off): Update.
6096 * dwarf2/loc.c (dwarf2_find_location_expression)
6097 (class dwarf_evaluate_loc_desc, rw_pieced_value)
6098 (dwarf2_evaluate_loc_desc_full, dwarf2_locexpr_baton_eval)
6099 (dwarf2_loc_desc_get_symbol_read_needs)
6100 (locexpr_describe_location_piece, locexpr_describe_location_1)
6101 (loclist_describe_location): Update.
6102 * dwarf2/index-write.c (write_debug_names): Update.
6103 * dwarf2/frame.c (dwarf2_build_frame_info): Update.
6104 * dtrace-probe.c (dtrace_process_dof): Update.
6105 * dbxread.c (read_dbx_symtab, dbx_end_psymtab)
6106 (process_one_symbol): Update.
6107 * ctfread.c (ctf_init_float_type, read_base_type): Update.
6108 * coffread.c (coff_symtab_read, enter_linenos, decode_base_type)
6109 (coff_read_enum_type): Update.
6110 * cli/cli-cmds.c (edit_command, list_command): Update.
6111 * buildsym.c (buildsym_compunit::finish_block_internal): Update.
6112 * breakpoint.c (create_overlay_event_breakpoint)
6113 (create_longjmp_master_breakpoint)
6114 (create_std_terminate_master_breakpoint)
6115 (create_exception_master_breakpoint, get_sal_arch): Update.
6116 * block.c (block_gdbarch): Update.
6117 * annotate.c (annotate_source_line): Update.
6118
6119 2020-04-17 Tom Tromey <tromey@adacore.com>
6120
6121 * auto-load.c (show_auto_load_cmd): Remove.
6122 (auto_load_show_cmdlist_get): Use add_show_prefix_cmd.
6123 * arc-tdep.c (_initialize_arc_tdep): Use add_show_prefix_cmd.
6124 (maintenance_print_arc_command): Remove.
6125 * tui/tui-win.c (tui_command): Remove.
6126 (tui_get_cmd_list): Use add_basic_prefix_cmd.
6127 * tui/tui-layout.c (tui_layout_command): Remove.
6128 (_initialize_tui_layout): Use add_basic_prefix_cmd.
6129 * python/python.c (user_set_python, user_show_python): Remove.
6130 (_initialize_python): Use add_basic_prefix_cmd,
6131 add_show_prefix_cmd.
6132 * guile/guile.c (set_guile_command, show_guile_command): Remove.
6133 (install_gdb_commands): Use add_basic_prefix_cmd,
6134 add_show_prefix_cmd.
6135 (info_guile_command): Remove.
6136 * dwarf2/read.c (set_dwarf_cmd, show_dwarf_cmd): Remove.
6137 (_initialize_dwarf2_read): Use add_basic_prefix_cmd,
6138 add_show_prefix_cmd.
6139 * cli/cli-style.h (class cli_style_option) <add_setshow_commands>:
6140 Remove do_set and do_show parameters.
6141 * cli/cli-style.c (set_style, show_style): Remove.
6142 (_initialize_cli_style): Use add_basic_prefix_cmd,
6143 add_show_prefix_cmd.
6144 (cli_style_option::add_setshow_commands): Remove do_set and
6145 do_show parameters.
6146 (cli_style_option::add_setshow_commands): Use
6147 add_basic_prefix_cmd, add_show_prefix_cmd.
6148 (STYLE_ADD_SETSHOW_COMMANDS): Remove macro.
6149 (set_style_name): Remove.
6150 * cli/cli-dump.c (dump_command, append_command): Remove.
6151 (srec_dump_command, ihex_dump_command, verilog_dump_command)
6152 (tekhex_dump_command, binary_dump_command)
6153 (binary_append_command): Remove.
6154 (_initialize_cli_dump): Use add_basic_prefix_cmd.
6155 * windows-tdep.c (w32_prefix_command_valid): Remove global.
6156 (init_w32_command_list): Remove; move into ...
6157 (_initialize_windows_tdep): ... here. Use add_basic_prefix_cmd.
6158 * valprint.c (set_print, show_print, set_print_raw)
6159 (show_print_raw): Remove.
6160 (_initialize_valprint): Use add_basic_prefix_cmd,
6161 add_show_prefix_cmd.
6162 * typeprint.c (set_print_type, show_print_type): Remove.
6163 (_initialize_typeprint): Use add_basic_prefix_cmd,
6164 add_show_prefix_cmd.
6165 * record.c (set_record_command, show_record_command): Remove.
6166 (_initialize_record): Use add_basic_prefix_cmd,
6167 add_show_prefix_cmd.
6168 * cli/cli-cmds.c (_initialize_cli_cmds): Use add_basic_prefix_cmd,
6169 add_show_prefix_cmd.
6170 (info_command, show_command, set_debug, show_debug): Remove.
6171 * top.h (set_history, show_history): Don't declare.
6172 * top.c (set_history, show_history): Remove.
6173 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
6174 (unset_tdesc_cmd): Remove.
6175 (_initialize_target_descriptions): Use add_basic_prefix_cmd,
6176 add_show_prefix_cmd.
6177 * symtab.c (info_module_command): Remove.
6178 (_initialize_symtab): Use add_basic_prefix_cmd.
6179 * symfile.c (overlay_command): Remove.
6180 (_initialize_symfile): Use add_basic_prefix_cmd.
6181 * sparc64-tdep.c (info_adi_command): Remove.
6182 (_initialize_sparc64_adi_tdep): Use add_basic_prefix_cmd.
6183 * sh-tdep.c (show_sh_command, set_sh_command): Remove.
6184 (_initialize_sh_tdep): Use add_basic_prefix_cmd,
6185 add_show_prefix_cmd.
6186 * serial.c (serial_set_cmd, serial_show_cmd): Remove.
6187 (_initialize_serial): Use add_basic_prefix_cmd,
6188 add_show_prefix_cmd.
6189 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Remove.
6190 (_initialize_ser_tcp): Use add_basic_prefix_cmd,
6191 add_show_prefix_cmd.
6192 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command)
6193 (_initialize_rs6000_tdep): Use add_basic_prefix_cmd,
6194 add_show_prefix_cmd.
6195 * riscv-tdep.c (show_riscv_command, set_riscv_command)
6196 (show_debug_riscv_command, set_debug_riscv_command): Remove.
6197 (_initialize_riscv_tdep): Use add_basic_prefix_cmd,
6198 add_show_prefix_cmd.
6199 * remote.c (remote_command, set_remote_cmd): Remove.
6200 (_initialize_remote): Use add_basic_prefix_cmd.
6201 * record-full.c (set_record_full_command)
6202 (show_record_full_command): Remove.
6203 (_initialize_record_full): Use add_basic_prefix_cmd,
6204 add_show_prefix_cmd.
6205 * record-btrace.c (cmd_set_record_btrace)
6206 (cmd_show_record_btrace, cmd_set_record_btrace_bts)
6207 (cmd_show_record_btrace_bts, cmd_set_record_btrace_pt)
6208 (cmd_show_record_btrace_pt): Remove.
6209 (_initialize_record_btrace): Use add_basic_prefix_cmd,
6210 add_show_prefix_cmd.
6211 * ravenscar-thread.c (set_ravenscar_command)
6212 (show_ravenscar_command): Remove.
6213 (_initialize_ravenscar): Use add_basic_prefix_cmd,
6214 add_show_prefix_cmd.
6215 * mips-tdep.c (show_mips_command, set_mips_command)
6216 (_initialize_mips_tdep): Use add_basic_prefix_cmd,
6217 add_show_prefix_cmd.
6218 * maint.c (maintenance_command, maintenance_info_command)
6219 (maintenance_check_command, maintenance_print_command)
6220 (maintenance_set_cmd, maintenance_show_cmd): Remove.
6221 (_initialize_maint_cmds): Use add_basic_prefix_cmd,
6222 add_show_prefix_cmd.
6223 (show_per_command_cmd): Remove.
6224 * maint-test-settings.c (maintenance_set_test_settings_cmd):
6225 Remove.
6226 (maintenance_show_test_settings_cmd): Remove.
6227 (_initialize_maint_test_settings): Use add_basic_prefix_cmd,
6228 add_show_prefix_cmd.
6229 * maint-test-options.c (maintenance_test_options_command):
6230 Remove.
6231 (_initialize_maint_test_options): Use add_basic_prefix_cmd.
6232 * macrocmd.c (macro_command): Remove
6233 (_initialize_macrocmd): Use add_basic_prefix_cmd.
6234 * language.c (set_check, show_check): Remove.
6235 (_initialize_language): Use add_basic_prefix_cmd,
6236 add_show_prefix_cmd.
6237 * infcmd.c (unset_command): Remove.
6238 (_initialize_infcmd): Use add_basic_prefix_cmd.
6239 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Remove.
6240 (_initialize_i386_tdep): Use add_basic_prefix_cmd,
6241 add_show_prefix_cmd.
6242 * go32-nat.c (go32_info_dos_command): Remove.
6243 (_initialize_go32_nat): Use add_basic_prefix_cmd.
6244 * cli/cli-decode.c (do_prefix_cmd, add_basic_prefix_cmd)
6245 (do_show_prefix_cmd, add_show_prefix_cmd): New functions.
6246 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Remove.
6247 (_initialize_frame): Use add_basic_prefix_cmd,
6248 add_show_prefix_cmd.
6249 * dcache.c (set_dcache_command, show_dcache_command): Remove.
6250 (_initialize_dcache): Use add_basic_prefix_cmd,
6251 add_show_prefix_cmd.
6252 * cp-support.c (maint_cplus_command): Remove.
6253 (_initialize_cp_support): Use add_basic_prefix_cmd.
6254 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
6255 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
6256 (maint_btrace_pt_show_cmd, _initialize_btrace): Use
6257 add_basic_prefix_cmd, add_show_prefix_cmd.
6258 * breakpoint.c (save_command): Remove.
6259 (_initialize_breakpoint): Use add_basic_prefix_cmd.
6260 * arm-tdep.c (set_arm_command, show_arm_command): Remove.
6261 (_initialize_arm_tdep): Use add_basic_prefix_cmd,
6262 add_show_prefix_cmd.
6263 * ada-lang.c (maint_set_ada_cmd, maint_show_ada_cmd)
6264 (set_ada_command, show_ada_command): Remove.
6265 (_initialize_ada_language): Use add_basic_prefix_cmd,
6266 add_show_prefix_cmd.
6267 * command.h (add_basic_prefix_cmd, add_show_prefix_cmd): Declare.
6268
6269 2020-04-16 Kamil Rytarowski <n54@gmx.com>
6270
6271 * nbsd-nat.c (inf_ptrace_target::auxv_parse): Remove.
6272 * nbsd-nat.h (inf_ptrace_target::auxv_parse): Likewise.
6273
6274 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
6275
6276 * windows-tdep.c (is_linked_with_cygwin_dll): Add filename to
6277 warning messages.
6278
6279 2020-04-16 Simon Marchi <simon.marchi@polymtl.ca>
6280
6281 * windows-tdep.c (is_linked_with_cygwin_dll): Consider case where
6282 import table is not at beginning of .idata section.
6283
6284 2020-04-16 Pedro Alves <palves@redhat.com>
6285
6286 * inferior.c (delete_inferior): Use delete operator directly
6287 instead of delete_program_space.
6288 * progspace.c (add_program_space): New, factored out from
6289 program_space::program_space.
6290 (remove_program_space): New, factored out from
6291 delete_program_space.
6292 (program_space::program_space): Remove intro comment. Rewrite.
6293 (program_space::~program_space): Remove intro comment. Call
6294 remove_program_space.
6295 (delete_program_space): Delete.
6296 * progspace.h (program_space::program_space): Make explicit. Move
6297 intro comment here, adjusted.
6298 (program_space::~program_space): Move intro comment here,
6299 adjusted.
6300 (delete_program_space): Remove.
6301
6302 2020-04-16 Tom Tromey <tromey@adacore.com>
6303
6304 * windows-nat.c (windows_nat::handle_access_violation): New
6305 function.
6306 * nat/windows-nat.h (handle_access_violation): Declare.
6307 * nat/windows-nat.c (handle_exception): Move Cygwin code to
6308 windows-nat.c. Call handle_access_violation.
6309
6310 2020-04-16 Tom de Vries <tdevries@suse.de>
6311
6312 PR symtab/25791
6313 * dwarf2/index-write.c (write_gdbindex): Generate CU table entries for
6314 CUs without psymtab.
6315
6316 2020-04-16 Kevin Buettner <kevinb@redhat.com>
6317
6318 * python/python.c (do_start_initialization): Don't call
6319 PyEval_InitThreads for Python 3.9 and beyond.
6320
6321 2020-04-15 Kamil Rytarowski <n54@gmx.com>
6322
6323 * obsd-nat.c (obsd_nat_target::update_thread_list): Pass "this" to
6324 thread functions.
6325 (obsd_nat_target::wait): Likewise.
6326
6327 2020-04-15 Tom Tromey <tromey@adacore.com>
6328
6329 * windows-nat.c (DEBUG_EXEC, DEBUG_EVENTS, DEBUG_MEM)
6330 (DEBUG_EXCEPT): Use debug_printf.
6331
6332 2020-04-15 Andrew Burgess <andrew.burgess@embecosm.com>
6333
6334 * completer.c (class completion_tracker::completion_hash_entry)
6335 <hash_name>: New member function.
6336 (completion_tracker::discard_completions): New callback to hash a
6337 completion_hash_entry, pass this to htab_create_alloc.
6338
6339 2016-01-20 Jon Turney <jon.turney@dronecode.org.uk>
6340
6341 * windows-nat.c (windows_make_so): Warn rather than stopping with
6342 an error if realpath() fails.
6343
6344 2020-04-14 Kamil Rytarowski <n54@gmx.com>
6345
6346 * nbsd-nat.c (nbsd_pid_to_kinfo_proc2): New.
6347 (nbsd_nat_target::info_proc): Add do_status.
6348
6349 2020-04-14 Simon Marchi <simon.marchi@polymtl.ca>
6350 Tom de Vries <tdevries@suse.de>
6351
6352 PR symtab/25718
6353 * psympriv.h (struct partial_symtab::read_symtab)
6354 (struct partial_symtab::expand_psymtab)
6355 (struct partial_symtab::read_dependencies): Update comments.
6356 * dwarf2/read.c (struct dwarf2_include_psymtab::read_symtab): Call
6357 read_symtab for includer.
6358 (struct dwarf2_include_psymtab::expand_psymtab): Assert false.
6359 (struct dwarf2_include_psymtab::readin_p): Call readin_p () for includer.
6360 (struct dwarf2_include_psymtab::m_readin): Remove.
6361 (struct dwarf2_include_psymtab::includer): New member function.
6362 (dwarf2_psymtab::expand_psymtab): Assert !readin.
6363
6364 2020-04-14 Tom de Vries <tdevries@suse.de>
6365
6366 PR symtab/25720
6367 * symmisc.c (maintenance_expand_symtabs): Call expand_symtabs_matching
6368 with NULL symbol_matcher and lookup_name.
6369 * psymtab.c (psym_expand_symtabs_matching): Handle NULL symbol_matcher
6370 and lookup_name.
6371 * dwarf2/read.c (dw2_expand_symtabs_matching)
6372 (dw2_debug_names_expand_symtabs_matching): Same.
6373 * symfile.h (struct quick_symbol_functions::expand_symtabs_matching):
6374 Make lookup_name a pointer. Update comment.
6375 * symtab.c (global_symbol_searcher::expand_symtabs): Handle
6376 lookup_name being a pointer.
6377 * symfile.c (expand_symtabs_matching): Same.
6378 * symfile-debug.c (debug_qf_expand_symtabs_matching): Same.
6379 * linespec.c (iterate_over_all_matching_symtabs): Same.
6380
6381 2020-04-13 Tom Tromey <tom@tromey.com>
6382
6383 * run-on-main-thread.c: Update include.
6384 * unittests/main-thread-selftests.c: Update include.
6385 * tui/tui-win.c: Update include.
6386 * tui/tui-io.c: Update include.
6387 * tui/tui-interp.c: Update include.
6388 * tui/tui-hooks.c: Update include.
6389 * top.h: Update include.
6390 * top.c: Update include.
6391 * ser-base.c: Update include.
6392 * remote.c: Update include.
6393 * remote-notif.c: Update include.
6394 * remote-fileio.c: Update include.
6395 * record-full.c: Update include.
6396 * record-btrace.c: Update include.
6397 * python/python.c: Update include.
6398 * posix-hdep.c: Update include.
6399 * mingw-hdep.c: Update include.
6400 * mi/mi-main.c: Update include.
6401 * mi/mi-interp.c: Update include.
6402 * main.c: Update include.
6403 * linux-nat.c: Update include.
6404 * interps.c: Update include.
6405 * infrun.c: Update include.
6406 * inf-loop.c: Update include.
6407 * event-top.c: Update include.
6408 * event-loop.c: Move to ../gdbsupport/.
6409 * event-loop.h: Move to ../gdbsupport/.
6410 * async-event.h: Update include.
6411 * Makefile.in (COMMON_SFILES, HFILES_NO_SRCDIR): Update.
6412
6413 2020-04-13 Tom Tromey <tom@tromey.com>
6414
6415 * tui/tui-win.c: Include async-event.h.
6416 * remote.c: Include async-event.h.
6417 * remote-notif.c: Include async-event.h.
6418 * record-full.c: Include async-event.h.
6419 * record-btrace.c: Include async-event.h.
6420 * infrun.c: Include async-event.h.
6421 * event-top.c: Include async-event.h.
6422 * event-loop.h: Move some declarations to async-event.h.
6423 * event-loop.c: Don't include ser-event.h or top.h. Move some
6424 code to async-event.c.
6425 * async-event.h: New file.
6426 * async-event.c: New file.
6427 * Makefile.in (COMMON_SFILES): Add async-event.c.
6428 (HFILES_NO_SRCDIR): Add async-event.h.
6429
6430 2020-04-13 Tom Tromey <tom@tromey.com>
6431
6432 * utils.c (flush_streams): New function.
6433 * event-loop.c (gdb_wait_for_event): Call flush_streams.
6434
6435 2020-04-13 Tom Tromey <tom@tromey.com>
6436
6437 * event-loop.c (handle_file_event): Use warning, not
6438 printf_unfiltered.
6439
6440 2020-04-13 Tom Tromey <tom@tromey.com>
6441
6442 * event-loop.c: Include <chrono>.
6443
6444 2020-04-13 Tom Tromey <tom@tromey.com>
6445
6446 * gdb_select.h: Move to ../gdbsupport/.
6447 * event-loop.c: Update include path.
6448 * top.c: Update include path.
6449 * ser-base.c: Update include path.
6450 * ui-file.c: Update include path.
6451 * ser-tcp.c: Update include path.
6452 * guile/scm-ports.c: Update include path.
6453 * posix-hdep.c: Update include path.
6454 * ser-unix.c: Update include path.
6455 * gdb_usleep.c: Update include path.
6456 * mingw-hdep.c: Update include path.
6457 * inflow.c: Update include path.
6458 * infrun.c: Update include path.
6459 * event-top.c: Update include path.
6460
6461 2020-04-13 Tom Tromey <tom@tromey.com>
6462
6463 * configure: Rebuild.
6464 * configure.ac: Remove checks that are now in GDB_AC_COMMON.
6465
6466 2020-04-13 Tom Tromey <tom@tromey.com>
6467
6468 * event-loop.h (start_event_loop): Don't declare.
6469 * event-loop.c (start_event_loop): Move...
6470 * main.c (start_event_loop): ...here. Now static.
6471
6472 2020-04-13 Sergio Durigan Junior <sergiodj@sergiodj.net>
6473
6474 * MAINTAINERS: Update my email address.
6475
6476 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6477
6478 * nbsd-nat.c (nbsd_nat_target::info_proc): Add IP_MINIMAL and
6479 IP_ALL.
6480
6481 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6482
6483 * nbsd-nat.c (nbsd_pid_to_cmdline): Add.
6484 (nbsd_nat_target::info_proc): Add do_cmdline.
6485
6486 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6487
6488 * nbsd-nat.c (nbsd_pid_to_cwd): Add.
6489 (nbsd_nat_target::info_proc): Add do_cwd.
6490
6491 2020-04-12 Kamil Rytarowski <n54@gmx.com>
6492
6493 * nbsd-nat.c (nbsd_nat_target::info_proc): Add do_exe.
6494
6495 2020-04-11 Kamil Rytarowski <n54@gmx.com>
6496
6497 * nbsd-nat.c; Include "nbsd-tdep.h" and "gdbarch.h".
6498 * nbsd-nat.c (nbsd_nat_target::find_memory_regions)
6499 (nbsd_nat_target::info_proc): New functions.
6500 * nbsd-nat.c (kinfo_get_vmmap): New function.
6501 * nbsd-nat.c (nbsd_nat_target::info_proc) Use
6502 nbsd_info_proc_mappings_header and nbsd_info_proc_mappings_entry.
6503 * nbsd-tdep.c (nbsd_info_proc_mappings_header)
6504 (nbsd_info_proc_mappings_entry, nbsd_vm_map_entry_flags): New
6505 functions.
6506 * nbsd-tdep.c (KINFO_VME_PROT_READ, KINFO_VME_PROT_WRITE)
6507 (KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
6508 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
6509 (KINFO_VME_FLAG_PAGEABLE, KINFO_VME_FLAG_GROWS_UP)
6510 (KINFO_VME_FLAG_GROWS_DOWN): New.
6511
6512 2020-04-10 Artur Shepilko <nomadbyte@gmail.com>
6513
6514 * utils.c (copy_bitwise): Use unsigned 0 constant as operand of
6515 bit shift.
6516
6517 2020-04-10 Tom Tromey <tromey@adacore.com>
6518
6519 * symfile.c (symbol_file_add_separate): Preserve OBJF_MAINLINE.
6520
6521 2020-04-10 Tom Tromey <tromey@adacore.com>
6522
6523 * symtab.c (get_symbol_address, get_msymbol_address): Skip
6524 separate debug files.
6525
6526 2020-04-10 Hannes Domani <ssbssa@yahoo.de>
6527
6528 * nat/windows-nat.c (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
6529 Move to...
6530 * nat/windows-nat.h (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP):
6531 ... here.
6532 * windows-nat.c (windows_nat_target::get_windows_debug_event):
6533 Check for STATUS_WX86_BREAKPOINT.
6534 (windows_nat_target::wait): Same.
6535
6536 2020-04-10 Tom de Vries <tdevries@suse.de>
6537
6538 PR cli/25808
6539 * python/lib/gdb/__init__.py: Initialize lexer with stripnl=False.
6540
6541 2020-04-09 Simon Marchi <simon.marchi@polymtl.ca>
6542
6543 * MAINTAINERS (Global Maintainers): Add Tom de Vries.
6544 (Write After Approval): Remove Tom de Vries.
6545
6546 2020-04-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
6547
6548 revert partially:
6549 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
6550
6551 * buildsym.c (record_line): Fix undefined behavior and preserve
6552 lines at eof.
6553
6554 2020-04-09 Kamil Rytarowski <n54@gmx.com>
6555
6556 * auxv.h (svr4_auxv_parse): New.
6557 * auxv.c (default_auxv_parse): Split into default_auxv_parse
6558 and generic_auxv_parse.
6559 (svr4_auxv_parse): Add.
6560 * obsd-tdep.c: Include "auxv.h".
6561 (obsd_auxv_parse): Remove.
6562 (obsd_init_abi): Remove comment.
6563 (obsd_init_abi): Change set_gdbarch_auxv_parse passed argument
6564 from `obsd_auxv_parse' to `svr4_auxv_parse'.
6565 * nbsd-tdep.c: Include "auxv.h".
6566 (nbsd_init_abi): Call set_gdbarch_auxv_parse.
6567
6568 2020-04-08 Tom Tromey <tromey@adacore.com>
6569
6570 * nat/windows-nat.h (last_wait_event): Don't declare.
6571 (wait_for_debug_event): Update comment.
6572 * nat/windows-nat.c (last_wait_event): Now static.
6573
6574 2020-04-08 Tom Tromey <tromey@adacore.com>
6575
6576 * windows-nat.c (wait_for_debug_event): Move to
6577 nat/windows-nat.c.
6578 * nat/windows-nat.h (wait_for_debug_event): Declare.
6579 * nat/windows-nat.c (wait_for_debug_event): Move from
6580 windows-nat.c. No longer static.
6581
6582 2020-04-08 Tom Tromey <tromey@adacore.com>
6583
6584 * windows-nat.c (get_windows_debug_event): Use
6585 fetch_pending_stop.
6586 * nat/windows-nat.h (fetch_pending_stop): Declare.
6587 * nat/windows-nat.c (fetch_pending_stop): New function.
6588
6589 2020-04-08 Tom Tromey <tromey@adacore.com>
6590
6591 * windows-nat.c (windows_continue): Use matching_pending_stop and
6592 continue_last_debug_event.
6593 * nat/windows-nat.h (matching_pending_stop)
6594 (continue_last_debug_event): Declare.
6595 * nat/windows-nat.c (DEBUG_EVENTS): New define.
6596 (matching_pending_stop, continue_last_debug_event): New
6597 functions.
6598
6599 2020-04-08 Tom Tromey <tromey@adacore.com>
6600
6601 * windows-nat.c (MS_VC_EXCEPTION): Move to nat/windows-nat.c.
6602 (handle_exception_result): Move to nat/windows-nat.h.
6603 (DEBUG_EXCEPTION_SIMPLE): Remove.
6604 (windows_nat::handle_ms_vc_exception): New function.
6605 (handle_exception): Move to nat/windows-nat.c.
6606 (get_windows_debug_event): Update.
6607 (STATUS_WX86_BREAKPOINT, STATUS_WX86_SINGLE_STEP): Move to
6608 nat/windows-nat.c.
6609 * nat/windows-nat.h (handle_ms_vc_exception): Declare.
6610 (handle_exception_result): Move from windows-nat.c.
6611 (handle_exception): Declare.
6612 * nat/windows-nat.c (MS_VC_EXCEPTION, handle_exception)
6613 (STATUS_WX86_SINGLE_STEP, STATUS_WX86_BREAKPOINT): Move from
6614 windows-nat.c.
6615
6616 2020-04-08 Tom Tromey <tromey@adacore.com>
6617
6618 * windows-nat.c (exception_count, event_count): Remove.
6619 (handle_exception, get_windows_debug_event)
6620 (do_initial_windows_stuff): Update.
6621
6622 2020-04-08 Tom Tromey <tromey@adacore.com>
6623
6624 * windows-nat.c (windows_nat::handle_load_dll)
6625 (windows_nat::handle_unload_dll): Rename. No longer static.
6626 * nat/windows-nat.h (handle_load_dll, handle_unload_dll):
6627 Declare.
6628
6629 2020-04-08 Tom Tromey <tromey@adacore.com>
6630
6631 * complaints.h (stop_whining): Declare at top-level.
6632 (complaint): Don't declare stop_whining.
6633
6634 2020-04-08 Tom Tromey <tromey@adacore.com>
6635
6636 * windows-nat.c (windows_nat::handle_output_debug_string):
6637 Rename. No longer static.
6638 * nat/windows-nat.h (handle_output_debug_string): Declare.
6639
6640 2020-04-08 Tom Tromey <tromey@adacore.com>
6641
6642 * windows-nat.c (current_process_handle, current_process_id)
6643 (main_thread_id, last_sig, current_event, last_wait_event)
6644 (current_windows_thread, desired_stop_thread_id, pending_stops)
6645 (struct pending_stop, siginfo_er): Move to nat/windows-nat.c.
6646 (display_selectors, fake_create_process)
6647 (get_windows_debug_event): Update.
6648 * nat/windows-nat.h (current_process_handle, current_process_id)
6649 (main_thread_id, last_sig, current_event, last_wait_event)
6650 (current_windows_thread, desired_stop_thread_id, pending_stops)
6651 (struct pending_stop, siginfo_er): Move from windows-nat.c.
6652 * nat/windows-nat.c (current_process_handle, current_process_id)
6653 (main_thread_id, last_sig, current_event, last_wait_event)
6654 (current_windows_thread, desired_stop_thread_id, pending_stops)
6655 (siginfo_er): New globals. Move from windows-nat.c.
6656
6657 2020-04-08 Tom Tromey <tromey@adacore.com>
6658
6659 * windows-nat.c (get_image_name): Move to nat/windows-nat.c.
6660 (handle_load_dll): Update.
6661 * nat/windows-nat.c (get_image_name): Move from windows-nat.c.
6662
6663 2020-04-08 Tom Tromey <tromey@adacore.com>
6664
6665 * windows-nat.c (enum thread_disposition_type): Move to
6666 nat/windows-nat.h.
6667 (windows_nat::thread_rec): Rename from thread_rec. No longer
6668 static.
6669 (windows_add_thread, windows_nat_target::fetch_registers)
6670 (windows_nat_target::store_registers, handle_exception)
6671 (windows_nat_target::resume, get_windows_debug_event)
6672 (windows_nat_target::get_tib_address)
6673 (windows_nat_target::thread_name)
6674 (windows_nat_target::thread_alive): Update.
6675 * nat/windows-nat.h (enum thread_disposition_type): Move from
6676 windows-nat.c.
6677 (thread_rec): Declare.
6678
6679 2020-04-08 Tom Tromey <tromey@adacore.com>
6680
6681 * windows-nat.c: Add "using namespace".
6682 * nat/windows-nat.h: Wrap contents in windows_nat namespace.
6683 * nat/windows-nat.c: Wrap contents in windows_nat namespace.
6684
6685 2020-04-08 Tom Tromey <tromey@adacore.com>
6686
6687 * nat/windows-nat.h (struct windows_thread_info): Declare
6688 destructor.
6689 * nat/windows-nat.c (~windows_thread_info): New.
6690
6691 2020-04-08 Tom Tromey <tromey@adacore.com>
6692
6693 PR gdb/22992
6694 * windows-nat.c (current_event): Update comment.
6695 (last_wait_event, desired_stop_thread_id): New globals.
6696 (struct pending_stop): New.
6697 (pending_stops): New global.
6698 (windows_nat_target) <stopped_by_sw_breakpoint>
6699 <supports_stopped_by_sw_breakpoint>: New methods.
6700 (windows_fetch_one_register): Add assertions. Adjust PC.
6701 (windows_continue): Handle pending stops. Suspend other threads
6702 when stepping. Use last_wait_event
6703 (wait_for_debug_event): New function.
6704 (get_windows_debug_event): Use wait_for_debug_event. Handle
6705 pending stops. Queue spurious stops.
6706 (windows_nat_target::wait): Set stopped_at_software_breakpoint.
6707 (windows_nat_target::kill): Use wait_for_debug_event.
6708 * nat/windows-nat.h (struct windows_thread_info)
6709 <stopped_at_software_breakpoint>: New field.
6710 * nat/windows-nat.c (windows_thread_info::resume): Clear
6711 stopped_at_software_breakpoint.
6712
6713 2020-04-08 Tom Tromey <tromey@adacore.com>
6714
6715 * windows-nat.c (enum thread_disposition_type): New.
6716 (thread_rec): Replace "get_context" parameter with "disposition";
6717 change type.
6718 (windows_add_thread, windows_nat_target::fetch_registers)
6719 (windows_nat_target::store_registers, handle_exception)
6720 (windows_nat_target::resume, get_windows_debug_event)
6721 (windows_nat_target::get_tib_address)
6722 (windows_nat_target::thread_name)
6723 (windows_nat_target::thread_alive): Update.
6724
6725 2020-04-08 Tom Tromey <tromey@adacore.com>
6726
6727 * windows-nat.c (thread_rec): Use windows_thread_info::suspend.
6728 (windows_continue): Use windows_continue::resume.
6729 * nat/windows-nat.h (struct windows_thread_info) <suspend,
6730 resume>: Declare new methods.
6731 * nat/windows-nat.c: New file.
6732 * configure.nat (NATDEPFILES): Add nat/windows-nat.o when needed.
6733
6734 2020-04-08 Tom Tromey <tromey@adacore.com>
6735
6736 * windows-nat.c (windows_add_thread, windows_delete_thread)
6737 (windows_nat_target::fetch_registers)
6738 (windows_nat_target::store_registers, fake_create_process)
6739 (windows_nat_target::resume, windows_nat_target::resume)
6740 (get_windows_debug_event, windows_nat_target::wait)
6741 (windows_nat_target::pid_to_str)
6742 (windows_nat_target::get_tib_address)
6743 (windows_nat_target::get_ada_task_ptid)
6744 (windows_nat_target::thread_name)
6745 (windows_nat_target::thread_alive): Use lwp, not tid.
6746
6747 2020-04-08 Tom Tromey <tromey@adacore.com>
6748
6749 * windows-nat.c (handle_exception)
6750 (windows_nat_target::thread_name): Update.
6751 * nat/windows-nat.h (windows_thread_info): Remove destructor.
6752 <name>: Now unique_xmalloc_ptr.
6753
6754 2020-04-08 Tom Tromey <tromey@adacore.com>
6755
6756 * windows-nat.c (thread_rec)
6757 (windows_nat_target::fetch_registers): Update.
6758 * nat/windows-nat.h (struct windows_thread_info) <suspended>:
6759 Update comment.
6760 <debug_registers_changed, reload_context>: Now bool.
6761
6762 2020-04-08 Tom Tromey <tromey@adacore.com>
6763
6764 * windows-nat.c (windows_add_thread): Use new.
6765 (windows_init_thread_list, windows_delete_thread): Use delete.
6766 (get_windows_debug_event): Update.
6767 * nat/windows-nat.h (struct windows_thread_info): Add constructor,
6768 destructor, and initializers.
6769
6770 2020-04-08 Tom Tromey <tromey@adacore.com>
6771
6772 * windows-nat.c (struct windows_thread_info): Remove.
6773 * nat/windows-nat.h: New file.
6774
6775 2020-04-08 Tom Tromey <tromey@adacore.com>
6776
6777 * windows-nat.c (struct windows_thread_info) <tid>: Rename from "id".
6778 (thread_rec, windows_add_thread, windows_delete_thread)
6779 (windows_continue): Update.
6780
6781 2020-04-08 Tom Tromey <tromey@adacore.com>
6782
6783 * windows-nat.c (struct windows_thread_info): Remove typedef.
6784 (thread_head): Remove.
6785 (thread_list): New global.
6786 (thread_rec, windows_add_thread, windows_init_thread_list)
6787 (windows_delete_thread, windows_continue): Update.
6788
6789 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
6790
6791 * windows-tdep.h (windows_init_abi): Add comment.
6792 (cygwin_init_abi): New declaration.
6793 * windows-tdep.c: Split signal enumeration in two, one for
6794 Windows and one for Cygwin.
6795 (windows_gdb_signal_to_target): Only deal with signal of the
6796 Windows OS ABI.
6797 (cygwin_gdb_signal_to_target): New function.
6798 (windows_init_abi): Rename to windows_init_abi_common, don't set
6799 gdb_signal_to_target gdbarch method. Add new new function with
6800 this name.
6801 (cygwin_init_abi): New function.
6802 * amd64-windows-tdep.c (amd64_windows_init_abi_common): Add
6803 comment. Don't call windows_init_abi.
6804 (amd64_windows_init_abi): Add comment, call windows_init_abi.
6805 (amd64_cygwin_init_abi): Add comment, call cygwin_init_abi.
6806 * i386-windows-tdep.c (i386_windows_init_abi): Rename to
6807 i386_windows_init_abi_common, don't call windows_init_abi. Add
6808 a new function of this name.
6809 (i386_cygwin_init_abi): New function.
6810 (_initialize_i386_windows_tdep): Bind i386_cygwin_init_abi to
6811 OS ABI Cygwin.
6812
6813 2020-04-08 Simon Marchi <simon.marchi@polymtl.ca>
6814
6815 * dwarf2/read.c (read_gdb_index_from_buffer): Remove objfile
6816 parameter.c.
6817 (dwarf2_read_gdb_index): Update.
6818
6819 2020-04-07 Kamil Rytarowski <n54@gmx.com>
6820
6821 * nbsd-tdep.c: Include "objfiles.h".
6822 (nbsd_skip_solib_resolver): New.
6823 (nbsd_init_abi): Call set_gdbarch_skip_solib_resolver().
6824
6825 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6826
6827 * dwarf2/loc.c (loclist_describe_location): Call the function decode_debug_loclists_
6828 addresses if DWARF version is 5 or more because DW_LLE_start* or DW_LLE_offset_pair
6829 with DW_LLE_base_addressx are being emitted in DWARFv5.
6830 Add the newly added kind DW_LOC_OFFSET_PAIR also.
6831 The length of location description is an unsigned ULEB integer in DWARFv5 instead of
6832 unsigned integer.
6833
6834 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6835
6836 * dwarf2/loc.c (enum debug_loc_kind): Add a new kind DEBUG_LOC_OFFSET_PAIR.
6837 (dwarf2_find_location_expression): Call the function decode_debug_loclists_
6838 addresses if DWARF version is 5 or more. DW_LLE_start* or DW_LLE_offset_pair
6839 with DW_LLE_base_addressx are being emitted in DWARFv5 instead of DW_LLE_GNU*.
6840 Add applicable base address if the entry is DW_LLE_offset_pair from DWO.
6841 (decode_debug_loclists_addresses): Return DEBUG_LOC_OFFSET_PAIR instead of
6842 DEBUG_LOC_START_END in case of DW_LLE_offset_pair.
6843
6844
6845 2020-04-07 Nitika Achra <Nitika.Achra@amd.com>
6846
6847 * dwarf2/read.c (cu_debug_loc_section): Added the declaration for the function.
6848 (read_loclist_index): New function definition.
6849 (lookup_loclist_base): New function definition.
6850 (read_loclist_header): New function definition.
6851 (dwarf2_cu): Add loclist_base and loclist_header field.
6852 (dwarf2_locate_dwo_sections): Handle .debug_loclists.dwo section.
6853 (read_full_die_1): Read the value of DW_AT_loclists_base.
6854 (read_attribute_reprocess): Handle DW_FORM_loclistx.
6855 (read_attribute_value): Handle DW_FORM_loclistx.
6856 (skip_one_die): Handle DW_FORM_loclistx.
6857 (loclist_header): New structure declaration.
6858 * dwarf2/attribute.c (form_is_section_offset): Handle DW_FORM_loclistx.
6859
6860 2020-04-07 Simon Marchi <simon.marchi@polymtl.ca>
6861
6862 * dwarf2/read.h (struct dwarf2_psymtab): Remove two-parameters
6863 constructor. Remove `addr` parameter from other constructor and
6864 add `per_cu` parameter.
6865 * dwarf2/read.c (create_partial_symtab): Update.
6866
6867 2020-04-07 Tom de Vries <tdevries@suse.de>
6868
6869 PR symtab/25796
6870 * dwarf2/read.c (can_have_DW_AT_const_value_p): New function.
6871 (partial_die_info::fixup): Inherit has_const_value.
6872
6873 2020-04-07 Tom de Vries <tdevries@suse.de>
6874
6875 * psymtab.c (maintenance_check_psymtabs): Skip static LOC_BLOCK
6876 symbols without address.
6877
6878 2020-04-06 Kamil Rytarowski <n54@gmx.com>
6879
6880 * nbsd-nat.h (struct thread_info): Add forward declaration.
6881 (nbsd_nat_target::thread_alive): Add.
6882 (nbsd_nat_target::thread_name): Likewise.
6883 (nbsd_nat_target::update_thread_list): Likewise.
6884 (update_thread_list::post_attach): Likewise.
6885 (post_attach::pid_to_str): Likewise.
6886 * nbsd-nat.c: Include "gdbthread.h" and "inferior.h".
6887 (nbsd_thread_lister): Add.
6888 (nbsd_nat_target::thread_alive): Likewise.
6889 (nbsd_nat_target::thread_name): Likewise.
6890 (nbsd_add_threads): Likewise.
6891 (update_thread_list::post_attach): Likewise.
6892 (nbsd_nat_target::update_thread_list): Likewise.
6893 (post_attach::pid_to_str): Likewise.
6894
6895 2020-04-06 Tom Tromey <tromey@adacore.com>
6896
6897 * ada-valprint.c (print_variant_part): Extract the variant field.
6898 (print_field_values): Use the field as the outer value when
6899 recursing.
6900
6901 2020-04-06 Tom Tromey <tromey@adacore.com>
6902
6903 * sh-nbsd-tdep.c: Include nbsd-tdep.h.
6904 * ppc-nbsd-tdep.c: Include nbsd-tdep.h.
6905 * mips-nbsd-tdep.c (mipsnbsd_init_abi): Add missing ";".
6906 * arm-nbsd-tdep.c: Include nbsd-tdep.h.
6907 * hppa-nbsd-tdep.c: Include nbsd-tdep.h.
6908
6909 2020-04-06 Tom Tromey <tromey@adacore.com>
6910
6911 * dwarf2/read.c (read_base_type) <DW_ATE_complex_float>: Handle
6912 TYPE_CODE_ERROR.
6913
6914 2020-04-06 Kamil Rytarowski <n54@gmx.com>
6915
6916 * nbsd-tdep.c: Include "gdbarch.h".
6917 Define enum with NetBSD signal numbers.
6918 (nbsd_gdb_signal_from_target, nbsd_gdb_signal_to_target): New.
6919 * alpha-nbsd-tdep.c (alphanbsd_init_abi): Call nbsd_init_abi().
6920 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
6921 * arm-nbsd-tdep.c (arm_netbsd_elf_init_abi): Likewise.
6922 * hppa-nbsd-tdep.c (hppanbsd_init_abi): Likewise.
6923 * i386-nbsd-tdep.c (i386nbsd_init_abi): Likewise.
6924 * mips-nbsd-tdep.c (nbsd_init_abi): Likewise.
6925 * ppc-nbsd-tdep.c (ppcnbsd_init_abi): Likewise.
6926 * sh-nbsd-tdep.c (shnbsd_init_abi): Likewise.
6927 * sparc-nbsd-tdep.c (sparc32nbsd_init_abi): Likewise.
6928 * sparc64-nbsd-tdep.c (sparc64nbsd_init_abi): Likewise.
6929 * vax-nbsd-tdep.c (vaxnbsd_elf_init_abi): Likewise.
6930
6931 2020-04-03 Hannes Domani <ssbssa@yahoo.de>
6932
6933 PR gdb/25325
6934 * dwarf2/read.c (read_enumeration_type): Fix typed enum attributes.
6935
6936 2020-04-03 Tom Tromey <tromey@adacore.com>
6937
6938 * dwarf2/loc.c (disassemble_dwarf_expression) <DW_OP_const_type>:
6939 Read constant block.
6940
6941 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
6942
6943 * gdb_bfd.h: Include gdbsupport/byte-vector.h.
6944 (gdb_bfd_get_full_section_contents): New declaration.
6945 * gdb_bfd.c (gdb_bfd_get_full_section_contents): New function.
6946 * windows-tdep.c (is_linked_with_cygwin_dll): Use
6947 gdb_bfd_get_full_section_contents.
6948
6949 2020-04-02 Simon Marchi <simon.marchi@polymtl.ca>
6950
6951 * exec.c (build_section_table): Replace internal_error with
6952 gdb_assert.
6953 (section_table_xfer_memory_partial): Likewise.
6954 * mdebugread.c (parse_partial_symbols): Likewise.
6955 * psymtab.c (lookup_partial_symbol): Likewise.
6956 * utils.c (wrap_here): Likewise.
6957
6958 2020-04-02 Tom Tromey <tromey@adacore.com>
6959
6960 * f-lang.c (build_fortran_types): Use arch_type to initialize
6961 builtin_complex_s32 in the TYPE_CODE_ERROR case.
6962
6963 2020-04-02 Tom Tromey <tromey@adacore.com>
6964
6965 * dwarf2/read.c (partial_die_info::read): Do not create a vector
6966 of attributes.
6967
6968 2020-04-02 Andrew Burgess <andrew.burgess@embecosm.com>
6969 Bernd Edlinger <bernd.edlinger@hotmail.de>
6970 Tom Tromey <tromey@adacore.com>
6971
6972 * buildsym.c (buildsym_compunit::record_line): Remove
6973 deduplication code.
6974
6975 2020-04-02 Tom de Vries <tdevries@suse.de>
6976
6977 PR ada/24671
6978 * dwarf2/read.c (dw2_map_matching_symbols): Handle -readnow.
6979
6980 2020-04-02 Tom de Vries <tdevries@suse.de>
6981
6982 * dwarf2/read.c (dwarf2_gdb_index_functions,
6983 dwarf2_debug_names_functions): Init lookup_global_symbol_language with
6984 NULL.
6985 * psymtab.c (psym_lookup_global_symbol_language): New function.
6986 (psym_functions): Init psym_lookup_global_symbol_language with
6987 psym_lookup_global_symbol_language.
6988 * symfile-debug.c (debug_sym_quick_functions): Init
6989 lookup_global_symbol_language with NULL.
6990 * symfile.c (set_initial_language): Remove fixme comment.
6991 * symfile.h (struct quick_symbol_functions): Add
6992 lookup_global_symbol_language.
6993 * symtab.c (find_quick_global_symbol_language): New function.
6994 (find_main_name): Use find_quick_global_symbol_language.
6995
6996 2020-04-01 Simon Marchi <simon.marchi@polymtl.ca>
6997
6998 * windows-tdep.c (is_linked_with_cygwin_dll): Fix style.
6999
7000 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
7001
7002 * buildsym.c (record_line): Fix undefined behavior and preserve
7003 lines at eof.
7004
7005 2020-04-01 Bernd Edlinger <bernd.edlinger@hotmail.de>
7006
7007 * buildsym.c (record_line): Fix the resizing condition.
7008
7009 2020-04-01 Tom Tromey <tom@tromey.com>
7010
7011 * value.h (value_literal_complex): Add comment.
7012 * valops.c (value_literal_complex): Refer to value.h.
7013
7014 2020-04-01 Tom Tromey <tom@tromey.com>
7015
7016 * c-exp.y (FLOAT_KEYWORD, COMPLEX): New tokens.
7017 (scalar_type): New rule, from typebase.
7018 (typebase): Use scalar_type. Recognize complex types.
7019 (field_name): Handle FLOAT_KEYWORD.
7020 (ident_tokens): Add _Complex and __complex__.
7021
7022 2020-04-01 Tom Tromey <tom@tromey.com>
7023
7024 PR exp/25299:
7025 * valarith.c (promotion_type, complex_binop): New functions.
7026 (scalar_binop): Handle complex numbers. Use promotion_type.
7027 (value_pos, value_neg, value_complement): Handle complex numbers.
7028
7029 2020-04-01 Tom Tromey <tom@tromey.com>
7030
7031 * c-exp.y (COMPLEX_INT, COMPLEX_FLOAT): New tokens.
7032 (exp) <COMPLEX_INT, COMPLEX_FLOAT>: New rules.
7033 (parse_number): Handle complex numbers.
7034
7035 2020-04-01 Tom Tromey <tom@tromey.com>
7036
7037 * c-valprint.c (c_decorations): Change complex suffix to "i".
7038
7039 2020-04-01 Tom Tromey <tom@tromey.com>
7040
7041 * valprint.c (generic_value_print_complex): Use accessors.
7042 * value.h (value_real_part, value_imaginary_part): Declare.
7043 * valops.c (value_real_part, value_imaginary_part): New
7044 functions.
7045 * value.c (creal_internal_fn, cimag_internal_fn): Use accessors.
7046
7047 2020-04-01 Tom Tromey <tom@tromey.com>
7048
7049 * stabsread.c (rs6000_builtin_type, read_sun_floating_type)
7050 (read_range_type): Update.
7051 * mdebugread.c (basic_type): Update.
7052 * go-lang.c (build_go_types): Use init_complex_type.
7053 * gdbtypes.h (struct main_type) <complex_type>: New member.
7054 (init_complex_type): Update.
7055 (arch_complex_type): Don't declare.
7056 * gdbtypes.c (init_complex_type): Remove "objfile" parameter.
7057 Make name if none given. Use alloc_type_copy. Look for cached
7058 complex type.
7059 (arch_complex_type): Remove.
7060 (gdbtypes_post_init): Use init_complex_type.
7061 * f-lang.c (build_fortran_types): Use init_complex_type.
7062 * dwarf2/read.c (read_base_type): Update.
7063 * d-lang.c (build_d_types): Use init_complex_type.
7064 * ctfread.c (read_base_type): Update.
7065
7066 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7067
7068 * infrun.c (stop_all_threads): Update assertion, plus when
7069 stopping threads, take into account that we might be trying
7070 to stop an all-stop target.
7071 (stop_waiting): Call 'stop_all_threads' if there exists a
7072 non-stop target.
7073
7074 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7075
7076 * target.h (exists_non_stop_target): New function declaration.
7077 * target.c (exists_non_stop_target): New function.
7078
7079 2020-04-01 Hannes Domani <ssbssa@yahoo.de>
7080
7081 PR gdb/24789
7082 * eval.c (is_integral_or_integral_reference): New function.
7083 (evaluate_subexp_standard): Allow integer references in
7084 pointer arithmetic.
7085
7086 2020-04-01 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
7087
7088 * remote.c (remote_target::remote_parse_stop_reply): Remove the
7089 check for no ptid in the stop reply when the target is non-stop.
7090
7091 2020-04-01 Tom Tromey <tromey@adacore.com>
7092
7093 * symtab.h (class lookup_name_info) <lookup_name_info>: Change
7094 "name" parameter to rvalue reference. Initialize m_name_holder.
7095 <lookup_name_info>: New overloads.
7096 <name>: Return gdb::string_view.
7097 <c_str>: New method.
7098 <make_ignore_params>: Update.
7099 <search_name_hash>: Update.
7100 <language_lookup_name>: Return const char *.
7101 <m_name>: Change type.
7102 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info)
7103 (demangle_for_lookup_info::demangle_for_lookup_info): Update.
7104 (lookup_name_info::match_any): Update.
7105 * psymtab.c (match_partial_symbol, lookup_partial_symbol):
7106 Update.
7107 * minsyms.c (linkage_name_str): Update.
7108 * language.c (default_symbol_name_matcher): Update.
7109 * dwarf2/read.c (mapped_index_base::find_name_components_bounds):
7110 Update.
7111 * ada-lang.c (ada_fold_name): Change parameter to string_view.
7112 (ada_lookup_name_info::ada_lookup_name_info): Update.
7113 (literal_symbol_name_matcher): Update.
7114
7115 2020-04-01 Tom Tromey <tromey@adacore.com>
7116
7117 * psymtab.c (psymtab_search_name): Remove function.
7118 (psym_lookup_symbol): Create search name and lookup name here.
7119 (lookup_partial_symbol): Remove "name" parameter; add
7120 lookup_name.
7121 (psym_expand_symtabs_for_function): Update.
7122
7123 2020-03-31 Joel Jones <joelkevinjones@gmail.com>
7124
7125 PR tui/25597:
7126 * python/py-tui.c: Include gdb_curses.h inside of #ifdef TUI.
7127
7128 2020-03-31 Tom Tromey <tromey@adacore.com>
7129
7130 * dwarf2/abbrev.c (abbrev_table::read): Conditionally call
7131 memcpy.
7132
7133 2020-03-30 Nelson Chu <nelson.chu@sifive.com>
7134
7135 * features/riscv/32bit-csr.xml: Regenerated.
7136 * features/riscv/64bit-csr.xml: Regenerated.
7137
7138 2020-03-30 Tom Tromey <tromey@adacore.com>
7139
7140 * ada-valprint.c (print_variant_part): Update.
7141 * ada-lang.h (ada_which_variant_applies): Update.
7142 * ada-lang.c (ada_which_variant_applies): Remove outer_type and
7143 outer_valaddr parameters; replace with "outer" value parameter.
7144 (to_fixed_variant_branch_type): Update.
7145
7146 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
7147
7148 * ppc-linux-nat.c: Include <algorithm>, <unordered_map>, and
7149 <list>. Remove inclusion of observable.h.
7150 (PPC_DEBUG_CURRENT_VERSION): Move up define.
7151 (struct arch_lwp_info): New struct.
7152 (class ppc_linux_dreg_interface): New class.
7153 (struct ppc_linux_process_info): New struct.
7154 (struct ppc_linux_nat_target) <low_delete_thread, low_new_fork>
7155 <low_new_clone, low_forget_process, low_prepare_to_resume>
7156 <copy_thread_dreg_state, mark_thread_stale>
7157 <mark_debug_registers_changed, register_hw_breakpoint>
7158 <clear_hw_breakpoint, register_wp, clear_wp>
7159 <can_use_watchpoint_cond_accel, calculate_dvc, check_condition>
7160 <num_memory_accesses, get_trigger_type>
7161 <create_watchpoint_request, hwdebug_point_cmp>
7162 <init_arch_lwp_info, get_arch_lwp_info>
7163 <low_stopped_by_watchpoint, low_stopped_data_address>: Declare as
7164 methods.
7165 <struct ptid_hash>: New inner struct.
7166 <m_dreg_interface, m_process_info, m_installed_hw_bps>: Declare
7167 members.
7168 (saved_dabr_value, hwdebug_info, max_slots_number)
7169 (struct hw_break_tuple, struct thread_points, ppc_threads)
7170 (have_ptrace_hwdebug_interface)
7171 (hwdebug_find_thread_points_by_tid)
7172 (hwdebug_insert_point, hwdebug_remove_point): Remove.
7173 (ppc_linux_nat_target::can_use_hw_breakpoint): Use
7174 m_dreg_interface, remove call to PTRACE_SET_DEBUGREG.
7175 (ppc_linux_nat_target::region_ok_for_hw_watchpoint): Add comment,
7176 use m_dreg_interface.
7177 (hwdebug_point_cmp): Change to...
7178 (ppc_linux_nat_target::hwdebug_point_cmp): ...this method. Use
7179 reference arguments instead of pointers.
7180 (ppc_linux_nat_target::ranged_break_num_registers): Use
7181 m_dreg_interface.
7182 (ppc_linux_nat_target::insert_hw_breakpoint): Add comment, use
7183 m_dreg_interface. Call register_hw_breakpoint.
7184 (ppc_linux_nat_target::remove_hw_breakpoint): Add comment, use
7185 m_dreg_interface. Call clear_hw_breakpoint.
7186 (get_trigger_type): Change to...
7187 (ppc_linux_nat_target::get_trigger_type): ...this method. Add
7188 comment.
7189 (ppc_linux_nat_target::insert_mask_watchpoint): Update comment,
7190 use m_dreg_interface. Call register_hw_breakpoint.
7191 (ppc_linux_nat_target::remove_mask_watchpoint): Update comment,
7192 use m_dreg_interface. Call clear_hw_breakpoint.
7193 (can_use_watchpoint_cond_accel): Change to...
7194 (ppc_linux_nat_target::can_use_watchpoint_cond_accel): ...this
7195 method. Update comment, use m_dreg_interface and
7196 m_process_info.
7197 (calculate_dvc): Change to...
7198 (ppc_linux_nat_target::calculate_dvc): ...this method. Use
7199 m_dreg_interface.
7200 (num_memory_accesses): Change to...
7201 (ppc_linux_nat_target::num_memory_accesses): ...this method.
7202 (check_condition): Change to...
7203 (ppc_linux_nat_target::check_condition): ...this method.
7204 (ppc_linux_nat_target::can_accel_watchpoint_condition): Update
7205 comment, use m_dreg_interface.
7206 (create_watchpoint_request): Change to...
7207 (ppc_linux_nat_target::create_watchpoint_request): ...this
7208 method. Use m_dreg_interface.
7209 (ppc_linux_nat_target::insert_watchpoint): Add comment, use
7210 m_dreg_interface. Call register_hw_breakpoint or register_wp.
7211 (ppc_linux_nat_target::remove_watchpoint): Add comment, use
7212 m_dreg_interface. Call clear_hw_breakpoint or clear_wp.
7213 (ppc_linux_nat_target::low_forget_process)
7214 (ppc_linux_nat_target::low_new_fork)
7215 (ppc_linux_nat_target::low_new_clone)
7216 (ppc_linux_nat_target::low_delete_thread)
7217 (ppc_linux_nat_target::low_prepare_to_resume): New methods.
7218 (ppc_linux_nat_target::low_new_thread): Remove previous logic,
7219 only call mark_thread_stale.
7220 (ppc_linux_thread_exit): Remove.
7221 (ppc_linux_nat_target::stopped_data_address): Change to...
7222 (ppc_linux_nat_target::low_stopped_data_address): This. Add
7223 comment, use m_dreg_interface and m_thread_hw_breakpoints.
7224 (ppc_linux_nat_target::stopped_by_watchpoint): Change to...
7225 (ppc_linux_nat_target::stopped_by_watchpoint): This. Add
7226 comment. Call low_stopped_data_address.
7227 (ppc_linux_nat_target::watchpoint_addr_within_range): Use
7228 m_dreg_interface.
7229 (ppc_linux_nat_target::masked_watch_num_registers): Use
7230 m_dreg_interface.
7231 (ppc_linux_nat_target::copy_thread_dreg_state)
7232 (ppc_linux_nat_target::mark_thread_stale)
7233 (ppc_linux_nat_target::mark_debug_registers_changed)
7234 (ppc_linux_nat_target::register_hw_breakpoint)
7235 (ppc_linux_nat_target::clear_hw_breakpoint)
7236 (ppc_linux_nat_target::register_wp)
7237 (ppc_linux_nat_target::clear_wp)
7238 (ppc_linux_nat_target::init_arch_lwp_info)
7239 (ppc_linux_nat_target::get_arch_lwp_info): New methods.
7240 (_initialize_ppc_linux_nat): Remove observer callback.
7241
7242 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
7243
7244 * ppc-linux-nat.c (ppc_linux_nat_target::store_registers)
7245 (ppc_linux_nat_target::auxv_parse)
7246 (ppc_linux_nat_target::read_description)
7247 (supply_gregset, fill_gregset, supply_fpregset, fill_fpregset):
7248 Move up.
7249
7250 2020-03-30 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
7251
7252 * linux-nat.h (low_new_clone): New method.
7253 * linux-nat.c (linux_handle_extended_wait): Call low_new_clone.
7254
7255 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
7256
7257 * dbxread.c (dbx_psymtab_to_symtab_1): Rename to...
7258 (dbx_expand_psymtab): ... this.
7259 (start_psymtab): Update.
7260 * mdebugread.c (psymtab_to_symtab_1): Rename to...
7261 (mdebug_expand_psymtab): ... this.
7262 (parse_partial_symbols): Update.
7263 (new_psymtab): Update.
7264 * xcoffread.c (xcoff_psymtab_to_symtab_1): Rename to...
7265 (xcoff_expand_psymtab): ... this.
7266 (xcoff_start_psymtab): Update.
7267
7268 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
7269
7270 * psympriv.h (partial_symtab) <read_dependencies>: Rename to...
7271 <expand_dependencies>: ... this.
7272 * psymtab.c (partial_symtab::read_dependencies): Rename to...
7273 (partial_symtab::expand_dependencies): ... this.
7274 * dwarf2/read.c (dwarf2_include_psymtab) <expand_psymtab>:
7275 Update.
7276 (dwarf2_psymtab::expand_psymtab): Update.
7277 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
7278 * mdebugread.c (psymtab_to_symtab_1): Update.
7279 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
7280
7281 2020-03-29 Simon Marchi <simon.marchi@polymtl.ca>
7282
7283 * psympriv.h (discard_psymtab): Remove.
7284 * dbxread.c (dbx_end_psymtab): Update.
7285 * xcoffread.c (xcoff_end_psymtab): Update.
7286
7287 2020-03-28 Tom Tromey <tom@tromey.com>
7288
7289 * dwarf2/attribute.h (struct attribute) <form_is_constant>: Update
7290 comment.
7291
7292 2020-03-28 Tom Tromey <tom@tromey.com>
7293
7294 * dwarf2/read.c (read_attribute_reprocess): Fix formatting.
7295
7296 2020-03-27 Hannes Domani <ssbssa@yahoo.de>
7297
7298 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
7299
7300 2020-03-26 John Baldwin <jhb@FreeBSD.org>
7301
7302 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_FREEBSD_BSDFLAGS.
7303
7304 2020-03-26 Tom Tromey <tom@tromey.com>
7305
7306 * dwarf2/read.c (handle_data_member_location, dwarf2_add_field)
7307 (mark_common_block_symbol_computed, read_tag_string_type)
7308 (attr_to_dynamic_prop, read_subrange_type): Update.
7309 (dwarf2_get_ref_die_offset, dwarf2_get_attr_constant_value): Move
7310 to be methods on struct attribute.
7311 (skip_one_die, process_imported_unit_die, read_namespace_alias)
7312 (read_call_site_scope, partial_die_info::read)
7313 (partial_die_info::read, lookup_die_type, follow_die_ref):
7314 Update.
7315 * dwarf2/attribute.c (attribute::get_ref_die_offset): New method,
7316 from dwarf2_get_ref_die_offset.
7317 (attribute::constant_value): New method, from
7318 dwarf2_get_attr_constant_value.
7319 * dwarf2/attribute.h (struct attribute) <get_ref_die_offset>:
7320 Declare method.
7321 <constant_value>: New method.
7322
7323 2020-03-26 Tom Tromey <tom@tromey.com>
7324
7325 * dwarf2/read.c (dwarf_unit_type_name, dwarf_tag_name)
7326 (dwarf_attr_name, dwarf_form_name, dwarf_bool_name)
7327 (dwarf_type_encoding_name): Move to stringify.c.
7328 * Makefile.in (COMMON_SFILES): Add dwarf2/stringify.c.
7329 * dwarf2/stringify.c: New file.
7330 * dwarf2/stringify.h: New file.
7331
7332 2020-03-26 Tom Tromey <tom@tromey.com>
7333
7334 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>:
7335 Rewrite.
7336
7337 2020-03-26 Tom Tromey <tom@tromey.com>
7338
7339 * dwarf2/die.h (struct die_info) <addr_base, ranges_base>: New
7340 methods.
7341 * dwarf2/read.c (lookup_addr_base): Move to die.h.
7342 (lookup_ranges_base): Likewise.
7343 (read_cutu_die_from_dwo, read_full_die_1): Update.
7344
7345 2020-03-26 Tom Tromey <tom@tromey.com>
7346
7347 * dwarf2/read.c (read_import_statement, read_file_scope)
7348 (read_type_unit_scope, inherit_abstract_dies, read_func_scope)
7349 (read_lexical_block_scope, read_call_site_scope)
7350 (dwarf2_get_subprogram_pc_bounds, get_scope_pc_bounds)
7351 (handle_struct_member_die, process_structure_scope)
7352 (update_enumeration_type_from_children)
7353 (process_enumeration_scope, read_array_type, read_common_block)
7354 (read_namespace, read_module, read_subroutine_type): Update.
7355 (sibling_die): Remove.
7356
7357 2020-03-26 Tom Tromey <tom@tromey.com>
7358
7359 * dwarf2/read.c (lookup_addr_base, lookup_ranges_base)
7360 (build_type_psymtabs_reader, read_structure_type)
7361 (read_enumeration_type, read_full_die_1): Update.
7362 (dwarf2_attr_no_follow): Move to die.h.
7363 * dwarf2/die.h (struct die_info) <attr>: New method.
7364
7365 2020-03-26 Tom Tromey <tom@tromey.com>
7366
7367 * dwarf2/read.c (struct dwarf2_cu) <base_known>: Remove.
7368 <base_address>: Now an optional.
7369 (dwarf2_find_base_address, dwarf2_rnglists_process)
7370 (dwarf2_ranges_process, fill_in_loclist_baton)
7371 (dwarf2_symbol_mark_computed): Update.
7372
7373 2020-03-26 Tom Tromey <tom@tromey.com>
7374
7375 * dwarf2/read.c (struct die_info): Move to die.h.
7376 * dwarf2/die.h: New file.
7377
7378 2020-03-26 Tom Tromey <tom@tromey.com>
7379
7380 * dwarf2/line-header.h (dwarf_decode_line_header): Declare.
7381 * dwarf2/read.c
7382 (dwarf2_statement_list_fits_in_line_number_section_complaint):
7383 Move to line-header.c.
7384 (read_checked_initial_length_and_offset, read_formatted_entries):
7385 Likewise.
7386 (dwarf_decode_line_header): Split into two.
7387 * dwarf2/line-header.c
7388 (dwarf2_statement_list_fits_in_line_number_section_complaint):
7389 Move from read.c.
7390 (read_checked_initial_length_and_offset, read_formatted_entries):
7391 Likewise.
7392 (dwarf_decode_line_header): New function, split from read.c.
7393
7394 2020-03-26 Tom Tromey <tom@tromey.com>
7395
7396 * dwarf2/read.h (struct dwarf2_per_objfile) <read_line_string>:
7397 Declare method.
7398 * dwarf2/read.c (read_attribute_value): Update.
7399 (dwarf2_per_objfile::read_line_string): Rename from
7400 read_indirect_line_string.
7401 (read_formatted_entries): Update.
7402
7403 2020-03-26 Tom Tromey <tom@tromey.com>
7404
7405 * dwarf2/macro.c (dwarf_decode_macro_bytes): Use objfile local
7406 variable.
7407
7408 2020-03-26 Tom Tromey <tom@tromey.com>
7409
7410 * dwarf2/macro.h (dwarf_decode_macros): Make section parameter
7411 const.
7412 * dwarf2/macro.c (skip_form_bytes, skip_unknown_opcode)
7413 (dwarf_decode_macro_bytes, dwarf_decode_macros): Make section
7414 parameter const.
7415
7416 2020-03-26 Tom Tromey <tom@tromey.com>
7417
7418 * dwarf2/read.c (dwarf_decode_macros): Make "lh" const.
7419 * dwarf2/macro.h (dwarf_decode_macros): Constify "lh" parameter.
7420 * dwarf2/macro.c (macro_start_file): Constify "lh" parameter.
7421 (dwarf_decode_macro_bytes, dwarf_decode_macros): Likewise.
7422
7423 2020-03-26 Tom Tromey <tom@tromey.com>
7424
7425 * dwarf2/line-header.h (struct line_header) <is_valid_file_index,
7426 file_names_size, file_full_name, file_file_name>: Use const.
7427 <file_name_at, file_names>: Add const overload.
7428 * dwarf2/line-header.c (line_header::file_file_name)
7429 (line_header::file_full_name): Update.
7430
7431 2020-03-26 Tom Tromey <tom@tromey.com>
7432
7433 * dwarf2/read.c (dwarf2_macro_malformed_definition_complaint)
7434 (macro_start_file, consume_improper_spaces)
7435 (parse_macro_definition, skip_form_bytes, skip_unknown_opcode)
7436 (dwarf_parse_macro_header, dwarf_decode_macro_bytes)
7437 (dwarf_decode_macros): Move to macro.c.
7438 * dwarf2/macro.c: New file.
7439 * dwarf2/macro.h: New file.
7440 * Makefile.in (COMMON_SFILES): Add dwarf2/macro.c.
7441
7442 2020-03-26 Tom Tromey <tom@tromey.com>
7443
7444 * dwarf2/section.h (struct dwarf2_section_info) <read_string>: New
7445 method.
7446 * dwarf2/section.c: New method. From
7447 read_indirect_string_at_offset_from.
7448 * dwarf2/read.c (mapped_debug_names::namei_to_name): Update.
7449 (read_indirect_string_at_offset_from): Move to section.c.
7450 (read_indirect_string_at_offset): Rewrite.
7451 (read_indirect_line_string_at_offset): Remove.
7452 (read_indirect_string, read_indirect_line_string)
7453 (dwarf_decode_macro_bytes): Update.
7454
7455 2020-03-26 Tom Tromey <tom@tromey.com>
7456
7457 * dwarf2/section.h (struct dwarf2_section_info)
7458 <overload_complaint>: Declare.
7459 (dwarf2_section_buffer_overflow_complaint): Don't declare.
7460 * dwarf2/section.c (dwarf2_section_info::overflow_complaint):
7461 Rename from dwarf2_section_buffer_overflow_complaint.
7462 * dwarf2/read.c (skip_one_die, partial_die_info::read)
7463 (skip_form_bytes, dwarf_decode_macro_bytes): Update.
7464
7465 2020-03-26 Tom Tromey <tom@tromey.com>
7466
7467 * dwarf2/section.h (dwarf2_section_buffer_overflow_complaint):
7468 Declare.
7469 * dwarf2/section.c (dwarf2_section_buffer_overflow_complaint):
7470 Move from read.c.
7471 * dwarf2/read.c (dwarf2_section_buffer_overflow_complaint): Move
7472 to section.c.
7473
7474 2020-03-26 Tom Tromey <tom@tromey.com>
7475
7476 * dwarf2/read.c (dwarf_decode_macros): Split into two overloads.
7477
7478 2020-03-26 Tom Tromey <tom@tromey.com>
7479
7480 * dwarf2/read.c (macro_start_file): Change "cu" parameter to
7481 "builder".
7482 (dwarf_decode_macro_bytes): Likewise. Add dwarf2_per_objfile
7483 parameter.
7484 (dwarf_decode_macros): Update.
7485
7486 2020-03-26 Tom Tromey <tom@tromey.com>
7487
7488 * dwarf2/read.c (read_attribute_value): Update.
7489 (read_indirect_string_from_dwz): Move to dwz.c; change into
7490 method.
7491 (dwarf_decode_macro_bytes): Update.
7492 * dwarf2/dwz.h (struct dwz_file) <read_string>: Declare method.
7493 * dwarf2/dwz.c: New file.
7494 * Makefile.in (COMMON_SFILES): Add dwz.c.
7495
7496 2020-03-26 Tom Tromey <tom@tromey.com>
7497
7498 * dwarf2/read.h (struct dwz_file): Move to dwz.h.
7499 * dwarf2/read.c: Add include.
7500 * dwarf2/index-write.c: Add include.
7501 * dwarf2/index-cache.c: Add include.
7502 * dwarf2/dwz.h: New file.
7503
7504 2020-03-25 Tom Tromey <tom@tromey.com>
7505
7506 * compile/compile-object-load.c (get_out_value_type): Mention
7507 correct symbol name in error message.
7508
7509 2020-03-25 Hannes Domani <ssbssa@yahoo.de>
7510
7511 * windows-nat.c (windows_add_all_dlls): Fix system dll paths.
7512
7513 2020-03-25 Tom de Vries <tdevries@suse.de>
7514
7515 * symtab.h (is_main_symtab_of_compunit_symtab): New function.
7516 * symmisc.c (dump_symtab_1): Print user and includes fields.
7517 (maintenance_info_symtabs): Same.
7518
7519 2020-03-25 Andrew Burgess <andrew.burgess@embecosm.com>
7520
7521 PR gdb/25534
7522 * riscv-tdep.c (riscv_arg_info::c_offset): Update comment.
7523 (riscv_regcache_cooked_write): New function.
7524 (riscv_push_dummy_call): Use new function.
7525 (riscv_return_value): Likewise.
7526
7527 2020-03-24 Simon Marchi <simon.marchi@polymtl.ca>
7528
7529 * fbsd-nat.c (fbsd_nat_target::follow_fork): Change bool to int.
7530 * fbsd-nat.h (class fbsd_nat_target) <follow_fork>: Likewise.
7531 * inf-ptrace.c (inf_ptrace_target::follow_fork): Likewise.
7532 * inf-ptrace.h (struct inf_ptrace_target) <follow_fork>: Likewise.
7533 * infrun.c (follow_fork): Likewise.
7534 (follow_fork_inferior): Likewise.
7535 * linux-nat.c (linux_nat_target::follow_fork): Likewise.
7536 * linux-nat.h (class linux_nat_target): Likewise.
7537 * remote.c (class remote_target) <follow_fork>: Likewise.
7538 (remote_target::follow_fork): Likewise.
7539 * target-delegates.c: Re-generate.
7540 * target.c (default_follow_fork): Likewise.
7541 (target_follow_fork): Likewise.
7542 * target.h (struct target_ops) <follow_fork>: Likewise.
7543 (target_follow_fork): Likewise.
7544
7545 2020-03-24 Tom de Vries <tdevries@suse.de>
7546
7547 * psymtab.c (maintenance_info_psymtabs): Print user field.
7548
7549 2020-03-20 Tom Tromey <tromey@adacore.com>
7550
7551 * dwarf2/loc.h (dwarf2_evaluate_property): Make "addr_stack"
7552 const.
7553 * dwarf2/loc.c (dwarf2_evaluate_property): Make "addr_stack"
7554 const.
7555
7556 2020-03-20 Simon Marchi <simon.marchi@efficios.com>
7557
7558 * ptrace.m4: Don't check for ptrace declaration.
7559 * config.in: Re-generate.
7560 * configure: Re-generate.
7561 * nat/gdb_ptrace.h: Don't declare ptrace if HAVE_DECL_PTRACE is
7562 not defined.
7563
7564 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7565
7566 * amd64-bsd-nat.c (gdb_ptrace): Change return type from `int' to
7567 `PTRACE_TYPE_RET'.
7568 * i386-bsd-nat.c (gdb_ptrace): Likewise.
7569 * sparc-nat.c (gdb_ptrace): Likewise.
7570 * x86-bsd-nat.c (gdb_ptrace): Likewise.
7571
7572 2020-03-20 Tom Tromey <tromey@adacore.com>
7573
7574 * c-exp.y (lex_one_token): Fix assert.
7575
7576 2020-03-20 Tom Tromey <tromey@adacore.com>
7577
7578 * ada-tasks.c (read_atcb): Use smaller length in strncpy call.
7579 * linux-tdep.c (linux_fill_prpsinfo): Use smaller length in
7580 strncpy call.
7581
7582 2020-03-20 Tom Tromey <tromey@adacore.com>
7583
7584 * symmisc.c (maintenance_print_one_line_table): Use ui_out.
7585
7586 2020-03-20 Tom Tromey <tromey@adacore.com>
7587
7588 * ada-valprint.c (print_variant_part): Remove parameters; switch
7589 to value-based API.
7590 (print_field_values): Likewise.
7591 (ada_val_print_struct_union): Likewise.
7592 (ada_value_print_1): Update.
7593
7594 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7595
7596 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): Inherit from
7597 nbsd_nat_target instead of inf_ptrace_target.
7598 * ppc-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7599 nbsd_nat_target.
7600
7601 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7602
7603 * hppa-nbsd-nat.c (fetch_registers): New variable lwp and pass
7604 it to the ptrace call.
7605 * (store_registers): Likewise.
7606
7607 2020-03-20 Kamil Rytarowski <n54@gmx.com>
7608
7609 * ppc-nbsd-nat.c (fetch_registers): New variable lwp and pass
7610 it to the ptrace call.
7611 * (store_registers): Likewise.
7612
7613 2020-03-19 Luis Machado <luis.machado@linaro.org>
7614
7615 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_set_vq): If vg is not
7616 valid, fetch vg value from ptrace.
7617
7618 2020-03-19 Kamil Rytarowski <n54@gmx.com>
7619 * inf-ptrace.h: Disable get_ptrace_pid on NetBSD.
7620 * inf-ptrace.c: Likewise.
7621 * (gdb_ptrace): Add.
7622 * (inf_ptrace_target::resume): Update.
7623 * (inf_ptrace_target::xfer_partial): Likewise.
7624 * (inf_ptrace_peek_poke): Change argument `pid' to `ptid'.
7625 * (inf_ptrace_peek_poke): Update.
7626
7627 2020-03-19 Kamil Rytarowski <n54@gmx.com>
7628
7629 * x86-bsd-nat.c (gdb_ptrace): New.
7630 * (x86bsd_dr_set): Add new argument `ptid'.
7631 * (x86bsd_dr_get, x86bsd_dr_set, x86bsd_dr_set_control,
7632 x86bsd_dr_set_addr): Update.
7633
7634 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7635
7636 * remote.c (remote_target::process_stop_reply): Handle events for
7637 all threads differently.
7638
7639 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7640
7641 * completer.c (completion_tracker::remove_completion): Define new
7642 function.
7643 * completer.h (completion_tracker::remove_completion): Declare new
7644 function.
7645 * symtab.c (completion_list_add_symbol): Remove aliasing msymbols
7646 when adding a C++ function symbol.
7647
7648 2020-03-19 Andrew Burgess <andrew.burgess@embecosm.com>
7649
7650 * completer.c (completion_tracker::completion_hash_entry): Define
7651 new class.
7652 (advance_to_filename_complete_word_point): Call
7653 recompute_lowest_common_denominator.
7654 (completion_tracker::completion_tracker): Call discard_completions
7655 to setup the hash table.
7656 (completion_tracker::discard_completions): Allow for being called
7657 from the constructor, pass new equal function, and element deleter
7658 when constructing the hash table. Initialise new class member
7659 variables.
7660 (completion_tracker::maybe_add_completion): Remove use of
7661 m_entries_vec, and store more information into m_entries_hash.
7662 (completion_tracker::recompute_lcd_visitor): New function, most
7663 content taken from...
7664 (completion_tracker::recompute_lowest_common_denominator):
7665 ...here, this now just visits each item in the hash calling the
7666 above visitor.
7667 (completion_tracker::build_completion_result): Remove use of
7668 m_entries_vec, call recompute_lowest_common_denominator.
7669 * completer.h (completion_tracker::have_completions): Remove use
7670 of m_entries_vec.
7671 (completion_tracker::completion_hash_entry): Declare new class.
7672 (completion_tracker::recompute_lowest_common_denominator): Change
7673 function signature.
7674 (completion_tracker::recompute_lcd_visitor): Declare new function.
7675 (completion_tracker::m_entries_vec): Delete.
7676 (completion_tracker::m_entries_hash): Initialize to NULL.
7677 (completion_tracker::m_lowest_common_denominator_valid): New
7678 member variable.
7679 (completion_tracker::m_lowest_common_denominator_max_length): New
7680 member variable.
7681
7682 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7683
7684 * regformats/regdef.h: Put reg in gdb namespace.
7685
7686 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7687
7688 * i386-bsd-nat.c (gdb_ptrace): New.
7689 * (i386bsd_fetch_inferior_registers,
7690 i386bsd_store_inferior_registers) Switch from pid_t to ptid_t.
7691 * (i386bsd_fetch_inferior_registers,
7692 i386bsd_store_inferior_registers) Use gdb_ptrace.
7693
7694 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7695
7696 * amd64-bsd-nat.c (gdb_ptrace): New.
7697 * (amd64bsd_fetch_inferior_registers,
7698 amd64bsd_store_inferior_registers) Switch from pid_t to ptid_t.
7699 * (amd64bsd_fetch_inferior_registers,
7700 amd64bsd_store_inferior_registers) Use gdb_ptrace.
7701
7702 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7703
7704 * user-regs.c (user_reg::read): Rename to...
7705 (user_reg::xread): ...this.
7706 * (append_user_reg): Rename argument `read' to `xread'.
7707 * (user_reg_add_builtin): Likewise.
7708 * (user_reg_add): Likewise.
7709 * (value_of_user_reg): Likewise.
7710
7711 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7712
7713 * sparc-nat.c (gdb_ptrace): New.
7714 * sparc-nat.c (sparc_fetch_inferior_registers)
7715 (sparc_store_inferior_registers) Remove obsolete comment.
7716 * sparc-nat.c (sparc_fetch_inferior_registers)
7717 (sparc_store_inferior_registers) Switch from pid_t to ptid_t.
7718 * sparc-nat.c (sparc_fetch_inferior_registers)
7719 (sparc_store_inferior_registers) Use gdb_ptrace.
7720
7721 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7722
7723 * sh-nbsd-nat.c (fetch_registers): New variable lwp and pass
7724 it to the ptrace call.
7725 * sh-nbsd-nat.c (store_registers): Likewise.
7726
7727 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7728
7729 * sh-nbsd-nat.c (sh_nbsd_nat_target): Inherit from
7730 nbsd_nat_target instead of inf_ptrace_target.
7731 * sh-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7732 nbsd_nat_target.
7733
7734 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7735
7736 * amd64-bsd-nat.c: Include amd64-bsd-nat.h".
7737
7738 2020-03-17 Kamil Rytarowski <n54@gmx.com>
7739
7740 * nbsd-nat.c: Include <sys/types.h>, <sys/ptrace.h> and
7741 <sys/sysctl.h>.
7742 * nbsd-nat.c (nbsd_nat_target::pid_to_exec_file): Rewrite.
7743
7744 2020-03-17 Tom de Vries <tdevries@suse.de>
7745
7746 PR gdb/23710
7747 * dwarf2/read.h (struct dwarf2_per_cu_data): Add unit_type and lang
7748 fields.
7749 * dwarf2/read.c (process_psymtab_comp_unit): Initialize unit_type and lang
7750 fields.
7751 (process_imported_unit_die): Skip import of c++ CUs.
7752
7753 2020-03-16 Tom Tromey <tom@tromey.com>
7754
7755 * p-valprint.c (pascal_object_print_value): Initialize
7756 base_value.
7757
7758 2020-03-16 Anton Kolesov <anton.kolesov@synopsys.com>
7759 Shahab Vahedi <shahab@synopsys.com>
7760
7761 * Makefile.in: Add arch/arc.o
7762 * configure.tgt: Likewise.
7763 * arc-tdep.c (arc_tdesc_init): Use arc_read_description.
7764 (_initialize_arc_tdep): Don't initialize old target descriptions.
7765 (arc_read_description): New function to cache target descriptions.
7766 * arc-tdep.h (arc_read_description): Add proto type.
7767 * arch/arc.c: New file.
7768 * arch/arc.h: Likewise.
7769 * features/Makefile: Replace old target descriptions with new.
7770 * features/arc-arcompact.c: Remove.
7771 * features/arc-arcompact.xml: Likewise.
7772 * features/arc-v2.c: Likewise
7773 * features/arc-v2.xml: Likewise
7774 * features/arc/aux-arcompact.xml: New file.
7775 * features/arc/aux-v2.xml: Likewise.
7776 * features/arc/core-arcompact.xml: Likewise.
7777 * features/arc/core-v2.xml: Likewise.
7778 * features/arc/aux-arcompact.c: Generate.
7779 * features/arc/aux-v2.c: Likewise.
7780 * features/arc/core-arcompact.c: Likewise.
7781 * features/arc/core-v2.c: Likewise.
7782 * target-descriptions (maint_print_c_tdesc_cmd): Support ARC features.
7783
7784 2020-03-16 Tom Tromey <tromey@adacore.com>
7785
7786 PR gdb/25663:
7787 * dwarf2/read.c (dwarf2_name): Strip leading namespaces after
7788 putting value into bcache.
7789
7790 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7791
7792 PR gdb/21500
7793 * amd64-windows-tdep.c (amd64_windows_init_abi): Rename
7794 to...
7795 (amd64_windows_init_abi_common): ... this. Don't set size of
7796 long type.
7797 (amd64_windows_init_abi): New function.
7798 (amd64_cygwin_init_abi): New function.
7799 (_initialize_amd64_windows_tdep): Use amd64_cygwin_init_abi for
7800 the Cygwin OS ABI.
7801 * i386-windows-tdep.c (_initialize_i386_windows_tdep): Clarify
7802 comment.
7803
7804 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7805
7806 * windows-tdep.h (is_linked_with_cygwin_dll): New declaration.
7807 * windows-tdep.c (CYGWIN_DLL_NAME): New.
7808 (pe_import_directory_entry): New struct type.
7809 (is_linked_with_cygwin_dll): New function.
7810 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Select
7811 GDB_OSABI_CYGWIN if the BFD is linked with the Cygwin DLL.
7812 * i386-windows-tdep.c (i386_windows_osabi_sniffer): Likewise.
7813
7814 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7815
7816 * i386-windows-tdep.c: Mass-rename "cygwin" to "windows", except
7817 i386_cygwin_core_osabi_sniffer.
7818
7819 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7820
7821 * i386-cygwin-tdep.c: Rename to...
7822 * i386-windows-tdep.c: ... this.
7823 * Makefile.in (ALL_TARGET_OBS): Rename i386-cygwin-tdep.c to
7824 i386-windows-tdep.c.
7825 * configure.tgt: Likewise.
7826
7827 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7828
7829 * osabi.h (enum gdb_osabi): Add GDB_OSABI_WINDOWS.
7830 * osabi.c (gdb_osabi_names): Add "Windows".
7831 * i386-cygwin-tdep.c (i386_cygwin_osabi_sniffer): Return
7832 GDB_OSABI_WINDOWS when the binary's target is "pei-i386".
7833 (i386_cygwin_core_osabi_sniffer): New function, extracted from
7834 i386_cygwin_osabi_sniffer.
7835 (_initialize_i386_cygwin_tdep): Register OS ABI
7836 GDB_OSABI_WINDOWS for i386.
7837 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): Return
7838 GDB_OSABI_WINDOWS when the binary's target is "pei-x86-64".
7839 (_initialize_amd64_windows_tdep): Register OS ABI GDB_OSABI_WINDOWS
7840 for x86-64.
7841 * configure.tgt: Use GDB_OSABI_WINDOWS as the default OS ABI
7842 when the target matches '*-*-mingw*'.
7843
7844 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7845
7846 * defs.h (enum gdb_osabi): Move to...
7847 * osabi.h (enum gdb_osabi): ... here.
7848 * gdbarch.sh: Include osabi.h in gdbarch.h.
7849 * gdbarch.h: Re-generate.
7850
7851 2020-03-16 Simon Marchi <simon.marchi@efficios.com>
7852
7853 * amd64-windows-tdep.c (amd64_windows_osabi_sniffer): New
7854 function.
7855 (_initialize_amd64_windows_tdep): Register osabi sniffer.
7856
7857 2020-03-14 Tom Tromey <tom@tromey.com>
7858
7859 * c-typeprint.c (cp_type_print_method_args): Print "__restrict__"
7860 for C++.
7861 (c_type_print_modifier): Likewise. Add "language" parameter.
7862 (c_type_print_varspec_prefix, c_type_print_base_struct_union)
7863 (c_type_print_base_1): Update.
7864 * type-stack.h (enum type_pieces) <tp_atomic, tp_restrict>: New
7865 constants.
7866 * type-stack.c (type_stack::insert): Handle tp_atomic and
7867 tp_restrict.
7868 (type_stack::follow_type_instance_flags): Likewise.
7869 (type_stack::follow_types): Likewise. Merge type-following code.
7870 * c-exp.y (RESTRICT, ATOMIC): New tokens.
7871 (space_identifier, cv_with_space_id)
7872 (const_or_volatile_or_space_identifier_noopt)
7873 (const_or_volatile_or_space_identifier): Remove.
7874 (single_qualifier, qualifier_seq_noopt, qualifier_seq): New
7875 rules.
7876 (ptr_operator, typebase): Update.
7877 (enum token_flag) <FLAG_C>: New constant.
7878 (ident_tokens): Add "restrict", "__restrict__", "__restrict", and
7879 "_Atomic".
7880 (lex_one_token): Handle FLAG_C.
7881
7882 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7883
7884 * m68k-bsd-nat.c (fetch_registers): New variable lwp and pass
7885 it to the ptrace call.
7886 * m68k-bsd-nat.c (store_registers): Likewise.
7887
7888 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7889
7890 * m68k-bsd-nat.c (m68kbsd_supply_gregset): Change type of regs to
7891 gdb_byte *.
7892 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
7893 * m68k-bsd-nat.c (m68kbsd_collect_gregset): Likewise.
7894 * m68k-bsd-nat.c (m68kbsd_supply_pcb): Cast &tmp to gdb_byte *.
7895
7896 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7897
7898 * m68k-bsd-nat.c (m68k_bsd_nat_target): Inherit from
7899 nbsd_nat_target instead of inf_ptrace_target.
7900 * m68k-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7901 nbsd_nat_target.
7902
7903 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7904
7905 * m68k-bsd-nat.c: Define _KERNTYPES to get the declaration of
7906 register_t.
7907
7908 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7909
7910 * alpha-bsd-nat.c (fetch_registers): New variable lwp and pass
7911 it to the ptrace call.
7912 * alpha-bsd-nat.c (store_registers): Likewise.
7913
7914 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7915
7916 * alpha-bsd-nat.c: Remove <sys/procfs.h> and "gregset.h" from
7917 includes.
7918 * alpha-bsd-nat.c (gregset_t, fpregset_t): Remove.
7919 * alpha-bsd-nat.c (supply_gregset, fill_gregset, supply_fpregset,
7920 fill_fpregset): Likewise.
7921
7922 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7923
7924 * alpha-bsd-nat.c (alpha_netbsd_nat_target): Inherit from
7925 nbsd_nat_target instead of inf_ptrace_target.
7926 * alpha-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7927 nbsd_nat_target.
7928
7929 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7930
7931 * alpha-bsd-nat.c: Define _KERNTYPES to get the declaration of
7932 register_t.
7933
7934 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7935
7936 * arm-nbsd-nat.c (fetch_register): New variable lwp and pass
7937 it to the ptrace call.
7938 * arm-nbsd-nat.c (fetch_fp_register): Likewise.
7939 * arm-nbsd-nat.c (fetch_fp_regs): Likewise.
7940 * arm-nbsd-nat.c (store_register): Likewise.
7941 * arm-nbsd-nat.c (store_regs): Likewise.
7942 * arm-nbsd-nat.c (store_fp_register): Likewise.
7943 * arm-nbsd-nat.c (store_fp_regs): Likewise.
7944
7945 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7946
7947 * arm-nbsd-nat.c (arm_netbsd_nat_target): Inherit from
7948 nbsd_nat_target instead of inf_ptrace_target.
7949 * arm-nbsd-nat.c: Include "nbsd-nat.h", as we are now using
7950 nbsd_nat_target.
7951
7952 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7953
7954 * x86-bsd-nat.c (x86bsd_dr_get): New variable lwp and pass
7955 it to the ptrace call.
7956 * x86-bsd-nat.c (x86bsd_dr_set): Likewise.
7957
7958 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7959
7960 * vax-bsd-nat.c (vaxbsd_supply_gregset): New variable lwp and pass
7961 it to the ptrace call.
7962 * vax-bsd-nat.c (vaxbsd_collect_gregset): Likewise.
7963
7964 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7965
7966 * vax-bsd-nat.c (vaxbsd_supply_gregset): Cast gregs to const
7967 gdb_byte *.
7968 * vax-bsd-nat.c (vaxbsd_collect_gregset): Cast gregs to void *.
7969
7970 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7971
7972 * vax-bsd-nat.c (vax_bsd_nat_target): Inherit from nbsd_nat_target
7973 instead of inf_ptrace_target.
7974 * vax-bsd-nat.c: Include "nbsd-nat.h", as we are now using
7975 nbsd_nat_target.
7976
7977 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7978
7979 * mips-nbsd-nat.c: Define _KERNTYPES to get the declaration of
7980 register_t.
7981
7982 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7983
7984 * ppc-nbsd-nat.c: Define _KERNTYPES to get the declaration of
7985 register_t.
7986
7987 2020-03-14 Kamil Rytarowski <n54@gmx.com>
7988
7989 * vax-bsd-nat.c: Define _KERNTYPES to get the declaration of
7990 register_t.
7991
7992 2020-03-13 Tom Tromey <tom@tromey.com>
7993
7994 * value.h (val_print): Don't declare.
7995 * valprint.h (val_print_array_elements)
7996 (val_print_scalar_formatted, generic_val_print): Don't declare.
7997 * valprint.c (generic_val_print_array): Take a struct value.
7998 (generic_val_print_ptr, generic_val_print_memberptr)
7999 (generic_val_print_bool, generic_val_print_int)
8000 (generic_val_print_char, generic_val_print_complex)
8001 (generic_val_print): Remove.
8002 (generic_value_print): Update.
8003 (do_val_print): Remove unused parameters. Don't call
8004 la_val_print.
8005 (val_print): Remove.
8006 (common_val_print): Update. Don't call value_check_printable.
8007 (val_print_scalar_formatted, val_print_array_elements): Remove.
8008 * rust-lang.c (rust_val_print): Remove.
8009 (rust_language_defn): Update.
8010 * p-valprint.c (pascal_val_print): Remove.
8011 (pascal_value_print_inner): Update.
8012 (pascal_object_print_val_fields, pascal_object_print_val):
8013 Remove.
8014 (pascal_object_print_static_field): Update.
8015 * p-lang.h (pascal_val_print): Don't declare.
8016 * p-lang.c (pascal_language_defn): Update.
8017 * opencl-lang.c (opencl_language_defn): Update.
8018 * objc-lang.c (objc_language_defn): Update.
8019 * m2-valprint.c (m2_print_unbounded_array, m2_val_print): Remove.
8020 * m2-lang.h (m2_val_print): Don't declare.
8021 * m2-lang.c (m2_language_defn): Update.
8022 * language.h (struct language_defn) <la_val_print>: Remove.
8023 * language.c (unk_lang_value_print_inner): Rename. Change
8024 argument types.
8025 (unknown_language_defn, auto_language_defn): Update.
8026 * go-valprint.c (go_val_print): Remove.
8027 * go-lang.h (go_val_print): Don't declare.
8028 * go-lang.c (go_language_defn): Update.
8029 * f-valprint.c (f_val_print): Remove.
8030 * f-lang.h (f_value_print): Don't declare.
8031 * f-lang.c (f_language_defn): Update.
8032 * d-valprint.c (d_val_print): Remove.
8033 * d-lang.h (d_value_print): Don't declare.
8034 * d-lang.c (d_language_defn): Update.
8035 * cp-valprint.c (cp_print_value_fields)
8036 (cp_print_value_fields_rtti, cp_print_value): Remove.
8037 (cp_print_static_field): Update.
8038 * c-valprint.c (c_val_print_array, c_val_print_ptr)
8039 (c_val_print_struct, c_val_print_union, c_val_print_int)
8040 (c_val_print_memberptr, c_val_print): Remove.
8041 * c-lang.h (c_val_print_array, cp_print_value_fields)
8042 (cp_print_value_fields_rtti): Don't declare.
8043 * c-lang.c (c_language_defn, cplus_language_defn)
8044 (asm_language_defn, minimal_language_defn): Update.
8045 * ada-valprint.c (ada_val_print_ptr, ada_val_print_num): Remove.
8046 (ada_val_print_enum): Take a struct value.
8047 (ada_val_print_flt, ada_val_print_array, ada_val_print_1)
8048 (ada_val_print): Remove.
8049 (ada_value_print_1): Update.
8050 (printable_val_type): Remove.
8051 * ada-lang.h (ada_val_print): Don't declare.
8052 * ada-lang.c (ada_language_defn): Update.
8053
8054 2020-03-13 Tom Tromey <tom@tromey.com>
8055
8056 * valprint.c (do_val_print): Update.
8057 * python/python-internal.h (gdbpy_apply_val_pretty_printer): Take
8058 a struct value.
8059 (value_to_value_object_no_release): Declare.
8060 * python/py-value.c (value_to_value_object_no_release): New
8061 function.
8062 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Take a
8063 struct value.
8064 * guile/scm-value.c (vlscm_scm_from_value_no_release): New
8065 function.
8066 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer): Take
8067 a struct value.
8068 * guile/guile-internal.h (vlscm_scm_from_value_no_release):
8069 Declare.
8070 (gdbscm_apply_val_pretty_printer): Take a struct value.
8071 * extension.h (apply_ext_lang_val_pretty_printer): Take a struct
8072 value.
8073 * extension.c (apply_ext_lang_val_pretty_printer): Take a struct
8074 value.
8075 * extension-priv.h (struct extension_language_ops)
8076 <apply_val_pretty_printer>: Take a struct value.
8077 * cp-valprint.c (cp_print_value): Create a struct value.
8078 (cp_print_value): Update.
8079
8080 2020-03-13 Tom Tromey <tom@tromey.com>
8081
8082 * ada-valprint.c (print_field_values): Call common_val_print.
8083
8084 2020-03-13 Tom Tromey <tom@tromey.com>
8085
8086 * ada-valprint.c (val_print_packed_array_elements): Remove
8087 bitoffset and val parameters. Call common_val_print.
8088 (ada_val_print_string): Remove offset, address, and original_value
8089 parameters.
8090 (ada_val_print_array): Update.
8091 (ada_value_print_array): New function.
8092 (ada_value_print_1): Call it.
8093
8094 2020-03-13 Tom Tromey <tom@tromey.com>
8095
8096 * ada-valprint.c (ada_value_print): Use common_val_print.
8097
8098 2020-03-13 Tom Tromey <tom@tromey.com>
8099
8100 * ada-valprint.c (ada_val_print_ref): Use common_val_print.
8101
8102 2020-03-13 Tom Tromey <tom@tromey.com>
8103
8104 * ada-valprint.c (ada_value_print_num): New function.
8105 (ada_value_print_1): Use it.
8106
8107 2020-03-13 Tom Tromey <tom@tromey.com>
8108
8109 * ada-valprint.c (ada_value_print_1) <TYPE_CODE_FLT>: Rewrite.
8110
8111 2020-03-13 Tom Tromey <tom@tromey.com>
8112
8113 * ada-valprint.c (ada_value_print_ptr): New function.
8114 (ada_value_print_1): Use it.
8115
8116 2020-03-13 Tom Tromey <tom@tromey.com>
8117
8118 * ada-valprint.c (ada_val_print_gnat_array): Take a struct value;
8119 call common_val_print.
8120 (ada_val_print_1): Update.
8121 (ada_value_print_1): New function.
8122 (ada_value_print_inner): Rewrite.
8123
8124 2020-03-13 Tom Tromey <tom@tromey.com>
8125
8126 * cp-valprint.c (cp_print_value_fields): Update.
8127 (cp_print_value): New function.
8128
8129 2020-03-13 Tom Tromey <tom@tromey.com>
8130
8131 * m2-valprint.c (m2_value_print_inner): Use
8132 cp_print_value_fields.
8133 * cp-valprint.c (cp_print_value_fields): New function.
8134 * c-valprint.c (c_value_print_struct): New function.
8135 (c_value_print_inner): Use c_value_print_struct.
8136 * c-lang.h (cp_print_value_fields): Declare.
8137
8138 2020-03-13 Tom Tromey <tom@tromey.com>
8139
8140 * c-valprint.c (c_value_print_array): New function.
8141 (c_value_print_inner): Use it.
8142
8143 2020-03-13 Tom Tromey <tom@tromey.com>
8144
8145 * c-valprint.c (c_value_print_memberptr): New function.
8146 (c_value_print_inner): Use it.
8147
8148 2020-03-13 Tom Tromey <tom@tromey.com>
8149
8150 * c-valprint.c (c_value_print_int): New function.
8151 (c_value_print_inner): Use it.
8152
8153 2020-03-13 Tom Tromey <tom@tromey.com>
8154
8155 * c-valprint.c (c_value_print_ptr): New function.
8156 (c_value_print_inner): Use it.
8157
8158 2020-03-13 Tom Tromey <tom@tromey.com>
8159
8160 * c-valprint.c (c_value_print_inner): Rewrite.
8161
8162 2020-03-13 Tom Tromey <tom@tromey.com>
8163
8164 * valprint.c (generic_value_print_complex): New function.
8165 (generic_value_print): Use it.
8166
8167 2020-03-13 Tom Tromey <tom@tromey.com>
8168
8169 * valprint.c (generic_val_print_float): Don't call
8170 val_print_scalar_formatted.
8171 (generic_val_print, generic_value_print): Update.
8172
8173 2020-03-13 Tom Tromey <tom@tromey.com>
8174
8175 * valprint.c (generic_value_print_char): New function
8176 (generic_value_print): Use it.
8177
8178 2020-03-13 Tom Tromey <tom@tromey.com>
8179
8180 * valprint.c (generic_value_print_int): New function.
8181 (generic_value_print): Use it.
8182
8183 2020-03-13 Tom Tromey <tom@tromey.com>
8184
8185 * valprint.c (generic_value_print_bool): New function.
8186 (generic_value_print): Use it.
8187
8188 2020-03-13 Tom Tromey <tom@tromey.com>
8189
8190 * valprint.c (generic_val_print_func): Simplify.
8191 (generic_val_print, generic_value_print): Update.
8192
8193 2020-03-13 Tom Tromey <tom@tromey.com>
8194
8195 * valprint.c (generic_val_print_flags): Remove.
8196 (generic_val_print, generic_value_print): Update.
8197 (val_print_type_code_flags): Add original_value parameter.
8198
8199 2020-03-13 Tom Tromey <tom@tromey.com>
8200
8201 * valprint.c (generic_val_print): Update.
8202 (generic_value_print): Update.
8203 * valprint.c (generic_val_print_enum): Don't call
8204 val_print_scalar_formatted.
8205
8206 2020-03-13 Tom Tromey <tom@tromey.com>
8207
8208 * valprint.c (generic_value_print): Call generic_value_print_ptr.
8209 * valprint.c (generic_value_print_ptr): New function.
8210
8211 2020-03-13 Tom Tromey <tom@tromey.com>
8212
8213 * valprint.c (generic_value_print): Rewrite.
8214
8215 2020-03-13 Tom Tromey <tom@tromey.com>
8216
8217 * p-valprint.c (pascal_object_print_value_fields)
8218 (pascal_object_print_value): New functions.
8219
8220 2020-03-13 Tom Tromey <tom@tromey.com>
8221
8222 * p-valprint.c (pascal_value_print_inner): Rewrite.
8223
8224 2020-03-13 Tom Tromey <tom@tromey.com>
8225
8226 * f-valprint.c (f_value_print_innner): Rewrite.
8227
8228 2020-03-13 Tom Tromey <tom@tromey.com>
8229
8230 * m2-valprint.c (m2_print_unbounded_array): New overload.
8231 (m2_print_unbounded_array): Update.
8232 (m2_print_array_contents): Take a struct value.
8233 (m2_value_print_inner): Rewrite.
8234
8235 2020-03-13 Tom Tromey <tom@tromey.com>
8236
8237 * d-valprint.c (dynamic_array_type): Call d_value_print_inner.
8238 (d_value_print_inner): New function.
8239 * d-lang.h (d_value_print_inner): Declare.
8240 * d-lang.c (d_language_defn): Use d_value_print_inner.
8241
8242 2020-03-13 Tom Tromey <tom@tromey.com>
8243
8244 * go-valprint.c (go_value_print_inner): New function.
8245 * go-lang.h (go_value_print_inner): Declare.
8246 * go-lang.c (go_language_defn): Use go_value_print_inner.
8247
8248 2020-03-13 Tom Tromey <tom@tromey.com>
8249
8250 * rust-lang.c (val_print_struct, rust_print_enum): Use the value
8251 API.
8252 (rust_val_print): Rewrite.
8253 (rust_value_print_inner): New function, from rust_val_print.
8254 (rust_language_defn): Use rust_value_print_inner.
8255
8256 2020-03-13 Tom Tromey <tom@tromey.com>
8257
8258 * ada-valprint.c (ada_value_print_inner): New function.
8259 * ada-lang.h (ada_value_print_inner): Declare.
8260 * ada-lang.c (ada_language_defn): Use ada_value_print_inner.
8261
8262 2020-03-13 Tom Tromey <tom@tromey.com>
8263
8264 * f-valprint.c (f_value_print_innner): New function.
8265 * f-lang.h (f_value_print_innner): Declare.
8266 * f-lang.c (f_language_defn): Use f_value_print_innner.
8267
8268 2020-03-13 Tom Tromey <tom@tromey.com>
8269
8270 * p-valprint.c (pascal_value_print_inner): New function.
8271 * p-lang.h (pascal_value_print_inner): Declare.
8272 * p-lang.c (pascal_language_defn): Use pascal_value_print_inner.
8273
8274 2020-03-13 Tom Tromey <tom@tromey.com>
8275
8276 * m2-valprint.c (m2_value_print_inner): New function.
8277 * m2-lang.h (m2_value_print_inner): Declare.
8278 * m2-lang.c (m2_language_defn): Use m2_value_print_inner.
8279
8280 2020-03-13 Tom Tromey <tom@tromey.com>
8281
8282 * opencl-lang.c (opencl_language_defn): Use c_value_print_inner.
8283 * objc-lang.c (objc_language_defn): Use c_value_print_inner.
8284 * c-valprint.c (c_value_print_inner): New function.
8285 * c-lang.h (c_value_print_inner): Declare.
8286 * c-lang.c (c_language_defn, cplus_language_defn)
8287 (asm_language_defn, minimal_language_defn): Use
8288 c_value_print_inner.
8289
8290 2020-03-13 Tom Tromey <tom@tromey.com>
8291
8292 * p-valprint.c (pascal_object_print_value_fields): Now static.
8293 * p-lang.h (pascal_object_print_value_fields): Don't declare.
8294
8295 2020-03-13 Tom Tromey <tom@tromey.com>
8296
8297 * c-valprint.c (c_val_print_array): Simplify.
8298
8299 2020-03-13 Tom Tromey <tom@tromey.com>
8300
8301 * valprint.c (value_print_array_elements): New function.
8302 * valprint.h (value_print_array_elements): Declare.
8303
8304 2020-03-13 Tom Tromey <tom@tromey.com>
8305
8306 * printcmd.c (print_formatted): Use value_print_scalar_formatted.
8307 * mips-tdep.c (mips_print_register): Use
8308 value_print_scalar_formatted.
8309
8310 2020-03-13 Tom Tromey <tom@tromey.com>
8311
8312 * valprint.h (value_print_scalar_formatted): Declare.
8313 * valprint.c (value_print_scalar_formatted): New function.
8314
8315 2020-03-13 Tom Tromey <tom@tromey.com>
8316
8317 * valprint.h (generic_value_print): Declare.
8318 * valprint.c (generic_value_print): New function.
8319
8320 2020-03-13 Tom Tromey <tom@tromey.com>
8321
8322 * valprint.c (do_val_print): Call la_value_print_inner, if
8323 available.
8324 * rust-lang.c (rust_language_defn): Update.
8325 * p-lang.c (pascal_language_defn): Update.
8326 * opencl-lang.c (opencl_language_defn): Update.
8327 * objc-lang.c (objc_language_defn): Update.
8328 * m2-lang.c (m2_language_defn): Update.
8329 * language.h (struct language_defn) <la_value_print_inner>: New
8330 member.
8331 * language.c (unknown_language_defn, auto_language_defn): Update.
8332 * go-lang.c (go_language_defn): Update.
8333 * f-lang.c (f_language_defn): Update.
8334 * d-lang.c (d_language_defn): Update.
8335 * c-lang.c (c_language_defn, cplus_language_defn)
8336 (asm_language_defn, minimal_language_defn): Update.
8337 * ada-lang.c (ada_language_defn): Update.
8338
8339 2020-03-13 Tom Tromey <tom@tromey.com>
8340
8341 * c-valprint.c (c_value_print): Use common_val_print.
8342
8343 2020-03-13 Tom Tromey <tom@tromey.com>
8344
8345 * cp-valprint.c (cp_print_static_field): Use common_val_print.
8346
8347 2020-03-13 Tom Tromey <tom@tromey.com>
8348
8349 * f-valprint.c (f77_print_array_1, f_val_print): Use
8350 common_val_print.
8351
8352 2020-03-13 Tom Tromey <tom@tromey.com>
8353
8354 * riscv-tdep.c (riscv_print_one_register_info): Use
8355 common_val_print.
8356
8357 2020-03-13 Tom Tromey <tom@tromey.com>
8358
8359 * mi/mi-main.c (output_register): Use common_val_print.
8360
8361 2020-03-13 Tom Tromey <tom@tromey.com>
8362
8363 * infcmd.c (default_print_one_register_info): Use
8364 common_val_print.
8365
8366 2020-03-13 Tom Tromey <tom@tromey.com>
8367
8368 * valprint.h (common_val_print_checked): Declare.
8369 * valprint.c (common_val_print_checked): New function.
8370 * stack.c (print_frame_arg): Use common_val_print_checked.
8371
8372 2020-03-13 Tom Tromey <tom@tromey.com>
8373
8374 * valprint.c (do_val_print): New function, from val_print.
8375 (val_print): Use do_val_print.
8376 (common_val_print): Use do_val_print.
8377
8378 2020-03-13 Tom Tromey <tom@tromey.com>
8379
8380 * valprint.c (value_print): Use scoped_value_mark.
8381
8382 2020-03-13 Tom de Vries <tdevries@suse.de>
8383
8384 PR symtab/25646
8385 * psymtab.c (partial_symtab::partial_symtab): Don't set
8386 globals_offset and statics_offset. Push element onto
8387 current_global_psymbols and current_static_psymbols stacks.
8388 (concat): New function.
8389 (end_psymtab_common): Set globals_offset and statics_offset. Pop
8390 element from current_global_psymbols and current_static_psymbols
8391 stacks. Concat popped elements to global_psymbols and
8392 static_symbols.
8393 (add_psymbol_to_list): Use current_global_psymbols and
8394 current_static_psymbols stacks.
8395 * psymtab.h (class psymtab_storage): Add current_global_psymbols and
8396 current_static_psymbols fields.
8397
8398 2020-03-12 Christian Biesinger <cbiesinger@google.com>
8399
8400 * corelow.c (sniff_core_bfd): Remove.
8401 (class core_target) <m_core_vec>: Remove.
8402 (core_target::core_target): Update.
8403 (core_file_fns): Remove.
8404 (deprecated_add_core_fns): Remove.
8405 (default_core_sniffer): Remove.
8406 (sniff_core_bfd): Remove.
8407 (default_check_format): Remove.
8408 (gdb_check_format): Remove.
8409 (core_target_open): Update.
8410 (core_target::get_core_register_section): Update.
8411 (get_core_registers_cb): Update.
8412 (core_target::fetch_registers): Update.
8413 * gdbcore.h (struct core_fns): Remove.
8414 (deprecated_add_core_fns): Remove.
8415 (default_core_sniffer): Remove.
8416 (default_check_format): Remove.
8417
8418 2020-03-12 Tom Tromey <tom@tromey.com>
8419
8420 * arm-tdep.c (struct arm_mapping_symbol) <value>: Now a
8421 CORE_ADDR.
8422 (struct arm_exidx_entry) <addr>: Now a CORE_ADDR.
8423
8424 2020-03-12 Tom Tromey <tom@tromey.com>
8425
8426 * remote.c (remote_target::download_tracepoint)
8427 (remote_target::enable_tracepoint)
8428 (remote_target::disable_tracepoint): Use phex, not sprintf_vma.
8429 * breakpoint.c (print_recreate_masked_watchpoint): Use phex, not
8430 sprintf_vma.
8431
8432 2020-03-12 Tom Tromey <tom@tromey.com>
8433
8434 * symfile-mem.c: Update CORE_ADDR size assert.
8435
8436 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8437
8438 * selftest.m4: Move to gdbsupport/.
8439 * acinclude.m4: Update path to selftest.m4.
8440
8441 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8442
8443 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Rename to...
8444 (SELFTESTS_SRCS): ... this. Add disasm-selftests.c,
8445 gdbarch-selfselftests.c and selftest-arch.c.
8446 (SUBDIR_UNITTESTS_OBS): Rename to...
8447 (SELFTESTS_OBS): ... this.
8448 (COMMON_SFILES): Remove disasm-selftests.c and
8449 gdbarch-selftests.c.
8450 * configure.ac: Don't add selftest-arch.{c,o} to
8451 CONFIG_{SRCS,OBS}.
8452 * disasm-selftests.c, gdbarch-selftests.c: Remove GDB_SELF_TEST
8453 preprocessor conditions.
8454
8455 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8456
8457 * configure.ac: Don't source bfd/development.sh.
8458 * selftest.m4: Modify comment.
8459 * configure: Re-generate.
8460
8461 2020-03-12 Simon Marchi <simon.marchi@efficios.com>
8462
8463 * selftest.m4 (GDB_AC_SELFTEST): Error out if $development is
8464 not "true" or "false".
8465 * configure: Re-generate.
8466
8467 2020-03-12 Christian Biesinger <cbiesinger@google.com>
8468
8469 * Makefile.in (HFILES_NO_SRCDIR): Add new arm-nbsd-tdep.h file.
8470 * arm-nbsd-nat.c (arm_supply_gregset): Moved to arm-nbsd-tdep and
8471 renamed to arm_nbsd_supply_gregset.
8472 (fetch_register): Update to call arm_nbsd_supply_gregset.
8473 (fetch_regs): Remove in favor of fetch_register with a -1 regno.
8474 (arm_netbsd_nat_target::fetch_registers): Update.
8475 (fetch_elfcore_registers): Removed.
8476 (_initialize_arm_netbsd_nat): Removed call to deprecated_add_core_fns.
8477 * arm-nbsd-tdep.c (struct arm_nbsd_reg): New struct.
8478 (arm_nbsd_supply_gregset): Moved from arm-nbsd-nat.c and updated to
8479 not require NetBSD system headers.
8480 (arm_nbsd_regset): New struct.
8481 (arm_nbsd_iterate_over_regset_sections): New function.
8482 (arm_netbsd_init_abi_common): Updated to call
8483 set_gdbarch_iterate_over_regset_sections.
8484 * arm-nbsd-tdep.h: New file.
8485
8486 2020-03-11 Kevin Buettner <kevinb@redhat.com>
8487
8488 * symtab.c (find_pc_sect_line): Add check which prevents infinite
8489 recursion.
8490
8491 2020-03-11 Simon Marchi <simon.marchi@efficios.com>
8492
8493 * configure: Re-generate.
8494
8495 2020-03-11 Tom Tromey <tromey@adacore.com>
8496
8497 * ada-typeprint.c (print_choices): Fix comment.
8498
8499 2020-03-11 Andrew Burgess <andrew.burgess@embecosm.com>
8500
8501 * buildsyms.c (buildsym_compunit::record_line): Avoid accessing
8502 previous item in the list, when the list has no items.
8503
8504 2020-03-11 Tom de Vries <tdevries@suse.de>
8505
8506 * dwarf2/loc.c (dwarf2_evaluate_property): Handle NULL frame in
8507 PROP_LOCLIST handling code.
8508
8509 2020-03-10 Andrew Burgess <andrew.burgess@embecosm.com>
8510
8511 * buildsym-legacy.c (record_line): Pass extra parameter to
8512 record_line.
8513 * buildsym.c (buildsym_compunit::record_line): Take an extra
8514 parameter, reduce duplication in the line table, and record the
8515 is_stmt flag in the line table.
8516 * buildsym.h (buildsym_compunit::record_line): Add extra
8517 parameter.
8518 * disasm.c (do_mixed_source_and_assembly_deprecated): Ignore
8519 non-statement lines.
8520 * dwarf2/read.c (dwarf_record_line_1): Add extra parameter, pass
8521 this to the symtab builder.
8522 (dwarf_finish_line): Pass extra parameter to dwarf_record_line_1.
8523 (lnp_state_machine::record_line): Pass a suitable is_stmt flag
8524 through to dwarf_record_line_1.
8525 * infrun.c (process_event_stop_test): When stepping, don't stop at
8526 a non-statement instruction, and only refresh the step info when
8527 we land in the middle of a line's range. Also add an extra
8528 comment.
8529 * jit.c (jit_symtab_line_mapping_add_impl): Initialise is_stmt
8530 field.
8531 * record-btrace.c (btrace_find_line_range): Only record lines
8532 marked as is-statement.
8533 * stack.c (frame_show_address): Show the frame address if we are
8534 in a non-statement sal.
8535 * symmisc.c (dump_symtab_1): Print the is_stmt flag.
8536 (maintenance_print_one_line_table): Print a header for the is_stmt
8537 column, and include is_stmt information in the output.
8538 * symtab.c (find_pc_sect_line): Find lines marked as statements in
8539 preference to non-statements.
8540 (find_pcs_for_symtab_line): Prefer is-statement entries.
8541 (find_line_common): Likewise.
8542 * symtab.h (struct linetable_entry): Add is_stmt field.
8543 (struct symtab_and_line): Likewise.
8544 * xcoffread.c (arrange_linetable): Initialise is_stmt field when
8545 arranging the line table.
8546
8547 2020-03-07 Tom de Vries <tdevries@suse.de>
8548
8549 * dwarf2/read.c (read_typedef): Treat anonymous typedef as forwarder
8550 DIE.
8551
8552 2020-03-07 Tom Tromey <tom@tromey.com>
8553
8554 * valops.c (value_literal_complex): Remove obsolete comment.
8555 * gdbtypes.h (enum type_code) <TYPE_CODE_FLT>: Remove obsolete
8556 comment.
8557
8558 2020-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8559
8560 * infrun.h: Forward-declare thread_info.
8561 (set_step_info): Add thread_info parameter, add doc.
8562 * infrun.c (set_step_info): Add thread_info parameter, move doc
8563 to header.
8564 * infrun.c (process_event_stop_test): Pass thread to
8565 set_step_info call.
8566 * infcmd.c (set_step_frame): Add thread_info pointer, pass it to
8567 set_step_info.
8568 (prepare_one_step): Add thread_info parameter, pass it to
8569 set_step_frame and prepare_one_step (recursive) call.
8570 (step_1): Pass thread to prepare_one_step call.
8571 (step_command_fsm::should_stop): Pass thread to
8572 prepare_one_step.
8573 (until_next_fsm): Pass thread to set_step_frame call.
8574 (finish_command): Pass thread to set_step_info call.
8575
8576 2020-03-06 Hannes Domani <ssbssa@yahoo.de>
8577
8578 * windows-tdep.c (windows_solib_create_inferior_hook):
8579 Check if inferior is running.
8580
8581 2020-03-06 Tom de Vries <tdevries@suse.de>
8582
8583 * NEWS: Fix "the the".
8584 * ctfread.c: Same.
8585
8586 2020-03-06 Tom de Vries <tdevries@suse.de>
8587
8588 * psymtab.c (psymtab_to_symtab): Don't print "done.".
8589
8590 2020-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8591
8592 * .dir-locals.el: Add a comment referencing the other copies of
8593 this file.
8594
8595 2020-03-05 John Baldwin <jhb@FreeBSD.org>
8596
8597 * fbsd-tdep.c (fbsd_make_corefile_notes): Use std::string for
8598 psargs.
8599
8600 2020-03-05 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
8601
8602 * .gitattributes: New file.
8603
8604 2020-03-04 Tom Tromey <tom@tromey.com>
8605
8606 * symmisc.c (print_symbol_bcache_statistics)
8607 (print_objfile_statistics): Update.
8608 * symfile.c (allocate_symtab): Use intern.
8609 * psymtab.c (partial_symtab::partial_symtab): Use intern.
8610 * objfiles.h (struct objfile_per_bfd_storage) <filename_cache,
8611 macro_cache>: Remove.
8612 <string_cache>: New member.
8613 (struct objfile) <intern>: New methods.
8614 * elfread.c (elf_symtab_read): Use intern.
8615 * dwarf2/read.c (fixup_go_packaging): Intern package name.
8616 (dwarf2_compute_name, dwarf2_physname)
8617 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2): Intern
8618 names.
8619 (guess_partial_die_structure_name): Update.
8620 (partial_die_info::fixup): Intern name.
8621 (dwarf2_canonicalize_name): Change parameter to objfile. Intern
8622 name.
8623 (dwarf2_name): Intern name. Update.
8624 * buildsym.c (buildsym_compunit::get_macro_table): Use
8625 string_cache.
8626
8627 2020-03-04 Tom Tromey <tom@tromey.com>
8628
8629 * jit.c (bfd_open_from_target_memory): Make "target" const.
8630 * corefile.c (gnutarget): Now const.
8631 * gdbcore.h (gnutarget): Now const.
8632
8633 2020-03-04 Hannes Domani <ssbssa@yahoo.de>
8634
8635 * NEWS: Mention support for WOW64 processes.
8636 * amd64-windows-nat.c (amd64_mappings): Rename and remove static.
8637 (amd64_windows_segment_register_p): Remove static.
8638 (_initialize_amd64_windows_nat): Update.
8639 * configure.nat <windows> (NATDEPFILES): Add i386-windows-nat.o.
8640 * i386-windows-nat.c (context_offset): Update.
8641 (i386_mappings): Rename and remove static.
8642 (i386_windows_segment_register_p): Remove static.
8643 (_initialize_i386_windows_nat): Update.
8644 * windows-nat.c (STATUS_WX86_BREAKPOINT): New macro.
8645 (STATUS_WX86_SINGLE_STEP): New macro.
8646 (EnumProcessModulesEx): New macro.
8647 (Wow64SuspendThread): New macro.
8648 (Wow64GetThreadContext): New macro.
8649 (Wow64SetThreadContext): New macro.
8650 (Wow64GetThreadSelectorEntry): New macro.
8651 (windows_set_context_register_offsets): Add static.
8652 (windows_set_segment_register_p): Likewise.
8653 (windows_add_thread): Adapt for WOW64 processes.
8654 (windows_fetch_one_register): Likewise.
8655 (windows_nat_target::fetch_registers): Likewise.
8656 (windows_store_one_register): Likewise.
8657 (display_selector): Likewise.
8658 (display_selectors): Likewise.
8659 (handle_exception): Likewise.
8660 (windows_continue): Likewise.
8661 (windows_nat_target::resume): Likewise.
8662 (windows_add_all_dlls): Likewise.
8663 (do_initial_windows_stuff): Likewise.
8664 (windows_nat_target::attach): Likewise.
8665 (windows_get_exec_module_filename): Likewise.
8666 (windows_nat_target::create_inferior): Likewise.
8667 (windows_xfer_siginfo): Likewise.
8668 (_initialize_loadable): Initialize Wow64SuspendThread,
8669 Wow64GetThreadContext, Wow64SetThreadContext,
8670 Wow64GetThreadSelectorEntry and EnumProcessModulesEx.
8671 * windows-nat.h (windows_set_context_register_offsets):
8672 Remove declaration.
8673 (windows_set_segment_register_p): Likewise.
8674 (i386_windows_segment_register_p): Add declaration.
8675 (amd64_windows_segment_register_p): Likewise.
8676
8677 2020-03-04 Luis Machado <luis.machado@linaro.org>
8678
8679 Revert aa66aac47b4dd38f9524ddb5546c08cc09930d37 due to regressions
8680 in "info registers" for AArch64/ARM.
8681
8682 The change caused "info registers" to not print GPR's.
8683
8684 gdb/ChangeLog:
8685
8686 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
8687
8688 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
8689 when reg->group is empty and reggroup is not.
8690
8691 2020-03-03 Tom Tromey <tromey@adacore.com>
8692
8693 * dwarf2/frame.c (struct dwarf2_frame_cache)
8694 <checked_tailcall_bottom, entry_cfa_sp_offset,
8695 entry_cfa_sp_offset_p>: Remove members.
8696 (dwarf2_frame_cache): Call dwarf2_tailcall_sniffer_first.
8697 (dwarf2_frame_prev_register): Don't call
8698 dwarf2_tailcall_sniffer_first.
8699 (dwarf2_append_unwinders): Don't append tailcall unwinder.
8700 * frame-unwind.c (add_unwinder): New fuction.
8701 (frame_unwind_init): Use it. Add tailcall unwinder.
8702
8703 2020-03-03 Andrew Burgess <andrew.burgess@embecosm.com>
8704 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
8705
8706 * f-valprint.c (f_val_print): Handle TYPE_CODE_BOOL, any non-zero
8707 value should be printed as true.
8708
8709 2020-03-03 Hannes Domani <ssbssa@yahoo.de>
8710
8711 * windows-tdep.c (windows_solib_create_inferior_hook): New function.
8712 (windows_init_abi): Set and use windows_so_ops.
8713
8714 2020-03-03 Sergio Durigan Junior <sergiodj@redhat.com>
8715
8716 * printcmd.c (print_c_string): Check also for TYPE_CODE_PTR
8717 when verifying if dealing with a convenience variable.
8718
8719 2020-03-03 Luis Machado <luis.machado@linaro.org>
8720
8721 * auxv.c (default_print_auxv_entry): Add new AUXV entries.
8722
8723 2020-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8724
8725 * infrun.c (gdbarch_supports_displaced_stepping): New.
8726 (use_displaced_stepping): Break up conditions in smaller pieces.
8727 Use gdbarch_supports_displaced_stepping.
8728 (displaced_step_prepare_throw): Use
8729 gdbarch_supports_displaced_stepping.
8730
8731 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
8732
8733 * NEWS: Mention new behaviour of the history filename.
8734 * top.c (write_history_p): Add comment.
8735 (show_write_history_p): Add header comment, give a different
8736 message when history writing is on, but the history filename is
8737 empty.
8738 (history_filename): Add comment.
8739 (history_filename_empty): New function.
8740 (show_history_filename): Add header comment, give a different
8741 message when the filename is empty.
8742 (init_history): Compare history_filename against nullptr, and only
8743 read history if the filename is not empty.
8744 (set_history_filename): Add header comment, and only make
8745 non-empty filenames absolute.
8746 (init_main): Make the filename argument to 'set history filename'
8747 optional.
8748
8749 2020-03-02 Christian Biesinger <cbiesinger@google.com>
8750
8751 * arm-nbsd-nat.c (arm_supply_fparegset): Rename to...
8752 (arm_supply_vfpregset): ...this, and update to use VFP registers.
8753 (fetch_fp_register): Update.
8754 (fetch_fp_regs): Update.
8755 (store_fp_register): Update.
8756 (store_fp_regs): Update.
8757 (arm_netbsd_nat_target::read_description): New function.
8758 (fetch_elfcore_registers): Update.
8759
8760 2020-03-02 Andrew Burgess <andrew.burgess@embecosm.com>
8761
8762 * remote.c (remote_target::remote_parse_stop_reply): Don't use the
8763 general_thread if the stop reply is missing a thread-id.
8764 (remote_target::process_stop_reply): Use the first non-exited
8765 thread if the target didn't pass a thread-id.
8766 * infrun.c (do_target_wait): Move call to
8767 switch_to_inferior_no_thread to ....
8768 (do_target_wait_1): ... here.
8769
8770 2020-02-29 Jon Turney <jon.turney@dronecode.org.uk>
8771
8772 * debuginfod-support.c: Include defs.h first.
8773
8774 2020-02-28 Tom de Vries <tdevries@suse.de>
8775
8776 * symfile.c (set_initial_language): Use default language for lookup.
8777
8778 2020-02-28 Simon Marchi <simon.marchi@efficios.com>
8779
8780 * dwarf2/read.c (cutu_reader::init_tu_and_read_dwo_dies): Remove
8781 reader variable, pass `this` to read_cutu_die_from_dwo.
8782
8783 2020-02-27 Aaron Merey <amerey@redhat.com>
8784
8785 * source.c (open_source_file): Check for nullptr when computing
8786 srcpath.
8787
8788 2020-02-27 Tom Tromey <tromey@adacore.com>
8789
8790 * dwarf2/read.c (struct field_info) <nfields>: Now a method, not a
8791 member.
8792 (dwarf2_add_field): Don't update nfields.
8793 (dwarf2_attach_fields_to_type, process_structure_scope): Update.
8794
8795 2020-02-27 Andrew Burgess <andrew.burgess@embecosm.com>
8796
8797 * gdbtypes.c (create_array_type_with_stride): Use std::abs not
8798 abs.
8799
8800 2020-02-26 Tom Tromey <tom@tromey.com>
8801
8802 * dwarf2/read.c (struct dwarf2_include_psymtab): New.
8803 (dwarf2_create_include_psymtab): Use dwarf2_include_psymtab.
8804 (dwarf2_psymtab::expand_psymtab, dwarf2_psymtab::readin_p)
8805 (dwarf2_psymtab::get_compunit_symtab): Remove null checks for
8806 per_cu_data.
8807
8808 2020-02-26 Tom Tromey <tom@tromey.com>
8809
8810 * dwarf2/index-write.c (psym_index_map): Change type.
8811 (add_address_entry_worker, write_one_signatured_type)
8812 (recursively_count_psymbols, recursively_write_psymbols)
8813 (class debug_names, psyms_seen_size, write_gdbindex)
8814 (write_debug_names): Use partial_symtab, not dwarf2_psymtab.
8815
8816 2020-02-26 Aaron Merey <amerey@redhat.com>
8817
8818 * Makefile.in: Handle optional debuginfod support.
8819 * NEWS: Update.
8820 * README: Add --with-debuginfod summary.
8821 * config.in: Regenerate.
8822 * configure: Regenerate.
8823 * configure.ac: Handle optional debuginfod support.
8824 * debuginfod-support.c: debuginfod helper functions.
8825 * debuginfod-support.h: Ditto.
8826 * doc/gdb.texinfo: Add --with-debuginfod to configure options
8827 summary.
8828 * dwarf2/read.c (dwarf2_get_dwz_file): Query debuginfod servers
8829 when a dwz file cannot be found.
8830 * elfread.c (elf_symfile_read): Query debuginfod servers when a
8831 debuginfo file cannot be found.
8832 * source.c (open_source_file): Query debuginfod servers when a
8833 source file cannot be found.
8834 * top.c (print_gdb_configuration): Include
8835 --{with,without}-debuginfod in the output.
8836
8837 2020-02-26 Jérémie Galarneau <jeremie.galarneau@efficios.com>
8838
8839 * thread.c (thr_try_catch_cmd): Print thread name.
8840
8841 2020-02-26 Simon Marchi <simon.marchi@efficios.com>
8842
8843 * dwarf2/loc.h (dwarf2_fetch_die_loc_sect_off,
8844 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8845 dwarf2_fetch_die_type_sect_off): Move to...
8846 * dwarf2/read.h (dwarf2_fetch_die_loc_sect_off,
8847 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8848 dwarf2_fetch_die_type_sect_off): ... here.
8849 * dwarf2/read.c (dwarf2_fetch_die_loc_sect_off,
8850 dwarf2_fetch_die_loc_cu_off, dwarf2_fetch_constant_bytes,
8851 dwarf2_fetch_die_type_sect_off): Move doc to header file.
8852
8853 2020-02-26 Tom de Vries <tdevries@suse.de>
8854
8855 PR gdb/25603
8856 * symfile.c (set_initial_language): Exit-early if
8857 language_mode == language_mode_manual.
8858
8859 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
8860
8861 * dwarf2/loc.h (dwarf2_read_addr_index): Move...
8862 * dwarf2/read.h (dwarf2_read_addr_index): ... here.
8863 * dwarf2/read.c (dwarf2_read_addr_index): Move doc to header.
8864
8865 2020-02-25 Andrew Burgess <andrew.burgess@embecosm.com>
8866
8867 * gdbtypes.c (create_array_type_with_stride): Handle negative
8868 array strides.
8869 * valarith.c (value_subscripted_rvalue): Likewise.
8870
8871 2020-02-25 Luis Machado <luis.machado@linaro.org>
8872
8873 * aarch64-tdep.c (aarch64_vnv_type): Fix comment typo.
8874
8875 2020-02-25 Simon Marchi <simon.marchi@polymtl.ca>
8876
8877 * loc.h (dwarf2_get_die_type): Move to...
8878 * read.h (dwarf2_get_die_type): ... here.
8879 * read.c (dwarf2_get_die_type): Move doc to header.
8880
8881 2020-02-25 Joel Brobecker <brobecker@adacore.com>
8882
8883 * copypright.py (EXCLUDE_LIST): Add 'gnulib/config.in' and
8884 'gnulib/Makefile.in' to the list.
8885
8886 2020-02-24 Tom Tromey <tom@tromey.com>
8887
8888 * dwarf2/read.h (struct type_unit_unshareable) <num_symtabs>:
8889 Remove.
8890 * dwarf2/read.c (dwarf2_cu::setup_type_unit_groups): Use
8891 XOBNEWVEC.
8892
8893 2020-02-24 Tom Tromey <tom@tromey.com>
8894
8895 * dwarf2/read.h (struct dwarf2_per_cu_data) <type_unit_group_p>:
8896 New method.
8897 * dwarf2/read.c (IS_TYPE_UNIT_GROUP): Remove.
8898 (dw2_do_instantiate_symtab, dw2_get_file_names)
8899 (build_type_psymtab_dependencies, load_full_type_unit): Update.
8900
8901 2020-02-24 Tom Tromey <tom@tromey.com>
8902
8903 * dwarf2read.c (dwarf2_build_psymtabs_hard): Use
8904 make_scoped_restore.
8905 (dwarf2_psymtab::read_symtab): Don't clear
8906 reading_partial_symbols.
8907
8908 2020-02-24 Tom de Vries <tdevries@suse.de>
8909
8910 PR gdb/25592
8911 * stack.c (iterate_over_block_locals): Handle LOC_CONST.
8912
8913 2020-02-24 Tom de Vries <tdevries@suse.de>
8914
8915 * tui/tui-layout.c (_initialize_tui_layout): Fix help messages for
8916 commands layout next/prev/regs.
8917
8918 2020-02-22 Tom Tromey <tom@tromey.com>
8919
8920 * dwarf2/loc.h (dwarf2_compile_expr_to_ax): Don't declare.
8921 * dwarf2/loc.c (dwarf2_compile_expr_to_ax): Now static.
8922
8923 2020-02-22 Tom Tromey <tom@tromey.com>
8924
8925 * tui/tui-data.h (TUI_DISASM_WIN): Cast to tui_disasm_window.
8926
8927 2020-02-22 Tom Tromey <tom@tromey.com>
8928
8929 * tui/tui-win.c (_initialize_tui_win): Add usage text.
8930 * tui/tui-stack.c (_initialize_tui_stack): Add usage text.
8931 * tui/tui-regs.c (_initialize_tui_regs): Add usage text.
8932 * tui/tui.c (_initialize_tui): Add usage text.
8933
8934 2020-02-22 Tom Tromey <tom@tromey.com>
8935
8936 * tui/tui-win.c (tui_set_focus_command)
8937 (tui_set_win_height_command): Use error_no_arg.
8938 (_initialize_tui_win): Update help text.
8939 (FOCUS_USAGE, WIN_HEIGHT_USAGE): Don't define.
8940
8941 2020-02-22 Tom Tromey <tom@tromey.com>
8942
8943 * tui/tui-layout.c (extract_display_start_addr): Rewrite.
8944 * tui/tui-disasm.h (struct tui_disasm_window)
8945 <display_start_addr>: Declare.
8946 * tui/tui-source.h (struct tui_source_window)
8947 <display_start_addr>: Declare.
8948 * tui/tui-winsource.h (struct tui_source_window_base)
8949 <show_source_line, display_start_addr>: New methods.
8950 <m_horizontal_offset, m_start_line_or_addr, m_gdbarch, m_content>:
8951 Rename and move to protected section.
8952 * tui/tui-winsource.c (tui_source_window_base::update_source_window)
8953 (tui_source_window_base::do_erase_source_content): Update.
8954 (tui_source_window_base::show_source_line): Now a method.
8955 (tui_source_window_base::show_source_content)
8956 (tui_source_window_base::tui_source_window_base)
8957 (tui_source_window_base::rerender)
8958 (tui_source_window_base::refill)
8959 (tui_source_window_base::do_scroll_horizontal)
8960 (tui_source_window_base::set_is_exec_point_at)
8961 (tui_source_window_base::update_breakpoint_info)
8962 (tui_source_window_base::update_exec_info): Update.
8963 * tui/tui-source.c (tui_source_window::set_contents)
8964 (tui_source_window::showing_source_p)
8965 (tui_source_window::do_scroll_vertical)
8966 (tui_source_window::location_matches_p)
8967 (tui_source_window::line_is_displayed): Update.
8968 (tui_source_window::display_start_addr): New method.
8969 * tui/tui-disasm.c (tui_disasm_window::set_contents)
8970 (tui_disasm_window::do_scroll_vertical)
8971 (tui_disasm_window::location_matches_p): Update.
8972 (tui_disasm_window::display_start_addr): New method.
8973
8974 2020-02-22 Tom Tromey <tom@tromey.com>
8975
8976 * NEWS: Add entry for gdb.register_window_type.
8977 * tui/tui-layout.h (window_factory): New typedef.
8978 (tui_register_window): Declare.
8979 * tui/tui-layout.c (saved_tui_windows): New global.
8980 (tui_apply_current_layout): Use it.
8981 (tui_register_window): New function.
8982 * python/python.c (do_start_initialization): Call
8983 gdbpy_initialize_tui.
8984 (python_GdbMethods): Add "register_window_type" function.
8985 * python/python-internal.h (gdbpy_register_tui_window)
8986 (gdbpy_initialize_tui): Declare.
8987 * python/py-tui.c: New file.
8988 * Makefile.in (SUBDIR_PYTHON_SRCS): Add py-tui.c.
8989
8990 2020-02-22 Tom Tromey <tom@tromey.com>
8991
8992 * tui/tui-io.c (do_tui_putc): Don't omit annotations.
8993
8994 2020-02-22 Tom Tromey <tom@tromey.com>
8995
8996 * tui/tui-win.c (tui_set_win_focus_to): Move to tui-data.c.
8997 * tui/tui-data.h (tui_set_win_with_focus): Don't declare.
8998 * tui/tui-data.c (tui_set_win_with_focus): Remove.
8999 (tui_set_win_focus_to): Move from tui-win.c.
9000
9001 2020-02-22 Tom Tromey <tom@tromey.com>
9002
9003 * tui/tui-layout.c (make_standard_window, get_locator_window): New
9004 functions.
9005 (known_window_types): New global.
9006 (tui_get_window_by_name): Reimplement.
9007 (initialize_known_windows): New function.
9008 (validate_window_name): Rewrite.
9009 (_initialize_tui_layout): Call initialize_known_windows.
9010
9011 2020-02-22 Tom Tromey <tom@tromey.com>
9012
9013 * tui/tui.h (enum tui_win_type) <LOCATOR_WIN, DATA_ITEM_WIN>:
9014 Remove constants.
9015 * tui/tui-winsource.h (struct tui_source_window_base)
9016 <tui_source_window_base>: Remove parameter.
9017 * tui/tui-winsource.c
9018 (tui_source_window_base::tui_source_window_base): Remove
9019 parameter.
9020 (tui_source_window_base::refill): Update.
9021 * tui/tui-stack.h (struct tui_locator_window)
9022 <tui_locator_window>: Update.
9023 * tui/tui-source.h (struct tui_source_window) <tui_source_window>:
9024 Default the constructor.
9025 * tui/tui-regs.h (struct tui_data_item_window)
9026 <tui_data_item_window>: Default the constructor.
9027 (struct tui_data_window) <tui_data_window>: Likewise.
9028 * tui/tui-disasm.h (struct tui_disasm_window) <tui_disasm_window>:
9029 Default the constructor.
9030 * tui/tui-data.h (struct tui_gen_win_info) <tui_gen_win_info>:
9031 Default the constructor.
9032 <type>: Remove.
9033 (struct tui_win_info) <tui_win_info>: Default the constructor.
9034 * tui/tui-data.c (tui_win_info::tui_win_info): Remove.
9035 * tui/tui-command.h (struct tui_cmd_window) <tui_cmd_window>:
9036 Default the constructor.
9037
9038 2020-02-22 Tom Tromey <tom@tromey.com>
9039
9040 * tui/tui-wingeneral.h (tui_make_all_invisible): Don't declare.
9041 * tui/tui-wingeneral.c (tui_make_all_invisible): Remove.
9042 * tui/tui-win.c (tui_resize_all): Don't call
9043 tui_delete_invisible_windows.
9044 * tui/tui-layout.c (tui_apply_current_layout): Delete windows when
9045 done.
9046 (tui_set_layout): Update.
9047 (tui_add_win_to_layout): Don't call tui_delete_invisible_windows.
9048 * tui/tui-data.h (tui_delete_invisible_windows): Don't declare.
9049 * tui/tui-data.c (tui_delete_invisible_windows): Remove.
9050
9051 2020-02-22 Tom Tromey <tom@tromey.com>
9052
9053 * tui/tui-win.c (tui_partial_win_by_name): Handle ambiguity
9054 correctly.
9055
9056 2020-02-22 Tom Tromey <tom@tromey.com>
9057
9058 * tui/tui-data.c (tui_next_win, tui_prev_win): Reimplement.
9059
9060 2020-02-22 Tom Tromey <tom@tromey.com>
9061
9062 * tui/tui-winsource.h (struct tui_source_window_iterator)
9063 <inner_iterator>: New etytypedef.
9064 <tui_source_window_iterator>: Take "end" parameter.
9065 <tui_source_window_iterator>: Take iterator.
9066 <operator*, advance>: Update.
9067 <m_iter>: Change type.
9068 <m_end>: New field.
9069 (struct tui_source_windows) <begin, end>: Update.
9070 * tui/tui-layout.c (tui_windows): New global.
9071 (tui_apply_current_layout): Clear tui_windows.
9072 (tui_layout_window::apply): Update tui_windows.
9073 * tui/tui-data.h (tui_windows): Declare.
9074 (all_tui_windows): Now inline function.
9075 (class tui_window_iterator, struct all_tui_windows): Remove.
9076
9077 2020-02-22 Tom Tromey <tom@tromey.com>
9078
9079 PR tui/17850:
9080 * tui/tui-win.c (tui_gen_win_info::max_width): New method.
9081 * tui/tui-layout.h (class tui_layout_base) <get_sizes>: Add
9082 "height" argument.
9083 (class tui_layout_window) <get_sizes>: Likewise.
9084 (class tui_layout_split) <tui_layout_split>: Add "vertical"
9085 argument.
9086 <get_sizes>: Add "height" argument.
9087 <m_vertical>: New field.
9088 * tui/tui-layout.c (tui_layout_split::clone): Update.
9089 (tui_layout_split::get_sizes): Add "height" argument.
9090 (tui_layout_split::adjust_size, tui_layout_split::apply): Update.
9091 (tui_new_layout_command): Parse "-horizontal".
9092 (_initialize_tui_layout): Update help string.
9093 (tui_layout_split::specification): Add "-horizontal" when needed.
9094 * tui/tui-layout.c (tui_layout_window::get_sizes): Add "height"
9095 argument.
9096 * tui/tui-data.h (struct tui_gen_win_info) <max_width, min_width>:
9097 New methods.
9098
9099 2020-02-22 Tom Tromey <tom@tromey.com>
9100
9101 * tui/tui-layout.h (enum tui_adjust_result): New.
9102 (class tui_layout_base) <adjust_size>: Return tui_adjust_result.
9103 (class tui_layout_window) <adjust_size>: Return
9104 tui_adjust_result. Rewrite.
9105 (class tui_layout_split) <adjust_size>: Return tui_adjust_result.
9106 * tui/tui-layout.c (tui_layout_split::adjust_size): Update.
9107
9108 2020-02-22 Tom Tromey <tom@tromey.com>
9109
9110 * tui/tui-layout.h (class tui_layout_split) <add_split>: Change
9111 parameter and return types.
9112 (class tui_layout_base) <specification>: Add "depth".
9113 (class tui_layout_window) <specification>: Add "depth".
9114 (class tui_layout_split) <specification>: Add "depth".
9115 * tui/tui-layout.c (tui_layout_split::add_split): Change parameter
9116 and return types.
9117 (tui_new_layout_command): Parse sub-layouts.
9118 (_initialize_tui_layout): Update help string.
9119 (tui_layout_window::specification): Add "depth".
9120 (add_layout_command): Update.
9121
9122 2020-02-22 Tom Tromey <tom@tromey.com>
9123
9124 * NEWS: Add "tui new-layout" item.
9125 * tui/tui-layout.c (add_layout_command): Return cmd_list_element.
9126 Add new-layout command to help text.
9127 (validate_window_name): New function.
9128 (tui_new_layout_command): New function.
9129 (_initialize_tui_layout): Register "new-layout".
9130 (tui_layout_window::specification): New method.
9131 (tui_layout_window::specification): New method.
9132 * tui/tui-layout.h (class tui_layout_base) <specification>: New
9133 method.
9134 (class tui_layout_window) <specification>: New method.
9135 (class tui_layout_split) <specification>: New method.
9136
9137 2020-02-22 Tom Tromey <tom@tromey.com>
9138
9139 * tui/tui.c (tui_enable): Call tui_set_initial_layout.
9140 * tui/tui-win.c (window_name_completer): Update comment.
9141 * tui/tui-layout.h (class tui_layout_base) <replace_window>:
9142 Declare method.
9143 (class tui_layout_window) <replace_window>: Likewise.
9144 (class tui_layout_split) <replace_window>: Likewise.
9145 (tui_set_layout): Don't declare.
9146 (tui_set_initial_layout): Declare function.
9147 * tui/tui-layout.c (layouts, applied_skeleton, src_regs_layout)
9148 (asm_regs_layout): New globals.
9149 (tui_current_layout, show_layout): Remove.
9150 (tui_set_layout, tui_add_win_to_layout): Rewrite.
9151 (find_layout, tui_apply_layout): New function.
9152 (layout_completer): Remove.
9153 (tui_next_layout): Reimplement.
9154 (tui_next_layout_command): New function.
9155 (tui_set_initial_layout, tui_prev_layout_command): New functions.
9156 (tui_regs_layout): Reimplement.
9157 (tui_regs_layout_command): New function.
9158 (extract_display_start_addr): Rewrite.
9159 (next_layout, prev_layout): Remove.
9160 (tui_layout_window::replace_window): New method.
9161 (tui_layout_split::replace_window): New method.
9162 (destroy_layout): New function.
9163 (layout_list): New global.
9164 (add_layout_command): New function.
9165 (initialize_layouts): Update.
9166 (tui_layout_command): New function.
9167 (_initialize_tui_layout): Install "layout" commands.
9168 * tui/tui-data.h (enum tui_layout_type): Remove.
9169 (tui_current_layout): Don't declare.
9170
9171 2020-02-22 Tom Tromey <tom@tromey.com>
9172
9173 * tui/tui-regs.c (tui_reg_layout): Remove.
9174 (tui_reg_command): Use tui_regs_layout.
9175 * tui/tui-layout.h (tui_reg_command): Declare.
9176 * tui/tui-layout.c (tui_reg_command): New function.
9177
9178 2020-02-22 Tom Tromey <tom@tromey.com>
9179
9180 * tui/tui.c (tui_rl_delete_other_windows): Call
9181 tui_remove_some_windows.
9182 * tui/tui-layout.h (class tui_layout_base) <remove_windows>:
9183 Declare method.
9184 (class tui_layout_window) <remove_windows>: New method.
9185 (class tui_layout_split) <remove_windows>: Declare.
9186 (tui_remove_some_windows): Declare.
9187 * tui/tui-layout.c (tui_remove_some_windows): New function.
9188 (tui_layout_split::remove_windows): New method.
9189
9190 2020-02-22 Tom Tromey <tom@tromey.com>
9191
9192 * tui/tui.c (tui_rl_change_windows): Call tui_next_layout.
9193 * tui/tui-layout.h (tui_next_layout): Declare.
9194 * tui/tui-layout.c (tui_next_layout): New function.
9195
9196 2020-02-22 Tom Tromey <tom@tromey.com>
9197
9198 * tui/tui-regs.c (tui_data_window::display_registers_from): Use
9199 correct coordinates.
9200
9201 2020-02-22 Tom Tromey <tom@tromey.com>
9202
9203 * tui/tui-layout.h (tui_add_win_to_layout): Add comment.
9204 * tui/tui-layout.c (tui_add_win_to_layout): Add assert. Remove
9205 DATA_WIN case.
9206
9207 2020-02-22 Tom Tromey <tom@tromey.com>
9208
9209 * tui/tui-disasm.c (tui_get_low_disassembly_address): Use
9210 TUI_DISASM_WIN, not tui_win_list.
9211
9212 2020-02-22 Tom Tromey <tom@tromey.com>
9213
9214 * valprint.c (generic_val_print_enum_1)
9215 (val_print_type_code_flags): Style member names.
9216 * rust-lang.c (val_print_struct, rust_print_enum)
9217 (rust_print_struct_def, rust_internal_print_type): Style member
9218 names.
9219 * p-valprint.c (pascal_object_print_value_fields): Style member
9220 names. Only call fprintf_symbol_filtered for static members.
9221 * m2-typeprint.c (m2_record_fields, m2_enum): Style member names.
9222 * f-valprint.c (f_val_print): Style member names.
9223 * f-typeprint.c (f_type_print_base): Style member names.
9224 * cp-valprint.c (cp_print_value_fields): Style member names. Only
9225 call fprintf_symbol_filtered for static members.
9226 (cp_print_class_member): Style member names.
9227 * c-typeprint.c (c_print_type_1, c_type_print_base_1): Style
9228 member names.
9229 * ada-valprint.c (ada_print_scalar): Style enum names.
9230 (ada_val_print_enum): Likewise.
9231 * ada-typeprint.c (print_enum_type): Style enum names.
9232
9233 2020-02-21 Tom Tromey <tom@tromey.com>
9234
9235 * psympriv.h (struct partial_symtab): Update comment.
9236
9237 2020-02-21 Tom Tromey <tromey@adacore.com>
9238
9239 * mips-tdep.h (mips_pc_is_mips16, mips_pc_is_micromips): Parameter
9240 type is CORE_ADDR.
9241
9242 2020-02-21 Tom de Vries <tdevries@suse.de>
9243
9244 PR gdb/25534
9245 * psymtab.c (partial_symtab::read_dependencies): Don't read dependency
9246 if dependencies[i]->user != NULL.
9247
9248 2020-02-21 Ali Tamur <tamur@google.com>
9249
9250 * dwarf2/read.c (dwarf2_name): Add null check.
9251
9252 2020-02-20 Tom Tromey <tom@tromey.com>
9253
9254 * dwarf2/read.c (dwarf2_find_containing_comp_unit): Use ">", not
9255 ">=", in binary search.
9256 (dwarf2_find_containing_comp_unit): New overload.
9257 (run_test): New self-test.
9258 (_initialize_dwarf2_read): Register new test.
9259
9260 2020-02-20 Nelson Chu <nelson.chu@sifive.com>
9261
9262 * riscv-tdep.c: Updated since the DECLARE_CSR is changed.
9263 * riscv-tdep.h: Likewise.
9264 * features/riscv/rebuild-csr-xml.sh: Generate the 64bit-csr.xml without
9265 rv32-only CSR.
9266 * features/riscv/64bit-csr.xml: Regenerated.
9267
9268 2020-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9269 Tom Tromey <tom@tromey.com>
9270
9271 * utils.c (fputs_maybe_filtered): Call 'stream->puts' instead
9272 of 'fputc_unfiltered'.
9273 (putchar_unfiltered): Call 'fputc_unfiltered'.
9274 (fputc_unfiltered): Call 'fputs_unfiltered'.
9275
9276 2020-02-20 Andrew Burgess <andrew.burgess@embecosm.com>
9277
9278 * config.in: Regenerate.
9279 * configure: Regenerate.
9280 * configure.ac: Add --with-python-libdir option.
9281 * main.c: Use WITH_PYTHON_LIBDIR.
9282
9283 2020-02-19 Tom Tromey <tom@tromey.com>
9284
9285 * symtab.c (general_symbol_info::compute_and_set_names): Use
9286 obstack_strndup. Simplify call to symbol_set_demangled_name.
9287
9288 2020-02-19 Simon Marchi <simon.marchi@efficios.com>
9289
9290 * dwarf2/read.c (allocate_signatured_type_table,
9291 allocate_dwo_unit_table, allocate_type_unit_groups_table,
9292 allocate_dwo_file_hash_table, allocate_dwp_loaded_cutus_table):
9293 Remove objfile parameter, update all callers.
9294
9295 2020-02-19 Doug Evans <dje@google.com>
9296
9297 PR rust/25535
9298 * rust-lang.c (rust_print_enum): Apply embedded_offset to
9299 rust_enum_variant calculation.
9300
9301 2020-02-19 Tom Tromey <tromey@adacore.com>
9302
9303 * mips-tdep.h (mips_pc_is_mips): Parameter type is CORE_ADDR.
9304
9305 2020-02-19 Tom Tromey <tromey@adacore.com>
9306
9307 * ada-lang.c (cache_symbol): Use obstack_strdup.
9308
9309 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
9310
9311 * configure: Regenerate.
9312
9313 2020-02-19 Tom Tromey <tromey@adacore.com>
9314
9315 * python/python.c (do_start_initialization): Use XNEWVEC. Remove
9316 NULL check.
9317
9318 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
9319
9320 * NEWS: Mention RISC-V GNU/Linux GDBserver support.
9321
9322 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
9323
9324 * arch/riscv.c (struct riscv_gdbarch_features_hasher): Only define
9325 if GDBSERVER is not defined.
9326 (riscv_tdesc_cache): Likewise, also store const target_desc.
9327 (STATIC_IN_GDB): Define.
9328 (riscv_create_target_description): Update declaration with
9329 STATIC_IN_GDB.
9330 (riscv_lookup_target_description): New function, only define if
9331 GDBSERVER is not defined.
9332 * arch/riscv.h (riscv_create_target_description): Declare only
9333 when GDBSERVER is defined.
9334 (riscv_lookup_target_description): New declaration when GDBSERVER
9335 is not defined.
9336 * nat/riscv-linux-tdesc.c (riscv_linux_read_description): Rename to...
9337 (riscv_linux_read_features): ...this, and return
9338 riscv_gdbarch_features instead of target_desc.
9339 * nat/riscv-linux-tdesc.h: Include 'arch/riscv.h'.
9340 (riscv_linux_read_description): Rename to...
9341 (riscv_linux_read_features): ...this.
9342 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
9343 Update to use riscv_gdbarch_features and
9344 riscv_lookup_target_description.
9345 * riscv-tdep.c (riscv_find_default_target_description): Use
9346 riscv_lookup_target_description instead of
9347 riscv_create_target_description.
9348
9349 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9350
9351 * valprint.c (generic_val_print_enum_1): When printing a flag
9352 enum with value 0 and there is no enumerator with value 0, print
9353 just "0" instead of "(unknown: 0x0)".
9354
9355 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9356
9357 * valprint.c (generic_val_print_enum_1): Print unknown part of
9358 flag enum in hex.
9359
9360 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9361
9362 * dwarf2/read.c (update_enumeration_type_from_children): Allow
9363 flag enums to contain duplicate enumerators.
9364 * valprint.c (generic_val_print_enum_1): Update comment.
9365
9366 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9367
9368 * dwarf2/read.c: Include "count-one-bits.h".
9369 (update_enumeration_type_from_children): If an enumerator has
9370 multiple bits set, don't treat the enumeration as a "flag enum".
9371 * valprint.c (generic_val_print_enum_1): Assert that enumerators
9372 of flag enums have 0 or 1 bit set.
9373
9374 2020-02-18 Bernd Edlinger <bernd.edlinger@hotmail.de>
9375
9376 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use an explicit
9377 conversion.
9378 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
9379 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
9380 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
9381 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
9382 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
9383
9384 2020-02-18 Simon Marchi <simon.marchi@efficios.com>
9385
9386 * MAINTAINERS: Change palmer@sifive.com to palmer@dabbelt.com.
9387
9388 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9389
9390 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Use
9391 displaced_step_closure_up.
9392 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
9393 (struct displaced_step_closure_up):
9394 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
9395 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
9396 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn):
9397 Likewise.
9398 * gdbarch.sh (displaced_step_copy_insn): Likewise.
9399 * gdbarch.c, gdbarch.h: Re-generate.
9400 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Use
9401 displaced_step_closure_up.
9402 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
9403 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
9404 * infrun.h (displaced_step_closure_up): New type alias.
9405 (struct displaced_step_inferior_state) <step_closure>: Change
9406 type to displaced_step_closure_up.
9407 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Use
9408 displaced_step_closure_up.
9409 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
9410
9411 2020-02-14 Tom Tromey <tom@tromey.com>
9412
9413 * minidebug.c (gnu_debug_key): New global.
9414 (find_separate_debug_file_in_section): Use it.
9415
9416 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9417
9418 * gdbarch.sh (displaced_step_copy_insn): Change return type to an
9419 std::unique_ptr.
9420 * gdbarch.c: Re-generate.
9421 * gdbarch.h: Re-generate.
9422 * infrun.c (displaced_step_prepare_throw): Adjust to std::unique_ptr
9423 change.
9424 * aarch64-tdep.c (aarch64_displaced_step_copy_insn): Change return
9425 type to std::unique_ptr.
9426 * aarch64-tdep.h (aarch64_displaced_step_copy_insn): Likewise.
9427 * amd64-tdep.c (amd64_displaced_step_copy_insn): Likewise.
9428 * amd64-tdep.h (amd64_displaced_step_copy_insn): Likewise.
9429 * arm-linux-tdep.c (arm_linux_displaced_step_copy_insn): Likewise.
9430 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn): Likewise.
9431 * i386-tdep.c (i386_displaced_step_copy_insn): Likewise.
9432 * i386-tdep.h (i386_displaced_step_copy_insn): Likewise.
9433 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Likewise.
9434 * s390-tdep.c (s390_displaced_step_copy_insn): Likewise.
9435
9436 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9437
9438 * infrun.c (get_displaced_step_closure_by_addr): Adjust to
9439 std::unique_ptr.
9440 (displaced_step_clear): Rename to...
9441 (displaced_step_reset): ... this. Just call displaced->reset ().
9442 (displaced_step_clear_cleanup): Rename to...
9443 (displaced_step_reset_cleanup): ... this.
9444 (displaced_step_prepare_throw): Adjust to std::unique_ptr.
9445 (displaced_step_fixup): Likewise.
9446 (resume_1): Likewise.
9447 (handle_inferior_event): Restore child's memory before calling
9448 displaced_step_fixup on the parent.
9449 * infrun.h (displaced_step_inferior_state) <reset>: Adjust
9450 to std::unique_ptr.
9451 <step_closure>: Change type to std::unique_ptr.
9452
9453 2020-02-14 Simon Marchi <simon.marchi@efficios.com>
9454
9455 * arm-tdep.c: Include count-one-bits.h.
9456 (cleanup_block_store_pc): Use count_one_bits.
9457 (cleanup_block_load_pc): Use count_one_bits.
9458 (arm_copy_block_xfer): Use count_one_bits.
9459 (thumb2_copy_block_xfer): Use count_one_bits.
9460 (thumb_copy_pop_pc_16bit): Use count_one_bits.
9461 * arch/arm-get-next-pcs.c: Include count-one-bits.h.
9462 (thumb_get_next_pcs_raw): Use count_one_bits.
9463 (arm_get_next_pcs_raw): Use count_one_bits_l.
9464 * arch/arm.c (bitcount): Remove.
9465 * arch/arm.h (bitcount): Remove.
9466
9467 2020-02-14 Tom Tromey <tromey@adacore.com>
9468
9469 * dwarf2/frame-tailcall.c (dwarf2_tailcall_sniffer_first):
9470 Update.
9471 * dwarf2/loc.h (call_site_find_chain): Return unique_xmalloc_ptr.
9472 * dwarf2/loc.c (call_site_find_chain_1): Return
9473 unique_xmalloc_ptr.
9474 (call_site_find_chain): Likewise.
9475
9476 2020-02-14 Richard Biener <rguenther@suse.de>
9477
9478 * dwarf2/read.c (lnp_state_machine::handle_special_opcode): Apply CSE
9479 on expression with division operators.
9480
9481 2020-02-13 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
9482
9483 * MAINTAINERS (Write After Approval): Adding myself.
9484
9485 2020-02-12 Tom Tromey <tom@tromey.com>
9486
9487 * event-loop.c (event_data, gdb_event, event_handler_func):
9488 Remove.
9489
9490 2020-02-12 Tom Tromey <tom@tromey.com>
9491
9492 * dwarf2/frame.c (dwarf2_frame_bfd_data): New global.
9493 (dwarf2_frame_objfile_data): Add comment.
9494 (find_comp_unit, set_comp_unit): New functions.
9495 (dwarf2_frame_find_fde): Use find_comp_unit.
9496 (dwarf2_build_frame_info): Use set_comp_unit.
9497
9498 2020-02-12 Tom Tromey <tom@tromey.com>
9499
9500 * dwarf2/frame.c (struct comp_unit) <objfile>: Remove.
9501 (comp_unit): Don't initialize objfile.
9502 (execute_cfa_program): Add text_offset parameter.
9503 (execute_cfa_program_test, dwarf2_fetch_cfa_info)
9504 (dwarf2_frame_cache): Update.
9505 (dwarf2_build_frame_info): Don't set "objfile" member.
9506
9507 2020-02-12 Tom Tromey <tom@tromey.com>
9508
9509 * dwarf2/frame.c (decode_frame_entry_1): Add gdbarch parameter.
9510 (decode_frame_entry): Likewise.
9511 (dwarf2_build_frame_info): Update.
9512
9513 2020-02-12 Tom Tromey <tom@tromey.com>
9514
9515 * dwarf2/frame.c (struct comp_unit) <obstack>: New member.
9516 (decode_frame_entry_1): Use the comp_unit obstack.
9517
9518 2020-02-12 Tom Tromey <tom@tromey.com>
9519
9520 * dwarf2/frame.c (struct comp_unit): Add initializers and
9521 constructor.
9522 (dwarf2_frame_objfile_data): Store a comp_unit.
9523 (dwarf2_frame_find_fde): Update.
9524 (dwarf2_build_frame_info): Use "new".
9525
9526 2020-02-12 Tom Tromey <tom@tromey.com>
9527
9528 * dwarf2/frame.c (struct dwarf2_fde_table): Remove.
9529 (dwarf2_fde_table): Typedef for std::vector.
9530 (dwarf2_frame_objfile_data): Remove the deleter. Now static.
9531 (dwarf2_frame_find_fde, add_fde, decode_frame_entry_1)
9532 (decode_frame_entry): Update.
9533 (dwarf2_build_frame_info): Use "new".
9534
9535 2020-02-12 Christian Biesinger <cbiesinger@google.com>
9536
9537 * arm-tdep.c (arm_gdbarch_init): Update.
9538 * arm-tdep.h (struct gdbarch_tdep) <have_fpa_registers,
9539 have_wmmx_registers, have_vfp_pseudos, have_neon_pseudos,
9540 have_neon, is_m>: Change to bool.
9541
9542 2020-02-12 Christian Biesinger <cbiesinger@google.com>
9543
9544 * arm-tdep.c (arm_dump_tdep): Print more fields of tdep.
9545
9546 2020-02-12 Tom Tromey <tom@tromey.com>
9547
9548 * dwarf2/loc.c (struct dwarf_expr_baton): Remove.
9549
9550 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
9551
9552 * windows-tdep.c (struct windows_gdbarch_data): Add tib_ptr_type.
9553 (windows_get_tlb_type): Use windows_gdbarch_data->tib_ptr_type.
9554
9555 2020-02-11 Tom Tromey <tom@tromey.com>
9556
9557 * psymtab.h: Update comment.
9558
9559 2020-02-11 Tom Tromey <tom@tromey.com>
9560
9561 * gdb_obstack.h (struct auto_obstack): Use
9562 DISABLE_COPY_AND_ASSIGN.
9563
9564 2020-02-11 Tom Tromey <tom@tromey.com>
9565
9566 * dwarf2/frame.h (struct objfile): Don't forward declare.
9567
9568 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9569
9570 * cris-tdep.c (cris_supply_gregset): Change signature to match
9571 what struct regset expects.
9572 (cris_regset): New struct.
9573 (fetch_core_registers): Remove.
9574 (cris_iterate_over_regset_sections): New function.
9575 (_initialize_cris_tdep): Don't call deprecated_add_core_fns.
9576 (cris_gdbarch_init): Call set_gdbarch_iterate_over_regset_sections.
9577
9578 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9579
9580 * arch/arm.h (enum gdb_regnum): Add comment for the FP0..7
9581 registers.
9582
9583 2020-02-11 Christian Biesinger <cbiesinger@google.com>
9584
9585 * arm-tdep.c (arm_dump_tdep): Add \n in fprintf.
9586
9587 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9588
9589 * configure: Re-generate.
9590
9591 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9592
9593 * configure: Re-generate.
9594
9595 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
9596
9597 * acinclude: Update warning.m4 path.
9598 * warning.m4: Move to gdbsupport.
9599
9600 2020-02-11 Tom Tromey <tromey@adacore.com>
9601
9602 * remote.c (remote_console_output): Update.
9603 * printcmd.c (printf_command): Update.
9604 * event-loop.c (gdb_wait_for_event): Update.
9605 * linux-nat.c (sigchld_handler): Update.
9606 * remote-sim.c (gdb_os_write_stdout): Update.
9607 (gdb_os_flush_stdout): Update.
9608 (gdb_os_flush_stderr): Update.
9609 (gdb_os_write_stderr): Update.
9610 * exceptions.c (print_exception): Update.
9611 * remote-fileio.c (remote_fileio_func_read): Update.
9612 (remote_fileio_func_write): Update.
9613 * tui/tui.c (tui_enable): Update.
9614 * tui/tui-interp.c (tui_interp::init): Update.
9615 * utils.c (init_page_info): Update.
9616 (putchar_unfiltered, fputc_unfiltered): Update.
9617 (gdb_flush): Update.
9618 (emit_style_escape): Update.
9619 (flush_wrap_buffer, fputs_maybe_filtered): Update.
9620 * ui-file.c (ui_file_isatty, ui_file_read, ui_file_write)
9621 (ui_file_write_async_safe, ui_file_flush, ui_file_puts): Remove.
9622 (stderr_file::write): Update.
9623 (stderr_file::puts): Update.
9624 * ui-file.h (ui_file_isatty, ui_file_write)
9625 (ui_file_write_async_safe, ui_file_read, ui_file_flush)
9626 (ui_file_puts): Don't declare.
9627
9628 2020-02-10 Tom de Vries <tdevries@suse.de>
9629
9630 * dwarf2/read.c (process_psymtab_comp_unit_reader): Cast concat NULL
9631 sentinel to char *.
9632
9633 2020-02-09 Tom de Vries <tdevries@suse.de>
9634
9635 * dwarf2read.c (process_psymtab_comp_unit_reader): Append CU offset to
9636 filename if it matches "<artificial>".
9637
9638 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
9639
9640 * windows-tdep.c (struct enum_value_name): New struct.
9641 (create_enum): New function.
9642 (windows_get_siginfo_type): Create and use enum types.
9643
9644 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
9645
9646 * NEWS: Mention $_siginfo support for Windows.
9647 * windows-nat.c (handle_exception): Set siginfo_er.
9648 (windows_nat_target::mourn_inferior): Reset siginfo_er.
9649 (windows_xfer_siginfo): New function.
9650 (windows_nat_target::xfer_partial): Call windows_xfer_siginfo.
9651 * windows-tdep.c (struct windows_gdbarch_data): New struct.
9652 (init_windows_gdbarch_data): New function.
9653 (get_windows_gdbarch_data): New function.
9654 (windows_get_siginfo_type): New function.
9655 (windows_init_abi): Register windows_get_siginfo_type.
9656 (_initialize_windows_tdep): Register init_windows_gdbarch_data.
9657
9658 2020-02-08 Tom Tromey <tom@tromey.com>
9659
9660 * dwarf2/read.c (class cutu_reader) <cutu_reader,
9661 init_tu_and_read_dwo_dies>: Remove "keep" parameter.
9662 <keep>: Declare method.
9663 <m_keep>: Remove member.
9664 <~cutu_reader>: Remove.
9665 (cutu_reader::init_tu_and_read_dwo_dies): Update.
9666 (cutu_reader::cutu_reader): Update.
9667 (cutu_reader::keep): Rename from ~cutu_reader.
9668 (process_psymtab_comp_unit, build_type_psymtabs_1)
9669 (process_skeletonless_type_unit, load_partial_comp_unit)
9670 (load_full_comp_unit, dwarf2_read_addr_index)
9671 (read_signatured_type): Update.
9672
9673 2020-02-08 Tom Tromey <tom@tromey.com>
9674
9675 * dwarf2/read.c (process_psymtab_comp_unit_reader): Remove
9676 "want_partial_unit" parameter.
9677 (process_psymtab_comp_unit): Change want_partial_unit to bool.
9678 Inline check for DW_TAG_partial_unit.
9679 (dwarf2_build_psymtabs_hard, scan_partial_symbols): Update.
9680
9681 2020-02-08 Tom Tromey <tom@tromey.com>
9682
9683 * dwarf2/read.c (read_n_bytes, read_direct_string): Move to
9684 read.c.
9685 * dwarf2/leb.h (read_n_bytes, read_direct_string): Move from
9686 read.c.
9687
9688 2020-02-08 Tom Tromey <tom@tromey.com>
9689
9690 * dwarf2/read.c (read_address): Move to comp-unit.c.
9691 (dwarf2_rnglists_process, dwarf2_ranges_process)
9692 (read_attribute_value, dwarf_decode_lines_1)
9693 (var_decode_location, decode_locdesc): Update.
9694 * dwarf2/comp-unit.c (comp_unit_head::read_address): Move from
9695 read.c. Remove "cu" parameter.
9696 * dwarf2/comp-unit.h (struct comp_unit_head) <read_address>: New
9697 method.
9698
9699 2020-02-08 Tom Tromey <tom@tromey.com>
9700
9701 * dwarf2/read.c (read_attribute_value, read_indirect_string)
9702 (read_indirect_line_string): Update.
9703 * dwarf2/comp-unit.c (read_offset): Remove.
9704 (read_comp_unit_head): Update.
9705 * dwarf2/comp-unit.h (struct comp_unit_head) <read_offset>: New
9706 method.
9707 (read_offset): Don't declare.
9708
9709 2020-02-08 Tom Tromey <tom@tromey.com>
9710
9711 * Makefile.in (COMMON_SFILES): Add dwarf2/comp-unit.c.
9712 * dwarf2/read.c (struct comp_unit_head): Move to
9713 dwarf2/comp-unit.h.
9714 (enum class rcuh_kind): Move to comp-unit.h.
9715 (get_cu_length, offset_in_cu_p): Now methods on comp_unit_head.
9716 (read_comp_unit_head, error_check_comp_unit_head)
9717 (read_and_check_comp_unit_head): Move to comp-unit.c.
9718 (read_offset, dwarf_unit_type_name): Likewise.
9719 (create_debug_type_hash_table, read_cutu_die_from_dwo)
9720 (cutu_reader::cutu_reader, read_call_site_scope)
9721 (find_partial_die, follow_die_offset): Update.
9722 * dwarf2/comp-unit.h: New file, from dwarf2read.c.
9723
9724 2020-02-08 Tom Tromey <tom@tromey.com>
9725
9726 * dwarf2/read.c (read_offset_1): Move to leb.c.
9727 (read_abbrev_offset, read_offset, dwarf_decode_line_header)
9728 (dwarf_decode_macro_bytes): Update.
9729 * dwarf2/leb.c (read_offset): Rename; move from read.c.
9730 * dwarf2/leb.h (read_offset): Declare.
9731
9732 2020-02-08 Tom Tromey <tom@tromey.com>
9733
9734 * dwarf2/read.c (dwarf2_section_size): Remove.
9735 (error_check_comp_unit_head, dwarf2_symbol_mark_computed):
9736 Update.
9737 * dwarf2/section.h (struct dwarf2_section_info) <get_size>: New method.
9738
9739 2020-02-08 Tom Tromey <tom@tromey.com>
9740
9741 * dwarf2/read.c (read_initial_length): Move to leb.c.
9742 * dwarf2/leb.h (read_initial_length): Declare.
9743 * dwarf2/leb.c (read_initial_length): Move from read.c. Add
9744 handle_nonstd parameter.
9745 * dwarf2/frame.c (read_initial_length): Remove.
9746 (decode_frame_entry_1): Update.
9747
9748 2020-02-08 Tom Tromey <tom@tromey.com>
9749
9750 * dwarf2/loc.c (dwarf2_find_location_expression)
9751 (dwarf_evaluate_loc_desc::get_tls_address)
9752 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
9753 (rw_pieced_value, dwarf2_evaluate_loc_desc_full)
9754 (dwarf2_locexpr_baton_eval, dwarf2_evaluate_property)
9755 (dwarf2_compile_property_to_c)
9756 (dwarf2_loc_desc_get_symbol_read_needs)
9757 (dwarf2_compile_expr_to_ax, locexpr_describe_location)
9758 (locexpr_tracepoint_var_ref, locexpr_generate_c_location)
9759 (loclist_describe_location, loclist_tracepoint_var_ref)
9760 (loclist_generate_c_location): Update.
9761 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Update.
9762 * dwarf2/loc.h (dwarf2_per_cu_objfile, dwarf2_per_cu_addr_size)
9763 (dwarf2_per_cu_ref_addr_size, dwarf2_per_cu_offset_size)
9764 (dwarf2_per_cu_text_offset, dwarf2_version): Don't declare.
9765 * dwarf2/read.c (dwarf2_per_cu_data::objfile)
9766 (dwarf2_per_cu_data::addr_size)
9767 (dwarf2_per_cu_data::ref_addr_size)
9768 (dwarf2_per_cu_data::text_offset)
9769 (dwarf2_per_cu_data::addr_type): Now methods.
9770 (per_cu_header_read_in): Make per_cu "const".
9771 (dwarf2_version): Remove.
9772 (dwarf2_per_cu_data::int_type): Now a method.
9773 (dwarf2_per_cu_data::_addr_sized_int_type): Likewise.
9774 (set_die_type, read_array_type, read_subrange_index_type)
9775 (read_tag_string_type, read_subrange_type): Update.
9776 * dwarf2/read.h (struct dwarf2_per_cu_data) <addr_size,
9777 offset_size, ref_addr_size, text_offset, addr_type, version,
9778 objfile, int_type, addr_sized_int_type>: Declare methods.
9779
9780 2020-02-08 Tom Tromey <tom@tromey.com>
9781
9782 * dwarf2/read.h (struct dwarf2_per_cu_data) <imported_symtabs>:
9783 Move earlier.
9784
9785 2020-02-08 Tom Tromey <tom@tromey.com>
9786
9787 * dwarf2/read.h (dwarf_line_debug): Declare.
9788 * Makefile.in (COMMON_SFILES): Add dwarf2/line-header.c.
9789 * dwarf2/read.c: Move line_header code to new files.
9790 (dwarf_line_debug): No longer static.
9791 * dwarf2/line-header.c: New file.
9792 * dwarf2/line-header.h: New file.
9793
9794 2020-02-08 Tom Tromey <tom@tromey.com>
9795
9796 * dwarf2/read.c (struct line_header) <file_full_name,
9797 file_file_name>: Return unique_xmalloc_ptr.
9798 (line_header::file_file_name): Update.
9799 (line_header::file_full_name): Update.
9800 (dw2_get_file_names_reader): Update.
9801 (macro_start_file): Update.
9802
9803 2020-02-08 Tom Tromey <tom@tromey.com>
9804
9805 * dwarf2/read.c (struct line_header) <file_full_name,
9806 file_file_name>: Declare methods.
9807 (dw2_get_file_names_reader): Update.
9808 (file_file_name): Now a method.
9809 (file_full_name): Likewise.
9810 (macro_start_file): Update.
9811
9812 2020-02-08 Tom Tromey <tom@tromey.com>
9813
9814 * dwarf2/read.c (dwarf_always_disassemble)
9815 (show_dwarf_always_disassemble): Move to loc.c.
9816 (_initialize_dwarf2_read): Move "always-disassemble" registration
9817 to loc.c.
9818 * dwarf2/read.h (dwarf_always_disassemble): Don't declare.
9819 * dwarf2/loc.c (dwarf_always_disassemble): Move from read.c. Now
9820 static.
9821 (show_dwarf_always_disassemble): Move from read.c.
9822 (_initialize_dwarf2loc): Move always-disassemble from read.c.
9823
9824 2020-02-08 Tom Tromey <tom@tromey.com>
9825
9826 * dwarf2/read.c (~dwarf2_per_objfile): Update.
9827 (create_quick_file_names_table): Return htab_up.
9828 (dw2_get_file_names_reader, dw2_forget_cached_source_info):
9829 Update.
9830 * dwarf2/read.h (struct dwarf2_per_objfile)
9831 <quick_file_names_table>: Now htab_up.
9832
9833 2020-02-08 Tom Tromey <tom@tromey.com>
9834
9835 * dwarf2/abbrev.c (abbrev_table::read): Simplify.
9836
9837 2020-02-08 Tom Tromey <tom@tromey.com>
9838
9839 * dwarf2/abbrev.c (abbrev_table): Move constructor from header.
9840 Rewrite.
9841 (abbrev_table::add_abbrev, abbrev_table::lookup_abbrev): Rewrite.
9842 * dwarf2/abbrev.h (struct abbrev_info) <next>: Remove.
9843 (abbrev_table::abbrev_table): No longer inline.
9844 (ABBREV_HASH_SIZE): Remove.
9845 (abbrev_table::m_abbrevs): Now an htab_up.
9846
9847 2020-02-08 Tom Tromey <tom@tromey.com>
9848
9849 * dwarf2/read.c (read_cutu_die_from_dwo): Update.
9850 (cutu_reader): Update.
9851 (build_type_psymtabs_1): Update.
9852 * dwarf2/abbrev.c (abbrev_table::read): Rename.
9853 (abbrev_table::alloc_abbrev): Update.
9854 * dwarf2/abbrev.h (abbrev_table_up): Move earlier.
9855 (abbrev_table::read): New static method, renamed from
9856 abbrev_table_read_table.
9857 (abbrev_table::alloc_abbrev)
9858 (abbrev_table::add_abbrev): Now private.
9859 (abbrev_table::abbrev_table): Now private.
9860 (abbrev_table::m_abbrev_obstack): Now private. Rename.
9861
9862 2020-02-08 Tom Tromey <tom@tromey.com>
9863
9864 * dwarf2/read.c (set_die_type, get_die_type_at_offset): Update.
9865 * dwarf2/read.h (struct dwarf2_per_objfile) <die_type_hash>: Now
9866 htab_up.
9867
9868 2020-02-08 Tom Tromey <tom@tromey.com>
9869
9870 * dwarf2/read.c (struct dwp_file) <loaded_cus, loaded_tus>: Now
9871 htab_up.
9872 (lookup_dwo_unit_in_dwp): Update.
9873 (allocate_dwp_loaded_cutus_table): Return htab_up. Don't allocate
9874 on obstack.
9875
9876 2020-02-08 Tom Tromey <tom@tromey.com>
9877
9878 * dwarf2/read.c (allocate_dwo_file_hash_table): Don't allocate on
9879 obstack.
9880
9881 2020-02-08 Tom Tromey <tom@tromey.com>
9882
9883 * dwarf2/read.c (~dwarf2_per_objfile): Don't delete
9884 line_header_hash.
9885 (handle_DW_AT_stmt_list): Update. Don't allocate on obstack.
9886 * dwarf2/read.h (struct dwarf2_per_objfile) <line_header_hash>:
9887 Change type to htab_up.
9888
9889 2020-02-08 Tom Tromey <tom@tromey.com>
9890
9891 * dwarf2/read.c (allocate_type_unit_groups_table): Return
9892 htab_up. Don't allocate on obstack.
9893 (get_type_unit_group, dwarf2_build_psymtabs_hard): Update.
9894 * dwarf2/read.h (struct dwarf2_per_objfile) <type_unit_groups>:
9895 Change type to htab_up.
9896
9897 2020-02-08 Tom Tromey <tom@tromey.com>
9898
9899 * dwarf2/read.h (struct dwarf2_per_objfile) <signatured_types>:
9900 Change type to htab_up.
9901 * dwarf2/read.c (create_signatured_type_table_from_index)
9902 (create_signatured_type_table_from_debug_names)
9903 (create_all_type_units, add_type_unit)
9904 (lookup_dwo_signatured_type, lookup_signatured_type)
9905 (process_skeletonless_type_unit): Update.
9906 (create_debug_type_hash_table, create_debug_types_hash_table):
9907 Change type of types_htab.
9908 (allocate_signatured_type_table, allocate_dwo_unit_table): Return
9909 htab_up. Don't allocate on obstack.
9910 (create_cus_hash_table): Change type of cus_htab parameter.
9911 (struct dwo_file) <cus, tus>: Now htab_up.
9912 (lookup_dwo_signatured_type, lookup_dwo_cutu)
9913 (process_dwo_file_for_skeletonless_type_units, lookup_dwo_cutu)
9914 (queue_and_load_all_dwo_tus): Update.
9915 * dwarf2/index-write.c (write_gdbindex): Update.
9916 (write_debug_names): Update.
9917
9918 2020-02-08 Tom Tromey <tom@tromey.com>
9919
9920 * dwarf2/read.h (struct dwarf2_queue_item): Move from
9921 dwarf2/read.c. Remove "next" member. Add constructor ntad
9922 destructor.
9923 (struct dwarf2_per_objfile) <queue>: New member.
9924 * dwarf2/read.c (struct dwarf2_queue_item): Move to
9925 dwarf2/read.h.
9926 (dwarf2_queue, dwarf2_queue_tail): Remove.
9927 (class dwarf2_queue_guard): Add parameter to constructor. Use
9928 DISABLE_COPY_AND_ASSIGN.
9929 <m_per_objfile>: New member.
9930 <~dwarf2_queue_guard>: Rewrite.
9931 (dw2_do_instantiate_symtab, queue_comp_unit, process_queue):
9932 Update.
9933 (~dwarf2_queue_item): New.
9934
9935 2020-02-08 Tom Tromey <tom@tromey.com>
9936
9937 * dwarf2/read.c (struct die_info) <has_children>: New member.
9938 (dw2_get_file_names_reader): Remove has_children.
9939 (dw2_get_file_names): Update.
9940 (read_cutu_die_from_dwo): Remove has_children.
9941 (cutu_reader::init_tu_and_read_dwo_dies)
9942 (cutu_reader::cutu_reader): Update.
9943 (process_psymtab_comp_unit_reader, build_type_psymtabs_reader):
9944 Remove has_children.
9945 (build_type_psymtabs_1, process_skeletonless_type_unit)
9946 (load_partial_comp_unit, load_full_comp_unit): Update.
9947 (create_dwo_cu_reader): Remove has_children.
9948 (create_cus_hash_table, read_die_and_children): Update.
9949 (read_full_die_1,read_full_die): Remove has_children.
9950 (read_signatured_type): Update.
9951 (class cutu_reader) <has_children>: Remove.
9952
9953 2020-02-08 Tom Tromey <tom@tromey.com>
9954
9955 * dwarf2/expr.c: Rename from dwarf2expr.c.
9956 * dwarf2/expr.h: Rename from dwarf2expr.h.
9957 * dwarf2/frame-tailcall.c: Rename from dwarf2-frame-tailcall.c.
9958 * dwarf2/frame-tailcall.h: Rename from dwarf2-frame-tailcall.h.
9959 * dwarf2/frame.c: Rename from dwarf2-frame.c.
9960 * dwarf2/frame.h: Rename from dwarf2-frame.h.
9961 * dwarf2/index-cache.c: Rename from dwarf-index-cache.c.
9962 * dwarf2/index-cache.h: Rename from dwarf-index-cache.h.
9963 * dwarf2/index-common.c: Rename from dwarf-index-common.c.
9964 * dwarf2/index-common.h: Rename from dwarf-index-common.h.
9965 * dwarf2/index-write.c: Rename from dwarf-index-write.c.
9966 * dwarf2/index-write.h: Rename from dwarf-index-write.h.
9967 * dwarf2/loc.c: Rename from dwarf2loc.c.
9968 * dwarf2/loc.h: Rename from dwarf2loc.h.
9969 * dwarf2/read.c: Rename from dwarf2read.c.
9970 * dwarf2/read.h: Rename from dwarf2read.h.
9971 * dwarf2/abbrev.c, aarch64-tdep.c, alpha-tdep.c,
9972 amd64-darwin-tdep.c, arc-tdep.c, arm-tdep.c, bfin-tdep.c,
9973 compile/compile-c-symbols.c, compile/compile-cplus-symbols.c,
9974 compile/compile-loc2c.c, cris-tdep.c, csky-tdep.c, findvar.c,
9975 gdbtypes.c, guile/scm-type.c, h8300-tdep.c, hppa-bsd-tdep.c,
9976 hppa-linux-tdep.c, i386-darwin-tdep.c, i386-linux-tdep.c,
9977 i386-tdep.c, iq2000-tdep.c, m32c-tdep.c, m68hc11-tdep.c,
9978 m68k-tdep.c, microblaze-tdep.c, mips-tdep.c, mn10300-tdep.c,
9979 msp430-tdep.c, nds32-tdep.c, nios2-tdep.c, or1k-tdep.c,
9980 riscv-tdep.c, rl78-tdep.c, rs6000-tdep.c, rx-tdep.c, s12z-tdep.c,
9981 s390-tdep.c, score-tdep.c, sh-tdep.c, sparc-linux-tdep.c,
9982 sparc-tdep.c, sparc64-linux-tdep.c, sparc64-tdep.c, tic6x-tdep.c,
9983 tilegx-tdep.c, v850-tdep.c, xstormy16-tdep.c, xtensa-tdep.c:
9984 Update.
9985 * Makefile.in (COMMON_SFILES): Update.
9986 (HFILES_NO_SRCDIR): Update.
9987
9988 2020-02-08 Tom Tromey <tom@tromey.com>
9989
9990 * dwarf2read.c (struct die_reader_specs) <comp_dir>: Remove.
9991 (init_cu_die_reader, read_cutu_die_from_dwo): Update.
9992
9993 2020-02-08 Tom Tromey <tom@tromey.com>
9994
9995 * dwarf2read.h (struct die_info): Don't declare.
9996
9997 2020-02-08 Tom Tromey <tom@tromey.com>
9998
9999 * dwarf2read.h (die_info_ptr): Remove typedef.
10000
10001 2020-02-08 Tom Tromey <tom@tromey.com>
10002
10003 * dwarf2read.c (read_call_site_scope)
10004 (handle_data_member_location, dwarf2_add_member_fn)
10005 (mark_common_block_symbol_computed, read_common_block)
10006 (attr_to_dynamic_prop, partial_die_info::read)
10007 (var_decode_location, dwarf2_fetch_die_loc_sect_off)
10008 (dwarf2_symbol_mark_computed, set_die_type): Update.
10009 * dwarf2/attribute.h (struct attribute) <form_is_block>: Declare
10010 method.
10011 (attr_form_is_block): Don't declare.
10012 * dwarf2/attribute.c (attribute::form_is_block): Now a method.
10013
10014 2020-02-08 Tom Tromey <tom@tromey.com>
10015
10016 * dwarf2read.c (dwarf2_find_base_address, )
10017 (read_call_site_scope, rust_containing_type)
10018 (dwarf2_get_pc_bounds, dwarf2_record_block_ranges)
10019 (handle_data_member_location, dwarf2_add_member_fn)
10020 (get_alignment, read_structure_type, process_structure_scope)
10021 (mark_common_block_symbol_computed, read_common_block)
10022 (read_tag_string_type, attr_to_dynamic_prop, read_subrange_type)
10023 (partial_die_info::read, read_attribute_value, new_symbol)
10024 (lookup_die_type, dwarf2_get_ref_die_offset)
10025 (dwarf2_get_attr_constant_value, follow_die_ref_or_sig)
10026 (dwarf2_fetch_die_loc_sect_off, get_DW_AT_signature_type)
10027 (dwarf2_symbol_mark_computed): Update.
10028 * dwarf2/attribute.h (struct attribute) <value_as_address,
10029 form_is_section_offset, form_is_constant, form_is_ref>: Declare
10030 methods.
10031 (value_as_address, attr_form_is_section_offset)
10032 (attr_form_is_constant, attr_form_is_ref): Don't declare.
10033 * dwarf2/attribute.c (attribute::value_as_address)
10034 (attribute::form_is_section_offset, attribute::form_is_constant)
10035 (attribute::form_is_ref): Now methods.
10036
10037 2020-02-08 Tom Tromey <tom@tromey.com>
10038
10039 * dwarf2read.c (struct attribute, DW_STRING)
10040 (DW_STRING_IS_CANONICAL, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR)
10041 (DW_SIGNATURE, struct dwarf_block, attr_value_as_address)
10042 (attr_form_is_block, attr_form_is_section_offset)
10043 (attr_form_is_constant, attr_form_is_ref): Move.
10044 * dwarf2/attribute.h: New file.
10045 * dwarf2/attribute.c: New file, from dwarf2read.c.
10046 * Makefile.in (COMMON_SFILES): Add dwarf2/attribute.c.
10047
10048 2020-02-08 Tom Tromey <tom@tromey.com>
10049
10050 * dwarf2read.c (abbrev_table_up, struct abbrev_info)
10051 (struct attr_abbrev, ABBREV_HASH_SIZE, struct abbrev_table):
10052 Move.
10053 (read_cutu_die_from_dwo, build_type_psymtabs_1): Update.
10054 (abbrev_table::alloc_abbrev, abbrev_table::add_abbrev)
10055 (abbrev_table::lookup_abbrev, abbrev_table_read_table): Move to
10056 abbrev.c.
10057 * dwarf2/abbrev.h: New file.
10058 * dwarf2/abbrev.c: New file, from dwarf2read.c.
10059 * Makefile.in (COMMON_SFILES): Add dwarf2/abbrev.c.
10060
10061 2020-02-08 Tom Tromey <tom@tromey.com>
10062
10063 * dwarf2read.c (dwarf2_section_buffer_overflow_complaint)
10064 (dwarf2_section_size, dwarf2_get_section_info)
10065 (create_signatured_type_table_from_debug_names)
10066 (create_addrmap_from_aranges, read_debug_names_from_section)
10067 (get_gdb_index_contents_from_section, read_comp_unit_head)
10068 (error_check_comp_unit_head, read_abbrev_offset)
10069 (create_debug_type_hash_table, init_cu_die_reader)
10070 (read_cutu_die_from_dwo, dwarf2_build_psymtabs_hard)
10071 (read_comp_units_from_section, create_cus_hash_table)
10072 (create_dwp_hash_table, create_dwo_unit_in_dwp_v1)
10073 (create_dwp_v2_section, dwarf2_rnglists_process)
10074 (dwarf2_ranges_process, read_die_and_siblings, read_full_die)
10075 (abbrev_table_read_table, read_indirect_string_at_offset_from)
10076 (read_indirect_string_from_dwz, read_addr_index_1)
10077 (read_str_index, dwarf_decode_line_header, skip_form_bytes)
10078 (dwarf_decode_macro_bytes, dwarf_decode_macros)
10079 (fill_in_loclist_baton): Update.
10080 * dwarf2/section.h (struct dwarf2_section_info) <get_name,
10081 get_containing_section, get_bfd_owner, get_bfd_section,
10082 get_file_name, get_id, get_flags, empty, read>: Declare methods.
10083 (dwarf2_read_section, get_section_name, get_section_file_name)
10084 (get_containing_section, get_section_bfd_owner)
10085 (get_section_bfd_section, get_section_name, get_section_file_name)
10086 (get_section_id, get_section_flags, dwarf2_section_empty_p): Don't
10087 declare.
10088 * dwarf2/section.c (dwarf2_section_info::get_containing_section)
10089 (dwarf2_section_info::get_bfd_owner)
10090 (dwarf2_section_info::get_bfd_section)
10091 (dwarf2_section_info::get_name)
10092 (dwarf2_section_info::get_file_name, dwarf2_section_info::get_id)
10093 (dwarf2_section_info::get_flags, dwarf2_section_info::empty)
10094 (dwarf2_section_info::read): Now methods.
10095 * dwarf-index-write.c (class debug_names): Update.
10096
10097 2020-02-08 Tom Tromey <tom@tromey.com>
10098
10099 * dwarf2read.h (struct dwarf2_section_info, dwarf2_read_section):
10100 Move to dwarf2/section.h.
10101 * dwarf2read.c (get_containing_section, get_section_bfd_owner)
10102 (get_section_bfd_section, get_section_name)
10103 (get_section_file_name, get_section_id, get_section_flags)
10104 (dwarf2_section_empty_p, dwarf2_read_section): Moe to
10105 dwarf2/section.c.
10106 * dwarf2/section.h: New file.
10107 * dwarf2/section.c: New file, from dwarf2read.c.
10108 * Makefile.in (COMMON_SFILES): Add dwarf2/section.c.
10109
10110 2020-02-08 Tom Tromey <tom@tromey.com>
10111
10112 * dwarf2read.h (read_unsigned_leb128): Don't declare.
10113 * dwarf2read.c (read_1_byte, read_1_signed_byte, read_2_bytes)
10114 (read_2_signed_bytes, read_3_bytes, read_4_bytes)
10115 (read_4_signed_bytes, read_8_bytes): Move to dwarf2/leb.h.
10116 (read_unsigned_leb128, read_signed_leb128): Move to dwarf2/leb.c.
10117 * dwarf2/leb.h: New file, from dwarf2read.c.
10118 * dwarf2/leb.c: New file, from dwarf2read.c.
10119 * dwarf2-frame.c (read_1_byte, read_4_bytes, read_8_bytes):
10120 Remove.
10121 * Makefile.in (CONFIG_SRC_SUBDIR): Add dwarf2.
10122 (COMMON_SFILES): Add dwarf2/leb.c.
10123
10124 2020-02-08 Joel Brobecker <brobecker@adacore.com>
10125
10126 GDB 9.1 released.
10127
10128 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
10129
10130 PR gdb/25190:
10131 * gdb/remote-sim.c (gdb_os_write_stderr): Update.
10132 * gdb/remote.c (remote_console_output): Update.
10133 * gdb/ui-file.c (fputs_unfiltered): Rename to...
10134 (ui_file_puts): ...this.
10135 * gdb/ui-file.h (ui_file_puts): Add declaration.
10136 * gdb/utils.c (emit_style_escape): Update.
10137 (flush_wrap_buffer): Update.
10138 (fputs_maybe_filtered): Update.
10139 (fputs_unfiltered): Add function.
10140
10141 2020-02-05 Iain Buclaw <ibuclaw@gdcproject.org>
10142
10143 * gdb/event-loop.c (gdb_wait_for_event): Update.
10144 * gdb/printcmd.c (printf_command): Update.
10145 * gdb/remote-fileio.c (remote_fileio_func_write): Update.
10146 * gdb/remote-sim.c (gdb_os_flush_stdout): Update.
10147 (gdb_os_flush_stderr): Update.
10148 * gdb/remote.c (remote_console_output): Update.
10149 * gdb/ui-file.c (gdb_flush): Rename to...
10150 (ui_file_flush): ...this.
10151 (stderr_file::write): Update.
10152 (stderr_file::puts): Update.
10153 * gdb/ui-file.h (gdb_flush): Rename to...
10154 (ui_file_flush): ...this.
10155 * gdb/utils.c (gdb_flush): Add function.
10156 * gdb/utils.h (gdb_flush): Add declaration.
10157
10158 2020-02-07 Tom Tromey <tromey@adacore.com>
10159
10160 PR breakpoints/24915:
10161 * source.c (find_and_open_source): Do not check basenames_may_differ.
10162
10163 2020-02-07 Tom Tromey <tom@tromey.com>
10164
10165 * README: Update gdbserver documentation.
10166 * gdbserver: Move to top level.
10167 * configure.tgt (build_gdbserver): Remove.
10168 * configure.ac: Remove --enable-gdbserver.
10169 * configure: Rebuild.
10170 * Makefile.in (distclean): Don't mention gdbserver.
10171
10172 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
10173
10174 * source-cache.c (source_cache::ensure): Surround
10175 get_plain_source_lines with a try/catch.
10176 (source_cache::get_line_charpos): Get rid of try/catch
10177 and only check for the return value of "ensure".
10178 * tui/tui-source.c (tui_source_window::set_contents):
10179 Simplify "nlines" calculation.
10180
10181 2020-02-06 Shahab Vahedi <shahab@synopsys.com>
10182
10183 * MAINTAINERS (Write After Approval): Add myself.
10184
10185 2020-02-05 Christian Biesinger <cbiesinger@google.com>
10186
10187 * sparc-nat.h (struct sparc_target) <xfer_partial>: Fix base class
10188 function call.
10189
10190 2020-02-05 Christian Biesinger <cbiesinger@google.com>
10191
10192 * ppc-nbsd-tdep.h: Fix macro name in #endif comment.
10193
10194 2020-02-05 Maciej W. Rozycki <macro@wdc.com>
10195
10196 * nat/riscv-linux-tdesc.h: New file.
10197 * nat/riscv-linux-tdesc.c: New file, taking code from...
10198 * riscv-linux-nat.c (riscv_linux_nat_target::read_description):
10199 ... here.
10200 * configure.nat <linux> <riscv*>: Add nat/riscv-linux-tdesc.o to
10201 NATDEPFILES.
10202
10203 2020-02-04 Andrew Burgess <andrew.burgess@embecosm.com>
10204
10205 * remote-sim.c (sim_inferior_data::sim_inferior_data): Assert that
10206 we don't set the fake simulator ptid to the null_ptid.
10207
10208 2020-02-03 Simon Marchi <simon.marchi@efficios.com>
10209
10210 * fork-child.c (gdb_startup_inferior): Use bool instead of int.
10211 * gdbthread.h (class thread_info) <resumed>: Likewise.
10212 * infrun.c (resume_1): Likewise.
10213 (proceed): Likewise.
10214 (infrun_thread_stop_requested): Likewise.
10215 (stop_all_threads): Likewise.
10216 (handle_inferior_event): Likewise.
10217 (restart_threads): Likewise.
10218 (finish_step_over): Likewise.
10219 (keep_going_stepped_thread): Likewise.
10220 * linux-nat.c (attach_proc_task_lwp_callback): Likewise.
10221 (linux_handle_extended_wait): Likewise.
10222 * record-btrace.c (get_thread_current_frame_id): Likewise.
10223 * record-full.c (record_full_wait_1): Likewise.
10224 * remote.c (remote_target::process_initial_stop_replies): Likewise.
10225 * target.c (target_resume): Likewise.
10226 * thread.c (set_running_thread): Likewise.
10227
10228 2020-02-03 Alok Kumar Sharma <AlokKumar.Sharma@amd.com>
10229
10230 * f-valprint.c (f77_print_array_1): Changed datatype of index
10231 variable to LONGEST from int to enable it to contain bound
10232 values correctly.
10233
10234 2020-02-03 Maciej W. Rozycki <macro@wdc.com>
10235
10236 * riscv-linux-nat.c [!NFPREG] (NFPREG): New macro.
10237 (supply_fpregset_regnum, fill_fpregset): Handle regset buffer
10238 offsets according to FLEN determined.
10239 (riscv_linux_nat_target::read_description): Determine FLEN
10240 dynamically.
10241 (riscv_linux_nat_target::fetch_registers): Size regset buffer
10242 according to FLEN determined.
10243 (riscv_linux_nat_target::store_registers): Likewise.
10244
10245 2020-02-01 Shahab Vahedi <shahab@synopsys.com>
10246
10247 * target-descriptions.c (tdesc_register_in_reggroup_p): Return 0
10248 when reg->group is empty and reggroup is not.
10249
10250 2020-01-31 Tom Tromey <tromey@adacore.com>
10251
10252 * ravenscar-thread.c (ravenscar_thread_target::mourn_inferior):
10253 Call beneath target's mourn_inferior after unpushing.
10254
10255 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
10256
10257 PR tui/9765
10258 * tui/tui-disasm.c (tui_find_disassembly_address): If we don't
10259 have enough lines to fill the screen, still return the lowest
10260 address we found.
10261
10262 2020-01-31 Andrew Burgess <andrew.burgess@embecosm.com>
10263
10264 * tui/tui-win.c (_initialize_tui_win): Update help text for '+',
10265 '-', '<', and '>' commands.
10266
10267 2020-01-29 Pedro Alves <palves@redhat.com>
10268 Sergio Durigan Junior <sergiodj@redhat.com>
10269
10270 * infcmd.c (construct_inferior_arguments): Assert that
10271 'argc' is greater than 0.
10272
10273 2020-01-29 Luis Machado <luis.machado@linaro.org>
10274
10275 * aarch64-tdep.c (BRK_INSN_MASK): Define to 0xffe0001f.
10276 (BRK_INSN_MASK): Define to 0xd4200000.
10277 (aarch64_program_breakpoint_here_p): New function.
10278 (aarch64_gdbarch_init): Set gdbarch_program_breakpoint_here_p hook.
10279 * arch-utils.c (default_program_breakpoint_here_p): Moved from
10280 breakpoint.c.
10281 * arch-utils.h (default_program_breakpoint_here_p): Moved from
10282 breakpoint.h
10283 * breakpoint.c (bp_loc_is_permanent): Changed return type to bool and
10284 call gdbarch_program_breakpoint_here_p.
10285 (program_breakpoint_here): Moved to arch-utils.c, renamed to
10286 default_program_breakpoint_here_p, changed return type to bool and
10287 simplified.
10288 * breakpoint.h (program_breakpoint_here): Moved prototype to
10289 arch-utils.h, renamed to default_program_breakpoint_here_p and changed
10290 return type to bool.
10291 * gdbarch.c: Regenerate.
10292 * gdbarch.h: Regenerate.
10293 * gdbarch.sh (program_breakpoint_here_p): New method.
10294 * infrun.c (handle_signal_stop): Call
10295 gdbarch_program_breakpoint_here_p.
10296
10297 2020-01-26 Tom Tromey <tom@tromey.com>
10298
10299 * ctfread.c (struct ctf_fp_info): Reindent.
10300 (_initialize_ctfread): Remove.
10301
10302 2020-01-26 Tom Tromey <tom@tromey.com>
10303
10304 * psymtab.c (partial_map_expand_apply)
10305 (psym_find_pc_sect_compunit_symtab, psym_lookup_symbol)
10306 (psymtab_to_symtab, psym_find_last_source_symtab, dump_psymtab)
10307 (psym_print_stats, psym_expand_symtabs_for_function)
10308 (psym_map_symbol_filenames, psym_map_matching_symbols)
10309 (psym_expand_symtabs_matching)
10310 (partial_symtab::read_dependencies, maintenance_info_psymtabs)
10311 (maintenance_check_psymtabs): Use new methods.
10312 * psympriv.h (struct partial_symtab) <readin_p,
10313 get_compunit_symtab>: New methods.
10314 <readin, compunit_symtab>: Remove members.
10315 (struct standard_psymtab): New.
10316 (struct legacy_psymtab): Derive from standard_psymtab.
10317 * dwarf2read.h (struct dwarf2_psymtab): Derive from
10318 standard_psymtab.
10319 * ctfread.c (struct ctf_psymtab): Derive from standard_psymtab.
10320
10321 2020-01-26 Tom Tromey <tom@tromey.com>
10322
10323 * xcoffread.c (xcoff_psymtab_to_symtab_1): Call
10324 read_dependencies. Add assert.
10325 * psymtab.c (partial_symtab::read_dependencies): New method.
10326 * psympriv.h (struct partial_symtab) <read_dependencies>: New
10327 method.
10328 * mdebugread.c (psymtab_to_symtab_1): Call read_dependencies.
10329 * dwarf2read.c (dwarf2_psymtab::expand_psymtab): Call
10330 read_dependencies.
10331 * dbxread.c (dbx_psymtab_to_symtab_1): Call read_dependencies.
10332 Add assert.
10333
10334 2020-01-26 Tom Tromey <tom@tromey.com>
10335
10336 * xcoffread.c (xcoff_psymtab_to_symtab_1): Change argument order.
10337 Call expand_psymtab.
10338 (xcoff_read_symtab): Call expand_psymtab.
10339 (xcoff_start_psymtab, xcoff_end_psymtab): Set
10340 legacy_expand_psymtab.
10341 * psympriv.h (struct partial_symtab) <expand_psymtab>: New
10342 method.
10343 (struct legacy_psymtab) <expand_psymtab>: Implement.
10344 <legacy_expand_psymtab>: New member.
10345 * mdebugread.c (mdebug_read_symtab): Call expand_psymtab.
10346 (parse_partial_symbols): Set legacy_expand_psymtab.
10347 (psymtab_to_symtab_1): Change argument order. Call
10348 expand_psymtab.
10349 (new_psymtab): Set legacy_expand_psymtab.
10350 * dwarf2read.h (struct dwarf2_psymtab) <expand_psymtab>: Declare.
10351 * dwarf2read.c (dwarf2_psymtab::read_symtab): Call
10352 expand_psymtab.
10353 (dwarf2_psymtab::expand_psymtab): Rename from
10354 psymtab_to_symtab_1. Call expand_psymtab.
10355 * dbxread.c (start_psymtab): Set legacy_expand_psymtab.
10356 (dbx_end_psymtab): Likewise.
10357 (dbx_psymtab_to_symtab_1): Change argument order. Call
10358 expand_psymtab.
10359 (dbx_read_symtab): Call expand_psymtab.
10360 * ctfread.c (struct ctf_psymtab) <expand_psymtab>: Declare.
10361 (ctf_psymtab::expand_psymtab): Rename from psymtab_to_symtab.
10362 (ctf_psymtab::read_symtab): Call expand_psymtab.
10363
10364 2020-01-26 Tom Tromey <tom@tromey.com>
10365
10366 * xcoffread.c (xcoff_read_symtab): Remove prints. Add assert.
10367 * psymtab.c (psymtab_to_symtab): Print verbose "Reading"
10368 messages.
10369 * mdebugread.c (mdebug_read_symtab): Remove prints.
10370 * dwarf2read.c (dwarf2_psymtab::read_symtab): Remove prints. Add
10371 assert.
10372 * dbxread.c (dbx_read_symtab): Remove prints. Add assert.
10373
10374 2020-01-26 Tom Tromey <tom@tromey.com>
10375
10376 * xcoffread.c (this_symtab_psymtab, read_xcoff_symtab)
10377 (xcoff_psymtab_to_symtab_1, xcoff_read_symtab)
10378 (xcoff_start_psymtab, xcoff_end_psymtab, scan_xcoff_symtab): Use
10379 legacy_symtab.
10380 * stabsread.h (dbx_end_psymtab): Use legacy_symtab.
10381 * psymtab.c (psymtab_to_symtab): Call method.
10382 (dump_psymtab): Update.
10383 * psympriv.h (struct partial_symtab): Add virtual destructor.
10384 <read_symtab>: New method.
10385 (struct legacy_symtab): New.
10386 * mdebugread.c (mdebug_read_symtab): Use legacy_psymtab.
10387 (struct pst_map) <pst>: Now a legacy_psymtab.
10388 (parse_procedure, parse_partial_symbols, psymtab_to_symtab_1)
10389 (new_psymtab): Use legacy_psymtab.
10390 * dwarf2read.h (struct dwarf2_psymtab): New.
10391 (struct dwarf2_per_cu_data) <psymtab>: Use it.
10392 * dwarf2read.c (dwarf2_create_include_psymtab)
10393 (dwarf2_build_include_psymtabs, create_type_unit_group)
10394 (create_partial_symtab, process_psymtab_comp_unit_reader)
10395 (build_type_psymtabs_reader, build_type_psymtab_dependencies)
10396 (set_partial_user): Use dwarf2_psymtab.
10397 (dwarf2_psymtab::read_symtab): Rename from dwarf2_read_symtab.
10398 (psymtab_to_symtab_1, process_full_comp_unit)
10399 (process_full_type_unit, dwarf2_ranges_read)
10400 (dwarf2_get_pc_bounds, psymtab_include_file_name)
10401 (dwarf_decode_lines): Use dwarf2_psymtab.
10402 * dwarf-index-write.c (psym_index_map): Use dwarf2_psymtab.
10403 (add_address_entry_worker, write_one_signatured_type)
10404 (recursively_count_psymbols, recursively_write_psymbols)
10405 (write_one_signatured_type, psyms_seen_size, write_gdbindex)
10406 (write_debug_names): Likewise.
10407 * dbxread.c (struct header_file_location): Take a legacy_psymtab.
10408 <pst>: Now a legacy_psymtab.
10409 (find_corresponding_bincl_psymtab): Return a legacy_psymtab.
10410 (read_dbx_symtab, start_psymtab, dbx_end_psymtab)
10411 (dbx_psymtab_to_symtab_1, read_ofile_symtab): Use legacy_psymtab.
10412 * ctfread.c (struct ctf_psymtab): New.
10413 (ctf_start_symtab, ctf_end_symtab, psymtab_to_symtab): Take a
10414 ctf_psymtab.
10415 (ctf_psymtab::read_symtab): Rename from ctf_read_symtab.
10416 (create_partial_symtab): Return a ctf_psymtab.
10417 (scan_partial_symbols): Update.
10418
10419 2020-01-26 Tom Tromey <tom@tromey.com>
10420
10421 * xcoffread.c (xcoff_start_psymtab): Use new.
10422 * psymtab.c (partial_symtab::partial_symtab): New constructor,
10423 renamed from start_psymtab_common.
10424 * psympriv.h (struct partial_symtab): Add new constructor.
10425 (start_psymtab_common): Don't declare.
10426 * mdebugread.c (parse_partial_symbols): Use new.
10427 * dwarf2read.c (create_partial_symtab): Use new.
10428 * dbxread.c (start_psymtab): Use new.
10429 * ctfread.c (create_partial_symtab): Use new.
10430
10431 2020-01-26 Tom Tromey <tom@tromey.com>
10432
10433 * xcoffread.c (xcoff_end_psymtab): Use new.
10434 * psymtab.c (start_psymtab_common): Use new.
10435 (partial_symtab::partial_symtab): Rename from allocate_psymtab.
10436 Update.
10437 * psympriv.h (struct partial_symtab): Add parameters to
10438 constructor. Don't inline.
10439 (allocate_psymtab): Don't declare.
10440 * mdebugread.c (new_psymtab): Use new.
10441 * dwarf2read.c (dwarf2_create_include_psymtab): Use new.
10442 * dbxread.c (dbx_end_psymtab): Use new.
10443
10444 2020-01-26 Tom Tromey <tom@tromey.com>
10445
10446 * psymtab.h (class psymtab_storage) <install_psymtab>: Rename from
10447 allocate_psymtab. Update documentation.
10448 * psymtab.c (psymtab_storage::install_psymtab): Rename from
10449 allocate_psymtab. Do not use new.
10450 (allocate_psymtab): Use new. Update.
10451
10452 2020-01-26 Tom Tromey <tom@tromey.com>
10453
10454 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
10455 * psymtab.c (psym_print_stats): Update.
10456 * psympriv.h (struct partial_symtab) <readin,
10457 psymtabs_addrmap_supported, anonymous>: Now bool.
10458 * mdebugread.c (psymtab_to_symtab_1): Update.
10459 * dwarf2read.c (create_type_unit_group, create_partial_symtab)
10460 (build_type_psymtabs_reader, psymtab_to_symtab_1)
10461 (process_full_comp_unit, process_full_type_unit): Update.
10462 * dbxread.c (dbx_psymtab_to_symtab_1): Update.
10463 * ctfread.c (psymtab_to_symtab): Update.
10464
10465 2020-01-26 Tom Tromey <tom@tromey.com>
10466
10467 * mdebugread.c (parse_partial_symbols): Use discard_psymtab.
10468 * psymtab.h (class psymtab_storage) <free_psymtabs>: Remove.
10469 * psymtab.c (psymtab_storage): Delete psymtabs.
10470 (psymtab_storage::allocate_psymtab): Use new.
10471 (psymtab_storage::discard_psymtab): Use delete.
10472 * psympriv.h (struct partial_symtab): Add constructor and
10473 initializers.
10474
10475 2020-01-26 Tom Tromey <tom@tromey.com>
10476
10477 * machoread.c: Do not include psympriv.h.
10478
10479 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10480
10481 * NEWS: Mention the new option and the set/show commands.
10482
10483 2020-01-25 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10484
10485 * exec.c (exec_file_mismatch_names, exec_file_mismatch_mode)
10486 (show_exec_file_mismatch_command, set_exec_file_mismatch_command)
10487 (validate_exec_file): New variables, enums, functions.
10488 (exec_file_locate_attach, print_section_info): Style the filenames.
10489 (_initialize_exec): Install show_exec_file_mismatch_command and
10490 set_exec_file_mismatch_command.
10491 * gdbcore.h (validate_exec_file): Declare.
10492 * infcmd.c (attach_command): Call validate_exec_file.
10493 * remote.c ( remote_target::remote_add_inferior): Likewise.
10494
10495 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10496
10497 * frame.c (find_frame_sal): Move call to get_next_frame into more
10498 inner scope.
10499 * inline-frame.c (inilne_state) <inline_state>: Update argument
10500 types.
10501 (inilne_state) <skipped_symbol>: Rename to...
10502 (inilne_state) <skipped_symbols>: ...this, and change to a vector.
10503 (skip_inline_frames): Build vector of skipped symbols and use this
10504 to reate the inline_state.
10505 (inline_skipped_symbol): Add a comment and some assertions, fetch
10506 skipped symbol from the list.
10507
10508 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10509
10510 * buildsym.c (lte_is_less_than): Delete.
10511 (buildsym_compunit::end_symtab_with_blockvector): Create local
10512 lambda function to sort line table entries, and use
10513 std::stable_sort instead of std::sort.
10514 * symtab.c (find_pc_sect_line): Skip backward over end of sequence
10515 markers when looking for a previous line.
10516
10517 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10518
10519 * dwarf2read.c (lnp_state_machine::record_line): Include
10520 end_sequence parameter in debug print out. Record the line if we
10521 are at an end_sequence marker even if it's not the start of a
10522 statement.
10523 * symmisc.c (maintenance_print_one_line_table): Print end of
10524 sequence markers with 'END' not '0'.
10525
10526 2020-01-24 Pedro Alves <palves@redhat.com>
10527
10528 PR gdb/25410
10529 * thread.c (scoped_restore_current_thread::restore): Use
10530 switch_to_inferior_no_thread.
10531 * exec.c: Include "progspace-and-thread.h".
10532 (add_target_sections, remove_target_sections):
10533 scoped_restore_current_pspace_and_thread instead of
10534 scoped_restore_current_thread.
10535 * infrun.c (handle_vfork_child_exec_or_exit): Assign the pspace
10536 and aspace to the inferior before calling clone_program_space.
10537 Remove stale comment.
10538
10539 2020-01-24 Christian Biesinger <cbiesinger@google.com>
10540
10541 * arm-nbsd-nat.c (arm_nbsd_nat_target::fetch_registers): Rename to...
10542 (arm_netbsd_nat_target::fetch_registers): ...this.
10543 (arm_nbsd_nat_target::store_registers): Rename to...
10544 (arm_netbsd_nat_target::store_registers): ...this.
10545
10546 2020-01-24 Christian Biesinger <cbiesinger@google.com>
10547
10548 * arm-nbsd-nat.c: Define _KERNTYPES to get the declaration of
10549 register_t.
10550
10551 2020-01-24 Christian Biesinger <cbiesinger@google.com>
10552
10553 * aarch64-fbsd-tdep.c (aarch64_fbsd_iterate_over_regset_sections):
10554 Update comment.
10555 * aarch64-linux-tdep.c (aarch64_linux_iterate_over_regset_sections):
10556 Likewise.
10557 * arm-fbsd-tdep.c (arm_fbsd_iterate_over_regset_sections): Likewise.
10558 * gdbcore.h (deprecated_add_core_fns): Update comment to point to
10559 the correct replacement (iterate_over_regset_sections).
10560 * riscv-fbsd-tdep.c (riscv_fbsd_iterate_over_regset_sections):
10561 Update comment.
10562
10563 2020-01-24 Graham Markall <graham.markall@embecosm.com>
10564
10565 PR gdb/23718
10566 * gdb/python/python.c (execute_gdb_command): Call
10567 async_enable_stdin in catch block.
10568
10569 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10570
10571 * event-loop.c (start_event_loop): Wrap async_enable_stdin with
10572 SWITCH_THRU_ALL_UIS.
10573
10574 2020-01-24 Andrew Burgess <andrew.burgess@embecosm.com>
10575
10576 PR tui/9765
10577 * minsyms.c (lookup_minimal_symbol_by_pc_section): Update header
10578 comment, add extra parameter, and update to store previous symbol
10579 when appropriate.
10580 * minsyms.h (lookup_minimal_symbol_by_pc_section): Update comment,
10581 add extra parameter.
10582 * tui/tui-disasm.c (tui_disassemble): Update header comment,
10583 remove unneeded parameter, add try/catch around gdb_print_insn,
10584 rewrite to add items to asm_lines vector.
10585 (tui_find_backward_disassembly_start_address): New function.
10586 (tui_find_disassembly_address): Updated throughout.
10587 (tui_disasm_window::set_contents): Update for changes to
10588 tui_disassemble.
10589 (tui_disasm_window::do_scroll_vertical): No need to adjust the
10590 number of lines to scroll.
10591
10592 2020-01-23 Simon Marchi <simon.marchi@polymtl.ca>
10593
10594 * objfiles.h (ALL_OBJFILE_OSECTIONS): Move up.
10595 (SECT_OFF_DATA): Likewise.
10596 (SECT_OFF_RODATA): Likewise.
10597 (SECT_OFF_TEXT): Likewise.
10598 (SECT_OFF_BSS): Likewise.
10599 (struct objfile) <text_section_offset, data_section_offset>: New
10600 methods.
10601 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Use
10602 objfile::text_section_offset.
10603 * coff-pe-read.c (add_pe_forwarded_sym): Likewise.
10604 * coffread.c (coff_symtab_read): Likewise.
10605 (enter_linenos): Likewise.
10606 (process_coff_symbol): Likewise.
10607 * ctfread.c (get_objfile_text_range): Likewise.
10608 * dtrace-probe.c (dtrace_probe::get_relocated_address):
10609 Use objfile::data_section_offset.
10610 * dwarf2-frame.c (execute_cfa_program): Use
10611 objfile::text_section_offset.
10612 (dwarf2_frame_find_fde): Likewise.
10613 * dwarf2read.c (create_addrmap_from_index): Likewise.
10614 (create_addrmap_from_aranges): Likewise.
10615 (dw2_find_pc_sect_compunit_symtab): Likewise.
10616 (process_psymtab_comp_unit_reader): Likewise.
10617 (add_partial_symbol): Likewise.
10618 (add_partial_subprogram): Likewise.
10619 (process_full_comp_unit): Likewise.
10620 (read_file_scope): Likewise.
10621 (read_func_scope): Likewise.
10622 (read_lexical_block_scope): Likewise.
10623 (read_call_site_scope): Likewise.
10624 (dwarf2_rnglists_process): Likewise.
10625 (dwarf2_ranges_process): Likewise.
10626 (dwarf2_ranges_read): Likewise.
10627 (dwarf_decode_lines_1): Likewise.
10628 (new_symbol): Likewise.
10629 (dwarf2_fetch_die_loc_sect_off): Likewise.
10630 (dwarf2_per_cu_text_offset): Likewise.
10631 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Likewise.
10632 * hppa-tdep.c (read_unwind_info): Likewise.
10633 * ia64-tdep.c (ia64_find_unwind_table): Likewise.
10634 * psympriv.h (struct partial_symtab): Likewise.
10635 * psymtab.c (find_pc_sect_psymtab): Likewise.
10636 * solib-svr4.c (enable_break): Likewise.
10637 * stap-probe.c (relocate_address): Use
10638 objfile::data_section_offset.
10639 * xcoffread.c (enter_line_range): Use
10640 objfile::text_section_offset.
10641 (read_xcoff_symtab): Likewise.
10642
10643 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
10644
10645 * darwin-nat.c (darwin_nat_target::wait_1): Move `inf`
10646 declaration to narrower scopes.
10647
10648 2020-01-23 Simon Marchi <simon.marchi@efficios.com>
10649
10650 * darwin-nat.h (struct darwin_exception_msg, enum
10651 darwin_msg_state, struct darwin_thread_info, darwin_thread_t):
10652 Move up.
10653 (class darwin_nat_target) <wait_1, check_new_threads,
10654 decode_exception_message, decode_message, stop_inferior,
10655 init_thread_list, ptrace_him, cancel_breakpoint>: Declare.
10656 * darwin-nat.c (darwin_check_new_threads): Rename to...
10657 (darwin_nat_target::check_new_threads): ... this.
10658 (darwin_suspend_inferior_it): Remove.
10659 (darwin_decode_exception_message): Rename to...
10660 (darwin_nat_target::decode_exception_message): ... this.
10661 (darwin_nat_target::resume): Pass target to find_inferior_ptid.
10662 (darwin_decode_message): Rename to...
10663 (darwin_nat_target::decode_message): ... this.
10664 (cancel_breakpoint): Rename to...
10665 (darwin_nat_target::cancel_breakpoint): ... this.
10666 (darwin_wait): Rename to...
10667 (darwin_nat_target::wait_1): ... this. Use range-based for loop
10668 instead of iterate_over_inferiors.
10669 (darwin_nat_target::wait): Call wait_1 instead of darwin_wait.
10670 (darwin_stop_inferior): Rename to...
10671 (darwin_nat_target::stop_inferior): ... this.
10672 (darwin_nat_target::kill): Call wait_1 instead of darwin_wait.
10673 (darwin_init_thread_list): Rename to...
10674 (darwin_nat_target::init_thread_list): ... this.
10675 (darwin_ptrace_him): Rename to...
10676 (darwin_nat_target::ptrace_him): ... this.
10677 (darwin_nat_target::create_inferior): Pass lambda function to
10678 fork_inferior.
10679 (darwin_nat_target::detach): Call stop_inferior instead of
10680 darwin_stop_inferior.
10681 * fork-inferior.h (fork_inferior): Change init_trace_fun
10682 parameter to gdb::function_view.
10683 * fork-inferior.c (fork_inferior): Likewise.
10684
10685 2020-01-23 Hannes Domani <ssbssa@yahoo.de>
10686
10687 * i386-cygwin-tdep.c (core_process_module_section): Update.
10688 * windows-nat.c (struct lm_info_windows): Add text_offset.
10689 (windows_xfer_shared_libraries): Update.
10690 * windows-tdep.c (windows_xfer_shared_library):
10691 Add text_offset_cached argument.
10692 * windows-tdep.h (windows_xfer_shared_library): Update.
10693
10694 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10695
10696 * gdbarch.sh: Add declaration for _initialize_gdbarch.
10697
10698 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10699
10700 * remote-sim.c (check_for_duplicate_sim_descriptor): Remove.
10701 (get_sim_inferior_data): Remove use of iterate_over_inferiors,
10702 replace with range-based for.
10703 (gdbsim_interrupt_inferior): Remove.
10704 (gdbsim_target::interrupt): Replace iterate_over_inferiors use
10705 with a range-based for. Inline code from
10706 gdbsim_interrupt_inferior.
10707
10708 2020-01-21 Simon Marchi <simon.marchi@efficios.com>
10709
10710 * infrun.c (proceed): Fix indentation.
10711
10712 2020-01-21 Tom Tromey <tromey@adacore.com>
10713
10714 * source-cache.c (source_cache::ensure): Call ext_lang_colorize.
10715 * python/python.c (python_extension_ops): Update.
10716 (gdbpy_colorize): New function.
10717 * python/lib/gdb/__init__.py (colorize): New function.
10718 * extension.h (ext_lang_colorize): Declare.
10719 * extension.c (ext_lang_colorize): New function.
10720 * extension-priv.h (struct extension_language_ops) <colorize>: New
10721 member.
10722 * cli/cli-style.c (_initialize_cli_style): Update help text.
10723
10724 2020-01-21 Luis Machado <luis.machado@linaro.org>
10725
10726 * aarch64-tdep.c (struct aarch64_displaced_step_closure)
10727 <cond>: Change type to bool.
10728 (aarch64_displaced_step_b_cond): Update cond to use bool type.
10729 (aarch64_displaced_step_cb): Likewise.
10730 (aarch64_displaced_step_tb): Likewise.
10731
10732 2020-01-21 Luis Machado <luis.machado@linaro.org>
10733
10734 * aarch64-tdep.c (aarch64_displaced_step_fixup): Add more debugging
10735 output.
10736
10737 2020-01-21 Luis Machado <luis.machado@linaro.org>
10738
10739 * aarch64-tdep.c (struct aarch64_displaced_step_closure )
10740 <pc_adjust>: Adjust the documentation.
10741 (aarch64_displaced_step_fixup): Check if PC really moved before
10742 adjusting it.
10743
10744 2020-01-19 Tom Tromey <tom@tromey.com>
10745
10746 * disasm.c (~gdb_disassembler): New destructor.
10747 (gdb_buffered_insn_length): Call disassemble_free_target.
10748 * disasm.h (class gdb_disassembler): Declare destructor. Use
10749 DISABLE_COPY_AND_ASSIGN.
10750
10751 2020-01-19 Tom Tromey <tom@tromey.com>
10752
10753 * dwarf2read.c (abbrev_table_up): Move typedef earlier.
10754 (die_reader_func_ftype): Remove.
10755 (cutu_reader): New class.
10756 (dw2_get_file_names_reader): Remove "data" parameter.
10757 (dw2_get_file_names): Use cutu_reader.
10758 (create_debug_type_hash_table): Update.
10759 (read_cutu_die_from_dwo): Update comment.
10760 (lookup_dwo_unit): Add dwo_name parameter.
10761 (cutu_reader::init_tu_and_read_dwo_dies): Now a method. Remove
10762 die_reader_func_ftype and data parameters.
10763 (cutu_reader::cutu_reader): Rename from init_cutu_and_read_dies.
10764 Remove die_reader_func_ftype and data parameters.
10765 (~cutu_reader): New; from init_cutu_and_read_dies.
10766 (cutu_reader::cutu_reader): Rename from
10767 init_cutu_and_read_dies_no_follow. Remove die_reader_func_ftype
10768 and data parameters.
10769 (init_cutu_and_read_dies_simple): Remove.
10770 (struct process_psymtab_comp_unit_data): Remove.
10771 (process_psymtab_comp_unit_reader): Remove data parameter; add
10772 want_partial_unit and pretend_language parameters.
10773 (process_psymtab_comp_unit): Use cutu_reader.
10774 (build_type_psymtabs_reader): Remove data parameter.
10775 (build_type_psymtabs_1): Use cutu_reader.
10776 (process_skeletonless_type_unit): Likewise.
10777 (load_partial_comp_unit_reader): Remove.
10778 (load_partial_comp_unit): Use cutu_reader.
10779 (load_full_comp_unit_reader): Remove.
10780 (load_full_comp_unit): Use cutu_reader.
10781 (struct create_dwo_cu_data): Remove.
10782 (create_dwo_cu_reader): Remove datap parameter; add dwo_file and
10783 dwo_unit parameters.
10784 (create_cus_hash_table): Use cutu_reader.
10785 (struct dwarf2_read_addr_index_data): Remove.
10786 (dwarf2_read_addr_index_reader): Remove.
10787 (dwarf2_read_addr_index): Use cutu_reader.
10788 (read_signatured_type_reader): Remove.
10789 (read_signatured_type): Use cutu_reader.
10790
10791 2020-01-19 Tom Tromey <tom@tromey.com>
10792
10793 * tui/tui.c (tui_show_assembly): Use tui_suppress_output.
10794 * tui/tui-wingeneral.h (class tui_suppress_output): New.
10795 (tui_wrefresh): Declare.
10796 * tui/tui-wingeneral.c (suppress_output): New global.
10797 (tui_suppress_output, ~tui_suppress_output): New constructor and
10798 destructor.
10799 (tui_wrefresh): New function.
10800 (tui_gen_win_info::refresh_window): Use tui_wrefresh.
10801 (tui_gen_win_info::make_window): Call wnoutrefresh when needed.
10802 * tui/tui-regs.h (struct tui_data_window) <no_refresh>: Declare
10803 method.
10804 * tui/tui-regs.c (tui_data_window::erase_data_content): Call
10805 tui_wrefresh.
10806 (tui_data_window::no_refresh): New method.
10807 (tui_data_item_window::refresh_window): Call tui_wrefresh.
10808 (tui_reg_command): Use tui_suppress_output
10809 * tui/tui-layout.c (tui_set_layout): Use tui_suppress_output.
10810 * tui/tui-data.h (struct tui_gen_win_info) <no_refresh>: New
10811 method.
10812 * tui/tui-command.c (tui_refresh_cmd_win): Call tui_wrefresh.
10813
10814 2020-01-19 Tom Tromey <tom@tromey.com>
10815
10816 * tui/tui-winsource.c (tui_update_source_windows_with_line):
10817 Handle case where symtab is null.
10818
10819 2020-01-19 Simon Marchi <simon.marchi@polymtl.ca>
10820
10821 * linux-fork.c (one_fork_p): Simplify.
10822
10823 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10824
10825 * top.c (struct qt_args): Remove.
10826 (kill_or_detach): Change return type to void, replace `void *`
10827 parameter with a proper one.
10828 (print_inferior_quit_action): Likewise.
10829 (quit_confirm): Use range-based for loop to iterate over inferiors.
10830 (quit_force): Likewise.
10831
10832 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10833
10834 * mi/mi-main.c (run_one_inferior): Change return type to void, replace
10835 `void *` parameter with proper parameters.
10836 (mi_cmd_exec_run): Use range-based loop to iterate over inferiors.
10837 (print_one_inferior): Change return type to void, replace `void *`
10838 parameter with proper parameters.
10839 (mi_cmd_list_thread_groups): Use range-based loop to iterate over
10840 inferiors.
10841 (get_other_inferior): Remove.
10842 (mi_cmd_remove_inferior): Use range-based loop to iterate over
10843 inferiors.
10844
10845 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10846
10847 * mi/mi-interp.c (report_initial_inferior): Remove.
10848 (mi_interp::init): Use range-based for to iterate over inferiors.
10849
10850 2020-01-17 Simon Marchi <simon.marchi@efficios.com>
10851
10852 * python/py-inferior.c (build_inferior_list): Remove.
10853 (gdbpy_ref): Use range-based for loop to iterate over inferiors.
10854
10855 2020-01-16 Christian Biesinger <cbiesinger@google.com>
10856
10857 * btrace.c (btrace_compute_ftrace_1): Fix spelling error (Unkown).
10858 (btrace_stitch_trace): Likewise.
10859 * charset.c (intermediate_encoding): Likewise (vaild).
10860 * nat/linux-btrace.c (linux_read_pt): Likewise (Unkown).
10861 * python/py-record-btrace.c (struct PyMethodDef): Likewise (occurences).
10862 * record-btrace.c (record_btrace_print_conf): Likewise (unkown).
10863
10864 2020-01-16 Hannes Domani <ssbssa@yahoo.de>
10865
10866 * windows-tdep.c (windows_get_tlb_type):
10867 Add rtl_user_process_parameters type.
10868
10869 2020-01-16 Pedro Alves <palves@redhat.com>
10870 Norbert Lange <nolange79@gmail.com>
10871
10872 PR build/24805
10873 * gdbsupport/gdb_proc_service.h (PS_EXPORT): New.
10874 (ps_get_thread_area, ps_getpid, ps_lcontinue, ps_lgetfpregs)
10875 (ps_lgetregs, ps_lsetfpregs, ps_lsetregs, ps_lstop, ps_pcontinue)
10876 (ps_pdread, ps_pdwrite, ps_pglobal_lookup, ps_pstop, ps_ptread)
10877 (ps_ptwrite, ps_lgetxregs, ps_lgetxregsize, ps_lsetxregs)
10878 (ps_plog): Redeclare exported functions with default visibility.
10879
10880 2020-01-16 Nitika Achra <Nitika.Achra@amd.com>
10881
10882 * dwarf2loc.c (decode_debug_loclists_addresses): Handle
10883 DW_LLE_base_addressx, DW_LLE_startx_length, DW_LLE_start_length.
10884
10885 2020-01-15 Simon Marchi <simon.marchi@efficios.com>
10886
10887 * infcmd.c (post_create_inferior): Use get_thread_regcache
10888 instead of get_current_regcache.
10889
10890 2020-01-14 Tom Tromey <tom@tromey.com>
10891
10892 PR symtab/12535:
10893 * python/python.c (gdbpy_decode_line): Treat empty string the same
10894 as no argument.
10895
10896 2020-01-14 Tom Tromey <tom@tromey.com>
10897
10898 * Makefile.in (CLIBS): Remove second use of $(LIBIBERTY).
10899
10900 2020-01-14 Tom Tromey <tom@tromey.com>
10901
10902 * nat/linux-btrace.c: Don't include <config.h>.
10903 * nat/linux-ptrace.c: Don't include <config.h>.
10904 * nat/x86-linux-dregs.c: Don't include <config.h>.
10905
10906 2020-01-14 Tom Tromey <tom@tromey.com>
10907
10908 * configure: Rebuild.
10909 * configure.ac: Move many checks to ../gdbsupport/common.m4.
10910
10911 2020-01-14 Tom Tromey <tom@tromey.com>
10912
10913 * nat/x86-linux-dregs.c: Include configh.h.
10914 * nat/linux-ptrace.c: Include configh.h.
10915 * nat/linux-btrace.c: Include configh.h.
10916 * defs.h: Include config.h, bfd.h.
10917 * configure.ac: Don't source common.host.
10918 (CONFIG_OBS, CONFIG_SRCS): Remove gdbsupport files.
10919 * configure: Rebuild.
10920 * acinclude.m4: Update path.
10921 * Makefile.in (SUPPORT, LIBSUPPORT, INCSUPPORT): New variables.
10922 (CONFIG_SRC_SUBDIR): Remove gdbsupport.
10923 (INTERNAL_CFLAGS_BASE): Add INCSUPPORT.
10924 (CLIBS): Add LIBSUPPORT.
10925 (CDEPS): Likewise.
10926 (COMMON_SFILES): Remove gdbsupport files.
10927 (HFILES_NO_SRCDIR): Likewise.
10928 (stamp-version): Update path to create-version.sh.
10929 (ALLDEPFILES): Remove gdbsupport files.
10930
10931 2020-01-14 Tom Tromey <tom@tromey.com>
10932
10933 * gdbsupport/common.m4 (GDB_AC_COMMON): Define WIN32APILIBS and
10934 USE_WIN32API when needed.
10935 * configure.ac (USE_WIN32API): Don't define.
10936 (WIN32LIBS): Use WIN32APILIBS.
10937 * configure: Rebuild.
10938
10939 2020-01-14 Tom Tromey <tom@tromey.com>
10940
10941 * configure: Rebuild.
10942 * gdbsupport/common.m4 (GDB_AC_COMMON): Fix indentation.
10943
10944 2020-01-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10945
10946 * skip.c (skip_function_command): Make skip w/o arguments use the
10947 name of the inlined function if pc is inside any inlined function.
10948
10949 2020-01-14 Luis Machado <luis.machado@linaro.org>
10950
10951 * inf-ptrace.c (inf_ptrace_target::resume): Update comments.
10952 * infrun.c (resume_1): Likewise.
10953 (handle_inferior_event): Remove stale comment.
10954 * linux-nat.c (linux_nat_target::resume): Update comments.
10955 (save_stop_reason): Likewise.
10956 (linux_nat_filter_event): Likewise.
10957 * linux-nat.h (struct lwp_info) <stop_pc>, <stop_reason>: Likewise.
10958
10959 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
10960
10961 * elfread.c (record_minimal_symbol): Set section index to 0 for
10962 non-allocatable sections.
10963
10964
10965 2020-01-13 Ali Tamur <tamur@google.com>
10966
10967 * dwarf2read.c (dwarf2_debug_sections): Add debug_str_offsets sections.
10968 (dwarf2_cu): Add str_offsets_base field. Change the type of addr_base
10969 to gdb::optional. Update comments.
10970 (dwo_file): Update comments.
10971 (read_attribute): Update API to take an additional out parameter,
10972 need_reprocess. This is used to mark attributes that need other
10973 attributes (e.g. str_offsets_base) for correct computation which may not
10974 have been read yet.
10975 (read_attribute_reprocess): New function declaration.
10976 (read_addr_index): Likewise.
10977 (read_dwo_str_index): Likewise.
10978 (read_stub_str_index): Likewise.
10979 (dwarf2_per_objfile::locate_sections): Handle debug_str_offsets section.
10980 (lookup_addr_base): New function definition.
10981 (lookup_ranges_base): Likewise.
10982 (read_cutu_die_from_dwo): Use the new functions: lookup_addr_base,
10983 lookup_ranges_base.
10984 (init_cutu_and_read_dies): Update comments.
10985 (init_cutu_and_read_dies_no_follow): Change API to take parent compile
10986 unit. This is used to inherit parent's str_offsets_base and addr_base.
10987 Update comments.
10988 (init_cutu_and_read_dies_simple): Reflect API changes.
10989 (skip_one_die): Reflect API changes. Handle DW_FORM_rnglistx.
10990 (create_cus_hash_table): Change API to take parent compile unit.
10991 Reflect API changes.
10992 (open_and_init_dwo_file): Reflect API changes.
10993 (dwarf2_get_pc_bounds): Update comments.
10994 (dwarf2_record_block_ranges): Likewise.
10995 (read_full_die_1): Change implementation to reprocess attributes that
10996 need str_offsets_base and addr_base.
10997 (partial_die_info::read): Likewise.
10998 (read_attribute_reprocess): New function definition.
10999 (read_attribute_value): Change API to take an additional out parameter,
11000 need_reprocess. Handle DW_FORM_rnglistx. No longer trigger an error
11001 when a non-dwo compile unit has index based attributes.
11002 (read_attribute): Reflect API changes.
11003 (read_addr_index_1): Reflect API changes. Update comments.
11004 (dwarf2_read_addr_index_data): Reflect API changes.
11005 (dwarf2_read_addr_index): Likewise.
11006 (read_str_index): Change API and implementation. This becomes a helper
11007 to be used by the new string index related methods. Update error
11008 message and comments.
11009 (read_dwo_str_index): New function definition.
11010 (read_stub_str_index): Likewise.
11011 * dwarf2read.h (dwarf2_per_objfile): Add str_offsets field.
11012 * symfile.h (dwarf2_debug_sections): Likewise.
11013 * xcoffread.c (dwarf2_debug_sections): Likewise.
11014
11015 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11016
11017 * gdbcore.h (struct core_fns) <core_read_registers>: Change
11018 core_reg_sect type to gdb_byte *.
11019 * arm-nbsd-nat.c (fetch_elfcore_registers): Likewise.
11020 * cris-tdep.c (fetch_core_registers): Likewise.
11021 * corelow.c (core_target::get_core_register_section): Change
11022 type of `contents` to gdb::byte_vector.
11023
11024 2020-01-13 Andrew Burgess <andrew.burgess@embecosm.com>
11025
11026 * tui/tui-wingeneral.c (box_win): Position the title in the center
11027 of the border.
11028
11029 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
11030
11031 * corelow.c (core_target::get_core_register_section): Use
11032 std::vector instead of alloca.
11033
11034 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11035
11036 * warning.m4: Add -Wmissing-declarations to build_warnings.
11037 * configure: Re-generate.
11038
11039 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11040
11041 * python/python.c (init__gdb_module): Add declaration.
11042
11043 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
11044
11045 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Add declaration.
11046 * aarch64-fbsd-tdep.c (_initialize_aarch64_fbsd_tdep): Add declaration.
11047 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Add declaration.
11048 * aarch64-linux-tdep.c (_initialize_aarch64_linux_tdep): Add declaration.
11049 * aarch64-newlib-tdep.c (_initialize_aarch64_newlib_tdep): Add declaration.
11050 * aarch64-tdep.c (_initialize_aarch64_tdep): Add declaration.
11051 * ada-exp.y (_initialize_ada_exp): Add declaration.
11052 * ada-lang.c (_initialize_ada_language): Add declaration.
11053 * ada-tasks.c (_initialize_tasks): Add declaration.
11054 * agent.c (_initialize_agent): Add declaration.
11055 * aix-thread.c (_initialize_aix_thread): Add declaration.
11056 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Add declaration.
11057 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Add declaration.
11058 * alpha-linux-tdep.c (_initialize_alpha_linux_tdep): Add declaration.
11059 * alpha-nbsd-tdep.c (_initialize_alphanbsd_tdep): Add declaration.
11060 * alpha-obsd-tdep.c (_initialize_alphaobsd_tdep): Add declaration.
11061 * alpha-tdep.c (_initialize_alpha_tdep): Add declaration.
11062 * amd64-darwin-tdep.c (_initialize_amd64_darwin_tdep): Add declaration.
11063 * amd64-dicos-tdep.c (_initialize_amd64_dicos_tdep): Add declaration.
11064 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Add declaration.
11065 * amd64-fbsd-tdep.c (_initialize_amd64fbsd_tdep): Add declaration.
11066 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Add declaration.
11067 * amd64-linux-tdep.c (_initialize_amd64_linux_tdep): Add declaration.
11068 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Add declaration.
11069 * amd64-nbsd-tdep.c (_initialize_amd64nbsd_tdep): Add declaration.
11070 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Add declaration.
11071 * amd64-obsd-tdep.c (_initialize_amd64obsd_tdep): Add declaration.
11072 * amd64-sol2-tdep.c (_initialize_amd64_sol2_tdep): Add declaration.
11073 * amd64-tdep.c (_initialize_amd64_tdep): Add declaration.
11074 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Add declaration.
11075 * amd64-windows-tdep.c (_initialize_amd64_windows_tdep): Add declaration.
11076 * annotate.c (_initialize_annotate): Add declaration.
11077 * arc-newlib-tdep.c (_initialize_arc_newlib_tdep): Add declaration.
11078 * arc-tdep.c (_initialize_arc_tdep): Add declaration.
11079 * arch-utils.c (_initialize_gdbarch_utils): Add declaration.
11080 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Add declaration.
11081 * arm-fbsd-tdep.c (_initialize_arm_fbsd_tdep): Add declaration.
11082 * arm-linux-nat.c (_initialize_arm_linux_nat): Add declaration.
11083 * arm-linux-tdep.c (_initialize_arm_linux_tdep): Add declaration.
11084 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Add declaration.
11085 * arm-nbsd-tdep.c (_initialize_arm_netbsd_tdep): Add declaration.
11086 * arm-obsd-tdep.c (_initialize_armobsd_tdep): Add declaration.
11087 * arm-pikeos-tdep.c (_initialize_arm_pikeos_tdep): Add declaration.
11088 * arm-symbian-tdep.c (_initialize_arm_symbian_tdep): Add declaration.
11089 * arm-tdep.c (_initialize_arm_tdep): Add declaration.
11090 * arm-wince-tdep.c (_initialize_arm_wince_tdep): Add declaration.
11091 * auto-load.c (_initialize_auto_load): Add declaration.
11092 * auxv.c (_initialize_auxv): Add declaration.
11093 * avr-tdep.c (_initialize_avr_tdep): Add declaration.
11094 * ax-gdb.c (_initialize_ax_gdb): Add declaration.
11095 * bfin-linux-tdep.c (_initialize_bfin_linux_tdep): Add declaration.
11096 * bfin-tdep.c (_initialize_bfin_tdep): Add declaration.
11097 * break-catch-sig.c (_initialize_break_catch_sig): Add declaration.
11098 * break-catch-syscall.c (_initialize_break_catch_syscall): Add declaration.
11099 * break-catch-throw.c (_initialize_break_catch_throw): Add declaration.
11100 * breakpoint.c (_initialize_breakpoint): Add declaration.
11101 * bsd-uthread.c (_initialize_bsd_uthread): Add declaration.
11102 * btrace.c (_initialize_btrace): Add declaration.
11103 * charset.c (_initialize_charset): Add declaration.
11104 * cli/cli-cmds.c (_initialize_cli_cmds): Add declaration.
11105 * cli/cli-dump.c (_initialize_cli_dump): Add declaration.
11106 * cli/cli-interp.c (_initialize_cli_interp): Add declaration.
11107 * cli/cli-logging.c (_initialize_cli_logging): Add declaration.
11108 * cli/cli-script.c (_initialize_cli_script): Add declaration.
11109 * cli/cli-style.c (_initialize_cli_style): Add declaration.
11110 * coff-pe-read.c (_initialize_coff_pe_read): Add declaration.
11111 * coffread.c (_initialize_coffread): Add declaration.
11112 * compile/compile-cplus-types.c (_initialize_compile_cplus_types): Add declaration.
11113 * compile/compile.c (_initialize_compile): Add declaration.
11114 * complaints.c (_initialize_complaints): Add declaration.
11115 * completer.c (_initialize_completer): Add declaration.
11116 * copying.c (_initialize_copying): Add declaration.
11117 * corefile.c (_initialize_core): Add declaration.
11118 * corelow.c (_initialize_corelow): Add declaration.
11119 * cp-abi.c (_initialize_cp_abi): Add declaration.
11120 * cp-namespace.c (_initialize_cp_namespace): Add declaration.
11121 * cp-support.c (_initialize_cp_support): Add declaration.
11122 * cp-valprint.c (_initialize_cp_valprint): Add declaration.
11123 * cris-linux-tdep.c (_initialize_cris_linux_tdep): Add declaration.
11124 * cris-tdep.c (_initialize_cris_tdep): Add declaration.
11125 * csky-linux-tdep.c (_initialize_csky_linux_tdep): Add declaration.
11126 * csky-tdep.c (_initialize_csky_tdep): Add declaration.
11127 * ctfread.c (_initialize_ctfread): Add declaration.
11128 * d-lang.c (_initialize_d_language): Add declaration.
11129 * darwin-nat-info.c (_initialize_darwin_info_commands): Add declaration.
11130 * darwin-nat.c (_initialize_darwin_nat): Add declaration.
11131 * dbxread.c (_initialize_dbxread): Add declaration.
11132 * dcache.c (_initialize_dcache): Add declaration.
11133 * disasm-selftests.c (_initialize_disasm_selftests): Add declaration.
11134 * disasm.c (_initialize_disasm): Add declaration.
11135 * dtrace-probe.c (_initialize_dtrace_probe): Add declaration.
11136 * dummy-frame.c (_initialize_dummy_frame): Add declaration.
11137 * dwarf-index-cache.c (_initialize_index_cache): Add declaration.
11138 * dwarf-index-write.c (_initialize_dwarf_index_write): Add declaration.
11139 * dwarf2-frame-tailcall.c (_initialize_tailcall_frame): Add declaration.
11140 * dwarf2-frame.c (_initialize_dwarf2_frame): Add declaration.
11141 * dwarf2expr.c (_initialize_dwarf2expr): Add declaration.
11142 * dwarf2loc.c (_initialize_dwarf2loc): Add declaration.
11143 * dwarf2read.c (_initialize_dwarf2_read): Add declaration.
11144 * elfread.c (_initialize_elfread): Add declaration.
11145 * exec.c (_initialize_exec): Add declaration.
11146 * extension.c (_initialize_extension): Add declaration.
11147 * f-lang.c (_initialize_f_language): Add declaration.
11148 * f-valprint.c (_initialize_f_valprint): Add declaration.
11149 * fbsd-nat.c (_initialize_fbsd_nat): Add declaration.
11150 * fbsd-tdep.c (_initialize_fbsd_tdep): Add declaration.
11151 * filesystem.c (_initialize_filesystem): Add declaration.
11152 * findcmd.c (_initialize_mem_search): Add declaration.
11153 * findvar.c (_initialize_findvar): Add declaration.
11154 * fork-child.c (_initialize_fork_child): Add declaration.
11155 * frame-base.c (_initialize_frame_base): Add declaration.
11156 * frame-unwind.c (_initialize_frame_unwind): Add declaration.
11157 * frame.c (_initialize_frame): Add declaration.
11158 * frv-linux-tdep.c (_initialize_frv_linux_tdep): Add declaration.
11159 * frv-tdep.c (_initialize_frv_tdep): Add declaration.
11160 * ft32-tdep.c (_initialize_ft32_tdep): Add declaration.
11161 * gcore.c (_initialize_gcore): Add declaration.
11162 * gdb-demangle.c (_initialize_gdb_demangle): Add declaration.
11163 * gdb_bfd.c (_initialize_gdb_bfd): Add declaration.
11164 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Add declaration.
11165 * gdbarch.c (_initialize_gdbarch): Add declaration.
11166 * gdbtypes.c (_initialize_gdbtypes): Add declaration.
11167 * gnu-nat.c (_initialize_gnu_nat): Add declaration.
11168 * gnu-v2-abi.c (_initialize_gnu_v2_abi): Add declaration.
11169 * gnu-v3-abi.c (_initialize_gnu_v3_abi): Add declaration.
11170 * go-lang.c (_initialize_go_language): Add declaration.
11171 * go32-nat.c (_initialize_go32_nat): Add declaration.
11172 * guile/guile.c (_initialize_guile): Add declaration.
11173 * h8300-tdep.c (_initialize_h8300_tdep): Add declaration.
11174 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Add declaration.
11175 * hppa-linux-tdep.c (_initialize_hppa_linux_tdep): Add declaration.
11176 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Add declaration.
11177 * hppa-nbsd-tdep.c (_initialize_hppanbsd_tdep): Add declaration.
11178 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Add declaration.
11179 * hppa-obsd-tdep.c (_initialize_hppabsd_tdep): Add declaration.
11180 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
11181 * i386-bsd-nat.c (_initialize_i386bsd_nat): Add declaration.
11182 * i386-cygwin-tdep.c (_initialize_i386_cygwin_tdep): Add declaration.
11183 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Add declaration.
11184 * i386-darwin-tdep.c (_initialize_i386_darwin_tdep): Add declaration.
11185 * i386-dicos-tdep.c (_initialize_i386_dicos_tdep): Add declaration.
11186 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Add declaration.
11187 * i386-fbsd-tdep.c (_initialize_i386fbsd_tdep): Add declaration.
11188 * i386-gnu-nat.c (_initialize_i386gnu_nat): Add declaration.
11189 * i386-gnu-tdep.c (_initialize_i386gnu_tdep): Add declaration.
11190 * i386-go32-tdep.c (_initialize_i386_go32_tdep): Add declaration.
11191 * i386-linux-nat.c (_initialize_i386_linux_nat): Add declaration.
11192 * i386-linux-tdep.c (_initialize_i386_linux_tdep): Add declaration.
11193 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Add declaration.
11194 * i386-nbsd-tdep.c (_initialize_i386nbsd_tdep): Add declaration.
11195 * i386-nto-tdep.c (_initialize_i386nto_tdep): Add declaration.
11196 * i386-obsd-nat.c (_initialize_i386obsd_nat): Add declaration.
11197 * i386-obsd-tdep.c (_initialize_i386obsd_tdep): Add declaration.
11198 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Add declaration.
11199 * i386-sol2-tdep.c (_initialize_i386_sol2_tdep): Add declaration.
11200 * i386-tdep.c (_initialize_i386_tdep): Add declaration.
11201 * i386-windows-nat.c (_initialize_i386_windows_nat): Add declaration.
11202 * ia64-libunwind-tdep.c (_initialize_libunwind_frame): Add declaration.
11203 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Add declaration.
11204 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Add declaration.
11205 * ia64-tdep.c (_initialize_ia64_tdep): Add declaration.
11206 * ia64-vms-tdep.c (_initialize_ia64_vms_tdep): Add declaration.
11207 * infcall.c (_initialize_infcall): Add declaration.
11208 * infcmd.c (_initialize_infcmd): Add declaration.
11209 * inflow.c (_initialize_inflow): Add declaration.
11210 * infrun.c (_initialize_infrun): Add declaration.
11211 * interps.c (_initialize_interpreter): Add declaration.
11212 * iq2000-tdep.c (_initialize_iq2000_tdep): Add declaration.
11213 * jit.c (_initialize_jit): Add declaration.
11214 * language.c (_initialize_language): Add declaration.
11215 * linux-fork.c (_initialize_linux_fork): Add declaration.
11216 * linux-nat.c (_initialize_linux_nat): Add declaration.
11217 * linux-tdep.c (_initialize_linux_tdep): Add declaration.
11218 * linux-thread-db.c (_initialize_thread_db): Add declaration.
11219 * lm32-tdep.c (_initialize_lm32_tdep): Add declaration.
11220 * m2-lang.c (_initialize_m2_language): Add declaration.
11221 * m32c-tdep.c (_initialize_m32c_tdep): Add declaration.
11222 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Add declaration.
11223 * m32r-linux-tdep.c (_initialize_m32r_linux_tdep): Add declaration.
11224 * m32r-tdep.c (_initialize_m32r_tdep): Add declaration.
11225 * m68hc11-tdep.c (_initialize_m68hc11_tdep): Add declaration.
11226 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Add declaration.
11227 * m68k-bsd-tdep.c (_initialize_m68kbsd_tdep): Add declaration.
11228 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Add declaration.
11229 * m68k-linux-tdep.c (_initialize_m68k_linux_tdep): Add declaration.
11230 * m68k-tdep.c (_initialize_m68k_tdep): Add declaration.
11231 * machoread.c (_initialize_machoread): Add declaration.
11232 * macrocmd.c (_initialize_macrocmd): Add declaration.
11233 * macroscope.c (_initialize_macroscope): Add declaration.
11234 * maint-test-options.c (_initialize_maint_test_options): Add declaration.
11235 * maint-test-settings.c (_initialize_maint_test_settings): Add declaration.
11236 * maint.c (_initialize_maint_cmds): Add declaration.
11237 * mdebugread.c (_initialize_mdebugread): Add declaration.
11238 * memattr.c (_initialize_mem): Add declaration.
11239 * mep-tdep.c (_initialize_mep_tdep): Add declaration.
11240 * mi/mi-cmd-env.c (_initialize_mi_cmd_env): Add declaration.
11241 * mi/mi-cmds.c (_initialize_mi_cmds): Add declaration.
11242 * mi/mi-interp.c (_initialize_mi_interp): Add declaration.
11243 * mi/mi-main.c (_initialize_mi_main): Add declaration.
11244 * microblaze-linux-tdep.c (_initialize_microblaze_linux_tdep): Add declaration.
11245 * microblaze-tdep.c (_initialize_microblaze_tdep): Add declaration.
11246 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Add declaration.
11247 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Add declaration.
11248 * mips-linux-nat.c (_initialize_mips_linux_nat): Add declaration.
11249 * mips-linux-tdep.c (_initialize_mips_linux_tdep): Add declaration.
11250 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Add declaration.
11251 * mips-nbsd-tdep.c (_initialize_mipsnbsd_tdep): Add declaration.
11252 * mips-sde-tdep.c (_initialize_mips_sde_tdep): Add declaration.
11253 * mips-tdep.c (_initialize_mips_tdep): Add declaration.
11254 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Add declaration.
11255 * mips64-obsd-tdep.c (_initialize_mips64obsd_tdep): Add declaration.
11256 * mipsread.c (_initialize_mipsread): Add declaration.
11257 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Add declaration.
11258 * mn10300-tdep.c (_initialize_mn10300_tdep): Add declaration.
11259 * moxie-tdep.c (_initialize_moxie_tdep): Add declaration.
11260 * msp430-tdep.c (_initialize_msp430_tdep): Add declaration.
11261 * nds32-tdep.c (_initialize_nds32_tdep): Add declaration.
11262 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Add declaration.
11263 * nios2-tdep.c (_initialize_nios2_tdep): Add declaration.
11264 * nto-procfs.c (_initialize_procfs): Add declaration.
11265 * objc-lang.c (_initialize_objc_language): Add declaration.
11266 * observable.c (_initialize_observer): Add declaration.
11267 * opencl-lang.c (_initialize_opencl_language): Add declaration.
11268 * or1k-linux-tdep.c (_initialize_or1k_linux_tdep): Add declaration.
11269 * or1k-tdep.c (_initialize_or1k_tdep): Add declaration.
11270 * osabi.c (_initialize_gdb_osabi): Add declaration.
11271 * osdata.c (_initialize_osdata): Add declaration.
11272 * p-valprint.c (_initialize_pascal_valprint): Add declaration.
11273 * parse.c (_initialize_parse): Add declaration.
11274 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Add declaration.
11275 * ppc-fbsd-tdep.c (_initialize_ppcfbsd_tdep): Add declaration.
11276 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Add declaration.
11277 * ppc-linux-tdep.c (_initialize_ppc_linux_tdep): Add declaration.
11278 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Add declaration.
11279 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Add declaration.
11280 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Add declaration.
11281 * ppc-obsd-tdep.c (_initialize_ppcobsd_tdep): Add declaration.
11282 * printcmd.c (_initialize_printcmd): Add declaration.
11283 * probe.c (_initialize_probe): Add declaration.
11284 * proc-api.c (_initialize_proc_api): Add declaration.
11285 * proc-events.c (_initialize_proc_events): Add declaration.
11286 * proc-service.c (_initialize_proc_service): Add declaration.
11287 * procfs.c (_initialize_procfs): Add declaration.
11288 * producer.c (_initialize_producer): Add declaration.
11289 * psymtab.c (_initialize_psymtab): Add declaration.
11290 * python/python.c (_initialize_python): Add declaration.
11291 * ravenscar-thread.c (_initialize_ravenscar): Add declaration.
11292 * record-btrace.c (_initialize_record_btrace): Add declaration.
11293 * record-full.c (_initialize_record_full): Add declaration.
11294 * record.c (_initialize_record): Add declaration.
11295 * regcache-dump.c (_initialize_regcache_dump): Add declaration.
11296 * regcache.c (_initialize_regcache): Add declaration.
11297 * reggroups.c (_initialize_reggroup): Add declaration.
11298 * remote-notif.c (_initialize_notif): Add declaration.
11299 * remote-sim.c (_initialize_remote_sim): Add declaration.
11300 * remote.c (_initialize_remote): Add declaration.
11301 * reverse.c (_initialize_reverse): Add declaration.
11302 * riscv-fbsd-nat.c (_initialize_riscv_fbsd_nat): Add declaration.
11303 * riscv-fbsd-tdep.c (_initialize_riscv_fbsd_tdep): Add declaration.
11304 * riscv-linux-nat.c (_initialize_riscv_linux_nat): Add declaration.
11305 * riscv-linux-tdep.c (_initialize_riscv_linux_tdep): Add declaration.
11306 * riscv-tdep.c (_initialize_riscv_tdep): Add declaration.
11307 * rl78-tdep.c (_initialize_rl78_tdep): Add declaration.
11308 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Add declaration.
11309 * rs6000-lynx178-tdep.c (_initialize_rs6000_lynx178_tdep):
11310 Add declaration.
11311 * rs6000-nat.c (_initialize_rs6000_nat): Add declaration.
11312 * rs6000-tdep.c (_initialize_rs6000_tdep): Add declaration.
11313 * run-on-main-thread.c (_initialize_run_on_main_thread): Add declaration.
11314 * rust-exp.y (_initialize_rust_exp): Add declaration.
11315 * rx-tdep.c (_initialize_rx_tdep): Add declaration.
11316 * s12z-tdep.c (_initialize_s12z_tdep): Add declaration.
11317 * s390-linux-nat.c (_initialize_s390_nat): Add declaration.
11318 * s390-linux-tdep.c (_initialize_s390_linux_tdep): Add declaration.
11319 * s390-tdep.c (_initialize_s390_tdep): Add declaration.
11320 * score-tdep.c (_initialize_score_tdep): Add declaration.
11321 * ser-go32.c (_initialize_ser_dos): Add declaration.
11322 * ser-mingw.c (_initialize_ser_windows): Add declaration.
11323 * ser-pipe.c (_initialize_ser_pipe): Add declaration.
11324 * ser-tcp.c (_initialize_ser_tcp): Add declaration.
11325 * ser-uds.c (_initialize_ser_socket): Add declaration.
11326 * ser-unix.c (_initialize_ser_hardwire): Add declaration.
11327 * serial.c (_initialize_serial): Add declaration.
11328 * sh-linux-tdep.c (_initialize_sh_linux_tdep): Add declaration.
11329 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Add declaration.
11330 * sh-nbsd-tdep.c (_initialize_shnbsd_tdep): Add declaration.
11331 * sh-tdep.c (_initialize_sh_tdep): Add declaration.
11332 * skip.c (_initialize_step_skip): Add declaration.
11333 * sol-thread.c (_initialize_sol_thread): Add declaration.
11334 * solib-aix.c (_initialize_solib_aix): Add declaration.
11335 * solib-darwin.c (_initialize_darwin_solib): Add declaration.
11336 * solib-dsbt.c (_initialize_dsbt_solib): Add declaration.
11337 * solib-frv.c (_initialize_frv_solib): Add declaration.
11338 * solib-svr4.c (_initialize_svr4_solib): Add declaration.
11339 * solib-target.c (_initialize_solib_target): Add declaration.
11340 * solib.c (_initialize_solib): Add declaration.
11341 * source-cache.c (_initialize_source_cache): Add declaration.
11342 * source.c (_initialize_source): Add declaration.
11343 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Add declaration.
11344 * sparc-linux-tdep.c (_initialize_sparc_linux_tdep): Add declaration.
11345 * sparc-nat.c (_initialize_sparc_nat): Add declaration.
11346 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Add declaration.
11347 * sparc-nbsd-tdep.c (_initialize_sparcnbsd_tdep): Add declaration.
11348 * sparc-obsd-tdep.c (_initialize_sparc32obsd_tdep): Add declaration.
11349 * sparc-sol2-tdep.c (_initialize_sparc_sol2_tdep): Add declaration.
11350 * sparc-tdep.c (_initialize_sparc_tdep): Add declaration.
11351 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Add declaration.
11352 * sparc64-fbsd-tdep.c (_initialize_sparc64fbsd_tdep): Add declaration.
11353 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Add declaration.
11354 * sparc64-linux-tdep.c (_initialize_sparc64_linux_tdep): Add declaration.
11355 * sparc64-nat.c (_initialize_sparc64_nat): Add declaration.
11356 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Add declaration.
11357 * sparc64-nbsd-tdep.c (_initialize_sparc64nbsd_tdep): Add declaration.
11358 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Add declaration.
11359 * sparc64-obsd-tdep.c (_initialize_sparc64obsd_tdep): Add declaration.
11360 * sparc64-sol2-tdep.c (_initialize_sparc64_sol2_tdep): Add declaration.
11361 * sparc64-tdep.c (_initialize_sparc64_adi_tdep): Add declaration.
11362 * stabsread.c (_initialize_stabsread): Add declaration.
11363 * stack.c (_initialize_stack): Add declaration.
11364 * stap-probe.c (_initialize_stap_probe): Add declaration.
11365 * std-regs.c (_initialize_frame_reg): Add declaration.
11366 * symfile-debug.c (_initialize_symfile_debug): Add declaration.
11367 * symfile-mem.c (_initialize_symfile_mem): Add declaration.
11368 * symfile.c (_initialize_symfile): Add declaration.
11369 * symmisc.c (_initialize_symmisc): Add declaration.
11370 * symtab.c (_initialize_symtab): Add declaration.
11371 * target.c (_initialize_target): Add declaration.
11372 * target-connection.c (_initialize_target_connection): Add
11373 declaration.
11374 * target-dcache.c (_initialize_target_dcache): Add declaration.
11375 * target-descriptions.c (_initialize_target_descriptions): Add declaration.
11376 * thread.c (_initialize_thread): Add declaration.
11377 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Add declaration.
11378 * tic6x-tdep.c (_initialize_tic6x_tdep): Add declaration.
11379 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Add declaration.
11380 * tilegx-linux-tdep.c (_initialize_tilegx_linux_tdep): Add declaration.
11381 * tilegx-tdep.c (_initialize_tilegx_tdep): Add declaration.
11382 * tracectf.c (_initialize_ctf): Add declaration.
11383 * tracefile-tfile.c (_initialize_tracefile_tfile): Add declaration.
11384 * tracefile.c (_initialize_tracefile): Add declaration.
11385 * tracepoint.c (_initialize_tracepoint): Add declaration.
11386 * tui/tui-hooks.c (_initialize_tui_hooks): Add declaration.
11387 * tui/tui-interp.c (_initialize_tui_interp): Add declaration.
11388 * tui/tui-layout.c (_initialize_tui_layout): Add declaration.
11389 * tui/tui-regs.c (_initialize_tui_regs): Add declaration.
11390 * tui/tui-stack.c (_initialize_tui_stack): Add declaration.
11391 * tui/tui-win.c (_initialize_tui_win): Add declaration.
11392 * tui/tui.c (_initialize_tui): Add declaration.
11393 * typeprint.c (_initialize_typeprint): Add declaration.
11394 * ui-style.c (_initialize_ui_style): Add declaration.
11395 * unittests/array-view-selftests.c (_initialize_array_view_selftests): Add declaration.
11396 * unittests/child-path-selftests.c (_initialize_child_path_selftests): Add declaration.
11397 * unittests/cli-utils-selftests.c (_initialize_cli_utils_selftests): Add declaration.
11398 * unittests/common-utils-selftests.c (_initialize_common_utils_selftests): Add declaration.
11399 * unittests/copy_bitwise-selftests.c (_initialize_copy_bitwise_utils_selftests): Add declaration.
11400 * unittests/environ-selftests.c (_initialize_environ_selftests): Add declaration.
11401 * unittests/filtered_iterator-selftests.c
11402 (_initialize_filtered_iterator_selftests): Add declaration.
11403 * unittests/format_pieces-selftests.c (_initialize_format_pieces_selftests): Add declaration.
11404 * unittests/function-view-selftests.c (_initialize_function_view_selftests): Add declaration.
11405 * unittests/help-doc-selftests.c (_initialize_help_doc_selftests): Add declaration.
11406 * unittests/lookup_name_info-selftests.c (_initialize_lookup_name_info_selftests): Add declaration.
11407 * unittests/main-thread-selftests.c
11408 (_initialize_main_thread_selftests): Add declaration.
11409 * unittests/memory-map-selftests.c (_initialize_memory_map_selftests): Add declaration.
11410 * unittests/memrange-selftests.c (_initialize_memrange_selftests): Add declaration.
11411 * unittests/mkdir-recursive-selftests.c (_initialize_mkdir_recursive_selftests): Add declaration.
11412 * unittests/observable-selftests.c (_initialize_observer_selftest): Add declaration.
11413 * unittests/offset-type-selftests.c (_initialize_offset_type_selftests): Add declaration.
11414 * unittests/optional-selftests.c (_initialize_optional_selftests): Add declaration.
11415 * unittests/parse-connection-spec-selftests.c (_initialize_parse_connection_spec_selftests): Add declaration.
11416 * unittests/rsp-low-selftests.c (_initialize_rsp_low_selftests): Add declaration.
11417 * unittests/scoped_fd-selftests.c (_initialize_scoped_fd_selftests): Add declaration.
11418 * unittests/scoped_mmap-selftests.c (_initialize_scoped_mmap_selftests): Add declaration.
11419 * unittests/scoped_restore-selftests.c (_initialize_scoped_restore_selftests): Add declaration.
11420 * unittests/string_view-selftests.c (_initialize_string_view_selftests): Add declaration.
11421 * unittests/style-selftests.c (_initialize_style_selftest): Add declaration.
11422 * unittests/tracepoint-selftests.c (_initialize_tracepoint_selftests): Add declaration.
11423 * unittests/tui-selftests.c (_initialize_tui_selftest): Add
11424 declaration.
11425 * unittests/unpack-selftests.c (_initialize_unpack_selftests): Add declaration.
11426 * unittests/utils-selftests.c (_initialize_utils_selftests): Add declaration.
11427 * unittests/vec-utils-selftests.c (_initialize_vec_utils_selftests): Add declaration.
11428 * unittests/xml-utils-selftests.c (_initialize_xml_utils): Add declaration.
11429 * user-regs.c (_initialize_user_regs): Add declaration.
11430 * utils.c (_initialize_utils): Add declaration.
11431 * v850-tdep.c (_initialize_v850_tdep): Add declaration.
11432 * valops.c (_initialize_valops): Add declaration.
11433 * valprint.c (_initialize_valprint): Add declaration.
11434 * value.c (_initialize_values): Add declaration.
11435 * varobj.c (_initialize_varobj): Add declaration.
11436 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Add declaration.
11437 * vax-nbsd-tdep.c (_initialize_vaxnbsd_tdep): Add declaration.
11438 * vax-tdep.c (_initialize_vax_tdep): Add declaration.
11439 * windows-nat.c (_initialize_windows_nat): Add declaration.
11440 (_initialize_check_for_gdb_ini): Add declaration.
11441 (_initialize_loadable): Add declaration.
11442 * windows-tdep.c (_initialize_windows_tdep): Add declaration.
11443 * x86-bsd-nat.c (_initialize_x86_bsd_nat): Add declaration.
11444 * x86-linux-nat.c (_initialize_x86_linux_nat): Add declaration.
11445 * xcoffread.c (_initialize_xcoffread): Add declaration.
11446 * xml-support.c (_initialize_xml_support): Add declaration.
11447 * xstormy16-tdep.c (_initialize_xstormy16_tdep): Add declaration.
11448 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Add declaration.
11449 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Add declaration.
11450 * xtensa-tdep.c (_initialize_xtensa_tdep): Add declaration.
11451
11452 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
11453
11454 * regformats/regdat.sh: Generate declaration for init function.
11455
11456 2020-01-13 Simon Marchi <simon.marchi@polymtl.ca>
11457
11458 * remote-sim.c (next_pid, INITIAL_PID, sim_inferior_data): Move
11459 up.
11460 (gdbsim_target) <get_inferior_data_by_ptid, resume_one_inferior,
11461 close_one_inferior>: New methods.
11462 (get_sim_inferior_data_by_ptid): Move to gdbsim_target,
11463 pass down target to find_inferior_pid.
11464 (gdbsim_target::fetch_registers, gdbsim_target::store_registers):
11465 Pass down target to find_inferior_ptid.
11466 (gdbsim_target::create_inferior): Pass down target to
11467 add_thread_silent.
11468 (gdbsim_close_inferior): Move to gdbsim_close_inferior, pass
11469 target down to find_inferior_ptid and switch_to_thread.
11470 (gdbsim_target::close): Update to call close_one_inferior.
11471 (struct resume_data): Remove.
11472 (gdbsim_resume_inferior): Move to gdbsim_target. Take arguments
11473 directly, rather than through a void pointer.
11474 (gdbsim_target::resume): Update to call resume_one_inferior.
11475
11476 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
11477
11478 * gdbsupport/gdb_wait.c: Include gdb_wait.h.
11479
11480 2020-01-12 Pedro Alves <palves@redhat.com>
11481
11482 * bsd-kvm.c (bsd_kvm_target::close): Call exit_inferior_silent
11483 directly for the current inferior instead of
11484 discard_all_inferiors.
11485 (discard_all_inferiors): Delete.
11486
11487 2020-01-11 Tom Tromey <tom@tromey.com>
11488
11489 * tui/tui-wingeneral.c (box_win): Check cli_styling.
11490 * tui/tui-winsource.c (tui_source_window_base::refill): Use
11491 deprecated_safe_get_selected_frame.
11492
11493 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
11494
11495 * inferior.c (print_inferior): Switch inferior before printing it.
11496
11497 2020-01-10 Aleksandar Paunovic <aleksandar.paunovic@intel.com>
11498 Pedro Alves <palves@redhat.com>
11499
11500 * progspace-and-thread.c (switch_to_program_space_and_thread):
11501 Assert there's an inferior for PSPACE. Use
11502 switch_to_inferior_no_thread to switch the inferior too.
11503 * progspace.c (program_space::~program_space): Call
11504 clear_symtab_users here, with SYMFILE_DEFER_BP_RESET.
11505 (program_space::free_all_objfiles): Don't call clear_symtab_users
11506 here.
11507 * symfile.c (symbol_file_clear): Call clear_symtab_users here.
11508
11509 2020-01-10 Pedro Alves <palves@redhat.com>
11510
11511 * NEWS: Mention multi-target debugging, "info connections", and
11512 "add-inferior -no-connection".
11513
11514 2020-01-10 Pedro Alves <palves@redhat.com>
11515
11516 * infrun.c: Include "target-connection.h".
11517 (check_multi_target_resumption): New.
11518 (proceed): Call it.
11519 * target-connection.c (make_target_connection_string): Make
11520 extern.
11521 * target-connection.h (make_target_connection_string): Declare.
11522
11523 2020-01-10 Pedro Alves <palves@redhat.com>
11524
11525 * Makefile.in (COMMON_SFILES): Add target-connection.c.
11526 * inferior.c (uiout_field_connection): New function.
11527 (print_inferior): Add new "connection-id" column.
11528 (add_inferior_command): Show connection number/string of added
11529 inferior.
11530 * process-stratum-target.h
11531 (process_stratum_target::connection_string): New virtual method.
11532 (process_stratum_target::connection_number): New field.
11533 * remote.c (remote_target::connection_string): New override.
11534 * target-connection.c: New file.
11535 * target-connection.h: New file.
11536 * target.c (decref_target): Remove process_stratum targets from
11537 the connection list.
11538 (target_stack::push): Add process_stratum targets to the
11539 connection list.
11540
11541 2020-01-10 Pedro Alves <palves@redhat.com>
11542
11543 Revert:
11544 2016-04-12 Pedro Alves <palves@redhat.com>
11545 * serial.c (serial_open, serial_fdopen_ops, do_serial_close):
11546 Remove references to name.
11547 * serial.h (struct serial) <name>: Delete.
11548
11549 2020-01-10 Pedro Alves <palves@redhat.com>
11550
11551 * gdbarch-selftests.c (register_to_value_test): Remove "target
11552 already pushed" check.
11553
11554 2020-01-10 Pedro Alves <palves@redhat.com>
11555 John Baldwin <jhb@FreeBSD.org>
11556
11557 * aarch64-linux-nat.c
11558 (aarch64_linux_nat_target::thread_architecture): Adjust.
11559 * ada-tasks.c (print_ada_task_info): Adjust find_thread_ptid call.
11560 (task_command_1): Likewise.
11561 * aix-thread.c (sync_threadlists, aix_thread_target::resume)
11562 (aix_thread_target::wait, aix_thread_target::fetch_registers)
11563 (aix_thread_target::store_registers)
11564 (aix_thread_target::thread_alive): Adjust.
11565 * amd64-fbsd-tdep.c: Include "inferior.h".
11566 (amd64fbsd_get_thread_local_address): Pass down target.
11567 * amd64-linux-nat.c (ps_get_thread_area): Use ps_prochandle
11568 thread's gdbarch instead of target_gdbarch.
11569 * break-catch-sig.c (signal_catchpoint_print_it): Adjust call to
11570 get_last_target_status.
11571 * break-catch-syscall.c (print_it_catch_syscall): Likewise.
11572 * breakpoint.c (breakpoints_should_be_inserted_now): Consider all
11573 inferiors.
11574 (update_inserted_breakpoint_locations): Skip if inferiors with no
11575 execution.
11576 (update_global_location_list): When handling moribund locations,
11577 find representative inferior for location's pspace, and use thread
11578 count of its process_stratum target.
11579 * bsd-kvm.c (bsd_kvm_target_open): Pass target down.
11580 * bsd-uthread.c (bsd_uthread_target::wait): Use
11581 as_process_stratum_target and adjust thread_change_ptid and
11582 add_thread calls.
11583 (bsd_uthread_target::update_thread_list): Use
11584 as_process_stratum_target and adjust find_thread_ptid,
11585 thread_change_ptid and add_thread calls.
11586 * btrace.c (maint_btrace_packet_history_cmd): Adjust
11587 find_thread_ptid call.
11588 * corelow.c (add_to_thread_list): Adjust add_thread call.
11589 (core_target_open): Adjust add_thread_silent and thread_count
11590 calls.
11591 (core_target::pid_to_str): Adjust find_inferior_ptid call.
11592 * ctf.c (ctf_target_open): Adjust add_thread_silent call.
11593 * event-top.c (async_disconnect): Pop targets from all inferiors.
11594 * exec.c (add_target_sections): Push exec target on all inferiors
11595 sharing the program space.
11596 (remove_target_sections): Remove the exec target from all
11597 inferiors sharing the program space.
11598 (exec_on_vfork): New.
11599 * exec.h (exec_on_vfork): Declare.
11600 * fbsd-nat.c (fbsd_add_threads): Add fbsd_nat_target parameter.
11601 Pass it down.
11602 (fbsd_nat_target::update_thread_list): Adjust.
11603 (fbsd_nat_target::resume): Adjust.
11604 (fbsd_handle_debug_trap): Add fbsd_nat_target parameter. Pass it
11605 down.
11606 (fbsd_nat_target::wait, fbsd_nat_target::post_attach): Adjust.
11607 * fbsd-tdep.c (fbsd_corefile_thread): Adjust
11608 get_thread_arch_regcache call.
11609 * fork-child.c (gdb_startup_inferior): Pass target down to
11610 startup_inferior and set_executing.
11611 * gdbthread.h (struct process_stratum_target): Forward declare.
11612 (add_thread, add_thread_silent, add_thread_with_info)
11613 (in_thread_list): Add process_stratum_target parameter.
11614 (find_thread_ptid(inferior*, ptid_t)): New overload.
11615 (find_thread_ptid, thread_change_ptid): Add process_stratum_target
11616 parameter.
11617 (all_threads()): Delete overload.
11618 (all_threads, all_non_exited_threads): Add process_stratum_target
11619 parameter.
11620 (all_threads_safe): Use brace initialization.
11621 (thread_count): Add process_stratum_target parameter.
11622 (set_resumed, set_running, set_stop_requested, set_executing)
11623 (threads_are_executing, finish_thread_state): Add
11624 process_stratum_target parameter.
11625 (switch_to_thread): Use is_current_thread.
11626 * i386-fbsd-tdep.c: Include "inferior.h".
11627 (i386fbsd_get_thread_local_address): Pass down target.
11628 * i386-linux-nat.c (i386_linux_nat_target::low_resume): Adjust.
11629 * inf-child.c (inf_child_target::maybe_unpush_target): Remove
11630 have_inferiors check.
11631 * inf-ptrace.c (inf_ptrace_target::create_inferior)
11632 (inf_ptrace_target::attach): Adjust.
11633 * infcall.c (run_inferior_call): Adjust.
11634 * infcmd.c (run_command_1): Pass target to
11635 scoped_finish_thread_state.
11636 (proceed_thread_callback): Skip inferiors with no execution.
11637 (continue_command): Rename 'all_threads' local to avoid hiding
11638 'all_threads' function. Adjust get_last_target_status call.
11639 (prepare_one_step): Adjust set_running call.
11640 (signal_command): Use user_visible_resume_target. Compare thread
11641 pointers instead of inferior_ptid.
11642 (info_program_command): Adjust to pass down target.
11643 (attach_command): Mark target's 'thread_executing' flag.
11644 (stop_current_target_threads_ns): New, factored out from ...
11645 (interrupt_target_1): ... this. Switch inferior before making
11646 target calls.
11647 * inferior-iter.h
11648 (struct all_inferiors_iterator, struct all_inferiors_range)
11649 (struct all_inferiors_safe_range)
11650 (struct all_non_exited_inferiors_range): Filter on
11651 process_stratum_target too. Remove explicit.
11652 * inferior.c (inferior::inferior): Push dummy target on target
11653 stack.
11654 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors):
11655 Add process_stratum_target parameter, and pass it down.
11656 (have_live_inferiors): Adjust.
11657 (switch_to_inferior_and_push_target): New.
11658 (add_inferior_command, clone_inferior_command): Handle
11659 "-no-connection" parameter. Use
11660 switch_to_inferior_and_push_target.
11661 (_initialize_inferior): Mention "-no-connection" option in
11662 the help of "add-inferior" and "clone-inferior" commands.
11663 * inferior.h: Include "process-stratum-target.h".
11664 (interrupt_target_1): Use bool.
11665 (struct inferior) <push_target, unpush_target, target_is_pushed,
11666 find_target_beneath, top_target, process_target, target_at,
11667 m_stack>: New.
11668 (discard_all_inferiors): Delete.
11669 (find_inferior_pid, find_inferior_ptid, number_of_live_inferiors)
11670 (all_inferiors, all_non_exited_inferiors): Add
11671 process_stratum_target parameter.
11672 * infrun.c: Include "gdb_select.h" and <unordered_map>.
11673 (target_last_proc_target): New global.
11674 (follow_fork_inferior): Push target on new inferior. Pass target
11675 to add_thread_silent. Call exec_on_vfork. Handle target's
11676 reference count.
11677 (follow_fork): Adjust get_last_target_status call. Also consider
11678 target.
11679 (follow_exec): Push target on new inferior.
11680 (struct execution_control_state) <target>: New field.
11681 (user_visible_resume_target): New.
11682 (do_target_resume): Call target_async.
11683 (resume_1): Set target's threads_executing flag. Consider resume
11684 target.
11685 (commit_resume_all_targets): New.
11686 (proceed): Also consider resume target. Skip threads of inferiors
11687 with no execution. Commit resumtion in all targets.
11688 (start_remote): Pass current inferior to wait_for_inferior.
11689 (infrun_thread_stop_requested): Consider target as well. Pass
11690 thread_info pointer to clear_inline_frame_state instead of ptid.
11691 (infrun_thread_thread_exit): Consider target as well.
11692 (random_pending_event_thread): New inferior parameter. Use it.
11693 (do_target_wait): Rename to ...
11694 (do_target_wait_1): ... this. Add inferior parameter, and pass it
11695 down.
11696 (threads_are_resumed_pending_p, do_target_wait): New.
11697 (prepare_for_detach): Adjust calls.
11698 (wait_for_inferior): New inferior parameter. Handle it. Use
11699 do_target_wait_1 instead of do_target_wait.
11700 (fetch_inferior_event): Adjust. Switch to representative
11701 inferior. Pass target down.
11702 (set_last_target_status): Add process_stratum_target parameter.
11703 Save target in global.
11704 (get_last_target_status): Add process_stratum_target parameter and
11705 handle it.
11706 (nullify_last_target_wait_ptid): Clear 'target_last_proc_target'.
11707 (context_switch): Check inferior_ptid == null_ptid before calling
11708 inferior_thread().
11709 (get_inferior_stop_soon): Pass down target.
11710 (wait_one): Rename to ...
11711 (poll_one_curr_target): ... this.
11712 (struct wait_one_event): New.
11713 (wait_one): New.
11714 (stop_all_threads): Adjust.
11715 (handle_no_resumed, handle_inferior_event): Adjust to consider the
11716 event's target.
11717 (switch_back_to_stepped_thread): Also consider target.
11718 (print_stop_event): Update.
11719 (normal_stop): Update. Also consider the resume target.
11720 * infrun.h (wait_for_inferior): Remove declaration.
11721 (user_visible_resume_target): New declaration.
11722 (get_last_target_status, set_last_target_status): New
11723 process_stratum_target parameter.
11724 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
11725 process_stratum_target parameter, and use it.
11726 (clear_inline_frame_state (thread_info*)): New.
11727 * inline-frame.c (clear_inline_frame_state(ptid_t)): Add
11728 process_stratum_target parameter.
11729 (clear_inline_frame_state (thread_info*)): Declare.
11730 * linux-fork.c (delete_checkpoint_command): Pass target down to
11731 find_thread_ptid.
11732 (checkpoint_command): Adjust.
11733 * linux-nat.c (linux_nat_target::follow_fork): Switch to thread
11734 instead of just tweaking inferior_ptid.
11735 (linux_nat_switch_fork): Pass target down to thread_change_ptid.
11736 (exit_lwp): Pass target down to find_thread_ptid.
11737 (attach_proc_task_lwp_callback): Pass target down to
11738 add_thread/set_running/set_executing.
11739 (linux_nat_target::attach): Pass target down to
11740 thread_change_ptid.
11741 (get_detach_signal): Pass target down to find_thread_ptid.
11742 Consider last target status's target.
11743 (linux_resume_one_lwp_throw, resume_lwp)
11744 (linux_handle_syscall_trap, linux_handle_extended_wait, wait_lwp)
11745 (stop_wait_callback, save_stop_reason, linux_nat_filter_event)
11746 (linux_nat_wait_1, resume_stopped_resumed_lwps): Pass target down.
11747 (linux_nat_target::async_wait_fd): New.
11748 (linux_nat_stop_lwp, linux_nat_target::thread_address_space): Pass
11749 target down.
11750 * linux-nat.h (linux_nat_target::async_wait_fd): Declare.
11751 * linux-tdep.c (get_thread_arch_regcache): Pass target down.
11752 * linux-thread-db.c (struct thread_db_info::process_target): New
11753 field.
11754 (add_thread_db_info): Save target.
11755 (get_thread_db_info): New process_stratum_target parameter. Also
11756 match target.
11757 (delete_thread_db_info): New process_stratum_target parameter.
11758 Also match target.
11759 (thread_from_lwp): Adjust to pass down target.
11760 (thread_db_notice_clone): Pass down target.
11761 (check_thread_db_callback): Pass down target.
11762 (try_thread_db_load_1): Always push the thread_db target.
11763 (try_thread_db_load, record_thread): Pass target down.
11764 (thread_db_target::detach): Pass target down. Always unpush the
11765 thread_db target.
11766 (thread_db_target::wait, thread_db_target::mourn_inferior): Pass
11767 target down. Always unpush the thread_db target.
11768 (find_new_threads_callback, thread_db_find_new_threads_2)
11769 (thread_db_target::update_thread_list): Pass target down.
11770 (thread_db_target::pid_to_str): Pass current inferior down.
11771 (thread_db_target::get_thread_local_address): Pass target down.
11772 (thread_db_target::resume, maintenance_check_libthread_db): Pass
11773 target down.
11774 * nto-procfs.c (nto_procfs_target::update_thread_list): Adjust.
11775 * procfs.c (procfs_target::procfs_init_inferior): Declare.
11776 (proc_set_current_signal, do_attach, procfs_target::wait): Adjust.
11777 (procfs_init_inferior): Rename to ...
11778 (procfs_target::procfs_init_inferior): ... this and adjust.
11779 (procfs_target::create_inferior, procfs_notice_thread)
11780 (procfs_do_thread_registers): Adjust.
11781 * ppc-fbsd-tdep.c: Include "inferior.h".
11782 (ppcfbsd_get_thread_local_address): Pass down target.
11783 * proc-service.c (ps_xfer_memory): Switch current inferior and
11784 program space as well.
11785 (get_ps_regcache): Pass target down.
11786 * process-stratum-target.c
11787 (process_stratum_target::thread_address_space)
11788 (process_stratum_target::thread_architecture): Pass target down.
11789 * process-stratum-target.h
11790 (process_stratum_target::threads_executing): New field.
11791 (as_process_stratum_target): New.
11792 * ravenscar-thread.c
11793 (ravenscar_thread_target::update_inferior_ptid): Pass target down.
11794 (ravenscar_thread_target::wait, ravenscar_add_thread): Pass target
11795 down.
11796 * record-btrace.c (record_btrace_target::info_record): Adjust.
11797 (record_btrace_target::record_method)
11798 (record_btrace_target::record_is_replaying)
11799 (record_btrace_target::fetch_registers)
11800 (get_thread_current_frame_id, record_btrace_target::resume)
11801 (record_btrace_target::wait, record_btrace_target::stop): Pass
11802 target down.
11803 * record-full.c (record_full_wait_1): Switch to event thread.
11804 Pass target down.
11805 * regcache.c (regcache::regcache)
11806 (get_thread_arch_aspace_regcache, get_thread_arch_regcache): Add
11807 process_stratum_target parameter and handle it.
11808 (current_thread_target): New global.
11809 (get_thread_regcache): Add process_stratum_target parameter and
11810 handle it. Switch inferior before calling target method.
11811 (get_thread_regcache): Pass target down.
11812 (get_thread_regcache_for_ptid): Pass target down.
11813 (registers_changed_ptid): Add process_stratum_target parameter and
11814 handle it.
11815 (registers_changed_thread, registers_changed): Pass target down.
11816 (test_get_thread_arch_aspace_regcache): New.
11817 (current_regcache_test): Define a couple local test_target_ops
11818 instances and use them for testing.
11819 (readwrite_regcache): Pass process_stratum_target parameter.
11820 (cooked_read_test, cooked_write_test): Pass mock_target down.
11821 * regcache.h (get_thread_regcache, get_thread_arch_regcache)
11822 (get_thread_arch_aspace_regcache): Add process_stratum_target
11823 parameter.
11824 (regcache::target): New method.
11825 (regcache::regcache, regcache::get_thread_arch_aspace_regcache)
11826 (regcache::registers_changed_ptid): Add process_stratum_target
11827 parameter.
11828 (regcache::m_target): New field.
11829 (registers_changed_ptid): Add process_stratum_target parameter.
11830 * remote.c (remote_state::supports_vCont_probed): New field.
11831 (remote_target::async_wait_fd): New method.
11832 (remote_unpush_and_throw): Add remote_target parameter.
11833 (get_current_remote_target): Adjust.
11834 (remote_target::remote_add_inferior): Push target.
11835 (remote_target::remote_add_thread)
11836 (remote_target::remote_notice_new_inferior)
11837 (get_remote_thread_info): Pass target down.
11838 (remote_target::update_thread_list): Skip threads of inferiors
11839 bound to other targets. (remote_target::close): Don't discard
11840 inferiors. (remote_target::add_current_inferior_and_thread)
11841 (remote_target::process_initial_stop_replies)
11842 (remote_target::start_remote)
11843 (remote_target::remote_serial_quit_handler): Pass down target.
11844 (remote_target::remote_unpush_target): New remote_target
11845 parameter. Unpush the target from all inferiors.
11846 (remote_target::remote_unpush_and_throw): New remote_target
11847 parameter. Pass it down.
11848 (remote_target::open_1): Check whether the current inferior has
11849 execution instead of checking whether any inferior is live. Pass
11850 target down.
11851 (remote_target::remote_detach_1): Pass down target. Use
11852 remote_unpush_target.
11853 (extended_remote_target::attach): Pass down target.
11854 (remote_target::remote_vcont_probe): Set supports_vCont_probed.
11855 (remote_target::append_resumption): Pass down target.
11856 (remote_target::append_pending_thread_resumptions)
11857 (remote_target::remote_resume_with_hc, remote_target::resume)
11858 (remote_target::commit_resume): Pass down target.
11859 (remote_target::remote_stop_ns): Check supports_vCont_probed.
11860 (remote_target::interrupt_query)
11861 (remote_target::remove_new_fork_children)
11862 (remote_target::check_pending_events_prevent_wildcard_vcont)
11863 (remote_target::remote_parse_stop_reply)
11864 (remote_target::process_stop_reply): Pass down target.
11865 (first_remote_resumed_thread): New remote_target parameter. Pass
11866 it down.
11867 (remote_target::wait_as): Pass down target.
11868 (unpush_and_perror): New remote_target parameter. Pass it down.
11869 (remote_target::readchar, remote_target::remote_serial_write)
11870 (remote_target::getpkt_or_notif_sane_1)
11871 (remote_target::kill_new_fork_children, remote_target::kill): Pass
11872 down target.
11873 (remote_target::mourn_inferior): Pass down target. Use
11874 remote_unpush_target.
11875 (remote_target::core_of_thread)
11876 (remote_target::remote_btrace_maybe_reopen): Pass down target.
11877 (remote_target::pid_to_exec_file)
11878 (remote_target::thread_handle_to_thread_info): Pass down target.
11879 (remote_target::async_wait_fd): New.
11880 * riscv-fbsd-tdep.c: Include "inferior.h".
11881 (riscv_fbsd_get_thread_local_address): Pass down target.
11882 * sol2-tdep.c (sol2_core_pid_to_str): Pass down target.
11883 * sol-thread.c (sol_thread_target::wait, ps_lgetregs, ps_lsetregs)
11884 (ps_lgetfpregs, ps_lsetfpregs, sol_update_thread_list_callback):
11885 Adjust.
11886 * solib-spu.c (spu_skip_standalone_loader): Pass down target.
11887 * solib-svr4.c (enable_break): Pass down target.
11888 * spu-multiarch.c (parse_spufs_run): Pass down target.
11889 * spu-tdep.c (spu2ppu_sniffer): Pass down target.
11890 * target-delegates.c: Regenerate.
11891 * target.c (g_target_stack): Delete.
11892 (current_top_target): Return the current inferior's top target.
11893 (target_has_execution_1): Refer to the passed-in inferior's top
11894 target.
11895 (target_supports_terminal_ours): Check whether the initial
11896 inferior was already created.
11897 (decref_target): New.
11898 (target_stack::push): Incref/decref the target.
11899 (push_target, push_target, unpush_target): Adjust.
11900 (target_stack::unpush): Defref target.
11901 (target_is_pushed): Return bool. Adjust to refer to the current
11902 inferior's target stack.
11903 (dispose_inferior): Delete, and inline parts ...
11904 (target_preopen): ... here. Only dispose of the current inferior.
11905 (target_detach): Hold strong target reference while detaching.
11906 Pass target down.
11907 (target_thread_name): Add assertion.
11908 (target_resume): Pass down target.
11909 (target_ops::beneath, find_target_at): Adjust to refer to the
11910 current inferior's target stack.
11911 (get_dummy_target): New.
11912 (target_pass_ctrlc): Pass the Ctrl-C to the first inferior that
11913 has a thread running.
11914 (initialize_targets): Rename to ...
11915 (_initialize_target): ... this.
11916 * target.h: Include "gdbsupport/refcounted-object.h".
11917 (struct target_ops): Inherit refcounted_object.
11918 (target_ops::shortname, target_ops::longname): Make const.
11919 (target_ops::async_wait_fd): New method.
11920 (decref_target): Declare.
11921 (struct target_ops_ref_policy): New.
11922 (target_ops_ref): New typedef.
11923 (get_dummy_target): Declare function.
11924 (target_is_pushed): Return bool.
11925 * thread-iter.c (all_matching_threads_iterator::m_inf_matches)
11926 (all_matching_threads_iterator::all_matching_threads_iterator):
11927 Handle filter target.
11928 * thread-iter.h (struct all_matching_threads_iterator, struct
11929 all_matching_threads_range, class all_non_exited_threads_range):
11930 Filter by target too. Remove explicit.
11931 * thread.c (threads_executing): Delete.
11932 (inferior_thread): Pass down current inferior.
11933 (clear_thread_inferior_resources): Pass down thread pointer
11934 instead of ptid_t.
11935 (add_thread_silent, add_thread_with_info, add_thread): Add
11936 process_stratum_target parameter. Use it for thread and inferior
11937 searches.
11938 (is_current_thread): New.
11939 (thread_info::deletable): Use it.
11940 (find_thread_ptid, thread_count, in_thread_list)
11941 (thread_change_ptid, set_resumed, set_running): New
11942 process_stratum_target parameter. Pass it down.
11943 (set_executing): New process_stratum_target parameter. Pass it
11944 down. Adjust reference to 'threads_executing'.
11945 (threads_are_executing): New process_stratum_target parameter.
11946 Adjust reference to 'threads_executing'.
11947 (set_stop_requested, finish_thread_state): New
11948 process_stratum_target parameter. Pass it down.
11949 (switch_to_thread): Also match inferior.
11950 (switch_to_thread): New process_stratum_target parameter. Pass it
11951 down.
11952 (update_threads_executing): Reimplement.
11953 * top.c (quit_force): Pop targets from all inferior.
11954 (gdb_init): Don't call initialize_targets.
11955 * windows-nat.c (windows_nat_target) <get_windows_debug_event>:
11956 Declare.
11957 (windows_add_thread, windows_delete_thread): Adjust.
11958 (get_windows_debug_event): Rename to ...
11959 (windows_nat_target::get_windows_debug_event): ... this. Adjust.
11960 * tracefile-tfile.c (tfile_target_open): Pass down target.
11961 * gdbsupport/common-gdbthread.h (struct process_stratum_target):
11962 Forward declare.
11963 (switch_to_thread): Add process_stratum_target parameter.
11964 * mi/mi-interp.c (mi_on_resume_1): Add process_stratum_target
11965 parameter. Use it.
11966 (mi_on_resume): Pass target down.
11967 * nat/fork-inferior.c (startup_inferior): Add
11968 process_stratum_target parameter. Pass it down.
11969 * nat/fork-inferior.h (startup_inferior): Add
11970 process_stratum_target parameter.
11971 * python/py-threadevent.c (py_get_event_thread): Pass target down.
11972
11973 2020-01-10 Pedro Alves <palves@redhat.com>
11974
11975 * remote.c (remote_target::start_remote): Don't set inferior_ptid
11976 directly. Instead find the first thread in the thread list and
11977 use switch_to_thread.
11978
11979 2020-01-10 Pedro Alves <palves@redhat.com>
11980
11981 * remote.c (remote_target::remote_add_inferior): Don't bind a
11982 process to the current inferior if the current inferior is already
11983 bound to a process.
11984
11985 2020-01-10 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
11986 Pedro Alves <palves@redhat.com>
11987
11988 * remote.c (remote_target::remote_parse_stop_reply) <W/X packets>:
11989 If no process is specified, return null_ptid instead of
11990 inferior_ptid.
11991 (remote_target::wait_as): Handle TARGET_WAITKIND_EXITED /
11992 TARGET_WAITKIND_SIGNALLED with no pid.
11993
11994 2020-01-10 Pedro Alves <palves@redhat.com>
11995
11996 * remote.c (first_remote_resumed_thread): New.
11997 (remote_target::wait_as): Use it as default event_ptid instead of
11998 inferior_ptid.
11999
12000 2020-01-10 Pedro Alves <palves@redhat.com>
12001
12002 * infrun.c (handle_no_resumed): Use all_non_exited_inferiors.
12003
12004 2020-01-10 Pedro Alves <palves@redhat.com>
12005
12006 * tracefile-tfile.c (tfile_target::close): Assert that trace_fd is
12007 not -1.
12008
12009 2020-01-10 Pedro Alves <palves@redhat.com>
12010
12011 * break-catch-sig.c (signal_catchpoint_print_it): Don't pass a
12012 ptid to get_last_target_status.
12013 * break-catch-syscall.c (print_it_catch_syscall): Don't pass a
12014 ptid to get_last_target_status.
12015 * infcmd.c (continue_command): Don't pass a target_waitstatus to
12016 get_last_target_status.
12017 (info_program_command): Don't pass a target_waitstatus to
12018 get_last_target_status.
12019 * infrun.c (init_wait_for_inferior): Use
12020 nullify_last_target_wait_ptid.
12021 (get_last_target_status): Handle nullptr arguments.
12022 (nullify_last_target_wait_ptid): Clear target_last_waitstatus.
12023 (print_stop_event): Don't pass a ptid to get_last_target_status.
12024 (normal_stop): Don't pass a ptid to get_last_target_status.
12025 * infrun.h (get_last_target_status, set_last_target_status): Move
12026 comments here and update.
12027 (nullify_last_target_wait_ptid): Declare.
12028 * linux-fork.c (fork_load_infrun_state): Remove local extern
12029 declaration of nullify_last_target_wait_ptid.
12030 * linux-nat.c (get_detach_signal): Don't pass a target_waitstatus
12031 to get_last_target_status.
12032
12033 2020-01-10 Pedro Alves <palves@redhat.com>
12034
12035 * gdbthread.h (scoped_restore_current_thread)
12036 <dont_restore, restore, m_dont_restore>: Declare.
12037 * thread.c (thread_alive): Add assertion. Return bool.
12038 (switch_to_thread_if_alive): New.
12039 (prune_threads): Switch inferior/thread.
12040 (print_thread_info_1): Switch thread before calling target methods.
12041 (scoped_restore_current_thread::restore): New, factored out from
12042 ...
12043 (scoped_restore_current_thread::~scoped_restore_current_thread):
12044 ... this.
12045 (scoped_restore_current_thread::scoped_restore_current_thread):
12046 Add assertion.
12047 (thread_apply_all_command, thread_select): Use
12048 switch_to_thread_if_alive.
12049 * infrun.c (proceed, restart_threads, handle_signal_stop)
12050 (switch_back_to_stepped_thread): Switch current thread before
12051 calling target methods.
12052
12053 2020-01-10 Pedro Alves <palves@redhat.com>
12054
12055 * inferior.c (switch_to_inferior_no_thread): New function,
12056 factored out from ...
12057 (inferior_command): ... here.
12058 * inferior.h (switch_to_inferior_no_thread): Declare.
12059 * mi/mi-main.c (run_one_inferior): Use
12060 switch_to_inferior_no_thread.
12061
12062 2020-01-10 Pedro Alves <palves@redhat.com>
12063
12064 * infcmd.c (kill_command): Remove dead code.
12065
12066 2020-01-10 Pedro Alves <palves@redhat.com>
12067
12068 * remote.c (remote_target::mourn_inferior): No longer check
12069 whether the target is running.
12070
12071 2020-01-10 Pedro Alves <palves@redhat.com>
12072
12073 * corelow.c (core_target::has_execution): Change parameter type to
12074 inferior pointer.
12075 * inferior.c (number_of_live_inferiors): Use
12076 inferior::has_execution instead of target_has_execution_1.
12077 * inferior.h (inferior::has_execution): New.
12078 * linux-thread-db.c (thread_db_target::update_thread_list): Use
12079 inferior::has_execution instead of target_has_execution_1.
12080 * process-stratum-target.c
12081 (process_stratum_target::has_execution): Change parameter type to
12082 inferior pointer. Check the inferior's PID instead of
12083 inferior_ptid.
12084 * process-stratum-target.h
12085 (process_stratum_target::has_execution): Change parameter type to
12086 inferior pointer.
12087 * record-full.c (record_full_core_target::has_execution): Change
12088 parameter type to inferior pointer.
12089 * target.c (target_has_execution_1): Change parameter type to
12090 inferior pointer.
12091 (target_has_execution_current): Adjust.
12092 * target.h (target_ops::has_execution): Change parameter type to
12093 inferior pointer.
12094 (target_has_execution_1): Change parameter type to inferior
12095 pointer. Change return type to bool.
12096 * tracefile.h (tracefile_target::has_execution): Change parameter
12097 type to inferior pointer.
12098
12099 2020-01-10 Pedro Alves <palves@redhat.com>
12100
12101 * exceptions.c (print_flush): Remove current_top_target() check.
12102
12103 2020-01-10 Pedro Alves <palves@redhat.com>
12104
12105 * remote.c (show_remote_exec_file): Show the current inferior's
12106 exec-file instead of the command variable's value.
12107
12108 2020-01-10 Pedro Alves <palves@redhat.com>
12109
12110 * record-full.c (record_full_resume_ptid): New global.
12111 (record_full_target::resume): Set it.
12112 (record_full_wait_1): Use record_full_resume_ptid instead of
12113 inferior_ptid.
12114
12115 2020-01-10 Pedro Alves <palves@redhat.com>
12116
12117 * gdbthread.h (scoped_restore_current_thread)
12118 <dont_restore, restore, m_dont_restore>: Declare.
12119 * thread.c (thread_alive): Add assertion. Return bool.
12120 (switch_to_thread_if_alive): New.
12121 (prune_threads): Switch inferior/thread.
12122 (print_thread_info_1): Switch thread before calling target methods.
12123 (scoped_restore_current_thread::restore): New, factored out from
12124 ...
12125 (scoped_restore_current_thread::~scoped_restore_current_thread):
12126 ... this.
12127 (scoped_restore_current_thread::scoped_restore_current_thread):
12128 Add assertion.
12129 (thread_apply_all_command, thread_select): Use
12130 switch_to_thread_if_alive.
12131
12132 2020-01-10 George Barrett <bob@bob131.so>
12133
12134 * stap-probe.c (stap_modify_semaphore): Don't check for null
12135 semaphores.
12136 (stap_probe::set_semaphore, stap_probe::clear_semaphore): Check
12137 for null semaphores.
12138
12139 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
12140
12141 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Update
12142 all source windows, and maintain horizontal scroll status while
12143 doing so.
12144
12145 2020-01-09 Tom Tromey <tom@tromey.com>
12146
12147 PR tui/18932:
12148 * tui/tui-source.c (tui_source_window::do_scroll_vertical): Call
12149 update_source_window, not print_source_lines.
12150
12151 2020-01-09 Andrew Burgess <andrew.burgess@embecosm.com>
12152
12153 * tui/tui.c (tui_enable): Register tui hooks after calling
12154 tui_display_main.
12155
12156 2020-01-09 Christian Biesinger <cbiesinger@google.com>
12157
12158 * gdbsupport/common-defs.h: Don't define _FORTIFY_SOURCE on MinGW.
12159
12160 2020-01-08 Simon Marchi <simon.marchi@efficios.com>
12161
12162 * thread.c (print_thread_info_1): Fix indentation.
12163
12164 2020-01-09 Christian Biesinger <cbiesinger@google.com>
12165
12166 * symtab.c (general_symbol_info::compute_and_set_names): Move the
12167 unique_xmalloc_ptr outside the if to always free the demangled name.
12168
12169 2020-01-08 Tom Tromey <tromey@adacore.com>
12170
12171 * xcoffread.c (enter_line_range, read_xcoff_symtab)
12172 (process_xcoff_symbol, xcoff_symfile_offsets): Update.
12173 * symtab.h (MSYMBOL_VALUE_ADDRESS): Update.
12174 (struct section_offsets, ANOFFSET, SIZEOF_N_SECTION_OFFSETS):
12175 Remove.
12176 (section_offsets): New typedef.
12177 * symtab.c (fixup_section, get_msymbol_address): Update.
12178 * symmisc.c (dump_msymbols): Update.
12179 * symfile.h (relative_addr_info_to_section_offsets)
12180 (symfile_map_offsets_to_segments): Update.
12181 * symfile.c (build_section_addr_info_from_objfile)
12182 (init_objfile_sect_indices): Update.
12183 (struct place_section_arg): Change type of "offsets".
12184 (place_section): Update.
12185 (relative_addr_info_to_section_offsets): Change type of
12186 "section_offsets". Remove "num_sections" parameter.
12187 (default_symfile_offsets, syms_from_objfile_1)
12188 (set_objfile_default_section_offset): Update.
12189 (reread_symbols): No need to preserve section offsets by hand.
12190 (symfile_map_offsets_to_segments): Change type of "offsets".
12191 * stap-probe.c (relocate_address): Update.
12192 * stabsread.h (process_one_symbol): Update.
12193 * solib-target.c (struct lm_info_target) <offsets>: Change type.
12194 (solib_target_relocate_section_addresses): Update.
12195 * solib-svr4.c (enable_break, svr4_relocate_main_executable):
12196 Update.
12197 * solib-frv.c (frv_relocate_main_executable): Update.
12198 * solib-dsbt.c (dsbt_relocate_main_executable): Update.
12199 * solib-aix.c (solib_aix_get_section_offsets): Change return
12200 type.
12201 (solib_aix_solib_create_inferior_hook): Update.
12202 * remote.c (remote_target::get_offsets): Update.
12203 * psymtab.c (find_pc_sect_psymtab): Update.
12204 * psympriv.h (struct partial_symbol) <address, text_low,
12205 text_high>: Update.
12206 * objfiles.h (obj_section_offset): Update.
12207 (struct objfile) <section_offsets>: Change type.
12208 <num_sections>: Remove.
12209 (objfile_relocate): Update.
12210 * objfiles.c (entry_point_address_query): Update
12211 (relocate_one_symbol): Change type of "section_offsets".
12212 (objfile_relocate1, objfile_relocate1): Change type of
12213 "new_offsets".
12214 (objfile_rebase1): Update.
12215 * mipsread.c (mipscoff_symfile_read): Update.
12216 (read_alphacoff_dynamic_symtab): Remove "section_offsets"
12217 parameter.
12218 * mdebugread.c (parse_symbol): Change type of "section_offsets".
12219 (parse_external, psymtab_to_symtab_1): Update.
12220 * machoread.c (macho_symfile_offsets): Update.
12221 * ia64-tdep.c (ia64_find_unwind_table): Update.
12222 * hppa-tdep.c (read_unwind_info): Update.
12223 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Update.
12224 * dwarf2read.c (create_addrmap_from_index)
12225 (create_addrmap_from_aranges, dw2_find_pc_sect_compunit_symtab)
12226 (process_psymtab_comp_unit_reader, add_partial_symbol)
12227 (add_partial_subprogram, process_full_comp_unit)
12228 (read_file_scope, read_func_scope, read_lexical_block_scope)
12229 (read_call_site_scope, dwarf2_rnglists_process)
12230 (dwarf2_ranges_process, dwarf2_ranges_read)
12231 (dwarf_decode_lines_1, var_decode_location, new_symbol)
12232 (dwarf2_fetch_die_loc_sect_off, dwarf2_per_cu_text_offset):
12233 Update.
12234 * dwarf2-frame.c (execute_cfa_program, dwarf2_frame_find_fde):
12235 Update.
12236 * dtrace-probe.c (dtrace_probe::get_relocated_address): Update.
12237 * dbxread.c (read_dbx_symtab, read_ofile_symtab): Update.
12238 (process_one_symbol): Change type of "section_offsets".
12239 * ctfread.c (get_objfile_text_range): Update.
12240 * coffread.c (coff_symtab_read, enter_linenos)
12241 (process_coff_symbol): Update.
12242 * coff-pe-read.c (add_pe_forwarded_sym): Update.
12243 * amd64-windows-tdep.c (amd64_windows_find_unwind_info): Update.
12244
12245 2020-01-08 Tom Tromey <tromey@adacore.com>
12246
12247 * dwarf2read.c (parse_macro_definition): Use std::string.
12248 (parse_macro_definition): Likewise.
12249
12250 2020-01-08 Tom Tromey <tromey@adacore.com>
12251
12252 * dwarf2read.c (abbrev_table_read_table): Use std::vector.
12253 (ATTR_ALLOC_CHUNK): Remove.
12254
12255 2020-01-08 Tom Tromey <tromey@adacore.com>
12256
12257 * dwarf2read.c (fixup_go_packaging): Use unique_xmalloc_ptr.
12258
12259 2020-01-08 Tom Tromey <tromey@adacore.com>
12260
12261 * dwarf2read.c (add_partial_symbol): Use unique_xmalloc_ptr.
12262 (dwarf2_compute_name, open_dwo_file): Likewise.
12263 (process_enumeration_scope): Use std::vector.
12264 (guess_partial_die_structure_name): Use unique_xmalloc_ptr.
12265 (partial_die_info::fixup, dwarf2_start_subfile)
12266 (guess_full_die_structure_name, dwarf2_name): Likewise.
12267 (determine_prefix): Update.
12268 (guess_full_die_structure_name): Make return type const.
12269 (partial_die_full_name): Return unique_xmalloc_ptr.
12270 (DW_FIELD_ALLOC_CHUNK): Remove.
12271
12272 2020-01-07 Tom Tromey <tromey@adacore.com>
12273
12274 PR build/24937:
12275 * stap-probe.c (class stap_static_probe_ops): Add constructor.
12276
12277 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
12278
12279 * cli/cli-style.c: Set cli_styling to 'true' in the Cygwin build.
12280
12281 2020-01-06 Andrew Burgess <andrew.burgess@embecosm.com>
12282
12283 * stack.c (print_frame_info): Move disassemble_next_line code
12284 inside source_print block.
12285
12286 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12287
12288 * gdbsupport/gdb_wait.c: Include <signal.h> instead of
12289 gdb/signals.h, as we are now using native signal symbols.
12290
12291 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
12292
12293 * tui/tui-disasm.c (tui_disasm_window::addr_is_displayed): Avoid
12294 overflow by an early check of content vs threshold.
12295 * tui/tui-source.c (tui_source_window::line_is_displayed):
12296 Likewise.
12297
12298 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12299
12300 * NEWS: Mention the recent fix of $_exitsignal on MS-Windows.
12301
12302 2020-01-02 Jon Turney <jon.turney@dronecode.org.uk>
12303
12304 * coff-pe-read.c (read_pe_exported_syms): Don't try to read the
12305 export table if no section contains it's RVA.
12306
12307 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12308
12309 * windows-tdep.c: Fix a typo in WINDOWS_SIGABRT.
12310
12311 2020-01-06 Hannes Domani <ssbssa@yahoo.de>
12312
12313 * source.c (print_source_lines_base): Set last_line_listed.
12314
12315 2020-01-06 Shahab Vahedi <shahab@synopsys.com>
12316
12317 * tui/tui-disasm.c: Remove trailing spaces.
12318
12319 2020-01-06 Eli Zaretskii <eliz@gnu.org>
12320 Pedro Alves <palves@redhat.com>
12321
12322 * Makefile.in (COMMON_SFILES): Add gdbsupport/gdb_wait.c.
12323 * windows-tdep.c: New enumeration of WINDOWS_SIG* signals.
12324 (windows_gdb_signal_to_target): New function, uses the above
12325 enumeration to convert GDB internal signal codes to equivalent
12326 Windows codes.
12327 (windows_init_abi): Call set_gdbarch_gdb_signal_to_target.
12328 * windows-nat.c: Include "gdb_wait.h".
12329 (get_windows_debug_event): Extract the fatal exception from the
12330 exit status and convert to the equivalent Posix signal number.
12331 * cli/cli-cmds.c (exit_status_set_internal_vars): Account for the
12332 possibility that WTERMSIG returns GDB_SIGNAL_UNKNOWN.
12333 * gdbsupport/gdb_wait.c: New file, implements
12334 windows_status_to_termsig.
12335 * gdbsupport/gdb_wait.h (WIFEXITED, WIFSIGNALED, WEXITSTATUS)
12336 (WTERMSIG) [__MINGW32__]: Separate definitions for MinGW.
12337
12338 2020-01-05 Andrew Burgess <andrew.burgess@embecosm.com>
12339
12340 * tui/tui-layout.c (tui_add_win_to_layout): Use tui_set_layout not
12341 show_layout.
12342
12343 2020-01-05 Luis Machado <luis.machado@linaro.org>
12344
12345 * aarch64-linux-nat.c
12346 (aarch64_linux_nat_target::thread_architecture): Use bfd_arch_aarch64
12347 and bfd_mach_aarch64.
12348
12349 2020-01-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
12350
12351 * ui-file.c (stdio_file::can_emit_style_escape)
12352 (tee_file::can_emit_style_escape): Ensure style is used also on
12353 gdb_stderr when gdb_stderr is a tty supporting styling, similarly
12354 to gdb_stdout.
12355 * main.c (set_gdb_data_directory): Use file style to output the
12356 warning that the given pathname is not a directory.
12357 * top.c (show_history_filename, gdb_safe_append_history)
12358 (show_gdb_datadir): Use file style.
12359
12360 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
12361
12362 * solib-target.c (struct lm_info_target):
12363 Change offsets to be a unique_xmalloc_ptr.
12364 (solib_target_relocate_section_addresses): Update.
12365
12366 2020-01-03 Hannes Domani <ssbssa@yahoo.de>
12367
12368 * windows-nat.c (windows_clear_solib): Free so_list linked list.
12369
12370 2020-01-03 Bernd Edlinger <bernd.edlinger@hotmail.de>
12371
12372 * MAINTAINERS (Write After Approval): Add myself.
12373
12374 2020-01-02 Luis Machado <luis.machado@linaro.org>
12375
12376 * proc-service.c (get_ps_regcache): Remove reference to obsolete
12377 Cell BE architecture.
12378 * target.h (struct target_ops) <thread_architecture>: Likewise.
12379
12380 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
12381
12382 * Makefile.in: Use INSTALL_PROGRAM_ENV.
12383
12384 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
12385
12386 * MAINTAINERS (Write After Approval): Add myself.
12387
12388 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12389
12390 * gdbarch.sh: Update copyright year range of generated files.
12391
12392 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12393
12394 Update copyright year range in all GDB files.
12395
12396 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12397
12398 * copyright.py: Convert to Python 3.
12399
12400 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12401
12402 * copyright.py: Adapt after move of gnulib directory from gdb
12403 directory to toplevel directory.
12404
12405 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12406
12407 * copyright.py (main): Exit if run from the wrong directory.
12408
12409 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12410
12411 * top.c (print_gdb_version): Change copyright year to 2020.
12412
12413 2020-01-01 Joel Brobecker <brobecker@adacore.com>
12414
12415 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2019.
12416
12417 For older changes see ChangeLog-2019.
12418 \f
12419 Local Variables:
12420 mode: change-log
12421 left-margin: 8
12422 fill-column: 74
12423 version-control: never
12424 coding: utf-8
12425 End:
This page took 0.490692 seconds and 3 git commands to generate.